Shop OBEX P1 Docs P2 Docs Learn Events
Problems with transistor driving relay — Parallax Forums

Problems with transistor driving relay

ArchiverArchiver Posts: 46,084
edited 2000-09-07 11:33 in General Discussion
I know this has been covered many many times before, and I've had it
working many times before but this times I'm stumped.

First of all this isn't a stamp project I'm driving a relay from a
555 timer through a transistor. The how thing is running at 12V dc.
The output of the 555 is through a 4.7K resistor to the base of the
transistor. The emitter is to ground. The coil has a 1n4148 diode
across it with the band to the +12V and the other side to the
collector. The coil takes something like 30mA I think.

When the 555 goes high the relay closes just fine, but when the 555
goes low the relay stays closed.

I have gotten it to work by changing the transistor. It works if I
use a BC547 but not with a 2n2222, 2n4401 or 2n3904.

What's going on here, is something setup wrong or is it the 12V
supply. The fact that it works OK with one and not the others is
cool, at least it works, but the specs for the transistors are
somewhat close. I wouldn't think it would be that critical in this
application.

Thanks for all your help.
Mike

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2000-09-06 21:14
    Mike,

    I would guess that your 555 is damaged, because the circuit should work as
    described at any reasonable supply voltage. Check the 555 output (pin 3)
    voltage when it's low. It should be less than 0.25V.

    By the way, you could easily drive a 30mA relay directly from the output
    pin of a standard 555-- there's no obvious reason (to me, anyway!) to use
    the coil drive transistor in this case...

    >I know this has been covered many many times before, and I've had it
    >working many times before but this times I'm stumped.
    >
    >First of all this isn't a stamp project I'm driving a relay from a
    >555 timer through a transistor. The how thing is running at 12V dc.
    >The output of the 555 is through a 4.7K resistor to the base of the
    >transistor. The emitter is to ground. The coil has a 1n4148 diode
    >across it with the band to the +12V and the other side to the
    >collector. The coil takes something like 30mA I think.
    >
    >When the 555 goes high the relay closes just fine, but when the 555
    >goes low the relay stays closed.
    >
    >I have gotten it to work by changing the transistor. It works if I
    >use a BC547 but not with a 2n2222, 2n4401 or 2n3904.
    >
    >What's going on here, is something setup wrong or is it the 12V
    >supply. The fact that it works OK with one and not the others is
    >cool, at least it works, but the specs for the transistors are
    >somewhat close. I wouldn't think it would be that critical in this
    >application.

    Mike Hardwick, for Decade Engineering -- <http://www.decadenet.com>
    Manufacturer of the famous BOB-II Serial Video Text Display Module!
  • ArchiverArchiver Posts: 46,084
    edited 2000-09-06 23:02
    Hi Mike,

    I've got a mini-notebook from Radio Shack, which says that the maximum
    output current of a 555 is 200 mA. So I think you can drive the relay
    directly.
    If you want to use a transistor, you may try to put a 1K resistor between
    pin 3 and ground.
    Hope this helps...
    Best regards,
    Phil.

    Original Message
    From: Mike Davey <mdavey@v...>
    To: <basicstamps@egroups.com>
    Sent: Wednesday, September 06, 2000 6:41 PM
    Subject: [noparse][[/noparse]basicstamps] Problems with transistor driving relay


    > I know this has been covered many many times before, and I've had it
    > working many times before but this times I'm stumped.
    >
    > First of all this isn't a stamp project I'm driving a relay from a
    > 555 timer through a transistor. The how thing is running at 12V dc.
    > The output of the 555 is through a 4.7K resistor to the base of the
    > transistor. The emitter is to ground. The coil has a 1n4148 diode
    > across it with the band to the +12V and the other side to the
    > collector. The coil takes something like 30mA I think.
    >
    > When the 555 goes high the relay closes just fine, but when the 555
    > goes low the relay stays closed.
    >
    > I have gotten it to work by changing the transistor. It works if I
    > use a BC547 but not with a 2n2222, 2n4401 or 2n3904.
    >
    > What's going on here, is something setup wrong or is it the 12V
    > supply. The fact that it works OK with one and not the others is
    > cool, at least it works, but the specs for the transistors are
    > somewhat close. I wouldn't think it would be that critical in this
    > application.
    >
    > Thanks for all your help.
    > Mike
    >
    >
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2000-09-06 23:09
    The 555 should be fine pushing a 30mA relay, I'd keep the diode across the
    Relay though! [noparse]:o[/noparse])


    >Hi Mike,
    >
    >I've got a mini-notebook from Radio Shack, which says that the maximum
    >output current of a 555 is 200 mA. So I think you can drive the relay
    >directly.
    >If you want to use a transistor, you may try to put a 1K resistor between
    >pin 3 and ground.
    >Hope this helps...
    >Best regards,
    >Phil.
    >
    >
    Original Message
    >From: Mike Davey <mdavey@v...>
    >To: <basicstamps@egroups.com>
    >Sent: Wednesday, September 06, 2000 6:41 PM
    >Subject: [noparse][[/noparse]basicstamps] Problems with transistor driving relay
    >
    >
    > > I know this has been covered many many times before, and I've had it
    > > working many times before but this times I'm stumped.
    > >
    > > First of all this isn't a stamp project I'm driving a relay from a
    > > 555 timer through a transistor. The how thing is running at 12V dc.
    > > The output of the 555 is through a 4.7K resistor to the base of the
    > > transistor. The emitter is to ground. The coil has a 1n4148 diode
    > > across it with the band to the +12V and the other side to the
    > > collector. The coil takes something like 30mA I think.
    > >
    > > When the 555 goes high the relay closes just fine, but when the 555
    > > goes low the relay stays closed.
    > >
    > > I have gotten it to work by changing the transistor. It works if I
    > > use a BC547 but not with a 2n2222, 2n4401 or 2n3904.
    > >
    > > What's going on here, is something setup wrong or is it the 12V
    > > supply. The fact that it works OK with one and not the others is
    > > cool, at least it works, but the specs for the transistors are
    > > somewhat close. I wouldn't think it would be that critical in this
    > > application.
    > >
    > > Thanks for all your help.
    > > Mike
    > >
    > >
    > >
    > >

    Beau Schwabe Mask Designer
    National Semiconductor Network Products Division
    500 Pinnacle Court, Suite 525 Mail Stop GA1 Norcross, GA 30071
  • ArchiverArchiver Posts: 46,084
    edited 2000-09-06 23:55
    Mike:

    I use a 2N2222 or 2N2222A all the time to do exactly what you are doing.
    However, I use a 1K resistor to the base not a 4.7K. I don't know if this
    would cause your problem or not but it might have some effect on it.
    Otherwise you description of the circuit sounds correct. Personally, I NEVER
    connect the output of any IC directly to the device that I am driving unless
    the IC is a driver such as a ULN2004 etc. It may be a personal thing but
    that was the way I was taught to do it.

    Hope this may help,

    Randy A.
  • ArchiverArchiver Posts: 46,084
    edited 2000-09-07 02:48
    > The output of the 555 is through a 4.7K resistor
    > to the base of the transistor. The emitter is to ground.
    >...
    > When the 555 goes high the relay closes just fine,
    > but when the 555 goes low the relay stays closed.
    > I have gotten it to work by changing the transistor.
    > It works if I use a BC547 but not with a 2n2222,
    > 2n4401 or 2n3904.

    Mike,
    One thing I would try in a situation like that is an additional resistor
    (say 4.7k) from the base of the transistor to ground. It may be that the
    output of the 555 is not going all the way to ground, so there is a
    residual base current flowing into your switching transistor, so it never
    turns completely off. The additional resistor provides a more solid ground
    path. You will notice that almost all professional circuits include that
    additional resistor from the base to ground. The problem can also be
    attacked by using a darlington transistor or a mosfet, either of which have
    a higher input threshold. Or a low-gain transistor, which would really be
    hit or miss. But it is always a good idea to include the extra resistor
    from base (or gate) to ground. Just a thought.

    -- Tracy
  • ArchiverArchiver Posts: 46,084
    edited 2000-09-07 11:33
    add another resistor from the base lead to ground, this helps to shut off
    the transistor when its drive becomes low enough, 2.2k should be enough.
    norm



    >From: Mike Davey <mdavey@v...>
    >Reply-To: basicstamps@egroups.com
    >To: basicstamps@egroups.com
    >Subject: [noparse][[/noparse]basicstamps] Problems with transistor driving relay
    >Date: Wed, 6 Sep 2000 11:41:15 -0500
    >
    >I know this has been covered many many times before, and I've had it
    >working many times before but this times I'm stumped.
    >
    >First of all this isn't a stamp project I'm driving a relay from a
    >555 timer through a transistor. The how thing is running at 12V dc.
    >The output of the 555 is through a 4.7K resistor to the base of the
    >transistor. The emitter is to ground. The coil has a 1n4148 diode
    >across it with the band to the +12V and the other side to the
    >collector. The coil takes something like 30mA I think.
    >
    >When the 555 goes high the relay closes just fine, but when the 555
    >goes low the relay stays closed.
    >
    >I have gotten it to work by changing the transistor. It works if I
    >use a BC547 but not with a 2n2222, 2n4401 or 2n3904.
    >
    >What's going on here, is something setup wrong or is it the 12V
    >supply. The fact that it works OK with one and not the others is
    >cool, at least it works, but the specs for the transistors are
    >somewhat close. I wouldn't think it would be that critical in this
    >application.
    >
    >Thanks for all your help.
    >Mike
    >
    >
    >

    _________________________________________________________________________
    Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

    Share information about yourself, create your own public profile at
    http://profiles.msn.com.
Sign In or Register to comment.