An interactive method, device and storage medium based on custom instructions

By registering interface functions in the editing interface of custom instructions, and obtaining and processing parameter information passed by the editing end, the error input problem caused by unintuitive modification of attribute values ​​is solved, and development efficiency and error tolerance are improved.

CN114579119BActive Publication Date: 2024-12-17SHANGHAI JIEKA ROBOT TECH CO LTD
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
CN202210291629.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-23
Publication Date
2024-12-17
Estimated Expiration
2042-03-23

AI Technical Summary

Technical Problem

When the attribute value is directly modified in the editing interface of the custom instruction, the attribute status status of the command after the attribute value is modified cannot be visually displayed, resulting in a high frequency of input errors and reducing development efficiency.

Method used

By registering an interface function for listening to the custom instruction attribute value editing interface on the client, obtaining the parameter information passed by the editing end, and performing corresponding interaction operations based on this information, realizing intuitive editing and saving of attribute values, and improving interaction efficiency .

Benefits of technology

Improve the fault tolerance and development efficiency of property value editing, ensure accurate editing and saving of property values, and reduce the possibility of manual input errors.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114579119B_ABST
    Figure CN114579119B_ABST
Patent Text Reader

Abstract

The present application provides an interactive method, device and storage medium based on custom instructions, which are applied to a client and relate to the technical field of human-computer interaction. The method requests to load an attribute value editing interface through trigger information of a custom instruction of a client. When the attribute value editing interface is successfully loaded, an interface function of the listening editing end is registered on the client. The interface function is equivalent to the communication interface between the two ends. When the editing end is monitored to be called, parameter information transmitted by the interface function from the editing end is obtained, and corresponding interactive logic is executed according to the parameter information, so that intuitive attribute value setting can be realized from the attribute value editing interface displayed on the editing end into the client, thereby improving fault tolerance and development efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of human-computer interaction technology, and in particular to an interaction method, device and storage medium based on custom instructions. Background Art

[0002] Graphical programming is one of the ways of human-computer interaction. Graphical programming is to write programs with interfaces. Programming language is a standardized communication skill used to issue instructions to computers and define computer programs. Customized graphical programming instructions are pre-established by users on the client side. By modifying the internal attribute values ​​of custom instructions, the control of intelligent devices such as robots can be further realized.

[0003] At present, the editing interface corresponding to the above-mentioned custom instructions can display and modify the instruction attribute values. However, directly modifying certain attribute values ​​in the editing interface cannot intuitively display the instruction attribute status after the attribute value is modified, which is easy to cause input errors, thereby reducing development efficiency. Summary of the invention

[0004] In view of this, the purpose of the embodiments of the present application is to provide a method, device and storage medium based on custom instructions, by registering an interface function for monitoring the attribute value editing interface corresponding to the custom instruction on the client, and using the interface function to transmit the attribute value information displayed on the editing end, to solve the technical problem of "directly modifying certain attribute values ​​in the editing interface, which cannot intuitively display the instruction attribute status after the attribute value is modified, which is easy to cause input errors, thereby reducing development efficiency."

[0005] In the first aspect, an embodiment of the present application provides a method based on custom instructions, which is applied to a client, and the method includes: based on the trigger information of the custom instruction, initiating a request to access the editing end to load the attribute value editing interface corresponding to the custom instruction; registering an interface function for monitoring the editing end; after monitoring that the interface function is called by the editing end, obtaining parameter information passed by the interface function; and performing corresponding interactive operations based on the parameter information.

[0006] In the above implementation process, the attribute value editing interface is loaded through the trigger information request of the custom instruction. When the attribute value editing interface is loaded successfully, the interface function of the editing end is registered on the client. The interface function is equivalent to the communication interface between the two ends. When the editing end is monitored to be called, the parameter information passed back from the editing end by the interface function is obtained, and the corresponding interaction logic is executed according to the parameter information, so that the attribute value setting can be intuitively entered from the editing end attribute value editing interface into the client, thereby improving the fault tolerance rate and development efficiency.

[0007] Optionally, performing corresponding operations based on the parameter information includes: parsing the parameter type of the parameter information; performing corresponding interactive operations based on the parameter type; wherein the interactive operations include: obtaining the parameter information of the internal editing interface of the client through the editing end to achieve interaction, saving the parameter information to the custom instruction to achieve interaction, and closing the attribute value editing interface to achieve interaction.

[0008] In the above implementation process, by calling and passing parameters of the interface function, the specific operation information inside the client can be passed to the editing end for display, the information displayed on the editing end can be saved in the client's custom instructions, and the attribute value editing interface displayed on the editing end can be directly closed, thereby realizing accurate editing of attribute values ​​inside custom instructions and improving interaction efficiency.

[0009] Optionally, the parameter information of the internal editing interface of the client is obtained through the editing end to achieve interaction, including: if the parameter type is an interactive command for calling the internal editing interface of the client, then after opening the internal editing interface of the client from the editing end, setting the attribute value in the internal editing interface of the client; calling the callback function corresponding to the interface function, and assigning the set attribute value to the callback function, generating parameter information corresponding to the callback function, so that the editing end can receive the parameter information passed by the callback function and display it.

[0010] In the above implementation process, when the parameter type is the interactive information generated by calling the internal editing interface of the client, specific editing operations can be performed inside the client from the editing end, avoiding the error-prone problem of manually entering a large amount of specific attribute value information on the editing end, realizing intuitive editing of attribute values, and improving development efficiency.

[0011] Optionally, saving the parameter information to the custom instruction to achieve interaction, and closing the property value editing interface to achieve interaction, include: if the parameter type is a save command of the property value editing interface, obtaining the parameter information passed by the interface function, and saving the parameter information to the custom instruction; if the parameter type is a close command of the property value editing interface, closing the property value editing interface displayed on the editing end.

[0012] In the above implementation process, when the parameter type is the save or close information generated by the attribute value editing interface, the information displayed on the editing end is saved to the client custom instruction, or the attribute value editing interface displayed on the editing end is directly closed to realize direct editing of the attribute value and improve the interaction efficiency between the client and the editing end.

