A communication method and intelligent door lock
By arranging an auxiliary control chip and drive circuit in the lock body of the smart door lock, and using encrypted command packet transmission, the problem of low security performance of the existing smart door lock is solved, and the security and control security of the door lock are improved.
Patent Information
- Application Number
- CN201910859277.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2019-09-11
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2039-09-11
AI Technical Summary
The safety performance of existing smart door locks is low and there are serious safety risks, because the circuit that drives the motor clutch is usually placed inside the panel, and the motor can be directly controlled after the outer panel is removed, resulting in insufficient safety.
An auxiliary control chip and a drive circuit are set in the lock body of the smart door lock, and a main control chip is set in the panel. The main control chip transmits the encrypted command packet to the auxiliary control chip, allowing it to control the drive motor to open and close the lock. Improve security.
Through the transmission of encrypted command packets and response packets, the security of the smart door lock is improved, illegal control is prevented, and the security performance of the door lock is enhanced.
Smart Images

Figure CN112482897B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of smart door locks, and in particular to a communication method and a smart door lock. Background Art
[0002] With the development of science and technology, the application scope of smart door locks has gradually expanded. Smart door locks are a type of door lock that triggers the control circuit or chip through user interaction, completes the unlocking or locking of the door lock when the control circuit or chip is verified, and obtains the door lock status.
[0003] Existing smart door locks are divided into three parts, including an outer panel, an inner panel and a lock body. The outer panel contains circuits for interacting with users and is installed on the outside of the house. The inner panel contains structural parts, batteries and some control circuits and is installed inside the house. The lock body includes a mechanical transmission part and a motor clutch. The door lock is locked and unlocked by popping out or retracting the motor clutch, and the lock body is embedded in the door. However, the circuit for driving the motor clutch of the existing door lock is usually placed in the panel, so the pins of the motor clutch need to be connected to the panel by wiring. When the outer panel is removed, the wiring of the motor clutch in the lock body can be led out, and an external power supply can directly control the motor, thereby controlling the opening and closing of the door, which has low safety performance.
[0004] Therefore, existing smart door locks have serious potential safety hazards and low safety performance. Summary of the invention
[0005] In view of this, an embodiment of the present invention provides a communication method and a smart door lock to solve the problems of serious safety hazards and low safety performance of existing smart door locks.
[0006] To achieve the above objectives, the embodiments of the present invention provide the following technical solutions:
[0007] A first aspect of an embodiment of the present invention discloses a smart door lock, comprising: a panel and a lock body, wherein the panel comprises at least a main control chip, and the lock body comprises at least an auxiliary control chip, a drive circuit connected to the auxiliary control chip, and a motor connected to the drive circuit;
[0008] The main control chip is connected to the auxiliary control chip and is used to send the encrypted command packet to the auxiliary control chip;
[0009] The auxiliary control chip is used to receive the encrypted command packet and decrypt it to obtain a command packet containing a door lock opening and closing command, and control the drive circuit to drive the motor to control the smart door lock to unlock or lock based on the command packet;
[0010] Wherein, the auxiliary control chip and the main control chip are authenticated in advance.
[0011] Preferably, the main control chip is specifically used to calculate the checksum of the command packet using a preset checksum algorithm, and based on a random number, a pre-stored key and the checksum of the command packet, a preset encryption algorithm is used to calculate the main control chip signature, and the random number and the main control chip signature are added to the command packet to obtain the encrypted command packet.
[0012] Preferably, the auxiliary control chip is also used to generate an encrypted response packet containing the door lock opening and closing status, and feed it back to the main control chip.
[0013] Preferably, the auxiliary control chip is specifically used to calculate the checksum of the response packet using a checksum algorithm, and based on a random number, a pre-stored key and the checksum of the response packet, a preset encryption algorithm is used to calculate the auxiliary control chip signature, and the auxiliary control chip signature is added to the response packet to obtain the encrypted response packet.
[0014] Preferably, the main control chip is also used to: decrypt the encrypted response packet fed back by the auxiliary control chip to obtain a response packet containing the opening and closing status of the door lock.
[0015] Preferably, the lock body further comprises:
[0016] a sensor connected to the auxiliary control chip, and used to collect status data of the lock body and send the status data of the lock body to the auxiliary control chip;
[0017] The auxiliary control chip is also used to send the status data of the lock body to the main control chip;
[0018] The main control chip is also used to receive the status data of the lock body sent by the auxiliary control chip.
[0019] Preferably, the main control chip and the auxiliary control chip are connected via an I2C bus, an SPI bus or a Uart bus.
[0020] Preferably, the motor driving circuit is specifically used to drive the motor to rotate forward to control the smart door lock to unlock, and drive the motor to rotate reversely to control the smart door lock to lock; or, drive the motor to rotate forward to control the smart door lock to lock, and drive the motor to rotate reversely to control the smart door lock to unlock.
[0021] Preferably, the sensor includes a mechanical switch, an infrared photoelectric sensor, a Hall switch, a magnetic sensor or a laser sensor.
[0022] A second aspect of an embodiment of the present invention discloses a communication method, which is applicable to a main control chip. The method includes:
[0023] The main control chip encrypts the command packet;
[0024] The main control chip sends the encrypted command packet to the auxiliary control chip, so that the auxiliary control chip decrypts the encrypted command packet and controls the smart door lock to unlock or lock.
[0025] Preferably, the main control chip encrypts the command packet, including:
[0026] The main control chip calculates the checksum of the command packet using a preset checksum algorithm;
[0027] The main control chip calculates the main control chip signature using a preset encryption algorithm based on a random number, a pre-stored key and a checksum of the command packet;
[0028] The main control chip adds the random number and the main control chip signature to the command packet to obtain the encrypted command packet.
[0029] A third aspect of an embodiment of the present invention discloses a communication method, which is applicable to an auxiliary control chip. The method includes:
[0030] The auxiliary control chip receives the encrypted command packet sent by the main control chip;
[0031] The auxiliary control chip decrypts the encrypted command packet to obtain a command packet including a door lock opening and closing command;
[0032] The auxiliary control chip controls the driving circuit to drive the motor based on the command packet to control the smart door lock to unlock or lock.
[0033] Preferably, after the auxiliary control chip controls the driving circuit to drive the motor based on the command packet to control the smart door lock to unlock or lock, it also includes:
[0034] The auxiliary control chip generates an encrypted response packet containing the door lock opening and closing status, and feeds the encrypted response packet back to the main control chip, so that the main control chip decrypts the encrypted response packet to obtain a response packet containing the door lock opening and closing status.
[0035] Preferably, the auxiliary control chip generates an encrypted response packet containing the door lock opening and closing status, including:
[0036] The auxiliary control chip calculates the checksum of the response packet using a checksum algorithm;
[0037] The auxiliary control chip calculates the auxiliary control chip signature using a preset encryption algorithm based on a random number, a pre-stored key and a checksum of the response packet;
[0038] The auxiliary control chip adds the auxiliary control chip signature to the response packet to obtain the encrypted response packet.
[0039] Based on the above-mentioned embodiment of the present invention, a communication method and a smart door lock are provided. The smart door lock includes a panel and a lock body. The panel includes at least a main control chip, and the lock body includes at least: an auxiliary control chip, a drive circuit connected to the auxiliary control chip, and a motor connected to the drive circuit. The main control chip sends the encrypted command packet to the auxiliary control chip. The auxiliary control chip receives the encrypted command packet and decrypts it to obtain a command packet containing a door lock opening and closing command, and controls the smart door lock to unlock or lock. In this solution, by setting an auxiliary control chip and a drive circuit in the lock body, when controlling the lock body, the main control chip set in the panel transmits the encrypted command packet to the auxiliary control chip, so that the auxiliary control chip controls the drive circuit to drive the motor to perform the door lock opening and closing operations, thereby improving the security of the smart door lock. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, 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 embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.
[0041] Figure 1 A schematic diagram of the structure of a smart door lock provided by an embodiment of the present invention;
[0042] Figure 2 A schematic diagram of the structure of a smart door lock provided by an embodiment of the present invention;
[0043] Figure 3 A schematic diagram of the architecture of a smart door lock provided by an embodiment of the present invention;
[0044] Figure 4 A flow chart of a communication method provided by an embodiment of the present invention;
[0045] Figure 5a A schematic diagram of the command packet structure provided by an embodiment of the present invention;
[0046] Figure 5b A schematic diagram of the structure of a response packet provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0047] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0048] In this application, the terms "comprises", "comprising" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprising a ..." does not exclude the presence of other identical elements in the process, method, article or device comprising the element.
[0049] As can be seen from the background technology, the circuit of the driving motor clutch of the existing door lock is usually placed inside the panel, so the pins of the motor clutch need to be connected to the panel by wiring. When the outer panel is removed, the wiring of the motor clutch in the lock body can be led out, and an external power supply can directly control the motor, thereby controlling the opening and closing of the door, and the safety performance is low.
[0050] Therefore, an embodiment of the present invention provides a communication method and a smart door lock. When controlling the lock body, the encrypted command packet is transmitted to the auxiliary control chip in the lock body through the main control chip arranged in the panel, so that the auxiliary control chip controls the drive circuit placed in the lock body to drive the motor to perform opening and closing operations, thereby improving the security of the smart door lock.
[0051] It should be noted that currently, the encryption methods for command packets and response packets are divided into symmetric encryption and asymmetric encryption. The encryption method involved in the embodiment of the present invention takes the symmetric encryption method as an example, but the encryption method in the embodiment of the present invention is not limited to the symmetric encryption method.
[0052] refer to Figure 1 , shows a structural schematic diagram of a smart door lock provided by an embodiment of the present invention, the smart door lock includes: a panel 101 and a lock body 102, the panel 101 includes at least a main control chip 1011, the lock body 102 includes at least: an auxiliary control chip 1021, a drive circuit 1022 connected to the auxiliary control chip 1021, and a motor 1023 connected to the drive circuit 1022.
[0053] The main control chip 1011 is connected to the auxiliary control chip 1021 and is used to send the encrypted command packet to the auxiliary control chip 1021 .
[0054] In a specific implementation, the main control chip 1011 is specifically used to calculate the checksum of the command packet using a preset checksum algorithm, and based on a random number, a pre-stored key and the checksum of the command packet, a preset encryption algorithm is used to calculate the main control chip signature, and the random number and the main control chip signature are added to the command packet to obtain the encrypted command packet.
[0055] In a specific implementation, the main control chip 1011 and the auxiliary control chip 1021 are specifically connected via an I2C bus, an SPI bus, or a Uart bus. It should be noted that the communication method between the main control chip 1011 and the auxiliary control chip 1021 includes but is not limited to the above-mentioned I2C bus, SPI bus, or Uart bus, and can also be other communication methods, which will not be illustrated one by one here.
[0056] It should be noted that before the main control chip 1011 and the auxiliary control chip 1021 perform data communication, the auxiliary control chip 1021 and the main control chip 1011 are authenticated in advance. The specific authentication method includes but is not limited to: the main control chip 1011 and the auxiliary control chip 1021 are authenticated by their unique ID numbers defined when they leave the factory, and data communication can only be performed after the authentication is passed.
[0057] Preferably, the main control chip 1011 is also used to: decrypt the encrypted response packet fed back by the auxiliary control chip 1021 to obtain a response packet containing the opening and closing status of the door lock.
[0058] The auxiliary control chip 1021 is used to receive the encrypted command packet and decrypt it to obtain a command packet containing a door lock opening and closing command, and based on the command packet, control the drive circuit 1022 to drive the motor 1023 to control the smart door lock to unlock or lock.
[0059] Preferably, in a specific implementation, after the auxiliary control chip 1021 controls the drive circuit 1022 to drive the motor 1023 to control the smart door lock to unlock or lock based on the command packet, the auxiliary control chip 1021 is also used to: generate an encrypted response packet containing the opening and closing status of the door lock, and feed it back to the main control chip 1011.
[0060] In a specific implementation, the auxiliary control chip 1021 is specifically used to calculate the checksum of the response packet using a checksum algorithm, and based on a random number, a pre-stored key and the checksum of the response packet, a preset encryption algorithm is used to calculate the auxiliary control chip signature, and the auxiliary control chip signature is added to the response packet to obtain the encrypted response packet.
[0061] It should be noted that the key is generated by the main control chip 1011 and sent to the auxiliary control chip 1021 in the lock body 102 before the smart door lock leaves the factory.
[0062] The motor driving circuit 1022 is specifically used to drive the motor 1023 to rotate forward to control the smart door lock to unlock, and drive the motor 1023 to rotate reversely to control the smart door lock to lock; or, drive the motor 1023 to rotate forward to control the smart door lock to lock, and drive the motor 1023 to rotate reversely to control the smart door lock to unlock.
[0063] It should be noted that the smart door lock is divided into an outer panel, an inner panel and a lock body. In the embodiment of the present invention, the main control chip is arranged in the outer panel or the inner panel of the smart door lock, and the auxiliary control chip, the drive circuit and the motor are arranged in the lock body, and other components of the smart door lock are not illustrated one by one.
[0064] In an embodiment of the present invention, an auxiliary control chip and a driving circuit are set in the lock body. When the lock body is controlled, the main control chip set in the panel transmits the encrypted command packet to the auxiliary control chip, so that the auxiliary control chip controls the driving circuit to drive the motor to perform opening and closing operations of the door lock, thereby improving the security of the smart door lock.
[0065] Preferably, combined Figure 1 ,refer to Figure 2 , shows a schematic structural diagram of a smart door lock provided in an embodiment of the present invention, and the smart door lock also includes: a sensor 1024.
[0066] The sensor 1024 is connected to the auxiliary control chip 1021 , and is used to collect status data of the lock body 102 , and send the status data of the lock body 102 to the auxiliary control chip 1021 .
[0067] In a specific implementation, the sensor 1024 includes a mechanical switch, an infrared photoelectric sensor, a Hall switch, a magnetic sensor or a laser sensor. The state data of the lock body 102 includes but is not limited to the retraction or ejection state of the main lock tongue, the oblique tongue and the detection tongue of the lock body 102. It should be noted that the sensor 1024 includes but is not limited to the types mentioned above, and examples are not given one by one here.
[0068] The auxiliary control chip 1021 is also used to send the status data of the lock body 102 to the main control chip 1011 .
[0069] The main control chip 1011 is also used to receive the status data of the lock body 102 sent by the auxiliary control chip 1021 .
[0070] In the embodiment of the present invention, by setting an auxiliary control chip and a driving circuit in the lock body, when controlling the lock body, the main control chip set in the panel transmits the encrypted command packet to the auxiliary control chip, so that the auxiliary control chip controls the driving circuit to drive the motor to perform the door lock opening and closing operations. The state data of the lock body is collected by using the sensor set in the lock body, and the state data of the lock body is fed back to the main control chip through the auxiliary control chip, thereby improving the security of the smart door lock.
[0071] To better explain the above embodiments of the present invention Figure 1 and Figure 2 A schematic diagram of the structure of a disclosed smart door lock, see Figure 3 , shows a schematic diagram of the architecture of the smart door lock provided by an embodiment of the present invention, in the Figure 3 In the invention, a main control chip 301, a wireless communication module 302, a human-computer interaction module 303 and a biometric recognition module 304 are arranged in the panel of the smart door lock, and an auxiliary control chip 305, a motor driving integrated circuit (IC) 306, a motor 307 and a sensor 308 are arranged in the panel of the smart door lock.
[0072] It should be noted that the Figure 3 The motor driver IC 306 is the motor driver circuit mentioned above. The specific functions of the main control chip 301, the auxiliary control chip 305, the motor driver IC 306, the motor 307 and the sensor 308 can be found in the above description. Figure 1 and Figure 2 The corresponding content is made public.
[0073] It should be noted that the above Figure 3 The architecture diagram of the smart door lock shown in FIG. 1 is for illustration only.
[0074] In an embodiment of the present invention, an auxiliary control chip and a driving circuit are set in the lock body. When the lock body is controlled, the main control chip set in the panel transmits the encrypted command packet to the auxiliary control chip, so that the auxiliary control chip controls the driving circuit to drive the motor to perform opening and closing operations of the door lock, thereby improving the security of the smart door lock.
[0075] Based on the smart door lock disclosed in the above embodiment of the present invention, refer to Figure 4 , shows a flow chart of a communication method provided by an embodiment of the present invention, the method is applicable to a smart door lock, the smart door lock comprises: a panel and a lock body, the panel comprises at least a main control chip, the lock body comprises at least an auxiliary control chip, a drive circuit connected to the auxiliary control chip, and a motor connected to the drive circuit. The method comprises the following steps:
[0076] Step S401: the main control chip sends the encrypted command packet to the auxiliary control chip.
[0077] In the specific implementation of step S401, the main control chip and the auxiliary control chip communicate via a digital interface, for example, the main control chip sends the encrypted command packet via an I2C bus, a Uart bus, or an SPI bus. Before the main control chip sends the command packet containing the door lock opening and closing command to the auxiliary control chip, it is necessary to encrypt the command packet using a preset algorithm based on a pre-stored key and a random number, so as to obtain the encrypted command packet.
[0078] It should be noted that the key is generated by the main control chip and sent to the auxiliary control chip in the lock body before the smart door lock leaves the factory.
[0079] In order to better explain how the main control chip obtains the encrypted command packet, the following is an example through process A1-A3:
[0080] A1. The main control chip calculates the checksum of the command packet using a preset checksum algorithm. The checksum algorithm includes but is not limited to an XOR algorithm or a cyclic redundancy check algorithm (CRC).
[0081] A2. The main control chip calculates the main control chip signature based on the random number, the pre-stored key and the checksum of the command packet using a preset encryption algorithm. The preset encryption algorithm includes but is not limited to the Advanced Encryption Standard (AES).
[0082] A3. The main control chip adds the random number and the main control chip signature to the command packet to obtain the encrypted command packet.
[0083] To better explain the form of the encrypted command packet involved in process A3, please refer to Figure 5a , shows a schematic diagram of the structure of the encrypted command packet, in the Figure 5a In the example, random Seed is the random number, sign1 is the signature of the main control chip, and the original protocol command packet data is the command packet. The encrypted command packet is obtained by sequentially adding the random number and the signature of the main control chip to the end of the command packet.
[0084] It should be noted that the contents involved in the above processes A1-A3 are only for illustration purposes. Figure 5a The structure of the encrypted command packet includes but is not limited to Figure 5aThe remaining situations will not be given examples here.
[0085] It should be noted that before the main control chip and the auxiliary control chip communicate, the main control chip needs to complete authentication with the auxiliary control chip. The specific authentication method includes but is not limited to: the main control chip and the auxiliary control chip are authenticated by their unique ID numbers defined when they leave the factory. Data communication can only be carried out after authentication is passed.
[0086] It should be noted that the command packets and response packets between the main control chip and the auxiliary control chip are transmitted in plain text. However, in commands involving unlocking or locking the door lock, the command packets transmitted by the main control chip need to be encrypted, and the response packets fed back by the auxiliary control chip also need to be encrypted.
[0087] Step S402: the auxiliary control chip decrypts the encrypted command packet to obtain a command packet including a door lock opening and closing command.
[0088] In the specific implementation of step S402, the auxiliary control chip decrypts the encrypted command packet based on the key and the random number using the preset encryption algorithm to obtain the command packet containing the door lock opening and closing command.
[0089] Step S403: The auxiliary control chip controls the driving circuit to drive the motor based on the command packet to control the smart door lock to unlock or lock.
[0090] In the process of implementing step S403, the auxiliary control chip controls the driving circuit to drive the motor to rotate forward to control the smart door lock to unlock, and drives the motor to rotate reversely to control the smart door lock to lock; or, drives the motor to rotate forward to control the smart door lock to lock, and drives the motor to rotate reversely to control the smart door lock to unlock.
[0091] It should be noted that the rotation time of the motor is a fixed time or a dynamic time. The specific setting of the dynamic time is adjusted by the time data transmitted by the main control chip or according to the signal output by the sensor pre-set in the lock body.
[0092] Preferably, a sensor is also provided in the lock body, and the sensor is connected to the auxiliary control chip, and is used to collect the status data of the lock body, and send the status data of the lock body to the auxiliary control chip, and the status data of the lock body is sent to the main control core through the auxiliary control chip. The status data of the lock body includes but is not limited to the retraction or ejection status of the main lock tongue, the oblique tongue and the detection tongue of the lock body, and the sensor includes a mechanical switch, an infrared photoelectric sensor, a Hall switch, a magnetic sensor or a laser sensor. It should be noted that the sensors include but are not limited to the types mentioned above, and examples are not given one by one here.
[0093] Preferably, after executing step S403, the auxiliary control chip generates an encrypted response packet including the door lock opening and closing status, and feeds the encrypted response packet back to the main control chip.
[0094] In the specific process of obtaining the encrypted response packet, the auxiliary control chip uses a preset algorithm to encrypt the response packet containing the opening and closing status of the door lock based on the key and the random number before sending the encrypted response packet to obtain the encrypted response packet. It should be noted that the random number is the random number carried by the main control chip when sending the encrypted response packet, and the key is generated by the main control chip and sent to the auxiliary control chip in the lock body before the smart door lock leaves the factory.
[0095] To better explain how to encrypt a response packet to obtain an encrypted response packet, the following uses processes B1-B3 as an example.
[0096] B1. The auxiliary control chip calculates the checksum of the response packet using a preset checksum algorithm. The checksum algorithm includes but is not limited to an XOR algorithm or a CRC algorithm.
[0097] B2. The auxiliary control chip calculates the auxiliary control chip signature using a preset encryption algorithm based on the random number, the pre-stored key and the checksum of the response packet. The preset encryption algorithm includes but is not limited to AES.
[0098] B3. The auxiliary control chip adds the auxiliary control chip signature to the response packet to obtain the encrypted response packet.
[0099] To better explain the structure of the encrypted response packet involved above, refer to Figure 5b , shows a schematic diagram of the structure of the encrypted response packet, in the Figure 5b In the example, sign2 is the auxiliary control chip signature, the original protocol response packet data is the response packet, and the encrypted response packet is obtained by adding the auxiliary control chip signature to the end of the response packet. It should be noted that the structural diagram of the encrypted response packet includes but is not limited to Figure 5b The structure shown here is the only one, and the remaining structures will not be explained one by one.
[0100] It should be noted that the contents involved in the above processes B1-B3 are only used for illustration.
[0101] Furthermore, the main control chip decrypts the encrypted response packet to obtain a response packet including the opening and closing status of the door lock.
[0102] In a specific implementation, after receiving the encrypted response packet fed back by the auxiliary control chip, the main control chip decrypts the encrypted response packet to obtain a response packet containing the door lock opening and closing status, thereby obtaining the door lock opening and closing status of the smart door lock.
[0103] It should be noted that the random numbers involved in the above steps are different each time when the main control chip and the auxiliary control chip transmit command packets and response packets.
[0104] It should be noted that in order to reduce the power consumption of the smart door lock, when the smart door lock is static, the main control chip and the auxiliary control chip are both in sleep mode. When data communication is performed, the auxiliary control chip is awakened by the main control chip, or the main control chip is awakened by the auxiliary control chip. For example, when the main control chip has a command packet to be transmitted to the auxiliary control chip, the main control chip will wake up the auxiliary control chip through an I / O level flip to perform data communication. When the auxiliary control chip has data to upload to the main control chip, the auxiliary control chip will wake up the main control chip through an I / O level flip to perform data communication.
[0105] It should be noted that the smart door lock is divided into an outer panel, an inner panel and a lock body. In the embodiment of the present invention, the main control chip is arranged in the outer panel or the inner panel of the smart door lock, and the auxiliary control chip, the drive circuit and the motor are arranged in the lock body, and other components of the smart door lock are not illustrated one by one.
[0106] In summary, an embodiment of the present invention provides a communication method and a smart door lock, which includes a panel and a lock body, the panel at least includes a main control chip, and the lock body at least includes: an auxiliary control chip, a drive circuit connected to the auxiliary control chip, and a motor connected to the drive circuit. The main control chip sends the encrypted command packet to the auxiliary control chip. The auxiliary control chip receives the encrypted command packet and decrypts it to obtain a command packet containing a door lock opening and closing command, and controls the smart door lock to unlock or lock. In this solution, by setting an auxiliary control chip and a drive circuit in the lock body, when controlling the lock body, the main control chip set in the panel transmits the encrypted command packet to the auxiliary control chip, so that the auxiliary control chip controls the drive circuit to drive the motor to perform the door lock opening and closing operations, thereby improving the safety of the smart door lock.
[0107] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can refer to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system or system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can refer to the partial description of the method embodiment. The system and system embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without creative work.
[0108] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may 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 the present invention.
[0109] The above description of the disclosed embodiments enables one skilled in the art to implement or use the present invention. Various modifications to these embodiments will be apparent to one skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but rather to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A smart door lock, It is characterized in that include: A panel and a lock body, wherein the panel at least includes a main control chip, and the lock body at least includes: an auxiliary control chip, a sensor connected to the auxiliary control chip, a drive circuit connected to the auxiliary control chip, and a motor connected to the drive circuit; The main control chip is connected to the auxiliary control chip and is used to send the encrypted command packet to the auxiliary control chip; wherein the command packet includes a door lock unlocking command or a door lock locking command; The auxiliary control chip is used to receive the encrypted command packet and decrypt it to obtain a command packet, and based on the command packet, control the drive circuit to drive the motor to control the smart door lock to unlock or lock; The auxiliary control chip is also used to: generate an encrypted response packet containing the door lock opening and closing status, and feed it back to the main control chip; The sensor is used to collect the status data of the lock body and send the status data of the lock body to the auxiliary control chip; The auxiliary control chip is also used to send the status data of the lock body to the main control chip; The main control chip is also used to receive the status data of the lock body sent by the auxiliary control chip; Wherein, the auxiliary control chip and the main control chip are authenticated in advance.
2. The smart door lock according to claim 1, It is characterized in that The main control chip is specifically used to calculate the checksum of the command packet using a preset checksum algorithm, and based on a random number, a pre-stored key and the checksum of the command packet, a preset encryption algorithm is used to calculate the main control chip signature, and the random number and the main control chip signature are added to the command packet to obtain the encrypted command packet.
3. The smart door lock according to claim 1, It is characterized in that The auxiliary control chip is specifically used to calculate the checksum of the response packet using a checksum algorithm, and based on a random number, a pre-stored key and the checksum of the response packet, a preset encryption algorithm is used to calculate the auxiliary control chip signature, and the auxiliary control chip signature is added to the response packet to obtain the encrypted response packet.
4. The smart door lock according to claim 1, It is characterized in that The main control chip is also used to decrypt the encrypted response packet fed back by the auxiliary control chip to obtain a response packet containing the opening and closing status of the door lock.
5. The smart door lock according to claim 1, It is characterized in that The main control chip and the auxiliary control chip are specifically connected via an I2C bus, an SPI bus or a Uart bus.
6. The smart door lock according to claim 1, It is characterized in that The motor driving circuit is specifically used to drive the motor to rotate forward to control the smart door lock to unlock, and drive the motor to rotate reversely to control the smart door lock to lock; or, drive the motor to rotate forward to control the smart door lock to lock, and drive the motor to rotate reversely to control the smart door lock to unlock.
7. The smart door lock according to claim 1, It is characterized in that The sensor includes a mechanical switch, an infrared photoelectric sensor, a Hall switch, a magnetic sensor or a laser sensor.
8. A communication method, It is characterized in that Applicable to the main control chip, the method includes: The main control chip encrypts the command packet; wherein the command packet includes a door lock unlocking command or a door lock locking command; The main control chip sends the encrypted command packet to the auxiliary control chip, so that the auxiliary control chip decrypts the encrypted command packet and controls the smart door lock to unlock or lock; The main control chip receives the encrypted response packet containing the door lock opening and closing status generated and fed back by the auxiliary control chip; The main control chip receives the status data of the lock body sent by the auxiliary control chip; wherein the status data of the lock body is data collected by a sensor connected to the auxiliary control chip.
9. The method according to claim 8, It is characterized in that The main control chip encrypts the command packet, including: The main control chip calculates the checksum of the command packet using a preset checksum algorithm; The main control chip calculates the main control chip signature using a preset encryption algorithm based on a random number, a pre-stored key and a checksum of the command packet; The main control chip adds the random number and the main control chip signature to the command packet to obtain the encrypted command packet.
10. A communication method, It is characterized in that Applicable to the auxiliary control chip, the method comprises: The auxiliary control chip receives the encrypted command packet sent by the main control chip; wherein the command packet includes a door lock unlocking command or a door lock locking command; The auxiliary control chip decrypts the encrypted command packet to obtain a command packet including a door lock opening and closing command; The auxiliary control chip controls the driving circuit to drive the motor based on the command packet to control the door lock to unlock or lock; The auxiliary control chip generates an encrypted response packet containing the door lock opening and closing status, and feeds the encrypted response packet back to the main control chip, so that the main control chip decrypts the encrypted response packet to obtain a response packet containing the door lock opening and closing status; The auxiliary control chip receives the status data of the lock body collected and sent by the sensor, and sends the status data of the lock body to the main control chip; wherein the auxiliary control chip is connected to the sensor.
11. The method according to claim 10, It is characterized in that The auxiliary control chip generates an encrypted response packet containing the door lock opening and closing status, including: The auxiliary control chip calculates the checksum of the response packet using a checksum algorithm; The auxiliary control chip calculates the auxiliary control chip signature using a preset encryption algorithm based on a random number, a pre-stored key and a checksum of the response packet; The auxiliary control chip adds the auxiliary control chip signature to the response packet to obtain the encrypted response packet.
Citation Information
Patent Citations
Door lock with high safety and working method thereof
CN109184361A
Intelligent door lock
CN211287048U
