Go Down

Topic: AnalogRead unstable with ColorLCD (Read 1 time) previous topic - next topic

gaith

Hello,
I just installed ColorLCD from Sparkfun on my Arduino Mega. It works Fine.
But when I put a 10 kOhm potentiometer in an analog input (with two border pins connected to ground and 5V), the value is VERY unstable (+30 / -30).
And Even if I'm connecting the analog input to the ground (with no potentiometer), the value is varying between 0 and 30 (on 1023), with some kind of cycles.
If I disconnect the LCD, the analog values become stable again.

So I think maybe there are some kinds of capacitors (the varying has... constent cycles) in the LCD which are perturbating the inside of Arduino ??
Someone did have the same problem ?
Can I add some regulation in the analog input of Arduino ? (like capacitors)

Thank you in advance, and sorry for my poor english.
Build a groove box with Arduino Due :
http://groovuino.blogspot.com/

Grumpy_Mike

Quote
So I think maybe there are some kinds of capacitors (the varying has... constent cycles) in the LCD which are perturbating the inside of Arduino ??

No I would not think so.
It is the very lack of capacitors that is causing you the problem.

First make sure your power supply can delver the expected current. Then add a 10 to 100uF capacitor across power and ground of the LCD.

gaith

Yes, you're right, I'm powering with my computer and USB cable, maybe it's not enough. I will try to power with external power supply and add capacitors.

Thanks
Build a groove box with Arduino Due :
http://groovuino.blogspot.com/

PaulRijk

gaith,
I noticed that when using digital- and/or analog Outputs and Analog inputs, using the same Gnd-pin the Analog input values are lifted about 30, like you mentioned. Even grounded analog inputs show so.
When using a separate Gnd-pin for analog-inputs the problem is gone. When measuring the voltage between the two Gnd-pins you'll see a value raising to >100mV, depending of the number of digital outputs.
It seems it has to do with the differential measurement at the analog input cicuits.


MarkT

This is classic issue - any ground wire that carries an appreciable current (such as powering LCD backlights) will have a voltage
across it (in fact the bulk of this voltage can be due to the contact resistance of the header pins).

You want any measurement signal to use a separate, non-current-carrying, ground wire as its reference - then you are not
adding/subtracting any IR-voltages to your signal. (V = IR).  [ well more accurately you are keeping the current really small
so the error is less ]
[ I won't respond to messages, use the forum please ]

Go Up
 


Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

Arduino
via Egeo 16
Torino, 10131
Italy