[0013] In the second aspect, an embodiment of the present application provides an interaction method based on custom instructions, which is applied to the editing end, and the method includes: receiving a request initiated by a client through a custom instruction; displaying an attribute value editing interface corresponding to the custom instruction based on the request; setting attribute values ​​in the attribute value editing interface; and calling an interface function registered by the client, and assigning the set attribute value to the interface function, generating parameter information corresponding to the interface function, so that the client can receive the parameter information passed by the interface function for interaction.

[0014] In the above implementation process, the attribute value can be directly modified or edited on the editing end, and the attribute value currently displayed on the editing end is assigned to the interface function. The client listens to the interface function being called, thereby obtaining the parameter information transmitted by the interface function, and implements client internal operations, saving, closing and other interactions based on the parameter information.

[0015] Optionally, setting the attribute value in the attribute value editing interface includes: opening the client internal editing interface based on entry information from the attribute value editing interface to enter the client internal editing interface, so as to set the attribute value through the client internal editing interface; receiving parameter information passed by the callback function corresponding to the interface function; and generating and displaying the attribute value of the attribute value editing interface based on the parameter information.

[0016] In the above implementation process, the specific attribute value information obtained by entering the client's internal editing interface for modification or editing can be displayed in the attribute value editing interface of the editing end through the callback function, thereby realizing intuitive editing and improving development efficiency.

[0017] In the third aspect, an embodiment of the present application provides a device for custom instructions, which is applied to a client, and the device includes: a request module, which is used to initiate a request to access an editing end based on trigger information of the custom instruction to load an attribute value editing interface corresponding to the custom instruction; a registration module, which is used to register an interface function for monitoring the editing end; a parameter receiving module, which is used to obtain parameter information passed by the interface function after monitoring the interface function being called by the editing end; and an interaction module, which is used to perform corresponding interactive operations based on the parameter information.

[0018] In a fourth aspect, an embodiment of the present application provides a device for custom instructions, which is applied to an editing end, and the device includes: a receiving module, used to receive a request initiated by a client through a custom instruction; a display module, used to display an attribute value editing interface corresponding to the custom instruction based on the request; an editing module, used to set attribute values ​​in the attribute value editing interface; and a parameter transfer module, used to call an interface function registered by the client, and assign the set attribute value to the interface function, and generate parameter information corresponding to the interface function, so that the client can receive the parameter information transferred by the interface function for interaction.

[0019] In a fifth aspect, an embodiment of the present application provides an interactive method based on custom instructions, and the interactive method based on custom instructions is applied to a system including a client and an editing end, and the client is communicatively connected to the editing end; the client, based on the trigger information of the custom instruction, initiates a request to access the editing end to load the attribute value editing interface corresponding to the custom instruction; the editing end receives the request initiated by the client through the custom instruction, displays the attribute value editing interface corresponding to the custom instruction based on the request, and sets the attribute value in the attribute value editing interface; the client registers an interface function for monitoring the editing end, and after monitoring that the interface function is called by the editing end, obtains the parameter information passed by the interface function; the editing end calls the interface function registered by the client, and assigns the set attribute value to the interface function to generate parameter information corresponding to the interface function; and the client performs corresponding interactive operations based on the parameter information.

[0020] In the above implementation process, by calling and passing parameters of the interface function between the client and the editing end, the client's internal operations, saving, closing and other interactions are performed according to the parameter information, which improves the fault tolerance of attribute value editing and the development efficiency of custom instructions.

[0021] In a sixth aspect, an embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the above method are executed.

[0022] In order to make the above-mentioned objects, features and advantages of the present application more obvious and understandable, embodiments are given below and described in detail with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments of the present application will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.

[0024] Figure 1 A flowchart of an interactive method based on custom instructions provided in an embodiment of the present application;

[0025] Figure 2 A flowchart of an interactive method based on custom instructions applied to a client provided in an embodiment of the present application;

[0026] Figure 3 A flowchart of an interactive method based on custom instructions applied to an editing terminal provided in an embodiment of the present application;

[0027] Figure 4 A flowchart of a preferred interactive method based on custom instructions provided in an embodiment of the present application;

[0028] Figure 5 A schematic diagram of functional modules of an interactive device based on custom instructions applied to a client provided in an embodiment of the present application;

[0029] Figure 6 A functional module diagram of an interactive device based on custom instructions applied to an editing terminal provided in an embodiment of the present application; and

[0030] Figure 7 A block diagram of an electronic device providing an apparatus according to an embodiment of the present application.

[0031] Icons: 210-request module; 220-registration module; 230-receiving parameter module; 240-interaction module; 250-receiving module; 260-display module; 270-editing module; 280-transmitting parameter module; 300-electronic device; 311-memory; 312-storage controller; 313-processor; 314-peripheral interface; 315-input and output unit; 316-display unit. DETAILED DESCRIPTION

[0032] The technical solutions in the embodiments of the present application will be described below in conjunction with the accompanying drawings in the embodiments of the present application.

[0033] It should be noted that similar reference numerals and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in subsequent drawings. At the same time, in the description of this application, the terms "first", "second", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance.

[0034] The inventor of this application noticed that the editing interface of custom instructions is to display and modify the instruction attribute values. When directly modifying certain attribute values ​​in the editing interface, it may not be intuitive and concise enough and increase the possibility of input errors. For example, when modifying the robot point (joint coordinates and Cartesian coordinates), the information directly input into the point is too much and the posture corresponding to the point cannot be displayed intuitively. At this time, it is necessary to enter the manual operation interface inside the APP to teach the robot, and call back the taught point to the instruction editing interface. There is no need to manually enter the point value. Therefore, by setting an interactive interface, the editing interface of the editing end can interact with the client to set and transfer the attribute value, solving the problem of not intuitive display and possible errors when the user directly inputs.

