Go Down

Topic: Unwanted feedback from potentiometers (Read 855 times) previous topic - next topic

tb0508

Apr 11, 2012, 09:41 am Last Edit: Apr 11, 2012, 09:51 am by tb0508 Reason: 1
I am receiving feedback from my potentiometers without them being pressed. More specifically, I have three pots. One for wheels, steer, brake. When I run my code and test the brake pot and motor controller it works perfect but I get an output like this:

Code: [Select]

Brake is applied
Brake Motor Reverse
Brake = 395
Decreasing Value, Brake not applied
Brake Motor Forward
Brake = 379
Decreasing Value, Brake not applied
Brake Motor Forward
Brake = 363
Decreasing Value, Brake not applied
Brake Motor Forward
Brake = 329
Decreasing Value, Brake not applied
Brake Motor Forward
Brake = 350
Brake is applied
Brake Motor Reverse
Brake = 329
Decreasing Value, Brake not applied
Brake Motor Forward
Brake = 311
Decreasing Value, Brake not applied
Brake Motor Forward
Brake = 294
Decreasing Value, Brake not applied
Brake Motor Forward
Brake = 278
Decreasing Value, Brake not applied
Brake Motor Forward
Brake = 258
Decreasing Value, Brake not applied
Brake Motor Forward
Brake = 278
Brake is applied
Brake Motor Reverse
Steer = 642
Wheel = 615
Steer = 624
Wheel = 617
Steer = 0
Steer = 641
Wheel = 6
Steer = 609
Wheel = 615
Steer = 632
Wheel = 615
Wheel = 66
Wheel = 61
Brake = 144
Brake is not applied
Brake Motor Forward
Wheel = 615
Steer = 631


This happens when I only touch the brake pot. As you can see I am getting steer/wheel feedback without even using those pots but the brake works perfectly with its motor controller to actuator. I have tried using capacitors, many, to no avail. When I take the +5V for the wheel pot and steering pot off the +5V rail, then brake looks good with no wheel/steer feedback showing. Only possible reason I can think is all three of these pots are in the front of our cart. We run the -,+,signal all together down the side of the cart and then branch them off in the back of the go-cart to their respected destinations. Another thing is that I have a GAS pot also but it runs down the cart on the opposite side and when I press that pot I get no feedback from any other pot. Maybe I am getting crazy feedback since they are all traveling together? Any help?

AWOL

#1
Apr 11, 2012, 10:36 am Last Edit: Apr 11, 2012, 10:39 am by AWOL Reason: 1
Well, it's good that you posted your debug output, but not good that you didn't post the code that produced it.

Quote
I am receiving feedback from my potentiometers without them being pressed

Most pots I've come across you turn or slide.

Quote
Another thing is that I have a GAS pot

Gallium Arsenide?
"Pete, it's a fool looks for logic in the chambers of the human heart." Ulysses Everett McGill.
Do not send technical questions via personal messaging - they will be ignored.

MarkT

[The word is "crosstalk", not "feedback" BTW]

So how are you wiring up these pots, how long are the wires, are they shielded?

What resistance are the pots - I would recommend lowish values for good noise immunity especially with long cables (5k or so).

Do you run the cables parallel to any high current wiring?  That's usually a cause of interference.

Have you considered adding a capacitor for each pot signal at the Arduino to ground?
[ I won't respond to messages, use the forum please ]

winner10920

What are the actual numbers on the analog read? If the cros talk is only like 10-20 units perhaps you can eliminate that in code and not do anything unless the change is more than say 20

pwillard

Here is a a thought...

Assuming that you wired them correctly.

If you slide a pot and the values of the other pots change... that means to *me* that it is very likely that your 5V power source changed voltage... IE; the "load" caused a change in regulated voltage and as a result... it changed all the voltage levels seen by that analog pins accordingly.  If you have a voltmeter, you might be able to confirm this by monitoring your power rails while you make adjustments.  It will either remain stable (good)  or raise and drop a little (bad).

Bad means... maybe you need a better voltage source.

winner10920

Where's your code for all that? Perhaps in your implementation there's a bug in the brake pot code, because if there the same pot they should crosstalk equally
worse case scenario you can eliminate the crosstalk considerably with metallic sheathing altho that's abit more expensive to get wire with that

pwillard

Is this a re-purposing of an existing PC racing wheel?

If so, the brake and acceleration pots can actually in series on the same AXIS.  IE; like 2 variable resistors in each leg of a voltage divider pair.  (worth checking if this is your scenario)

Go Up