CN117914634A - Method and device for sending control instruction, storage medium and electronic device - Google Patents

Method and device for sending control instruction, storage medium and electronic device Download PDF

Info

Publication number
CN117914634A
CN117914634A CN202311737038.2A CN202311737038A CN117914634A CN 117914634 A CN117914634 A CN 117914634A CN 202311737038 A CN202311737038 A CN 202311737038A CN 117914634 A CN117914634 A CN 117914634A
Authority
CN
China
Prior art keywords
control
controlled
control instruction
channel
control channel
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202311737038.2A
Other languages
Chinese (zh)
Inventor
董海涛
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Qingdao Haier Technology Co Ltd
Haier Smart Home Co Ltd
Haier Uplus Intelligent Technology Beijing Co Ltd
Original Assignee
Qingdao Haier Technology Co Ltd
Haier Smart Home Co Ltd
Haier Uplus Intelligent Technology Beijing Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Qingdao Haier Technology Co Ltd, Haier Smart Home Co Ltd, Haier Uplus Intelligent Technology Beijing Co Ltd filed Critical Qingdao Haier Technology Co Ltd
Priority to CN202311737038.2A priority Critical patent/CN117914634A/en
Publication of CN117914634A publication Critical patent/CN117914634A/en
Pending legal-status Critical Current

Links

Landscapes

  • Selective Calling Equipment (AREA)

Abstract

The application discloses a method and a device for sending control instructions, a storage medium and an electronic device, and relates to the technical field of smart families, wherein the method for sending the control instructions comprises the following steps: determining a target control channel corresponding to each controlled device in all the controlled devices; responding to a controlled request of each controlled device, and determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to a control zone bit of the controlled request and a channel type of a target control channel; by adopting the technical scheme, the technical problem of how to improve the sending efficiency of the control instructions when facing to the controlled equipment supporting different communication modes is solved.

Description