[0035] Based on the above research, an embodiment of the present application provides an interactive method based on custom instructions, which requests the loading of the attribute value editing interface through the trigger information of the custom instruction. When the attribute value editing interface is loaded successfully, the interface function of the listening editing end is registered on the client. The interface function is equivalent to the communication interface between the two ends. When the editing end is monitored to be called, the parameter information passed by the interface function from the editing end is obtained, and the corresponding interactive logic is executed according to the parameter information, so that the intuitive attribute value setting can be realized from the attribute value editing interface of the editing end to the client, thereby improving the fault tolerance rate and development efficiency.

[0036] See also Figure 1 , Figure 1 An interactive method based on custom instructions is provided in an embodiment of the present application, and the specific process of this embodiment is explained in detail below.

[0037] The interactive method based on custom instructions is applied to a system including a client and an editing end, and the client is connected to the editing end for communication.

[0038] Exemplarily, the client can be a mobile Android platform, a mobile IOS platform, a PC, or an application APP; the editing end can be an editable Web page, an H5 (HyperText Markup Language5, the fifth generation hypertext markup language) page, and can be on the same application APP as the client, or on a different platform from the client; by defining the same code and using the same calling usage specifications, the client and editing end can be uniformly packaged under different systems.

[0039] This embodiment may specifically include step 100 , step 120 , step 140 , step 160 and step 180 .

[0040] Step 100: The client initiates a request to access the editing end based on the trigger information of the custom instruction to load the attribute value editing interface corresponding to the custom instruction;

[0041] Step 120: The editing end receives the request initiated by the client through the custom instruction, displays the attribute value editing interface corresponding to the custom instruction based on the request, and sets the attribute value in the attribute value editing interface;

[0042] Step 140: The client registers an interface function for monitoring the editing end, and after monitoring the interface function being called by the editing end, obtains parameter information passed by the interface function;

[0043] Step 160: the editing end calls the interface function registered by the client, and assigns the set attribute value to the interface function, generating parameter information corresponding to the interface function; and

[0044] Step 180: The client performs corresponding interactive operations based on the parameter information.

[0045] In step 100 , the client initiates a request to access the editing end based on the trigger information of the custom instruction to load the attribute value editing interface corresponding to the custom instruction.

[0046] Exemplarily, a custom instruction can be a graphic programming instruction independently developed by the user on the client side, and the user can use this solution to display, modify or edit the internal attribute values ​​of the custom instruction. The custom instruction includes a unique attribute name, multiple attribute types, and attribute values ​​corresponding to the attribute types, where the attribute types can include: text, condition, input box, drop-down box, hidden text and case statement block. The trigger information can be the trigger information generated by the user on the client side through operations such as "clicking", "sliding", and "long pressing" the custom instruction. For this request, it can be implemented through the get() method, specifically loading information through a remote Http Get request.

[0047] The attribute value editing interface can be a web page written by the user himself, or a Webview control, that is, a web page view, a browser control that is nested on the client custom instruction interface to display a web page, and a control that can parse DOM elements and display HTML pages.

[0048] Optionally, users can add custom instructions on the client side. First, enter a unique name for the custom instruction and select the instruction type as instruction or instruction block. Then, you can add the correct URL editing path and the correct URL script path for the custom instruction. When editing a custom instruction, the user clicks on the custom instruction to generate trigger information, thereby triggering the client to obtain the editing path of the custom instruction to access the editing end, initiate a Get request, and concatenate the attribute name and attribute value of the custom instruction, that is, specifically package the attribute name and attribute value contained in the custom instruction in Json data format as the transmission parameter of the Get request to the editing end, so as to request to load and display the attribute value editing interface of the Get request transmission parameter.

[0049] Step 120: The editing end receives the request initiated by the client through the custom instruction, displays the attribute value editing interface corresponding to the custom instruction based on the request, and then sets the attribute value in the attribute value editing interface.

[0050] For example, after the editing end receives the Get request initiated by the client user by clicking the custom instruction, it waits for the client to load, and after the loading is successful, the attribute value editing interface corresponding to the custom instruction is displayed on the editing end to modify or edit the attribute values ​​of various types of the custom instruction. In the attribute value editing interface, the attribute values ​​of multiple different attribute types displayed can be arbitrarily set or edited.

[0051] Optionally, modify the value displayed in the attribute value editing interface of the editing end, that is, the attribute value of the custom instruction passed and displayed by the Get request, for example: the attribute value corresponding to the attribute name "name": "test"; the attribute value corresponding to the attribute name "time": "1"; the attribute value corresponding to the attribute name "posinfos point": "0,0,0,0,0,0,0", etc.

[0052] Step 140: The client registers an interface function for monitoring the editing end, and after monitoring the interface function being called by the editing end, obtains parameter information passed by the interface function;

[0053] Step 160: The editing end calls the interface function registered by the client, and assigns the set attribute value to the interface function, generating parameter information corresponding to the interface function.

[0054] For example, the interactive interface for accessing the editing end is registered on the client side through the JavaScript method, and the registration methods on different platforms are slightly different. For example: on the PC platform, the interface function JAKAController.jakaCall can be registered through the RgisterFunction method; on the mobile Android platform, the JavaScriptInterface method is initialized to establish an entity interface class of JavaScriptInterface, and all methods are annotated with @JavascriptInterface, so as to implement its interface method in the activity; on the mobile IOS platform, the content of JAKAController is injected into js, ​​and a message listening callback is added, and at the same time, a proxy for the js message callback is added to implement the protocol method, so as to receive the message from the interface.

[0055] Optionally, one of the above methods is used to register an interface function on the client: JAKAController.jakaCall, which serves as the request entry for the client to access the editing end. Generally, programming languages ​​have a monitoring function. Therefore, after successful registration, the client will monitor whether the interface function is called by the editing end. After the editing end completes the modification or editing of the attribute value, it calls the interface function registered by the client and assigns the attribute value currently displayed on the editing end to the interface function. The client monitors the interface function being called, thereby obtaining the parameter information sent by the interface function.

