Abstract:
A system for locking an electronic device is provided. The system includes an electronic device, and electronic keys electrically connected to the electronic device. The electronic key includes a plurality of resistors which are connected in series, the resistance value of the electronic key is changeable by coupling different resistors of the electronic key. The electronic device comprises of a processing unit and a function key. When the function key produces locking command in response to user operation, the processing unit obtains the resistance value of the electronic key and produce encryption key according to the obtained resistance value to unlock the electronic device. When the function key produces unlocking command, the processing unit decodes the encryption key and unlocks the electronic device when determining the obtained value matches the decoded encryption key.

Description:
BACKGROUND 
       [0001]    1. Technical Field 
         [0002]    The disclosure relates to electronic devices and, particularly, to a system for locking and unlocking an electronic device. 
         [0003]    2. Description of Related Art 
         [0004]    Nowadays, electronic devices such as mobile phones have become more and popular. To prevent unauthorized use of the device, the owner can set a password to lock or unlock the device. 
         [0005]    To set a password one must input characters using a keyboard which is not always the convenient way to the owner. Therefore, there is a need for a new method and system to lock and unlock the electronic device. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0006]    The components in the drawings are not necessarily drawn to scale, the emphasis instead being placed upon clearly illustrating the principles of the electronic device. Moreover, in the drawings, like reference numerals designate corresponding parts throughout the several views. 
           [0007]      FIG. 1  is a block diagram of a system for locking and unlocking an electronic device in accordance with an exemplary embodiment. 
           [0008]      FIG. 2  is a functional block diagram of the system of  FIG. 1 . 
           [0009]      FIG. 3  is a circuit diagram illustrating the connection of a series of resistors and the electronic device of the system of  FIG. 1 . 
           [0010]      FIG. 4  shows an operation to change the resistance value obtained by a resistance value obtaining module of the system of  FIG. 1 . 
           [0011]      FIG. 5  is flowchart illustrating a method for locking an electronic device of the  FIG. 1 . 
           [0012]      FIG. 6  is a flowchart illustrating a method for unlocking an electronic device of  FIG. 1 . 
       
    
    
     DETAILED DESCRIPTION 
       [0013]    Referring to  FIGS. 1 and 2 , a system  100  for locking an electronic device (hereinafter: system  100 ) includes the electronic device  10  and an electronic key  20 . 
         [0014]    The electronic key  20  includes a resistive circuit  210 . As shown in  FIG. 1 , in the embodiment, the circuit  210  includes six resistors R 1 , R 2 , R 3 , R 4 , R 5 , and R 6 . However, it should be noted that the number of the resistors in the resistive circuit  210  is not limited to as in this embodiment, and can be any number greater than 1, as needed. The resistors R 1 ˜R 6  can have the same resistance value or different resistance values. 
         [0015]    The electronic device  10  includes a connection port  16 , which is configured to connect to the electronic key  20 . The electronic device  10  also includes a function key  11 , which is used for producing a locking or an unlocking command in response to user operations, the function key  11  could be configured at any suitable place of the electronic device  10 , for example, a left side or a right side of the electronic device  10 . 
         [0016]    Referring also to  FIG. 2 , the electronic device  10  includes the function key  11 , a storage unit  12 , a processing unit  13 , a power management unit  14 , a power source and the connection port  16 . The processing unit  13  is connected to the function key  11 , the storage unit  12 , and the power management unit  14 . 
         [0017]    The processing unit  13  includes a resistance value obtaining module  131 , an locking module  132 , and a unlocking module  133 . The resistance value obtaining module  131  is used for obtaining the resistance value of the electronic key  20 . The locking module  132  is used for encoding the resistance value of the electronic key  20  to produce an encryption key for the electronic device  10  and storing the encryption key in the storage unit  12  when the function key  11  produces a locking command. In other embodiments, the locking module  132  also prompts the user to input the resistance value again, ensuring the user has set the correct and desired resistance value. The unlocking module  132  is used for unlocking the electronic device  10 . In detail, the unlocking module  132  decodes the encryption key stored in the storage unit  12  and compares the decoded encryption key with the resistance value obtained by the resistance value obtaining module  131 . The electronic device  10  is unlocked when the resistance value obtained by the resistance value obtaining module  131  matches the decoded encryption key. 
         [0018]    Referring to  FIG. 3 , in the embodiment, the connection port  16  includes two terminals  161 ,  162 , and two ends  211 ,  212  of the electronic key  20  these are electronically connected to the power source  15  of the electronic device  10  to the connection port  16  thus forming a circuit. Furthermore, a switch S 1  is connected between the power source  15  and the terminal  162  of the connection port  16 , an ammeter A is connected between the power source  15  and the terminal  161  of the connection port  16 , and a voltmeter V and the electronic key  20  are connected in parallel between the two terminals  161 ,  162  of connection port  16 . The switch S 1  is connected to the power management unit  14 , the processing unit  13  controls the power management unit  14  to switch on switch S 1  when receiving the locking command from the function key  11 , then the electronic key  20  is activated and the power source  15  provides power to the electronic key  20 . 
         [0019]    The ammeter A obtains the current I of the electronic key  20  and the voltmeter V obtains the voltage U of the electronic key  20 . The resistance value obtaining module  131  calculates the resistance value of the electronic key  20  using the formula: R=U/I. In the embodiment, the locking module  132  of the processing unit  13  is also used for controlling the power management unit  14  to switch off the switch S 1  after locking the electronic device  10 , the electronic key  20  is then deactivated. 
         [0020]    In the embodiment, each resistor of the electronic key  20  is exposed (namely, the resistors R 1 ˜R 6  are not wrapped by insulated material, for example, each resistor can be a block of metal, such as iron or cuprum, and have no insulated material case), and is connected in series via a conductive line, which is wrapped by insulated material. When different resistors of the electronic key  20  are coupled, the coupled resistors are combined as one resistor, and the resistance value of the electronic key  20  obtained by the resistance value obtaining module  131  is changed accordingly. For example, as shown in  FIG. 4 , if the user couples the resistor R 2  and R 5  by his/her fingers, the resistor R 2  is contacted to resistor R 5  and they are combined as one resistor and cause a short circuit in resistor R 3  and R 4 , and the resistor R 1 , R 2 , R 5 , R 6  and the power source  15  forms a circuit. When the power source  15  provides power to the electronic key  20 , the current only pass through the resistor R 1 , R 2 , R 5 , and R 6 , then the resistance value obtained by the resistance value obtaining module  131  is changed to R 1  plus R 2  plus R 5  and plus R 6 . Therefore, the user can change the resistance value obtained by the resistance value obtaining module  131  by coupling different resistors of the electronic key  20 , and thus producing a different encryption key for the electronic device  10 . The unlocking module  133  of the processing unit  13  is also used for controlling the power management unit  14  to switch off the switch S 1  after unlocking the electronic device  10 , and then the electronic key  20  is deactivated. 
         [0021]      FIG. 5  is flowchart illustrating a method for locking an electronic device, for instance, the electronic device  10 . In step S 401 , the function key  11  produces a locking command in response to user operation. 
         [0022]    In step S 402 , the locking module  132  of the processing unit  13  activates the electronic key  20  when receiving the locking command, namely, the processing unit  13  received the command and controls the power management unit  14  to switch on the switch S 1 . 
         [0023]    In step S 403 , the resistance value obtaining module  131  obtains the resistance value of the electronic key  20 . 
         [0024]    In step S 404 , the locking module  132  produces an encryption key by encoding the resistance value obtained by the resistance value obtaining module  131  and locks the electronic device  10 . In other embodiments, the locking module  132  also prompts the user to input the value again; to ensure the user has set the correct and desired resistance value. 
         [0025]    In step S 405 , the locking module  132  of the processing unit  13  deactivates the electronic key  20  after locking the electronic device  10 . The locking module  132  controls the power management unit  14  to switch off the switch S 1  after locking the electronic device  10  successfully. 
         [0026]      FIG. 6  is a flowchart illustrating a method for unlocking an electronic device, for instance, the electronic device  10 . In step S 501 , the function key  11  produces unlocking command in response to user operation. 
         [0027]    In step S 502 , the unlocking module  133  of the processing unit  13  activates the electronic key  20  when receiving the unlocking command, namely the unlocking module  133  of the processing unit  13  controls the power management unit  14  to switch on the switch S 1 . 
         [0028]    In step S 503 , the resistance value obtaining module  131  obtains the resistance value of the electronic key  20  and transmits the obtained resistance value to the unlocking module  133 . 
         [0029]    In step S 504 , the unlocking module  133  decodes the encryption key stored in the storage unit  12 . 
         [0030]    In step S 505 , the unlocking module  133  compares the obtained value with the decoded encryption key and determines whether the obtained resistance value matches the decoded encryption key. 
         [0031]    If the obtained resistance value doesn&#39;t matches the decoded encryption key, the process goes to step S 507 , else, in step S 506 , the unlocking module  133  unlocks the electronic device  10 . 
         [0032]    In step S 507 , the unlocking module  133  of the processing unit  13  deactivates switch S 1  after unlocking the electronic device  10 . 
         [0033]    It is believed that the present embodiments and their advantages will be understood from the foregoing description, and it will be apparent that various changes may be made thereto without departing from the spirit and scope of the disclosure or sacrificing all of its material advantages, the examples hereinbefore described merely being preferred or exemplary embodiments of the present disclosure.