Abstract:
A device for producing a magnetic field and adjusting the magnetic field&#39;s intensity includes a power source, a wire winding, a path switching module, a path control module, a first adjusting module, and a second adjusting module. The path switching module is electrically connected between the power source and the wire winding. The path control module controls the wire winding and the power source to form a first loop to produce a first magnetic field or a second loop to produce a second magnetic field by controlling the path switching module. The first adjusting module is located in the first loop and adjusts the intensity of the first magnetic field by adjusting current flowing through the first loop. The second adjusting module is located in the second loop and adjusts the intensity of the second magnetic field by adjusting current flowing through the second loop.

Description:
BACKGROUND 
       [0001]    1. Technical Field 
         [0002]    The present disclosure relates to devices for producing a magnetic field and, particularly, to a device for producing a magnetic field and adjusting the intensity of the magnetic field produced by it. 
         [0003]    2. Description of Related Art 
         [0004]    Nowadays, more and more electronic devices, such as mobile phones, are equipped with an electronic compass to provide a navigation function. In order to guarantee the quality of the electronic compass, a related test is needed before manufacturing is completed. An electronic compass can execute navigation functions by detecting the magnetic field of the earth, therefore, it is needed to provide a magnetic field to test the electronic compass. The usual method is to use a magnet to produce the magnetic field, however, the intensity of the magnetic field produced by the magnet cannot be changed easily, therefore some functions such as the sensitivity of the electronic compass cannot be tested. 
         [0005]    Therefore, it is desirable to provide a device that produces a magnetic field and adjusts the magnetic field&#39;s intensity to overcome the above-mentioned limitations. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0006]    Many aspects of the present disclosure should be better understood with reference to the following drawings. The components in the drawings are not necessarily drawn to scale, the emphasis instead being placed upon clearly illustrating the principles of the present disclosure. Moreover, in the drawings, like reference numerals designate corresponding parts throughout the several views. 
           [0007]      FIG. 1  is a block diagram of a device for producing and adjusting magnetic field, in accordance with an exemplary embodiment. 
           [0008]      FIG. 2  is a circuit diagram of the device of  FIG. 1 , in accordance with an exemplary embodiment. 
       
    
    
     DETAILED DESCRIPTION 
       [0009]    Embodiments of the present disclosure will now be described in detail below, with reference to the accompanying drawings. 
         [0010]    Referring to  FIG. 1 , a device  1  that produces a magnetic field and adjusts the intensity of the magnetic filed is provided in accordance with an exemplary embodiment. The device  1  includes a path control module  10 , a path switching module  20 , a wire winding  30 , and a power source  40 . 
         [0011]    The path switching module  20  is electrically connected between the wire winding  30  and the power source  40 . The path control module  10  controls the path switching module  20  to switch the connection between the power source  40  and the wire winding  30  to cause the wire winding  30  and the power source  40  to form a first loop or a second loop. In the embodiment, when the first loop is formed, the wire winding  30  produces a first magnetic field, when the second loop is formed, the wire winding  30  produces a second magnetic field. The wire winding  30  includes a first terminal  301  and a second terminal  302 . When the wire winding  30  and the power source  40  form the first loop, the first terminal  301  and the second terminal  302  are respectively connected to an anode  401  and a cathode  402  of the power source  40 . The current flows through the wire winding  30  from the first terminal  301  to the second terminal  302 , then the wire winding  30  produces the first magnetic field. When the wire winding  30  and the power source  40  form the second loop, the first terminal  301  and the second terminal  302  are respectively connected to the cathode  402  and the anode  401  of the power source  40 . The current flows through the wire winding  30  from the second terminal  302  to the first terminal  301 , then the wire winding  30  produces the second magnetic field. 
         [0012]    The device  1  further includes a first adjusting module  50  and a second adjusting module  60 . The first adjusting module  50  is electrically connected between the path switching module  20  and the cathode  402  of the power source  40 , the second adjusting module  60  is electrically connected between the path switching module  20  and the anode  401  of the power source  40 . When the wire winding  30  and the power source  40  form the first loop, the first adjusting module  50  is located in the first loop and adjusts the current flowing through the first loop thereby adjusting the intensity of the first magnetic field. When the wire winding  30  and the power source  40  form the second loop, the first adjusting module  50  is located in the second loop and adjusts the current flowing through the second loop thereby adjusting the intensity of the second magnetic field. 
         [0013]    The device  1  further includes a path switch  70  for turning on or off the device  1 . The path switch  70  is electrically connected between the second adjusting module  60  and the anode  401  of the power source  40 . In other embodiment, the path switch  70  can be disposed between the first adjusting module  50  and the cathode  402  of the power source  40 , or any suitable place. 
         [0014]    Referring to  FIG. 2 , in the embodiment, the path control module  10  includes an input port  101 , a photo-coupler  102 , and a control winding  103 . The photo-coupler  102  includes a first input terminal  1021 , a second input terminal  1022 , a first output terminal  1023 , and a second output terminal  1024 . The first input terminal  1021  is connected to the input port  101  via a resistor R 1 , and is also connected to a potential point Vcc via a resistor R 2 . The second input terminal  1022  is connected to the input port  101 . The first output terminal  1023  is connected to the potential point Vcc via a resistor R 3 . The second output terminal  1024  is connected to a base of a negative-positive-negative (NPN) bipolar junction transistor (BJT) Q 1 . The control winding  103  is connected between the potential point Vcc and a collector of the NPN BJT Q 1 . An emitter of the NPN BJT Q 1  is grounded. In other embodiments, the NPN BJT Q 1  can instead be an n-channel metal-oxide-semiconductor field-effect transistor. 
         [0015]    In one embodiment, the path control module  10  further includes a diode D 1 . The diode D 1  and the control winding  103  are connected between the potential point Vcc and the collector of the NPN BJT Q 1  in parallel. In one embodiment, the potential point Vcc is connected to the anode of the power source  40  and at high voltage. 
         [0016]    In one embodiment, the path switching module  20  is a double-pole double-throw (DPDT) switch K, which combines with the control winding  103  to form a relay. In the embodiment, the relay is a direct current electromagnetic relay. 
         [0017]    The DPDT switch K includes two normally closed points T 1  and T 4 , two stationary contact points T 2  and T 5 , and two normally open points T 3  and T 6 . The two stationary contact points T 2  and T 5  are respectively connected to the first terminal  301  and the second terminal  302  of the wire winding  30 . The normally open point T 3  is electrically connected to the anode  401  of the power source  40  by the path switch  70 , and the normally open point T 6  is connected to the cathode  402  of the power source  40  by the first adjusting module  50 . The normally closed point T 1  is connected to the cathode  402  of the power source  40 , and the normally closed point T 4  is electrically connected to the anode of the power source  40  by the second adjusting module  60  and the path switch  70 . In one embodiment, when the current flows through the control winding  103 , the two stationary contact points T 2  and T 5  are respectively connected to the two normally open points T 3  and T 6 . When no current flows through the control winding  103 , the two stationary contact points T 2  and T 5  are respectively connected to the two normally closed points T 1  and T 4 . 
         [0018]    In the circuit, the first adjusting module  50  and the second adjusting module  60  respectively are a rheostat R 4  and a rheostat R 5 . The path switch  70  can be a switch, which a user can operate, such as a push button switch or a toggle switch. 
         [0019]    When the input port  101  of the path control module  10  is at low voltage, the first input terminal  1021  of the photo-coupler  102  is at high voltage, and the second input terminal  1022  of the photo-coupler  102 , which is electrically connected to the input port  101  is at low voltage. Then the photo-coupler  102  is turned on when there is a voltage between the first input terminal  1021  and the second input terminal  1022 , the base of the NPN BJT Q 1  is electrically connected to the potential point Vcc by the photo-coupler  102 , which is turned on and at high voltage, the NPN BJT Q 1  is turned on accordingly. Then the current flows through the control winding  103 , and thus, the two stationary contact points T 2  and T 5  of the DPDT switch K are respectively connected to the two normally open points T 3  and T 6  of the DPDT switch K. 
         [0020]    Therefore, the first terminal  301  of the wire winding  30  is connected to the anode of the power source  40  via the path switch  70 , the second terminal  302  of the winding  30  is connected to the cathode of the power source  40  via the first adjusting module  50 . The current flows through the wire winding  30  from the first terminal  301  to the second terminal  302 , accordingly, the wire winding  30  produces the first magnetic field. When the resistance value of the first adjusting module  50  is adjusted, the current value flowing through the wire winding  30  is changed, and the intensity of the first magnetic field is changed accordingly. 
         [0021]    When the input port  101  of the path control module  10  is at high voltage, the first input terminal  1021  and the second input terminal  1022  of the photo-coupler  102  are both at high voltage, then the photo-coupler  102  is turned off. The electrical connection between the potential point Vcc and the base of the NPN BJT Q 1  is disconnected, and the NPN BJT Q 1  is turned off accordingly. Then no current flows through the control winding  103 , and thus, the two stationary contact points T 2  and T 5  are respectively connected to the two normally closed points T 1  and T 4 . 
         [0022]    Therefore, the first terminal  301  of the wire winding  30  is connected to the cathode of the power source  40 , the second terminal  302  of the wire winding  30  is connected to the anode of the power source  40  via the second adjusting module  60  and the path switch  70 . The current flows through the wire winding  30  from the second terminal  302  to the first terminal  301 , accordingly, the wire winding  30  produces the second magnetic field. When the resistance value of the second adjusting module  60  has been adjusted, the current value flowing through the wire winding  30  changes, and the intensity of the second magnetic field changes accordingly. 
         [0023]    In the embodiment, the input port  101  of the path control module  10  is further connected to the potential point Vcc via a switch K 2  and a resistor R 6 , and is further connected to ground via a resistor R 7 . The switch K 2  also can be a switch, which a user can operate, such as a push button switch or a toggle switch. When the switch K 2  is turned on, the input port  101  of the path control module  10  is connected to the potential point Vcc, and then the input port  101  is at high voltage. When the switch K 2  is turned off, the resistor R 7  grounds input port  101  of the path control module  10 , and then the input port  101  is at low voltage. 
         [0024]    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 exemplary embodiments of the present disclosure.