[0056] The parameters of the interface function JAKAController.jakaCall may include: the type of parameter type, callback function callback, and request related data data. The callback function indicates the callback function that is called after the client completes the internal operation and clicks OK or Cancel. If it is not filled in, the default call will be window.jakaCallBack, that is, the callback in JAKAController.jakaCall. If no parameters are passed, the client calls window.jakaCallBack by default to return the parameters set by the client to the editing end.

[0057] Taking the teaching robot as an example: the relevant parameters of the interface function can be specifically: {"type":"jakaMoveRobot"; "callback":"window.jakaMoveRobotCallBack"; "data":{"pose":"0,0,0,0,0,0,0", "jointpose":"0,0,0,0,0,0,0"}}, jakaMoveRobot indicates that the parameter type is robot point movement; the callback function calls the user-defined callback function window.jakaMoveRobotCallBac by default; the request related data data parameters include two attribute parameters such as pose and jointpose, and the specific attribute value data of pose and jointpose are obtained according to the attribute value displayed in the attribute value editing interface.

[0058] Step 180: The client performs corresponding interactive operations based on the parameter information.

[0059] Exemplarily, the client listens to the interface function being called, thereby obtaining the parameter information transmitted by the interface function, parsing the transmitted parameter information, and further determining what interactive operation to perform. Since the type of the transmitted parameter is predefined, the client first determines what type it belongs to, and then performs the corresponding interactive operation. The interactive operation may include: entering the client to perform editing operations, saving the attribute information of the attribute value editing interface to the client's custom instructions, or closing the attribute value editing interface displayed on the editing end.

[0060] See also Figure 2 , Figure 2 A flowchart of an interactive method based on custom instructions applied to a client provided in an embodiment of the present application is provided. The specific process of this embodiment is explained in detail below.

[0061] Step 101: Based on the trigger information of the custom instruction, a request to access the editing end is initiated to load the attribute value editing interface corresponding to the custom instruction;

[0062] Step 141: registering an interface function for monitoring the editing end;

[0063] Step 142: after monitoring that the interface function is called by the editing terminal, obtaining parameter information passed by the interface function; and

[0064] Step 181: Perform corresponding interactive operations based on the parameter information.

[0065] Exemplarily, a client user enters a unique name for the custom instruction, selects the instruction type as instruction or instruction block, and then adds the correct URL editing path and the correct URL script path, thereby adding a custom instruction based on a programming language on the client; when editing the custom instruction, the user clicks on the custom instruction to generate trigger information, which triggers the client to obtain the editing path of the custom instruction to access the editing end, initiates a Get request, concatenates the attribute name and attribute value contained in the custom instruction in Json data format, and passes it to the editing end as a Get request passing parameter, so as to request to load and display the attribute value editing interface of the Get request passing parameter.

[0066] Optionally, a JavaScript method is used to register an interface function for accessing the editing end on the client: JAKAController.jakaCall, which is used as the request entry for the client to access the editing end. After successful registration, the client will monitor whether the interface function is called by the editing end. When the client monitors the interface function being called, it obtains the parameter information transmitted by the interface function. The transmitted parameter information is parsed to further determine what interactive operation to perform.

[0067] In one embodiment, step 181 may specifically include: step 1811 and step 1812.

[0068] Wherein, step 1811: parsing parameter type of parameter information;

[0069] Step 1812: Based on the parameter type, perform corresponding interactive operations; wherein the interactive operations include: obtaining parameter information of the internal editing interface of the client through the editing end to achieve interaction, saving parameter information to custom instructions to achieve interaction, and closing the attribute value editing interface to achieve interaction.

[0070] For example, since the type of parameter passed by the interface function is predefined, the client will first determine what parameter type it belongs to and then perform the corresponding interactive operation. The interactive operation may include: entering the client to perform editing operations, saving the attribute information of the attribute value editing interface to the client's custom instructions, or closing the attribute value editing interface displayed on the editing end.

[0071] In one embodiment, step 1812 may specifically include: step 1812a and step 1812b.

[0072] Wherein, step 1812a: if the parameter type is an interactive command for calling the internal editing interface of the client, after opening the internal editing interface of the client from the editing end, set the attribute value in the internal editing interface of the client;

[0073] Step 1812b: Call the callback function corresponding to the interface function, assign the set property value to the callback function, generate parameter information corresponding to the callback function, so that the editing end can receive the parameter information passed by the callback function and display it.

[0074] Exemplarily, the client internal editing interface may be an interface for the client to perform intuitive attribute value setting. The interactive command for calling the client internal editing interface may be interactive interface information generated by entering the client from the attribute value editing interface.

[0075] Taking the robot teaching APP on the client as an example, since the joint coordinates and Cartesian coordinates and other point information of the robot teaching are directly input or edited on the editing end, the point information directly input or edited is too much and the corresponding posture of the point cannot be displayed intuitively. Therefore, after opening the internal editing interface of the client on the editing end, you can enter the manual operation interface inside the APP to teach the robot, call the callback function callback corresponding to the pre-defined interface function, assign the taught point to the callback, and generate the parameter information corresponding to the callback function. Furthermore, if a custom instruction needs to set attributes such as robot point, tool center point or user coordinate system value, the attribute value editing interface can be directly input, or the interface function can be triggered to enter the internal editing interface of the client to directly obtain the robot point, tool center point or user coordinate system value.

[0076] Optionally, if the user needs to enter the client's internal operations, click "Enter", "Confirm", "Teach and other specific internal operations" and other buttons on the attribute value editing interface of the editing end, which will trigger the editing end to call the JAKAController.jakaCall interface function and assign values ​​to the parameters such as the transmission parameter type type, callback function callback, and request related data data according to the design specifications of the interface function. After the client listens to the call of JAKAController.jakaCall, it will determine the parameter type. If it is "type = jakaMoveRobot", it will parse it and then open the client's internal editing interface, that is, the teaching interface at this time, and enter or edit the teaching point information in the teaching interface. After completing the teaching, the client assigns and calls the callback function window.jakaCallBack of JAKAController.jakaCall. The editing end receives the parameter information from window.jakaCallBack and parses it, and displays the teaching point information through the attribute value editing interface, thereby realizing intuitive editing, without the need to manually enter the attribute value such as the point value, reducing the possibility of input errors.

