Action association method, electronic device and storage medium based on Internet of Things
By judging the feedback results and execution effects of actions in the Internet of Things system, and associating actions with the same functions, the problem of lack of logical relationships between actions in the prior art is solved, and the robustness and intelligence level of the system are improved.
Patent Information
- Application Number
- CN202010339968.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-04-26
- Publication Date
- 2024-11-15
- Estimated Expiration
- 2040-04-26
AI Technical Summary
The lack of logical relationships between actions in the prior art leads to poor robustness and insensible enough to achieve the desired action effect by triggering actions with similar functions.
By judging whether the feedback results of the first action and the second action and the execution effect are the same or similar, if the same, they are related to ensure that there is a logical relationship between the actions with the same functions, so that the first action fails to execute or the effect is poor When the same effect is achieved by triggering the second action.
Improve the robustness and intelligence of the system to ensure the reliability and effectiveness of action execution.
Smart Images

Figure CN113552938B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of Internet of Things, and in particular to an action association method, electronic equipment and storage medium based on the Internet of Things. Background Art
[0002] Action triggering is a public service function provided by the service platform. Business logic can be implemented on the platform without the need for application programs to check the links, thereby reducing message transmission and improving efficiency and intelligence. After deploying the service to the service platform, the application can safely enter sleep or roam.
[0003] However, in the prior art, since there is no logical relationship between actions, when an action is implemented, if the execution effect of the action is poor or cannot be executed, it is impossible to achieve the desired action effect by triggering an action with similar functions, resulting in poor robustness and lack of intelligence of the system. Summary of the invention
[0004] In view of this, the purpose of the present invention is to propose an action association method, electronic device and storage medium based on the Internet of Things to solve the problems of poor robustness and lack of intelligence.
[0005] According to a first aspect of an embodiment of the present invention, there is provided an action association method based on the Internet of Things, comprising:
[0006] Triggering the first device to execute a first action and the second device to execute a second action respectively, and obtaining a feedback result of the first action and a feedback result of the second action; wherein the feedback result includes at least one of an execution result and an execution effect;
[0007] Based on the feedback result of the first action and the feedback result of the second action, it is determined whether the first action and the second action can be associated; if so, the first action is associated with the second action.
[0008] In some embodiments of the present invention, judging whether the first action and the second action can be associated based on the feedback result of the first action and the feedback result of the second action; if so, associating the first action with the second action includes:
[0009] Determining whether the execution result of the first action is the same as the execution result of the second action;
[0010] If so, associating the first action with the second action;
[0011] If not, obtain the execution effect of the first action and the execution effect of the second action, and determine whether the execution effect of the first action and the execution effect of the second action are the same; if so, associate the first action with the second action.
[0012] In some embodiments of the present invention, obtaining the execution effect of the first action and the execution effect of the second action includes:
[0013] According to a pre-configured collection interval and collection method, respectively obtaining the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action;
[0014] The execution effect of the first action and the execution effect of the second action are calculated according to the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action.
[0015] In some embodiments of the present invention, calculating the execution effect of the first action and the execution effect of the second action according to the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action includes:
[0016] Calculate result data corresponding to the first action and result data corresponding to the second action respectively according to the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action;
[0017] It is respectively determined whether the result data corresponding to the first action and the result data corresponding to the second action meet the pre-configured action conditions, thereby obtaining the execution effect of the first action and the execution effect of the second action.
[0018] In some embodiments of the present invention, associating the first action with the second action includes:
[0019] According to the pre-configured association condition of the first action, determining whether the second action meets the association condition;
[0020] If so, the first action is associated with the second action.
[0021] In some embodiments of the present invention, the association condition includes at least one of device location, device type, operation time and operation priority.
[0022] In some embodiments of the present invention, associating the first action with the second action includes:
[0023] The first action is associated with the second action based on a preconfigured associating action mode of the first action and the second action.
[0024] In some embodiments of the present invention, the associated action mode includes one of sequential execution, simultaneous execution and abnormal execution.
[0025] According to a second aspect of an embodiment of the present invention, there is provided an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method described in any one of the above embodiments when executing the program, and the memory is used to store data, wherein the data comprises at least one of a collection interval, a collection method, an execution result, an execution effect, result data, an action condition, an associated condition, and an associated action method.
[0026] According to a third aspect of an embodiment of the present invention, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable the computer to execute the method described in any of the above embodiments.
[0027] From the above description, it can be seen that the embodiment of the present invention determines whether the first action and the second action have the same function by determining whether the feedback result of the first action and the feedback result of the second action are the same or similar, so that there is a logical relationship between the actions with the same function. Then, when the first device fails to execute the first action or the execution effect is poor, the second action can be executed by triggering the second device, thereby achieving the same effect as the first action, thereby improving the robustness and intelligence level of the system. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0029] Figure 1 A schematic diagram of a process for triggering actions on a service platform in the prior art;
[0030] Figure 2 It is a flowchart of an action association method based on the Internet of Things according to an embodiment of the present invention;
[0031] Figure 3 A schematic diagram of the action triggering process of a smart camera and a smart cat's eye in a home security scenario according to an embodiment of the present invention;
[0032] Figure 4It is a schematic diagram of the action triggering and association process of the smart camera and the smart cat eye in the home security scenario according to an embodiment of the present invention;
[0033] Figure 5 This is a schematic diagram of the action triggering process of the ventilator and the window in the smart home scene according to an embodiment of the present invention;
[0034] Figure 6 A schematic diagram of the action triggering and association process of a ventilator and a window in a smart home scenario according to an embodiment of the present invention;
[0035] Figure 7 For the embodiment of the present invention <resultmode>Schematic diagram of the structure of the attribute;
[0036] Figure 8 A schematic diagram of a process of performing a Retrieve operation according to an embodiment of the present invention;
[0037] Fig. 9 A schematic diagram of the action triggering process of multiple air conditioners in a smart home scenario according to an embodiment of the present invention;
[0038] Fig.10 A schematic diagram of the action triggering and association process of multiple air conditioners in a smart home scenario according to an embodiment of the present invention;
[0039] Fig.11 A schematic diagram of a flow chart for triggering the simultaneous execution of multiple actions according to an embodiment of the present invention;
[0040] Fig.12 A schematic diagram of a process for triggering abnormal execution of multiple actions according to an embodiment of the present invention;
[0041] Fig.13 Schematic diagram of the internal structure of an electronic device in an embodiment of the present invention. DETAILED DESCRIPTION
[0042] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with specific embodiments and with reference to the accompanying drawings.
[0043] It should be noted that, unless otherwise defined, the technical terms or scientific terms used in the embodiments of the present invention should be understood by people with ordinary skills in the field to which the present disclosure belongs. "First", "second" and similar words used in the present disclosure do not represent any order, quantity or importance, but are only used to distinguish different components. "Including" or "comprising" and similar words mean that the elements or objects appearing before the word cover the elements or objects listed after the word and their equivalents, without excluding other elements or objects. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. "Up", "down", "left", "right" and the like are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.
[0044] The process of creating an action mainly includes: the application initiates a request to the service platform and creates action-related resources on the service platform; the resources need to include the action detection object, action triggering conditions, action execution content, action execution results, etc. After the service platform completes the action creation, the service platform will trigger the action, such as Figure 1 As shown, the action detection object is monitored to determine whether the action triggering condition is met; if met, the action is triggered and a corresponding instruction is sent to the action operation object so that the action operation object performs the action; the action execution result is obtained and recorded through the action result object.
[0045] In the prior art, the association between actions is that after a condition triggers a certain action, other devices are also linked to operate. For example, when a smoke sensor triggers an alarm message on a mobile phone, it can also be associated with an alarm buzzer and a flashing warning light. This action can be combined into one trigger condition in the action trigger mechanism to execute multiple actions, but there is no logical relationship between multiple actions with different trigger conditions. In actual application scenarios, there are multiple actions that may have similar functions. When the action is implemented, if the effect of the action is poor, the desired execution effect cannot be achieved by triggering actions with similar functions.
[0046] The Internet of Things-based action association method provided in the embodiment of the present invention associates actions with the same execution effect or execution result, and can start the associated second action when the execution of the first action fails or the execution effect is poor due to other circumstances, thereby ensuring the execution effect of the action and improving the robustness and intelligence level of the system.
[0047] In one embodiment of the present invention, Figure 2 As shown, an embodiment of the present invention provides an action association method based on the Internet of Things, which is applied to a service platform and may include the following steps:
[0048] Step 201, triggering the first device to execute a first action and the second device to execute a second action respectively, and obtaining a feedback result of the first action and a feedback result of the second action.
[0049] After the application creates the first action and the second action respectively on the service platform, the service platform triggers the first device to execute the first action and the second device to execute the second action respectively, thereby obtaining the feedback result of the first action and the feedback result of the second action. The service platform can trigger the first device to execute the first action and the second device to execute the second action at the same time, or can trigger them in sequence, which is not limited in the embodiment of the present invention.
[0050] After the service platform triggers the device to perform the corresponding action, it can receive the corresponding feedback result. In the embodiment of the present invention, the feedback result may include at least one of the execution result and the execution effect. The execution result may be the instantaneous state of the action result object such as collecting images, opening doors or alarming, and the execution effect may be the state change of the duration of the action result object such as lowering the indoor temperature, raising the indoor temperature or lowering the indoor CO concentration.
[0051] Step 202: Based on the feedback result of the first action and the feedback result of the second action, determine whether the first action and the second action can be associated; if so, associate the first action with the second action.
[0052] The service platform determines whether the feedback results of the first action and the feedback results of the second action obtained in step 201 are the same or similar, thereby determining whether the first action and the second action can be associated; if the feedback results are the same, it is determined that the first action and the second action can be associated, otherwise, it is determined that the first action and the second action cannot be associated.
[0053] The embodiment of the present invention determines whether the first action and the second action have the same function by determining whether the feedback result of the first action is the same or similar to the feedback result of the second action, so that there is a logical relationship between the actions with the same function. Then, when the first device fails to execute the first action or the execution effect is poor, the second action can be executed by triggering the second device, thereby achieving the same effect as the first action, thereby improving the robustness and intelligence level of the system.
[0054] Optionally, step 202 may include: determining whether the execution result of the first action is the same as the execution result of the second action; if so, associating the first action with the second action; if not, obtaining the execution effect of the first action and the execution effect of the second action, and determining whether the execution effect of the first action is the same as the execution effect of the second action; if so, associating the first action with the second action. In an embodiment of the present invention, if it can be directly determined that the first action and the second action have the same function according to the execution result, the two are associated (for example, the execution results of the smart cat's eye and the camera are both to collect images, and the two have the same functions, so the two can be associated); if not, further obtaining the execution effects of the two actions, and determining whether they have the same function according to the execution effects, and if so, associating. For example: the execution results of the action of turning on the ventilation fan and the action of opening the window are the ventilation fan turning on and the window opening, respectively. The execution results between the two are different, so it is necessary to further obtain the execution effects of the two. The execution effects of the two actions are both a decrease in CO concentration, indicating that the two have the same functions and can be associated.
[0055] Optionally, obtaining the execution effect of the first action and the execution effect of the second action includes: obtaining the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action respectively according to a pre-configured collection interval and collection method (which can be divided into one-time collection and periodic collection); calculating the execution effect of the first action and the execution effect of the second action according to the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action. According to the pre-configured collection interval and collection method, the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action are continuously collected, and each execution result in the execution result set of the action result object corresponding to the first action and each execution result in the execution result set of the action result object corresponding to the second action are calculated, so as to obtain the execution effect of the first action and the execution effect of the second action. For example, if the CO sensor data is continuously collected, it is found through calculation that the execution effects of the two actions are both that the CO concentration is decreasing, indicating that the two have the same functions.
[0056] Optionally, the execution effect of the first action and the execution effect of the second action are calculated according to the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action, including: calculating the result data corresponding to the first action and the result data corresponding to the second action respectively according to the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action; and judging whether the result data corresponding to the first action and the result data corresponding to the second action meet the pre-configured action conditions respectively, so as to obtain the execution effect of the first action and the execution effect of the second action. For example, the pre-configured action condition may be: the indoor temperature drops below 20°C within 5 minutes or the indoor temperature decrease rate is greater than or equal to 5°C / minute, or the temperature drops below 23°C. If the execution result of the action meets the pre-configured action condition, the execution effect of the action is valid, otherwise it is invalid. If the execution effects of both actions are valid, it means that the two actions have the same function and can be associated.
[0057] Optionally, associating the first action with the second action includes: judging whether the second action meets the association condition according to the pre-configured association condition of the first action; if so, associating the first action with the second action. In an embodiment of the present invention, the association result can be optimized by adding association conditions, and the association of some actions can be restricted. For example: the intercommunication between the air conditioner in the bedroom on the first floor and the air conditioner in the bedroom on the second floor is poor, and restrictions are imposed based on the device location, and the actions triggered by the two cannot be associated. Optionally, the association condition includes at least one of device location, device type, operation time and operation priority.
[0058] Optionally, associating the first action with the second action includes: associating the first action with the second action based on a pre-configured associating action mode of the first action and the second action. In order to control the execution of the two actions, the associating action mode can be configured so that the two actions are executed in one of the modes. Optionally, the associating action mode includes one of sequential execution, simultaneous execution and abnormal execution. Optionally, if it is abnormal execution, there is further configuration of abnormal conditions (for example: no action response is received within a period of time, or the execution effect does not reach the expected value within a period of time).
[0059] In order to implement the above-mentioned embodiments of the present invention, the standard of oneM2M (Internet of Things standard) may be modified: <action>Add the actionEffect attribute in the action, which can represent the execution effect of the action. By judging the content of this attribute, the execution purpose of the action can be identified, and actions with the same actionEffect can be associated. After the actions are associated, the triggering of the action can be controlled according to different execution strategies.
[0060] Optionally, in <action>The following properties are added:
[0061] Output resource identification code (outputResourceID): the resource identification code for storing the execution result.
[0062] Execution result (actionResult): stores the execution result corresponding to the action and the execution result of the action result object.
[0063] ActionRelationEnable: Determines whether an action can be associated with other action control buttons.
[0064] ActionEffect: This property can be calculated using different strategies.
[0065] Related action identifier (relatedActionID): The resource identifier of the action related to this action.
[0066] ActionRelationCriteria: This attribute indicates the criteria by which an action can be related to the action, which may include device location, device type, action time, and action priority.
[0067] RelatedActionsRelationship: This attribute indicates how related actions are executed when the action is triggered. It can be sequential execution, simultaneous execution, and abnormal execution.
[0068] Result Mode (resultMode): The storage mode of the action result includes retrieval mode (Retrieve Mode) and duration (duration). According to different result modes, the execution result (actionResult) can store a series of results of the action.
[0069] As another embodiment of the present invention, Figure 3 As shown in the figure, in the home security scenario, there are two devices, smart camera and smart cat eye, and the following actions:
[0070] First action: The infrared sensor detects whether there is a moving object. If a moving object is detected, the camera is triggered to record.
[0071] Second action: If someone is detected pressing the doorbell, the smart cat's eye will be triggered to capture the image.
[0072] In this scenario, since the triggering conditions of the two actions are completely different, the execution results of the actions are both to store the multimedia image data of the target resource at the current moment. <actioneffect>Should be executed through the results <actionresult>Determine that, since the execution results are the same, the execution effects are also the same, so the first action and the second action can be associated. After the first action and the second action are associated, when one of the actions has a problem, the other action is triggered.
[0073] The action triggering and association process in this scenario is as follows Figure 4 As shown, it mainly includes the following steps:
[0074] The security management application, infrared sensor, smart camera, smart cat eye, and doorbell initiate registration requests to the security management server respectively. After registration is completed, the security management application creates actions for the smart cameras on the security management server respectively. <action1>And the action of smart cat's eye <action2>.
[0075] The security management server initiates a subscription request to the doorbell, and the doorbell creates a subscription resource. When someone presses the doorbell, the doorbell sends a notification request to the security management server, which returns a notification response and sends an action request to the smart cat's eye to trigger the smart cat's eye to capture and store images. Subsequently, the smart cat's eye returns an action response to the security management server, and the security management server obtains the action of the smart cat's eye. <action2>The execution result <actionresult>.
[0076] The infrared sensor detects in real time whether there are any moving objects and sends the execution results to the security management server. When a moving object is detected, the security management server sends an action request to the smart camera to trigger the smart camera to capture and store images. Subsequently, the smart camera returns an action response to the security management server, and the security management server obtains the action of the smart camera. <action1>The execution result <actionresult>.
[0077] Security management servers are based on <action1>of <actionresult> 、 <action2>of <actionresult>calculate <action1>of <actioneffect> 、 <action2>of <actioneffect>, and judge <action1>and <action2>of <actioneffect>Are they the same? If they are the same, <action1>and <action2>association.
[0078] After the action association is completed, the infrared sensor still detects whether there are active objects in real time and sends the execution results to the security management server. When an active object is detected, the security management server sends an action request to the smart camera to trigger the smart camera to capture and store images. If the security management server does not receive an action response from the smart camera within a period of time or the received action response is a response failure, it means that the action of the smart camera has failed. <action1>If the execution fails, the security management server sends an action request to the smart cat's eye to trigger the smart cat's eye to capture and store images.
[0079] Correspondingly, when someone presses the doorbell, the doorbell sends a notification request to the security management server, and the security management server returns a notification response and sends an action request to the smart cat's eye to trigger the smart cat's eye to capture and store images. If the security management server does not receive an action response from the smart cat's eye within a period of time or the received action response is a response failure, it means that the action of the smart cat's eye has failed. <action2>If the execution fails, the security management server sends an action request to the smart camera to trigger the smart camera to capture and store images.
[0080] As another embodiment of the present invention, Figure 5 As shown, in the smart home scenario, there are two devices, a ventilator and a window, and the following actions:
[0081] First action: The CO concentration sensor detects whether the CO concentration is higher than threshold A. If so, the ventilation fan is triggered to turn on;
[0082] Second action: The CO concentration sensor detects whether the CO concentration is higher than threshold B. If so, it triggers the window to open.
[0083] In this scenario, when actions allow action association, the server can calculate the execution effect of the action by judging the triggering condition and execution result of the action. If the execution effects are the same, the two actions are associated.
[0084] <action1>In <outputresource>The attribute can be a CO concentration sensor, indicating that the action targets the CO concentration in the space. <actionresult>By comparing the CO concentration stored in the trigger condition with the threshold value, it can be known that the purpose of this action is to reduce the CO concentration in the space, thereby obtaining <action1>of <actioneffect>Similarly, we can obtain <action2>of <actioneffect>It is also to reduce the CO concentration in the space.
[0085] Therefore, the judgment of these two actions <actioneffect>Similarly, you can <action1>and <action2>Make an association. <action1>and <action2>After association, when <action1>If there is a problem with the execution, <action2>Trigger.
[0086] The action triggering and association process in this scenario is as follows Figure 6 As shown, it mainly includes the following steps:
[0087] The security management application, CO concentration sensor, ventilation fan, and window each initiate a registration request to the security management server. After registration is completed, the security management application creates an action for the ventilation fan on the security management server. <action1>and window actions <action2>.
[0088] The CO concentration sensor detects the indoor CO concentration in real time and sends the execution result to the security management server. When the indoor CO concentration is greater than the threshold A, the security management server sends an action request to the ventilation fan to trigger the ventilation fan to turn on. The CO concentration sensor continues to detect the indoor CO concentration and stores the execution result in <action1>of <actionresult>When the indoor CO concentration is greater than threshold B, the security management server sends an action request to the window to trigger the window to open. The CO concentration sensor continues to detect the indoor CO concentration and stores the execution result in <action2>of <actionresult>.
[0089] Security management servers are based on <action1>of <actionResult、 <action2>of <actionresult>calculate <action1>of <actioneffect> 、 <action2>of <actioneffect>, and judge <action1>and <action2>of <actioneffect>Are they the same? If they are the same, modify them. <action1>and <action2>of <relatedactionid>, so that the two actions are related to each other. In this embodiment, <action1>and <action2>of <actioneffect>Both are to reduce the CO concentration in the space, so it can be <action1>and <action2>association.
[0090] After the action association is completed, the CO concentration sensor still detects the indoor CO concentration in real time and sends the execution result to the security management server. When the indoor CO concentration is greater than the threshold A, the security management server sends an action request to the ventilation fan to trigger the ventilation fan to turn on. If the security management server does not receive an action response from the ventilation fan within a period of time or the received action response is a response failure, it means that the action of the ventilation fan has failed. <action1>If the execution fails, the security management server sends an action request to the window to trigger the window to open.
[0091] Accordingly, when the indoor CO concentration is greater than the threshold value B, the security management server sends an action request to the window to trigger the window to open. If the security management server does not receive an action response from the window within a period of time or the received action response is a response failure, it means that the window action has failed. <action1>If the execution fails, the security management server sends an action request to the ventilation fan to trigger the ventilation fan to turn on.
[0092] In the process of implementing the present invention, it can be found that the execution result of the action cannot be perfectly represented at the moment of execution, and the execution result under the current action trigger mechanism <actionresult>It can only represent the action result content at the time of action triggering, but cannot show the subsequent changes of the action result, which has a great impact on the execution effect. <actioneffect>The calculation of <action>Optionally, in <action>Add attributes <resultmode>This property can determine the mode of the retrieve operation and thus the execution result. <actionresult>The different contents of the action results are stored in Figure 7 shown.
[0093] When Retrieve Mode is set to once (which can be represented by "0"), only one retrieval operation is performed, and the interval between retrieval operations is determined by the <duration>OK, store the result of the retrieve operation in <actionresult>middle.
[0094] When Retrieve Mode is set to periodic (indicated by "1"), multiple retrieve operations are performed periodically. The time interval for performing the retrieve operations is determined by <duration>OK, store all the results of the retrieve operation in <actionresult>middle.
[0095] It is important to note that duration should be a non-zero value. When duration is 0, the resultMode selection operation is not performed.
[0096] In this scenario, for Figure 5 In <action1>In <actionresult>Execution process such as Figure 8 As shown, it mainly includes the following steps:
[0097] The security management application, CO concentration sensor, and ventilation fan each initiate a registration request to the security management server. After registration is completed, the security management application creates an action for the ventilation fan on the security management server. <action>.
[0098] The CO concentration sensor detects the indoor CO concentration in real time and sends the execution result to the security management server. When the indoor CO concentration is greater than the threshold A, the security management server sends an action request to the ventilation fan to trigger the ventilation fan to turn on.
[0099] The security management server sends a Retrieve request to the CO concentration sensor, and the CO concentration sensor returns a Retrieve response (carrying the CO concentration) to the security management server. The security management server stores the obtained CO concentration in <actionresult>Next, the security management server determines whether the Retrieve Mode in resultMode is once or periodic. If the Retrieve Mode is once, then after a preset time interval <duration>After that, only one retrieve operation is performed, and the operation result (i.e. CO concentration) is stored in <actionresult>If Retrieve Mode is periodic, the <duration>After that, the retrieve operation is performed periodically, and the result of each operation (i.e., CO concentration) is stored in <actionresult>middle.
[0100] In the smart home environment, multiple actions can be created, such as Fig. 9 As shown, taking four actions as an example, different sensors are used to detect the temperature in different spaces, thereby triggering the corresponding air conditioners to turn on, which is similar to the previous text and will not be repeated here.
[0101] The action triggering and association process in this scenario is as follows Fig.10 As shown in the figure, in this embodiment, it can be seen that the trigger temperature thresholds of the above four actions (32℃, 28℃, 28℃ and 30℃) are all higher than the set temperature (25℃). Since the four attributes are all temperature, and after numerical comparison, it can be seen that the above four actions can achieve the function of lowering the temperature, so the execution effects of these four actions are the same. However, due to the poor intercommunication between the first floor and the second floor, associating all four actions may result in poor association effects. In this case, the association condition can be used to <actionrelationcriteria>Limit the association of some actions to optimize the association results. <action1>and <action2>Associate <action3>and <action4>association.
[0102] After the actions are associated, in order to control the execution of the two actions, you can set the associated action mode <relatedactionsrelationship>It can realize the execution of actions simultaneously or sequentially, or execute the associated actions when the first action is abnormal. When it is set to execute simultaneously, the execution process after the actions are associated is as follows Fig.11 As shown; when it is set to execute the associated action when the first action is abnormal, the execution process after the action is associated is as follows Fig.12 shown.
[0103] like Fig.11 As shown, if the associated action mode of the action is to execute simultaneously, the first action and the second action are triggered at the same time; Fig.12 As shown, if the associated action mode of an action is abnormal execution, the second action will be triggered only when the first action fails to execute.
[0104] It should be noted that the method of the embodiment of the present invention can be performed by a single device, such as a computer or a server. The method of this embodiment can also be applied in a distributed scenario and completed by multiple devices cooperating with each other. In the case of such a distributed scenario, one of the multiple devices can only perform one or more steps in the method of the embodiment of the present invention, and the multiple devices will interact with each other to complete the described method.
[0105] Fig.13 A more specific schematic diagram of the hardware structure of an electronic device provided in this embodiment is shown, and the device may include: a processor 1310, a memory 1320, an input / output interface 1330, a communication interface 1340, and a bus 1350. The processor 1310, the memory 1320, the input / output interface 1330, and the communication interface 1340 are connected to each other through the bus 1350 in the device.
[0106] The processor 1310 can be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this specification. When the processor 1301 executes the program, the method described in any of the above embodiments is implemented.
[0107] In some embodiments of the present invention, the processor 1301 can load and execute: triggering the first device to execute a first action and the second device to execute a second action, respectively, to obtain feedback results of the first action and feedback results of the second action; wherein the feedback results include at least one of execution results and execution effects; based on the execution feedback results of the first action and the feedback results of the second action, determining whether the first action and the second action can be associated; if so, associating the first action with the second action.
[0108] In some embodiments of the present invention, the processor 1301 may load and execute:
[0109] Determining whether the execution result of the first action is the same as the execution result of the second action;
[0110] If so, associating the first action with the second action;
[0111] If not, obtain the execution effect of the first action and the execution effect of the second action, and determine whether the execution effect of the first action and the execution effect of the second action are the same; if so, associate the first action with the second action.
[0112] In some embodiments of the present invention, the processor 1301 may load and execute:
[0113] According to a pre-configured collection cycle and collection times, respectively obtaining a detection result of the detection object corresponding to the first action and a detection result of the detection object corresponding to the second action;
[0114] The detection result of the detection object corresponding to the first action and the detection result of the detection object corresponding to the second action are analyzed to obtain the execution effect of the first action and the execution effect of the second action.
[0115] In some embodiments of the present invention, the processor 1301 may load and execute:
[0116] In combination with the pre-configured action conditions, the detection result of the detection object corresponding to the first action and the detection result of the detection object corresponding to the second action are analyzed to obtain the execution effect of the first action and the execution effect of the second action.
[0117] In some embodiments of the present invention, the processor 1301 may load and execute:
[0118] According to the pre-configured association condition of the first action, determining whether the second action meets the association condition;
[0119] If so, the first action is associated with the second action.
[0120] In some embodiments of the present invention, the association condition includes at least one of device location, device type, operation time and operation priority.
[0121] In some embodiments of the present invention, the processor 1301 may load and execute:
[0122] Based on a preconfigured association relationship between the first action and the second action, the first action is associated with the second action.
[0123] In some embodiments of the present invention, the association relationship includes one of sequential execution, simultaneous execution and abnormal execution.
[0124] The memory 1320 can be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage device, dynamic storage device, etc. The memory 1320 can store operating systems and other applications. When the technical solutions provided in the embodiments of this specification are implemented by software or firmware, the relevant program codes are stored in the memory 1320 and called and executed by the processor 1310. The memory 1302 is used to store data, and the data includes at least one of a collection interval, a collection method, an execution result, an execution effect, result data, an action condition, an associated condition, and an associated action method.
[0125] The input / output interface 1330 is used to connect the input / output module to realize information input and output. The input / output module can be configured as a component in the device (not shown in the figure), or it can be externally connected to the device to provide corresponding functions. The input device may include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output device may include a display, a speaker, a vibrator, an indicator light, etc.
[0126] The communication interface 1340 is used to connect a communication module (not shown) to realize communication interaction between the device and other devices. The communication module can realize communication through a wired mode (such as USB, network cable, etc.) or a wireless mode (such as mobile network, WIFI, Bluetooth, etc.).
[0127] The bus 1350 includes a path that transmits information between the various components of the device (eg, the processor 1310 , the memory 1320 , the input / output interface 1330 , and the communication interface 1340 ).
[0128] It should be noted that, although the above device only shows the processor 1310, the memory 1320, the input / output interface 1330, the communication interface 1340 and the bus 1350, in the specific implementation process, the device may also include other components necessary for normal operation. In addition, it can be understood by those skilled in the art that the above device may also only include the components necessary for implementing the embodiments of the present specification, and does not necessarily include all the components shown in the figure.
[0129] The computer-readable medium of this embodiment includes permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, read-only compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device.
[0130] Those skilled in the art should understand that the discussion of any of the above embodiments is merely illustrative and is not intended to imply that the scope of the present disclosure (including the claims) is limited to these examples. Within the scope of the present invention, the above embodiments or technical features in different embodiments may be combined, the steps may be implemented in any order, and there are many other variations of the different aspects of the present invention as described above, which are not provided in detail for the sake of simplicity.
[0131] In addition, to simplify the description and discussion, and in order not to obscure the present invention, known power / ground connections to integrated circuit (IC) chips and other components may or may not be shown in the provided figures. In addition, the devices may be shown in the form of block diagrams to avoid obscuring the present invention, and this also takes into account the fact that the details of the implementation of these block diagram devices are highly dependent on the platform on which the present invention will be implemented (i.e., these details should be fully within the scope of understanding of those skilled in the art). Where specific details (e.g., circuits) are set forth to describe exemplary embodiments of the present invention, it will be apparent to those skilled in the art that the present invention may be implemented without these specific details or with variations in these specific details. Therefore, these descriptions should be considered illustrative rather than restrictive.
[0132] Although the invention has been described in conjunction with specific embodiments of the invention, many replacements, modifications and variations of these embodiments will be apparent to those skilled in the art from the foregoing description. For example, other memory architectures (e.g., dynamic RAM (DRAM)) may use the embodiments discussed.
[0133] The embodiments of the present invention are intended to cover all such substitutions, modifications and variations that fall within the broad scope of the appended claims. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the protection scope of the present invention.< / relatedactionsrelationship> < / actionrelationcriteria> < / actionresult> < / duration> < / actionresult> < / duration> < / actionresult> < / action> < / actionresult> < / actionresult> < / duration> < / actionresult> < / duration> < / actionresult> < / resultmode> < / action> < / action> < / actioneffect> < / actionresult> < / actioneffect> < / relatedactionid> < / actioneffect> < / actioneffect> < / actioneffect> < / actionresult> < / actionresult> < / actionresult> < / actioneffect> < / actioneffect> < / actioneffect> < / actionresult> < / outputresource> < / actioneffect> < / actioneffect> < / actioneffect> < / actionresult> < / actionresult> < / actionresult> < / actionresult> < / actionresult> < / actioneffect> < / action> < / action> < / resultmode>
Claims
1. An action association method based on the Internet of Things, characterized in that: include: Triggering the first device to execute a first action and the second device to execute a second action respectively, and obtaining a feedback result of the first action and a feedback result of the second action; wherein the feedback result includes at least one of an execution result and an execution effect; Based on the feedback result of the first action and the feedback result of the second action, determining whether the first action and the second action can be associated; if so, associating the first action with the second action, including: determining whether the execution result of the first action and the execution result of the second action are the same; if so, associating the first action with the second action; if not, obtaining the execution effect of the first action and the execution effect of the second action, and determining whether the execution effect of the first action and the execution effect of the second action are the same; if so, associating the first action with the second action; Among them, associating the first action with the second action includes: associating the first action with the second action based on a pre-configured associating action mode of the first action and the second action; in response to the associating action mode being abnormal execution, when the first device fails to execute the first action or the execution effect of the first device does not reach the expected value, triggering the second device to execute the second action.
2. The action association method based on the Internet of Things according to claim 1 is characterized in that: Obtaining the execution effect of the first action and the execution effect of the second action, including: According to a pre-configured collection interval and collection method, respectively obtaining the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action; The execution effect of the first action and the execution effect of the second action are calculated according to the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action.
3. The action association method based on the Internet of Things according to claim 2 is characterized in that: Calculating the execution effect of the first action and the execution effect of the second action according to the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action includes: Calculate result data corresponding to the first action and result data corresponding to the second action respectively according to the execution result of the action result object corresponding to the first action and the execution result of the action result object corresponding to the second action; It is respectively determined whether the result data corresponding to the first action and the result data corresponding to the second action meet the pre-configured action conditions, thereby obtaining the execution effect of the first action and the execution effect of the second action.
4. The action association method based on the Internet of Things according to claim 1 is characterized in that: Associating the first action with the second action includes: According to the pre-configured association condition of the first action, determining whether the second action meets the association condition; If so, the first action is associated with the second action.
5. The action association method based on the Internet of Things according to claim 4 is characterized in that: The association condition includes at least one of a device location, a device type, an operation time, and an operation priority.
6. The action association method based on the Internet of Things according to claim 1 is characterized in that: The associated action mode includes one of sequential execution, simultaneous execution and abnormal execution.
7. The action association method based on the Internet of Things according to claim 1 is characterized in that: The action association method is applied to the server.
8. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the method described in any one of claims 1 to 7 is implemented, and the memory is used to store data, and the data includes at least one of a collection interval, a collection method, an execution result, an execution effect, result data, an action condition, an associated condition and an associated action method.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to cause the computer to execute any one of the methods of claims 1 to 7.
