A smart scene linkage control method based on a smart home platform

By creating triggering and linkage scenarios on the smart home platform, and utilizing parallel threads and thread pool technology for efficient detection and execution, the flexibility and efficiency issues of smart home products in scene linkage are solved, achieving user-friendly smart scene control.

CN116700035BActive Publication Date: 2026-04-21四川长虹新网科技有限责任公司
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
四川长虹新网科技有限责任公司
Filing Date
2023-07-26
Publication Date
2026-04-21

AI Technical Summary

Technical Problem

Existing smart home products have limited use in complex environmental detection and timed scene linkage, especially in terms of how to flexibly set up smart scenes and efficiently execute them.

Method used

By creating trigger scenarios, linkage execution scenarios, and configuring effective times on the smart home platform, and combining parallel threads for device and timed trigger detection, linkage scenario tasks are generated and executed, and thread pool technology is used for efficient task execution.

Benefits of technology

It achieves flexibility and high efficiency in setting up intelligent scenarios for users, improves the efficiency of trigger judgment and execution, and ensures the independence and high efficiency of scenario triggering and execution.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116700035B_ABST
    Figure CN116700035B_ABST
Patent Text Reader

Abstract

The application relates to the field of smart home, and discloses a smart scene linkage control method based on a smart home platform, which makes the setting of a smart scene more flexible and the execution of the smart scene more efficient. The method comprises the following steps: A, smart scene creation and saving in a cloud platform; the smart scene creation comprises creating a triggering scene, creating a linkage execution scene and configuring a smart scene effective time; B, the cloud platform starts a device triggering detection task and a timing triggering detection task through parallel threads to perform triggering detection; and C, the cloud platform starts linkage scene execution task generation and linkage scene execution task execution through parallel threads to perform linkage scene execution. The application is suitable for smart home scenes.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of smart homes, and more specifically to a method for intelligent scene linkage control based on a smart home platform. Background Technology

[0002] As society becomes increasingly digitalized and intelligent, various electronic products and applications are constantly facilitating people's travel and enriching their leisure and entertainment. Among these, smart home-related electronic products and applications are the most representative area. However, most smart home products currently only cover simple control and environmental detection, with limited use of complex scene linkages based on environmental detection and timing. In particular, research on how to flexibly set up smart scenes and how to efficiently execute smart scenes is lacking. Summary of the Invention

[0003] The technical problem to be solved by this invention is to propose a smart scene linkage control method based on a smart home platform, which makes it more flexible for users to set up smart scenes and more efficient for smart scene execution.

[0004] The technical solution adopted by the present invention to solve the above-mentioned technical problems is as follows:

[0005] A smart scene linkage control method based on a smart home platform includes:

[0006] A. Intelligent scene creation and storage on the cloud platform: The intelligent scene creation includes creating trigger scenes, creating linked execution scenes, and configuring the effective time of intelligent scenes;

[0007] B. The cloud platform initiates device trigger detection tasks and timed trigger detection tasks through parallel threads to perform trigger detection. Among them, the device trigger detection task monitors changes in device status and determines whether the device meets the trigger conditions based on the user's smart scene configuration to determine whether to trigger the execution of the linkage scene. The timed trigger detection task detects whether the current time matches the user's timed configuration and whether the trigger conditions include device triggering, while also determining whether the device status meets the trigger conditions to determine whether to trigger the execution of the linkage scene.

[0008] C. The cloud platform uses parallel threads to initiate the generation and execution of linked scenario execution tasks to perform linked scenario execution tasks. Specifically, the generation of linked scenario execution tasks involves converting the actions to be performed in the linked scenario into execution tasks and placing them into the task execution queue when the linked scenario execution is triggered. The execution of linked scenario execution tasks involves accessing the task execution queue at fixed time intervals and retrieving the tasks to be executed.

[0009] Furthermore, step A specifically includes:

[0010] A1. Create a trigger scenario:

[0011] Configure a trigger type, which can be set to trigger when any trigger condition is met or when all trigger conditions are met;

[0012] Configure at least one trigger condition, wherein the trigger condition can be selected to be device-triggered or timed-triggered;

[0013] When a trigger condition is configured as device trigger, add the triggering device and the trigger status;

[0014] When a trigger condition is configured to trigger at a time, add the trigger time;

