Quick Question
If i want to run 3 Micro Relays Running at 5VDC and Nominal Current is 89.3Ma what do i need?
i have a NPN silicone transistor 2N4401
Rated at Ic: 600Ma
VCeo: 40V
VCbd: 60v
and 2 PNP Transistors 2N3906
CBV= 40V
CEV = 40V
EBV = 5V
it says its good for running currents from 10uA t 100 mA
will this work or do i need smthing different? Im still kinda confused on the difference between PNP NPN i kow that the properties make up for the way they transfer molecules and such but if anyone had a BetterDefintion ide Appreciate it. Thanks Guys....
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
-Learn somthing about everything, and Everthing about somthing-
i have a NPN silicone transistor 2N4401
Rated at Ic: 600Ma
VCeo: 40V
VCbd: 60v
and 2 PNP Transistors 2N3906
CBV= 40V
CEV = 40V
EBV = 5V
it says its good for running currents from 10uA t 100 mA
will this work or do i need smthing different? Im still kinda confused on the difference between PNP NPN i kow that the properties make up for the way they transfer molecules and such but if anyone had a BetterDefintion ide Appreciate it. Thanks Guys....
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
-Learn somthing about everything, and Everthing about somthing-
Comments
www.parallax.com/detail.asp?product_id=122-28176
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Martin Hebel
Southern Illinois University Carbondale - Electronic Systems Technologies
Personal Links with plenty of BASIC Stamp info
StampPlot - Graphical Data Acquisition and Control
http://www.parallax.com/detail.asp?product_id=122-28176
-Martin (again)
For NPN transistors, you connect the base (B) lead to a 1K resistor and the other end of the resistor gets connected to a Stamp pin. You connect the emitter (E) lead to ground. You connect the collector (C) lead to one end of the relay coil and the other end to a +5V supply with maybe 100ma of extra capacity. When the Stamp pin is HIGH, the relay will turn on. When the Stamp pin is LOW, the relay will be off. You can do the same thing with the other 2 relays. Your 5V power supply has to have about 300ma total extra capacity in case all 3 relays are on at the same time. You might want a diode (like a 1N4001) connected across the relay with its cathode (the bar symbol) attached to +5V end of the relay and its anode (the triangle symbol) attached to the transistor end of the relay. When the transistor turns off, the magnetic field in the relay generates a reverse current as it collapses and the diode dissipates it rather than having it destroy the transistor. With a small relay, this is not likely to be a problem, but, for large relays or coils or transformers, some kind of protection is needed.
here is one example:
http://www.allelectronics.com/cgi-bin/category.cgi
use that ic wired like that last paragraph above, except on this ic, you only hook up GND to one pin on the ic, very neat and clean hard to screw it up. the are older but still available, there are newer ones, like ULN2803 these will make your life simpler than sorting out what npn and pnp transistor you have on hand.
this type of relay driving circuit as Mike mentioned is called "sinking", whee you are supplying th GND to the motor, as the motor already is hardwired to the + " source" would be where you'd supply the + when motor is already hardwred to GND
an hbridge can supply both + and GND, as it switches between the two. think of an hbridge this way:
get a battery and a motor and two wires, plu the two wires onto the motor, and hold the other ends in your hand. then touch the two wires and make the motor tirn, now reverse your wires and make it run the other wau. that is what an hbridge does.
if you want to goodle up ULN2803 circuit for lots of reading
you can connect it directly to the Stamp with no resistors, and directly to the motor. so very few parts to deal with.
some good examples here:
http://www.southwest.com.au/~jfuller/sio5works.htm
http://www.circuitcellar.com/library/details/0999/c99cd5.asp
i thought the collector "collects" from the source nd when the base is turned it Emits out the emitter the higher voltage? or is tht PNP? i dunno ill read up on them and goto radio shacknad bu ya fe more NPN, one question i have... is there that much of a difference between the two? that much that i shouldnt use the PNP, and why dopeople normally in hbridges use two phpand two NPN?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
-Learn somthing about everything, and Everthing about somthing-
In digital use, we tend to 'saturate' the transistor -- that is, use it like a switch, either fully 'on' or fully 'off'. So, if the collector is sitting at 5 volts, and the base is at zero volts, and the emitter is at zero volts, there's no current flowing, the transistor is 'off'. If the base goes to 5 volts, and the collector stays at 5 volts, and you have a current limiting resistor in the base, then current will flow in the collector, and the transistor will be 'on'.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
-Learn somthing about everything, and Everthing about somthing-
Let's start with a P-N junction, like you find in a Diode. You start off with plain Silicon, which is electrially neutral. Then you 'dope' (add a chemical) one-half of the silicon with atoms that have an excess of electrons. This gets you an 'N' material. Then you 'dope' the other half of the silicon with atoms that have a deficit of electrons in their 'outer-shell'. This gets you a 'P' material. At the line between the halves, you have a "P-N Junction". With no voltage applied, the electrons a little way into the 'N' side will travel a little way into the 'P' side, making a 'voltage barrier' to further electron flow.
Now, the 'deficit of electrons' is also called 'holes'. So you have 'electrons' with negative charge, and 'holes' with positive charge.
Now, when you 'forward bias' a diode by putting a postive voltage on the 'P' side, and ground on the 'N' side, electrons flow from N to P. This fills in the 'holes' left on the 'N' side when its electrons went to fill some of the 'holes' on the P side. At the same time, 'holes' flow into the 'P' side, and pull away those 'extra' electrons at the junction.
As a result, at some applied voltage (0.7 volts, in fact) the 'voltage barrier' disappears, and the diode acts like a resistor which will drop 0.7 volts across itself.
Ok. So, an NPN transistor consists of TWO P-N junctions. The convention is Collector-Base-Emitter, so an NPN transistor will have an N-doped Collector, a P-doped Base, and an N-doped Emitter. There's a P-N junction between the Base and Collector, and another P-N junction between the Base and Emitter.
If the Base-Emitter leads have zero volts across them, then you get that 'voltage barrier', and current can't flow. If the Base-Emitter leads have more than 0.7 volts across them, then current can flow from the Base to the Emitter, and the 'voltage barrier' drops, and current can also flow from the Collector to the Emitter. In fact, the devices are created such that the amount of current flowing from the Collector to the Emitter is proportional to the amount flowing from the Base to the Emitter.
Now, a PNP transistor works the same, but with reversed voltage biases. This is very handy in an H-Bridge application, for instance.
OK, so now a disclaimer. While the above is accurate as far as it goes, it does gloss over lots of tiny details, and was written off the top of my head. You definitely should read the Parallax docs called out earlier. But hopefully the above will give you a good perspective to start with.
Post Edited (allanlane5) : 8/31/2006 3:27:20 PM GMT
If the little arrow points AWAY from the 'emitter', then the Base is 'N', and you have a PNP device.
If the "little arrow" is
(N)ot (P)ointing i(N) = NPN
(P)ointing i(N) = PNP
·· I haven't heard that one before, but I like it...I always think of it in terms of, "The arrow points to N".
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com
The NPN
Ground->N-> Base -> N->Relay needing Negative
|
Voltage to "Open" and "Close" Valve for flow
Bipolar transistors work as current-controlled current regulators. In other words, they restrict the amount of current that can go through them according to a smaller, controlling current. The main current that is controlled goes from collector to emitter, or from emitter to collector, depending on the type of transistor it is (PNP or NPN, respectively). The small current that controls the main current goes from base to emitter, or from emitter to base, once again depending on the type of transistor it is (PNP or NPN, respectively). According to the confusing standards of semiconductor symbology, the arrow always points against the direction of electron flow:
why couldnt someone just say that? i have to say for all the times i come here and the attacks of "im not trying" and what not, you guys lave some very confusing comments. Im not compalining ive got alot of help but ive been stressing out about the whole transistor thing because i dont wanna here that im stupid once more on this forum. I read what im told and take the information to heart and these overly complicated terms and discriptions are more then i need. But why would you what a current to go through the base in a PNP? wont that damage the stamp?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
-Learn somthing about everything, and Everthing about somthing-
Post Edited (willthiswork89) : 8/31/2006 8:44:04 PM GMT
Now, the physics of the situation is a little different. In actuality electrons each have a negative charge. So lets make a really simple circuit -- one battery, with one resistor going from the 'Plus' terminal to the 'negative' terminal. Ohm's law says V = I * R, or Voltage = Current * Resistance. So, if you have a 6 volt battery, and a 100 ohm resistor, then Ohms law says that V = I * R, or V / R = I, or 6 / 100 == 0.0600, or 60 mA of current will flow. That's POSITIVE (by definition) current, flowing OUT of the current source (the battery positive terminal) through the resistor, and then in to the other terminal of the battery to complete the circuit.
In reality, the battery through chemical action is putting a surplus of charges on the negative side of the battery, and these charges then flow in a NEGATIVE (by definition) direction through the wire, through the resistor, and into the Plus terminal of the battery.
We've occasionally had religious discussions about which is the proper way to teach electronics. The "conventional" way, where positive charges are 'pushed' through the wire in a positive direction by positive voltages? Or the "real" way, where negative charges are 'sucked' out of the ground and flow in a 'negative' direction into the 'plus' terminal?
I call these "religious" because it doesn't really matter which way you understand it, the effect is the same. Doesn't change the circuit, in other words. And "religious" because people sometimes get very angry that the other side "has it completely wrong". Personally, I find schematics (and electronics) MUCH easier to understand and get right if you go with the 'positive charge', 'positive current', 'positive voltage' model.
So in answer to your simple question -- the reason people don't always give you a simple answer to a simple question is that the issue you've asked a simple question about is not in fact simple. And by asking a 'simple' question, you often leave out lots of detail that would make a simple answer much more likely.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
-Learn somthing about everything, and Everthing about somthing-
DEDEDEDEDEDEDEDEDEDEDEDE
like, a machine gun? it scares me cuz they are expensive so i hurry up and cut the power to them. this is the case of a battery not being able to supply the current if im correct? these are some cheapo batteries from like walmart that say HEAVY DUTY on them.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
-Learn somthing about everything, and Everthing about somthing-
SEROUT 16, 16384, [noparse][[/noparse]"Reset!", 13]
At the start of your project, then you can see the 'Reset' string on the debug terminal to see if you're resetting the BS2.
And yes, 300 mA is a LOT to take out of any battery. And a "Heavy Duty" battery doesn't have much energy in it. I'd recommend either using a 'wall-wart' supply (6 volts DC or above) or use Alkaline batteries -- though they aren't going to last very long.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
-Learn somthing about everything, and Everthing about somthing-
I had the same problem i need to use a relay that the current was 80 ma
So i used the UN2803 but what i did i put·one 220·ohms on each on·and used one Stamp I/O pin
·········································· >>>>> STAMP I/O PIN····································>>>>>> Relay OutPut
·(UN2803)···InPut1 >> 220 Ohm>>^·····························//··· ··········· ··· OutPut1 >>^
············ ·· ·InPut2 >> 220·Ohm>>^····························//··· ·(UN2803)·· OutPut2 >>^
·············· · InPut3 >> 220·Ohm>>^···························//···················· ·OutPut3 >>^
(3) inputs ·and tied·the outputs are tied together and that works great
·I did ·this way because i did not·want the UN2803 to be warm at all
·I·see no reason why this should not work
·I going to try this very soon myself and i let you how well this works
·Sam······
··Ps······ ·This is just my 2 cents worth· of an ·