Shop OBEX P1 Docs P2 Docs Learn Events
BS1 12v problem — Parallax Forums

BS1 12v problem

Blackbird455Blackbird455 Posts: 124
edited 2007-08-08 19:52 in BASIC Stamp
I am trying to control a 12v load with my BS1 OEM, I have made several sucessfully controlling a 5v load, using a tip 31 transistor.
Base pin on the Tip31 going to the i/o on the stamp and it switches the 5v load fine. When I place 12v on the transistor, it feeds back all the way to the BS1, cooking one already, so I have a Z diode protecting the I/O now, but I still cant get the 12v to switch when the I/O tells it to. Help!!!!! Or else my cook is goosed, I have a deadline this week, and I am stumped on how to get a BS1 to switch 12vdc through a transistor. I have darlington transistors, and several other types.........The first person that gives me the solution to this problem that works, I will send a $20 check to !!!!!!·

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2007-08-08 00:11
    1) If your load is inductive (a motor, relay, or solenoid), you need a reverse connected diode across the load (cathode to +12V, anode to transistor collector - like a 1N4001).

    2) You should not be able to "toast" the BS1 if the transistor is connected properly and not defective. There should be a current limiting resistor in the base lead. If you didn't have this before, you might have overloaded the BS1 pin because of too much current, not the voltage. You need to limit the base current to 15-20ma. With a Darlington transistor, that's about 220 ohms. With a single power transistor, that's maybe 270 ohms.

    3) Download the Stamps in Class tutorials. Several of them discuss switching large loads with a Stamp. I don't have my copies handy, but have a look at their tables of content.
  • Blackbird455Blackbird455 Posts: 124
    edited 2007-08-08 00:17
    Thanks Mike,

    The load is LED's , does that help?
  • Mike GreenMike Green Posts: 23,101
    edited 2007-08-08 00:26
    You could use a smaller switching transistor like a 2N2222 and the base resistor could be higher (like 1K). You wouldn't need the reverse connected diode since the load is resistive.

    Is there some reason why you're running the LEDs off 12V? If you had a +5V supply, you could switch them directly with the BS1 since its I/O pins can handle the 15ma or so. You'd just need a 270 to 330 ohm resistor in series with the LED (for a 10-15ma LED current) and could connect the LED to ground or to +5V. The BS1 regulator is limited in how many LEDs it could handle ... figure 3-5. If you're running the BS1 off an external regulator, you could run up to 8 LEDs ... no problem.
  • Blackbird455Blackbird455 Posts: 124
    edited 2007-08-08 02:39
    I have run 72 leds off of a BS1 @ 30 ma each, using a tip31 transistor and a handfull of 7805 regulators......sucessfully.

    The reason that I am using 12v is because I am not running traditional LED's.... the ones I am driving operate @ 3.85v, 1500ma each, so in a series of three that means that I can run them @ 11.55v and still only 1500ma, or if I were to run them all paralell ,3.85v @ 4500ma, a real waste considering the power dissipation from 12v regulated to 5v, and then resisted to 3.85, ............so using the total number of bulbs, 9, times 1500ma would mean 13.5 amps, that much heat would melt the housings I am using. There is a simple answer to this........I guess I just need a few more Miller Lites, and a little less sleep, to get it right...........but any help is greatly appreciated
  • Blackbird455Blackbird455 Posts: 124
    edited 2007-08-08 02:43
    what about a MOSFET???? would that change things?
  • Mike GreenMike Green Posts: 23,101
    edited 2007-08-08 02:48
    An MOSFET would work as long as you get one designed for logic level switching (IRL510 for example). You would not need the series resistor.

    The TIP31 probably won't work with the high current LEDs. The current gain is only about 25 so you'd have a maximum output current of maybe 375-500ma with a 15-20ma drive. You're better off with a Darlington with its higher current gain or the MOSFET.

    Post Edited (Mike Green) : 8/8/2007 2:53:09 AM GMT
  • Blackbird455Blackbird455 Posts: 124
    edited 2007-08-08 04:14
    I cant get the darlington to respond (switch) like the tip31????? wtf?
  • Mike GreenMike Green Posts: 23,101
    edited 2007-08-08 13:20
    The BS1 can switch Darlington transistors just fine. There must be something about what you're doing. You'll have to give details about what you're trying.
  • Blackbird455Blackbird455 Posts: 124
    edited 2007-08-08 16:59
    Standard setup, base going to the I/O, C to the anode side of the led, E Vdd
  • Steve-0Steve-0 Posts: 5
    edited 2007-08-08 17:04
    would you have the option of using a small reed relay in place of the transistor or FET?
  • Blackbird455Blackbird455 Posts: 124
    edited 2007-08-08 17:16
    no reed relay , switching speed is too slow
  • Mike GreenMike Green Posts: 23,101
    edited 2007-08-08 17:19
    You still need a base resistor to limit the current out of the I/O pin to maybe 15ma, otherwise you can burn out the BS1 pin.
  • Blackbird455Blackbird455 Posts: 124
    edited 2007-08-08 17:52
    Mike,

    Please explain to me in detail how I can make the darlington and the mosfet switch off of an I/O . Am I doing something wrong? I have no trouble with the tip31, but no luck with the other two. Tell me how you would do it, or where I can find a schematic......this is kicking my butt

    Post Edited By Moderator (Chris Savage (Parallax)) : 8/8/2007 10:01:15 PM GMT
  • Mike GreenMike Green Posts: 23,101
    edited 2007-08-08 19:13
    Try downloading the Process Control tutorial text from the Stamps in Class section of Parallax's website. If I remember correctly, there's a whole section on switching high power loads using a Stamp. The EFX Prop-1 and Prop-2 are just a BS1 and BS2 respectively attached to a ULN2803 Darlington array (with some nice bells and whistles too). You can get schematics for those from EFX-TEK ... there's a link on the Parallax website.
  • Blackbird455Blackbird455 Posts: 124
    edited 2007-08-08 19:45
    Mike ,
    thank you so much for your help,

    I went back to some of my old schematics and changed the way I had Vdd and Vcc on the C and E pins (tip31) and it worked like it was supposed to..........told ya the lack of sleep and generous helpings of Miller Lite would do it. I feel like a dummy now. Such a simple thing cost me this much grief, guess I couldnt see the forrest for all of those green thingys in the way.

    Post Edited By Moderator (Chris Savage (Parallax)) : 8/8/2007 10:01:48 PM GMT
  • Mike GreenMike Green Posts: 23,101
    edited 2007-08-08 19:52
    Yeah. When in doubt, get someone else to check your wiring ... preferably someone who's better rested and less impaired.
Sign In or Register to comment.