Loading...
Pages: [1]   Go Down
Author Topic: Damn Pot  (Read 319 times)
0 Members and 1 Guest are viewing this topic.
Gibraltar
Offline Offline
Newbie
*
Karma: 0
Posts: 37
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Afternoon all,

Trying a simple analog read on an arduino uno analog pin 2 from a potentiometer, and then using the Serial.print to display this input, the problem I have is the reading keeps fluctuating  when the pot is stationary, I have changed the pot and still the same issue.
Any ideas what could be causing the issue? Tried a resistor on the wiper but no improvement.

Thanks,

Mark
Logged

Offline Offline
Edison Member
*
Karma: 23
Posts: 1372
Now, More Than Ever
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

How much is is fluctuating?
Could be coupling noise (AC - it's all around us)...
Tried shorter leads?
A 0u1 bypass?
Logged

Don't Be Upset By The Results You Didn't Get With The Work You Didn't Do

Gibraltar
Offline Offline
Newbie
*
Karma: 0
Posts: 37
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi runaway_pancake,

The values keeps jumping from 150 to 134 then 161 then back again, the leads I'm using are short breadboard connector leads, but there were close to the laptop at the time, I will set it up again and try it.
"A 0u1 bypass?" - Sorry totally lost me there  smiley-eek

Many thanks for your help.

Mark
Logged

Offline Offline
God Member
*****
Karma: 3
Posts: 812
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Trying a simple analog read on an arduino uno analog pin 2 from a potentiometer

Schematic?
And how much is it fluctuating?
Logged

Central MN, USA
Offline Offline
Faraday Member
**
Karma: 35
Posts: 5918
Phi_prompt, phi_interfaces, phi-2 shields, phi-panels
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

What is the value (total resistance) of the pot? Do you have a multimeter to measure it? Maybe the contact inside is bad.
Logged


Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 279
Posts: 15314
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

If the value of the pot is too high then it can effect the stablity of the reading. No higher then a 10k ohm pot is recommended. And any noise on the voltage feeding the pot will also be seen as noise on the measurement.


Lefty

Logged

0
Offline Offline
Tesla Member
***
Karma: 71
Posts: 6603
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Computers put out oodles of interference.
Logged

Northern California (by San Francisco)
Offline Offline
Full Member
***
Karma: 1
Posts: 238
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Just to give you a benchmark, I've been working with a 5k pot using analogRead, and if I don't move the pot wiper it stays on a value, sometimes flipping between two values (like from 243 to 244 and back). I've never seen the sensed values moving + and - over 1% like you are seeing.

My pot is hooked to a breadboard about six inches from the Arduino, and the Arduino is on a six-foot USB cable from my computer.
Logged

Pages: [1]   Go Up
Print
 
Jump to: