Quote:
Originally Posted by Triapod
If i'm following the math correctly...It's probably that +1 that makes the joystick send out a value other than 0 because in this case it will only be 0 if the joystick is all the way back.
You might want to try preset heights controlled by buttons. It seems that you'll need to hold the joystick at that position in order for the hight to remain there.
|
Thanks for clearing that up!
We still want joystick control of the elevator, but i wanted to use PID to slow down motor control as it hits the upper and lower limits (which I wanted to be recognized by a specific value from the encoder.
The elevator is controlled by axis 2. Lets say the upper limit is 1000 rotations, and the elevator starts at its bottom limit - 0. I want the motor to slow down as it reaches either of those two values so we don't overshoot and blow the motor. How should I go about doing that then?