[0015] A2. Create a linked execution scenario:

[0016] Configure the execution device and execution action; select whether to set a delay for the execution action and the delay duration according to requirements;

[0017] A3. Configure the effective time of intelligent scenes;

[0018] The cloud platform will save the smart scenes created in steps A1-A3 as a smart scene configuration list associated with the user bound to the device.

[0019] Furthermore, step B specifically includes:

[0020] B1. For device-triggered detection tasks, the execution process is as follows:

[0021] B11. When the cloud platform receives a status change reported by a device in the smart scene, it obtains the smart scene configuration list of the user bound to the device, and determines whether the current time is within the effective time range of the smart scene based on the smart scene configuration list. If so, it executes step B12; otherwise, it returns to step B11.

[0022] B12. Determine the current trigger type. If it is triggered when any trigger condition is met, proceed to step B13. If it is triggered when all trigger conditions are met, proceed to step B14.

[0023] B13. Determine whether the current state of the device matches the trigger state of the device in the trigger conditions. If yes, trigger the execution of the linkage scene; otherwise, return to step B11.

[0024] B14. Determine whether any of the triggering conditions contain a timed trigger configuration. If yes, return to step B11; otherwise, proceed to step B15.

[0025] B15. Determine whether the current state of the device matches the trigger state of the device in the trigger conditions. If so, continue to determine whether the current state of other devices in the trigger conditions meets the trigger conditions. If they match, trigger the execution of the linkage scene. Otherwise, return to step B11.

[0026] B2. For timed triggering tasks, the execution process is as follows:

[0027] B21. Scheduled trigger task starts a scheduled trigger detection at regular intervals;

[0028] B22. When triggering detection at regular intervals, first obtain the list of smart scene configurations for the user bound to the device;

[0029] B23. Based on the intelligent scene configuration list, determine whether the current time is within the effective time range of the intelligent scene. If yes, proceed to step B24; otherwise, return to step B21.

[0030] B24. Determine whether the current time matches the time configured in the smart scene configuration list. If yes, proceed to step B25; otherwise, return to step B21.

[0031] B25. Determine the current trigger type. If it is triggered when any trigger condition is met, then trigger the execution of the linked scene. If it is triggered when all trigger conditions are met, then proceed to step B26.

[0032] B26. Determine if all triggering conditions are met. If so, trigger the execution of the linked scene; otherwise, return to step B21.

[0033] Furthermore, step C specifically includes:

[0034] C1. The process for generating tasks in linked scenarios is as follows:

[0035] C11. When a linked scene is triggered, extract the execution device and execution action of the related linked scene from the smart scene configuration list of the user bound to the device, and generate a scene execution list;

[0036] C12. Loop through the execution actions and delay times of each device in the scene execution list;

[0037] C13. Convert the action into a scene execution task, set the specific execution time in the task according to the current time and delay, and put the scene execution task into the task execution list to wait for execution;

[0038] C2. For tasks executed in linked scenarios, the process is as follows:

[0039] C21. Set a timer to repeat once per second;

[0040] C22. When the timer expires, iterate through the task execution list once and retrieve the tasks that match the execution time to execute.

[0041] Furthermore, in step A3, the effective time of the smart scene includes which day or days of the week it takes effect, and the effective time period on the effective day.

[0042] Furthermore, step C2 also includes:

[0043] C23. Record the task execution process and results.

[0044] The beneficial effects of this invention are:

[0045] (1) This solution sets up two types of trigger conditions: timed trigger and device trigger. Furthermore, the triggering method can be any condition or all configured trigger conditions. In addition, this solution can trigger based on any variable state of the device and can select any executable command from the device for scene execution. Therefore, it makes setting up intelligent scenes more flexible for users.

[0046] (2) This solution processes device triggering and timed triggering independently and in parallel, ensuring that their triggering judgments do not affect or restrict each other, thereby improving the efficiency of triggering judgment. Furthermore, when the triggering conditions are met, this solution does not immediately execute the scene; instead, it assembles the scenes to be executed into tasks, places them in a task queue, and then uses a timer to query and execute tasks in the task queue every second. This solution also uses thread pool technology during task execution, enabling the platform to execute multiple tasks simultaneously. This separation of triggering and execution, coupled with multi-threaded task execution, completely isolates scene triggering detection and execution, significantly improving the efficiency of scene triggering and execution. Attached Figure Description

