With reference to the accompanying drawings, describe the circuit structure of dynamic password electronic lock of the present utility model in detail.
Fig. 1 is the circuit structure diagram of expression dynamic random Puzzle electronic lock, and as shown in Figure 1, dynamic password electronic lock of the present utility model should comprise: lock body and dead bolt (not shown) and to the power unit 1 of above-mentioned opening device 6 and control circuit power supply.Control circuit partly has microprocessor portion 2 and comprises: key socket 3, nonvolatile memory 4, dynamic password generator circuit 5 and the above-mentioned opening device 6 that is connected with above-mentioned microprocessor portion 2 respectively.
In this microprocessor portion 2, by the reset circuit that capacitor C 3 and resistance R 1 constitute, 101 pin of its output termination microprocessor IC1, the other end of capacitor C 3 is connected to power supply VCC, and the end of the crystal Z1 in the other end of resistance R 1 and the crystal oscillating circuit is connected.Constitute crystal oscillating circuit by capacitor C 1, C2 and crystal Z1.The two ends of crystal join with 104 and 105 pin of IC1 respectively in the crystal oscillating circuit.112 pin of the signal output part of random code generator 5 and microprocessor IC1 join.The start signal of IC1 is exported 108 pin and is received opening device 6.110 and 120 difference grounding wire and the power supplys of IC1,
Opening device 6 is made of resistance R 4, triode G2 and motor M T.The start signal of microprocessor IC1 is exported the end of 108 pin connecting resistance R4, and resistance R 4 other ends are received the base stage of triode G2.The grounded emitter of triode G2, its colelctor electrode connect the end of drive motors MT, another termination power VCC of motor M T.
Nonvolatile memory 4 is made of IC2.The clock mouth of IC2 and data port 205 and 206 pin join with two LPTs 114 and 115 of IC1 respectively, 204 ground connection of IC2, and its 208 pin meets positive supply VCC, i.e. and the input of reset circuit meets positive supply VCC.
Key socket comprises key socket KA and Men Nei key socket KB outdoors.This outdoors 1 and 2 pin of key socket KA be to be used for powering up from the outside unblanking, and join, and the positive pole of the negative terminal of diode D1 and battery E1 joins with the anode of diode D1.3 pin of key socket KB join in 3 pin of this KA and the positive pole of battery E1 and the door, and its 4 pin connects the anode of capacitor C 7 and resistance R 3 parallel connections and 4 pin of the interior key socket KB of door, and its 5 and 6 pin connects 119 and 118 pin of IC1,7 pin ground connection respectively.5 and 6 pin of key socket KB connect 107 and 106 pin of IC1 respectively in the door, and its 7 pin is ground connection also.
Acousto-optic circuit comprises: 106 pin of IC1 connect a pin of LED (redness) luminous tube and buzzer (illustrating with horn-like), and another pin of buzzer and the positive pole of LED meet power supply VCC.107 pin of IC1 connect the negative pole of LEZ (green) luminous tube, and its positive pole meets power supply VCC.
Random number generator 5 is composed in series by noise generator, an amplifier of making an uproar, comparator.It is big characteristics that noise generator is applied to this lock, has had it to make this lock realize autonomous type.Noise generator is made of the noise producing component, such as (2N5401,2N9012) a kind of element of selecting in the grade is as producing noise source by resistor, Zener diode (BZV16, IN5353BY series), triode.That use in this circuit is exactly Zener diode R.Noise amplifier constitutes just no longer explanation by integrated circuit block broad band amplifier OP and comparator (comparator is inner existing at ICI in this circuit).The course of work of random number generator 5 is, produces as the Zener diode R of noise source and delivers to broad band amplifier OP behind the noise and amplify, and delivers to the 112 pin internal comparator of microprocessor IC1 after noise is exaggerated.
This IC circuit 1, IC3 and IC2, IC4 can with computer processor and memory 89S8252,89C51 as atmel corp, 89C52,24C08,93C46 etc. are arranged a lot.That more particularly, this IC circuit 1, IC3 are used is the 89C2051 of atmel corp.IC2, IC4 are the 24C04 of atmel corp.
Be used to open the key of dynamic random Puzzle electronic lock of the present utility model, shown in Fig. 2 and 3, its key body 15 is the flat, rectangular body, and an end is the ailhead shape.Key body 15 tops are provided with external power supply socket 11, have in this external power socket 11 a plurality of, such as 3 power pins, wherein two contact pin close together are used to add positive supply, another contact pin adds negative supply.Be provided with key chain hole 16 near ailhead shape circular arc edge one end.These key body 15 middle part mounting circuit boards 12 are equipped with nonvolatile memory and (are designated hereinafter simply as: internal memory) 13 on circuit board 12.These key body 15 bottoms are provided with contact pin spare 14, totally 1~7 of contact pin.Contact pin 1~7 can insert in the jack 21 of key holder 20.Key body is divided into two, before the injection mo(u)lding each contact pin is embedded in the key body, after the moulding two is combined into one.Nonvolatile memory can adopt 24C04,93C46, SLE4418 and AT88SC102 etc.
1~7 pin in the jack of drawing key socket KB in contact and the KA of key socket outdoors that is provided with respectively, the door on inside and outside lock body of contact pin is corresponding.The contact pin 1 and 2 of key is to be used to add the input power supply, contact pin 3 and 4 is and connects the power port that is installed on the memory on the circuit board in the key after inside links to each other, contact pin 5 and 6 is connected the data port and the clock mouth of internal memory respectively, and 7 pin connect outer powering up and connect key internal memory ground wire simultaneously.
Key of the present utility model is divided into sub-key, master key and removing key.In the internal memory of sub-key, there are one group of sub-keyed feature sign indicating number, one group of above lock number, one group of above key cipher and one group of above random code respectively.One group of master key identification code, one group of dispatch from the factory password and one group of (12) personal identification number are arranged in the internal memory of master key.Remove and have one group of program of removing the keyed feature sign indicating number and removing key in the key respectively.In the internal memory IC2 of lock body, have with the key internal memory in corresponding password, keyed feature and master key identification code.
The course of work of the present utility model is: group key or master key are inserted as outdoors during key holder KA, make power connection, make the start-up routine among the microprocessor IC1 of microprocessor portion 2 immediately, the internal memory of the sub-key of being inserted on KA key mouth by 118 and 119 pin of IC1 or the internal memory of master key communicate, and take out one group of password of corresponding this lock code name.Then, clock mouth and the data port of the IC2 by memory 4 find one group of password of corresponding key code name to check with it from memory IC 2.If password conforms to, then the I LPT output high level of microprocessor IC1 by joining with output driving circuit then by output driving circuit drive motors MT, opened dead bolt, can finish and unblank, realize to input the purpose that password can be unblanked from face.When unblanking success, 112 pin of microprocessor IC1 read a new random cipher from random code generator immediately, write the random cipher position of lock corresponding with it in IC2 and the sub-key internal memory number and key number simultaneously.At this moment, used password promptly is replaced, and realizes the one-time pad sign indicating number.
Above-mentioned sub-key also can insert finishes normal unlocking function in the endoporus.Corresponding contacting during key mouth KB in the group key inserts, IC1 by the password that reads corresponding this lock the key internal memory of 106,107 pin on being inserted in KB key mouth after with IC2 in password compare, correct as password, IC1 provides unlocking signal by 108 pin, as incorrect, then IC1 provides the sound and light alarm signal by 116 pin.
Key holder in master key inserts door, and any bundle key is when inserting outdoors key holder, microprocessor IC1 at first discerns the master key condition code, read the master key identification code again, check with memory master key identification code in the memory IC 2, check and conform to, promptly carry out the bitting program, promptly produce one group automatically by this lock lock code name and a new key code name and the sub-key cipher that new random cipher is formed, and it is write in sub-key internal memory and the lock body memory IC 2 simultaneously, thereby realize autonomous type bitting function.
The utility model also has one to remove key, and based structures is with above-mentioned key.In removing key, there is one and removes the keyed feature sign indicating number.In key holder in the removing key insertion door, and insert in the key holder outdoors for master key the time, microprocessor IC1 is after confirming master key, the keyed feature sign indicating number is removed in identification, promptly carry out clear program, all the sub-key code names and the corresponding clearing password thereof of storage in the memory IC in the lock body 2 are fallen, thereby all legal sub-keys of original preparation were lost efficacy.The afterbody of this key also is provided with the power supply plug hole, crosses when low when cell voltage in the lock body, unblanks by powering up outward.
Circuit of the present utility model does not power up at ordinary times, has only that circuit just powers up when key inserts key holder.The course of work is that 3 pin of key holder connect anode, and 4 pin connect the anode of capacitor C 7, and the contact pin 3 and 4 of key is to join in key inside.When key inserted key holder, anode was added on the anode of capacitor C 7 by the contact pin 3 and 4 of key, and power control circuit can be used integrated circuits such as amplifier, comparator, and this power control circuit is with a triode G1, a capacitor C 7 and a resistance R 3.The annexation of this control circuit is the colelctor electrode that battery E1 positive pole meets triode G1, and 4 pin of key holder connect base stage and the positive pole of capacitor C 7 and the end of resistance R 3 of triode G1, and the other end ground connection of the negative pole of capacitor C 7 and resistance R 3.When key inserted key holder, the electricity of battery E1 positive pole entered 4 pin from the contact pin 3 of key and inputs to capacitor C 7 chargings, triode G1 conducting simultaneously, control circuit work to power control circuit.When key is transferred to, keep triode G1 conducting 5-6 power down after second with the electricity that electric capacity C7 is deposited.But so both power savings, the application life of having improved circuit again.106,107 pin of IC1 of the present utility model are connected to an aforesaid warning circuit, when password that reads from key as IC1 and internal memory password not match, can output alarm signal or relevant digital information, and as illegal key, low-voltage etc.
Above-mentioned control circuit in the utility model also has standby control circuit.Standby control circuit as shown in Figure 1, comprising: the key socket 10 that is connected with microprocessor portion 8, shelf storage 9 and opening device 7 respectively.
The microprocessor IC3 of microprocessor portion 8 has reset circuit, crystal circuit, and the connected mode microprocessor IC1 with microprocessor portion 2 basically is identical, no longer explanation.Shelf storage 9 is used nonvolatile memory, is designated as IC4.Opening device 7 has drive circuit and motor (MT), and connected mode is identical with above-mentioned opening device 6.More specifically say, the output of reset circuit connects 301 pin of IC3, the two ends of crystal Z2 join with 304 and 305 pin of IC3 respectively in the crystal oscillating circuit, the end of the output 315 pin connecting resistance R5 of IC3, the other end of resistance R 5 is received the base stage of triode G3, the grounded emitter of triode G3, its colelctor electrode connect the end of drive motors MT, another termination power of motor M T.310 and 320 pin of IC3 are 2 and 3 pin of grounding wire and standby key seat KC respectively, and the clock mouth of IC4 and data port 405 and 406 pin join with two LPTs 316 and 317 pin of IC3 respectively.404 ground connection of IC4, its 408 pin connect 2 and 3 pin of standby key seat KC and the input of reset circuit.1 and 4 of standby key seat KC is sky pin, and 2 and 3 pin are 306 and 308 pin that the input of stand-by circuit power supply meets IC3 respectively, 7 pin ground connection.
The course of work of this stand-by circuit is: when master key inserts standby key seat KC, corresponding contacting, make microprocessor IC3 start-up routine immediately, take out the master key password of corresponding this lock, then one group of password by finding corresponding master key among the IC4 with check, if password conforms to, the LPT output high level of microprocessor IC3 then by joining with output driving circuit, by the output driving circuit drive motors, open dead bolt, promptly stand-by circuit is finished and is unblanked.