Device networking method, control device and Internet of Things system
By selecting the master and slave devices in the Internet of Things system, and allowing the master devices to access the designated network to establish communication connections with the slave devices, the complex networking operation of IoT devices is solved, and networking efficiency and device management flexibility are improved.
Patent Information
- Application Number
- CN202010615159.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-06-30
- Publication Date
- 2025-03-07
- Estimated Expiration
- 2040-06-30
AI Technical Summary
In the prior art, the Internet of Things equipment networking operation is complicated and cumbersome, the operation is difficult, inefficient and error-prone, and the compatibility with the equipment is extremely poor.
By selecting a master device and multiple slave devices, the master device connects to the designated network and establishes a communication connection with the slave device. Users only need to allocate the master device to the network, simplifying the networking process.
It reduces the difficulty and time of user networking operations, improves networking efficiency, achieves compatibility with multiple models of equipment, and simplifies equipment management and control.
Smart Images

Figure CN113872782B_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the technical field of Internet of Things, and in particular to a device networking method, a control device and an Internet of Things system. Background Art
[0002] With the development of science and technology, the Internet of Things has gradually entered people's work and life. In order to use the Internet of Things, it is first necessary to network the various devices in the Internet of Things so that these devices can be connected to the specified network to form a usable Internet of Things system. The current networking method requires users to configure the network for each device one by one so that each device can be connected to the specified network. However, for users, the operation of configuring the network one by one is relatively complicated and cumbersome, difficult to operate, inefficient and prone to errors. Summary of the invention
[0003] In view of this, the embodiments of the present application provide a device networking method, a control device and an Internet of Things system, which can solve the problem of complex and inefficient Internet of Things device networking operations in the prior art.
[0004] A first aspect of an embodiment of the present application provides an Internet of Things system, including: a first master device and at least one first slave device;
[0005] The first master device obtains network configuration information, and uses the network configuration information to access a preset network;
[0006] The first master device establishes a communication connection with each of the first slave devices respectively; or, each of the first slave devices establishes a communication connection with the first master device respectively.
[0007] A second aspect of an embodiment of the present application provides a device networking method, which is applied to a first master device, including:
[0008] The first master device obtains network configuration information, and uses the network configuration information to access a preset network;
[0009] The first master device identifies at least one first slave device associated with itself, and establishes a communication connection with each of the first slave devices respectively.
[0010] A third aspect of an embodiment of the present application provides a device networking method, which is applied to a control device, including:
[0011] The control device obtains network distribution information;
[0012] The control device selects one device from at least two first devices, sets the selected device as a first master device, and sets the remaining devices from the at least two first devices as first slave devices;
[0013] The control device sends the network configuration information to the first master device, so that the first master device accesses a preset network according to the network configuration information;
[0014] The control device sends a first connection instruction to the first master device, and the first connection instruction is used to instruct the first master device to establish a communication connection with each of the first slave devices respectively; or the control device sends a second connection instruction to each of the first slave devices, and the second connection instruction is used to instruct each of the first slave devices to establish a communication connection with the first master device.
[0015] A fourth aspect of the embodiments of the present application provides a device control method, characterized in that it is applied to the Internet of Things system as described in the first aspect, and the device control method includes:
[0016] The first master device receives a first control instruction input by a user, and selects a third slave device pointed to by the first control instruction from the at least one first slave device;
[0017] The first master device determines a second control instruction related to the third slave device according to the first control instruction, and sends the second control instruction to the third slave device;
[0018] After receiving the second control instruction, the third slave device responds to the second control instruction.
[0019] The fifth aspect of an embodiment of the present application provides a control device, which includes a memory and a processor, wherein the memory stores a computer program that can be run on the processor, and when the processor executes the computer program, it implements the steps of the device networking method described in the third aspect above.
[0020] A sixth aspect of an embodiment of the present application provides a computer-readable storage medium, comprising: storing a computer program, characterized in that when the computer program is executed by a processor, the steps of the device networking method as described in any one of the third aspects above are implemented.
[0021] A seventh aspect of an embodiment of the present application provides a computer program product. When the computer program product runs on a control device, the control device executes the device networking method described in any one of the first aspects above.
[0022] Compared with the prior art, the embodiments of the present application have the following beneficial effects: in the embodiments of the present application, the user only needs to configure the network for the master device, and the master device then accesses the designated network according to the network configuration information. At the same time, the master and slave devices can communicate and connect by themselves. Therefore, the user does not need to configure the network and set up each device one by one, which greatly reduces the difficulty of user networking, makes networking operation simple and easy, and improves the user networking efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0024] Figure 1 This is a schematic diagram of a scenario of an Internet of Things system provided by an embodiment of the present application;
[0025] Figure 2 This is a schematic diagram of a scenario of an Internet of Things system provided by an embodiment of the present application;
[0026] Figure 3A This is a schematic diagram of a scenario of an Internet of Things system provided by an embodiment of the present application;
[0027] Figure 3B It is a structural diagram of the Internet of Things system provided by an embodiment of the present application;
[0028] Figure 4A This is a schematic diagram of a scenario of an Internet of Things system provided by an embodiment of the present application;
[0029] Figure 4B This is a schematic diagram of a scenario of an Internet of Things system provided by an embodiment of the present application;
[0030] Figure 4C This is a schematic diagram of a scenario of an Internet of Things system provided by an embodiment of the present application;
[0031] Figure 5 This is a schematic diagram of a scenario of an Internet of Things system provided by an embodiment of the present application;
[0032] Figure 6 It is a schematic diagram of a control device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0033] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.
[0034] In order to facilitate the understanding of the present application, the embodiments of the present application are briefly described here:
[0035] When the prior art is networking the Internet of Things, users are required to manually configure the network for all devices that need to be connected to the Internet of Things one by one, so that these devices are all connected to the designated network to realize the networking of these devices. On the one hand, this networking method is complicated and cumbersome to operate. For many users, the operation is difficult and the operation efficiency is low and error-prone, so it is less user-friendly. On the other hand, based on this networking method, the devices in the Internet of Things are relatively independent. If a user wants to control multiple devices in the Internet of Things, he needs to send operation instructions to these devices one by one. However, for users with group control requirements, the device control operation is cumbersome and inefficient at this time. On the other hand, all devices need to be connected to the designated network, which means that these devices have the requirement of "having the ability to access the designated network". However, in actual applications, users often have some devices that do not have the above capabilities. For example, when the designated network is a designated WiFi network, some old models of devices often do not have WiFi modules, and they cannot access the WiFi network at this time. Therefore, the networking method of the prior art has extremely poor compatibility with devices and is difficult to network.
[0036] In view of the above problems, when networking, the embodiment of the present application selects a master device from the devices that need to access the Internet of Things, and uses the other devices as slave devices. On this basis, the master device will access the specified network and establish a communication connection between the slave device and the master device. Figure 1 In this example, there are 4 devices that need to access the Internet of Things, and the preset network is the designated network to be accessed. One of the devices is selected as the master device, and the remaining 3 devices are set as slave 1, slave 2, and slave 3. On this basis, the 3 slave devices communicate with the master device through Bluetooth Zigbee and other methods. The master device is connected to the preset network.
[0037] In the embodiment of the present application, the slave device can exchange data with the designated network through the master device to achieve "access" to the designated network. During the networking process, the user only needs to configure the network for the master device, omitting a large number of network configuration operations. During use, the master device can be used to control the master device and its subordinate slave devices. Therefore, it has at least the following advantages over the prior art:
[0038] 1. The networking method is simple and efficient. Users only need to configure the network for the main device, without configuring and setting up each device one by one, which greatly reduces the difficulty of networking operation and improves the networking efficiency, making it easier for users to get started and less prone to errors, thus improving the user experience.
[0039] 2. Based on the networking architecture of master-slave devices, the embodiments of the present application can realize unified control or independent control of all master-slave devices under the master device. For example, the master-slave devices can be switched on and off uniformly, or some of the devices can be switched on and off or controlled in status, such as when a fan is included in the slave device, the wind speed of the fan can be adjusted. Therefore, compared with the prior art, the embodiments of the present application have extremely high flexibility in device management and control, and group control is more convenient and efficient.
[0040] 3. For devices that only have short-distance communication functions such as Bluetooth, Zigbee or infrared, and cannot access the designated network through WiFi or network cables, such as some Bluetooth speakers, etc. Through this solution, these devices can be treated as slave devices and network access control can be achieved. Therefore, compatibility with multiple models of devices can be achieved, reducing the difficulty of networking.
[0041] At the same time, some terms that may be involved in the embodiments of the present application are explained as follows:
[0042] Device: In the embodiments of the present application, except for those specifically described (such as control devices), devices refer to devices that need to be connected to the Internet of Things (also referred to as Internet of Things devices), and these devices are all electronic devices. Among them, the embodiments of the present application do not impose too many restrictions on the types and quantities of devices, which need to be determined based on actual application conditions. For example, when applied to daily life, the device may include household appliances such as televisions, sweepers, humidifiers, air purifiers, fans, air conditioners, and refrigerators, as well as any one or more non-household appliances such as electronic locks, Internet protocol network cameras (IPCAM), smart speakers, and lights.
[0043] Preset scenes: Considering that users may have many devices in actual applications and that they are widely distributed, in order to facilitate users to manage these devices, the concept of preset scenes is proposed in the embodiments of the present application. Users can set one or more preset scenes according to actual needs, or technicians can set one or more preset scenes according to actual user needs. The user or technician determines the devices that need to be added to each preset scene based on actual conditions. At this time, a single preset scene will contain at least one device. The preset scene is a virtual scene and has no necessary mapping relationship with the real space area. That is, it can correspond one-to-one with the real space area, or there may be certain differences.
[0044] Take an example to illustrate, you can refer to Figure 2It is a three-bedroom, one-living room house, which includes a study, master bedroom, second bedroom and living room. When dividing the preset scenes on this basis, an optional division method is: dividing according to the one-to-one correspondence of real space areas. In this case, the preset scenes can also include: study scene, master bedroom scene, second bedroom scene and living room scene. Correspondingly, each preset scene contains all the devices in the corresponding real space area. For example, the study scene contains all the devices in the study.
[0045] Another optional division method is to divide according to the actual needs of device management in the real space area. For example, you can refer to Figure 2 The dotted circle in the figure is used to divide the scene into preset scene A, preset scene B and preset scene C (the naming method of the preset scenes is not limited here and can be set by the user or technician). Preset scene A corresponds to the study + master bedroom in the real space area, preset scene B corresponds to the second bedroom, and preset scene C corresponds to the living room. At this time, the preset scene contains the corresponding devices in all real spaces. For example, preset scene A contains all the devices in the study and master bedroom.
[0046] Another optional way is to divide the preset scenes considering the actual user's needs for device management. For example, in order to facilitate unified management of TVs in the entire house, you can set up a TV scene and add all TVs to the TV scene. At this time, there may not be a strict correspondence between the preset scenes and the real space areas. For example, when there are TVs in three rooms, the TV scene will involve three real space areas, but it does not include all the devices in these real space areas. For another example, assuming that the study also serves as a children's room, for two functions, the room may contain multiple devices to serve the two functions at the same time. Therefore, according to the actual user needs, two preset scenes can be set up in a targeted manner: preset scene 1 and preset scene 2. And all devices related to the study function are added to one preset scene, and all devices related to the children's room function are added to another preset scene.
[0047] In addition to the above optional methods, users can also set preset scenes in other ways according to their actual needs, which are not limited here. It should also be noted that one or more optional methods can be used at the same time to divide the preset scenes to meet the needs of different practical applications of users. Through the devices with preset scenes, the actual management and control needs of users for the devices can be fully met, and flexible and accurate management and control of the devices can be achieved.
[0048] It should also be noted that there may be overlaps in the devices included in the preset scenes, for example Figure 2In the corresponding example, the TV in the study can be divided into the preset scene A and the TV scene at the same time. At this time, the user can control the overlapping devices respectively through different preset scenes.
[0049] Master device and slave device: In the embodiment of the present application, each preset scene will include at least one device.
[0050] When the preset scene contains only one device, this device is the main device. Accordingly, the main device will be connected to the preset network to enable the device to access the network. This allows the user to control the main device through the preset network.
[0051] For a preset scene containing two or more devices, the present embodiment of the application selects one device as the master device of the preset scene, and uses the other devices in the preset scene as slave devices of the preset scene. That is, in the present embodiment of the application:
[0052] 1. Each preset scenario will include a master device and an unknown number of slave devices.
[0053] 2. For different preset scenarios, since the specific types and quantities of devices included therein may be the same or different, the corresponding master and slave devices may also be the same or different.
[0054] 3. Master device and slave device do not refer to one or more specific devices, but are a general term for two selected types of devices.
[0055] Among them, the method for selecting the master device is not too limited here, and can be set by the technician according to actual needs, or can also be manually selected by the user. However, it should be understood that since the master device needs to communicate with one or more slave devices, and also needs to access a designated network. Therefore, in actual applications, when selecting a master device, the selected master device needs to have corresponding software and hardware configurations so that the master device can smoothly establish a communication connection with each slave device, and transmit data with the designated network. For example, when the slave device needs to communicate in the form of Bluetooth communication and ZigBee communication, the master device is required to have both software and hardware configurations for these two communications.
[0056] In addition, when there is no preset scene division in the Internet of Things, it can be regarded as a special case of the above preset scene division. That is, the entire Internet of Things as a configuration object is treated as a preset scene (but there is no specific preset scene corresponding to this time). All devices in the Internet of Things are devices in this preset scene. At this time, the selection of the above master and slave devices can also be carried out normally.
[0057] Control device: In the embodiment of the present application, the control device can be used for the selection of the master device, and the management and control of the master and slave devices. At the same time, in the case where preset scenes need to be set, the user can also set the preset scenes through the control device, such as adding, deleting, merging, naming and device management of preset scenes. In the embodiment of the present application, the control device can be some IoT devices. For example, when the IoT device includes a central control device (such as some smart housekeepers or smart terminals), the central control device can be used as the control device in the embodiment of the present application. Alternatively, the control device can also be a non-IoT device such as a mobile phone. In this case, the control device transmits data with each device through wired or wireless data transmission to realize operations such as master device selection, master and slave device management and preset scene setting.
[0058] In the embodiments of the present application, there are no excessive restrictions on the specific device type of the control device, which can be determined according to the actual application situation. For example, it can be a mobile phone, a computer, a tablet computer or other electronic devices. At the same time, in order to facilitate the user's selection of the control device, in some optional embodiments, an application with the above functions can be pre-designed. When necessary, the user can install the corresponding application in the device so that the device has the corresponding function and becomes the control device in the embodiments of the present application.
[0059] Preset network: a designated network that the device needs to access in the embodiment of the present application. In the embodiment of the present application, the preset network can be a wide area network or a specific local area network. After the device accesses the preset network, the user can use the control device to remotely manage and control the device through the preset network.
[0060] Network configuration information: information required for the device to access the preset network, such as the login account and password of the preset network. Specifically, the actual content of the network configuration information needs to be determined according to the type of the preset network and the network access method of the device. For example, in some optional embodiments, when the device accesses the preset network through WiFi, wireless network card or network cable, the network configuration information may include information such as the account and password for logging into the preset network (when the preset network itself is not encrypted, the password may not be included at this time). In other optional embodiments, when the device accesses the cellular network through a subscriber identification (Subscriber Identity Module, SIM) card and accesses the preset network through the cellular network. Since the main device needs to access a specific server through the cellular network, the user can subsequently access, manage and control the main device. Therefore, the network configuration information at this time may include the information required to access the specific server, such as the account and password for access.
[0061] In order to illustrate the technical solution described in this application, the following is a description through specific embodiments. Among them, the description is made by taking the control device as a mobile phone as an example. It should be understood that the control device can also be other types of devices.
[0062] Figure 3A A schematic diagram of a scenario in which the Internet of Things system provided by an embodiment of the present application performs device networking is shown, and the details are as follows:
[0063] In the embodiment of the present application, the IoT system includes n devices that need to access the preset network, namely Figure 3A Devices 1 to n in the IoT, and a mobile phone (in some embodiments, the mobile phone can also be a device outside the IoT, in which case the IoT system only includes n devices.). Where n is a natural number greater than or equal to 2. In actual applications, users can purchase the required number and type of devices according to their own implementation requirements, so the specific value of n can be determined according to the actual application situation. Accordingly, the operation of networking is as follows:
[0064] In actual applications, n devices will be placed by users in various spatial locations. In order to achieve networking, these devices need to be turned on first.
[0065] S11, after the device is turned on, the user can operate the mobile phone to scan the device. At this time, the mobile phone will automatically scan all available devices around and display the scanned devices.
[0066] S12, the user selects some or all of the devices from all displayed devices as the devices to be set this time (ie, the first device). At this time, the mobile phone will filter out all the selected devices according to the user's operation.
[0067] S13, when the user sets a preset scene in the mobile phone, or when some default preset scenes have been set in the mobile phone, the user can also select the scene to be used. Accordingly, after receiving the preset scene set or selected by the user and the selected device, the mobile phone will determine these devices as devices in the preset scene. (If the user selects all displayed devices, there may be no preset scene setting operation at this time, or all devices may be set as devices under one preset scene.)
[0068] As another optional embodiment of the present application, some default preset scenes can be pre-set in the mobile phone, and a device list is set for each preset scene. The device list records one or more devices that can be added to the preset scene. In this case, S12 and S13 can also be replaced by:
[0069] The user selects the default preset scene to be used on the mobile phone. At this time, the mobile phone will automatically determine the corresponding device list according to the selected preset scene, and then automatically select the device recorded in the device list from all displayed devices as the device in the selected preset scene.
[0070] S14, selecting a master device and setting a slave device from the devices selected in S13. Regarding the selection of the master device, two optional methods are provided in the embodiment of the present application:
[0071] Method 1: After the user selects the device to be set this time, he can select a device as the main device. The timing of selecting the main device can be before or after the preset scene setting. Correspondingly, the mobile phone will receive the device setting instruction actually input by the user, and use the device pointed to by the device setting instruction as the main device, and the remaining devices as slave devices.
[0072] Method 2: Provide users with an automatic setting function. Users only need to use this function in their mobile phones to automatically select and set the master device. Accordingly, after the function is triggered, the mobile phone will select a master device from the devices to be set according to the preset selection rules, and set the remaining devices as slave devices. Or after the function is triggered, the mobile phone sends a trigger instruction to the device to be set. After receiving the trigger instruction, the device selects a master device from the devices to be set according to the preset selection rules, and sets the remaining devices as slave devices (the execution subject of the selection operation at this time can be any device among the devices to be set).
[0073] Among them, the specific selection rules are not too limited here and can be set by technical personnel according to actual needs. For example, considering the different performances of different devices, a priority data can be set in advance, in which corresponding priorities are set for various devices. On this basis, it is only necessary to select the master device according to the actual priority. For another example, considering that the master device needs to transmit data with each slave device, it is necessary to have a better signal connection quality with each slave device. Therefore, in an embodiment of the present application, it can also be set to detect the signal connection quality between each device, and select a device with better signal connection quality with other devices as the master device. Alternatively, the above-mentioned priority and signal connection quality can be comprehensively evaluated, such as weighted operation, and then selected according to the evaluation results.
[0074] S15, the mobile phone configures the network for the main device so that the main device can access the preset network. There are multiple options for the network configuration method and timing. For example, the following options may be included:
[0075] 1. If the above method 1 is adopted, the user selects the main device by himself. At this time, the network configuration operation can be that after the user determines the main device, the user chooses to configure the network for the main device. Correspondingly, the mobile phone will send the network configuration information to the main device, and the main device will access the preset network according to the network configuration information. Or the network configuration operation can also be combined with the selection of the main device in one step, that is, the user selects a device from the devices to be set up for network configuration, and the device with network configuration is the main device. Correspondingly, after receiving the user's device setting instruction, the mobile phone will send the network configuration information to the device pointed to by the instruction and use it as the main device. The device that receives the network configuration information will access the preset network according to the network configuration information.
[0076] 2. If the above method 2 is adopted, the target device automatically selects the master device (the target device is the mobile phone or any device to be set). In this case, after the master device is selected, the mobile phone sends the network configuration information to the master device, and the master device connects to the preset network according to the network configuration information.
[0077] Among them, the network configuration information needs to be entered by the user into the mobile phone. The specific input time can be before S15 network configuration or during S15 network configuration operation. Correspondingly, if it is before S15, the mobile phone will store the network configuration information entered by the user and read it when needed. If it is in S15, it will prompt the user when the network configuration information is needed. After the user enters the network configuration information, the network configuration information is sent to the main device.
[0078] S16, establishing a communication connection between the master device and each slave device.
[0079] After selecting the master device, the embodiment of the present application will establish a communication connection between the master device and each slave device. Among them, the method of establishing the communication connection is not too limited here. For example, as an optional embodiment of the present application, each slave device can turn on the pairing mode, and the master device can actively pair with each slave device, and complete the communication connection after the pairing is successful. Or the master device can also turn on the pairing mode, and each slave device can actively pair with the master device, and the external communication connection can be completed after the pairing is successful. Among them, in order to inform the master and slave devices that a communication connection is required, the mobile phone can send corresponding connection instructions to the master and slave devices. After receiving the connection instruction, the master and slave devices turn on the pairing mode, or start to actively establish a communication connection.
[0080] In the embodiment of the present application, considering that the purpose of the communication connection is mainly to enable the master device to exchange data with the slave device, so that the master device can obtain the device status of the slave device, and can send some control instructions to the slave device to achieve the management and control of the slave device, so that the slave device can also achieve the effect of "accessing" the preset network even though it does not directly access the preset network. Therefore, in theory, as long as the selected communication connection can meet the above requirements, on this basis, the embodiment of the present application does not make too many restrictions on the specific communication connection technology between the master device and the slave device. As an optional embodiment of the present application, in order to reduce the power consumption of the communication connection between the master and slave devices, and reduce the requirements for the hardware and software configuration of the slave device. In the embodiment of the present application, some short-range communication technologies can be selected to realize the communication connection between the master and slave devices, such as Bluetooth, ZigBee, WiFi and LiFi.
[0081] For a single preset scenario, the network structure after the device is networked can refer to the structure diagram. Figure 3B The number of slave devices is only an example, and the actual number of slave devices needs to be determined according to the actual situation. Theoretically, the number m of slave devices is a natural number greater than or equal to 1.
[0082] Regarding the execution order of S15 and S16: When the main device selection and network configuration are two steps, the execution order of S15 and S16 is not limited. It can be S15 first and then S16, or S16 first and then S15. When the network configuration operation and the main device selection are combined into one step, S14 and S15 are combined into one step. Therefore, S16 needs to be executed after the main device network configuration.
[0083] It should be noted that the above S12-S16 are operations for a single preset scene. After S16 is completed, the networking of all devices in a single preset scene can be realized. However, in actual applications, users may need to set multiple different preset scenes. At this time, the user can re-perform the operations of S12-S16. The mobile phone and each device will also perform corresponding operations. In order to realize the setting of the master and slave devices in each preset scene, the network configuration of the master device and the connection of the master and slave devices, and then realize the networking of the devices in each preset scene.
[0084] After completing the networking operations for the IoT system devices, users can start using the IoT system normally. Assume that users still use mobile phones to manage and control the devices in the IoT system. The corresponding control process at this time includes:
[0085] The user selects the preset scene to be controlled in the mobile phone and determines the device to be controlled in the preset scene. Accordingly, after the mobile phone detects the preset scene selected by the user, it will display all the devices contained in the preset scene. The user can choose to control these displayed devices uniformly, or select one or more devices for independent control. After the mobile phone detects the device selected by the user, it will display the corresponding control options, such as on, off and timing. The specific control options depend on the device actually selected by the user. For example, when an air conditioner is selected, it can include the selection of air conditioning mode and temperature. If a fan is selected, it can include the selection of fan wind speed level.
[0086] After viewing the control options, the user can operate among these options. After detecting the user's operation, the mobile phone generates a corresponding control instruction (i.e., the first control instruction). And sends the control instruction to the master device in the preset scene. After receiving the control instruction, the master device will identify the first control instruction, determine the specific device (i.e., the third slave device) involved in the control instruction, and the specific control content corresponding to each device. And determine the corresponding control instruction (i.e., the second control instruction). On this basis, the master device will further send the determined control instruction to each corresponding slave device. After receiving the control instruction sent by the master device, the slave device can execute the operation corresponding to the control instruction. For example, suppose that the slave device has a fan and a humidifier, and the control instruction received by the master device includes an instruction for adjusting the wind speed of the fan and an instruction for turning on the humidification function of the humidifier. At this time, the master device will split the instruction, or regenerate two corresponding control instructions, and send them to the fan and humidifier respectively. After receiving the control instruction for adjusting the wind speed, the fan adjusts the wind speed according to the control instruction. And after receiving the control instruction for turning on the humidification function, the humidifier turns on the humidification function.
[0087] Among them, if the first control instruction is only an instruction for the master device itself, the master device can perform an operation response. At this time, the embodiment of the present application does not need the concept of the second control instruction, nor does it need to send a corresponding instruction. If the first control instruction is only a control instruction for a single slave device, the master device can forward the first control instruction to the corresponding slave device after determining the slave device to which the first control instruction points. At this time, there is no need to split and parse the first control instruction. That is, the second control instruction and the first control instruction can be the same instruction.
[0088] The above embodiment is described with an example. Figure 4AIn the present embodiment of the application, there are a total of 7 devices, namely: air purifier, fan, humidifier, corridor light, smart speaker, air conditioner and ceiling light. There is also a mobile phone. In the present embodiment of the application, the mobile phone is used for networking operations and management and control of various devices in the Internet of Things system after networking, and the mobile phone is not used as a device in the Internet of Things system. At the same time, the preset network is a specified WiFi network, and the user has entered the WiFi network account and password and other network configuration information in the mobile phone.
[0089] After the user turns on the mobile device to scan, the phone will display all the 7 scanned devices. Assume that the user selects the air purifier, fan, humidifier and corridor light as devices in a preset scene, and sets the preset scene name to living room. And manually select the air purifier as the main device (assuming that the air purifier has the functions of WiFi communication, Bluetooth communication and ZigBee communication). At this time, the mobile phone will send the network configuration information to the air purifier. The air purifier will use the network configuration information to log in to the WiFi network and complete the network access.
[0090] At the same time, in the embodiment of the present application, the master device is selected to start the pairing mode, and each slave device actively matches with the master device to establish a communication connection. Therefore, at this time, the mobile phone will also send information to the fan, humidifier and corridor light to inform them to pair with the air purifier. After receiving the information sent by the mobile phone, the fan and corridor light will pair with the air purifier through Bluetooth and establish a Bluetooth connection. The humidifier will pair with the air purifier through ZigBee and establish a ZigBee connection. At this point, the device networking in the preset scene of the living room is completed.
[0091] At the same time, assume that the user has selected the smart speaker, air conditioner, ceiling light and corridor light as devices in another preset scene, and set the preset scene name to bedroom. And manually select the smart speaker as the main device (assuming that the smart speaker has the functions of WiFi communication, Bluetooth communication and ZigBee communication). At this time, the mobile phone will send the network configuration information to the smart speaker. The smart speaker will use the network configuration information to log in to the WiFi network and complete the network access. At this time, the mobile phone will also send information to the air conditioner, ceiling light and corridor light to inform them to pair with the smart speaker. After receiving the information sent by the mobile phone, the air conditioner and corridor light will pair with the smart speaker through Bluetooth and establish a Bluetooth connection. The ceiling light will pair with the smart speaker through ZigBee and establish a ZigBee connection. At this point, the device networking in the preset scene of the bedroom is completed.
[0092] After the network is established, if the user wants to control these devices (or other devices other than the mobile phone) through the mobile phone, the mobile phone must first be able to send data to each master device. In the embodiment of the present application, the user can select at least the following three methods:
[0093] 1. The mobile phone communicates directly with the main device and sends data to the main device.
[0094] 2. The mobile phone accesses the WiFi network and sends data to the main device through the WiFi network.
[0095] 3. Reference Figure 4B , connect the WiFi network to the World Wide Web. The mobile phone connects to the World Wide Web and sends data to the main device through the World Wide Web and the WiFi network.
[0096] Assume that the WiFi network is connected to the World Wide Web. And the user wants to access the World Wide Web through a mobile phone to remotely control the devices in the living room scene. Figure 4B , at this time, the user performs the corresponding control operation on the mobile phone, and the mobile phone generates the corresponding control instruction. The control instruction is sent to the air purifier through the World Wide Web and WiFi network. After receiving the control instruction, the air purifier analyzes the specific equipment that needs to be controlled by the instruction. Assume that the control instruction is used to control the fan wind speed to the maximum, the humidifier to turn on the humidification function, and the air purifier is turned on. At this time, the air purifier will generate two corresponding control instructions A and control instruction B according to the control instruction. Among them, control instruction A is used to control the fan wind speed to the maximum, and control instruction B is used to control the humidifier to turn on the humidification function. At the same time, the air purifier will send control instruction A to the fan in the form of a Bluetooth signal, and send control instruction B to the humidifier in the form of a purple bee signal. After receiving control instruction A, the fan will respond, that is, adjust the wind speed to the maximum. After receiving control instruction B, the humidifier will turn on the humidification function.
[0097] In the embodiment of the present application, the group management of the device is realized in the way of preset scenes, so that the management of the device is extremely flexible and changeable, which can fully meet the actual needs of different users for device management and control. When networking the devices in each scene, the user only needs to configure the network for the master device, and then the master and slave devices themselves establish a communication connection. Therefore, the networking method is simple and efficient, and the operation difficulty is low and easy to use. The networking architecture of the master and slave devices also allows users to control a single device in detail when managing and controlling the devices, and can also control all the devices in a single scene uniformly. Therefore, the flexibility of the device management and control of the embodiment of the present application is extremely high, and the group control is more convenient and efficient. Finally, the slave device does not need the ability to locally access the preset network, and can also realize data interaction with the preset network through the master device, and then realize pseudo access to the preset network, so that the slave device can be controlled as a local area network device. Therefore, for devices with only short-distance communication functions, the embodiment of the present application can also achieve extremely strong compatibility and reduce the networking difficulty of the Internet of Things system.
[0098] right Figure 3ASome notes on the illustrated embodiment:
[0099] 1. After the devices included in a preset scene have been set up, you can add or delete devices from the preset scene.
[0100] In the embodiment of the present application, the user can increase or decrease the devices in the preset scene according to his actual needs. Figure 4B In the illustrated embodiment, if the user does not need the corridor light to be included in the living room scene, the user can delete the corridor light from the living room scene through a mobile phone operation. Accordingly, after detecting the user's deletion operation, the mobile phone will delete the corridor light from the living room scene on the one hand, and send an instruction to the air purifier to disconnect the communication connection with the corridor light on the other hand. After receiving the instruction, the air purifier will disconnect the communication connection with the corridor light.
[0101] Similarly, if the user wants to add a new device to a preset scene, the user can turn on the device and scan the device using the mobile phone. The mobile phone then displays the scan results. The user can select the device and the corresponding preset scene from the results. After detecting the user's operation, the mobile phone will perform device networking based on the existing devices in the preset scene and the newly selected device, thereby realizing the re-networking of the devices in the preset scene.
[0102] For the above operations of adding or deleting devices, there are two situations, depending on whether to reselect the main device:
[0103] For adding equipment:
[0104] Case 1: Set the added device as a slave device, and then establish a communication connection between the added device and the master device.
[0105] Case 2: Set the added device as the master device, or reselect a master device based on the devices currently included in the preset scene and the added devices. At this time, after determining the master device, it is necessary to connect the master device to the preset network and establish a communication connection between the master device and each slave device. Among them, if the reselected master device is still the previous master device, the master device does not need to reconnect to the preset network. The original slave device does not need to reconnect to the master device. It is only necessary to establish a communication connection between the added device and the master device.
[0106] In case 2, the user can decide whether to set the added device as the main device or whether to reselect the main device. In this case, the user needs to perform setting operations in the mobile phone, and the mobile phone sets the main device according to the user's operation, or triggers the corresponding main device selection operation. In the case where the main device needs to be reselected, please refer to the description in S14, that is, the user can manually select a main device, or the mobile phone or device can select a main device autonomously.
[0107] For deleted devices:
[0108] Case 1: The deleted device is a master device, or the deleted device is a slave device, but the user chooses to reselect the master device after deletion. In this case, the master device needs to be reselected.
[0109] Case 2: The deleted device is a slave device, and the user does not choose to reselect the master device. In this case, there is no need to reselect the master device.
[0110] In an embodiment of the present application, the user can also choose whether to reselect the main device after deleting the device. If the main device is to be reselected, the reselection operation can be performed in the mobile phone. The mobile phone sets the main device according to the user's operation, or triggers the corresponding main device selection operation. Unlike adding a device, when the deleted device itself is the main device in the preset scene, the preset scene lacks a main device, so the embodiment of the present application will reselect the main device. Among them, for the situation where the main device needs to be reselected, please refer to the description in S14, that is, the user can manually select a main device, or the mobile phone or device can autonomously select a main device.
[0111] 2. When the master device and slave device in a preset scene have been set, the master device of the preset scene can be modified.
[0112] Considering that in the IoT system, devices may move, malfunction, or be damaged. These unexpected situations may cause the original master device to be unable to interact with each slave device well, which may cause certain problems in the IoT system. In order to deal with this situation, in the embodiment of the present application, when the master device and slave device in a preset scene have been set, the master device of the preset scene can also be modified. Among them, the modification situations include at least the following:
[0113] 1. The user actively modifies the main device.
[0114] When the user needs to modify the master device, he can actively check all the devices included in the preset scene in the mobile phone, and select one as the master device to modify the master device. Correspondingly, after receiving the user's device modification instruction, the mobile phone will set the device pointed to by the device modification instruction as the master device, and set the other devices included in the preset scene as slave devices. At this time, the embodiment of the present application will re-execute S15 and S16 to perform the network configuration of the master device and the communication connection between the master and slave devices.
[0115] 2. The master device reselects a new master device.
[0116] Considering the actual situation, when the slave device moves, fails or is damaged, the device state of the slave device will change to a certain extent. The device state can be any one or both of the signal connection quality with the master device and the device online state of the slave device. Therefore, when it is detected that the device state of the slave device meets certain preset conditions, the operation of reselecting the master device can be triggered. Similarly, for the master device itself, if its own device state meets certain preset conditions, it can also trigger the operation of reselecting the master device. Among them, the specific content of the preset conditions can be set by the technician according to actual needs, for example, it can be set to the situation where the signal connection quality is lower than the preset threshold, or it is detected that a slave device is offline, or it is detected that the master device itself is damaged. In addition, for the operation of selecting the master device, refer to method 2 in S14, which will not be repeated here.
[0117] Let's take an example to illustrate. In actual applications, when the master device or the slave device is moved behind some obstacles (such as behind a wall or inside a cabinet), or an obstacle is placed between the master and slave devices, the signal connection quality between the master and slave devices will decrease, or even fail to connect normally. Suppose that it drops below the preset threshold. At this time, if the preset conditions include that the signal connection quality between the master and slave devices is lower than the preset threshold, the master device will be triggered to reselect a new master device.
[0118] 3. The slave device reselects a new master device.
[0119] Considering that the master device itself may be too damaged to perform the operation of reselecting the master device, or it may be offline (such as the communication module of the master device is damaged and cannot connect to other devices). At this time, the master device cannot perform the operation of reselecting the master device. In order to cope with this situation, in the embodiment of the present application, when the master device is damaged or offline, the slave device will reselect a master device. For the operation of selecting the master device, please refer to method 2 in S14, which will not be described here.
[0120] As an optional implementation method for selecting a master device from a slave device, in an embodiment of the present application, some devices will be pre-selected as alternative devices. These alternative devices are all devices with master device capabilities, such as being able to access a preset network and establishing a communication connection with a slave device. When the slave device of the preset scene includes an alternative device, a device is selected from the alternative devices as the master device. The selection method is not limited here and can be set by the technician. For example, in some optional embodiments, a priority can be set for each alternative device, and the alternative device with the highest current priority is selected as the master device during selection. In other optional embodiments, each alternative device can also detect the signal connection quality between itself and other devices in the preset scene, and obtain corresponding quality data. At the same time, each alternative device shares its own quality data. Then, based on the quality data, an alternative device with better signal connection quality is selected as the master device.
[0121] As an optional embodiment of the present application, if the above method cannot select a suitable master device, in order to ensure the availability of the device in the preset scenario as much as possible, all devices capable of accessing the preset network in the embodiment of the present application will directly access the preset network. To achieve this goal, when the mobile phone configures the network for the master device, the master device will send the network configuration information to each slave device.
[0122] As an optional embodiment of the present application, if a suitable main device cannot be selected through the above method, the embodiment of the present application will send a prompt to the user through the mobile phone and give relevant setting suggestions.
[0123] After selecting a new master device, if the new master device is still the previous master device, there is no need to repeatedly access the preset network and repeatedly establish existing connections with the slave devices. However, when the master device is not the previous master device, the new master device needs to access the preset network according to the network configuration information, and a communication connection needs to be established between the new master device and the new slave device. Accordingly, all connections of the previous master device need to be disconnected at this time. That is, the previous master device needs to disconnect from the preset network, and the communication connection between the previous master device and other devices will also be disconnected.
[0124] 3. Preset scenes can be deleted, and different preset scenes can be directly merged.
[0125] As an optional embodiment of the present application for managing preset scenes. In the embodiment of the present application, further operations can also be performed between different preset scenes. For example, a single preset scene can be deleted, or multiple preset scenes can be merged. Details are as follows:
[0126] In the case of deleting preset scenes, if the user does not need a preset scene, the user can delete the corresponding preset scene in the mobile phone. Correspondingly, after detecting the user's deletion operation, the mobile phone will send a scene deletion instruction to the master device under the preset scene. After receiving the scene deletion instruction, the master device will disconnect the communication connection with each slave device. At the same time, it will also disconnect from the preset network.
[0127] For the merging of preset scenes, if the user wants to merge and manage multiple preset scenes, he can select the corresponding preset scene in the mobile phone and use the merge function to enter the scene merge command. Correspondingly, after the mobile phone detects the scene merge command, it will filter out all the preset scenes pointed to by the command. Then, from all the devices contained in these preset scenes, select one device as the master device, and use the remaining devices as slave devices, so as to realize the device networking of the merged scene. Among them, the operation of selecting the master device can refer to the relevant instructions of S14, which will not be repeated here.
[0128] Take an example to illustrate the merging of preset scenes. Figure 4B Based on the embodiment shown, the user chooses to merge the object scene and the bedroom scene into a room scene. At this time, all 7 devices will be attributed to the room scene. At the same time, it is assumed that the new main device selected is a smart speaker. Figure 5 , at this time, the remaining 6 devices will communicate with the smart speaker. The smart speaker will be connected to the WiFi network. Since the original air conditioner, ceiling light and corridor light have already established communication connections with the smart speaker, these devices can maintain the original connection at this time. Similarly, the smart speaker can continue to maintain access to WiFi. However, for fans, humidifiers and corridor lights, they will be disconnected from the air purifier, and the air purifier will also be disconnected from the WiFi network. And fans, humidifiers and air purifiers will also be connected to the smart speaker.
[0129] In the embodiment of the present application, by deleting or merging preset scenes, device management based on preset scenes can be implemented, thereby improving the flexibility of device management.
[0130] Fourth, a multi-level preset scene mechanism can be established so that a high-level preset scene can contain one or more low-level preset scenes at the same time.
[0131] In order to further facilitate the user to manage preset scenes and realize the flexibility of device management in the Internet of Things system, in the embodiment of the present application, different levels of preset scene mechanisms can also be established. Among them, the lowest level of preset scenes only includes devices, while the high-level preset scenes will include at least one preset scene lower than its own level.
[0132] For example, for a house with two bedrooms, the preset scene levels can be set as follows, where the scene levels from level 1 to level 5 increase in sequence:
[0133] First level scene: master bedroom and second bedroom.
[0134] Secondary scene: bedroom.
[0135] Level 3 scene: house.
[0136] At this time, for the master bedroom and second bedroom scenes, it contains the devices placed in their respective real spaces. For the bedroom, it contains the master bedroom and second bedroom scenes, that is, it contains all the devices in both preset scenes. For the house, it contains the bedroom scene, that is, it contains all the devices in the master bedroom and second bedroom scenes.
[0137] In the embodiment of the present application, the user can set the devices and other preset scene conditions contained in each preset scene according to his actual needs. On the one hand, by controlling the high-level scene, the unified control of all the devices in the low-level scenes contained in the high-level scene can be achieved. On the other hand, the user can also independently control the low-level scene. Therefore, the management of the preset scenes in the embodiment of the present application is more flexible and convenient.
[0138] 5. For devices that belong to multiple preset scenes at the same time, the responses to control commands can be differentiated.
[0139] In the embodiment of the present application, the devices that are simultaneously divided into different preset scenes are called overlapping devices. In order to ensure the normal control of overlapping devices, in the embodiment of the present application, the overlapping devices can respond to operations according to the most recently received control instructions. If control instructions sent by multiple different master devices are received at the same time, one of the control instructions can be selected for operation response according to the situation of each master device. For example, in some optional embodiments, the response priority can be set for each master device in advance. When an overlapping device receives multiple control instructions at the same time, it can determine a control instruction for operation response according to the priority.
[0140] 6. Some advanced control functions can be executed by the master device and trigger the slave device when appropriate.
[0141] Considering that there may be some differences in the software and hardware configurations of different devices, and in actual applications, users may have some functional requirements that require higher software and hardware. At this time, it is easy for the device functions to not match the user needs. For example, the user needs to turn on the fan at a scheduled time, but the fan the user actually owns does not have the function of scheduled turning on. In theory, it is impossible to control the scheduled turning on of the fan. In order to alleviate this situation, in an embodiment of the present application, the master device can assist the slave device in realizing some functions that were originally difficult for the slave device to realize. Specifically:
[0142] The master device receives a control instruction input by a user for a certain slave device, and analyzes whether the slave device has the ability to respond to the control instruction.
[0143] If the slave device has the ability to respond to the control instruction, the control instruction is sent to the slave device.
[0144] If the slave device does not have the ability to respond to the control instruction, the master device determines whether it can assist the slave device in responding to the control instruction.
[0145] If the master device can assist the slave device in responding to the control instruction, the master device performs task differentiation on the operation task corresponding to the control instruction to obtain a first operation task executable by the master device and a second operation task executable by the slave device.
[0146] The master device executes the first operation task, and after the execution is completed, sends an operation execution instruction to the slave device, where the operation execution instruction is used to instruct the slave device to execute the second operation task.
[0147] After receiving the operation execution instruction, the slave device executes the second operation task, thereby realizing the response to the control instruction.
[0148] Take an example to illustrate. Assume that the control instruction corresponds to a task of timing a function of a slave device, and the slave device does not have a timing function, but the master device has a timing function. At this time, the master device will split the timing of turning on a certain function into: timing task + turning on a certain function task. The master device executes the timing task and sends an operation execution instruction to the slave device when the required time of the timing task is reached. After receiving the operation execution instruction, the slave device executes the task of turning on a certain function.
[0149] For another example, suppose that the control instruction corresponds to a task in which a slave device detects environmental parameters and turns on a certain function when the parameters meet a certain condition. The slave device does not have the environmental parameter detection function, but the master device has the environmental parameter detection function. At this time, the master device will split the task of detecting environmental parameters and turning on a certain function when the parameters meet the preset conditions into: detecting environmental parameters task + turning on a certain function task. The master device executes the task of detecting environmental parameters, and when it reaches the point where the environmental parameters meet the preset conditions, it sends an operation execution instruction to the slave device. After receiving the operation execution instruction, the slave device executes the task of turning on a certain function.
[0150] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0151] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or combinations thereof.
[0152] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0153] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.
[0154] In addition, in the description of the present specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish descriptions and cannot be understood as indicating or implying relative importance. It should also be understood that although the terms "first", "second", etc. are used to describe various elements in some embodiments of the present application in the text, these elements should not be limited by these terms. These terms are only used to distinguish one element from another element. For example, the first preset scene can be named as the second preset scene, and similarly, the second preset scene can be named as the first preset scene without departing from the scope of the various described embodiments. The first preset scene and the second preset scene are both preset scenes, but they are not the same preset scene.
[0155] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.
[0156] The device networking method provided in the embodiment of the present application can be applied to electronic devices such as mobile phones, tablet computers, wearable devices, vehicle-mounted devices, augmented reality (AR) / virtual reality (VR) devices, laptops, ultra-mobile personal computers (UMPC), netbooks, personal digital assistants (PDA), etc., in which case these electronic devices are control devices in the embodiment of the present application. It can also be applied to various Internet of Things devices, such as smart TVs, humidifiers, fans, smart speakers, and smart air conditioners, in which case the electronic devices are Internet of Things devices. The embodiment of the present application does not impose any restrictions on the specific types of electronic devices.
[0157] For example, the control device can be a personal digital assistant (PDA) device, a handheld device with wireless communication function, a computing device or other processing device connected to a wireless modem, a vehicle-mounted device, a vehicle networking terminal, a computer, a laptop computer and / or other devices for communicating on a wireless system and a next-generation communication system, such as a mobile terminal in a 5G network or a mobile terminal in a future evolved public land mobile network (PLMN) network, etc.
[0158] As an example but not limitation, when the control device is a wearable device, the wearable device can also be a general term for wearable devices that are intelligently designed and developed using wearable technology for daily wear, such as glasses, gloves, watches, clothing and shoes. A wearable device is a portable device that is worn directly on the body or integrated into the user's clothes or accessories. Wearable devices are not just hardware devices, but also achieve powerful functions through software support, data interaction, and cloud interaction. Broadly speaking, wearable smart devices include those that are fully functional, large in size, and can achieve complete or partial functions without relying on smartphones, such as smart watches or smart glasses, as well as those that only focus on a certain type of application function and need to be used in conjunction with other devices such as smartphones, such as various smart bracelets and smart jewelry for vital sign monitoring.
[0159] Figure 6 Schematic diagram of the structure of a control device provided by an embodiment of the present application. Figure 6 As shown, the control device 6 of this embodiment includes: at least one processor 60 ( Figure 6 Only one is shown), a memory 61, wherein the memory 61 stores a computer program 62 that can be run on the processor 60. When the processor 60 executes the computer program 62, the steps in the above-mentioned device networking method embodiments are implemented. Alternatively, when the processor 60 executes the computer program 62, the functions of each module / unit in the above-mentioned device embodiments are implemented.
[0160] The control device 6 may be a computing device such as a desktop computer, a notebook, a PDA, or a cloud server. The control device may include, but is not limited to, a processor 60 and a memory 61. Those skilled in the art will appreciate that Figure 6 It is only an example of the control device 6 and does not constitute a limitation of the control device 6. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the control device may also include an input sending device, a network access device, a bus, etc.
[0161] The processor 60 may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.
[0162] In some embodiments, the memory 61 may be an internal storage unit of the control device 6, such as a hard disk or memory of the control device 6. The memory 61 may also be an external storage device of the control device 6, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. equipped on the control device 6. Further, the memory 61 may also include both an internal storage unit and an external storage device of the control device 6. The memory 61 is used to store an operating system, an application program, a boot loader (BootLoader), data, and other programs, such as the program code of the computer program. The memory 61 may also be used to temporarily store data that has been sent or is to be sent.
[0163] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0164] An embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in the above-mentioned method embodiments can be implemented.
[0165] An embodiment of the present application provides a computer program product. When the computer program product runs on a control device, the control device can implement the steps in the above-mentioned method embodiments when the computer program product is executed.
[0166] If the integrated module / unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium, etc.
[0167] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0168] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0169] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0170] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. An Internet of Things system, characterized in that: include: a first master device and at least one first slave device; The first master device obtains network configuration information, and uses the network configuration information to access a preset network; The first master device establishes a communication connection with each of the first slave devices respectively; or each of the first slave devices establishes a communication connection with the first master device respectively; each of the first slave devices does not need to access the preset network; The Internet of Things system further includes: a control device and at least two first devices; Accordingly, before the master device obtains the network configuration information, the method further includes: The second target device selects one device from the at least two first devices, sets the selected device as the first master device, sets the remaining devices in the at least two first devices as the first slave devices, and the second target device is the control device; The Internet of Things system further includes: at least two electronic devices; The Internet of Things system further includes: The control device receives a scene merging instruction input by a user, and filters out a second preset scene pointed to by the scene merging instruction; The control device selects the at least two second devices associated with the second preset scene from the at least two electronic devices; The fourth target device selects one device from the at least two first devices and the at least two second devices and updates and sets it as the first master device, and updates and sets the remaining devices in the at least two first devices and the at least two second devices as the first slave devices, and the fourth target device is the control device; The control device sends the network distribution information to the updated first master device; The updated first master device establishes a communication connection with each updated first slave device respectively; or each updated first slave device establishes a communication connection with the updated first master device respectively; The updated first master device accesses the preset network using the network configuration information.
2. The Internet of Things system according to claim 1, characterized in that: Before the target device selects a device from the at least two first devices, the method further includes: The control device acquires a first preset scene, and selects the at least two first devices associated with the first preset scene from the at least two electronic devices.
3. The Internet of Things system according to claim 2, characterized in that: The step of selecting the at least two first devices associated with the first preset scene from the at least two electronic devices includes: In response to a device selection instruction input by a user for the first preset scenario, the control device selects the at least two first devices pointed to by the device selection instruction from the at least two electronic devices; or, The control device obtains a first device list associated with the first preset scene, and selects the at least two first devices from the at least two electronic devices according to the first device list.
4. The Internet of Things system according to claim 1, characterized in that: The Internet of Things system also includes: adding new equipment; The control device receives a device classification instruction input by a user for the newly added device, and identifies whether the newly added device is a slave device according to the device classification instruction; if the newly added device is a slave device, sends a pairing instruction to the first master device; After receiving the pairing instruction, the first master device establishes a communication connection with the newly added device; or after receiving the pairing instruction, the first master device turns on the pairing mode, and the newly added device establishes a communication connection with the first master device through the pairing mode.
5. The Internet of Things system according to claim 1, characterized in that: Also includes: In response to a device modification instruction input by a user, the control device filters out a device pointed to by the device modification instruction from the at least two first devices, updates and sets the filtered device as the first master device, and updates and sets all devices other than the updated first master device among the at least two first devices as the first slave devices; The updated first master device establishes a communication connection with each updated first slave device respectively; or each updated first slave device establishes a communication connection with the updated first master device respectively; The updated first master device accesses the preset network.
6. The Internet of Things system according to claim 1, characterized in that: Also includes: The first master device detects whether the device states of the first master device and the at least one first slave device meet a preset condition; If the device status meets the preset condition, the first master device selects a device from the first master device and the at least one first slave device, updates the selected device to be the first master device, and updates the remaining devices in the Internet of Things system to be the first slave devices; The updated first master device establishes a communication connection with each updated first slave device respectively; or each updated first slave device establishes a communication connection with the updated first master device respectively; The updated first master device accesses the preset network.
7. The Internet of Things system according to claim 1, characterized in that: Also includes: The first slave device detects whether it is offline or damaged; If the first master device is offline or damaged, the third target device selects a device from the Internet of Things system, and updates the selected device to be the first master device, and updates the remaining devices in the Internet of Things system to be the first slave devices, and the third target device is any device among the at least one first slave device; The updated first master device establishes a communication connection with each updated first slave device respectively; or each updated first slave device establishes a communication connection with the updated first master device respectively; The updated first master device accesses the preset network.
8. A device networking method, characterized in that: Applied to the first master device as claimed in claim 1, comprising: The first master device obtains network configuration information, and uses the network configuration information to access a preset network; The first master device identifies at least one first slave device associated with itself, and establishes a communication connection with each of the first slave devices respectively; each of the first slave devices does not need to access the preset network.
9. A device networking method, characterized in that: The control device as claimed in claim 1 comprises: Control equipment to obtain network distribution information; The control device selects one device from at least two first devices, sets the selected device as a first master device, and sets the remaining devices from the at least two first devices as first slave devices; The control device sends the network configuration information to the first master device, so that the first master device accesses a preset network according to the network configuration information; The control device sends a first connection instruction to the first master device, and the first connection instruction is used to instruct the first master device to establish a communication connection with each of the first slave devices respectively; or the control device sends a second connection instruction to each of the first slave devices, and the second connection instruction is used to instruct each of the first slave devices to establish a communication connection with the first master device; each of the first slave devices does not need to access the preset network.
10. The device networking method according to claim 9, characterized in that: Before acquiring the network distribution information, the control device further includes: The control device acquires a first preset scene, and selects the at least two first devices associated with the first preset scene from at least two electronic devices; The control device selects one device from the at least two first devices, sets the selected device as the first master device, and sets the remaining devices from the at least two first devices as the first slave devices.
11. The device networking method according to claim 10, characterized in that: Also includes: If the control device detects a newly added device, it receives a device classification instruction input by a user for the newly added device, and identifies whether the newly added device is a slave device according to the device classification instruction; If the newly added device is a slave device, a pairing instruction is sent to the first master device, where the pairing instruction is used to instruct the first master device to establish a communication connection with the newly added device.
12. A device control method, characterized in that: Applied to the Internet of Things system as claimed in claim 1, the device control method comprises: The first master device receives a first control instruction input by a user, and selects a third slave device pointed to by the first control instruction from the at least one first slave device, wherein the first control instruction is used to control a device in the Internet of Things system; The first master device determines a second control instruction related to the third slave device according to the first control instruction, and sends the second control instruction to the third slave device; After receiving the second control instruction, the third slave device responds to the second control instruction.
13. The device control method according to claim 12, characterized in that: Also includes: If the third slave device simultaneously receives multiple control instructions including the second control instruction, it obtains the priorities of these control instructions and responds to the control instruction with the highest priority.
14. A control device, characterized in that: The control device includes a memory and a processor, wherein the memory stores a computer program that can be run on the processor, and when the processor executes the computer program, the control device implements the steps of the method as claimed in any one of claims 9 to 11.
15. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the control device implements the steps of the method according to any one of claims 9 to 11.
Citation Information
Patent Citations
Method for controlling WiFi connection and electronic equipment thereof
CN105451299A
Smart home system, configuration method, device and machine-readable storage medium
CN109039834A