Disclosure of Invention
The technical problem to be solved by the present invention is to provide an electronic key, an unlocking system thereof, and an unlocking method thereof, which can make maintenance and installation of a power module more convenient, in view of the above-mentioned defects of the prior art.
The technical scheme adopted by the invention for solving the technical problems is as follows: an electronic key comprises a power supply module, a first control module and a first contact module; the power supply module is electrically connected with the first control module and the first contact module and is used for supplying power to the first control module and the first contact module; the first contact module is electrically connected with the first control module and is used for being electrically connected with a second contact module of the lock body so as to transmit first encryption information to the first control module; the first control module is used for sending an unlocking instruction to the lock body.
Further preferred embodiments of the present invention are: the electronic key further comprises a charging interface, and the charging interface is electrically connected with the power supply module and used for charging the power supply module.
Further preferred embodiments of the present invention are: the electronic key further comprises a magnetic suction interface, and the magnetic suction interface is electrically connected with the first control module and is used for being electrically connected with the second contact module of the lock body.
Further preferred embodiments of the present invention are: the electronic key further comprises an indicator light and a first switch, the first switch is electrically connected with the indicator light and used for controlling the indicator light to be turned on or off, and the indicator light is electrically connected with the first control module and used for displaying the electric quantity of the electronic key.
Further preferred embodiments of the present invention are: the electronic key further comprises a second switch, and the second switch is connected between the first control module and the power supply module and used for controlling power supply of the power supply module.
The invention provides a second scheme, and an unlocking system of an electronic key, which is applied to the electronic key in the scheme and further comprises a lock body, wherein the lock body comprises a second contact module and a second control module, the second control module is electrically connected with the second contact module, and when the first contact module is electrically connected with the second contact module in a contact manner, the second control module sends first encryption information to the first control module.
The third scheme provided by the invention is an unlocking method of an electronic key, which is applied to an unlocking system of the electronic key in the scheme and comprises the following steps:
s1: a first contact module of the electronic key is in contact electrical connection with a second contact module of the lock body, and a first control module of the electronic key receives first encrypted information sent by the second control module;
s2: the first control module decrypts the first encrypted information to obtain an identification code;
s3: the first control module matches the identification code with a plurality of pre-stored identification codes;
s4: the first control module sends an unlocking instruction to the second control module, and the second control module controls the lock body to be unlocked.
Further preferred embodiments of the present invention are: the first control module comprises a data processing unit; the first contact module is electrically connected with the data processing unit, and the step of decrypting the first encrypted information by the first control module to obtain the identification code comprises the following steps: and the data processing unit decrypts the first encrypted information to obtain an identification code.
In a further preferable aspect of the present invention, the first control module further includes a storage unit, the pre-stored identification code is stored in the storage unit, the data processing unit is electrically connected to the storage unit, and after the processing data unit decrypts the first encrypted information to obtain the identification code, the processing data unit matches the identification code with the identification code in the storage unit.
A further preferable scheme of the present invention is that after the data processing unit matches the identification code with the identification code in the storage unit, the method includes the following steps, if the matching is successful, the data processing unit sends an unlocking instruction to the second control module, and the second control module controls the lock body to unlock after receiving the unlocking instruction.
The portable electronic key has the advantages that the portable electronic key is convenient to install the power supply module on the portable electronic key, and the power supply module can be conveniently replaced or charged if the power supply module is not powered.
Detailed Description
It is to be understood that the terminology, the specific structural and functional details disclosed herein are for the purpose of describing particular embodiments only, and are representative, but that the present invention may be embodied in many alternate forms and should not be construed as limited to only the embodiments set forth herein.
Furthermore, unless expressly stated or limited otherwise, the terms "mounted," "connected," and "connected" are to be construed broadly and may include, for example, fixed connections, removable connections, and integral connections; can be mechanically or electrically connected; either directly or indirectly through intervening media, or through both elements. The specific meanings of the above terms in the present invention can be understood by those skilled in the art according to specific situations.
The invention will be further described with reference to figures 1 and 2 and alternative embodiments.
The invention provides an electronic key, which comprises a power supply module 10, a first control module 40 and a first contact module 70; the power module 10 is electrically connected with the first control module 40 and the first contact module 70, and is used for supplying power to the first control module 40 and the first contact module 70; the first contact module 70 is electrically connected with the first control module 40 and is used for electrically connecting with a second contact module of the lock body to transmit first encryption information to the first control module 40; the first control module 40 is configured to send an unlocking instruction to the lock body.
Since the electronic key is carried about, it is convenient to install the power module 10 on the electronic key, and it is also convenient to replace the power module 10 if the power module 10 is not powered.
Since the electric box is disposed outdoors and the installation position is usually high, and the lock body is disposed on the electric box, if the power module 10 is disposed in the lock body, the installation and maintenance of the power module 10 are troublesome, but if the power module 10 is disposed in the electronic key, when the first contact module 70 of the electronic key is connected with the second contact module of the lock body, the power module 10 in the electronic key can provide power to the second control module of the lock body, and the second control module controls the lock body to unlock after receiving the unlocking instruction sent by the first control module 40.
In this embodiment, the power module 10 is a battery, the battery is installed in the electronic key, and since the electronic key is carried about, when the battery is out of power, the battery can be conveniently replaced or charged, and since one electronic key stores the unlocking identification codes of a plurality of lock bodies, one electronic key can unlock a plurality of lock bodies, so that only one electronic key and one electronic key are provided with one battery, the lock bodies can be unlocked. If the batteries are installed in the lock body, because the installation positions of all the electric boxes are different, each electric box needs one lock body to lock the electric box, so that each lock body needs to be provided with one battery, and the batteries are installed in the electronic key in quantity, so that a lot of batteries can be saved.
Further, the electronic key further includes a charging interface 80, and the charging interface 80 is connected to the power module 10 and is used for charging the power module 10, so that when the power of the power module 10 is used up, the power module 10 can be charged through the charging interface 80.
Further, the electronic key further includes a magnetic attraction interface 30, and the magnetic attraction interface 30 is electrically connected to the first control module 40 and is configured to be electrically connected to the second contact module of the lock body. Because the electronic box sets up in the open air, sometimes the position that sets up of electronic box is higher, the position of lock body just is very high like this, just hardly put the electronic key and unblank on the lock body, inhale interface 30 through setting up magnetism on the electronic key this moment, just so can inhale interface 30 connection magnetism on the electronic key and inhale the line, the other end of inhaling the line is connected on the second contact module of lock body, the electronic key just can be with the lock body circular telegram like this, just can realize the transmission of signal, the electronic key just can realize the function of unblanking.
Further, the electronic key further comprises an indicator light 60 and a first switch 50, the first switch 50 is electrically connected with the indicator light 60 and is used for controlling the indicator light 60 to be turned on or off, and the indicator light 60 is electrically connected with the first control module 40 and is used for displaying the electric quantity of the electronic key. By providing the first switch 50, the indicator light 60 will indicate the corresponding amount of power when the first switch 50 is turned on.
Further, the electronic key further includes a second switch 20, and the second switch 20 is connected between the first control module 40 and the power module 10, and is used for controlling the power supply of the power module 10. By arranging the second switch 20, when the second switch 20 is turned on, the power module 10 can supply power to the whole circuit loop, when the electronic key needs to be unlocked, the second switch 20 is turned on, and when the electronic key does not need to be unlocked, the second switch 20 is turned off, so that when the electronic key does not need to be unlocked, the first control module 40 does not need to be supplied with power, and electric energy is not consumed.
Further, a second aspect of the present invention provides an unlocking system of an electronic key, including the electronic key in the above embodiments, further including a lock body, where the lock body includes a second contact module and a second control module, the second control module is electrically connected to the second contact module, and when the first contact module 70 is electrically connected to the second contact module in a contact manner, the second control module sends first encryption information to the first control module 40.
Further, a third aspect of the present invention also provides an unlocking method of an electronic key, including the unlocking system of the above embodiment, including the steps of:
s1: the first contact module 70 of the electronic key is in contact and electric connection with the second contact module of the lock body, and the first control module 40 of the electronic key receives the first encrypted information sent by the second control module;
s2: the first control module 40 decrypts the first encrypted information to obtain an identification code;
s3: the first control module 40 matches the identification code with a plurality of pre-stored identification codes;
s4; the first control module 40 sends an unlocking instruction to the second control module, and the second control module controls the lock body to unlock.
Specifically, the lock body is provided with a motor, the second control module is connected with the motor, the motor is connected with the unlocking structure, and the second control module receives an unlocking instruction and then controls the motor to rotate so as to unlock the unlocking structure.
It should be noted that the identifier may be a UUID, or other identifier, or other self-defined character string. The unlocking instruction can be a string of numbers or a string of characters, and the two parties agree.
Further, the first control module 40 includes a data processing unit; the first contact module 70 is electrically connected to the data processing unit, and the step of decrypting the first encrypted information by the first control module 40 to obtain the identification code includes: and the data processing unit decrypts the first encrypted information to obtain an identification code.
Further, the first control module 40 further includes a storage unit, the pre-stored identification code is stored in the storage unit, the data processing unit is electrically connected to the storage unit, and after the data processing unit decrypts the first encrypted information to obtain the identification code, the method includes the following steps that the data processing unit matches the identification code with the identification code in the storage unit.
Further, after the data processing unit matches the identification code with the identification code in the storage unit, the method includes the following steps that if the matching is successful, the data processing unit sends an unlocking instruction to the second control module, and the second control module controls the lock body to be unlocked after receiving the unlocking instruction.
It should be noted that, the limitations of the steps involved in the present disclosure are not considered to limit the order of the steps without affecting the implementation of the specific embodiments, and the steps written in the foregoing may be executed first, or executed later, or even executed simultaneously, and as long as the present disclosure can be implemented, all should be considered to belong to the protection scope of the present disclosure.
The foregoing is a more detailed description of the invention in connection with specific alternative embodiments, and the practice of the invention should not be construed as limited to those descriptions. For those skilled in the art to which the invention pertains, several simple deductions or substitutions can be made without departing from the spirit of the invention, and all shall be considered as belonging to the protection scope of the invention.