# calculation for the potentiometer

My team uses the potentiometer for the arm movement (up and down) according the joystick axis(y) position.
i looked into some guides explaining the use of potentiometer with the joystick axis, but the were a lot of calculations involved between the axis and the PID vi, which i didn’t really understood.

Can someone explain to me those calculations? for an example: what calculations do i need to do for max 60 deg up and min 40 deg down?

…?

I’m not sure what you’re asking.

It’s probably easier just to put the mechanism at the angles you care about and measure what the sensor value actually is, rather than try to compute what it ought to be.

The main problem is scaling the signals. The potentiometer will be something like 0 - 10v, the joystick is in -1 to +1, and you are thinking in terms of angle of the arm. Take a look at the following link:

http://team358.org/files/programming/ControlSystem2009-/LabVIEW/

Towards the bottom is a good Labview example of slaving a Joystick to a potentiometer signal using PID. I think this is similar to what you want to do. Take a look and reply back with more questions.

It’s a very nice web-page you have there…
Anyway, the example is very similar to what i was asking.
For example: How do you calculate it so, 1.17 is 90 deg max down and 3.9 is 90 max deg up? and how can i change it to be for example, 40 deg max down and 60 deg max up?

Those are measured values. You drive your device to where you want the limit to be with a probe or indicator on the Analog Voltage and see what it reads.