Hello,
I'm building a project with 2 seven segments displays(each has one digit).
Can someone explain me why do I need to attach a transistor (npn or pnp) to the display to serve as an on/off switch for the LEDs, can I just use the arduino's i/o pins to do that job?
DanAro:
Hello,
I'm building a project with 2 seven segments displays(each has one digit).
Can someone explain me why do I need to attach a transistor (npn or pnp) to the display to serve as an on/off switch for the LEDs, can I just use the arduino's i/o pins to do that job?
Thank you, Dan.
An Arduino pin can only switch an absolute maximum 40mA, and the current should be kept well below that.
A seven-segment display without a decimal point, with each segment at 20mA, would draw 140mA .
It depends on the input voltage. At a higher input voltage the regulator must dissipate more heat getting down to the 5V.
It's a good exercise in datasheet-hunting to find the exact component on your Uno, find its ratings and do the calculations on heat dissipation for your input voltage and output current.
The 5.0 volt voltage regulator on the UNO is, according to the schematic, an MC33269.
The data sheet for the MC33269 states that the current limit, with a 15 Volt supply, is a minimum of 800mA.
For the OP's application, that will be plenty, assuming that the LEDs are not directly driven from the Arduino pins, but via a appropriate transistors, each with say a 1K resistor to the base.
6v6gt:
The 5.0 volt voltage regulator on the UNO is, according to the schematic, an MC33269.
The data sheet for the MC33269 states that the current limit, with a 15 Volt supply, is a minimum of 800mA.
For the OP's application, that will be plenty, assuming that the LEDs are not directly driven from the Arduino pins, but via a appropriate transistors, each with say a 1K resistor to the base.
Read post#5 again, and read the datasheet again.
My car can reverse, and go 180.
If the datasheet states that the limits are 15volt and 800mA, that does not mean "at the same time".
The practical limits are usually power consumption (heat) in the regulator.
12volt on Vin means 7volt across the regulator.
100mA (0.7watt) will make it hot, and 200mA will probably shut the regulator down (if you're lucky).
A 9volt supply on the DC socket is 8.3volt on Vin, so 3.3volt across the regulator.
Then 300mA should just be possible.
USB supply bypasses the regulator.
Leo..
Seven segment displays can be multiplexed. Then you only have the current draw of a single digit.
The multiplex transistors (common anode or cathode) can be turned off in software (display off).
Leo..
Another thought... if the displays have a very high efficiency (brightness) you can drive them directly from the Arduino pins by choosing high resistor values for the LEDs. But since the LEDs share a common anode or cathode, a transistor drive on the common is a good design practice, because the resulting current sharing causes segments to light unevenly.
Wawa:
Read post#5 again, and read the datasheet again.
My ca[r] can reverse, and go 180.
If the datasheet states that the limits are 15volt and 800mA, that does not mean "at the same time".
. . .
I guess then that I have misinterpreted the datasheet at http://www.onsemi.com/pub/Collateral/MC33269-D.PDF where it says (slightly reformatted from the PDF to display here):
Current Limit (Vin − Vout = 10 V) ILimit Min 800 mA
Maybe that figure assumes something about the heat sink design ?
Look a the thermal resistance tables.
Junction to case is 15 degrees C per watt for the SOT-223 package.
Max chip (die) temp is 150C.
Say we have an infinite size thick copper water-cooled heatsink, kept at 30C.
Then we could dissipate (150-30) / 15 = 8watt
At 800mA, we could have 8watt/0.8A = 10volt across the regulator
Do your own calcs for free-air (no heatsink) cooling (156C/watt).
And 50C/watt (estimated) for a circuit board heatsink at say 60C heatsink (board) temp.
Leo..
Wawa is perfectly correct.
It's not a matter of misinterpreting datasheets, it's a matter of physics and a quick calculation, regardless of which exact regulator is used.
liudr:
The maximal current for ATMEGA328 on Arduino UNO is 200mA for all pins.
This could be misinterpreted. Better to say "The maximum current for ATMEGA328 on Arduino UNO is 200mA for all pins combined".
6v6gt:
Maybe that figure assumes something about the heat sink design ?
Regulator power ratings ALWAYS assume you're dissipating the heat.
A linear regulator drops the voltage by converting power to heat. A 10 volt drop at 0.8 amps will generate 8 Watts of heat. That's a lot of heat to get rid of.
DanAro:
Ok, I understand, one more question - what is the real output current of the 5v pin (is it the same as of the i/o pins?)
It's not the same as the I/O pins. As has been previously mentioned the input voltage is an important factor in how much current you can safely pull from the regulator. Keep in mind you have to share this current with the Arduino.
You're usually fine powering sensors from the 5V pin but don't try to power servos from the 5V pin. You'll probably be fine powering your LEDs from the 5V pin.
sterretje:
I have an Uno schematic (rev 3) in front of me that uses a NCP1117ST50T3G as a regulator Maybe different versions of the board?
Hmmm. Maybe the MC33269 is on some clones. (My clones have NCP1117s.)
Both regulators are from OnSemi, and they have very similar ratings, except that the quiescent current of the NCP1117 is lower, and dropout voltage is slightly better for the MC33269. (Dropout voltage for the MC33269 is 1V @ 400mA, and for the NCP1117 it's 1V @ 300mA.)
My copy of the schematic shows the NCP1117ST50T3G too. (Attached)