[0047] Figure 1 A flowchart for creating intelligent scenarios in this embodiment of the invention;

[0048] Figure 2 This is a flowchart of the trigger detection process in an embodiment of the present invention;

[0049] Figure 3 This is a flowchart of the linkage scenario execution in an embodiment of the present invention. Detailed Implementation

[0050] The present invention aims to propose a smart scene linkage control method based on a smart home platform, which makes it more flexible for users to set up smart scenes and more efficient for the execution of smart scenes. In this solution, intelligent scenes are first created and stored on the cloud platform. Intelligent scene creation includes creating trigger scenes, creating linked execution scenes, and configuring the effective time of the intelligent scenes. For trigger detection, the cloud platform uses parallel threads to start device trigger detection tasks and timed trigger detection tasks. The device trigger detection task monitors changes in device status and determines whether the device meets the trigger conditions based on the user's intelligent scene configuration to determine whether to trigger the linked scene execution. The timed trigger detection task checks whether the current time matches the user's timed configuration, and if the trigger conditions include device triggering, it also checks whether the device status meets the trigger conditions to determine whether to trigger the linked scene execution. For linked scene execution, the cloud platform uses parallel threads to start linked scene execution task generation and linked scene execution task execution. Linked scene execution task generation converts the actions to be performed in the linked scene into execution tasks and puts them into a task execution queue when the linked scene is triggered. Linked scene execution task execution accesses the task execution queue at fixed time intervals and retrieves the tasks to be executed.

[0051] The present invention will be further described below with reference to the accompanying drawings and embodiments.

[0052] Example:

[0053] In this embodiment, the specific process of creating an intelligent scene is as follows: Figure 1 As shown, it includes three parts: creating a trigger scenario, creating a linked execution scenario, and configuring the smart scenario's effective time. Detailed explanations are as follows:

[0054] Create a trigger scenario:

[0055] Configure a trigger type, which can be set to trigger if any trigger condition is met or trigger if all trigger conditions are met. "Trigger if any trigger condition is met" means that the scene will be triggered if any one of the configured trigger conditions is met. "Trigger if all trigger conditions are met" means that the scene will be triggered only if all the configured trigger conditions are met.

[0056] Configure at least one trigger condition, which can be selected as device trigger or timed trigger; when a trigger condition is configured as device trigger, add the triggering device and trigger status; when a trigger condition is configured as timed trigger, add the trigger time.

[0057] Understandably, the number of "trigger conditions" that can be configured can be set according to the user's actual needs. You can configure only one or multiple conditions at the same time. For each trigger condition, you can choose "device trigger" or "timed trigger". When you choose "device trigger", you need to add the triggering device and the triggering status. For example, the triggering device is "door sensor" and the triggering status is "open". Or, the triggering device is "infrared" and the triggering status is "person detected".

[0058] The above steps can be used to configure the triggering scenario.

[0059] Create interactive scenes:

[0060] Configure the execution device and the execution action; for example, the execution device is a socket and a curtain, the execution action of the socket is "open", the execution action of the curtain is "open", etc.; in addition, you can choose whether to set a delay for the execution action and the delay time according to your needs, such as "30:30", which means that the next action will be executed after a delay of 30 minutes and 30 seconds. It should be noted that the delay is not a mandatory setting, but if you choose it, it must be followed by an execution action.

[0061] Based on the above, the creation of a collaborative scenario can be completed.

[0062] Configure the smart scene activation time:

[0063] The "Smart Scene Activation Time" in this solution is a prerequisite for scene linkage triggering. If it is outside the activation time range, no timer or device status can trigger scene execution. During configuration, you can select the scene activation time period, such as "08:00-19:00," and select repeating days of the week, such as "Monday and Wednesday." The smart scene activation time configured accordingly means that the smart scene will only trigger detection and the linked scene can only take effect during the 08:00-19:00 time period on Mondays and Wednesdays.

[0064] The trigger scenarios created above are stored in the cloud platform (smart home platform).

[0065] In this embodiment, the process for triggering the detection is as follows: Figure 2 As shown, the cloud platform initiates device-triggered detection tasks and timed-triggered detection tasks through parallel threads to perform triggered detection.

