Answer to Speed control

All you would have to do is use a assignment and do the math of halfing the joystick value variable.

Speed Control


How do you program a robot to divide a joystick value in half? I.E. so when the joystick is full forwards it goes half speed or when it is half forward make it go at quarter speed. Same with reverse. Thanks in advance.

just set the channel on the transmiter to 50% or what ever to what you want

This is what I was talking about:

while ( var==1 )
{
rx1 = GetRxInput ( 1 , 1 ) ;
rx1= (rx1- 127) / 2 ;
SetMotor ( 1 , rx1+ 127 ) ;
}

Sounds like you mean changing the trim. This will achieve the effect you want in only one direction and often leave the motor running constantly in the opposite direction. The trim setting moves the neutral 127 value around so that if the default joystick position in more around 135 by adjusting the trim you can get 135 to equal 127.