Method and device for sending control instruction, storage medium and electronic device
Technical Field
The application relates to the technical field of smart families, in particular to a method and a device for sending control instructions, a storage medium and an electronic device.
Background
At present, with the increasing popularity of intelligent home appliances, the number of intelligent home appliances in a user's home is increasing, and home appliances with multiple appliance models are likely to appear in the same user's home. In general, home appliances of different models have different communication methods, and it is necessary to perform packet control on the home appliances supporting the different communication methods. For example, in the related art, for a plurality of groups of lamp devices, there is a method of locally controlling a group of devices added to only a device supporting a single communication mode, that is, a method of limiting the lamp devices added to the same group to be under the same gateway and issuing different control instructions to the devices in the group under different communication types by a cloud, however, the two methods respectively support limited communication modes, cannot control all home appliances in a compatible manner, and a problem that control instructions are generated by using any method to all home appliances, so that device control omission or device control is easy to occur is also present.
Therefore, in the related art, when the controlled device supporting different communication methods is oriented, there is a technical problem of how to improve the transmission efficiency of the control command.
Aiming at the technical problem of how to improve the sending efficiency of control instructions when supporting controlled equipment with different communication modes in the related art, no effective solution has been proposed yet.
Disclosure of Invention
The embodiment of the application provides a method and a device for sending a control instruction, a storage medium and an electronic device, which are used for at least solving the technical problem of how to improve the sending efficiency of the control instruction in the related technology.
According to an embodiment of the present application, there is provided a method for transmitting a control instruction, including: determining a target control channel corresponding to each controlled device in all the controlled devices; responding to a controlled request of each controlled device, and determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to a control zone bit of the controlled request and a channel type of the target control channel; and sending the first control instruction or the second control instruction to each controlled device through the target control channel.
In an exemplary embodiment, determining a target control channel to which each of all the controlled devices belongs includes: acquiring the equipment state of each controlled equipment; under the condition that the equipment state of each controlled equipment is determined to be online, determining a first control channel corresponding to each controlled equipment; if each controlled device is determined to correspond to a plurality of first control channels, determining a second control channel with the highest priority from the plurality of first control channels; and determining the second control channel as the target control channel.
In an exemplary embodiment, determining, according to the control flag bit of the controlled request and the channel type of the target control channel, a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device, where the first control instruction includes: determining to generate the first control instruction under the condition that the control zone bit of the controlled request is determined to be used for indicating that each controlled device supports remote control and the channel type of the target control channel is determined to be an intra-group device control channel; or under the condition that the control zone bit of the controlled request is determined to be used for indicating that each controlled device does not support remote control and the channel type of the target control channel is determined to be the intra-group device control channel, determining to generate the second control instruction.
In an exemplary embodiment, sending the first control instruction to each controlled device through the target control channel includes: the first control instruction is sent to a gateway server of each controlled device, so that the gateway server sends the first control instruction to a first device gateway corresponding to each controlled device; the target control channel is generated at least through the gateway server of each controlled device and the first device gateway; and determining all controlled devices corresponding to the first device gateway, and sending the first control instruction to all the controlled devices corresponding to the first device gateway.
In an exemplary embodiment, sending the second control instruction to each controlled device through the target control channel includes: the second control instruction is sent to a second device gateway corresponding to each controlled device, wherein the target control channel is generated at least through the second device gateway; and determining all the controlled devices corresponding to the second device gateway, and sending the second control instruction to all the controlled devices corresponding to the second device gateway.
In an exemplary embodiment, sending the second control instruction to each controlled device through the target control channel includes: sending the second control instruction to the proxy equipment of each controlled equipment, wherein the target control channel is at least generated by the proxy equipment of each controlled equipment; and determining all the controlled devices proxied by the proxy device of each controlled device, and sending the second control instruction to all the controlled devices proxied by the proxy device of each controlled device.
In an exemplary embodiment, sending the second control instruction to each controlled device through the target control channel includes: the second control instruction is sent to a third device gateway corresponding to each controlled device, wherein the target control channel is at least generated through the third device gateway of each controlled device; and sending the second control instruction to all controlled devices corresponding to each third device gateway in the plurality of third device gateways under the condition that the plurality of third device gateways are determined to exist.
In an exemplary embodiment, after determining the first control instruction for remotely controlling each controlled device or the second control instruction for non-remotely controlling each controlled device according to the control flag bit of the controlled request and the channel type of the target control channel, the method further includes: determining to generate a third control instruction under the condition that the control zone bit of the controlled request is determined to be used for indicating that each controlled device supports remote control and the channel type of the target control channel is determined to be a non-intra-group device control channel; the third control instruction is sent to a cloud server corresponding to each controlled device through the target control channel, so that the cloud server forwards the third control instruction to each controlled device; the target control channel is generated at least through a cloud server corresponding to each controlled device; and under the condition that each controlled device responds to the third control instruction to send first response information to the cloud server, acquiring the first response information from the cloud server.
In an exemplary embodiment, after determining the first control instruction for remotely controlling each controlled device or the second control instruction for non-remotely controlling each controlled device according to the control flag bit of the controlled request and the channel type of the target control channel, the method further includes: determining to generate a fourth control instruction under the condition that the control zone bit of the controlled request is used for indicating that remote control is not supported and the channel type of the target control channel is determined to be a non-intra-group equipment control channel; transmitting the fourth control instruction to each controlled device through the target control channel; and receiving second response information sent by each controlled device based on the fourth control instruction, wherein the second response information comprises an execution result generated when each controlled device executes the fourth control instruction.
According to another aspect of the embodiment of the present application, there is also provided a device for sending a control instruction, including: the channel determining module is used for determining a target control channel corresponding to each controlled device in all the controlled devices; the instruction determining module is used for responding to the controlled request of each controlled device, and determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to the control zone bit of the controlled request and the channel type of the target control channel; and the instruction sending module is used for sending the first control instruction or the second control instruction to each controlled device through the target control channel.
According to still another aspect of the embodiments of the present application, there is also provided a computer-readable storage medium having a computer program stored therein, wherein the computer program is configured to execute the above-described transmission method of control instructions when executed.
According to still another aspect of the embodiments of the present application, there is further provided an electronic device including a memory, a processor, and a computer program stored on the memory and executable on the processor, wherein the processor executes the method for sending control instructions described above through the computer program.
In the embodiment of the application, the target control channel corresponding to each controlled device in all the controlled devices is determined; responding to a controlled request of each controlled device, and determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to a control zone bit of the controlled request and a channel type of the target control channel; sending the first control instruction or the second control instruction to each controlled device through the target control channel; according to the technical scheme, under the device grouping control scene, if a large number of devices exist in each group and different channel types are supported, the control instruction of the device can be generated based on the controlled request of the device and the channel types supported by the device, so that the device in the group is ensured not to have control omission and re-control, the technical problem of how to improve the sending efficiency of the control instruction is solved, the sending efficiency of the control instruction of the device in the group is improved, and the control efficiency of the device is further improved.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the application and together with the description, serve to explain the principles of the application.
In order to more clearly illustrate the embodiments of the application or the technical solutions of the prior art, the drawings which are used in the description of the embodiments or the prior art will be briefly described, and it will be obvious to a person skilled in the art that other drawings can be obtained from these drawings without inventive effort.
FIG. 1 is a schematic diagram of a hardware environment of a method for sending control instructions according to an embodiment of the present application;
FIG. 2 is a flow chart of a method of sending control instructions according to an embodiment of the application;
FIG. 3 is a flow chart of a method for sending control instructions according to an embodiment of the present application;
FIG. 4 is a flow chart (II) of a method for sending control instructions according to an embodiment of the present application;
Fig. 5 is a block diagram of a control instruction transmitting apparatus according to an embodiment of the present application.
Detailed Description
In order that those skilled in the art will better understand the present application, a technical solution in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present application without making any inventive effort, shall fall within the scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present application and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the application described herein may be implemented in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
According to an aspect of an embodiment of the present application, there is provided a method for transmitting a control instruction. The method for sending the control instruction is widely applied to full-house intelligent digital control application scenes such as intelligent Home (Smart Home), intelligent Home equipment ecology, intelligent Home (INTELLIGENCE HOUSE) ecology and the like. Alternatively, in the present embodiment, the above-described transmission method of the control instruction may be applied to a hardware environment constituted by the terminal device 102 and the server 104 as shown in fig. 1. As shown in fig. 1, the server 104 is connected to the terminal device 102 through a network, and may be used to provide services (such as application services and the like) for a terminal or a client installed on the terminal, a database may be set on the server or independent of the server, for providing data storage services for the server 104, and cloud computing and/or edge computing services may be configured on the server or independent of the server, for providing data computing services for the server 104.
The network may include, but is not limited to, at least one of: wired network, wireless network. The wired network may include, but is not limited to, at least one of: a wide area network, a metropolitan area network, a local area network, and the wireless network may include, but is not limited to, at least one of: WIFI (WIRELESS FIDELITY ), bluetooth. The terminal device 102 may not be limited to a PC, a mobile phone, a tablet computer, an intelligent air conditioner, an intelligent smoke machine, an intelligent refrigerator, an intelligent oven, an intelligent cooking range, an intelligent washing machine, an intelligent water heater, an intelligent washing device, an intelligent dish washer, an intelligent projection device, an intelligent television, an intelligent clothes hanger, an intelligent curtain, an intelligent video, an intelligent socket, an intelligent sound box, an intelligent fresh air device, an intelligent kitchen and toilet device, an intelligent bathroom device, an intelligent sweeping robot, an intelligent window cleaning robot, an intelligent mopping robot, an intelligent air purifying device, an intelligent steam box, an intelligent microwave oven, an intelligent kitchen appliance, an intelligent purifier, an intelligent water dispenser, an intelligent door lock, and the like.
In this embodiment, a method for sending a control instruction is provided and applied to the terminal device, and fig. 2 is a flowchart of a method for sending a control instruction according to an embodiment of the present application, where the flowchart includes the following steps:
Step S202, determining a target control channel corresponding to each controlled device in all the controlled devices;
Optionally, the target control channel may be determined according to a communication manner of the controlled device, for example. For the controlled device that may support different communication modes such as WIFI, zigBee, BLE mesh, etc., the target control channel may include, but is not limited to, a remote control channel, a mesh gateway channel, and a BLE mesh Proxy channel.
Correspondingly, the controlled devices aiming at different communication modes can comprise ZigBee devices, WIFI devices, BLE mesh devices and the like.
For the ZigBee device, if there is a situation that the ZigBee gateway is required to be switched, the ZigBee network configuration must be performed again, and in this process, the ZigBee device cannot automatically switch the gateway. The ZigBee device supports two control channels, namely a remote control channel and a local control channel.
For the WIFI devices, the embodiment considers the one-to-one situation, that is, 1 WIFI module is only used for 1 WIFI device, and because the device model involved in modifying the WIFI module is too many, the modification process is complicated, in the embodiment, whether the process of controlling the WIFI device based on the cloud or the process of controlling the WIFI device based on uSDK is separately controlled according to the common device which does not support group control, the WIFI module is not required to be modified, and different WIFI devices can be controlled only by replacing the WIFI module.
For the BLE mesh device, since the BLE mesh supports the mesh protocol, the automatic switching of the gateway can be realized without the need of network reconfiguration. When BLE mesh equipment of the intra-group equipment is controlled based on uSDK, the BLE mesh equipment supports 3 control channels such as a remote control channel, a mesh gateway control channel, a BLE mesh Proxy control channel and the like.
Note that, the remote control channel represents a control instruction sent by the uSDK via the cloud, and the mesh gateway control channel, the table mesh Proxy control channel, and the like represent control instructions directly sent locally by uSDK.
Step S204, responding to the controlled request of each controlled device, and determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to the control zone bit of the controlled request and the channel type of the target control channel;
Step S206, sending, through the target control channel, the first control instruction or the second control instruction to each controlled device.
Through the steps, determining a target control channel corresponding to each controlled device in all the controlled devices; responding to a controlled request of each controlled device, and determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to a control zone bit of the controlled request and a channel type of the target control channel; and sending the first control instruction or the second control instruction to each controlled device through the target control channel, and under the device group control scene, if a large number of devices exist in each group and support different channel types, generating the control instruction of the devices based on the controlled request of the devices and the channel types supported by the devices so as to ensure that the devices in the group do not generate control omission and control again, thereby not only solving the technical problem of how to improve the sending efficiency of the control instruction when facing the controlled devices supporting different communication modes, but also improving the sending efficiency of the control instruction of the devices in the group and further improving the control efficiency of the devices.
Optionally, in an embodiment, the control channels of the devices in the group may be compatible with device control channels respectively supported by the WIFI device, the ZigBee device, and the BLE mesh device, for example. If devices supporting other Communication modes such as NFC (NEAR FIELD Communication) technology are newly added in the group, the channel type of the target control channel needs to be expanded again.
Optionally, based on the technical solution of the foregoing embodiment, in an application scenario of grouping control home appliances, compensation control may be performed on home appliances that are not grouped while grouping control is performed on grouped home appliances, so as to improve the probability of performing overall control on all home appliances. Specifically, the household appliances supporting grouping are grouped to obtain multiple groups of household appliances, for any group of household appliances including household appliances supporting different channel types, a control instruction of the household appliances can be generated for any group of household appliances based on a controlled request of the household appliances and the channel types supported by the household appliances, for example, the multiple groups of household appliances are taken as lamp groups, for a ZigBee lamp in any lamp group, a ZigBee lamp can be determined to be a device control channel in the group, and the ZigBee lamp can support remote control/non-remote control, and then a control instruction for the ZigBee lamp can be generated and the ZigBee lamp can be controlled at cloud/local. Or for the BLE mesh lamp included in any lamp group, the BLE mesh lamp can be determined to be an equipment control channel in the group, the BLE mesh lamp can support remote control/non-remote control, then a control instruction for the BLE mesh lamp can be generated, and the BLE mesh lamp is controlled at the cloud/local. The local control process can be realized through a mesh gateway channel or a table mesh Proxy channel. And for the household appliances which do not support grouping, generating a control instruction of the household appliances according to the channel types supported by the household appliances, and independently compensating and controlling the household appliances which do not support grouping. For example, for independent lamps outside the lamp group, independent control can be performed with reference to the WIFI lamps.
In an exemplary embodiment, for the implementation process of determining, in the step S202, the target control channel to which each of all the controlled devices belongs, the implementation process may be completed by the following technical scheme, and the specific steps include: step S11, acquiring the equipment state of each controlled equipment; step S12, under the condition that the equipment state of each controlled equipment is determined to be online, determining a first control channel corresponding to each controlled equipment; step S13, if each controlled device is determined to correspond to a plurality of first control channels, determining a second control channel with the highest priority from the plurality of first control channels; and step S14, determining the second control channel as the target control channel.
It should be noted that, the priority of the control channel may be determined according to a control manner of the control channel, and calculated by each controlled device separately. If the controlled device corresponds to a large circulation control channel containing a large circulation control mode of the cloud and a small circulation control channel not containing a small circulation control mode of the cloud, the priority of the large circulation control channel is higher than that of the small circulation control channel, the large circulation control channel is determined to be the target control channel, and therefore, even if the controlled device corresponds to the small circulation control channel, the small circulation control channel is not determined to be the target control channel.
The controlled device may include, but is not limited to, WIFI devices supporting WIFI communication, zigBee devices supporting ZigBee communication, and BLE mesh devices supporting mesh communication. The WiFi device may include a WiFi device and a BLE device, the ZigBee device may include a ZigBee device, and the BLE mesh device may include a BLE mesh device, for example.
For WiFi devices, the corresponding small-loop control channel does not support BLE control.
For BLE mesh equipment, the corresponding large-cycle control channel or small-cycle control channel is at least generated by a gateway. And the control channel corresponding to the BLE mesh equipment comprises a large circulation control channel or a small circulation control channel and a BLE mesh control channel capable of being controlled in a circulating mode, wherein the priority of the BLE mesh control channel is smaller than that of the small circulation control channel.
Optionally, in one embodiment, after acquiring the device state of each controlled device, if it is determined that the device state of each controlled device is offline, a prompt message is generated, where the prompt message includes an error code identifier for indicating that an error occurs in the device state of each controlled device; and sending the prompt information to a target object. In this embodiment, the user is prompted to indicate the manner in which the controlled device is uncontrollable by returning a specific error code. The fault real-time monitoring of the controlled equipment can be realized, the fault processing speed is increased, and the fault processing probability of the controlled equipment is improved.
In an exemplary embodiment, in order to better understand how to determine, in the step S204, a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to the control flag bit of the controlled request and the channel type of the target control channel, the following technical scheme is provided, where the method specifically includes the following steps: step S21, determining to generate the first control instruction under the condition that the control zone bit of the controlled request is determined to be used for indicating that each controlled device supports remote control and the channel type of the target control channel is determined to be an intra-group device control channel; step S22, or determining to generate the second control instruction if it is determined that the control flag bit of the controlled request is used to indicate that the remote control is not supported by each controlled device and it is determined that the channel type of the target control channel is an intra-group device control channel.
Optionally, for the controlled device of which the channel type of the target control channel is the intra-group device control channel, the control instruction may be sent preferentially, if the channel type of the target control channel is the controlled device of which all the controlled devices are corresponding to the intra-group device control channel after the sending of the control instruction of all the controlled devices are completed, the controlled device of which the channel type of the target control channel is the non-intra-group device control channel is still present, the control instruction is sent one by one for the controlled device of which the channel type of the target control channel is the non-intra-group device control channel, thereby realizing the rough control of the intra-group device, simultaneously carrying out precise control on the outer-group device, reducing the probability of device control omission, improving the probability of whole coverage of the controlled device, and improving the control efficiency of the controlled device.
Alternatively, the channel type of the target control channel may be determined according to a group control identifier, where the group control identifier may be represented by, for example, a device group control role and a device group control capability, and the representation mode is "(device group control role|device group control capability)".
Specifically, the device group control role is "0", and default indicates a common device that is not grouped; the device group control role is "1", which indicates a grouping device (user creation), the device group control role is "2", which indicates a grouping device (application creation), and the device group control role is "3", which indicates a general device that has entered a group.
The device group control capability is "0", and by default indicates a device (including gateway devices and other devices) that does not support group control, the device group control capability is "1" indicates a gateway device that supports performing group control, and the device group control capability is "2" indicates all other devices under the gateway that supports performing group control.
For example, if the channel type of the target control channel is "(1|2)", the channel type of the corresponding target control channel is the controlled device of the device control channel in the group; if the channel type of the target control channel is "(0|2)", the channel type of the corresponding target control channel is the controlled device of the non-intra-group device control channel.
Optionally, when it is determined that the control flag bit of the controlled request is used to indicate that remote control is supported, and it is determined that any one of the remote control channels is not satisfied, it is determined that the first control instruction is not generated, or when it is determined that the control flag bit of the controlled request is used to indicate that each controlled device does not support remote control, it is determined that any one of the intra-group device control channels is not satisfied, it is determined that the second control instruction is not generated.
In an exemplary embodiment, further, after the step S21 is performed, a description is given of an implementation procedure of sending the first control instruction to each controlled device through the target control channel by using the following technical scheme: step S211, sending the first control instruction to a gateway server of each controlled device, so that the gateway server sends the first control instruction to a first device gateway corresponding to each controlled device; the target control channel is generated at least through the gateway server of each controlled device and the first device gateway; step S212, determining all the controlled devices corresponding to the first device gateway, and sending the first control instruction to all the controlled devices corresponding to the first device gateway.
In an exemplary embodiment, after implementing the step S22, other technical solutions for sending the second control instruction to each controlled device through the target control channel are further provided, where the technical solutions specifically include: the scheme 1 is that the second control instruction is sent to a second device gateway corresponding to each controlled device, wherein the target control channel is generated at least through the second device gateway; and determining all the controlled devices corresponding to the second device gateway, and sending the second control instruction to all the controlled devices corresponding to the second device gateway.
Optionally, under the condition that a plurality of device gateways exist, a plurality of device gateways can be traversed, and for each device gateway in the plurality of device gateways, the first control instruction is sent to all controlled devices contained in each device gateway.
Scheme 2, send the second control instruction to the proxy device of each controlled device, where the target control channel is at least generated by the proxy device of each controlled device; and determining all the controlled devices proxied by the proxy device of each controlled device, and sending the second control instruction to all the controlled devices proxied by the proxy device of each controlled device.
The scheme 3 is that the second control instruction is sent to a third device gateway corresponding to each controlled device, wherein the target control channel is at least generated through the third device gateway of each controlled device; and sending the second control instruction to all controlled devices corresponding to each third device gateway in the plurality of third device gateways under the condition that the plurality of third device gateways are determined to exist.
In an exemplary embodiment, further, after determining, according to the control flag bit of the controlled request and the channel type of the target control channel, a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device, for a case that the channel type of the target control channel is a non-intra-group device control channel, the following implementation scheme is further provided: determining to generate a third control instruction under the condition that the control zone bit of the controlled request is determined to be used for indicating that each controlled device supports remote control and the channel type of the target control channel is determined to be a non-intra-group device control channel; the third control instruction is sent to a cloud server corresponding to each controlled device through the target control channel, so that the cloud server forwards the third control instruction to each controlled device; the target control channel is generated at least through a cloud server corresponding to each controlled device; and under the condition that each controlled device responds to the third control instruction to send first response information to the cloud server, acquiring the first response information from the cloud server.
In an exemplary embodiment, after determining, according to the control flag bit of the controlled request and the channel type of the target control channel, a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device, further, determining to generate a fourth control instruction in a case that it is determined that the control flag bit of the controlled request is used for indicating that remote control is not supported and that the channel type of the target control channel is a non-intra-group device control channel; transmitting the fourth control instruction to each controlled device through the target control channel; and receiving second response information sent by each controlled device based on the fourth control instruction, wherein the second response information comprises an execution result generated when each controlled device executes the fourth control instruction.
Or under the condition that the control zone bit of the controlled request is used for indicating that each controlled device supports remote control and that the channel type of the target control channel is determined to be that any one of the non-intra-group device control channels is not established, determining that a third control instruction is not generated; and under the condition that the control zone bit of the controlled request is used for indicating that remote control is not supported and that the channel type of the target control channel is determined to be any one of the non-intra-group equipment control channels is not established, determining that a fourth control instruction is not generated.
Alternatively, in this embodiment, if the second response information sent by each controlled device based on the fourth control instruction is not received, the device response information of the device packet may be simulated without waiting for the attribute to report.
In order to better understand the process of the method for sending the control instruction, the following describes the flow of the implementation method for sending the control instruction in combination with the alternative embodiment, but is not used for limiting the technical scheme of the embodiment of the application.
In one embodiment, the process of sending the control instruction via the cloud may include, for example: step S31, using the device number to inquire all the controlled devices of the input group; step S32, using the group control capability reported by the controlled device of the group and the relation with the gateway device ID, inquiring all gateways supporting group control, and sending a group control command (comprising the first control command and the second control command) to all gateways supporting group control by using a "=1" (corresponding to the group control identifier) representation; in step S33, when it is determined that the controlled device having received the packet also supports remote control, a normal control command (including the third control command and the fourth control command) is issued to a device that does not support group control (expressed as "=0", which corresponds to the group control identifier) in the received packet device.
Further, in this embodiment, a method for sending a control instruction is provided in conjunction with fig. 3, and fig. 3 is a flow chart (one) of a method for sending a control instruction according to an embodiment of the present application, as shown in fig. 3, specifically the following steps are provided:
Step S301: an AI cloud/big data cloud/scene center sends a device grouping control standard command to the LOT cloud;
wherein, the device group control standard command comprises the following parameters:
Device packet number: device ld represents the group of devices in which the device being controlled (which may be simply referred to as a device) is located.
Standard cmd: attribute write operations or other operations based on a standard device model.
Step S302: the domain model in the LOT cloud uses logical constraints to compute device group control instructions cmdList (i.e., the control instructions described above);
The domain model converts the equipment grouping control standard command into an actual command through conversion, compensation and mutual exclusion according to the logic constraint file;
the logical constraint file is generated by the IOT base cloud at the time of device group creation. Since the device group does not have typeld, each device group id has a corresponding logical constraint file. To reduce the number of logical constraint files, multiple device groups that hash the same functional set may share the same logical constraint file.
Step S303: the LOT cloud sends a common equipment single control command to the WIFI equipment;
step S304: the WIFI equipment replies control response information to the LOT cloud;
the WIFI device may include, for example, a WIFI module.
Step S305: the LOT cloud end sends a device grouping control instruction to the BLE mesh gateway;
Wherein the device group control instruction includes: device packet deviceld, cmd, BLEMeshGroupAddr, etc. cmd represents an actual device control instruction calculated by the domain model, BLEMeshGroupAddr represents a BLE mesh group address, is optional, and belongs to the specific of the BLE mesh.
Step S306: the BLE mesh gateway sends a device grouping control response to the LOT cloud;
Where a reply is understood to be a reply to receipt of a command and not a result of execution of a device group control instruction.
Step S307: the BLE mesh gateway sends a BLE mesh group control command to BLE mesh equipment;
In the step, the single gateway and the multi-gateway ZigBee equipment can be compatible, the cloud side searches the gateway where the equipment is located through the relation between the equipment and the gateway, and issues a command to the gateway;
For the ble mesh device, the LOT cloud searches Blemesh gateways to be issued through the heartbeat packet. For WIFI equipment, only consider the condition of 1 WIFI equipment of 1 WIFI module control, in order to reduce the development and the test workload of cloud core module this moment, the low cloud gives WIFI equipment and issues ordinary control command (attribute is write or equipment operation).
Next, the transmission process of the control command of the ZigBee gateway device is described through steps S308 to S312, and for a plurality of ZigBee gateway devices, each ZigBee gateway device needs to perform steps S308 to S312:
step S308: the LOT cloud sends a device grouping control instruction to SMART DEVICE; wherein SMART DEVICE can realize the function of the third device gateway together with the ZigBee gateway device APP;
step S309: SMART DEVICE sends a packet control instruction to the ZigBee gateway device APP;
Step S3010: the device ZigBee gateway device APP sends a device grouping control response to SMART DEVICE;
step S3011: SMART DEVICE sends a device grouping control response to the LOT cloud;
Wherein SMARTDEVICE directly transmits the command to ZigBee gateway device APP without filtering device list.
Step S3012: the device ZigBee gateway device APP controls group devices under the gateway through multicast/broadcast/unicast;
Step S3013: simulating equipment response, namely simulating equipment response after determining that equipment grouping control instructions are successfully transmitted without waiting for equipment in a group to report the response in a large loop simulated by the IOT cloud in order to reduce the change of the existing equipment control mechanism as much as possible;
Step S3014: the LOT cloud sends a device grouping control response to the AI cloud/big data cloud/scene center.
In one embodiment, the foregoing control instruction sending method may be described with reference to fig. 4, where in this embodiment, a control instruction sending method is provided, fig. 4 is a schematic flow chart (two) of a control instruction sending method according to an embodiment of the present application, as shown in fig. 4, and specifically includes the following steps:
step S401: transmitting a device group control standard command to usdk by the smart home APP;
Wherein, the device group control standard command comprises the following parameters: device packet number: device ld represents the device group in which the controlled device is located. Standard cmd: attribute write operations or other operations based on a standard device model.
For the calculation of the device grouping control standard instruction, the device command calculation is directly realized by the edge field model integrated in uSDK without passing through a logic engine of the intelligent app.
Step S402: updating equipment grouping attribute in the intelligent APP according to the control instruction;
step S403: the edge domain model in usdk calculates the device grouped control instructions cmdList according to the logical constraint file;
specifically, the edge domain model converts the device group control standard command into an actual command through conversion, compensation and mutual exclusion according to a logic constraint file, wherein the logic constraint file is generated by the IOT base cloud when the device group is created. Each device group has no typeld and no model number, and each device group ID has a corresponding logical constraint file.
Step S404: and selecting a route for the equipment according to the 3 communication protocols of the ble mesh, the ZigBee and the WIFI. Namely, a group control channel (namely the target control channel) is selected for the equipment according to different communication modes such as BLE mesh, zigBee, WIFI and the like supported by the equipment.
Step S405: usdk sends a device grouping large circulation control instruction to the LOT cloud based on mqtt protocol;
Wherein the device packet large loop control instruction comprises device packets deviceld, cmd, lsBleMeshRemoteCtrl, lsZigBeeRemoteCtrl, etc.
Cmd represents the actual plant control command after the domain model calculation.
LsBleMeshRemoteCtrl represents a remote control flag bit of the device in the ble mesh group, wherein 1 is yes, and 0 is no.
LsZigBeeRemoteCtrl indicates a remote control flag bit of the device in the ZigBee group, wherein 1 is yes, and 0 is no.
The parameters do not contain the device flag bit in the WIFI group, and the WIFI device can walk ordinary single control logic.
Step S406: LOT cloud response usdk; namely, a response returned by the LOT cloud represents a response of receiving the command;
step S407: the LOT cloud end sends a device grouping control instruction to the BLE mesh gateway;
step S408: the BLE mesh gateway equipment sends a packet control response to the LOT cloud;
Step S409: the BLE mesh gateway controls instructions to BLE mesh equipment group equipment;
Since steps S4010 to S4014 are similar to steps S308 to S312 described above, the transmission process of the control instruction to the ZigBee gateway device implemented in steps S4010 to S4014 can be described with reference to steps S308 to S312 described above.
For a plurality of ZigBee gateway devices, each ZigBee gateway device needs to perform steps S4010 to S4014.
Step S4015: usdk sends a control instruction of the devices in the group to the BLE mesh gateway;
Among these, for example, commands already existing in the UWT protocol may be used: cmd_uwt_mesh_epp_down to send control commands, which requires completion depending on the underlying mechanism of the UWT.
Step S4016: the BLE mesh gateway sends a group device control response to usdk;
Step S4017: the BLE mesh gateway sends a control instruction of the group device to the BLE mesh device;
Step S4018: usdk sends a control instruction of the devices in the group to the ble mesh Proxy;
Among these, for example, an existing command may be used: and the U+BLE mesh protocol+E++ protocol sends a control instruction. The indication of a command without an ack does not guarantee receipt by the device.
Step S4019: the method comprises the steps that a BLE mesh Proxy sends a control instruction of equipment in a group to BLE mesh equipment;
Since steps S4020 to S4024 are similar to steps S308 to S312 described above, the transmission process of the control instruction to the ZigBee gateway device implemented in steps S4020 to S4024 can be described with reference to steps S308 to S312 described above.
In this process, uSDK sends the group control command to all local gateways supporting group control (whether the devices in the group are under the gateway or not) according to a communication mode (BLE mesh, zigBee), and then issues the single control command to the common devices in the group of devices which do not support group control one by one.
The BLE mesh group control command carries a BLE mesh group address. For WIFI equipment, only consider the condition of 1 WIFI equipment of 1 WIFI module control, handle according to the equipment that does not support by the group accuse. In the implementation process, SMARTDEVICE directly transmits the command to the ZigBee gateway device APP without filtering the device list.
Next, the transmission process of the control instruction of the normal device will be described through steps S4025 to S4030:
Step S4025: usdk sends a common equipment control instruction to the LOT cloud;
step S4026: the LOT cloud end sends a common device control instruction to the WIFI device;
step S4027: the WIFI equipment sends a common equipment control response to the LOT cloud;
step S4028: the LOT cloud sends a common equipment control response to usdk;
step S4029: the LOT cloud directly sends a common device control instruction to the WIFI device;
The steps S4025 to S4029 represent a flow of sending a control instruction to the WIFI device via a remote control channel (i.e., a control channel for sending the third control instruction) and a local control channel (i.e., a control channel for sending the fourth control instruction); for ZigBee devices that do not support group control, SMARTDEVICE may also be used to implement this procedure.
Step S4030: the WIFI equipment sends a common equipment control response to the LOT cloud;
Step S4031: usdk simulate device responses of the device group;
step S4032: usdk feeds back simulated device group control responses to the smart home APP.
Through the steps, the group control command can be sent to all the devices supporting group control in the device list, and the common control command can be issued to the devices not supporting group control. For example, if a large-cycle control channel is needed, the device packet large-cycle control instruction of step S405 is invoked, whether remote control is performed is determined according to respective remote control flag bits (is BleMesh Remote Ctrl, is ZigBee Remote Ctrl) of BLE mesh and ZigBee, and different control instructions are issued according to the communication mode for the remote control flag bit with value 1. If the large-cycle control channel is not used, different group control commands are issued to different gateways according to different communication modes, and the WIFI equipment which does not support group control issues a single control command. In order to be compatible with the ZigBee old gateway with low version, uSDK can issue a single control command, so that no control leakage is ensured.
Based on the embodiment, compatible selection of control channels of WIFI equipment, zigBee equipment and BLE mesh equipment can be realized, the control channels are oriented to group control equipment and single control equipment, remote control and local control are supported, the control rate of the equipment can be improved, the probability of control command control omission is reduced, the expandability is realized, and equipment supporting other communication types can be increased in the later stage.
From the description of the above embodiments, it will be clear to a person skilled in the art that the method according to the above embodiments may be implemented by means of software plus the necessary general hardware platform, but of course also by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present application may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (e.g. ROM/RAM, magnetic disk, optical disk) comprising several instructions for causing a terminal device (which may be a mobile phone, a computer, a server, or a network device, etc.) to perform the method of the various embodiments of the present application.
Fig. 5 is a block diagram of a control instruction transmitting apparatus according to an embodiment of the present application; as shown in fig. 5, includes:
the channel determining module 52 is configured to determine a target control channel corresponding to each of all the controlled devices;
The instruction determining module 54 is configured to determine, in response to a controlled request of each controlled device, a first control instruction for performing remote control on each controlled device or a second control instruction for performing non-remote control on each controlled device according to a control flag bit of the controlled request and a channel type of the target control channel;
And the instruction sending module 56 is configured to send the first control instruction or the second control instruction to each controlled device through the target control channel.
Through the device, the target control channel corresponding to each controlled device in all the controlled devices is determined; responding to a controlled request of each controlled device, and determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to a control zone bit of the controlled request and a channel type of the target control channel; and sending the first control instruction or the second control instruction to each controlled device through the target control channel, and under the device grouping control scene, if a large number of devices exist in each group and support different channel types, generating the control instruction of the device based on the controlled request of the device and the channel types supported by the device so as to ensure that the devices in the group do not generate control omission and control again, thereby not only solving the technical problem of how to improve the sending efficiency of the control instruction, but also improving the sending efficiency of the control instruction of the devices in the group and further improving the control efficiency of the devices.
Optionally, in an embodiment, the control channels of the devices in the group may be compatible with device control channels respectively supported by the WIFI device, the ZigBee device, and the BLE mesh device, for example. If devices supporting other Communication modes such as NFC (NEAR FIELD Communication) technology are newly added in the group, the channel type of the target control channel needs to be expanded again.
In one exemplary embodiment, the channel determination module 52 further includes: a state acquisition unit, configured to acquire a device state of each controlled device; the first channel determining unit is used for determining a first control channel corresponding to each controlled device under the condition that the device state of each controlled device is determined to be online; a second channel determining unit, configured to determine, if it is determined that each of the controlled devices corresponds to a plurality of the first control channels, a second control channel having a highest priority from among the plurality of the first control channels; and the target channel determining unit is used for determining the second control channel as the target control channel.
It should be noted that, the priority of the control channel may be determined according to a control manner of the control channel, and calculated by each controlled device separately. If the controlled device corresponds to a large circulation control channel containing a large circulation control mode of the cloud and a small circulation control channel not containing a small circulation control mode of the cloud, the priority of the large circulation control channel is higher than that of the small circulation control channel, the large circulation control channel is determined to be the target control channel, and therefore, even if the controlled device corresponds to the small circulation control channel, the small circulation control channel is not determined to be the target control channel.
The controlled device may include, but is not limited to, WIFI devices supporting WIFI communication, zigBee devices supporting ZigBee communication, and BLE mesh devices supporting mesh communication. The WiFi device may include a WiFi device and a BLE device, the ZigBee device may include a ZigBee device, and the BLE mesh device may include a BLE mesh device, for example.
For WiFi devices, the corresponding small-loop control channel does not support BLE control.
For BLE mesh equipment, the corresponding large-cycle control channel or small-cycle control channel is at least generated by a gateway. And the control channel corresponding to the BLE mesh equipment comprises a large circulation control channel or a small circulation control channel and a BLE mesh control channel capable of being controlled in a circulating mode, wherein the priority of the BLE mesh control channel is smaller than that of the small circulation control channel.
Optionally, in one embodiment, the channel determining module 52 further includes: the prompt information generation unit is used for generating prompt information if the equipment state of each controlled equipment is offline after the equipment state of each controlled equipment is acquired, wherein the prompt information comprises an error code mark used for indicating that the equipment state of each controlled equipment is wrong; and sending the prompt information to a target object. In this embodiment, the user is prompted to indicate the manner in which the controlled device is uncontrollable by returning a specific error code. The fault real-time monitoring of the controlled equipment can be realized, the fault processing speed is increased, and the fault processing probability of the controlled equipment is improved.
In one exemplary embodiment, the instruction determination module 54 further includes: the first instruction generating unit is used for determining to generate the first control instruction under the condition that the control zone bit of the controlled request is used for indicating each controlled device to support remote control and the channel type of the target control channel is determined to be the intra-group device control channel; and the second instruction generating unit is used for determining to generate the second control instruction under the condition that the control zone bit of the controlled request is used for indicating that each controlled device does not support remote control and the channel type of the target control channel is determined to be the intra-group device control channel.
Optionally, the first instruction generating unit is further configured to send the control instruction preferentially to the controlled devices corresponding to the intra-group device control channel with respect to the channel type of the target control channel, and if the controlled devices corresponding to the non-intra-group device control channel with respect to the channel type of the target control channel exist after the control instruction sent by all the controlled devices corresponding to the intra-group device control channel with respect to the channel type of the target control channel is sent by the controlled devices corresponding to the non-intra-group device control channel, so that the intra-group device rough control is achieved, the external device is accurately controlled, the probability of device control omission is reduced, the probability of full coverage of the controlled devices is improved, and the control efficiency of the controlled devices is improved.
Alternatively, the channel type of the target control channel may be determined according to a group control identifier, where the group control identifier may be represented by, for example, a device group control role and a device group control capability, and the representation mode is "(device group control role|device group control capability)".
Specifically, the device group control role is "0", and default indicates a common device that is not grouped; the device group control role is "1", which indicates a grouping device (user creation), the device group control role is "2", which indicates a grouping device (application creation), and the device group control role is "3", which indicates a general device that has entered a group.
The device group control capability is "0", and by default indicates a device (including gateway devices and other devices) that does not support group control, the device group control capability is "1" indicates a gateway device that supports performing group control, and the device group control capability is "2" indicates all other devices under the gateway that supports performing group control.
For example, if the channel type of the target control channel is "(1|2)", the channel type of the corresponding target control channel is the controlled device of the device control channel in the group; if the channel type of the target control channel is "(0|2)", the channel type of the corresponding target control channel is the controlled device of the non-intra-group device control channel.
Optionally, the first instruction generating unit is further configured to: determining not to generate the first control instruction under the condition that the control zone bit of the controlled request is used for indicating support of remote control and the channel type of the control channel is determined to be any one of the remote control channels is not established; the second instruction generating unit is further configured to: and under the condition that the control zone bit of the controlled request is used for indicating that each controlled device does not support remote control and that the channel type of the target control channel is that any one of the device control channels in the group is not established, determining that the second control instruction is not generated.
In one exemplary embodiment, further, the instruction sending module 56 further includes: the first instruction sending unit is used for sending the first control instruction to the gateway server of each controlled device so that the gateway server sends the first control instruction to a first device gateway corresponding to each controlled device; the target control channel is generated at least through the gateway server of each controlled device and the first device gateway; and the second instruction sending unit is used for determining all the controlled devices corresponding to the first device gateway and sending the first control instruction to all the controlled devices corresponding to the first device gateway.
In an exemplary embodiment, further, the instruction sending module 56 further includes a third instruction sending unit, configured to implement scheme 1: the second control instruction is sent to a second device gateway corresponding to each controlled device, wherein the target control channel is generated at least through the second device gateway; and determining all the controlled devices corresponding to the second device gateway, and sending the second control instruction to all the controlled devices corresponding to the second device gateway.
Optionally, the third instruction sending unit is further configured to: and under the condition that a plurality of device gateways exist, traversing the plurality of device gateways, and sending the first control instruction to all controlled devices contained in each device gateway aiming at each device gateway in the plurality of device gateways.
In an exemplary embodiment, further, the instruction sending module 56 further includes a fourth instruction sending unit, configured to implement scheme 2: sending the second control instruction to the proxy equipment of each controlled equipment, wherein the target control channel is at least generated by the proxy equipment of each controlled equipment; and determining all the controlled devices proxied by the proxy device of each controlled device, and sending the second control instruction to all the controlled devices proxied by the proxy device of each controlled device.
In an exemplary embodiment, further, the instruction sending module 56 further includes a fifth instruction sending unit, configured to implement scheme 3: the second control instruction is sent to a third device gateway corresponding to each controlled device, wherein the target control channel is at least generated through the third device gateway of each controlled device; and sending the second control instruction to all controlled devices corresponding to each third device gateway in the plurality of third device gateways under the condition that the plurality of third device gateways are determined to exist.
In an exemplary embodiment, the foregoing control instruction sending apparatus further includes a first control instruction generating module, configured to, after determining, according to the control flag bit of the controlled request and the channel type of the target control channel, a first control instruction for performing remote control on each controlled device, or a second control instruction for performing non-remote control on each controlled device, execute, for a case that the channel type of the target control channel is a non-intra-group device control channel, the following implementation scheme: determining to generate a third control instruction under the condition that the control zone bit of the controlled request is determined to be used for indicating that each controlled device supports remote control and the channel type of the target control channel is determined to be a non-intra-group device control channel; the third control instruction is sent to a cloud server corresponding to each controlled device through the target control channel, so that the cloud server forwards the third control instruction to each controlled device; the target control channel is generated at least through a cloud server corresponding to each controlled device; and under the condition that each controlled device responds to the third control instruction to send first response information to the cloud server, acquiring the first response information from the cloud server.
In an exemplary embodiment, the foregoing control instruction sending apparatus further includes a second control instruction generating module, configured to determine, after determining, according to the control flag bit of the controlled request and the channel type of the target control channel, a first control instruction for performing remote control on each controlled device, or a second control instruction for performing non-remote control on each controlled device, determine, after determining that the control flag bit of the controlled request is used to indicate that remote control is not supported, and determine that the channel type of the target control channel is a non-intra-group device control channel, to generate a fourth control instruction; transmitting the fourth control instruction to each controlled device through the target control channel; and receiving second response information sent by each controlled device based on the fourth control instruction, wherein the second response information comprises an execution result generated when each controlled device executes the fourth control instruction.
Optionally, the first control instruction generating module is further configured to: and under the condition that the control zone bit of the controlled request is used for indicating that each controlled device supports remote control and that the channel type of the target control channel is determined to be that any one of the non-intra-group device control channels is not established, determining that a third control instruction is not generated. The second control instruction generating module is further configured to: and under the condition that the control zone bit of the controlled request is used for indicating that remote control is not supported and that the channel type of the target control channel is determined to be any one of the non-intra-group equipment control channels is not established, determining that a fourth control instruction is not generated.
Optionally, the second control instruction generating module is further configured to simulate device response information of a device packet without waiting for attribute reporting when the second response information sent by each controlled device based on the fourth control instruction is not received.
An embodiment of the present application also provides a storage medium including a stored program, wherein the program executes the method of any one of the above.
Alternatively, in the present embodiment, the above-described storage medium may be configured to store program code for performing the steps of:
s1, determining a target control channel corresponding to each controlled device in all controlled devices;
S2, responding to a controlled request of each controlled device, and determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to a control zone bit of the controlled request and a channel type of the target control channel;
S3, sending the first control instruction or the second control instruction to each controlled device through the target control channel.
An embodiment of the application also provides an electronic device comprising a memory having stored therein a computer program and a processor arranged to run the computer program to perform the steps of any of the method embodiments described above.
Optionally, the electronic apparatus may further include a transmission device and an input/output device, where the transmission device is connected to the processor, and the input/output device is connected to the processor.
Alternatively, in the present embodiment, the above-described processor may be configured to execute the following steps by a computer program:
s1, determining a target control channel corresponding to each controlled device in all controlled devices;
S2, responding to a controlled request of each controlled device, and determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to a control zone bit of the controlled request and a channel type of the target control channel;
S3, sending the first control instruction or the second control instruction to each controlled device through the target control channel.
Alternatively, in the present embodiment, the storage medium may include, but is not limited to: a U-disk, a read-only memory (ROM), a random access memory (Random Access Memory RAM), a removable hard disk, a magnetic disk, or an optical disk, etc., which can store program codes.
Alternatively, specific examples in this embodiment may refer to examples described in the foregoing embodiments and optional implementations, and this embodiment is not described herein.
It will be appreciated by those skilled in the art that the modules or steps of the application described above may be implemented in a general purpose computing device, they may be concentrated on a single computing device, or distributed across a network of computing devices, they may alternatively be implemented in program code executable by computing devices, so that they may be stored in a memory device for execution by computing devices, and in some cases, the steps shown or described may be performed in a different order than that shown or described, or they may be separately fabricated into individual integrated circuit modules, or multiple modules or steps within them may be fabricated into a single integrated circuit module for implementation. Thus, the present application is not limited to any specific combination of hardware and software.
The foregoing is merely a preferred embodiment of the present application and it should be noted that modifications and adaptations to those skilled in the art may be made without departing from the principles of the present application, which are intended to be comprehended within the scope of the present application.