[0066] Specifically, the execution process for a device-triggered detection task is as follows:

[0067] a. When the cloud platform receives a status change reported by a device in the smart scene, it obtains the smart scene configuration list of the user bound to the device, and determines whether the current time is within the effective time range of the smart scene based on the smart scene configuration list. If so, it executes step b; otherwise, it returns to step a.

[0068] b. Determine the current trigger type. If it is triggered when any trigger condition is met, proceed to step c. If it is triggered when all trigger conditions are met, proceed to step d.

[0069] c. Determine if the current state of the device matches the trigger state of the device in the trigger conditions. If yes, trigger the execution of the linkage scene; otherwise, return to step a.

[0070] d. Determine whether any of the triggering conditions contain a timed trigger configuration. If yes, return to step a; otherwise, proceed to step e.

[0071] e. Determine whether the current state of the device matches the trigger state of the device in the trigger conditions. If so, continue to determine whether the current state of other devices in the trigger conditions meets the trigger conditions. If they match, trigger the execution of the linkage scene. Otherwise, return to step a.

[0072] During the above execution process, the trigger detection with timed trigger configuration is performed by the timed trigger detection task, and not by the device trigger detection task. This is to ensure that the trigger judgment of the two do not affect or restrict each other, thereby improving the efficiency of trigger judgment.

[0073] Specifically, for timed triggering tasks, the execution process is as follows:

[0074] a. A timed trigger task starts a timed trigger detection at regular intervals (e.g., every 31 seconds);

[0075] b. When the detection is triggered on a timed basis, first obtain the list of smart scene configurations of the user bound to the device;

[0076] c. Based on the intelligent scene configuration list, determine whether the current time is within the effective time range of the intelligent scene. If yes, proceed to step d; otherwise, return to step a.

[0077] d. Determine if the current time matches the time configured in the smart scene configuration list. If yes, proceed to step e; otherwise, return to step a.

[0078] e. Determine the current trigger type. If it is triggered when any trigger condition is met, then trigger the execution of the linked scene. If it is triggered when all trigger conditions are met, then proceed to step f.

[0079] f. Determine if all triggering conditions are met. If yes, trigger the execution of the linked scene; otherwise, return to step a.

[0080] In this embodiment, the execution process of the linkage scene is described in detail below. Figure 3The cloud platform uses parallel threads to generate and execute linked scenario execution tasks to perform linked scenario execution.

[0081] Specifically, the process for generating tasks in a collaborative scenario is as follows:

[0082] a. When a linked scenario is triggered, the execution device and execution action of the related linked scenario are extracted from the smart scenario configuration list of the user bound to the device, and a scenario execution list is generated;

[0083] b. Loop through the execution actions and delay times of each device in the scene execution list;

[0084] c. Transform the action into a scenario execution task, set the specific execution time in the task based on the current time and delay, and put the scenario execution task into the task execution list to wait for execution.

[0085] Specifically, the process for executing tasks in a collaborative scenario is as follows:

[0086] a. Set a timer to repeat once per second;

[0087] b. When the timer expires, iterate through the task execution list once and retrieve the tasks that match the execution time to execute.

[0088] In this solution, by setting the generation and execution of linked scene execution tasks in parallel, the trigger detection and linked scene execution can be separated, resulting in more efficient trigger detection and scene execution.

[0089] Finally, it should be noted that the above embodiments are merely preferred embodiments and are not intended to limit the present invention. It should be pointed out that those skilled in the art can make various modifications, equivalent substitutions, and improvements without departing from the spirit and scope of the claims, and all such modifications, substitutions, and improvements should be included within the scope of protection of the present invention.

Claims

