Shop OBEX P1 Docs P2 Docs Learn Events
Fustrated Beginner — Parallax Forums

Fustrated Beginner

ArchiverArchiver Posts: 46,084
edited 2000-10-19 12:40 in General Discussion
Hello All,<br><br>While I'm sending this message, I am searching through the
archives for an answer that is probably<br>obvious to most of you.<br><br>I am
fairly new to electronics and stamping.<br><br>Here is the question<br><br>All I
am trying to do is drive a relay with my BSII. I've tried many ways but all
have failed.<br><br>Currently, I must not very good with shematics b/c I have
looked at some but it still does not work. The<br>relay is a simple SPDT rely I
picked up from RadioShack that turns on/off at 5V. I tried using two
stamp<br>pins, one low and one high. I tried using a NPN and a PNP transistor
connected to a stamp pin but nothing<br>seems to turn that coil on. If I take a
6v battery and connect it directly to the coil, it works. By the way<br>most of
my transistors seem to blow up.<br><br>Can anyone give help in laymens terms as
to how to go about connecting the wires. Right now I'm<br>using the BSII with
it's carrier board from the kit and and an addit!
ional breadboard.<br><br>Sorry for such a simple question.<br>Any help is
greatly appreciated. :-)<br><br>

Visit http://www.ChurchItinerary.com today!!

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2000-10-18 18:44
    Read http://www.al-williams.com/wd5gnr/stampfaq.htm#s2.5

    and http://www.al-williams.com/wd5gnr/stampfaq.htm#s2.29

    The idea is to connect the base of a 2N2222 (or similar) transistor to the
    Stamp via a resistor (say 1K or so). The emitter goes to ground and the
    collector goes to one end of the relay coil. The other end goes to +V.
    Here's the tricky part. Take a diode (1N914, 1N4148, even an 1N4001) and put
    the banded end to the +V end of the coil and the non-banded end to the other
    end of the coil (the collector end).

    When you set the Stamp pin high, the transistor will go into saturation. The
    Vce will be about .2V or so and the relay should snap on. When the pin goes
    low, the transistor falls out of saturation, Vce climbs to about 5V and the
    coil is off. Without the diode, the switching time of the transistor can
    create a huge voltage in the coil (inductors generate voltage in proportion
    to time variations in voltage -- that's why they resist AC but not DC).
    That's what is blowing your transistor.

    You can also use a MOSFET, but the old transistor circuit is a well-known
    design.

    Regards,

    Al Williams
    AWC
    *Expand your Stamp I/O: http://www.al-williams.com/awce/pak3.htm


    >
    Original Message
    > From: ContactMe@S... [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=vQflInjM8XjKJO4cRPV07C85e2IjL4Y4Ruh7dBtAyhspVr8VHdfbrmHrAeAk3i7Nh3Yw3p06oTAvppaNqPbIdL7Bw18]ContactMe@S...[/url
    > Sent: Wednesday, October 18, 2000 12:05 PM
    > To: basicstamps@egroups.com
    > Subject: [noparse][[/noparse]basicstamps] Fustrated Beginner
    >
    >
    >
    > Hello All,<br><br>While I'm sending this message, I am searching
    > through the archives for an answer that is probably<br>obvious to
    > most of you.<br><br>I am fairly new to electronics and
    > stamping.<br><br>Here is the question<br><br>All I am trying to
    > do is drive a relay with my BSII. I've tried many ways but all
    > have failed.<br><br>Currently, I must not very good with
    > shematics b/c I have looked at some but it still does not work.
    > The<br>relay is a simple SPDT rely I picked up from RadioShack
    > that turns on/off at 5V. I tried using two stamp<br>pins, one
    > low and one high. I tried using a NPN and a PNP transistor
    > connected to a stamp pin but nothing<br>seems to turn that coil
    > on. If I take a 6v battery and connect it directly to the coil,
    > it works. By the way<br>most of my transistors seem to blow
    > up.<br><br>Can anyone give help in laymens terms as to how to go
    > about connecting the wires. Right now I'm<br>using the BSII with
    > it's carrier board from the kit and and an addit!
    > ional breadboard.<br><br>Sorry for such a simple question.<br>Any
    > help is greatly appreciated. :-)<br><br>
    >
    >
    >
    > Visit http://www.ChurchItinerary.com today!!
    >
    >
  • ArchiverArchiver Posts: 46,084
    edited 2000-10-18 19:03
    Here's a schematic for connecting relays & drive
    transistors to the Basic Stamp.
    http://www.rentron.com/pc-relay.htm

    As Al Williams stated in his reply, without the flyback
    diode to protect the drive transistor, that nasty spike
    will blow up your transistors when you de-energize
    the relay coil.

    The schematic on the above page should help.

    Regards,

    Bruce Reynolds
    webmaster@r...
    http://www.rentron.com

    Original Message
    From: <ContactMe@S...>
    To: <basicstamps@egroups.com>
    Sent: Wednesday, October 18, 2000 11:05 AM
    Subject: [noparse][[/noparse]basicstamps] Fustrated Beginner


    |
    | Hello All,<br><br>While I'm sending this message, I am searching through the
    archives for an answer that is probably<br>obvious to most of you.<br><br>I am
    fairly
    new to electronics and stamping.<br><br>Here is the question<br><br>All I am
    trying
    to do is drive a relay with my BSII. I've tried many ways but all have
    failed.<br><br>Currently, I must not very good with shematics b/c I have looked
    at
    some but it still does not work. The<br>relay is a simple SPDT rely I picked up
    from
    RadioShack that turns on/off at 5V. I tried using two stamp<br>pins, one low
    and one
    high. I tried using a NPN and a PNP transistor connected to a stamp pin but
    nothing<br>seems to turn that coil on. If I take a 6v battery and connect it
    directly to the coil, it works. By the way<br>most of my transistors seem to
    blow
    up.<br><br>Can anyone give help in laymens terms as to how to go about
    connecting the
    wires. Right now I'm<br>using the BSII with it's carrier board from the kit and
    and
    an addit!
    | ional breadboard.<br><br>Sorry for such a simple question.<br>Any help is
    greatly
    appreciated. :-)<br><br>
    |
    |
    | Visit http://www.ChurchItinerary.com today!!
    |
    |
    |
    |
  • ArchiverArchiver Posts: 46,084
    edited 2000-10-18 20:37
    The best way is to use a ULN2803A, driving directly load or trough relay

    Datasheet should be available on the net or I think others on group will
    answer about this
  • ArchiverArchiver Posts: 46,084
    edited 2000-10-19 12:40

    Original Message
    From: <ContactMe@S...>
    To: <basicstamps@egroups.com>
    Sent: Wednesday, October 18, 2000 1:05 PM
    Subject: [noparse][[/noparse]basicstamps] Fustrated Beginner


    >
    > Hello All,<br><br>While I'm sending this message, I am searching through
    the archives for an answer that is probably<br>obvious to most of
    you.<br><br>I am fairly new to electronics and stamping.<br><br>Here is the
    question<br><br>All I am trying to do is drive a relay with my BSII. I've
    tried many ways but all have failed.<br><br>Currently, I must not very good
    with shematics b/c I have looked at some but it still does not work.
    The<br>relay is a simple SPDT rely I picked up from RadioShack that turns
    on/off at 5V. I tried using two stamp<br>pins, one low and one high. I
    tried using a NPN and a PNP transistor connected to a stamp pin but
    nothing<br>seems to turn that coil on. If I take a 6v battery and connect
    it directly to the coil, it works. By the way<br>most of my transistors
    seem to blow up.<br><br>Can anyone give help in laymens terms as to how to
    go about connecting the wires. Right now I'm<br>using the BSII with it's
    carrier board from the kit and and an addit!
    > ional breadboard.<br><br>Sorry for such a simple question.<br>Any help is
    greatly appreciated. :-)<br><br>
    >
    -
    >
    > Visit http://www.ChurchItinerary.com today!!
    >
    > YOU NEED TO TAKE THE SIGNAL FROM THE STAMP TO A DARLINGTON SWITCHING
    TRANSISTOR. SEE SCOTT EDWARDS ARTICLE IN NUTS N VOLTS 'STAMP APPLICATION NO.
    6'
    THIS WORKS REALLY WELL.
    KEITH MOORE.
    >
    >

    _______________________________________________
    Why pay for something you could get for free?
    NetZero provides FREE Internet Access and Email
    http://www.netzero.net/download/index.html
Sign In or Register to comment.