[0077] In one embodiment, step 1812 may further specifically include: step 1812c and step 1812d.

[0078] Wherein, step 1812c: if the parameter type is a save command of the attribute value editing interface, obtain the parameter information passed by the interface function, and save the parameter information into the custom instruction;

[0079] Step 1812d: If the parameter type is a close command of the attribute value editing interface, close the attribute value editing interface displayed on the editing end.

[0080] Among them, for step 1812c: if the parameter type is a save command of the attribute value editing interface, obtain the parameter information passed by the interface function, and save the parameter information into the custom instruction.

[0081] Exemplarily, the save command can be the save information generated by the attribute value editing interface. Specifically, after the attribute value of the custom instruction is modified in the attribute value editing interface, the user clicks the "Save" or "OK" button, which will trigger the editing end to call the JAKAController.jakaCall interface function and assign values ​​to the parameters such as the transmission parameter type type, callback function callback, and request related data data according to the design specifications of the interface function. After the client listens to the call of JAKAController.jakaCall, it will determine the parameter type. If it is "type=saveJakaEditorItem", it means that the attribute value information of the custom instruction needs to be saved, that is, the parameter information passed is stored in the custom instruction and the attribute value editing interface is closed.

[0082] Step 1812d: If the parameter type is a close command of the attribute value editing interface, close the attribute value editing interface displayed on the editing end.

[0083] Exemplarily, the close command can be a close message generated by the attribute value editing interface. Specifically, when the attribute value of the custom instruction is modified in the attribute value editing interface or the original value is not modified, the user clicks the "Close" button to trigger the editing end to call the JAKAController.jakaCall interface function, and assigns parameters such as the transmission parameter type type, callback function callback, and request-related data data according to the design specifications of the interface function. After the client listens to the call of JAKAController.jakaCall, it will determine the parameter type. If it is "type=close", it means that the attribute value editing interface needs to be closed, that is, the operation of closing the attribute value editing interface is executed.

[0084] See also Figure 3 , Figure 3A flowchart of an interactive method based on custom instructions applied to an editing terminal is provided in an embodiment of the present application. The specific process of this embodiment is explained in detail below.

[0085] Step 121: receiving a request initiated by a client through a custom instruction;

[0086] Step 122: Displaying a property value editing interface corresponding to the custom instruction based on the request;

[0087] Step 123: Setting the attribute value in the attribute value editing interface; and

[0088] Step 161: calling the interface function registered by the client, assigning the set attribute value to the interface function, generating parameter information corresponding to the interface function, so that the client receives the parameter information transmitted by the interface function for interaction.

[0089] Exemplarily, after the editing end receives the Get request initiated by the client user by clicking the custom instruction, it waits for the client to load. After successful loading, the editing end displays the attribute value editing interface corresponding to the custom instruction to modify or edit various types of attribute values ​​of the custom instruction.

[0090] Optionally, the attribute values ​​of multiple different attribute types displayed can be set or edited arbitrarily in the attribute value editing interface. After the attribute value modification or editing is completed on the editing end, the interface function registered on the client side for accessing the editing end through the JavaScript method is called, and the attribute value currently displayed on the editing end is assigned to the interface function. The client side monitors the interface function being called, thereby obtaining the parameter information transmitted by the interface function.

[0091] In one embodiment, step 123 may specifically include: step 123a, step 123b, and step 123c.

[0092] Wherein, step 123a: based on the entry information of entering the client internal editing interface from the attribute value editing interface, opening the client internal editing interface to set the attribute value through the client internal editing interface;

[0093] Step 123b: receiving parameter information passed by the callback function corresponding to the interface function;

[0094] Step 123c: Based on the parameter information, generate and display the attribute value of the attribute value editing interface.

[0095] Exemplarily, the entry information may be the entry information generated by the user entering the client's internal editing interface through "clicking", "sliding", "long pressing" and other operations on the editing end. Optionally, the user clicks on the button or link to enter the client's internal editing interface, opens the client's internal editing interface on the editing end, and after the editing operation on the client's internal editing interface is completed and "OK" is clicked, the callback function window.jakaCallBack of the client-side calling interface function is triggered to assign values, for example: the current Cartesian and joint information set by the robot in the client's internal editing interface is used as the parameter of the callback function window.jakaCallBack (default) in JAKAController.jakaCall. Receive and parse the parameter information passed by the callback function to the editing end, and then update and display the current relevant attribute values ​​of the attribute value editing interface.

[0096] Optionally, the attribute value of a custom instruction can not only display one attribute parameter value, but multiple attribute parameter values ​​can also be concatenated into a string through other separators and assigned to one attribute value. For example, the robot position is divided into Cartesian coordinates and joint coordinates. The Cartesian and joint coordinates are concatenated through the "|" separator and assigned to the attribute "robotPos". When the custom instruction request is clicked to open the attribute value editing interface, the attribute value editing interface can display the Cartesian coordinates and joint coordinates together or separately; when entering the client internal editing interface from the attribute value editing interface, the Cartesian coordinates and joint coordinates need to be separately assigned to the two attribute parameters of the data parameter in the interface function: "pose" and "jointpose"; after entering the client internal editing interface, the modified Cartesian coordinates and joint coordinates are respectively assigned to the two attribute parameters of the data parameter in the callback function of the interface function: "pose" and "jointpose", and returned to the editing end. The editing end obtains the parameter information of the callback function of the interface function and displays the Cartesian coordinates and joint coordinates together or separately. When saving the attribute values ​​written in the attribute value editing interface, the Cartesian and joint coordinates need to be concatenated with the "|" separator and returned to the client and saved inside the custom instruction.

