Device network distribution method, device, smart desk lamp and storage medium
The smart desk lamp broadcasts identity information and detects physical contact operations to ensure a safe connection with the control device, solving the problem of insufficient connection security, reducing the risk of malicious devices, and improving user experience.
Patent Information
- Application Number
- CN202010893699.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-08-31
- Publication Date
- 2024-09-06
- Estimated Expiration
- 2040-08-31
AI Technical Summary
The connection security between smart desk lamps and control devices is insufficient, and there is a risk of malicious devices establishing communication connections.
The smart desk lamp receives the connection request from the control device by broadcasting the identity information, and after detecting the physical contact operation, establishes a communication connection with the control device to ensure that the connection is safely established under physical control.
It improves the security of the connection between the smart desk lamp and the control device, reduces the risk of communication connection with malicious devices, and ensures the safety and comfort of users.
Smart Images

Figure CN114125837B
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of smart home technology, and in particular to a device network configuration method, device, smart desk lamp, and storage medium. Background Art
[0002] With the widespread application of smart devices in life, the security of smart devices directly determines the safety of users. Among them, smart desk lamps are a common smart device, and their security also directly affects the safety and comfort of users' lives.
[0003] In the related art, when a smart desk lamp is purchased and used by a user, it can usually be directly connected to the network mode and connected to a nearby control device to complete the binding with the account in the terminal. After the binding is completed, the smart desk lamp can be controlled by the connected control device to switch the light on and off and adjust the lighting mode. Summary of the invention
[0004] The embodiments of the present application provide a device network configuration method, device, smart desk lamp and storage medium. The technical solution is as follows:
[0005] According to one aspect of the present application, a device network configuration method is provided, which is applied to a smart desk lamp, and the method includes:
[0006] Broadcasting a first wireless signal, wherein the first wireless signal includes the identity information of the smart desk lamp;
[0007] Receiving a first connection request sent by a control device based on the first wireless signal;
[0008] In response to the first connection request, detecting a first contact control instruction, where the first contact control instruction is an instruction triggered by the smart desk lamp based on a physical contact operation;
[0009] Determining that the first contact control instruction is detected;
[0010] A first connection with the control device is established in response to the first contact control instruction.
[0011] According to another aspect of the present application, a device network distribution device is provided, which is applied to a smart desk lamp, and the device includes:
[0012] A signal broadcasting module, used for broadcasting a first wireless signal, wherein the first wireless signal includes the identity information of the smart desk lamp;
[0013] A request receiving module, configured to receive a first connection request sent by a control device based on the first wireless signal;
[0014] an instruction detection module, configured to detect a first contact control instruction in response to the first connection request, wherein the first contact control instruction is an instruction triggered by the smart desk lamp based on a physical contact operation;
[0015] An instruction determination module, used for determining that the first contact control instruction is detected;
[0016] A connection establishing module is used to establish a first connection with the control device in response to the first contact control instruction.
[0017] According to another aspect of the present application, a smart desk lamp is provided, which includes a communication component, a processor, and a memory connected to the processor, wherein the memory stores at least one instruction, and the instruction is loaded and executed by the processor to implement a device networking method provided in various aspects executed by the smart desk lamp as in the present application.
[0018] According to another aspect of the present application, a computer-readable storage medium is provided, in which at least one instruction is stored, and the instruction is loaded and executed by a processor to implement a device networking method provided in various aspects executed by a smart desk lamp as in the present application.
[0019] According to one aspect of the present application, a computer program product is provided, the computer program product including computer instructions, the computer instructions being stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the method provided in various optional implementations of the account binding performed by the smart desk lamp.
[0020] The smart desk lamp can broadcast a first wireless signal containing identity information to the surroundings, and receive a first connection request from the control device based on the identity information feedback. In response to the connection request, the smart desk lamp will detect whether it is subjected to physical contact operation. After being subjected to physical contact operation, the smart desk lamp will establish a communication connection with the control device under the instruction of the physical contact operation. Since the smart desk lamp can establish a communication connection with the control device under the premise that it actually receives physical control, this solution improves the security of the smart desk lamp when establishing a connection with the control device, and reduces the risk of the smart desk lamp establishing a communication connection with a malicious control device. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] In order to more clearly introduce the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments of the present application 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 work.
[0022] Figure 1 is a structural block diagram of a smart device provided by an exemplary embodiment of the present application;
[0023] Figure 2 is a structural block diagram of a terminal provided by an exemplary embodiment of the present application;
[0024] Figure 3 is a schematic diagram of a system framework provided by an exemplary embodiment of the present application;
[0025] Figure 4 is a flow chart of a device network configuration method provided by an exemplary embodiment of the present application;
[0026] Figure 5 It is a flow chart of a device network configuration method provided by an exemplary embodiment of the present application;
[0027] Figure 6 is based on Figure 5 A schematic diagram of a user interface provided by the illustrated embodiment;
[0028] Figure 7 This is a user interface diagram of a process of binding an account provided in an embodiment of the present application;
[0029] Figure 8 It is a flow chart of a device network configuration method provided by an exemplary embodiment of the present application;
[0030] Fig. 9 It is a structural block diagram of a device network distribution apparatus provided by an exemplary embodiment of the present application. DETAILED DESCRIPTION
[0031] In order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below with reference to the accompanying drawings.
[0032] When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present application. Instead, they are only examples of devices and methods consistent with some aspects of the present application as detailed in the attached claims.
[0033] In the description of the present application, it should be understood that the terms "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance. In the description of the present application, it should be noted that, unless otherwise clearly specified and limited, the terms "connected" and "connected" should be understood in a broad sense. For example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be directly connected or indirectly connected through an intermediate medium. For ordinary technicians in this field, the specific meanings of the above terms in this application can be understood according to specific circumstances. In addition, in the description of the present application, unless otherwise specified, "multiple" means two or more. "And / or" describes the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the objects associated before and after are in an "or" relationship.
[0034] In order to facilitate the understanding of the scheme shown in the embodiments of the present application, several nouns appearing in the embodiments of the present application are introduced below.
[0035] Smart desk lamp: a desk lamp with a communication component. In the present application, the communication component may be a component that supports short-range communication. Illustratively, the communication component may be a Bluetooth component, a WiFi (Wireless Fidelity) component, or a ZigBee component. The smart desk lamp can be communicatively connected to its control device through the communication component while achieving normal lighting functions. In an embodiment of the present application, when the communication component is a Bluetooth component, the Bluetooth connection includes connections based on various published versions of the Bluetooth protocol, and also includes connections based on various new versions of the Bluetooth protocol and derivative protocols in subsequent technological developments. This embodiment of the present application is not limited to this.
[0036] In one application scenario, the smart desk lamp may include four physical buttons. The physical buttons include a main light switch button, a night light switch button, a mode switch button, and a brightness touch pad. The main light switch button is used to control the main light fixture to turn on and off. The night light switch button is used to control the night light to turn on and off. The mode switch button is used to switch the lighting mode of the currently lit lamp. The brightness touch pad is used to control the brightness of the currently lit lamp.
[0037] Optionally, the physical button can be a mechanical button that is controlled by mechanical pressing, a touch-sensitive button that is controlled by a change in capacitance or resistance, a thermal-sensitive button that is controlled by a change in heat, or a proximity-sensitive button that is controlled by a change in distance. It should be noted that the above-stated implementation of the physical button of the smart desk lamp is a schematic illustration, and any other smart desk lamp that can realize the button function is within the protection scope of this application, and the embodiments of this application do not limit this.
[0038] Control device: A device that has the ability to connect to the Internet and can connect to the smart desk lamp shown in this application. It should be noted that since the control device needs to be connected to the smart desk lamp. Therefore, the control device needs to support the same communication protocol as the smart desk lamp. When the communication protocol is a protocol with a pre-set verification password, the control device and the smart desk lamp both have a pre-set verification password.
[0039] Optionally, the control device may be a gateway or a device with networking capability.
[0040] In one possible approach, the control device, the smart desk lamp and the gateway form a local area network, and the control device and the smart desk lamp exchange information through the Internet, thereby enabling the control device to control the smart desk lamp.
[0041] In another possible method, the control device, the smart desk lamp and the gateway are connected to the Internet and exchange information with the server in the Internet. The control device sends the control information to the server, the server forwards the information to the gateway, the gateway sends the control information to the smart desk lamp, and the smart desk lamp responds to the control instruction.
[0042] Control device: an electronic device used to send control instructions to the smart desk lamp. Generally, the control device can be a mobile phone, a tablet computer, a laptop computer, and a wearable smart device, which is not limited in the embodiments of the present application. It should be noted that the control device can also be a gateway, which has the ability to control the smart desk lamp.
[0043] Indicatively, a user account can be logged into the control device, and the user account has a corresponding account identifier corresponding to it. The account identifier can be a unique identifier composed of at least one combination of numbers, letters or other characters. The control device controls the corresponding smart desk lamp through the user account, and the smart desk lamp is bound to the user account.
[0044] Optionally, when a user account is logged in to the control device, the user controls the smart desk lamp through the user account. When the user account is not logged in to the control device, the control device will not be able to control the smart desk lamp and prompt the user to log in or register an account in the control device. Illustratively, in another possible manner, the control device may be pre-logged with a default system account, which cannot be logged out. When the user uses the control device to control the smart desk lamp, the control device issues control instructions through the system account by default.
[0045] Network configuration instruction: used to instruct the smart desk lamp to enter a state of matching with the control device and establishing a communication link. When the smart desk lamp enters the network configuration state, the smart desk lamp will broadcast the device identification information to the surrounding area in a short period of time. Correspondingly, when the control device receives the device identification information, it will send a networking signal to the smart desk lamp. Indicatively, the networking signal can be a signal sent by a communication component.
[0046] Network configuration information: information used to instruct the wireless fidelity component in the smart desk lamp to connect to the wireless gateway. When the smart desk lamp is connected to the wireless gateway through the network configuration information, the wireless gateway can enable the smart desk lamp to communicate with the server through the network if it successfully accesses the Internet. In an exemplary manner, the network configuration information may include the gateway identifier and gateway password in the home, and / or the identifier and IP address of the server.
[0047] See also Figure 1 , Figure 1 is a structural block diagram of a smart desk lamp provided by an exemplary embodiment of the present application, such as Figure 1 As shown, the smart desk lamp includes a processor 120, a memory 140 and a communication component 160, wherein the memory 140 stores at least one instruction, and the instruction is loaded and executed by the processor 120 to implement the device networking method as described in the various method embodiments executed by the smart desk lamp in this application.
[0048] In the present application, the smart desk lamp 100 broadcasts a first wireless signal, which includes the identity information of the smart desk lamp; receives a first connection request sent by a control device based on the first wireless signal; detects a first contact control instruction in response to the first connection request, which is an instruction triggered by the smart desk lamp based on physical contact operation; determines that the first contact control instruction is detected; and establishes a first connection with the control device in response to the first contact control instruction.
[0049] The processor 120 may include one or more processing cores. The processor 120 uses various interfaces and lines to connect the various parts of the entire smart desk lamp 100, and executes various functions and processes data of the smart desk lamp 100 by running or executing instructions, programs, code sets or instruction sets stored in the memory 140, and calling data stored in the memory 140. Optionally, the processor 120 can be implemented in at least one hardware form of digital signal processing (DSP), field-programmable gate array (FPGA), and programmable logic array (PLA). The processor 120 can integrate one or a combination of a central processing unit (CPU), a graphics processing unit (GPU), and a modem. Among them, the CPU mainly processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing the content to be displayed on the display screen; and the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 120, but may be implemented separately through a chip.
[0050] The memory 140 may include a random access memory (RAM) or a read-only memory (ROM). Optionally, the memory 140 includes a non-transitory computer-readable storage medium. The memory 140 may be used to store instructions, programs, codes, code sets, or instruction sets. The memory 140 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the following various method embodiments, etc.; the data storage area may store data involved in the following various method embodiments, etc.
[0051] The communication component 160 is used to communicate with external electronic devices. In one possible way, the communication component 160 includes a coding unit, an amplifier, a radio frequency unit, an antenna and a decoding unit. It should be noted that the composition of the communication component in actual application can be adjusted as needed, and the embodiment of the present application is not limited to this. Illustratively, in one possible way, the communication component 160 only supports one working mode. For example, when the smart desk lamp shares a hotspot through the communication component 160, it cannot interact with the Internet at the same time. In another possible way, the smart desk lamp can share a hotspot through the communication component 160 while also interacting with the Internet.
[0052] Optionally, in one application, the communication component 160 includes one of a Bluetooth component, a WiFi component or a ZigBee component.
[0053] Optionally, in another application mode, the communication component 160 includes a Bluetooth component and a wireless fidelity component. The wireless fidelity component is used to connect to a wireless gateway, and the wireless fidelity component is used to share hotspots with surrounding devices.
[0054] For example, the device network configuration method shown in the embodiment of the present application can be applied to a control device having a display screen. The terminal can include a mobile phone, a tablet computer, a laptop, smart glasses, a smart bracelet, or a smart watch or a gateway.
[0055] See also Figure 2 , Figure 2 is a structural block diagram of a control device provided by an exemplary embodiment of the present application, such as Figure 2 As shown, the control device includes a processor 220, a memory 240 and a communication component 260, wherein the memory 240 stores at least one instruction, and the instruction is loaded and executed by the processor 220 to implement the binding method of the control device as described in the various method embodiments of the present application.
[0056] The processor 220 may include one or more processing cores. The processor 220 uses various interfaces and lines to connect the various parts of the entire control device 200, and executes various functions and processes data of the control device 200 by running or executing instructions, programs, code sets or instruction sets stored in the memory 240, and calling data stored in the memory 240. Optionally, the processor 220 can be implemented in at least one hardware form of digital signal processing (DSP), field-programmable gate array (FPGA), and programmable logic array (PLA). The processor 220 can integrate one or a combination of a central processing unit (CPU), a graphics processing unit (GPU), and a modem. Among them, the CPU mainly processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing the content to be displayed on the display screen; and the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 220, but may be implemented separately through a chip.
[0057] The memory 240 may include a random access memory (RAM) or a read-only memory (ROM). Optionally, the memory 240 includes a non-transitory computer-readable storage medium. The memory 240 may be used to store instructions, programs, codes, code sets, or instruction sets. The memory 240 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the following various method embodiments, etc.; the data storage area may store data involved in the following various method embodiments, etc.
[0058] The communication component 260 is used to communicate with the communication component 160 of the smart desk lamp to realize the function of the control device sending control instructions and other information to the smart desk lamp. In the embodiment of the present application, a first connection is established between the control device and the smart desk lamp.
[0059] Please refer to Figure 3 , Figure 3 FIG. 1 is a schematic diagram of a system framework provided by an exemplary embodiment of the present application. Figure 3 The smart desk lamp 310, the control device 320, the gateway 330 and the server 340 are included.
[0060] The smart desk lamp 310 is first connected to the gateway 330. Optionally, the first connection may be a Bluetooth connection, a WiFi connection or a ZigBee connection. Indicatively, when the first connection is a Bluetooth connection, the smart desk lamp is connected to the control device 320 via Bluetooth.
[0061] In a possible scenario, if the user of the control device 320 is in a room where the gateway 330 is installed, the communication connection between the control device 320 and the server 340 is completed through the gateway 330. The communication connection between the smart desk lamp and the server 340 is also completed through the gateway 330.
[0062] In another possible scenario, if the user of the control device 320 is outdoors without the gateway 330 , the control device 320 may also access the Internet through the mobile communication network via its own communication component, thereby establishing a communication connection with the server 340 .
[0063] Please refer to Figure 4 , Figure 4 is a flow chart of a device network configuration method provided by an exemplary embodiment of the present application. The device network configuration method can be applied to the above Figure 1 or Figure 3 In the smart desk lamp shown. Figure 4 In the device configuration method, the device configuration method includes:
[0064] Step 410: broadcast a first wireless signal, where the first wireless signal includes the identity information of the smart desk lamp.
[0065] The first wireless signal includes the identity information of the smart desk lamp. Optionally, the smart desk lamp will broadcast its own device identification information to the surrounding area when receiving the network configuration instruction.
[0066] In one possible implementation, the network configuration instruction may be triggered when the smart desk lamp receives a designated physical button operation. Alternatively, the network configuration instruction may be an instruction automatically triggered by the smart desk lamp after power is turned on. In one possible way, if the smart desk lamp is not bound to an account, the smart desk lamp automatically triggers the configuration instruction after power is turned on, and broadcasts the desk lamp identification information to the surrounding area under the action of its own network configuration instruction. In another possible way, when a physical button of the smart desk lamp is pressed, the network configuration instruction is triggered to broadcast the desk lamp identification information to the surrounding area.
[0067] Indicatively, the smart desk lamp broadcasts a first wireless signal to the surroundings, so that the control device can search for the device identification information and send a networking signal to the smart desk lamp.
[0068] Step 420: Receive a first connection request sent by the control device based on a first wireless signal.
[0069] The smart desk lamp can receive the first connection request. It should be noted that the first connection request is sent by the control device based on the first wireless signal. Therefore, the first connection request can be received and identified by the smart desk lamp.
[0070] Step 430: In response to the first connection request, a first contact control instruction is detected, where the first contact control instruction is an instruction triggered by the smart desk lamp based on a physical contact operation.
[0071] Illustratively, the smart desk lamp detects a first contact control instruction in response to the first connection request. The first contact control instruction is an instruction triggered by the smart desk lamp receiving a physical contact operation. That is, when the smart desk lamp is actually touched by the user, the smart desk lamp will trigger the contact control instruction.
[0072] In one possible way, the first contact control instruction may be an instruction triggered after a physical button in the smart desk lamp receives a touch. The physical buttons may be 1, 2, or more. Touching includes short pressing, long pressing, light pressing, heavy pressing, single pressing, and continuous pressing. On the other hand, touching also includes a combination of pressing methods between multiple buttons. When a physical button in the smart desk lamp receives a touch pressed in a predetermined manner, the first contact control instruction is triggered.
[0073] In another possible manner, the first contact control instruction may be an instruction triggered when a rotatable component in the smart desk lamp rotates. The rotatable component may be at least one of a lamp head, a knob, a cantilever, or a lamp holder, which is not limited in the embodiments of the present application. Take the rotatable component as an example. When the lamp head of the smart desk lamp is rotated from a folded state to an unfolded state, the first contact control instruction is triggered. Alternatively, when the lamp head of the smart desk lamp is rotated from an unfolded state to a folded state, the first contact control instruction is triggered.
[0074] In another possible manner, the first contact control instruction may be an instruction triggered when the housing of the smart desk lamp is knocked N times in succession. Where N is a positive integer greater than 3. The smart desk lamp detects knocking through a gyroscope, and when the instantaneous acceleration of the smart desk lamp exceeds a specified threshold, the smart desk lamp confirms that a knock has occurred. When N knocks occur in the target period, the smart desk lamp triggers the first contact control instruction.
[0075] Step 440: Determine whether a first contact control instruction is detected.
[0076] In this embodiment, the terminal can determine that the first contact control instruction is detected when the first contact control instruction is detected.
[0077] In one possible way, the smart desk lamp can detect a first pressing process triggered by a physical button of the smart desk lamp, and use the instruction triggered by the first pressing process as the first contact control instruction. It should be noted that the first pressing process can be a set of operations in which a group of physical buttons are pressed. For example, the first pressing process can be long pressing the A button for 4 seconds. Alternatively, the first pressing process can also be pressing the A button and the B button at the same time for 3 seconds. Alternatively, the first pressing process can also be long pressing the A button for 3 seconds, and then long pressing the B button for 3 seconds.
[0078] In this embodiment, when the physical button in the smart desk lamp is pressed according to the first pressing process, the smart desk lamp uses the instruction triggered by the first pressing process as the first contact control instruction.
[0079] Step 450: Establish a first connection with a control device in response to a first contact control instruction.
[0080] In the embodiment of the present application, the smart desk lamp can establish a first connection with the control device in response to the first contact control instruction. It should be noted that when the control device is a device that can directly communicate with the Internet, the smart desk lamp can access the Internet through the control device.
[0081] In one possible method of establishing a first connection, the smart desk lamp reads an instruction string corresponding to a first contact control instruction; matches the corresponding instruction string with a preset information template; and when the corresponding instruction string matches the preset information template, responds to the first connection request to establish a first connection with the control device.
[0082] For example, when the smart desk lamp is powered on and a physical button is pressed, a first contact control instruction is generated, and the first contact control instruction carries a corresponding instruction string. The smart desk lamp matches the corresponding instruction string with a preset information template, and when the corresponding instruction string matches the preset information template, the smart desk lamp responds to the first connection request and establishes a first connection with the control device.
[0083] In the process of reading the corresponding instruction string in the first contact control instruction, the smart desk lamp can monitor the information input interface of the physical button. When the information input interface generates data, the data is obtained as an instruction string. Since the present application does not require the process of powering off and then powering on the smart desk lamp, the user does not have to interrupt the lighting service provided by the smart desk lamp during the process of binding the smart desk lamp to the master account in the control device, thereby improving the continuous working ability of the smart desk lamp and avoiding the problem of restricted user movement due to power outages.
[0084] Schematically, a possible implementation of the present application is described by taking a smart desk lamp as an example. When the desk lamp is powered on, it receives a contact control instruction acting on a physical button; when the button information matches a preset information template, the desk lamp is controlled to light up in a reminder mode, and the reminder mode is used to prompt the desk lamp that it is acquiring networking configuration information; and the networking configuration information is acquired through a secure communication link. The reminder mode may include flashing, highlighting, or emitting colored light.
[0085] In summary, since the smart desk lamp can broadcast the first wireless signal containing identity information to the surroundings, and receive the first connection request fed back by the control device based on the identity information, in response to the connection request, the smart desk lamp will detect whether it is subjected to physical contact operation. After being subjected to physical contact operation, the smart desk lamp will establish a communication connection with the control device under the instruction of the physical contact operation. Since the smart desk lamp can establish a communication connection with the control device under the premise that it actually receives physical control. Therefore, this solution improves the security of the smart desk lamp when establishing a connection with the control device, and reduces the risk of the smart desk lamp establishing a communication connection with a malicious control device.
[0086] After the first connection is established between the smart desk lamp and the control device, the smart desk lamp can also be connected to the Internet. The process of the method is performed after the step 450 is completed. After the step 450 is completed, the smart desk lamp can perform steps (a), (b) and (c).
[0087] Step (a): receiving wireless network configuration information sent by the control device through the first connection, wherein the wireless network configuration information includes network device information and account information.
[0088] In one possible manner, the network device information may be a network device MAC address or other identification information. Alternatively, the account information may be the SSID of a wireless router and a corresponding password.
[0089] Step (b), establishing a second connection with the wireless router according to the network device information.
[0090] It should be noted that, in the embodiment of the present application, the wireless router and the gateway may be the same device. The second connection may be a short-range wireless communication connection based on wireless fidelity technology.
[0091] Step (c), sending a binding request to the server through the second connection, wherein the binding request includes the account information, and the binding request is used to bind the smart desk lamp and the master control account logged in to the control device.
[0092] In an embodiment of the present application, the smart desk lamp is connected to a Bluetooth device, and the Bluetooth device is connected to the Internet.
[0093] In an illustrative manner, after establishing a connection with the Internet, the smart desk lamp can access the server through the server's IP address or other given addresses, and send a binding request to the server. The binding request includes the master account identifier and the smart desk lamp identifier. The master account identifier is used to indicate the currently logged-in account in the control device.
[0094] Optionally, in this embodiment, the smart desk lamp will be able to respond to the successful binding message returned by the server, which is used to indicate that the server has established a binding relationship between the smart desk lamp and the control device. Based on this scenario, the smart desk lamp will locally save the binding relationship between the smart desk lamp and the control device so that it can be controlled by the master account in the control device in the subsequent process.
[0095] In the embodiment of the present application, the smart desk lamp can also set a device shadow in the server. Specifically, the smart desk lamp sends a device shadow creation request to the server, and the device shadow creation request is used to request to create a dynamic backup in the server that is consistent with the operating status of the smart desk lamp; in response to the device creation success message returned by the server, the status information is synchronized to the server according to the agreed period, and the agreed period is the period information contained in the device shadow creation request.
[0096] It should be noted that the device shadow can include two functions. In one possible function, the device shadow is used for delayed control. When the smart desk lamp is powered off, the smart desk lamp in the server is offline, and the server records the status data of the smart desk lamp when it is powered off in the device shadow. When the smart desk lamp is powered on again, the server can restore the state of the smart desk lamp before the power failure according to the device shadow. In addition, due to the existence of the device shadow, the control device can normally issue instructions to the smart desk lamp during the period when the smart desk lamp is powered off. After being powered on and online, the smart desk lamp will respond to the instructions issued by the control device, so that the instructions issued by the control device are responded to with a delay, avoiding the problem that the instructions issued by the control device cannot be responded to.
[0097] In another possible role, the device shadow can prevent multiple devices with control permissions from intensively operating the smart desk lamp in a short period of time. For example, within a specified control cycle, control device A sends a command to the smart desk lamp to press the main light switch button, and control device B also sends a command to the smart desk lamp to press the main light switch button. The device shadow can discard the command sent by the first control device A, and only respond to the command sent by control device B to press the main light switch button to the smart desk lamp at the same time, so that the smart desk lamp can turn off the light normally, avoiding abnormal responses of the smart desk lamp caused by frequent operations of multiple control devices.
[0098] In one possible way, when the smart desk lamp has been bound to the master account, the smart desk lamp will no longer respond to binding requests from other accounts. In a specific implementation, when the smart desk lamp has created a corresponding device shadow in the server, a prompt message of rejecting the binding is output. The prompt message of rejecting the binding can be either a graphic message displayed on the display screen or a voice message played through the speaker.
[0099] In summary, the embodiment of the present application can receive the wireless network configuration information sent by the control device through the first connection when the smart desk lamp and the control device are in the first connection. Subsequently, the smart desk lamp can establish a second connection with the wireless router according to the network device information and account information in the wireless network configuration information. On this basis, the smart desk lamp sends a binding request to the server through the second connection. The binding request includes the account information of the smart desk lamp. The account will be bound to the main control account logged in to the control device. It can be seen that the embodiment of the present application can enter the binding relationship into the server in the cloud after the smart desk lamp safely establishes the first connection with the control device, thereby realizing the safe remote control of the smart desk lamp. On the premise of ensuring the safety of the smart desk lamp being controlled, the ability of the smart desk lamp to be remotely controlled is improved.
[0100] Based on the solution disclosed in the previous embodiment, the embodiment of the present application can also introduce the display of this solution from the control device side, please refer to the following embodiment.
[0101] See also Figure 5 , Figure 5 This is a flow chart of a device network configuration method provided by an exemplary embodiment of the present application. The device network configuration method can be applied to the above Figure 1 or Figure 3 In the control device shown. Figure 5 In the device configuration method, the device configuration method includes:
[0102] Step 510, in response to completion of the entry of the login information, an account login request is sent to the server.
[0103] Illustratively, in the control device, the smart device can be controlled by system applications or by third-party applications.
[0104] This embodiment is introduced by taking the control device controlling the smart device through the system application as an example.
[0105] When the system application in the control device is started, or when it is started for the first time, the system application will display the login interface of the user account, and the user can receive the login information entered by the user through the login interface. When the user completes the input of the login information, the control device will send an account login request to the server. Among them, the account login request is used to request to log in the master account corresponding to the above login information in the server.
[0106] Step 520, in response to the login success message returned by the server, search for the first wireless signal in the surrounding area, and after searching for the first wireless signal, transmit a networking signal to the smart desk lamp corresponding to the identity information in the first wireless signal.
[0107] Step 530, instructing the smart desk lamp to establish a first connection with the control device.
[0108] Optionally, the display screen of the control device may also display different contents in the above-mentioned different stages, so that the user can understand the binding progress of the smart desk lamp and the control device.
[0109] For illustration, see Figure 6 , Figure 6 is based on Figure 5 A schematic diagram of a user interface provided by the illustrated embodiment. Figure 6 In the embodiment, the control device may execute step 610, step 620 and step 630.
[0110] Step 610, when sending a networking signal to the smart desk lamp, the control device displays a status display interface, and the status display interface is used to indicate the current relationship between the control device and the smart desk lamp to be connected.
[0111] Step 620, when the first connection is successfully established with the smart desk lamp, a cover layer is displayed on the status display interface through the display screen, and the cover layer displays networking operation information, which is used to set the wireless fidelity component in the smart desk lamp to access the wireless gateway in the home.
[0112] Step 630: When a successful binding message is received, corresponding prompt information is displayed on the status display interface.
[0113] See also Figure 7 , Figure 7 Schematic diagram of a user interface of a smart desk lamp binding process provided by an embodiment of the present application. Figure 7, the user interface changes from state 710 to state 720, state 730 and state 740 in sequence. In state 710, the user interface is a state display interface. The state display interface displays "Scanning device", that is, the message is used to indicate that the control device is scanning the identification of the desk lamp. When the control device scans the identification of the desk lamp, state 710 changes to state 720. In state 720, a cover layer 721 is displayed on the state display interface, and "Networking confirmation: Long press the left read-write key until the main light flashes and then release it, and complete the next operation according to the application prompts." Then, when the desk lamp returns to the control device that the networking confirmation operation has been completed, the control device closes the cover layer. The display state of the display screen changes to state 730, and the control device establishes a first connection with the smart desk lamp. In state 730, the control device displays the binding progress of the current control device and the desk lamp in the form of a percentage animation. When the control device receives a successful binding message, the control device will display the corresponding prompt information on the state display interface. At this time, state 730 changes to state 740. In state 740, the corresponding prompt message is "Device added successfully, your new device is ready."
[0114] In summary, the control device introduced in the embodiment of the present application can remind the user in the user interface that the user needs to press a physical button on the smart desk lamp at an appropriate time to achieve the first connection between the smart desk lamp and the control device. Since the prompt on the control terminal is clear and timely, the smart desk lamp can establish the first connection with the control device in a safe manner, thereby improving the security of the connection between the control device and the smart desk lamp.
[0115] See also Figure 8 , Figure 8 1 is a flow chart of a device network configuration method provided in an embodiment of the present application. The device network configuration process can be applied to a smart desk lamp. Figure 8 FIG. 4 shows that the smart desk lamp executes the method after completing steps 410 to 450, step (a), step (b) and step (c) as shown in the above method. The method includes the following steps.
[0116] Step 811, detecting a second contact control instruction, where the second contact control instruction is an instruction triggered by a physical button of the smart desk lamp under a second pressing process.
[0117] In this example, the smart desk lamp can detect the second contact control instruction. It should be noted that the second contact control instruction is an instruction triggered by the physical button of the smart desk lamp under the second pressing process. The second pressing process can be a different pressing process from the first pressing process. That is, the process of pressing the physical button to trigger the first contact control instruction is different from the process of pressing the physical button to trigger the second contact control instruction.
[0118] Step 812, control the light-emitting component in the smart desk lamp to emit light in a first light-emitting mode.
[0119] Illustratively, the smart desk lamp can control the light-emitting components in the smart desk lamp to emit light in a first light-emitting mode, wherein the first light-emitting mode includes flashing, highlighting or color light-emitting modes.
[0120] Step 813: In response to the second contact control instruction, scan the second wireless signal broadcast by the device to be connected, where the second wireless signal includes the identity information of the device to be connected.
[0121] In this example, the smart desk lamp will be used as a device to scan surrounding connected devices. The smart desk lamp has scanning capabilities.
[0122] Optionally, the device to be connected may be a sensor without a physical button, the device to be connected may be a sensor including a physical button, or the device to be connected may be a lamp including a physical button.
[0123] When this solution is applied, all lamps in the home can be automatically connected to the smart desk lamp, using the smart desk lamp as a gateway.
[0124] Step 820: Verify the identity information of the device to be connected.
[0125] Optionally, the smart desk lamp can verify the identity information of the device to be accessed. In one possible verification method, the smart desk lamp can send the identity information to the server, and the server verifies whether the device to be accessed is a genuine device. In another possible verification method, the smart desk lamp can obtain the MAC address of the device to be accessed and the name of the device to be accessed. The smart desk lamp verifies whether the name of the device to be accessed complies with the preset naming rules. For example, the preset rule is "taideng-X". Among them, "taideng" is a fixed character, and "X" represents the last two digits of the MAC address. When the name of the device to be accessed does not comply with the preset naming rules, the smart desk lamp will directly reject the access request of the device to be accessed.
[0126] Step 830: When the identity information of the device to be connected is verified, a third connection is established with the device to be connected.
[0127] Illustratively, step 830 can be implemented through step (1), step (2) and step (3).
[0128] Step (1), sending a second connection request to the device to be connected, the second connection request is used to inquire whether the device to be connected confirms to establish a third connection with the smart desk lamp.
[0129] It should be noted that the third connection may be a Bluetooth connection, a WiFi connection or a Zigbee connection.
[0130] Step (2), controlling the light-emitting component in the smart desk lamp to emit light in a second light-emitting mode.
[0131] In this example, in order to give a targeted reminder to the user, the first light pattern and the second light pattern are different light patterns.
[0132] Step (3), in response to the connection confirmation information sent by the device to be connected, establish a third connection with the device to be connected.
[0133] It should be noted that when the device to be connected has a physical button, the device to be connected needs to press the physical button according to the third pressing process before sending the second wireless signal to the smart desk lamp. It can be seen that the controllability and security of the connection can also be guaranteed when the device to be connected is connected to the smart desk lamp.
[0134] To sum up, the device networking method provided in the embodiment of the present application can enable the smart desk lamp to act as a gateway and securely connect to surrounding devices to be connected, which not only improves the security of the smart desk lamp accessing the control device, but also improves the security of other devices to be connected accessing the smart desk lamp.
[0135] The following is an embodiment of the device of the present application, which can be used to execute the embodiment of the method of the present application. For details not disclosed in the embodiment of the device of the present application, please refer to the embodiment of the method of the present application.
[0136] Please refer to Fig. 9 , Fig. 9 This is a structural block diagram of a device network configuration device provided by an exemplary embodiment of the present application. The device network configuration device can be implemented as all or part of a terminal through software, hardware, or a combination of both. The device includes:
[0137] A signal broadcasting module 910, configured to broadcast a first wireless signal, wherein the first wireless signal includes the identity information of the smart desk lamp;
[0138] A request receiving module 920, configured to receive a first connection request sent by a control device based on the first wireless signal;
[0139] An instruction detection module 930, configured to detect a first contact control instruction in response to the first connection request, where the first contact control instruction is an instruction triggered by the smart desk lamp based on a physical contact operation;
[0140] An instruction determination module 940 is used to determine that the first contact control instruction is detected;
[0141] The connection establishing module 950 is used to establish a first connection with the control device in response to the first contact control instruction.
[0142] In an optional embodiment, the device also includes a wireless network configuration module, which is used to receive wireless network configuration information sent by the control device through the first connection, and the wireless network configuration information includes network device information and account information; establish a second connection with a wireless router based on the network device information; send a binding request to the server through the second connection, and the binding request includes the account information. The binding request is used to bind the smart desk lamp and the master control account logged in to the control device.
[0143] In an optional embodiment, the first contact control instruction is an instruction triggered when a physical button in the smart desk lamp receives a touch; and / or, the first contact control instruction is an instruction triggered when a rotatable part in the smart desk lamp rotates.
[0144] In an optional embodiment, the connection establishment module 950 is used to read the instruction string corresponding to the first contact control instruction; match the corresponding instruction string with a preset information template; and when the corresponding instruction string matches the preset information template, respond to the first connection request to establish the first connection with the control device.
[0145] In an optional embodiment, the connection establishment module 950 is used to monitor the information input interface of the physical key; when the information input interface generates data, the data is obtained as the instruction string.
[0146] In an optional embodiment, the first connection involved in the device is one of a Bluetooth connection, a WiFi connection or a Zigbee connection.
[0147] In an optional embodiment, the instruction detection module 930 is used to detect a first pressing process triggered by a physical button of the smart desk lamp; and use the instruction triggered by the first pressing process as the first contact control instruction.
[0148] In an optional embodiment, the device also includes a networking module for detecting a second contact control instruction, which is an instruction triggered by a physical button of the smart desk lamp under a second pressing process; in response to the second contact control instruction, scanning a second wireless signal broadcast by the device to be accessed, the second wireless signal including identity information of the device to be accessed; verifying the identity information of the device to be accessed; and establishing a third connection with the device to be accessed when the identity information of the device to be accessed passes the verification.
[0149] In an optional embodiment, the networking module is used to send a second connection request to the device to be connected, and the second connection request is used to inquire whether the device to be connected confirms to establish the third connection with the smart desk lamp; in response to the connection confirmation information sent by the device to be connected, establish the third connection with the device to be connected.
[0150] In an optional embodiment, the device further includes a lighting reminder module, which is used to control the light-emitting component in the smart desk lamp to emit light in a first lighting mode; and control the light-emitting component in the smart desk lamp to emit light in a second lighting mode.
[0151] In summary, the equipment network distribution device provided in this embodiment can enable the smart desk lamp to broadcast a first wireless signal containing identity information to the surroundings, and receive a first connection request fed back by the control device based on the identity information. In response to the connection request, the smart desk lamp will detect whether it is subjected to physical contact operation. After being subjected to physical contact operation, the smart desk lamp will establish a communication connection with the control device under the instruction of the physical contact operation. Since the smart desk lamp can establish a communication connection with the control device under the premise that it actually receives physical control. Therefore, this solution improves the security of the smart desk lamp when establishing a connection with the control device, and reduces the risk of the smart desk lamp establishing a communication connection with a malicious control device.
[0152] An embodiment of the present application also provides a computer-readable medium storing at least one instruction, wherein the at least one instruction is loaded and executed by the processor to implement the device network configuration method executed by the smart device as described in the above embodiments.
[0153] It should be noted that: the device network configuration device provided in the above embodiment only uses the division of the above functional modules as an example when executing the device network configuration method. In actual applications, the above functional distribution can be completed by different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the device network configuration device provided in the above embodiment and the device network configuration method embodiment belong to the same concept, and the specific implementation process is detailed in the method embodiment, which will not be repeated here.
[0154] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.
[0155] A person skilled in the art will understand that all or part of the steps to implement the above embodiments may be accomplished by hardware or by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a disk or an optical disk, etc.
[0156] The above description is only an illustrative embodiment that can be implemented in the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application should be included in the scope of protection of the present application.
Claims
1. A device network configuration method, characterized in that: Applied to a smart desk lamp, the method comprises: Broadcasting a first wireless signal, wherein the first wireless signal includes the identity information of the smart desk lamp; Receiving a first connection request sent by a control device based on the first wireless signal; In response to the first connection request, detecting a first contact control instruction, where the first contact control instruction is an instruction triggered by the smart desk lamp based on a physical contact operation; Determining that the first contact control instruction is detected; Reading the instruction character string corresponding to the first contact control instruction; Matching the corresponding instruction string with a preset information template; When the corresponding instruction string matches the preset information template, a first connection is established with the control device in response to the first connection request.
2. The method according to claim 1, characterized in that: The method further comprises: receiving wireless network configuration information sent by the control device through the first connection, wherein the wireless network configuration information includes network device information and account information; Establishing a second connection with the wireless router according to the network device information; A binding request is sent to the server through the second connection, wherein the binding request includes the account information, and the binding request is used to bind the smart desk lamp and the master control account logged in to the control device.
3. The method according to claim 1, characterized in that The first touch control instruction is an instruction triggered after a physical button in the smart desk lamp receives a touch; and / or, The first contact control instruction is an instruction triggered when the rotatable component in the smart desk lamp rotates.
4. The method according to claim 3, characterized in that The first contact control instruction is an instruction triggered after a physical button in the smart desk lamp receives a touch, and the instruction string corresponding to the first contact control instruction is read as follows: An information input interface for monitoring the physical buttons; When the information input interface generates data, the data is acquired as the instruction character string.
5. The method according to claim 1, characterized in that The first connection is one of a Bluetooth connection, a WiFi connection or a Zigbee connection.
6. The method according to claim 1, characterized in that The detecting the first contact control instruction comprises: Detecting a first pressing process triggered by a physical button of the smart desk lamp; The instruction triggered by the first pressing process is used as the first contact control instruction.
7. The method according to claim 2, characterized in that The step of establishing a second connection with the wireless router according to the network device information includes: Detecting a second contact control instruction, where the second contact control instruction is an instruction triggered by a physical button of the smart desk lamp under a second pressing process; In response to the second contact control instruction, scanning a second wireless signal broadcast by the device to be connected, wherein the second wireless signal includes identity information of the device to be connected; Verifying the identity information of the device to be connected; When the identity information of the device to be connected is verified, a third connection is established with the device to be connected.
8. The method according to claim 7, characterized in that The establishing a third connection with the device to be connected comprises: Sending a second connection request to the device to be connected, where the second connection request is used to inquire whether the device to be connected confirms to establish the third connection with the smart desk lamp; In response to the connection confirmation information sent by the device to be connected, a third connection is established with the device to be connected.
9. The method according to claim 8, characterized in that Before scanning the second wireless signal broadcast by the device to be connected, the method includes: controlling the light-emitting component in the smart desk lamp to emit light in a first light-emitting mode; After sending the second connection request to the device to be connected, the method includes: controlling the light-emitting component in the smart desk lamp to emit light in a second light-emitting mode.
10. A device network distribution device, characterized in that: Applied to a smart desk lamp, the device comprises: A signal broadcasting module, used for broadcasting a first wireless signal, wherein the first wireless signal includes the identity information of the smart desk lamp; A request receiving module, configured to receive a first connection request sent by a control device based on the first wireless signal; an instruction detection module, configured to detect a first contact control instruction in response to the first connection request, wherein the first contact control instruction is an instruction triggered by the smart desk lamp based on a physical contact operation; An instruction determination module, used for determining that the first contact control instruction is detected; A connection establishment module is used to read the instruction string corresponding to the first contact control instruction; match the corresponding instruction string with a preset information template; when the corresponding instruction string matches the preset information template, respond to the first connection request to establish a first connection with the control device.
11. A smart desk lamp, characterized in that: The smart desk lamp includes a communication component, a processor, a memory connected to the processor, and program instructions stored in the memory. When the processor executes the program instructions, the device networking method as described in any one of claims 1 to 9 is implemented.
12. A computer-readable storage medium, wherein program instructions are stored in the storage medium, characterized in that: When the program instructions are executed by the processor, the device network configuration method as described in any one of claims 1 to 9 is implemented.
13. A computer program product, characterized in that The computer program product includes computer instructions, which are stored in a computer-readable storage medium; a processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the device network configuration method as described in any one of claims 1 to 9.
