CN103684785B - Dynamic token with key protection function and working method thereof - Google Patents
Dynamic token with key protection function and working method thereof Download PDFInfo
- Publication number
- CN103684785B CN103684785B CN201310658897.2A CN201310658897A CN103684785B CN 103684785 B CN103684785 B CN 103684785B CN 201310658897 A CN201310658897 A CN 201310658897A CN 103684785 B CN103684785 B CN 103684785B
- Authority
- CN
- China
- Prior art keywords
- pin
- button
- input pin
- unit
- pressed
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
- 230000004224 protection Effects 0.000 title claims abstract description 66
- 238000000034 method Methods 0.000 title claims abstract description 27
- 230000005611 electricity Effects 0.000 claims description 15
- 238000001514 detection method Methods 0.000 claims description 12
- 230000001360 synchronised effect Effects 0.000 claims description 7
- 230000000284 resting effect Effects 0.000 claims description 6
- 230000002618 waking effect Effects 0.000 claims description 3
- 230000002159 abnormal effect Effects 0.000 abstract description 2
- 230000002035 prolonged effect Effects 0.000 abstract 1
- 238000010586 diagram Methods 0.000 description 4
- 230000009286 beneficial effect Effects 0.000 description 1
Classifications
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Landscapes
- Input From Keyboards Or The Like (AREA)
- Telephone Function (AREA)
Abstract
The invention discloses a dynamic token with the key protection function and a working method of the dynamic token and belongs to the technical field of keys. The dynamic token comprises a master control module, a key module, a key forbidden timing module and a key abnormity timing module, wherein the master control module comprises a clock unit, a timing interrupt unit, an input interrupt unit and an input/output unit. The working method includes the steps that when the dynamic token detects that input interrupt happens to the input interrupt unit, the dynamic token is awakened, and input awakening identification is set; when the dynamic token detects that timing interrupt happens to the timing interrupt unit, the dynamic token is awakened, and timing awakening identification is set; if key awakening identification is set, key operation is executed, and if the timing awakening identification is set, the key protection procedure is executed. Through the technical scheme, power consumption caused by abnormal key operation on the dynamic token can be reduced, and the service life of the dynamic token is prolonged.
Description
Technical field
The present invention relates to button technical field, more particularly, to a kind of dynamic token with massage protection function and its work
Method.
Background technology
Dynamic token is used to generate the terminal of dynamic password, and dynamic password can be used to confirm that the legal identity of user,
Thus ensureing, on the basis of user is with legal identity login, the security that customer service accesses.Dynamic password authentication technology is recognized
For being most effective at present one of method solving user authentication, thus being widely used in bank, security, Third-party payment and big
In the various information system scenarios such as enterprises.
Prevailing with electronic product, the power problemses of button also become the topic that more and more manufacturers fall over each other to pay close attention to, electricity
The length of sub- product use time directly affects the performance and electronic product of the electronic product image in the minds of user.
In life, it is frequently encountered such situation: when electronic product is put by user with hard thing (as key etc.)
When putting together, electronic product key can be led to be subject to hard thing pressing to produce unnecessary button power consumption, right particularly with some
The exigent product of battery power consumption (as dynamic token etc.), this phenomenon has had a strong impact on the service life of electronic product.Base
In these reasons, inventor solves the problems, such as the power consumption leading to because of improper button.
Content of the invention
The invention aims to solution problems of the prior art, there is provided one kind has massage protection function
Dynamic token and its method of work.
The technical solution used in the present invention is: a kind of dynamic token with massage protection function, comprising: main control module,
Key-press module, button disabling timing module and button exception timing module;Wherein, described main control module includes clock unit, determines
When interrupt location, input interrupt location and I/O unit;
Described clock unit: be connected with described Interruption unit, for for described main control module and described Interruption
Unit provides reliable clock source;
Described Interruption unit: it is connected with described clock unit, under the triggering of described clock unit, automatically fixed
When, when reaching Preset Time, produce Interruption under described master control module controls;
Described input interrupt location: be connected with described I/O unit, in the input of described I/O unit
When level produces default change, under the control of described main control module, produce input and interrupt;
Described I/O unit: with described input interrupt location be connected, for by output pin output level and lead to
Cross input pin receives input level, when the incoming level receiving by described input pin produces default change, described
Under the control of main control module, described input interrupt location produces input to interrupt;It is connected with described key-press module, know described button
The state that in module, button is pressed or do not pressed;
Described key-press module: be connected with described I/O unit, for feeding back button to described I/O unit
The state being pressed or not being pressed;
Described button disables timing module: is connected with described Interruption unit, for the control in described main control module
The time of lower record button disabling;
Described button exception timing module: be connected with described Interruption unit, for the control in described main control module
The time that lower record button is pressed.
A kind of dynamic token with massage protection function, also includes: display module and power module;
Described display module: it is connected with described main control module, under the control of described main control module, display information;
Described power module: be connected with described main control module and described display module, for described main control module and institute
Stating display module provides electric energy.
Described key-press module includes button (key1) and resistance (r1), and described I/O unit includes input pin
And output pin (k2) (k1).
Described key-press module is connected as with the physical circuit of described I/O unit: 1 pin of described button (key1) leads to
Cross described resistance (r1) and connect vcc, 1 pin of described button (key1) is connected with described input pin (k1), described button simultaneously
(key1) 2 pin are connected with described output pin (k2).
Described output pin (k2) exports low level;When described button (key1) is not pressed, described input pin
(k1) it is high level, when described button (key1) is pressed, described input pin (k1) is connected with described output pin (k2),
Described input pin (k1) is changed into low level.
Described key-press module is connected as with the physical circuit of described I/O unit: 1 pin of described button (key1) leads to
Cross described resistance (r1) and connect gnd, 1 pin of described button (key1) is connected with described output pin (k1), described button simultaneously
(key1) 2 pin are connected with described input pin (k2).
Described output pin (k2) exports high level;When described button (key1) is not pressed, described input pin
(k1) state is low level, when described button (key1) is pressed, described input pin (k1) and described output pin (k2)
It is connected, described input pin (k1) is changed into high level.
Described key-press module include button (key1, key2, key3, key4, key5, key6, key7, key8, key9,
Key10, key11, key12, key13, key14, key15, key16) and resistance (r1, r2, r3, r4), described input/output list
Unit includes input pin (k1, k2, k3, k4) and output pin (k5, k6, k7, k8).
Described key-press module is connected as with the physical circuit of described I/O unit:
1 pin of described button (key1, key2, key3, key4) connects vcc by described resistance (r4), simultaneously described presses
1 pin of key (key1, key2, key3, key4) is connected with described input pin (k1), described button (key1, key2, key3,
Key4 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key5, key6, key7, key8) connects vcc by described resistance (r3), simultaneously described presses
1 pin of key (key5, key6, key7, key8) is connected with described input pin (k2), described button (key5, key6, key7,
Key8 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key9, key10, key11, key12) connects vcc by described resistance (r2), simultaneously described
1 pin of button (key9, key10, key11, key12) is connected with described input pin (k3), described button (key9, key10,
Key11, key12) 2 pin be connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key13, key14, key15, key16) connects vcc, institute simultaneously by described resistance (r1)
1 pin stating button (key13, key14, key15, key16) is connected with described input pin (k4), described button (key13,
Key14, key15, key16) 2 pin be connected with described output pin (k5, k6, k7, k8) respectively.
Described output pin (k5, k6, k7, k8) exports low level;When described button (key1, key2, key3, key4) not
When being pressed, described input pin (k1) be high level, when described button (key1) is pressed, described input pin (k1) with
Described output pin (k5) is connected so that described input pin (k1) is low level;When described button (key2) is pressed, institute
State input pin (k1) to be connected with described output pin (k6) so that described input pin (k1) is low level;When described button
(key3), when being pressed, described input pin (k1) is connected with described output pin (k7) so that described input pin (k1) is
Low level;When described button (key4) is pressed, described input pin (k1) is connected with described output pin (k8) so that institute
Stating input pin (k1) is low level;
Described output pin (k5, k6, k7, k8) exports low level;When described button (key5, key6, key7, key8) not
When being pressed, described input pin (k2) be high level, when described button (key5) is pressed, described input pin (k2) with
Described output pin (k5) is connected so that described input pin (k2) is low level;When described button (key6) is pressed, institute
State input pin (k2) to be connected with described output pin (k6) so that described input pin (k2) is low level;When described button
(key7), when being pressed, described input pin (k2) is connected with described output pin (k7) so that described input pin (k2) is
Low level;When described button (key8) is pressed, described input pin (k2) is connected with described output pin (k8) so that institute
Stating input pin (k2) is low level;
Described output pin (k5, k6, k7, k8) exports low level;When described button (key9, key10, key11,
When key12) not being pressed, described input pin (k3) is high level, and when described button (key9) is pressed, described input is drawn
Pin (k3) is connected with described output pin (k5) so that described input pin (k3) is low level;When described button (key10) quilt
When pressing, described input pin (k3) is connected with described output pin (k6) so that described input pin (k3) is low level;When
When described button (key11) is pressed, described input pin (k3) is connected so that described input is drawn with described output pin (k7)
Pin (k3) is low level;When described button (key12) is pressed, described input pin (k3) and described output pin (k8) phase
Even so that described input pin (k3) is low level;
Described output pin (k5, k6, k7, k8) exports low level;When described button (key13, key14, key15,
When key16) not being pressed, described input pin (k4) is high level, when described button (key13) is pressed, described input
Pin (k4) is connected with described output pin (k5) so that described input pin (k4) is low level;As described button (key14)
When being pressed, described input pin (k4) is connected with described output pin (k6) so that described input pin (k4) is low level;
When described button (key15) is pressed, described input pin (k4) is connected with described output pin (k7) so that described input
Pin (k4) is low level;When described button (key16) is pressed, described input pin (k4) and described output pin (k8)
It is connected so that described input pin (k4) is low level.
Described key-press module is connected as with the physical circuit of described I/O unit:
1 pin of described button (key1, key2, key3, key4) is connected with gnd by described resistance (r4), simultaneously described
1 pin of button (key1, key2, key3, key4) is connected with described input pin (k1), described button (key1, key2, key3,
Key4 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key5, key6, key7, key8) is connected with gnd by described resistance (r3), simultaneously described
1 pin of button (key5, key6, key7, key8) is connected with described input pin (k2), described button (key5, key6, key7,
Key8 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key9, key10, key11, key12) is connected with gnd by described resistance (r2), institute simultaneously
1 pin stating button (key9, key10, key11, key12) is connected with described input pin (k3), described button (key9,
Key10, key11, key12) 2 pin be connected with respectively described output pin (k5, k6, k7, k8);
1 pin of described button (key13, key14, key15, key16) is connected with gnd, simultaneously by described resistance (r1)
1 pin of described button (key13, key14, key15, key16) is connected with described input pin (k4), described button (key13,
Key14, key15, key16) 2 pin be connected with described output pin (k5, k6, k7, k8) respectively.
Described output pin (k5, k6, k7, k8) exports high level;When described button (key1, key2, key3, key4) not
When being pressed, described input pin (k1) be low level, when described button (key1) is pressed, described input pin (k1) with
Described output pin (k5) is connected so that described input pin (k1) is high level;When described button (key2) is pressed, institute
State input pin (k1) to be connected with described output pin (k6) so that described input pin (k1) is high level;When described button
(key3), when being pressed, described input pin (k1) is connected with described output pin (k7) so that described input pin (k1) is
High level;When described button (key4) is pressed, described input pin (k1) is connected with described output pin (k8) so that institute
Stating input pin (k1) is high level;
Described output pin (k5, k6, k7, k8) exports high level;When described button (key5, key6, key7, key8) not
When being pressed, described input pin (k2) be low level, when described button (key5) is pressed, described input pin (k2) with
Described output pin (k5) is connected so that described input pin (k2) is high level;When described button (key6) is pressed, institute
State input pin (k2) to be connected with described output pin (k6) so that described input pin (k2) is high level;When described button
(key7), when being pressed, described input pin (k2) is connected with described output pin (k7) so that described input pin (k2) is
High level;When described button (key8) is pressed, described input pin (k2) is connected with described output pin (k8) so that institute
Stating input pin (k2) is high level;
Described output pin (k5, k6, k7, k8) exports high level;When described button (key9, key10, key11,
When key12) not being pressed, described input pin (k3) is low level, and when described button (key9) is pressed, described input is drawn
Pin (k3) is connected with described output pin (k5) so that described input pin (k3) is high level;When described button (key10) quilt
When pressing, described input pin (k3) is connected with described output pin (k6) so that described input pin (k3) is high level;When
When described button (key11) is pressed, described input pin (k3) is connected so that described input is drawn with described output pin (k7)
Pin (k3) is high level;When described button (key12) is pressed, described input pin (k3) and described output pin (k8) phase
Even so that described input pin (k3) is high level;
Described output pin (k5, k6, k7, k8) exports high level;When described button (key13, key14, key15,
When key16) not being pressed, described input pin (k4) is low level, when described button (key13) is pressed, described input
Pin (k4) is connected with described output pin (k5) so that described input pin (k4) is high level;As described button (key14)
When being pressed, described input pin (k4) is connected with described output pin (k6) so that described input pin (k4) is high level;
When described button (key15) is pressed, described input pin (k4) is connected with described output pin (k7) so that described input
Pin (k4) is high level;When described button (key16) is pressed, described input pin (k4) and described output pin (k8)
It is connected so that described input pin (k4) is high level.
A kind of method of work of the dynamic token with massage protection function is it is characterised in that include:
Step s1: electricity on described dynamic token, initialized, by the input pin in described I/O unit
Original state, as the first level, the output pin of described I/O unit is initialized as second electrical level;
Step s2: described dynamic token enables interrupt location, and the state of described dynamic token is set to resting state;
When described dynamic token detects described input interrupt location and produces input interruption, described dynamic token is called out
Wake up, input is waken up mark set;
When described dynamic token detects described Interruption unit and produces Interruption, described dynamic token is called out
Wake up, timing wake-up is identified set;
Step s3: described dynamic token judges the type waking up mark of set, if described input wakes up mark, then
Described input is waken up mark reset, button operation is executed according to push-button type, return execution step s2, if described timing
Wake up mark, then execution step s4;
Step s4: described dynamic token judges whether to be in massage protection state, if it is, execution step s5, otherwise
Execution step s7;
Step s5: described dynamic token obtains the value that described button disables timing module, judges described button disabling timing
Whether the value of module reaches first threshold, if it is, execution step s6, otherwise returns execution step s2;
Step s6: described dynamic token forbids described input interrupt location, and the output in described I/O unit is drawn
Pin is set to second electrical level, detects whether the input pin in described I/O unit is the first level, if it is, moving back
Go out massage protection state, the value of button exception timing module is set to the second initial value, returns execution step s2, otherwise will be described
Output pin in I/O unit is set to the first level, and the value that described button is disabled timing module is set at the beginning of first
Initial value, returns execution step s2;
Step s7: described dynamic token forbids described input interrupt location, and the output in described I/O unit is drawn
Pin is set to second electrical level, detects whether the input pin in described I/O unit is the first level, if it is, holding
Row step s8, otherwise execution step s9;
Step s8: the value of described button exception timing module is set to the second initial value by described dynamic token, returns execution
Step s2;
Step s9: described dynamic token updates the value of described button exception timing module, and judges that described button is counted extremely
When module value whether reach Second Threshold, if it is, execution step s10, otherwise return execution step s2;
Step s10: described dynamic token enters massage protection state, by the output pin in described I/O unit
It is set to the first level, the value that described button is disabled timing module is set to the first initial value;
Step s11: described dynamic token closes display screen, and the state of described dynamic token is set to resting state, returns
Execution step s2.
Described step s1 also includes: described input is waken up mark and resets, by described timing wake-up mark by described dynamic token
Know and reset, the value that described button is disabled timing module is set to the first initial value, the value of described button exception timing module is put
For the second initial value.
Described button disabling timing module is synchronous with described clock unit, when described clock unit increases by 1 second, described presses
The value that key disables timing module corresponds to increase by 1 second.
Described button disabling timing module is asynchronous with described clock unit, when described clock unit increase by 1 second, described presses
The value that key disables timing module corresponds to minimizing 1 second.
Described button exception timing module is synchronous with described clock unit, when described clock unit increases by 1 second, described presses
The value of key exception timing module is corresponding to be increased by 1 second.
Described button exception timing module is asynchronous with described clock unit, when described clock unit increase by 1 second, described presses
The value of key exception timing module is corresponding to reduce 1 second.
In described step s1, the described original state using the input pin in described I/O unit is as the first electricity
Flat, the output pin of described I/O unit is initialized as second electrical level, particularly as follows: the button in described key-press module
(key1) 1 pin is connected with vcc by resistance (r1), the original state of the input pin (k1) in described I/O unit
For high level, the output pin (k2) of described I/O unit is initialized as low level.
Whether the described input pin detecting in described I/O unit is the first level, particularly as follows: detection is described defeated
Enter/output unit in input pin (k1) whether be high level.
In described step s1, the described original state using the input pin in described I/O unit is as the first electricity
Flat, the output pin of described I/O unit is initialized as second electrical level, particularly as follows: the button in described key-press module
(key1) 1 pin is connected with gnd by resistance (r1), the original state of the input pin (k1) in described I/O unit
For low level, the output pin (k2) of described I/O unit is initialized as high level.
Whether the described input pin detecting in described I/O unit is the first level, particularly as follows: detection is described defeated
Enter/output unit in input pin (k1) whether be low level.
In described step s1, the described original state using the input pin in I/O unit, will used as the first level
The output pin of described I/O unit is initialized as second electrical level, particularly as follows:
1 pin of the button (key1, key2, key3, key4) in described key-press module passes through described resistance (r4) and connects
Vcc, the original state of the input pin (k1) in described I/O unit is high level, by described I/O unit
Output pin (k5, k6, k7, k8) is initialized as low level;
1 pin of the button (key5, key6, key7, key8) in described key-press module passes through described resistance (r3) and connects
Vcc, the original state of the input pin (k2) in described I/O unit is high level, by described I/O unit
Output pin (k5, k6, k7, k8) is initialized as low level;
1 pin of the button (key9, key10, key11, key12) in described key-press module passes through described resistance (r2) and connects
Vcc, the original state of the input pin (k3) in described I/O unit is high level, by described I/O unit
Output pin (k5, k6, k7, k8) is initialized as low level;
1 pin of the button (key13, key14, key15, key16) in described key-press module passes through described resistance (r1) even
Meet vcc, the original state of the input pin (k4) in described I/O unit is high level, by described I/O unit
Output pin (k5, k6, k7, k8) be initialized as low level.
Whether the described input pin detecting in described I/O unit is the first level, particularly as follows: detection is described defeated
Enter/output unit in input pin (k1, k2, k3, k4) whether be high level.
In described step s1, the described original state using the input pin in I/O unit, will used as the first level
The output pin of described I/O unit is initialized as second electrical level, particularly as follows:
1 pin of the button (key1, key2, key3, key4) in described key-press module is connected with gnd by resistance (r4),
The original state of the input pin (k1) in described I/O unit is low level, by the output of described I/O unit
Pin (k5, k6, k7, k8) is initialized as high level;
1 pin of the button (key5, key6, key7, key8) in described key-press module is connected with gnd by resistance (r3),
The original state of the input pin (k2) in described I/O unit is low level, by the output of described I/O unit
Pin (k5, k6, k7, k8) is initialized as high level;
1 pin of the button (key9, key10, key11, key12) in described key-press module passes through resistance (r2) with gnd even
Connect, the original state of the input pin (k3) in described I/O unit is low level, by described I/O unit
Output pin (k5, k6, k7, k8) is initialized as high level;
1 pin of the button (key13, key14, key15, key16) in described key-press module passes through resistance (r1) with gnd even
Connect, the original state of the input pin (k4) in described I/O unit is low level, by described I/O unit
Output pin (k5, k6, k7, k8) is initialized as high level.
Whether the described input pin detecting in described I/O unit is the first level, particularly as follows: detection is described defeated
Enter/output unit in input pin (k1, k2, k3, k4) whether be low level.
Described step s1 also includes: massage protection is identified and resets;
In described step s4, described judge whether to be in massage protection state, particularly as follows: judging described massage protection mark
Whether set, if it is, described dynamic token is in massage protection state, otherwise described dynamic token is not in massage protection
State;
In described step s6, described exit massage protection state, particularly as follows: by described massage protection identify reset;
In described step s10, described entrance massage protection state, particularly as follows: described massage protection is identified set.
The beneficial effect that the present invention obtains is: using the described scheme of the present invention, can reduce dynamic token because improper
Button operation and the power consumption that causes, increased the service life of dynamic token.
Brief description
For the clearer explanation embodiment of the present invention or technical scheme of the prior art, below will be to embodiment or existing
Have technology description in required use accompanying drawing be briefly described it should be apparent that, drawings in the following description be only this
Some embodiments of invention, for those of ordinary skill in the art, on the premise of not paying creative work, acceptable
Other accompanying drawings are obtained according to these accompanying drawings.
Fig. 1 is a kind of module map of dynamic token with massage protection function that the embodiment of the present invention 1 provides;
Fig. 2 is a kind of circuit theory diagrams of dynamic token with single-button defencive function that the embodiment of the present invention 1 provides;
Fig. 3 is the circuit theory of the dynamic token that the another kind that the embodiment of the present invention 1 provides has single-button defencive function
Figure;
Fig. 4 is a kind of circuit theory diagrams of dynamic token with many massage protections function that the embodiment of the present invention 1 provides;
Fig. 5 is the circuit theory of the dynamic token that the another kind that the embodiment of the present invention 1 provides has many massage protections function
Figure;
Fig. 6 is a kind of method of work flow process of dynamic token with massage protection function that the embodiment of the present invention 2 provides
Figure.
Specific embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete
Site preparation description is it is clear that described embodiment is only a part of embodiment of the present invention, rather than whole embodiments.It is based on
Embodiment in the present invention, it is every other that those of ordinary skill in the art are obtained under the premise of not making creative work
Embodiment, broadly falls into the scope of protection of the invention.
Embodiment 1
The embodiment of the present invention 1 provides a kind of dynamic token with massage protection function, as shown in Figure 1, comprising: master control
Module 101, display module 102, key-press module 103, power module 104, button disabling timing module 105 and button exception timing
Module 106;Wherein, described main control module 101 includes clock unit 1011, Interruption unit 1012, input interrupt location
1013 and I/O unit 1014;
Described clock unit 1011: be connected with described Interruption unit, for for described main control module 101 and described fixed
When interrupt location 1012 provide reliable clock source;
Described Interruption unit 1012: be connected with described clock unit, for the triggering in described clock unit 1011
Under, self-timing, when reaching Preset Time, under described main control module 101 controls, produce Interruption;
Described input interrupt location 1013: be connected with described I/O unit, in described I/O unit
When 1014 incoming levels produce default change, under the control of described main control module 101, produce input and interrupt;
Described I/O unit 1014: be connected with described input interrupt location, for by output pin output level
With by input pin receives input level, when the incoming level being received by described input pin produces default change,
Under the control of described main control module, described input interrupt location produces input to interrupt;It is connected with described key-press module, know described
The state that in key-press module 103, button is pressed or is not pressed;
Wherein, preset change particularly as follows: incoming level is changed into low level from high level or is changed into high level from low level;
Preferably, a kind of level change can only be set in a scheme;
Described display module 102: it is connected with described main control module 101, under the control of described main control module 101,
Display information;
Described key-press module 103: be connected with described I/O unit 1013, for described I/O unit
The state that 1013 feedback buttons are pressed or are not pressed;
Described power module 104: be connected with described main control module and described display module, for described main control module
101 and described display module 102 provide electric energy;
Described button disables timing module 105: is connected with described Interruption unit 1012, in described main control module
101 time controlling lower record button disabling;
Described button exception timing module 106: be connected with described Interruption unit 1012, in described main control module
101 control is lower to record the time that button is pressed.
Referring to Fig. 2, a kind of circuit of the dynamic token with single-button defencive function providing for the embodiment of the present invention 1 is former
Reason figure, described key-press module 103 includes button (key1) and resistance (r1), and described I/O unit 1014 includes input and draws
Pin (k1) and output pin (k2);The chip of label mcu correspond to the main control module 101 in the present embodiment, the chip of label lcd
Correspond to the display module 102 in the present embodiment, the power supply of label battary correspond to the power module 104 in the present embodiment;
Described key-press module 103 is connected as with the physical circuit of described I/O unit 1014: described button (key1)
1 pin by described resistance (r1) connect vcc, simultaneously 1 pin of described button (key1) be connected with described input pin (k1), institute
2 pin stating button (key1) are connected with described output pin (k2);
Described output pin (k2) exports low level;When described button (key1) is not pressed, described input pin (k1)
For high level, when described button (key1) is pressed, described input pin (k1) is connected with described output pin (k2), described defeated
Enter pin (k1) and be changed into low level.
Referring to Fig. 3, the another kind providing for the embodiment of the present invention 1 has the circuit of the dynamic token of single-button defencive function
Schematic diagram, described key-press module 103 includes button (key1) and resistance (r1), and described I/O unit 1014 includes inputting
Pin (k1) and output pin (k2);The chip of label mcu correspond to the main control module 101 in the present embodiment, the core of label lcd
Piece correspond to the display module 102 in the present embodiment, and the power supply of label battary correspond to the power module in the present embodiment
104;
Described key-press module 103 is connected as with the physical circuit of described I/O unit 1014: described button (key1)
1 pin by described resistance (r1) connect gnd, simultaneously 1 pin of described button (key1) be connected with described output pin (k1), institute
2 pin stating button (key1) are connected with described input pin (k2);
Described output pin (k2) exports high level;When described button (key1) is not pressed, described input pin (k1)
State is low level, and when described button (key1) is pressed, described input pin (k1) is connected with described output pin (k2), institute
State input pin (k1) and be changed into high level.
Referring to Fig. 4, a kind of circuit of the dynamic token with many massage protections function providing for the embodiment of the present invention 1 is former
Reason figure, described key-press module 103 include button (key1, key2, key3, key4, key5, key6, key7, key8, key9,
Key10, key11, key12, key13, key14, key15, key16) and resistance (r1, r2, r3, r4), described input/output list
Unit 1014 includes input pin (k1, k2, k3, k4) and output pin (k5, k6, k7, k8);The chip of label mcu correspond to this
Main control module 101 in embodiment, the chip of label lcd correspond to the display module 102 in the present embodiment, label battary
Power supply correspond to the power module 104 in the present embodiment;
Described key-press module 103 is connected as with the physical circuit of described I/O unit 1014:
1 pin of described button (key1, key2, key3, key4) connects vcc by described resistance (r4), simultaneously described presses
1 pin of key (key1, key2, key3, key4) is connected with described input pin (k1), described button (key1, key2, key3,
Key4 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key5, key6, key7, key8) connects vcc by described resistance (r3), simultaneously described presses
1 pin of key (key5, key6, key7, key8) is connected with described input pin (k2), described button (key5, key6, key7,
Key8 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key9, key10, key11, key12) connects vcc by described resistance (r2), simultaneously described
1 pin of button (key9, key10, key11, key12) is connected with described input pin (k3), described button (key9, key10,
Key11, key12) 2 pin be connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key13, key14, key15, key16) connects vcc, institute simultaneously by described resistance (r1)
1 pin stating button (key13, key14, key15, key16) is connected with described input pin (k4), described button (key13,
Key14, key15, key16) 2 pin be connected with described output pin (k5, k6, k7, k8) respectively;
Described output pin (k5, k6, k7, k8) exports low level;When described button (key1, key2, key3, key4) not
When pressing, described input pin (k1) be high level, when described button (key1) is pressed, described input pin (k1) with described
Output pin (k5) is connected so that described input pin (k1) is low level;When described button (key2) is pressed, described input
Pin (k1) is connected with described output pin (k6) so that described input pin (k1) is low level;As described button (key3)
When pressing, described input pin (k1) is connected with described output pin (k7) so that described input pin (k1) is low level;When
When described button (key4) is pressed, described input pin (k1) is connected with described output pin (k8) so that described input pin
(k1) it is low level;
Described output pin (k5, k6, k7, k8) exports low level;When described button (key5, key6, key7, key8) not
When pressing, described input pin (k2) be high level, when described button (key5) is pressed, described input pin (k2) with described
Output pin (k5) is connected so that described input pin (k2) is low level;When described button (key6) is pressed, described input
Pin (k2) is connected with described output pin (k6) so that described input pin (k2) is low level;As described button (key7)
When pressing, described input pin (k2) is connected with described output pin (k7) so that described input pin (k2) is low level;When
When described button (key8) is pressed, described input pin (k2) is connected with described output pin (k8) so that described input pin
(k2) it is low level;
Described output pin (k5, k6, k7, k8) exports low level;When described button (key9, key10, key11,
When key12) not pressing, described input pin (k3) is high level, when described button (key9) is pressed, described input pin
(k3) it is connected with described output pin (k5) so that described input pin (k3) is low level;When described button (key10) is pressed
When, described input pin (k3) is connected with described output pin (k6) so that described input pin (k3) is low level;When described
When button (key11) is pressed, described input pin (k3) is connected with described output pin (k7) so that described input pin (k3)
For low level;When described button (key12) is pressed, described input pin (k3) be connected with described output pin (k8) so that
Described input pin (k3) is low level;
Described output pin (k5, k6, k7, k8) exports low level;When described button (key13, key14, key15,
When key16) not pressing, described input pin (k4) is high level, when described button (key13) is pressed, described input pin
(k4) it is connected with described output pin (k5) so that described input pin (k4) is low level;When described button (key14) is pressed
When, described input pin (k4) is connected with described output pin (k6) so that described input pin (k4) is low level;When described
When button (key15) is pressed, described input pin (k4) is connected with described output pin (k7) so that described input pin (k4)
For low level;When described button (key16) is pressed, described input pin (k4) be connected with described output pin (k8) so that
Described input pin (k4) is low level.
Referring to Fig. 5, the another kind providing for the embodiment of the present invention 1 has the circuit of the dynamic token of many massage protections function
Schematic diagram, described key-press module 103 include button (key1, key2, key3, key4, key5, key6, key7, key8, key9,
Key10, key11, key12, key13, key14, key15, key16) and resistance (r1, r2, r3, r4), described input/output list
Unit 1014 includes input pin (k1, k2, k3, k4) and output pin (k5, k6, k7, k8);The chip of label mcu correspond to this
Main control module 101 in embodiment, the chip of label lcd correspond to the display module 102 in the present embodiment, label battary
Power supply correspond to the power module 104 in the present embodiment;
Described key-press module 103 is connected as with the physical circuit of described I/O unit 1014:
1 pin of described button (key1, key2, key3, key4) is connected with gnd by described resistance (r4), simultaneously described
1 pin of button (key1, key2, key3, key4) is connected with described input pin (k1), described button (key1, key2, key3,
Key4 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key5, key6, key7, key8) is connected with gnd by described resistance (r3), simultaneously described
1 pin of button (key5, key6, key7, key8) is connected with described input pin (k2), described button (key5, key6, key7,
Key8 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key9, key10, key11, key12) is connected with gnd by described resistance (r2), institute simultaneously
1 pin stating button (key9, key10, key11, key12) is connected with described input pin (k3), described button (key9,
Key10, key11, key12) 2 pin be connected with respectively described output pin (k5, k6, k7, k8);
1 pin of described button (key13, key14, key15, key16) is connected with gnd, simultaneously by described resistance (r1)
1 pin of described button (key13, key14, key15, key16) is connected with described input pin (k4), described button (key13,
Key14, key15, key16) 2 pin be connected with described output pin (k5, k6, k7, k8) respectively;
Described output pin (k5, k6, k7, k8) exports high level;When described button (key1, key2, key3, key4) not
When pressing, described input pin (k1) be low level, when described button (key1) is pressed, described input pin (k1) with described
Output pin (k5) is connected so that described input pin (k1) is high level;When described button (key2) is pressed, described input
Pin (k1) is connected with described output pin (k6) so that described input pin (k1) is high level;As described button (key3)
When pressing, described input pin (k1) is connected with described output pin (k7) so that described input pin (k1) is high level;When
When described button (key4) is pressed, described input pin (k1) is connected with described output pin (k8) so that described input pin
(k1) it is high level;
Described output pin (k5, k6, k7, k8) exports high level;When described button (key5, key6, key7, key8) not
When pressing, described input pin (k2) be low level, when described button (key5) is pressed, described input pin (k2) with described
Output pin (k5) is connected so that described input pin (k2) is high level;When described button (key6) is pressed, described input
Pin (k2) is connected with described output pin (k6) so that described input pin (k2) is high level;As described button (key7)
When pressing, described input pin (k2) is connected with described output pin (k7) so that described input pin (k2) is high level;When
When described button (key8) is pressed, described input pin (k2) is connected with described output pin (k8) so that described input pin
(k2) it is high level;
Described output pin (k5, k6, k7, k8) exports high level;When described button (key9, key10, key11,
When key12) not pressing, described input pin (k3) is low level, when described button (key9) is pressed, described input pin
(k3) it is connected with described output pin (k5) so that described input pin (k3) is high level;When described button (key10) is pressed
When, described input pin (k3) is connected with described output pin (k6) so that described input pin (k3) is high level;When described
When button (key11) is pressed, described input pin (k3) is connected with described output pin (k7) so that described input pin (k3)
For high level;When described button (key12) is pressed, described input pin (k3) be connected with described output pin (k8) so that
Described input pin (k3) is high level;
Described output pin (k5, k6, k7, k8) exports high level;When described button (key13, key14, key15,
When key16) not pressing, described input pin (k4) is low level, when described button (key13) is pressed, described input pin
(k4) it is connected with described output pin (k5) so that described input pin (k4) is high level;When described button (key14) is pressed
When, described input pin (k4) is connected with described output pin (k6) so that described input pin (k4) is high level;When described
When button (key15) is pressed, described input pin (k4) is connected with described output pin (k7) so that described input pin (k4)
For high level;When described button (key16) is pressed, described input pin (k4) be connected with described output pin (k8) so that
Described input pin (k4) is high level.
Embodiment 2
The embodiment of the present invention 2 is to provide a kind of dynamic token with massage protection function on the basis of embodiment 1
Method of work, as shown in Figure 6, comprising:
Step 201: electricity on dynamic token, initialized, by the initial shape of the input pin of described I/O unit
State, as the first level, the output pin of described I/O unit is initialized as second electrical level;
Wherein, Fig. 2 in embodiment 1, the original state of the described input pin using described I/O unit is as first
Level, the output pin of described I/O unit is initialized as second electrical level, particularly as follows: the button in key-press module
(key1) 1 pin is connected with vcc by resistance (r1), then the initial shape of the input pin (k1) in described I/O unit
State is high level, and described output pin (k2) is initialized as low level;
Wherein, Fig. 3 in embodiment 1, the original state of the described input pin using described I/O unit is as first
Level, the output pin of described I/O unit is initialized as second electrical level, if particularly as follows: pressing in key-press module
1 pin of key (key1) is connected with gnd by resistance (r1), then the input pin (k1) in described I/O unit is initial
State is low level, and the output pin (k2) in described I/O unit is initialized as high level;
Wherein, Fig. 4 in embodiment 1, the described original state using the input pin in I/O unit is as the first electricity
Flat, described output pin is initialized as second electrical level, particularly as follows:
1 pin of the button (key1, key2, key3, key4) in key-press module connects vcc, institute by described resistance (r1)
The original state stating the input pin (k1) in I/O unit is high level, by described output pin (k5, k6, k7, k8)
It is initialized as low level;
1 pin of the button (key5, key6, key7, key8) in key-press module connects vcc, institute by described resistance (r2)
The original state stating the input pin (k2) in I/O unit is high level, by described output pin (k5, k6, k7, k8)
It is initialized as low level;
1 pin of the button (key9, key10, key11, key12) in key-press module connects vcc by described resistance (r3),
The original state of the input pin (k3) in described I/O unit be high level, by described output pin (k5, k6, k7,
K8) it is initialized as low level;
1 pin of the button (key13, key14, key15, key16) in key-press module passes through described resistance (r4) and connects
Vcc, the original state of the input pin (k4) in described I/O unit is high level, by described output pin (k5, k6,
K7, k8) it is initialized as low level;
Wherein, Fig. 5 in embodiment 1, the described original state using the input pin in I/O unit is as the first electricity
Flat, described output pin is initialized as second electrical level, particularly as follows:
1 pin of the button (key1, key2, key3, key4) in key-press module is connected with gnd by resistance (r1), described
The original state of the input pin (k1) in I/O unit is low level, by described output pin (k5, k6, k7, k8) just
Begin to turn to high level;
1 pin of the button (key5, key6, key7, key8) in key-press module is connected with gnd by resistance (r2), described
The original state of the input pin (k2) in I/O unit is low level, by described output pin (k5, k6, k7, k8) just
Begin to turn to high level;
1 pin of the button (key9, key10, key11, key12) in key-press module is connected with gnd by resistance (r3), institute
The original state stating the input pin (k3) in I/O unit is low level, by described output pin (k5, k6, k7, k8)
It is initialized as high level;
1 pin of the button (key13, key14, key15, key16) in key-press module is connected with gnd by resistance (r4),
The original state of the input pin (k4) in described I/O unit be low level, by described output pin (k5, k6, k7,
K8) it is initialized as high level;
In the present embodiment, dynamic token is initialized, particularly as follows: key wakeup is identified resetting, by timing wake-up mark
Know and reset, massage protection is identified and resets, the value that button is disabled timer is set to the first initial value, by button exception timer
Value be set to the second initial value;
Step 202: described dynamic token enables interrupt location, and the state of described dynamic token is set to resting state;
In the present embodiment, described enable interrupt location specifically includes enable input interrupt location 1013, enables in timing
Disconnected unit 1012;
When described dynamic token detects described input interrupt location 1013 and produces input interruption, described dynamic token quilt
Wake up, input is waken up mark set;
When described dynamic token detects described Interruption unit 1012 and produces Interruption, described dynamic token quilt
Wake up, timing wake-up is identified set;
It is preferred that when described clock unit 1011 reaches Preset Time, dynamic token detects described in the present embodiment
Interruption unit 1012 produces Interruption it is preferred that Preset Time is 1 second;
Step 203: described dynamic token judges the type waking up mark of set, if input wakes up mark, then holds
Row step 204, if timing wake-up mark, then execution step 205;
Step 204: described input is waken up mark and resets by dynamic token, executes button operation according to push-button type, returns
Execution step 202;
In the present embodiment, push-button type includes: ON/OFF switch, delete key, login button, and up/down turns over key, numerical key etc.;Hold
Row button operation includes generating dynamic password etc.;
Step 205: dynamic token judges whether to be in massage protection state, if it is, execution step 206, otherwise holds
Row step 210;
It is preferred that described judge whether to be in massage protection state in the present embodiment, particularly as follows: judging that described button is protected
Shield identify whether set, if it is, described dynamic token is in massage protection state, otherwise described dynamic token be not in by
Key protection state;
Step 206: described dynamic token obtains the value that button disables timing module, judges described button disabling timing module
Value whether reach first threshold, if it is, execution step 207, otherwise return execution step 202;
In the present embodiment, button disabling timing module is synchronous with dynamic token internal clocking, when dynamic token internal clocking
When time increases by 1 second, button disables the corresponding increase of value 1 second of computing module it is preferred that first threshold is 5 seconds;
Can also be: when dynamic token internal clock time increases by 1 second, button disables the corresponding minimizing of value of timing module
1 second it is preferred that first threshold is 0 second;
Step 207: described dynamic token forbids described input interrupt location, described output pin is set to the second electricity
Flat, detect whether described input pin is the first level, if it is, execution step 209, otherwise execution step 208;
Wherein, Fig. 2 in embodiment 1, whether the input pin in the described I/O unit of described detection is the first electricity
Flat, particularly as follows: detecting whether the input pin (k1) in described I/O unit is high level;
Wherein, Fig. 3 in embodiment 1, whether the input pin in the described I/O unit of described detection is the first electricity
Flat, particularly as follows: detecting whether the input pin (k1) in described I/O unit is low level;
Wherein, Fig. 4 in embodiment 1, whether the input pin in the described I/O unit of described detection is the first electricity
Flat, particularly as follows: detecting whether the input pin (k1, k2, k3, k4) in described I/O unit is high level;
Wherein, Fig. 5 in embodiment 1, whether the input pin in the described I/O unit of described detection is the first electricity
Flat, particularly as follows: detecting whether the input pin (k1, k2, k3, k4) in described I/O unit is low level;
Step 208: the output pin in described I/O unit is set to the first level by dynamic token, will be described
The value that button disables timing module is set to the first initial value, returns execution step 202;
In the present embodiment, if made an appointment when dynamic token internal clocking increases by 1 second, button disables timing module
Value is corresponding to be increased by 1 second, then preferably, the first initial value is 0 second;
If making an appointment when dynamic token internal clocking increases by 1 second, the value that button disables timing module corresponds to minimizing 1
Second, then preferably, the second initial value is 5 seconds;
Step 209: dynamic token exits massage protection state, the value of button exception timing module is set to second initial
Value, returns execution step 202;
Wherein, described exit massage protection state, particularly as follows: by described massage protection identify reset;
In the present embodiment, button exception timing module is synchronous with dynamic token internal clocking, if it is dynamic to make an appointment
State token internal clock time increases by 1 second, and the value of button exception timing module is corresponding to be increased by 1 second, then this step is abnormal by button
The value of timing module is set to the second initial value 0 second;If dynamic token internal clocking of making an appointment increases by 1 second, button is counted extremely
When module value corresponding reduce 1 second, then the value of button exception timing module is set to the second initial value 10 seconds by this step;
Step 210: described dynamic token forbids described input interrupt location, by the output in described I/O unit
Pin is set to second electrical level, detects whether the input pin in described I/O unit is the first level, if it is,
Execution step 211, otherwise execution step 212;
Step 211: the value of described button exception timing module is set to the second initial value by described dynamic token, returns execution
Step 202;
Step 212: described dynamic token updates the value of described button exception timing module, and judges that described button is counted extremely
When module value whether reach Second Threshold, if it is, execution step 213, otherwise return execution step 202;
In the present embodiment, if button exception timing module is synchronous with dynamic token internal clocking, dynamic token
Internal clock time increases by 1 second, and the value updating button exception timing module is that the value of button exception timing module is corresponded to increase by 1
Second, then when the value of button exception timing module reaches Second Threshold 10 seconds, execution step 213;If button exception timing mould
Block and dynamic token internal clocking are asynchronous, then dynamic token internal clocking increases by 1 second, update button exception timing module
Value is to reduce 1 second by corresponding for the value of button exception timing module, then when the value of button exception timing module reaches Second Threshold 0 second
When, execution step 213;
Step 213: described dynamic token enters massage protection state, by the output pin in described I/O unit
It is set to the first level, the value that described button is disabled timing module is set to the first initial value;
In the present embodiment, if dynamic token internal clocking of making an appointment increases by 1 second, button disabling timing module corresponds to
Increase by 1 second, then this step by button disable timing module value be set to the first initial value 0 second;If making an appointment dynamic token
Internal clocking increases by 1 second, then button disabling timing module is corresponding reduces 1 second, then button is disabled the value of timing module by this step
It is set to the first initial value 5 seconds;
Step 214: described dynamic token closes display screen, and the state of described dynamic token is set to resting state, returns
Execution step 202;
In the present embodiment, the output pin in input pin and I/O unit in I/O unit is
One level, is capable of dynamic token and input can not be occurred to interrupt, when button is pressed, electric current does not increase, and so that dynamic token is entered low
Power consumption state.
The above, the only present invention preferably specific embodiment, but protection scope of the present invention is not limited thereto,
Any those familiar with the art in technical scope disclosed by the invention, the change or replacement that can readily occur in,
All should be included within the scope of the present invention.Therefore, protection scope of the present invention should be with scope of the claims
It is defined.
Claims (27)
1. a kind of dynamic token with massage protection function is it is characterised in that include: main control module, key-press module, button are prohibited
With timing module and button exception timing module;Wherein, described main control module includes clock unit, Interruption unit, input
Interrupt location and I/O unit;
Described clock unit: be connected with described Interruption unit, for providing reliable clock source for described Interruption unit;
Described Interruption unit: it is connected with described clock unit, under the triggering of described clock unit, self-timing,
When reaching Preset Time, produce Interruption;
Described input interrupt location: be connected with described I/O unit, in described I/O unit incoming level
When producing default change, produce input and interrupt;
Described I/O unit: be connected with described input interrupt location, for by output pin output level with by defeated
Enter pin receives input level, when the incoming level receiving by described input pin produces default change, in described input
Disconnected unit produces input to interrupt;It is connected with described key-press module, know the shape that in described key-press module, button is pressed or do not pressed
State;
Described key-press module: be connected with described I/O unit, for being pressed to described I/O unit feedback button
State that is lower or not being pressed;
Described button disables timing module: is connected with described Interruption unit, for remembering under the control of described main control module
The time of record button disabling;
Described button exception timing module: be connected with described Interruption unit, for remembering under the control of described main control module
The time that record button is pressed.
2. a kind of dynamic token with massage protection function according to claim 1 is it is characterised in that also include:
Display module and power module;
Described display module: it is connected with described main control module, under the control of described main control module, display information;
Described power module: be connected with described main control module and described display module, for described main control module and described aobvious
Show that module provides electric energy.
3. a kind of dynamic token with massage protection function according to claim 1 is it is characterised in that described button mould
Block includes button (key1) and resistance (r1), and described I/O unit includes input pin (k1) and output pin (k2).
4. a kind of dynamic token with massage protection function according to claim 3 is it is characterised in that described button mould
Block is connected as with the physical circuit of described I/O unit: 1 pin of described button (key1) is connected by described resistance (r1)
Vcc, simultaneously 1 pin of described button (key1) be connected with described input pin (k1), 2 pin of described button (key1) are defeated with described
Go out pin (k2) to connect.
5. a kind of dynamic token with massage protection function according to claim 4 is it is characterised in that described output is drawn
Pin (k2) exports low level;When described button (key1) is not pressed, described input pin (k1) is high level, presses when described
When key (key1) is pressed, described input pin (k1) is connected with described output pin (k2), and described input pin (k1) is changed into
Low level.
6. a kind of dynamic token with massage protection function according to claim 3 is it is characterised in that described button mould
Block is connected as with the physical circuit of described I/O unit: 1 pin of described button (key1) is connected by described resistance (r1)
Gnd, simultaneously 1 pin of described button (key1) be connected with described output pin (k1), 2 pin of described button (key1) are defeated with described
Enter pin (k2) to connect.
7. a kind of dynamic token with massage protection function according to claim 6 is it is characterised in that described output is drawn
Pin (k2) exports high level;When described button (key1) is not pressed, described input pin (k1) state is low level, works as institute
When stating button (key1) and being pressed, described input pin (k1) is connected with described output pin (k2), described input pin (k1)
It is changed into high level.
8. a kind of dynamic token with massage protection function according to claim 1 is it is characterised in that described button mould
Block include button (key1, key2, key3, key4, key5, key6, key7, key8, key9, key10, key11, key12,
Key13, key14, key15, key16) and resistance (r1, r2, r3, r4), described I/O unit include input pin (k1,
K2, k3, k4) and output pin (k5, k6, k7, k8).
9. a kind of dynamic token with massage protection function according to claim 8 is it is characterised in that described button mould
Block is connected as with the physical circuit of described I/O unit:
1 pin of described button (key1, key2, key3, key4) connects vcc, described button simultaneously by described resistance (r4)
1 pin of (key1, key2, key3, key4) is connected with described input pin (k1), described button (key1, key2, key3,
Key4 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key5, key6, key7, key8) connects vcc, described button simultaneously by described resistance (r3)
1 pin of (key5, key6, key7, key8) is connected with described input pin (k2), described button (key5, key6, key7,
Key8 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key9, key10, key11, key12) connects vcc, described button simultaneously by described resistance (r2)
1 pin of (key9, key10, key11, key12) is connected with described input pin (k3), described button (key9, key10,
Key11, key12) 2 pin be connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key13, key14, key15, key16) connects vcc by described resistance (r1), simultaneously described presses
1 pin of key (key13, key14, key15, key16) is connected with described input pin (k4), described button (key13, key14,
Key15, key16) 2 pin be connected with described output pin (k5, k6, k7, k8) respectively.
10. a kind of dynamic token with massage protection function according to claim 9 it is characterised in that
Described output pin (k5, k6, k7, k8) exports low level;When described button (key1, key2, key3, key4) is not pressed
When lower, described input pin (k1) be high level, when described button (key1) is pressed, described input pin (k1) with described
Output pin (k5) is connected so that described input pin (k1) is low level;When described button (key2) is pressed, described defeated
Enter pin (k1) to be connected with described output pin (k6) so that described input pin (k1) is low level;When described button
(key3), when being pressed, described input pin (k1) is connected with described output pin (k7) so that described input pin (k1) is
Low level;When described button (key4) is pressed, described input pin (k1) is connected with described output pin (k8) so that institute
Stating input pin (k1) is low level;
Described output pin (k5, k6, k7, k8) exports low level;When described button (key5, key6, key7, key8) is not pressed
When lower, described input pin (k2) be high level, when described button (key5) is pressed, described input pin (k2) with described
Output pin (k5) is connected so that described input pin (k2) is low level;When described button (key6) is pressed, described defeated
Enter pin (k2) to be connected with described output pin (k6) so that described input pin (k2) is low level;When described button
(key7), when being pressed, described input pin (k2) is connected with described output pin (k7) so that described input pin (k2) is
Low level;When described button (key8) is pressed, described input pin (k2) is connected with described output pin (k8) so that institute
Stating input pin (k2) is low level;
Described output pin (k5, k6, k7, k8) exports low level;When described button (key9, key10, key11, key12) not
When being pressed, described input pin (k3) be high level, when described button (key9) is pressed, described input pin (k3) with
Described output pin (k5) is connected so that described input pin (k3) is low level;When described button (key10) is pressed,
Described input pin (k3) is connected with described output pin (k6) so that described input pin (k3) is low level;Press when described
When key (key11) is pressed, described input pin (k3) is connected with described output pin (k7) so that described input pin (k3)
For low level;When described button (key12) is pressed, described input pin (k3) is connected with described output pin (k8), makes
Obtaining described input pin (k3) is low level;
Described output pin (k5, k6, k7, k8) exports low level;When described button (key13, key14, key15, key16) not
When being pressed, described input pin (k4) is high level, when described button (key13) is pressed, described input pin (k4)
It is connected with described output pin (k5) so that described input pin (k4) is low level;When described button (key14) is pressed
When, described input pin (k4) is connected with described output pin (k6) so that described input pin (k4) is low level;When described
When button (key15) is pressed, described input pin (k4) is connected with described output pin (k7) so that described input pin
(k4) it is low level;When described button (key16) is pressed, described input pin (k4) and described output pin (k8) phase
Even so that described input pin (k4) is low level.
A kind of 11. dynamic tokens with massage protection function according to claim 8 are it is characterised in that described button
Module is connected as with the physical circuit of described I/O unit:
1 pin of described button (key1, key2, key3, key4) is connected with gnd by described resistance (r4), described button simultaneously
1 pin of (key1, key2, key3, key4) is connected with described input pin (k1), described button (key1, key2, key3,
Key4 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key5, key6, key7, key8) is connected with gnd by described resistance (r3), described button simultaneously
1 pin of (key5, key6, key7, key8) is connected with described input pin (k2), described button (key5, key6, key7,
Key8 2 pin) are connected with described output pin (k5, k6, k7, k8) respectively;
1 pin of described button (key9, key10, key11, key12) is connected with gnd by described resistance (r2), simultaneously described presses
1 pin of key (key9, key10, key11, key12) is connected with described input pin (k3), described button (key9, key10,
Key11, key12) 2 pin be connected with respectively described output pin (k5, k6, k7, k8);
1 pin of described button (key13, key14, key15, key16) is connected with gnd by described resistance (r1), simultaneously described
1 pin of button (key13, key14, key15, key16) is connected with described input pin (k4), described button (key13,
Key14, key15, key16) 2 pin be connected with described output pin (k5, k6, k7, k8) respectively.
A kind of 12. dynamic tokens with massage protection function according to claim 11 it is characterised in that
Described output pin (k5, k6, k7, k8) exports high level;When described button (key1, key2, key3, key4) is not pressed
When lower, described input pin (k1) be low level, when described button (key1) is pressed, described input pin (k1) with described
Output pin (k5) is connected so that described input pin (k1) is high level;When described button (key2) is pressed, described defeated
Enter pin (k1) to be connected with described output pin (k6) so that described input pin (k1) is high level;When described button
(key3), when being pressed, described input pin (k1) is connected with described output pin (k7) so that described input pin (k1) is
High level;When described button (key4) is pressed, described input pin (k1) is connected with described output pin (k8) so that institute
Stating input pin (k1) is high level;
Described output pin (k5, k6, k7, k8) exports high level;When described button (key5, key6, key7, key8) is not pressed
When lower, described input pin (k2) be low level, when described button (key5) is pressed, described input pin (k2) with described
Output pin (k5) is connected so that described input pin (k2) is high level;When described button (key6) is pressed, described defeated
Enter pin (k2) to be connected with described output pin (k6) so that described input pin (k2) is high level;When described button
(key7), when being pressed, described input pin (k2) is connected with described output pin (k7) so that described input pin (k2) is
High level;When described button (key8) is pressed, described input pin (k2) is connected with described output pin (k8) so that institute
Stating input pin (k2) is high level;
Described output pin (k5, k6, k7, k8) exports high level;When described button (key9, key10, key11, key12) not
When being pressed, described input pin (k3) be low level, when described button (key9) is pressed, described input pin (k3) with
Described output pin (k5) is connected so that described input pin (k3) is high level;When described button (key10) is pressed,
Described input pin (k3) is connected with described output pin (k6) so that described input pin (k3) is high level;Press when described
When key (key11) is pressed, described input pin (k3) is connected with described output pin (k7) so that described input pin (k3)
For high level;When described button (key12) is pressed, described input pin (k3) is connected with described output pin (k8), makes
Obtaining described input pin (k3) is high level;
Described output pin (k5, k6, k7, k8) exports high level;When described button (key13, key14, key15, key16) not
When being pressed, described input pin (k4) is low level, when described button (key13) is pressed, described input pin (k4)
It is connected with described output pin (k5) so that described input pin (k4) is high level;When described button (key14) is pressed
When, described input pin (k4) is connected with described output pin (k6) so that described input pin (k4) is high level;When described
When button (key15) is pressed, described input pin (k4) is connected with described output pin (k7) so that described input pin
(k4) it is high level;When described button (key16) is pressed, described input pin (k4) and described output pin (k8) phase
Even so that described input pin (k4) is high level.
A kind of a kind of 13. method of works of the dynamic token with massage protection function being applied to described in claim 1, it is special
Levy and be, comprising:
Step s1: electricity on described dynamic token, initialized, the input pin in described I/O unit is initial
State, as the first level, the output pin of described I/O unit is initialized as second electrical level;
Step s2: described dynamic token enables interrupt location, and the state of described dynamic token is set to resting state;
When described dynamic token detects described input interrupt location and produces input interruption, described dynamic token is waken up, will
Input wakes up mark set;
When described dynamic token detects described Interruption unit and produces Interruption, described dynamic token is waken up, will
Timing wake-up identifies set;
Step s3: described dynamic token judges the type waking up mark of set, if described input wakes up mark, then by institute
State input and wake up mark reset, button operation is executed according to push-button type, returns execution step s2, if described timing wake-up
Mark, then execution step s4;
Step s4: described dynamic token judges whether to be in massage protection state, if it is, execution step s5, otherwise executes
Step s7;
Step s5: described dynamic token obtains the value that described button disables timing module, judges described button disabling timing module
Value whether reach first threshold, if it is, execution step s6, otherwise return execution step s2;
Step s6: described dynamic token forbids described input interrupt location, and the output pin in described I/O unit is set
Be set to second electrical level, detect whether the input pin in described I/O unit is the first level, if it is, exit by
Key protection state, the value of button exception timing module is set to the second initial value, returns execution step s2, otherwise will be described defeated
Enter/output unit in output pin be set to the first level, described button is disabled the value of timing module, and to be set to first initial
Value, returns execution step s2;
Step s7: described dynamic token forbids described input interrupt location, and the output pin in described I/O unit is set
Being set to second electrical level, detecting whether the input pin in described I/O unit is the first level, if it is, executing step
Rapid s8, otherwise execution step s9;
Step s8: the value of described button exception timing module is set to the second initial value by described dynamic token, returns execution step
s2;
Step s9: described dynamic token updates the value of described button exception timing module, and judge described button exception timing mould
Whether the value of block reaches Second Threshold, if it is, execution step s10, otherwise returns execution step s2;
Step s10: described dynamic token enters massage protection state, by the output pin setting in described I/O unit
For the first level, the value of described button disabling timing module is set to the first initial value;
Step s11: described dynamic token closes display screen, the state of described dynamic token is set to resting state, returns execution
Step s2.
14. methods according to claim 13 are it is characterised in that described step s1 also includes: described dynamic token is by institute
State input and wake up mark reset, described timing wake-up is identified and resets, the value that described button is disabled timing module is set to first
Initial value, the value of described button exception timing module is set to the second initial value.
15. methods according to claim 13 are it is characterised in that described button disables timing module and described clock unit
Synchronous, when described clock unit increases by 1 second, the value that described button disables timing module corresponds to increase by 1 second.
16. methods according to claim 13 are it is characterised in that described button disables timing module and described clock unit
Asynchronous, when described clock unit increases by 1 second, the value that described button disables timing module corresponds to minimizing 1 second.
17. methods according to claim 13 are it is characterised in that described button exception timing module and described clock unit
Synchronous, when described clock unit increases by 1 second, the value of described button exception timing module is corresponding to be increased by 1 second.
18. methods according to claim 13 are it is characterised in that described button exception timing module and described clock unit
Asynchronous, when described clock unit increases by 1 second, the value of described button exception timing module is corresponding to reduce 1 second.
19. methods according to claim 13 it is characterised in that in described step s1, described by described input/output list
The original state of the input pin in unit as the first level, the output pin of described I/O unit is initialized as the
Two level, particularly as follows: 1 pin of the button (key1) in described key-press module is connected with vcc by resistance (r1), described input/
The original state of the input pin (k1) in output unit is high level, by the output pin (k2) of described I/O unit
It is initialized as low level.
20. methods according to claim 19 are it is characterised in that input in the described I/O unit of described detection
Whether pin is the first level, particularly as follows: detecting whether the input pin (k1) in described I/O unit is high level.
21. methods according to claim 13 it is characterised in that in described step s1, described by described input/output list
The original state of the input pin in unit as the first level, the output pin of described I/O unit is initialized as the
Two level, particularly as follows: 1 pin of the button (key1) in described key-press module is connected with gnd by resistance (r1), described input/
The original state of the input pin (k1) in output unit is low level, by the output pin (k2) of described I/O unit
It is initialized as high level.
22. methods according to claim 21 are it is characterised in that input in the described I/O unit of described detection
Whether pin is the first level, particularly as follows: detecting whether the input pin (k1) in described I/O unit is low level.
23. methods according to claim 13 it is characterised in that in described step s1, described by I/O unit
Input pin original state as the first level, the output pin of described I/O unit is initialized as the second electricity
Flat, particularly as follows:
1 pin of the button (key1, key2, key3, key4) in described key-press module connects vcc by resistance (r4), described defeated
Enter/output unit in input pin (k1) original state be high level, by the output pin of described I/O unit
(k5, k6, k7, k8) is initialized as low level;
1 pin of the button (key5, key6, key7, key8) in described key-press module connects vcc by resistance (r3), described defeated
Enter/output unit in input pin (k2) original state be high level, by the output pin of described I/O unit
(k5, k6, k7, k8) is initialized as low level;
1 pin of the button (key9, key10, key11, key12) in described key-press module connects vcc by resistance (r2), described
The original state of the input pin (k3) in I/O unit is high level, by the output pin of described I/O unit
(k5, k6, k7, k8) is initialized as low level;
1 pin of the button (key13, key14, key15, key16) in described key-press module connects vcc, institute by resistance (r1)
The original state stating the input pin (k4) in I/O unit is high level, and the output of described I/O unit is drawn
Pin (k5, k6, k7, k8) is initialized as low level.
24. methods according to claim 23 are it is characterised in that input in the described I/O unit of described detection
Whether whether pin is the first level, particularly as follows: detecting input pin (k1, k2, k3, k4) in described I/O unit
It is high level.
25. methods according to claim 13 it is characterised in that in described step s1, described by I/O unit
Input pin original state as the first level, the output pin of described I/O unit is initialized as the second electricity
Flat, particularly as follows:
1 pin of the button (key1, key2, key3, key4) in described key-press module is connected with gnd by resistance (r4), described
The original state of the input pin (k1) in I/O unit is low level, by the output pin of described I/O unit
(k5, k6, k7, k8) is initialized as high level;
1 pin of the button (key5, key6, key7, key8) in described key-press module is connected with gnd by resistance (r3), described
The original state of the input pin (k2) in I/O unit is low level, by the output pin of described I/O unit
(k5, k6, k7, k8) is initialized as high level;
1 pin of the button (key9, key10, key11, key12) in described key-press module is connected with gnd by resistance (r2), institute
The original state stating the input pin (k3) in I/O unit is low level, and the output of described I/O unit is drawn
Pin (k5, k6, k7, k8) is initialized as high level;
1 pin of the button (key13, key14, key15, key16) in described key-press module is connected with gnd by resistance (r1),
The original state of the input pin (k4) in described I/O unit is low level, by the output of described I/O unit
Pin (k5, k6, k7, k8) is initialized as high level.
26. methods according to claim 25 are it is characterised in that input in the described I/O unit of described detection
Whether whether pin is the first level, particularly as follows: detecting input pin (k1, k2, k3, k4) in described I/O unit
It is low level.
27. methods according to claim 13 are it is characterised in that described step s1 also includes: will be multiple for massage protection mark
Position;
In described step s4, described judge whether to be in massage protection state, particularly as follows: judging that described massage protection identifies whether
Set, if it is, described dynamic token is in massage protection state, otherwise described dynamic token is not in massage protection shape
State;
In described step s6, described exit massage protection state, particularly as follows: by described massage protection identify reset;
In described step s10, described entrance massage protection state, particularly as follows: described massage protection is identified set.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310658897.2A CN103684785B (en) | 2013-12-09 | 2013-12-09 | Dynamic token with key protection function and working method thereof |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310658897.2A CN103684785B (en) | 2013-12-09 | 2013-12-09 | Dynamic token with key protection function and working method thereof |
Publications (2)
Publication Number | Publication Date |
---|---|
CN103684785A CN103684785A (en) | 2014-03-26 |
CN103684785B true CN103684785B (en) | 2017-01-18 |
Family
ID=50321179
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201310658897.2A Expired - Fee Related CN103684785B (en) | 2013-12-09 | 2013-12-09 | Dynamic token with key protection function and working method thereof |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103684785B (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104333454B (en) * | 2014-10-28 | 2017-07-14 | 飞天诚信科技股份有限公司 | A kind of method of work of the dynamic token of renewable seed |
CN104394145B (en) * | 2014-11-25 | 2015-09-23 | 飞天诚信科技股份有限公司 | A kind of dynamic token and method of work thereof with journal function |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101500232A (en) * | 2009-03-13 | 2009-08-05 | 北京华大智宝电子系统有限公司 | Method and system for implementing dynamic identity authentication |
CN202268898U (en) * | 2011-10-08 | 2012-06-06 | 北京集联网络技术有限公司 | Electronic dynamic token vibration waking circuit and device thereof |
CN103227720A (en) * | 2013-03-12 | 2013-07-31 | 飞天诚信科技股份有限公司 | Key processing method applied to dynamic token |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US8127142B2 (en) * | 2005-09-09 | 2012-02-28 | University Of South Florida | Method of authenticating a user on a network |
-
2013
- 2013-12-09 CN CN201310658897.2A patent/CN103684785B/en not_active Expired - Fee Related
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101500232A (en) * | 2009-03-13 | 2009-08-05 | 北京华大智宝电子系统有限公司 | Method and system for implementing dynamic identity authentication |
CN202268898U (en) * | 2011-10-08 | 2012-06-06 | 北京集联网络技术有限公司 | Electronic dynamic token vibration waking circuit and device thereof |
CN103227720A (en) * | 2013-03-12 | 2013-07-31 | 飞天诚信科技股份有限公司 | Key processing method applied to dynamic token |
Also Published As
Publication number | Publication date |
---|---|
CN103684785A (en) | 2014-03-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9565293B2 (en) | Method and device for operating mobile terminal based on sensor, and mobile terminal | |
US20180053034A1 (en) | Finger print state integration with non-application processor functions for power savings in an electronic device | |
CN104503569A (en) | Electronic equipment and awakening method thereof | |
CN104899029A (en) | Screen control method and apparatus | |
CN103543946A (en) | Gesture recognition based mobile terminal awakening and unlocking method and gesture recognition based mobile terminal awakening and unlocking system | |
US20170034331A1 (en) | Method and Device for Switching State of Terminal | |
CN106696863A (en) | Control method and system for vehicle-mounted intelligent interactive device | |
CN106250747B (en) | Information processing method and electronic equipment | |
CN107317924B (en) | Mobile terminal and dormancy method of mobile terminal | |
CN101807106A (en) | Standby circuit of handheld device and awaken method thereof | |
CN105301948A (en) | Intelligent wristwatch, screen locking management method and screen locking management system thereof | |
WO2014173244A1 (en) | Working method of smart key device | |
CN105141762B (en) | A kind of low electric closedown method and system of mobile terminal | |
CN110424831A (en) | Low power-consumption intelligent door lock | |
WO2015180607A1 (en) | Terminal | |
CN109388225A (en) | Key triggers energy-saving control method, storage medium, control device and its terminal | |
CN106095053B (en) | False-touch prevention Rouser and method and intelligent terminal | |
CN106484186B (en) | A kind of system wake-up method and device | |
CN103684785B (en) | Dynamic token with key protection function and working method thereof | |
WO2016095484A1 (en) | Mobile terminal, and method for preventing accidental touch of keys of mobile terminal | |
CN104836869A (en) | Mobile communication terminal and mobile communication terminal power-on method | |
CN104571509A (en) | Mobile terminal and awakening method thereof | |
WO2014183500A1 (en) | Working method of dynamic token | |
CN104007988A (en) | Computer startup and shutdown method and computer | |
CN206212149U (en) | Mirror cabinet camera secret protection circuit, the mirror cabinet with camera |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20170118 |
|
CF01 | Termination of patent right due to non-payment of annual fee |