1. A method for intelligent scene linkage control based on a smart home platform, characterized in that, include: A. Intelligent scene creation and storage on the cloud platform: The intelligent scene creation includes creating trigger scenes, creating linked execution scenes, and configuring the effective time of intelligent scenes; Step A specifically includes: A1. Create a trigger scenario: Configure a trigger type, which can be set to trigger when any trigger condition is met or when all trigger conditions are met; Configure at least one trigger condition, wherein the trigger condition can be selected to be device-triggered or timed-triggered; When a trigger condition is configured as device trigger, add the triggering device and the trigger status; When a trigger condition is configured to trigger at a time, add the trigger time; A2. Create a linked execution scenario: Configure the execution device and execution action; select whether to set a delay for the execution action and the delay duration according to requirements; A3. Configure the effective time of intelligent scenes; The cloud platform will save the smart scenes created in steps A1-A3 as a list of smart scene configurations associated with the user bound to the device; B. The cloud platform initiates device trigger detection tasks and timed trigger detection tasks through parallel threads to perform trigger detection. Among them, the device trigger detection task monitors changes in device status and determines whether the device meets the trigger conditions based on the user's smart scene configuration to determine whether to trigger the execution of the linkage scene. The timed trigger detection task detects whether the current time matches the user's timed configuration and whether the trigger conditions include device triggering, while also determining whether the device status meets the trigger conditions to determine whether to trigger the execution of the linkage scene. Step B specifically includes: B1. For device-triggered detection tasks, the execution process is as follows: B11. When the cloud platform receives a status change reported by a device in the smart scene, it obtains the smart scene configuration list of the user bound to the device, and determines whether the current time is within the effective time range of the smart scene based on the smart scene configuration list. If so, it executes step B12; otherwise, it returns to step B11. B12. Determine the current trigger type. If it is triggered when any trigger condition is met, proceed to step B13. If it is triggered when all trigger conditions are met, proceed to step B14. B13. Determine whether the current state of the device matches the trigger state of the device in the trigger conditions. If yes, trigger the execution of the linkage scene; otherwise, return to step B11. B14. Determine whether any of the triggering conditions contain a timed trigger configuration. If yes, return to step B11; otherwise, proceed to step B15. B15. Determine whether the current state of the device matches the trigger state of the device in the trigger conditions. If so, continue to determine whether the current state of other devices in the trigger conditions meets the trigger conditions. If they match, trigger the execution of the linkage scene. Otherwise, return to step B11. B2. For timed triggering tasks, the execution process is as follows: B21. Scheduled trigger task starts a scheduled trigger detection at regular intervals; B22. When triggering detection at regular intervals, first obtain the list of smart scene configurations for the user bound to the device; B23. Based on the intelligent scene configuration list, determine whether the current time is within the effective time range of the intelligent scene. If yes, proceed to step B24; otherwise, return to step B21. B24. Determine whether the current time matches the time configured in the smart scene configuration list. If yes, proceed to step B25; otherwise, return to step B21. B25. Determine the current trigger type. If it is triggered when any trigger condition is met, then trigger the execution of the linked scene. If it is triggered when all trigger conditions are met, then proceed to step B26. B26. Determine if all triggering conditions are met. If yes, trigger the execution of the linked scene; otherwise, return to step B21. C. The cloud platform uses parallel threads to initiate the generation and execution of linked scenario execution tasks to perform linked scenario execution tasks. Specifically, the generation of linked scenario execution tasks involves converting the actions to be performed in the linked scenario into execution tasks and placing them into the task execution queue when the linked scenario execution is triggered. The execution of linked scenario execution tasks involves accessing the task execution queue at fixed time intervals and retrieving the tasks to be executed.

2. The intelligent scene linkage control method based on a smart home platform as described in claim 1, characterized in that, Step C specifically includes: C1. The process for generating tasks in linked scenarios is as follows: C11. When a linked scene is triggered, extract the execution device and execution action of the related linked scene from the smart scene configuration list of the user bound to the device, and generate a scene execution list; C12. Loop through the execution actions and delay times of each device in the scene execution list; C13. Convert the action into a scene execution task, set the specific execution time in the task according to the current time and delay, and put the scene execution task into the task execution list to wait for execution; C2. For tasks executed in linked scenarios, the process is as follows: C21. Set a timer to repeat once per second; C22. When the timer expires, iterate through the task execution list once and retrieve the tasks that match the execution time to execute.

3. The intelligent scene linkage control method based on a smart home platform as described in claim 1, characterized in that, In step A3, the effective time of the smart scene includes which day or days of the week it takes effect, and the effective time period on the effective day.

4. The intelligent scene linkage control method based on a smart home platform as described in claim 2, characterized in that, Step C2 also includes: C23. Record the task execution process and results.

Citation Information

Patent Citations

  • Method for triggering smart home application scene, device and storage medium

    CN111459043A