[0097] In a preferred embodiment, Figure 4 As shown, Figure 4 This is a flow chart of a preferred interactive method based on custom instructions provided in an embodiment of the present application. The specific process of this embodiment is explained in detail below.

[0098] Exemplarily, the client and the editing end are located in the same application APP platform system, the client is the APP end, and the editing end is a Web page embedded in the custom instruction interface of the APP end.

[0099] First, the user can click on one of the custom instructions that need to set internal properties in the custom instruction interface on the APP side, triggering the APP side to obtain the editing path of the custom instruction to access the Web side, initiate a Get request, and then package the attribute name and attribute value contained in the custom instruction in the Json data format as the transmission parameters of the Get request to the Web side, so as to request to load and display the Web interface that transmits the parameters of the Get request; secondly, after the Web side receives the Get request initiated by the APP user by clicking the custom instruction, it waits for loading. After successful loading, the Web interface where the attribute value of the custom instruction can be edited is displayed on the Web side, and the attribute value displayed on the Web interface can be modified or edited at will; finally, the JavaScript method is used to register the interface function for accessing the Web side on the APP side: JAKAController.jakaCall, as the request entry for the APP side to access the Web side. After successful registration, the APP side will monitor whether the interface function is called by the Web side. When the interface function is called, the parameter information transmitted by the interface function is obtained, the transmitted parameter information is parsed, and further judgment is made on what interactive operation to perform.

[0100] Furthermore, if the user needs to enter the APP to perform specific editing operations, optionally, clicking the "Teach" button on the Web interface of the Web side will trigger the Web side to call the JAKAController.jakaCall interface function. After the APP side listens to the call of JAKAController.jakaCall, it will determine the parameter type. If it is "type=jakaMoveRobot", it will parse and then open the internal editing interface of the APP side, that is, the teaching interface at this time, and enter or edit the teaching point information in the teaching interface. After completing the teaching, the APP side assigns and calls the callback function window.jakaCallBack of JAKAController.jakaCall, and the Web side receives and parses the parameter information from window.jakaCallBack, and displays the point information of the teaching through the Web interface.

[0101] When the internal attribute value of the custom instruction is edited, including editing directly in the Web interface and editing in the internal interface of the APP, the user clicks the "Save" or "OK" button in the Web interface, which will trigger the Web end to call the JAKAController.jakaCall interface function again, and assign corresponding values ​​to the parameters such as the transmission parameter type type, callback function callback, and request related data data according to the point information currently displayed on the Web interface. After the APP end monitors the call of JAKAController.jakaCall, it determines the parameter type. If it is "type = saveJakaEditorItem", the transmitted point information is stored in the custom instruction, and the Web interface can be further closed.

[0102] See also Figure 5 , Figure 5 A functional module diagram of an interactive device based on custom instructions applied to a client provided in an embodiment of the present application. Each module in the interactive device in this embodiment is used to execute each step in the above-mentioned interactive method embodiment based on custom instructions applied to a client. The device includes a request module 210, a registration module 220, a receiving parameter module 230 and an interactive module 240.

[0103] The request module 210 is used to initiate a request to access the editing end based on the trigger information of the custom instruction to load the attribute value editing interface corresponding to the custom instruction;

[0104] A registration module 220, used to register an interface function for monitoring the editing end;

[0105] The parameter receiving module 230 is used to monitor the interface function being called by the editing terminal and obtain the parameter information transmitted by the interface function; and

[0106] The interaction module 240 is used to perform corresponding interaction operations based on the parameter information.

[0107] In a first optional implementation, the interaction module 240 is used to:

[0108] Parameter type of parsed parameter information;

[0109] Based on the parameter type, the corresponding interactive operation is performed; wherein the interactive operation includes: obtaining the parameter information of the internal editing interface of the client through the editing end to realize the interaction, saving the parameter information to the custom instruction to realize the interaction, and closing the attribute value editing interface to realize the interaction.

[0110] In a second optional implementation, the interaction module 240 is used to:

[0111] If the parameter type is an interactive command that calls the client's internal editing interface, after opening the client's internal editing interface from the editing end, set the attribute value in the client's internal editing interface;

[0112] The callback function corresponding to the interface function is called, and the set property value is assigned to the callback function, and the parameter information corresponding to the callback function is generated, so that the editing end can receive the parameter information passed by the callback function and display it.

[0113] In a third optional implementation, the interaction module 240 is used to:

[0114] If the parameter type is a save command of the attribute value editing interface, obtain the parameter information passed by the interface function, and save the parameter information to the custom instruction;

[0115] If the parameter type is a close command for the attribute value editing interface, close the attribute value editing interface displayed on the editing terminal.

[0116] See also Figure 6 , Figure 6 The module function diagram of an interactive device based on custom instructions applied to an editing end provided in an embodiment of the present application is shown in FIG. 2 . Each module in the interactive device in this embodiment is used to execute each step in the above-mentioned interactive method embodiment based on custom instructions applied to an editing end. The device includes a receiving module 250, a display module 260, an editing module 270, and a parameter transfer module 280.

[0117] The receiving module 250 is used to receive a request initiated by a client through a custom instruction;

[0118] A display module 260, configured to display a property value editing interface corresponding to the custom instruction based on the request;

[0119] An editing module 270, configured to set attribute values ​​in the attribute value editing interface; and

[0120] The parameter transfer module 280 is used to call the interface function registered by the client, assign the set property value to the interface function, and generate parameter information corresponding to the interface function, so that the client can receive the parameter information transferred by the interface function for interaction.

[0121] In a fourth optional implementation manner, the editing module 270 is used to:

[0122] Based on the entry information of entering the client internal editing interface from the attribute value editing interface, the client internal editing interface is opened to set the attribute value through the client internal editing interface;

[0123] Receive the parameter information passed by the callback function corresponding to the interface function;

[0124] Based on the parameter information, the attribute value of the attribute value editing interface is generated and displayed.

