Quote:
Originally Posted by microman1934
Thank you so much for the help guys, I just ended up doing this:
Code:
double rot = -stick.getX();
double speed = -stick.getY();
myRobot.arcadeDrive(rot*0.5, speed*0.5);
|
Why not just square the magnitude? Pseudo code for example.
Code:
double rot = -stick.getX();
double speed = -stick.getRawAxis(drive axis);
myRobot.arcadeDrive(rot, speed * Math.abs(speed));
This allows finer control at lower speeds (when joystick is reading 0.5 you will send 0.25 to the motors) but still allows full speed when the joysticks are at full throttle.