Electromagnet & PNP Transistor

Discussion in 'The Projects Forum' started by calvokv, Feb 4, 2016.

  1. calvokv

    Thread Starter New Member

    Feb 4, 2016
    3
    0
    I am new to the webpage and to electronics so please bear with me if my question seems too basic. I bought an electromagnetic lock for my fence. the data sheet for the lock says it works w 12V DC @ 110 mA and it comes with only a negative and a positive wire attached to the main body of the magnet. I have an electric gate (mighty mule 200) operated with a remote clicker; the circuit board of the gate has a Lock+ pin that allows the EM lock to be connected via a logic circuit which I tried to design.
    The gate will send 0 volts normally through the lock+ pin and when I activate the gate to open, it will send +13V for 1-2 seconds before going back to 0V.

    I decided to use a PNP 3906 transistor as depicted in the diagram to signal the lock when the gate is being activated. The 3906 acts as a normally closed switch allowing current from Emisor to Collector and keeping the lock activated. When the gate is opened, +13V go to the Base and transiently opens the circuit; the lock deactivates and the gate is allowed to swing open.

    The circuit seems to be working as expected in terms of the logic, but the force of the electromagnet is very weak when I hook it up. When I measure the current from A-B in the diagram, I get 50mA which I think is the reason why the magnet is not working at full capacity... Do you have any ideas on how to increase the current that goes to the magnet? from the spec sheet it can stand up to 110 mA.​
     
  2. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,386
    1,605
    R2 is much too large to drive the transistor! Drop it down to 1K or so.

    Also, the solenoid is a big inductor and will generate spikes that will destroy your transistor unless you protect it with a diode across C to E, Band at the E side. Just about any diode will do like a 1N4001.
     
  3. crutschow

    Expert

    Mar 14, 2008
    12,988
    3,226
    You do need protection for the transistor, but a standard diode across it won't help (the spike is negative going at the collector).
    The diode needs to be across the inductor load, cathode (band) to the top (point A) and anode at B.
     
    ErnieM likes this.
  4. Alec_t

    AAC Fanatic!

    Sep 17, 2013
    5,773
    1,103
    Are you sure the lock needs to be constantly energised to stay in the locked state? That wastes power and makes the lock vulnerable to power supply failure. I would have expected it to be energised only briefly to unlock.
     
  5. MaxHeadRoom

    Expert

    Jul 18, 2013
    10,509
    2,368
    If this is intended for a magnetic lock function, they are often latching solenoids, the pulse shifts the armature over to the magnet, the reverse pulse releases it.
    Max.
     
  6. calvokv

    Thread Starter New Member

    Feb 4, 2016
    3
    0
    Thanks to all of you who replied.
    The EM lock does require constant voltage to maintain it's magnetism. when voltage is off the magnet is off. I did reverse polarity and it still generates a magnetic force.
    I placed the 1N4001 Diode across the inductor load, cathode (band) to the top (point A) and anode at B as Crutschow recommended for protection.
    I also changed the 100K resistor to a 1K Resistor as ErnieM suggested but the current across AB was 250 mA so I ended up going for a 4.8K Resistor and my current flowing to the magnet is about 130 mA now.....
    I will transfer the project from the bench to the fence and see how it goes.
    Here is the updated version of the circuit.
     
  7. MaxHeadRoom

    Expert

    Jul 18, 2013
    10,509
    2,368
    If it is unipolar and the voltage is not maintained, what/how is it unlocked?
    If you have to reverse it you cannot use the BEMF diode.
    Max.
     
  8. calvokv

    Thread Starter New Member

    Feb 4, 2016
    3
    0
    To answer MaxHeadRoo's question, what I have is an electromagnet lock, which unlike an electric strike access control door lock, it has no interconnecting parts. It has an electromagnet and an armature plate. The magnet is attached to the door frame and the plate to the door. The current activates the magnet and holds the door in place by attracting the plate. The downside of this system is that it is possible to bypass the lock by disrupting the power supply. Since my purpose is to keep my dog from pushing the gate open, this is not an issue for me.
     
  9. AnalogKid

    Distinguished Member

    Aug 1, 2013
    4,516
    1,246
    We have those here where I work, basically the only way to secure a very nice looking all glass door. But about your circuit... If changing the base resistor changes the current through the magnet, then the transistor is not saturated and will burn up. At 100 mA, each volt across the 3906 is 100 mW of power dissipated inside the transistor, and a TO-92 package is good for less than 200 mW at high temperatures. It would help to see the specs for the magnet. If it really needs a limited current, there are much better ways to do this.

    ak
     
Loading...