[0125] See also Figure 7 , Figure 7 31 is a block diagram of an electronic device. The electronic device 300 may include a memory 311, a storage controller 312, a processor 313, a peripheral interface 314, an input and output unit 315, and a display unit 316. A person skilled in the art may understand that Figure 7 The structure shown is for illustration only and does not limit the structure of the electronic device 300. For example, the electronic device 300 may further include Figure 7 More or fewer components as shown, or with Figure 7 Different configurations shown.

[0126] The above-mentioned memory 311, storage controller 312, processor 313, peripheral interface 314, input / output unit 315, and display unit 316 are electrically connected to each other directly or indirectly to achieve data transmission or interaction. For example, these components can be electrically connected to each other through one or more communication buses or signal lines. The above-mentioned processor 313 is used to execute the executable module stored in the memory.

[0127] The memory 311 may be, but is not limited to, a random access memory (RAM), a read only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable read-only memory (EEPROM), etc. The memory 311 is used to store programs, and the processor 313 executes the program after receiving the execution instruction. The method executed by the electronic device 300 defined by the process disclosed in any embodiment of the present application can be applied to the processor 313, or implemented by the processor 313.

[0128] The processor 313 may be an integrated circuit chip with signal processing capability. The processor 313 may be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it may also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present application may be implemented or executed. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.

[0129] The above-mentioned peripheral interface 314 couples various input / output devices to the processor 313 and the memory 311. In some embodiments, the peripheral interface 314, the processor 313 and the memory controller 312 can be implemented in a single chip. In some other examples, they can be implemented by separate chips.

[0130] The input and output unit 315 is used to provide input data to the user. The input and output unit 315 can be, but is not limited to, a mouse and a keyboard.

[0131] The display unit 316 provides an interactive interface (e.g., a user operation interface) between the electronic device 300 and the user for the user to refer to. In this embodiment, the display unit 316 may be a liquid crystal display or a touch display. The liquid crystal display or the touch display may display the process of the processor executing the program.

[0132] The electronic device 300 in this embodiment can be used to execute each step in each method provided in the embodiments of the present application.

[0133] In addition, an embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above method embodiment are executed.

[0134] The computer program product of the above method provided in the embodiment of the present application includes a computer-readable storage medium storing program code, and the instructions included in the program code can be used to execute the steps in the above method embodiment. For details, please refer to the above method embodiment, which will not be repeated here.

[0135] To sum up: An embodiment of the present application provides an interactive method based on custom instructions, which is applied to a client, and the method includes: based on the trigger information of the custom instruction, initiating a request to access the editing end to load the attribute value editing interface corresponding to the custom instruction; registering an interface function for monitoring the editing end; after monitoring the interface function being called by the editing end, obtaining parameter information passed by the interface function; and performing corresponding interactive operations based on the parameter information.

[0136] In the above implementation process, the attribute value editing interface is loaded through the trigger information request of the custom instruction. When the attribute value editing interface is loaded successfully, the interface function of the editing end is registered on the client. The interface function is equivalent to the communication interface between the two ends. When the editing end is monitored to be called, the parameter information passed back from the editing end by the interface function is obtained, and the corresponding interaction logic is executed according to the parameter information, so that the attribute value editing and setting can be realized from the editing end attribute value editing interface to the client, thereby improving the fault tolerance rate and development efficiency.

[0137] In the embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are merely schematic. For example, the division of the modules is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some communication interfaces, devices or units, which can be electrical, mechanical or other forms. The functional modules in the embodiments of the present application can be integrated together to form an independent part, or each module can exist separately, or two or more modules can be integrated to form an independent part.

[0138] It should be noted that if the function is implemented in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application can essentially be embodied in the form of a software product, or the part that contributes to the prior art or the part of the technical solution. The computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM) random access memory (RAM), disk or optical disk, and other media that can store program codes.

[0139] In this document, relational terms such as first and second, etc. are used merely to distinguish one entity or operation from another entity or operation, but do not necessarily require or imply any such actual relationship or order between these entities or operations.

[0140] The above description is only an embodiment of the present application and is not intended to limit the protection scope of the present application. For those skilled in the art, the present application may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims

1. An interactive method based on custom instructions, It is characterized in that Applied to a client, the method comprises: Based on the trigger information of the custom instruction, a request to access the editing end is initiated to load the attribute value editing interface corresponding to the custom instruction; wherein the attribute value editing interface includes a Web page or a Webview control written by the user himself; the custom instruction is a graphic programming instruction independently developed by the user on the client, and the user on the client can add the custom instruction, enter a unique name for the custom instruction, select the instruction type, and add the correct URL editing path and the correct URL script path for the custom instruction; Register the interface function for monitoring the editing end; After monitoring that the interface function is called by the editing terminal, obtaining parameter information passed by the interface function; and Perform corresponding interactive operations based on the parameter information; The performing of the corresponding interactive operation based on the parameter information includes: parsing the parameter type of the parameter information; and performing the corresponding interactive operation based on the parameter type; wherein the interactive operation includes: obtaining the parameter information of the internal editing interface of the client through the editing end to achieve interaction, saving the parameter information to the custom instruction to achieve interaction, and closing the attribute value editing interface to achieve interaction; Among them, the method of obtaining parameter information of the internal editing interface of the client through the editing end to achieve interaction includes: if the parameter type is an interactive command for calling the internal editing interface of the client, then after opening the internal editing interface of the client from the editing end, setting the attribute value in the internal editing interface of the client; calling the callback function corresponding to the interface function, and assigning the set attribute value to the callback function, generating parameter information corresponding to the callback function, so that the editing end can receive the parameter information passed by the callback function and display it.

2. The method according to claim 1, It is characterized in that The step of saving the parameter information to the custom instruction to realize the interaction, and closing the attribute value editing interface to realize the interaction, includes: If the parameter type is a save command of the attribute value editing interface, obtain the parameter information passed by the interface function, and save the parameter information into the custom instruction; If the parameter type is a closing command of the attribute value editing interface, the attribute value editing interface displayed on the editing terminal is closed.

