Source or Sink current
Vincenzo1309
Posts: 76
Dear all, I am currently working on a project. I am connecting a transistor BD679 to a I/O pin of Basic Stamp 2. This NPN transistor is used to drive a solenoid actuator. I know that the source/sink current of BS2 = 20/25mA
But I am confused, so actually how much max. current actually flow out of the pin? is it 20 or 25mA?
Do I use source or sink current?
Kindly advise
Thanks and Regards,
But I am confused, so actually how much max. current actually flow out of the pin? is it 20 or 25mA?
Do I use source or sink current?
Kindly advise
Thanks and Regards,
Comments
I can use a resistor to do that.
But how do I calculate the value of the resistor?
Kindly advise..
Thanks and Regards,
A Stamp I/O pin provides roughly 5V when HIGH (actually about 4.7V, but this depends somewhat on the current drain). A transistor's base-emitter junction requires roughly 0.6V, that's 4.7V - 0.6V = 4.1V left for the resistor to drop. Pick 15mA for the current, so you have: 4.1V = 15mA x Resistance or R = 4.1V / 0.015A = 273 Ohms. The closest standard value is 270 Ohms.
Will it be logically wrong if I did it this way, my supply voltage for the actuator is 9V, measured resistance of the actuator is 8 Ohms.
Direct Current Gain of BD679 = 750 (from datasheet)
Rb = (IC supply voltage * Direct Current Gain) / (5 * load current)
load current = 9V / 8 Ohms = 1.125A
Rb = (5V * 750) / ( 5 * 1.125) = 667 Ohms, in this case, I use the 1K resistor. It works though.
So am I right for the above calculations? Can it be done this way?
Kindly advise.
Thanks and Regards.
Minimum base current = 1.125A / 750 = 1.5 mA.
The gain of the transistor may be lower than 750. You would use the minimum hFE (DC gain) from the datasheet. I would probably just use 10mA. This would guarantee that the transistor is saturated (fully conducting) and the extra few milliAmps won't normally make a difference. If you were using several I/O pins at the same time and the total BS2 I/O pin current was an issue, I might decrease this to 2-3mA. In your case, I'd still use something like 470 Ohms which would give a base current of around 8mA.
So in my case, if I use the 1K resistor, my base current is only 4.1A / 1000 ohms = 1.4 mA
therefore when this 1.4mA is amplified, the resulting Ic is enough to drive the actuator.
Ic = Current Gain * Ib
= 750 * 0.0014
= 1.05A
So do you think my method might be wrong, even though it works?
For power switching, you really want to drive the transistor into saturation to minimize the collector to emitter resistance and the power dissipation of the transistor.
By the way, don't forget the protective diode across the actuator coil!
Thanks alot! Sure remember about the diode!