So I'm powering an Arduino Mega with a TFT shield and 4.3" TFT LCD. It works great, depending on what power source I use. If I hook it up via USB or 5v external power (using the barrel jack on the Mega), it works great. If I hook it up with 12v (running off a 4-channel relay - see attachment "relay.png" for basic idea), no dice. The sketch TRIES to load, but it always ends with the LCD showing a blank white screen. It doesn't matter what 12v source I use, wall wart or battery, same results. See "uno.png" to get an idea of how I have it hooked up between power and the Arduino.
So it appears that I must use a 5v source to power the Mega. I may already have the solution here, but I'd like affirmation so I'm just going to talk myself through it:
I will remove the 12v power line from Vin on the Mega and replace it with a 5v power line (same power source, incidentally, but my power box has a step-down transformer). I will also remove the 12v wire from GND on the Mega (that would be one of the green wires in "uno.png").
Instead, I will just use a barrel jack to supply 5v to the Arduino.
I will leave everything else as-is, continuing to use the 12v main to power the relay (they are 12v devices, after all).
So I'm assuming that will work. Ideally, though, I'd like to stick with 12v to power it so I don't have to string another set of wires (which really isn't a big deal, just a bit time-consuming).
Now I'm also wondering what causes the white screen when 12v is used - does anyone have any ideas on why that happens? Is it just too much for the LCD to handle?
Also, is there some sort of "conditioner" I can put together to make the 12v more "stable," so to speak, or would just using 5v be simpler?
majhi:
So I'm powering an Arduino Mega with a TFT shield and 4.3" TFT LCD. It works great, depending on what power source I use. If I hook it up via USB or 5v external power (using the barrel jack on the Mega), it works great. If I hook it up with 12v (running off a 4-channel relay - see attachment "relay.png" for basic idea), no dice. The sketch TRIES to load, but it always ends with the LCD showing a blank white screen. It doesn't matter what 12v source I use, wall wart or battery, same results. See "uno.png" to get an idea of how I have it hooked up between power and the Arduino.
The problem you are running into is overloading the Mega's 5v regulator. When you connect the USB the onboard 5v regulator is not used. if you connect low voltage(5v) thru the regulator the amount of waste heat generated by the regulator is low enough not to cause the regulator to shut down.
If you want to run off 12v, you need a more substantial 5v regulator. The Mega will work just fine with 12v input, but it CANNOT produce enough 5v (without overheating and shutting down) to run your TFT shield from 12V.
When you supply 12V the regulator has to waste (12-5)amperage power. So if the TFT shield uses 250ma that puts a (7V.25A) 1.75Watt additional load on the regulator.
I think you need to add a powersupply that will provide the 5V for both the Mega, and the TFT.
Chuck.
Check out my Kickstarter Project Memory Panes an expansion RAM Shield for Mega2560's. It adds 1MB of RAM for those projects where 8KB is not enough.
majhi:
.....or 5v external power (using the barrel jack on the Mega), it works great.
Can't do that.
The DC socket needs at least 7.2volts for the onboard regulator to produce a stable 5volts.
majhi:
...remove the 12v power line from Vin on the Mega...
Shouldn't do that either.
12volts needs to go into the DC socket. Nowhere else.
If your setup runs from USB power, it must use less than 500mA, otherwise the USB would have shut down.
The previous poster mentions 250mA for the shield. The Mega itself uses ~75mA.
That means that the regulator has to consume ~2watt to do it's job.
That could indeed be too much, so it will shut down.
An easy way to fix this is to lower the 12volt input to the Mega.
Try four 1N4004 diode in series between +12volt and +DC socket.
That will drop the 12volt supply to ~9.2volt.
That might be just enough to keep the regulator happy.
Leo..