3. An interactive method based on custom instructions, It is characterized in that Applied to the editing end, the method includes: Receive requests initiated by the client through custom instructions; Based on the request, the attribute value editing interface corresponding to the custom instruction is displayed; wherein the attribute value editing interface includes a Web page or a Webview control written by the user; the custom instruction is a graphic programming instruction independently developed by the user on the client, and the user can add the custom instruction on the client, enter a unique name for the custom instruction, select the instruction type, and add a correct URL editing path and a correct URL script path for the custom instruction; Setting the attribute value in the attribute value editing interface; and Call the interface function registered by the client, assign the set attribute value to the interface function, generate parameter information corresponding to the interface function, so that the client receives the parameter information transmitted by the interface function for interaction; Among them, the setting of attribute values ​​in the attribute value editing interface includes: based on the entry information of entering the client internal editing interface from the attribute value editing interface, opening the client internal editing interface to set the attribute value through the client internal editing interface; receiving parameter information passed by the callback function corresponding to the interface function; based on the parameter information, generating and displaying the attribute value of the attribute value editing interface.

4. An interactive device based on custom instructions, It is characterized in that Applied to a client, the device comprises: A request module is used to initiate a request to access the editing end based on the trigger information of the custom instruction, so as to load the attribute value editing interface corresponding to the custom instruction; wherein the attribute value editing interface includes a Web page or a Webview control written by the user himself; the custom instruction is a graphic programming instruction independently developed by the user on the client, and the user on the client can add the custom instruction, enter a unique name for the custom instruction, select the instruction type, and add a correct URL editing path and a correct URL script path for the custom instruction; Registration module, used to register the interface function for monitoring the editing end; A parameter receiving module, configured to obtain parameter information transmitted by the interface function after monitoring that the interface function is called by the editing terminal; and An interaction module, used for performing corresponding interaction operations based on the parameter information; The interaction module is specifically used to: parse the parameter type of the parameter information; based on the parameter type, perform corresponding interaction operations; wherein the interaction operations include: obtaining the parameter information of the internal editing interface of the client through the editing end to achieve interaction, saving the parameter information to the custom instruction to achieve interaction, and closing the attribute value editing interface to achieve interaction; Among them, the method of obtaining parameter information of the internal editing interface of the client through the editing end to achieve interaction includes: if the parameter type is an interactive command for calling the internal editing interface of the client, then after opening the internal editing interface of the client from the editing end, setting the attribute value in the internal editing interface of the client; calling the callback function corresponding to the interface function, and assigning the set attribute value to the callback function, generating parameter information corresponding to the callback function, so that the editing end can receive the parameter information passed by the callback function and display it.

5. An interactive device based on custom instructions, It is characterized in that Applied to the editing end, the device comprises: The receiving module is used to receive requests initiated by the client through custom instructions; A display module is used to display the attribute value editing interface corresponding to the custom instruction based on the request; wherein the attribute value editing interface includes a Web page or a Webview control written by the user; the custom instruction is a graphic programming instruction independently developed by the user on the client, and the user can add the custom instruction on the client, enter a unique name for the custom instruction, select the instruction type, and add a correct URL editing path and a correct URL script path for the custom instruction; An editing module, used for setting attribute values ​​in the attribute value editing interface; and The parameter transfer module is used to call the interface function registered by the client, assign the set attribute value to the interface function, and generate parameter information corresponding to the interface function, so that the client can receive the parameter information transferred by the interface function for interaction; Among them, the editing module is specifically used to: open the client internal editing interface based on the entry information from the attribute value editing interface to the client internal editing interface, so as to set the attribute value through the client internal editing interface; receive parameter information passed by the callback function corresponding to the interface function; based on the parameter information, generate the attribute value of the attribute value editing interface and display it.

6. An interactive method based on custom instructions, It is characterized in that The interactive method based on custom instructions is applied to a system including a client and an editing end, wherein the client is in communication connection with the editing end; The client, based on the trigger information of the custom instruction, initiates a request to access the editing end to load the attribute value editing interface corresponding to the custom instruction; wherein the attribute value editing interface includes a Web page or a Webview control written by the user himself; the custom instruction is a graphic programming instruction independently developed by the user on the client, and the user on the client can add the custom instruction, enter a unique name for the custom instruction, select the instruction type, and add a correct URL editing path and a correct URL script path for the custom instruction; The editing end receives a request initiated by the client through a custom instruction, displays a property value editing interface corresponding to the custom instruction based on the request, and sets the property value in the property value editing interface; The client registers an interface function for monitoring the editing end, and after monitoring that the interface function is called by the editing end, obtains parameter information transmitted by the interface function; The editing end calls the interface function registered by the client, and assigns the set attribute value to the interface function, generating parameter information corresponding to the interface function; and The client performs corresponding interactive operations based on the parameter information; The performing of the corresponding interactive operation based on the parameter information includes: parsing the parameter type of the parameter information; and performing the corresponding interactive operation based on the parameter type; wherein the interactive operation includes: obtaining the parameter information of the internal editing interface of the client through the editing end to achieve interaction, saving the parameter information to the custom instruction to achieve interaction, and closing the attribute value editing interface to achieve interaction; Among them, the method of obtaining parameter information of the internal editing interface of the client through the editing end to achieve interaction includes: if the parameter type is an interactive command for calling the internal editing interface of the client, then after opening the internal editing interface of the client from the editing end, setting the attribute value in the internal editing interface of the client; calling the callback function corresponding to the interface function, and assigning the set attribute value to the callback function, generating parameter information corresponding to the callback function, so that the editing end can receive the parameter information passed by the callback function and display it.

7. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 3 are executed.

Citation Information

Patent Citations

  • Interaction method and device for user interface presentation, equipment and storage medium

    CN110275754A

  • Data interaction method and device, electronic equipment and storage medium

    CN110691136A

  • Command library creation method and device for RPA process generation end, medium and equipment

    CN111722840A

  • Robot interaction method, system and device, electronic device and storage medium

    CN113254006A

  • User Customization Method and System

    US20130104102A1