Quote:
Originally Posted by Ether
|
How do you access atan2? Its not included in the stripped down Math util.
A perfect arcade drive would map every point within a circle to a set of motor outputs. Using trig you can program for every case using one formula.
Same is true for the mecanum drive. By knowing the resulting vector and magnitude you want, you can program a whole mec drive with a couple calculations.
The code would be a lot cleaner and more efficient, as every point on the circle formed by the joystick would map to a distinct ideal set of motor outputs. (as opposed to using a scaling algorithm.)