Quote:
Originally Posted by pastelpony
Correct me if I'm wrong, but I've been reading that the default mecanum code in the WPI library actually takes the incorrect inputs by default.
|
Would you please post a link to where you've been reading that?
I don't have access to LabVIEW to inspect its code, but here's the inverse kinematics code taken straight from 2015 WPILib RobotDrive.Java:
Code:
wheelSpeeds[MotorType.kFrontLeft_val] = xIn + yIn + rotation;
wheelSpeeds[MotorType.kFrontRight_val] = -xIn + yIn - rotation;
wheelSpeeds[MotorType.kRearLeft_val] = -xIn + yIn + rotation;
wheelSpeeds[MotorType.kRearRight_val] = xIn + yIn - rotation;
I'm not a Java guru, but it looks correct to me.