Claims (12)

1. A method for transmitting a control command, comprising:
determining a target control channel corresponding to each controlled device in all the controlled devices;
Responding to a controlled request of each controlled device, and determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to a control zone bit of the controlled request and a channel type of the target control channel;
and sending the first control instruction or the second control instruction to each controlled device through the target control channel.
2. The method for sending a control command according to claim 1, wherein determining a target control channel to which each of all the controlled devices belongs comprises:
acquiring the equipment state of each controlled equipment;
Under the condition that the equipment state of each controlled equipment is determined to be online, determining a first control channel corresponding to each controlled equipment;
If each controlled device is determined to correspond to a plurality of first control channels, determining a second control channel with the highest priority from the plurality of first control channels;
And determining the second control channel as the target control channel.
3. The method for sending a control command according to claim 1, wherein determining a first control command for remotely controlling each controlled device or a second control command for non-remotely controlling each controlled device according to the control flag bit of the controlled request and the channel type of the target control channel includes:
Determining to generate the first control instruction under the condition that the control zone bit of the controlled request is determined to be used for indicating that each controlled device supports remote control and the channel type of the target control channel is determined to be an intra-group device control channel;
Or under the condition that the control zone bit of the controlled request is determined to be used for indicating that each controlled device does not support remote control and the channel type of the target control channel is determined to be the intra-group device control channel, determining to generate the second control instruction.
4. A method of sending control instructions according to claim 3, wherein sending the first control instruction to each of the controlled devices through the target control channel comprises:
The first control instruction is sent to a gateway server of each controlled device, so that the gateway server sends the first control instruction to a first device gateway corresponding to each controlled device;
The target control channel is generated at least through the gateway server of each controlled device and the first device gateway;
And determining all controlled devices corresponding to the first device gateway, and sending the first control instruction to all the controlled devices corresponding to the first device gateway.
5. A method of sending control instructions according to claim 3, wherein sending the second control instruction to each of the controlled devices through the target control channel comprises:
The second control instruction is sent to a second device gateway corresponding to each controlled device, wherein the target control channel is generated at least through the second device gateway;
and determining all the controlled devices corresponding to the second device gateway, and sending the second control instruction to all the controlled devices corresponding to the second device gateway.
6. A method of sending control instructions according to claim 3, wherein sending the second control instruction to each of the controlled devices through the target control channel comprises:
sending the second control instruction to the proxy equipment of each controlled equipment, wherein the target control channel is at least generated by the proxy equipment of each controlled equipment;
and determining all the controlled devices proxied by the proxy device of each controlled device, and sending the second control instruction to all the controlled devices proxied by the proxy device of each controlled device.
7. A method of sending control instructions according to claim 3, wherein sending the second control instruction to each of the controlled devices through the target control channel comprises:
the second control instruction is sent to a third device gateway corresponding to each controlled device, wherein the target control channel is at least generated through the third device gateway of each controlled device;
And sending the second control instruction to all controlled devices corresponding to each third device gateway in the plurality of third device gateways under the condition that the plurality of third device gateways are determined to exist.
8. The method according to claim 1, wherein after determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to the control flag bit of the controlled request and the channel type of the target control channel, the method further comprises:
determining to generate a third control instruction under the condition that the control zone bit of the controlled request is determined to be used for indicating that each controlled device supports remote control and the channel type of the target control channel is determined to be a non-intra-group device control channel;
The third control instruction is sent to a cloud server corresponding to each controlled device through the target control channel, so that the cloud server forwards the third control instruction to each controlled device; the target control channel is generated at least through a cloud server corresponding to each controlled device;
And under the condition that each controlled device responds to the third control instruction to send first response information to the cloud server, acquiring the first response information from the cloud server.
9. The method according to claim 1, wherein after determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to the control flag bit of the controlled request and the channel type of the target control channel, the method further comprises:
Determining to generate a fourth control instruction under the condition that the control zone bit of the controlled request is used for indicating that remote control is not supported and the channel type of the target control channel is determined to be a non-intra-group equipment control channel;
Transmitting the fourth control instruction to each controlled device through the target control channel;
And receiving second response information sent by each controlled device based on the fourth control instruction, wherein the second response information comprises an execution result generated when each controlled device executes the fourth control instruction.
10. A control instruction transmitting apparatus, comprising:
The channel determining module is used for determining a target control channel corresponding to each controlled device in all the controlled devices;
The instruction determining module is used for responding to the controlled request of each controlled device, and determining a first control instruction for remotely controlling each controlled device or a second control instruction for non-remotely controlling each controlled device according to the control zone bit of the controlled request and the channel type of the target control channel;
And the instruction sending module is used for sending the first control instruction or the second control instruction to each controlled device through the target control channel.
11. A computer readable storage medium, characterized in that the computer readable storage medium comprises a stored program, wherein the program when run performs the method of any of the preceding claims 1 to 9.
12. An electronic device comprising a memory and a processor, characterized in that the memory has stored therein a computer program, the processor being arranged to execute the method according to any of the claims 1 to 9 by means of the computer program.
CN202311737038.2A 2023-12-15 2023-12-15 Method and device for sending control instruction, storage medium and electronic device Pending CN117914634A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311737038.2A CN117914634A (en) 2023-12-15 2023-12-15 Method and device for sending control instruction, storage medium and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311737038.2A CN117914634A (en) 2023-12-15 2023-12-15 Method and device for sending control instruction, storage medium and electronic device

