Interaction method and device for smart home equipment, equipment and medium
By implementing on-demand reporting and real-time update of smart home device status information in the Internet of Things server, the problem of untimely update of status and excessive service load of cloud devices when processing large amounts of device reporting information is solved, real-time performance of smart home device status and reduction of server load is achieved.
Patent Information
- Application Number
- CN202411915912.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-24
- Publication Date
- 2025-05-16
AI Technical Summary
When cloud devices process large amounts of smart home devices to report information, the status update is not timely, the service processing is significantly slowed down or even crashed and restarted.
By responding to the device wake-up command of the voice entrance device, the smart home device wakes up and obtains its current status information, updates the status information of the cloud device, and feedbacks the latest status as needed when receiving the information acquisition command, reducing the frequency of reporting of the device.
While maintaining the real-time status of smart home devices, it reduces the load on IoT servers and avoids the problems of untimely status updates and service crashes.
Smart Images

Figure CN120010277A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of smart homes, and in particular to an interaction method for smart home devices, an interaction device for smart home devices, an electronic device and a computer-readable storage medium. Background Art
[0002] Although cloud devices can greatly improve the smart home experience, they also place a considerable burden on the server. With more and more online devices, the server is loaded with a large amount of device reporting information processing work, resulting in problems such as untimely updates of cloud device status (message backlog), significantly slowed service processing, and even crashes and restarts. Summary of the invention
[0003] In view of the above problems, an interaction method for smart home devices, an interaction device for smart home devices, an electronic device and a computer-readable storage medium are proposed to overcome the above problems or at least partially solve the above problems, including:
[0004] An interaction method for smart home devices is applied to an Internet of Things server, wherein a cloud device is deployed in the Internet of Things server for the smart home devices, and the method comprises:
[0005] In response to a device wake-up instruction of the voice entry device, wake up the smart home device, and obtain current first device status information of the smart home device from the smart home device;
[0006] According to the first device status information, updating the device status information of the cloud device;
[0007] In response to the information acquisition instruction of the voice entry device, the current second device status information of the cloud device is determined, and the second device status information is fed back to the voice entry device.
[0008] Optionally, acquiring the current first device status information of the smart home device from the smart home device includes:
[0009] At a preset time interval, continuously obtaining the current first device status information of the smart home device from the smart home device;
[0010] The updating of the device status information of the cloud device according to the first device status information includes:
[0011] The device status information of the cloud device is updated according to the latest first device status information currently acquired.
[0012] Optionally, the method further comprises:
[0013] When the duration of obtaining the current first device status information of the smart home device from the smart home device continues for a preset duration, stopping obtaining the current first device status information of the smart home device from the smart home device.
[0014] Optionally, the method further comprises:
[0015] Upon receiving the information acquisition instruction, determining a time difference between a timestamp of the current second device status information of the cloud device and the current time;
[0016] When the time difference is not less than a preset time difference, reacquiring the current first device status information of the smart home device from the smart home device;
[0017] When the time difference is less than a preset time difference, the second device status information is fed back to the voice entry device.
[0018] Optionally, when reacquiring the current first device status information of the smart home device from the smart home device, the method further includes:
[0019] When the current first device status information of the smart home device is re-acquired from the smart home device, if the first device status information is not re-acquired for more than a first preset time, query waiting information is fed back to the voice entry device.
[0020] Optionally, when reacquiring the current first device status information of the smart home device from the smart home device, the method further includes:
[0021] When the current first device status information of the smart home device is re-acquired from the smart home device, if the first device status information is not re-acquired for more than a second preset time period, device offline information is fed back to the voice entry device.
[0022] Optionally, when reacquiring the current first device status information of the smart home device from the smart home device, the method further includes:
[0023] When the current first device status information of the smart home device is obtained again from the smart home device, if the first device status information is not obtained again for more than a preset number of times, device offline information is fed back to the voice entry device.
[0024] Optionally, the device wake-up instruction is an instruction generated by the voice entry device based on the user's voice interaction operation.
[0025] Optionally, the first device status information includes environmental information acquired by the smart home device.
[0026] The embodiment of the present invention further provides an interactive device for smart home devices, which is applied to an Internet of Things server. A cloud device is deployed in the Internet of Things server for the smart home devices. The device includes:
[0027] an acquisition module, configured to wake up the smart home device in response to a device wake-up instruction of a voice entry device, and acquire current first device status information of the smart home device from the smart home device;
[0028] An updating module, configured to update the device status information of the cloud device according to the first device status information;
[0029] The first feedback module is used to respond to the information acquisition instruction of the voice entry device, determine the current second device status information of the cloud device, and feed back the second device status information to the voice entry device.
[0030] Optionally, the acquisition module is used to continuously acquire the current first device status information of the smart home device from the smart home device at a preset time interval;
[0031] The updating module is used to update the device status information of the cloud device according to the latest first device status information currently acquired.
[0032] Optionally, the device further comprises:
[0033] The stopping module is used to stop obtaining the current first device status information of the smart home device from the smart home device when the duration of obtaining the current first device status information of the smart home device from the smart home device continues for a preset duration.
[0034] Optionally, the device further comprises:
[0035] A time difference calculation module is used to determine the time difference between the timestamp of the current second device status information of the cloud device and the current time when receiving the information acquisition instruction; when the time difference is not less than the preset time difference, re-acquire the current first device status information of the smart home device from the smart home device; when the time difference is less than the preset time difference, feedback the second device status information to the voice entry device.
[0036] Optionally, the device further comprises:
[0037] The second feedback module is used to feedback query waiting information to the voice entry device when re-obtaining the current first device status information of the smart home device from the smart home device, when the first device status information of the smart home device is not re-obtained within a first preset time.
[0038] Optionally, the device further comprises:
[0039] The third feedback module is used to feedback device offline information to the voice entry device when the current first device status information of the smart home device is re-acquired from the smart home device, and when the first device status information of the smart home device is not re-acquired within a second preset time.
[0040] Optionally, the device further comprises:
[0041] The fourth feedback module is used to feedback device offline information to the voice entry device when the current first device status information of the smart home device is re-obtained from the smart home device, and when the current first device status information of the smart home device is not re-obtained from the smart home device for more than a preset number of times.
[0042] Optionally, the device wake-up instruction is an instruction generated by the voice entry device based on the user's voice interaction operation.
[0043] Optionally, the first device status information includes environmental information acquired by the smart home device.
[0044] An embodiment of the present invention further provides an electronic device, comprising a processor, a memory, and a computer program stored in the memory and capable of running on the processor, wherein the computer program implements the above-mentioned interaction method for smart home devices when executed by the processor.
[0045] An embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the above-mentioned interaction method for smart home devices is implemented.
[0046] The embodiments of the present invention have the following advantages:
[0047] In the embodiment of the present invention, in response to the device wake-up instruction of the voice entry device, the smart home device is woken up, and the current first device status information of the smart home device is obtained from the smart home device; according to the first device status information, the device status information of the cloud device is updated; in response to the information acquisition instruction of the voice entry device, the current second device status information of the cloud device is determined, and the second device status information is fed back to the voice entry device. Through the embodiment of the present invention, the load of the Internet of Things server can be reduced while maintaining the real-time status of the smart home device. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] In order to more clearly illustrate the technical solution of the present invention, the accompanying drawings required for use in the description of the present invention will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative labor.
[0049] Figure 1 is a flowchart of a method for interacting with smart home devices according to an embodiment of the present invention;
[0050] Figure 2 is a flowchart of another method for interacting with smart home devices according to an embodiment of the present invention;
[0051] Figure 3 is a flowchart of another method for interacting with smart home devices according to an embodiment of the present invention;
[0052] Figure 4 This is a flowchart of the steps of device awakening and information acquisition according to an embodiment of the present invention;
[0053] Figure 5 It is a structural block diagram of an interactive device for smart home devices according to an embodiment of the present invention. DETAILED DESCRIPTION
[0054] In order to make the above-mentioned purposes, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below in conjunction with the accompanying drawings and specific embodiments. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0055] In order to reduce the server load while maintaining the real-time status of smart home devices, the embodiment of the present invention provides an interactive method for smart home devices, which can convert automatic device reporting into on-demand reporting, thereby reducing the device reporting frequency; at the same time, it can also maintain the real-time status of cloud-based devices. Figure 1 , Figure 1 A flowchart of a method for interacting with smart home devices according to an embodiment of the present invention is shown.
[0056] like Figure 1 As shown, the interaction method for smart home devices may include the following steps:
[0057] Step 101: In response to a device wake-up instruction of a voice entry device, a smart home device is woken up, and current first device status information of the smart home device is obtained from the smart home device.
[0058] The field of smart home has made great progress. For the query and control of smart home devices, interaction with the devices is inevitable.
[0059] The current mainstream solution is real-time device communication, that is, querying the status and interacting with the smart home device once, and then sending it and interacting with the smart home device again; because the instability of the local network environment cannot be avoided, it leads to a long waiting time (for voice control, it is necessary to query the status once + send a command, which is equivalent to interacting with the device twice for one voice execution, which is easy to time out); nowadays, the more commonly used solutions are cloud devices (shadow devices), that is, cloud devices report the status to the IoT (Internet of Things) server cache, and the smart home client directly obtains the current status of the device by querying the IoT server cache.
[0060] Although cloud devices can greatly improve the smart home experience, they also put a lot of burden on the server. With more and more online devices, the server is loaded with a lot of device reporting information processing work, which causes problems such as untimely updates of cloud device status (message backlog), significantly slow service processing, and even crash restart. How to reduce the frequency of device reporting while maintaining the real-time status of cloud devices and ensuring services under the framework of cloud devices is a problem that needs to be carefully solved.
[0061] To address this problem, an embodiment of the present invention can change the reporting of smart home device status information to on-demand reporting, thereby reducing the reporting frequency; in addition, when the smart home device is woken up, the status information is obtained, so that the latest status information is stored in the Internet of Things server before receiving the information acquisition instruction, thereby ensuring the real-time status.
[0062] Specifically, the user may first perform an operation on the voice entry device to control the voice entry device to generate a device wake-up instruction for the smart home device. The voice entry device may refer to a device with a voice interaction function and used to control the smart home device, such as a voice audio system, a voice air conditioner, etc., which is not limited in the embodiment of the present invention.
[0063] Smart home devices can refer to home appliances and devices that are connected via the Internet and can be remotely controlled or automatically perform tasks. For example: smart bulbs and lighting systems, smart thermostats, smart door locks, smart cameras, smart sockets, smart refrigerators, smart washers and dryers, smart curtains and blinds, smart air purifiers, etc. These devices can be connected to the home network via wired, Wi-Fi, Bluetooth or other wireless communication protocols and controlled through smartphone apps, tablets or voice assistants.
[0064] When users need to control smart home devices or view the information of smart home devices, they need to wake up the smart home devices through the voice entry device first; for example, they can wake up the voice entry device by saying wake-up words such as "Xiaodu Xiaodu" or "Xiao Ai classmate" to the voice entry device.
[0065] After generating a device wake-up instruction, the voice entry device can send the device wake-up instruction to the Internet of Things server; after receiving the device wake-up instruction, the Internet of Things server can respond to the device wake-up instruction and wake up the corresponding smart home device.
[0066] In some feasible embodiments, the voice entry device caches a list of devices in the home at the voice communication module end, and the list also indicates the protocols that distinguish different devices.
[0067] When the voice function is awakened, the device status report wake-up is processed in parallel with the voice function. Specifically: for smart home devices that support short-range protocols such as Bluetooth or mesh, the device is notified to immediately report its real-time status through short-range methods such as LAN and Bluetooth broadcast;
[0068] For devices that do not support short-range communication or are not connected to a local area network, that is, the smart home devices cannot be directly awakened by the voice entry device, the smart home devices are reported to the IoT server, and the IoT server wakes up the smart home devices in parallel to start status reporting.
[0069] In actual applications, when a device wake-up command for a smart home device is detected, the smart home device can be notified to report the device status information, so that the cloud device deployed in the IoT server for the smart home device can be updated in advance.
[0070] Specifically, after detecting the device wake-up instruction, the IoT server may first wake up the smart home device and obtain the current first device status information of the smart home device from the smart home device. The first device status information may include the current status parameters of the smart home device and may also include the status parameters of the environment currently detected by the smart home device, which is not limited in the embodiment of the present invention.
[0071] Exemplarily, when the Internet of Things server obtains the current first device status information of the smart home device from the smart home device, the smart home device may actively report the current first device status information to the Internet of Things server.
[0072] Step 102: Update the device status information of the cloud device according to the first device status information.
[0073] After obtaining the first device status information, the IoT server can use the first device status information to update the device status information of its locally deployed cloud device, so that when it receives an information acquisition instruction in the future, it can directly feed back the latest device status information to the user.
[0074] Step 103: In response to the information acquisition instruction of the voice entry device, determine the current second device status information of the cloud device, and feed back the second device status information to the voice entry device.
[0075] In actual applications, after completing the wake-up, if the user wants to obtain the device status information of the smart home device, the user can further perform the operation of obtaining the device status information; the voice entry device can generate an information acquisition instruction in response to the operation, and send the information acquisition instruction to the Internet of Things server.
[0076] After receiving the information acquisition instruction, the Internet of Things server can respond to the information acquisition instruction to determine the current second device status information of the cloud device. The second device status information is based on the device status information determined based on the latest cloud device after the cloud device is updated by the first device status information.
[0077] After determining the second device status information, the IoT server may return the second device status information to the voice entry device. The voice entry device may perform subsequent data processing based on the second device status information; or, the voice entry device may also display the second device status information to the user, which is not limited in the embodiment of the present invention.
[0078] In the embodiment of the present invention, in response to the device wake-up instruction of the voice entry device, the smart home device is woken up, and the current first device status information of the smart home device is obtained from the smart home device; according to the first device status information, the device status information of the cloud device is updated; in response to the information acquisition instruction of the voice entry device, the current second device status information of the cloud device is determined, and the second device status information is fed back to the voice entry device. Through the embodiment of the present invention, the load of the Internet of Things server can be reduced while maintaining the real-time status of the smart home device.
[0079] Reference Figure 2 , shows a flowchart of another method for interacting with smart home devices according to an embodiment of the present invention, which may include the following steps:
[0080] Step 201: wake up the smart home device in response to a device wake-up instruction from a voice entry device.
[0081] In one embodiment of the present invention, the device wake-up instruction is an instruction generated by the voice entry device based on the user's voice interaction operation.
[0082] In some feasible embodiments, the device wake-up instruction may be an instruction generated by the voice entry device based on the user's voice interaction operation; wherein the voice interaction operation may refer to the operation of the user saying a wake-up word to the voice entry device.
[0083] The information acquisition instruction may also be an instruction generated by the voice entry device based on the user's voice interaction operation; wherein, the voice interaction operation used to generate the device wake-up instruction may be different from the voice interaction operation used to generate the information acquisition instruction. For example: the voice interaction operation used to generate the device wake-up instruction may be "Xiaodu Xiaodu", and the voice interaction operation used to generate the information acquisition instruction may be "Check the current air quality". The embodiments of the present invention do not limit this.
[0084] When the user needs to control the smart home device or view the information of the smart home device, the user needs to wake up the smart home device through the voice entry device first.
[0085] After generating a device wake-up instruction, the voice entry device can send the device wake-up instruction to the Internet of Things server; after receiving the device wake-up instruction, the Internet of Things server can respond to the device wake-up instruction and wake up the corresponding smart home device.
[0086] After detecting the device wake-up instruction, the IoT server may first wake up the smart home device and obtain the current first device status information of the smart home device from the smart home device.
[0087] Step 202: Continuously obtain current first device status information of the smart home device from the smart home device at a preset time interval.
[0088] In some feasible embodiments, after the smart home device is awakened, the Internet of Things server can continuously obtain the current first device status information of the smart home device from the smart home device at a preset time interval, so as to maintain the real-time nature of the device status information of the cloud device.
[0089] In an embodiment of the present invention, the first device status information includes environmental information acquired by the smart home device.
[0090] In some feasible embodiments, the first device status information may include environmental information obtained by the smart home device, such as temperature and humidity, PM (Particulate Matter) 2.5, and light intensity, which is not limited in this embodiment of the present invention.
[0091] Step 203: Update the device status information of the cloud device according to the latest first device status information currently obtained.
[0092] Every time the IoT server receives a first device status information, it can use the latest first device information obtained to update the device status information of the cloud device to ensure the real-time nature of the device status information of the cloud device.
[0093] Step 204: In response to the information acquisition instruction of the voice entry device, determine the current second device status information of the cloud device, and feed back the second device status information to the voice entry device.
[0094] In actual applications, after completing the wake-up, if the user wants to obtain the device status information of the smart home device, the user can further perform the operation of obtaining the device status information; the voice entry device can generate an information acquisition instruction in response to the operation, and send the information acquisition instruction to the Internet of Things server.
[0095] After receiving the information acquisition instruction, the Internet of Things server can respond to the information acquisition instruction to determine the current second device status information of the cloud device. The second device status information is based on the device status information determined based on the latest cloud device after the cloud device is updated by the first device status information.
[0096] After determining the second device status information, the IoT server may return the second device status information to the voice entry device. The voice entry device may perform subsequent data processing based on the second device status information; or, the voice entry device may also display the second device status information to the user, which is not limited in the embodiment of the present invention.
[0097] In the embodiment of the present invention, in response to the device wake-up instruction of the voice entry device, the smart home device is woken up; at a preset time interval, the current first device status information of the smart home device is continuously obtained from the smart home device; according to the latest first device status information currently obtained, the device status information of the cloud device is updated; in response to the information acquisition instruction of the voice entry device, the current second device status information of the cloud device is determined, and the second device status information is fed back to the voice entry device. Through the embodiment of the present invention, the load of the Internet of Things server can be reduced while maintaining the real-time status of the smart home device.
[0098] Reference Figure 3 , shows a flowchart of another method for interacting with smart home devices according to an embodiment of the present invention, which may include the following steps:
[0099] Step 301: wake up the smart home device in response to a device wake-up instruction from a voice entry device.
[0100] When the user needs to control the smart home device or view the information of the smart home device, the user needs to wake up the smart home device through the voice entry device first.
[0101] After generating a device wake-up instruction, the voice entry device can send the device wake-up instruction to the Internet of Things server; after receiving the device wake-up instruction, the Internet of Things server can respond to the device wake-up instruction and wake up the corresponding smart home device.
[0102] After detecting the device wake-up instruction, the IoT server may first wake up the smart home device and obtain the current first device status information of the smart home device from the smart home device.
[0103] Step 302: Continuously obtain current first device status information of the smart home device from the smart home device at a preset time interval.
[0104] In some feasible embodiments, after the smart home device is awakened, the Internet of Things server can continuously obtain the current first device status information of the smart home device from the smart home device at a preset time interval, so as to maintain the real-time nature of the device status information of the cloud device.
[0105] Step 303: When the duration of obtaining the current first device status information of the smart home device from the smart home device continues for a preset duration, stop obtaining the current first device status information of the smart home device from the smart home device.
[0106] In some feasible embodiments, in order to avoid excessive pressure on the IoT server, the smart home device can be set to only continue to report device status information for a preset time after being awakened.
[0107] Specifically, the smart home device can be set to continuously upload the first device status information to the Internet of Things server at a preset time interval after being awakened, and the duration is a preset time length; for example, the preset time interval can be 30s, and the preset duration can be 5 minutes.
[0108] When it is detected that the duration of obtaining the current first device status information of the smart home device from the smart home device continues for a preset duration, obtaining the current first device status information of the smart home device from the smart home device may be stopped.
[0109] For example, after waking up the smart home device, the voice entry device can also start a countdown, and the countdown duration is a preset duration; when the voice function is used again before the countdown ends, the smart home device may no longer be woken up (because within the preset duration, the smart home device is in an awake state and is continuously uploading device status information to the IoT server, so it does not need to be woken up again).
[0110] Step 304: Update the device status information of the cloud device according to the latest first device status information currently obtained.
[0111] Every time the IoT server receives a first device status information, it can use the latest first device information obtained to update the device status information of the cloud device to ensure the real-time nature of the device status information of the cloud device.
[0112] Step 305: In response to the information acquisition instruction of the voice entry device, determine the current second device status information of the cloud device, and feed back the second device status information to the voice entry device.
[0113] In actual applications, after completing the wake-up, if the user wants to obtain the device status information of the smart home device, the user can further perform the operation of obtaining the device status information; the voice entry device can generate an information acquisition instruction in response to the operation, and send the information acquisition instruction to the Internet of Things server.
[0114] After receiving the information acquisition instruction, the Internet of Things server can respond to the information acquisition instruction to determine the current second device status information of the cloud device. The second device status information is based on the device status information determined based on the latest cloud device after the cloud device is updated by the first device status information.
[0115] After determining the second device status information, the IoT server may return the second device status information to the voice entry device. The voice entry device may perform subsequent data processing based on the second device status information; or, the voice entry device may also display the second device status information to the user, which is not limited in the embodiment of the present invention.
[0116] In an embodiment of the present invention, the above method may further include the following steps:
[0117] When receiving the information acquisition instruction, determine the time difference between the timestamp of the current second device status information of the cloud device and the current time; when the time difference is not less than the preset time difference, re-acquire the current first device status information of the smart home device from the smart home device; when the time difference is less than the preset time difference, feedback the second device status information to the voice entry device.
[0118] In some feasible embodiments, when receiving an information acquisition instruction, in order to ensure that the device status information of the cloud device fed back is the latest, the timestamp of the current second device status information of the cloud device and the current time of the current IoT server can be determined first.
[0119] Then, the IoT server may calculate the time difference between the timestamp of the current second device status information of the cloud device and the current time.
[0120] If the time difference is not less than the preset time difference, it can be determined that the device status information is not the latest; at this time, the current first device status information of the smart home device can be obtained from the smart home device again, and the device status information of the cloud device can be updated using the first device status information to determine the second device status information of the cloud device.
[0121] On the contrary, if the time difference is less than the preset time difference, it can be determined that the device status information is the latest; at this time, the Internet of Things server can directly feedback the second device status information to the voice entry device.
[0122] In one embodiment of the present invention, when reacquiring the current first device status information of the smart home device from the smart home device, the method further includes:
[0123] When the current first device status information of the smart home device is re-acquired from the smart home device, if the first device status information is not re-acquired for more than a first preset time, query waiting information is fed back to the voice entry device.
[0124] In some feasible embodiments, when re-obtaining the current first device status information of the smart home device from the smart home device, the acquisition may time out due to network problems; at this time, it can be determined whether the first device status information has not been re-obtained for more than a first preset time period.
[0125] If it is determined that the first device status information is not re-acquired within the first preset time, query waiting information can be fed back to the voice entry device to prompt the user that the current network is not good and it takes a longer time to obtain the device status information of the smart home device.
[0126] In one embodiment of the present invention, when reacquiring the current first device status information of the smart home device from the smart home device, the method further includes:
[0127] When the current first device status information of the smart home device is re-acquired from the smart home device, if the first device status information is not re-acquired for more than a second preset time period, device offline information is fed back to the voice entry device.
[0128] In some feasible embodiments, when re-acquiring the current first device status information of the smart home device from the smart home device, the acquisition may time out due to network problems, and in this case, it can be determined whether the first device status information is not re-acquired for more than a second preset time period, wherein the first preset time period is less than the second preset time period.
[0129] If it is determined that the first device status information is not re-acquired within the second preset time period, the device offline information may be fed back to the voice entry device to avoid the user waiting for a long time.
[0130] In one embodiment of the present invention, when reacquiring the current first device status information of the smart home device from the smart home device, the method further includes:
[0131] When the current first device status information of the smart home device is re-acquired from the smart home device, if the first device status information is not re-acquired for more than a preset number of times, the device offline information is fed back to the voice entry device.
[0132] In some feasible embodiments, when re-obtaining the current first device status information of the smart home device from the smart home device, the acquisition may time out due to network problems; at this time, it can be determined whether the first device status information has not been re-obtained for more than a preset number of times.
[0133] If it is determined that the first device status information is not re-acquired within the second preset time period, the device offline information may be fed back to the voice entry device to avoid the user waiting for a long time.
[0134] For example, Figure 4 As shown, when waking up the voice entry device, it can be detected whether it has been more than 5 minutes since the first wake-up; if more, the smart home device is reactivated and the smart home device reports the device status information.
[0135] On the contrary, if it does not exceed, it can be determined whether the smart home device is in a cloud state and whether the cloud device is not offline and not real-time; if so, wait for a short time and then query again to obtain the latest device status information of the cloud device.
[0136] In actual applications, when using voice services, after waking up, you need to speak, convert voice to text, and understand the text intention. Only after knowing the user's intention can you determine whether to operate or query smart home devices, and then query the cloud devices. The multiple connections established in this process and the time-consuming business processing are definitely faster for the device to report its status once in the same wifi network environment. Of course, non-ideal situations must also be considered. For example, the smart home device is equipped with another wifi and the wifi network latency is particularly high, resulting in the voice service reaching the device query step. The status has not been reported to the cloud device. Therefore, the following additional operations are required:
[0137] After confirming that the user intends to query or control smart home devices, the voice service queries the IoT server for the device status information of the corresponding cloud device, and determines whether the difference between the last reported timestamp in the device status information and the current time is within the real-time threshold (generally 1.5 reporting intervals, for example, if the report is once every 30 seconds, the real-time threshold is 45 seconds). When the voice service finds that the difference exceeds the threshold, it will wait for a short time (500 milliseconds to 1 second) to query again. If the latest information is still not obtained, it will reply to the user "Device status query, please try again later". If the smart home device reports the status slowly due to network latency, the status can generally be checked when the voice function is used for the second time, unless the smart home device is offline (Briefly explain how the IoT server determines the offline of smart home devices. It will retry several times to let the device actively report the status, generally not more than 3 times. If the smart home device does not respond, it will be judged as offline. The expected time for this process is 2.5 reporting intervals. During this time, it is inevitable to avoid the voice reply "querying device status" and cannot directly reply "device offline")
[0138] In the embodiment of the present invention, in response to the device wake-up instruction of the voice entry device, the smart home device is woken up; at a preset time interval, the current first device status information of the smart home device is continuously obtained from the smart home device; when the duration of obtaining the current first device status information of the smart home device from the smart home device continues for a preset duration, the current first device status information of the smart home device is stopped from being obtained from the smart home device; according to the latest first device status information currently obtained, the device status information of the cloud device is updated; in response to the information acquisition instruction of the voice entry device, the current second device status information of the cloud device is determined, and the second device status information is fed back to the voice entry device. Through the embodiment of the present invention, the load of the Internet of Things server can be reduced while maintaining the real-time status of the smart home device.
[0139] It should be noted that, for the sake of simplicity, the method embodiments are described as a series of action combinations, but those skilled in the art should be aware that the embodiments of the present invention are not limited by the order of the actions described, because according to the embodiments of the present invention, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily required by the embodiments of the present invention.
[0140] Reference Figure 5 , shows a schematic diagram of the structure of an interactive device for smart home devices according to an embodiment of the present invention, which is applied to an Internet of Things server, in which a cloud device is deployed for smart home devices. Figure 5 As shown, the interactive device for smart home devices may include the following modules:
[0141] An acquisition module 501 is used to wake up the smart home device in response to a device wake-up instruction of the voice entry device, and obtain current first device status information of the smart home device from the smart home device;
[0142] An updating module 502 is used to update the device status information of the cloud device according to the first device status information;
[0143] The first feedback module 503 is used to respond to the information acquisition instruction of the voice entry device, determine the current second device status information of the cloud device, and feed back the second device status information to the voice entry device.
[0144] In an optional embodiment of the present invention, the acquisition module 501 is used to continuously acquire the current first device status information of the smart home device from the smart home device at a preset time interval;
[0145] The updating module 502 is used to update the device status information of the cloud device according to the latest first device status information currently obtained.
[0146] In an optional embodiment of the present invention, the device further comprises:
[0147] The stopping module is used to stop obtaining the current first device status information of the smart home device from the smart home device when the duration of obtaining the current first device status information of the smart home device from the smart home device continues for a preset duration.
[0148] In an optional embodiment of the present invention, the device further comprises:
[0149] The time difference calculation module is used to determine the time difference between the timestamp of the current second device status information of the cloud device and the current time when receiving the information acquisition instruction; when the time difference is not less than the preset time difference, re-acquire the current first device status information of the smart home device from the smart home device; when the time difference is less than the preset time difference, feedback the second device status information to the voice entry device.
[0150] In an optional embodiment of the present invention, the device further comprises:
[0151] The second feedback module is used to feedback query waiting information to the voice entry device when re-obtaining the current first device status information of the smart home device from the smart home device, when the first device status information of the smart home device is not re-obtained within a first preset time.
[0152] In an optional embodiment of the present invention, the device further comprises:
[0153] The third feedback module is used to feedback device offline information to the voice entry device when re-obtaining the current first device status information of the smart home device from the smart home device, when the first device status information of the smart home device is not re-obtained within a second preset time.
[0154] In an optional embodiment of the present invention, the device further comprises:
[0155] The fourth feedback module is used to feedback device offline information to the voice entry device when re-obtaining the current first device status information of the smart home device from the smart home device, and when the first device status information of the smart home device is not re-obtained for more than a preset number of times.
[0156] In an optional embodiment of the present invention, the device wake-up instruction is an instruction generated by the voice entry device based on the user's voice interaction operation.
[0157] In an optional embodiment of the present invention, the first device status information includes environmental information acquired by the smart home device.
[0158] In the embodiment of the present invention, in response to the device wake-up instruction of the voice entry device, the smart home device is woken up, and the current first device status information of the smart home device is obtained from the smart home device; according to the first device status information, the device status information of the cloud device is updated; in response to the information acquisition instruction of the voice entry device, the current second device status information of the cloud device is determined, and the second device status information is fed back to the voice entry device. Through the embodiment of the present invention, the load of the Internet of Things server can be reduced while maintaining the real-time status of the smart home device.
[0159] An embodiment of the present invention further provides an electronic device, including a processor, a memory, and a computer program stored in the memory and capable of running on the processor. When the computer program is executed by the processor, the above-mentioned interaction method for smart home devices is implemented.
[0160] An embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the above-mentioned interaction method for smart home devices is implemented.
[0161] As for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0162] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.
[0163] Those skilled in the art will appreciate that the embodiments of the present invention may be provided as methods, devices, or computer program products. Therefore, the embodiments of the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the embodiments of the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.
[0164] The embodiments of the present invention are described with reference to the flowcharts and / or block diagrams of the methods, terminal devices (systems), and computer program products according to the embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of the processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing terminal device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing terminal device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0165] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing terminal device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0166] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal device so that a series of operating steps are executed on the computer or other programmable terminal device to produce a computer-implemented process, thereby providing instructions for executing on the computer or other programmable terminal device to implement the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0167] Although the preferred embodiments of the present invention have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the embodiments of the present invention.
[0168] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or terminal device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or terminal device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or terminal device including the elements.
[0169] The above provides a detailed introduction to an interaction method for smart home devices, an interaction device for smart home devices, an electronic device and a computer-readable storage medium. Specific examples are used herein to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. At the same time, for those skilled in the art, according to the idea of the present invention, there will be changes in the specific implementation methods and application scopes. In summary, the content of this specification should not be understood as limiting the present invention.
Claims
1. An interactive method for smart home devices, characterized in that: Applied to an Internet of Things server, in which a cloud device is deployed for the smart home device, the method includes: In response to a device wake-up instruction of the voice entry device, wake up the smart home device, and obtain current first device status information of the smart home device from the smart home device; According to the first device status information, updating the device status information of the cloud device; In response to the information acquisition instruction of the voice entry device, the current second device status information of the cloud device is determined, and the second device status information is fed back to the voice entry device.
2. The method according to claim 1, characterized in that The obtaining, from the smart home device, current first device status information of the smart home device includes: At a preset time interval, continuously obtaining the current first device status information of the smart home device from the smart home device; The updating of the device status information of the cloud device according to the first device status information includes: The device status information of the cloud device is updated according to the latest first device status information currently acquired.
3. The method according to claim 2, characterized in that The method further comprises: When the duration of obtaining the current first device status information of the smart home device from the smart home device continues for a preset duration, stopping obtaining the current first device status information of the smart home device from the smart home device.
4. The method according to claim 3, characterized in that The method further comprises: Upon receiving the information acquisition instruction, determining a time difference between a timestamp of the current second device status information of the cloud device and the current time; When the time difference is not less than a preset time difference, reacquiring the current first device status information of the smart home device from the smart home device; When the time difference is less than a preset time difference, the second device status information is fed back to the voice entry device.
5. The method according to claim 4, characterized in that When reacquiring the current first device status information of the smart home device from the smart home device, the method further includes: When the current first device status information of the smart home device is re-acquired from the smart home device, if the first device status information is not re-acquired for more than a first preset time, query waiting information is fed back to the voice entry device.
6. The method according to claim 4, characterized in that When reacquiring the current first device status information of the smart home device from the smart home device, the method further includes: When the current first device status information of the smart home device is re-acquired from the smart home device, if the first device status information is not re-acquired for more than a second preset time period, device offline information is fed back to the voice entry device.
7. The method according to claim 4, characterized in that When reacquiring the current first device status information of the smart home device from the smart home device, the method further includes: When the current first device status information of the smart home device is obtained again from the smart home device, if the first device status information is not obtained again for more than a preset number of times, device offline information is fed back to the voice entry device.
8. The method according to claim 1, characterized in that The device wake-up instruction is an instruction generated by the voice entry device based on the user's voice interaction operation.
9. The method according to claim 1, characterized in that: The first device status information includes environmental information acquired by the smart home device.
10. An interactive device for smart home devices, characterized in that: Applied to an Internet of Things server, in which a cloud device is deployed for the smart home device, the device includes: an acquisition module, configured to wake up the smart home device in response to a device wake-up instruction of a voice entry device, and acquire current first device status information of the smart home device from the smart home device; An updating module, configured to update the device status information of the cloud device according to the first device status information; The first feedback module is used to respond to the information acquisition instruction of the voice entry device, determine the current second device status information of the cloud device, and feed back the second device status information to the voice entry device.
11. An electronic device, characterized in that: The invention comprises a processor, a memory and a computer program stored in the memory and capable of running on the processor, wherein when the computer program is executed by the processor, an interaction method for a smart home device as claimed in any one of claims 1 to 9 is implemented.
12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the interaction method for a smart home device as claimed in any one of claims 1 to 9 is implemented.
Citation Information
Patent Citations
Method and device for waking up smart home equipment, and computer storage medium
CN109450747A
Voice interaction method, device and system
CN111402900A
Equipment shadow control method and device, storage medium and electronic equipment
CN113037771A
Smart home awakening method and smart home platform
CN114373459A
Cited By
Equipment control method and device, equipment, storage medium and program product
CN122454975A