A device control method and apparatus
By judging the device application scenario in the Mesh network, if there is no downlink control message, it will enter the sleep state and only work when an event is triggered. Combined with setting it as an ordinary Mesh node, the radio frequency transceiver frequency and duration can be controlled, which solves the problem of strategic shutdown of LPN node radio frequency transceiver. To solve the problem of poor power consumption, low-power device control is achieved.
Patent Information
- Application Number
- CN202010632119.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-07-03
- Publication Date
- 2024-08-30
- Estimated Expiration
- 2040-07-03
AI Technical Summary
Strategically shutting down radio frequency transceivers based on low-pass network (LPN) nodes cannot effectively reduce power consumption, especially on battery-powered devices. It is difficult to achieve extremely low power consumption.
By judging whether there is a downlink control message on the Mesh network device, if not, it will enter the sleep state. It will only enter the working state when a trigger event is detected, and set the device as an ordinary Mesh node to control the frequency and duration of radio frequency transmission and reception, reducing working time.
It effectively reduces the average power consumption of the device, improves the battery life, and the power consumption is much lower than that of traditional LPN nodes.
Smart Images

Figure CN111800847B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of information processing, and in particular to a device control method and apparatus. Background Art
[0002] The BLE Mesh protocol is a broadcast communication protocol based on Bluetooth technology. In order to support low-power devices, the Mesh protocol specifies a low-pass network (LPN) node, which can strategically shut down radio frequency transmission and reception to reduce power consumption. Since LPN nodes need to periodically restore radio frequency transmission and reception to receive downlink messages from their friend nodes, their average power consumption cannot be extremely low, especially for some devices that use batteries as power sources.
[0003] With regard to the problem in the related art that the power consumption reduction effect of strategically shutting down radio frequency transmission and reception based on LPN nodes is poor, no solution has been proposed yet. Summary of the invention
[0004] The embodiments of the present invention provide a device control method and apparatus to at least solve the problem in the related art that the power consumption is poorly reduced by strategically shutting down radio frequency transmission and reception based on LPN nodes.
[0005] According to an embodiment of the present invention, there is provided a device control method, comprising:
[0006] Determine whether there is a downlink control message in the application scenario of the device in the Mesh network;
[0007] If the judgment result is no, controlling the device to enter a sleep state;
[0008] When a triggering event of the device is detected, the device is controlled to enter a working state.
[0009] Optionally, controlling the device to enter a sleep state includes:
[0010] The device is controlled to enter the sleep state by turning off the radio frequency transmission and reception of the device.
[0011] Optionally, the method further comprises:
[0012] Obtaining the activation frequency and activation duration of the radio frequency transceiver pre-set for the device;
[0013] The device is controlled to be in the working state within the on-time at the on-frequency, and enter the sleeping state after the on-time.
[0014] Optionally, before controlling the device to enter a sleep state, the method further includes:
[0015] Set the device as a normal Mesh node.
[0016] Optionally, controlling the device to enter a working state includes:
[0017] By turning on the radio frequency transmission and reception of the device, the device is controlled to enter a working state.
[0018] Optionally, the activation frequency is once a day, once every two days, once every three days, once every five days, once every five days, or once a week.
[0019] According to another embodiment of the present invention, there is also provided a device control apparatus, comprising:
[0020] A judgment module, used to judge whether there is a downlink control message in the application scenario of the device in the Mesh network;
[0021] A first control module, configured to control the device to enter a sleep state if the judgment result is no;
[0022] The second control module is used to control the device to enter a working state when a triggering event of the device is detected.
[0023] Optionally, the first control module includes:
[0024] The first control submodule is used to control the device to enter the sleep state by turning off the radio frequency transmission and reception of the device.
[0025] Optionally, the device further comprises:
[0026] An acquisition module, used to acquire the activation frequency and activation duration of the radio frequency transceiver pre-set for the device;
[0027] The third control module is used to control the device to be in the working state within the startup time at the startup frequency, and to enter the sleeping state after the startup time.
[0028] Optionally, the device further comprises:
[0029] A setting module is used to set the device as a common Mesh node.
[0030] Optionally, the second control module includes:
[0031] The second control submodule is used to control the device to enter a working state by turning on the radio frequency transmission and reception of the device.
[0032] Optionally, the activation frequency is once a day, once every two days, once every three days, once every five days, once every five days, or once a week.
[0033] According to yet another embodiment of the present invention, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the steps of any of the above method embodiments when run.
[0034] According to yet another embodiment of the present invention, there is provided an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.
[0035] Through the present invention, it is determined whether there is a downlink control message in the application scenario of the device in the Mesh network; when the determination result is no, the device is controlled to enter a sleep state; when a triggering event of the device is detected, the device is controlled to enter a working state, which can solve the problem of poor effect of reducing power consumption by strategically shutting down radio frequency transmission and reception based on LPN nodes in the related technology. By controlling the device without a downlink control message to enter a sleep state, the device will only return to the working state when a triggering event is detected, and the average power consumption of the device can be reduced by reducing the working time to improve the battery life. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:
[0037] Figure 1 is a hardware structure block diagram of a mobile terminal of a device control method according to an embodiment of the present invention;
[0038] Figure 2 is a flow chart of a device control method according to an embodiment of the present invention;
[0039] Figure 3 is a block diagram of a device control apparatus according to an embodiment of the present invention;
[0040] Figure 4 is a block diagram of a device control apparatus according to a preferred embodiment of the present invention. DETAILED DESCRIPTION
[0041] The present invention will be described in detail below with reference to the accompanying drawings and in combination with embodiments. It should be noted that the embodiments and features in the embodiments of the present application can be combined with each other without conflict.
[0042] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.
[0043] Example 1
[0044] The method embodiment provided in the first embodiment of the present application can be executed in a mobile terminal, a computer terminal or a similar computing device. Taking running on a mobile terminal as an example, Figure 1 is a hardware structure block diagram of a mobile terminal of a device control method according to an embodiment of the present invention, such as Figure 1 As shown, the mobile terminal may include one or more ( Figure 1 Only one is shown in the figure) a processor 102 (the processor 102 may include but is not limited to a processing device such as a microprocessor MCU or a programmable logic device FPGA) and a memory 104 for storing data. Optionally, the mobile terminal may also include a transmission device 106 and an input / output device 108 for communication functions. It can be understood by those skilled in the art that Figure 1 The structure shown is only for illustration and does not limit the structure of the mobile terminal. Figure 1 More or fewer components as shown, or with Figure 1 Different configurations are shown.
[0045] The memory 104 can be used to store computer programs, for example, software programs and modules of application software, such as the computer program corresponding to the device control method in the embodiment of the present invention. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, that is, to implement the above method. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include a memory remotely arranged relative to the processor 102, and these remote memories may be connected to the mobile terminal via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0046] The transmission device 106 is used to receive or send data via a network. The specific example of the above network may include a wireless network provided by a communication provider of the mobile terminal. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, referred to as NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 106 can be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.
[0047] In this embodiment, a device control method running on the above mobile terminal or network architecture is provided. Figure 2 is a flow chart of a device control method according to an embodiment of the present invention. Figure 2 As shown, the process includes the following steps:
[0048] Step S202, determining whether there is a downlink control message in the application scenario of the device in the Mesh network;
[0049] Step S204, if the judgment result is no, control the device to enter a sleep state;
[0050] Furthermore, the above step S204 may specifically include: controlling the device to enter the sleep state by turning off the radio frequency transceiver of the device.
[0051] Step S206: When a triggering event of the device is detected, the device is controlled to enter a working state.
[0052] Furthermore, the above step S206 may specifically include: controlling the device to enter a working state by turning on the radio frequency transceiver of the device.
[0053] Through the above steps S202 to S206, it is determined whether there is a downlink control message in the application scenario of the device in the Mesh network; when the judgment result is no, the device is controlled to enter a sleep state; when a trigger event of the device is detected, the device is controlled to enter a working state, which can solve the problem of poor effect of reducing power consumption by strategically shutting down RF transceiver based on LPN nodes in related technologies. By controlling the device without downlink control messages to enter a sleep state, it will only return to the working state when a trigger event is detected, and by reducing the working time, the average power consumption of the device is reduced to improve the battery life.
[0054] In an optional embodiment, the activation frequency and activation duration of the radio frequency transceiver pre-set for the device are obtained; the device is controlled to be in the working state within the activation duration by the activation frequency, and enters the sleeping state after the activation duration. The activation frequency in the embodiment of the present invention can be once a day, once every two days, once every three days, once every five days, once every five days, once a week, etc., and the activation duration can be 5 seconds, 10 seconds, 20 seconds, etc.
[0055] In another optional embodiment, before controlling the device to enter a sleep state, the device is set as a common Mesh node, that is, a low-power node of LPN is abandoned. Compared with the LPN-based node in the prior art, the device is controlled to enter a sleep state after being set as a common Mesh node, and is controlled to enter a working state only when a trigger event is detected, which greatly reduces power consumption.
[0056] In a Mesh-based smart home network, there is a type of device (such as a remote control, a sensor) whose application scenario does not have downlink control messages, allowing it to shut down the RF transceiver for a long time and enter a sleep state. This technical solution takes advantage of this feature and adds it to the Mesh network as a normal Mesh node. It stays in a sleep state for a long time during its operation, and only when it needs to report a status or event (such as a sensor trigger or a remote control key event occurs locally, waking up the device through an interrupt), will it restart the RF transceiver and send a message.
[0057] In addition, there is an IV update process in the Mesh network. In order to avoid missing the IV update and losing the network, the device should also perform an IV update process at a certain interval (longer, such as once a day or a week). This process has a high instantaneous power consumption, but has a small impact on the average power consumption. The overall power consumption is still far lower than the average power consumption of LPN nodes. The method for achieving low node power consumption in a Mesh network includes the following steps:
[0058] Determine whether the application scenario of the device in the Mesh network includes a downlink control message, if the device does not have a downlink control message, the device is a predetermined device;
[0059] Setting the predetermined device as a common Mesh node;
[0060] Turn off the radio frequency transmission and reception of the predetermined device and enter a sleep state;
[0061] When the predetermined device reports a state or event, the radio frequency transceiver of the predetermined device is turned on to send a message.
[0062] Furthermore, a preset radio frequency transceiver activation frequency and activation time are set for the predetermined device, and a password is refreshed, wherein the preset radio frequency transceiver activation frequency is from once a day to once a week.
[0063] This embodiment includes multiple devices in a Mesh network, among which devices such as door and window sensors, human body sensors and remote controls are predetermined devices without downlink control messages; in conventional Mesh network node settings, these devices are usually set as LPN nodes, which periodically restore RF transceiver to receive downlink messages from their friend nodes. Since their period t1 is short, assuming that the power consumed by each RF transceiver is p, the average power of the device's RF transceiver within unit time T is P1=p*(T / t1).
[0064] In the Mesh network node setting of the embodiment of the present invention, the device is set as a normal Mesh node and its RF transceiver is turned off to put it into a sleep state. Since the period t2 of actively triggering the sensor or remote control is relatively long, assuming that the power consumed by each RF transceiver is p, then within unit time T, the average power of the device's RF transceiver is P2=p*(T / t2).
[0065] Generally, t1 is significantly smaller than t2. Therefore, within a unit time T, the radio frequency receiving and transmitting power P2 of a device using the Mesh network node configuration of the present invention is significantly smaller than the radio frequency receiving and transmitting power P1 of a device using the conventional network node configuration.
[0066] Example 2
[0067] According to another embodiment of the present invention, there is also provided a device control apparatus, Figure 3 is a block diagram of a device control apparatus according to an embodiment of the present invention, such as Figure 3 As shown, including:
[0068] A determination module 32, used to determine whether there is a downlink control message in the application scenario of the device in the Mesh network;
[0069] The first control module 34 is used to control the device to enter a sleep state when the judgment result is no;
[0070] The second control module 36 is used to control the device to enter a working state when a triggering event of the device is detected.
[0071] Optionally, the first control module 34 includes:
[0072] The first control submodule is used to control the device to enter the sleep state by turning off the radio frequency transmission and reception of the device.
[0073] Figure 4 is a block diagram of a device control apparatus according to a preferred embodiment of the present invention, such as Figure 4 As shown, the device also includes:
[0074] An acquisition module 42 is used to acquire the activation frequency and activation duration of the radio frequency transceiver pre-set for the device;
[0075] The third control module 44 is used to control the device to be in the working state within the on-time at the on-frequency, and to enter the sleeping state after the on-time.
[0076] Optionally, the device further comprises:
[0077] A setting module is used to set the device as a common Mesh node.
[0078] Optionally, the second control module 36 includes:
[0079] The second control submodule is used to control the device to enter a working state by turning on the radio frequency transmission and reception of the device.
[0080] Optionally, the activation frequency is once a day, once every two days, once every three days, once every five days, once every five days, or once a week.
[0081] It should be noted that the above modules can be implemented by software or hardware. For the latter, it can be implemented in the following ways, but not limited to: the above modules are all located in the same processor; or the above modules are located in different processors in any combination.
[0082] Example 3
[0083] An embodiment of the present invention further provides a computer-readable storage medium, in which a computer program is stored, wherein the computer program is configured to execute the steps of any of the above method embodiments when running.
[0084] Optionally, in this embodiment, the storage medium may be configured to store a computer program for performing the following steps:
[0085] S1, determine whether there is a downlink control message in the application scenario of the device in the Mesh network;
[0086] S2, if the judgment result is no, controlling the device to enter a sleep state;
[0087] S3, when a triggering event of the device is detected, controlling the device to enter a working state.
[0088] Optionally, in this embodiment, the above-mentioned storage medium may include but is not limited to: a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk, and other media that can store computer programs.
[0089] Example 4
[0090] An embodiment of the present invention further provides an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.
[0091] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.
[0092] Optionally, in this embodiment, the processor may be configured to perform the following steps through a computer program:
[0093] S1, determine whether there is a downlink control message in the application scenario of the device in the Mesh network;
[0094] S2, if the judgment result is no, controlling the device to enter a sleep state;
[0095] S3, when a triggering event of the device is detected, controlling the device to enter a working state.
[0096] Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments and optional implementation modes, and this embodiment will not be described in detail here.
[0097] Obviously, those skilled in the art should understand that the above modules or steps of the present invention can be implemented by a general computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, and optionally, they can be implemented by a program code executable by a computing device, so that they can be stored in a storage device and executed by the computing device, and in some cases, the steps shown or described can be executed in a different order than here, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the present invention is not limited to any specific combination of hardware and software.
[0098] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A device control method, It is characterized in that include: Determine whether there is a downlink control message in the application scenario of the device in the Mesh network; If the judgment result is no, the device is set as a common Mesh node and the device is controlled to enter a sleep state; When a triggering event of the device is detected, controlling the device to enter a working state; Wherein, controlling the device to enter the sleep state comprises: controlling the device to enter the sleep state by turning off the radio frequency transceiver of the device; When a triggering event of the device is detected, controlling the device to enter a working state includes: When the predetermined device reports a state or event, the radio frequency transceiver of the predetermined device is turned on, and a message is sent. By turning on the radio frequency transceiver of the device, the device is controlled to enter a working state.
2. The method according to claim 1, It is characterized in that The method further comprises: Obtaining the activation frequency and activation duration of the radio frequency transceiver pre-set for the device; The device is controlled to be in the working state within the on-time at the on-frequency, and enter the sleeping state after the on-time.
3. The method according to claim 1, It is characterized in that The opening frequency is once a day, once every two days, once every three days, once every five days, once every five days, and once a week.
4. A device control device, It is characterized in that include: A judgment module, used to judge whether there is a downlink control message in the application scenario of the device in the Mesh network; A first control module, configured to, if the judgment result is negative, set the device to be a common Mesh node and control the device to enter a sleep state; A second control module, configured to control the device to enter a working state when a triggering event of the device is detected; Wherein, the first control module includes: A first control submodule, configured to control the device to enter the sleep state by turning off the radio frequency transceiver of the device; The second control module includes: The second control submodule is used to turn on the radio frequency transceiver of the predetermined device and send a message when the predetermined device reports a state or event, and control the device to enter a working state by turning on the radio frequency transceiver of the device.
5. A computer-readable storage medium, It is characterized in that The storage medium stores a computer program, wherein the computer program is configured to execute the method according to any one of claims 1 to 3 when executed.
6. An electronic device comprising a memory and a processor, It is characterized in that A computer program is stored in the memory, and the processor is configured to run the computer program to perform the method according to any one of claims 1 to 3.
Citation Information
Patent Citations
Greenhouse surroundings monitoring system based on ZigBee wireless sensor network
CN101140695A
Sensor equipment starting control method and device
CN110996288A
Intelligent home remote controller
CN205722369U