Publications (1)

Publication Number Publication Date
CN117914634A true CN117914634A (en) 2024-04-19

Family

ID=90693025

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311737038.2A Pending CN117914634A (en) 2023-12-15 2023-12-15 Method and device for sending control instruction, storage medium and electronic device

Country Status (1)

Country Link
CN (1) CN117914634A (en)

Similar Documents

Publication Publication Date Title
US10404832B2 (en) Management of gateway device using virtual gateway device
EP1569419B1 (en) Method of assigning addresses to a plurality of devices on a network and a network system therefor
RU2681351C1 (en) Method and means of managing an intellectual device for home use to download data, method and device for collecting data unloaded by intelligent device for home use
CN105681142B (en) networking system and networking method
WO2017040636A1 (en) Management of multi-radio gateway device using virtual gateway device
KR20170041743A (en) Method and apparatus for automatically generating an events dictionary in an internet of things (iot) network
US20110314163A1 (en) Wireless communication network for smart appliances
CA2714026A1 (en) System and method for transmitting and receiving information on a neighborhood area network
KR20100120110A (en) Apparatus and method for cooperatively updating firmware on wireless mesh network
CN116016002A (en) Intelligent household appliance network distribution method and device and electronic device
CN112152884B (en) Equipment control method and device and household appliance
CN112333014B (en) Device management method and communication apparatus
CN112311633B (en) Distribution network control method, distribution network control device, household appliance and storage medium
CN117914634A (en) Method and device for sending control instruction, storage medium and electronic device
JP6111607B2 (en) Network topology estimation device, network topology estimation method and program
CN112152885B (en) Equipment control method and device, household appliance and remote control equipment
CN105207811B (en) Method and device for replacing non-AllJoyn equipment
CN115174609B (en) Method and device for sending control instruction, storage medium and electronic device
CN115314549B (en) Offline equipment management method, storage medium and electronic device
CN115296948B (en) Scene information updating method and device, storage medium and electronic device
CN116382106A (en) Control method, system, storage medium and device of intelligent household equipment
CN110391927A (en) A kind of synchronous method of equipment state and public capability component
CN110809230A (en) Positioning information acquisition method and device
CN114697345B (en) Information updating method and device, storage medium and electronic device
CN116266845B (en) Data transmission method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination