-
Overall implementation is going great - thank you for this! We use Xbox controllers, the left stick is properly working commanding forward and back, left and right. I can't seem to get the right stick (axis 4) to control rotation. The robot will spin continuously in the direction it is commanded, until the right stick is moved in the y axis, it will then eventually stop rotating. I started from the example project with minor updates to cover our modules and the Xbox controller. I know it is something simple, any ideas? Below are snips of the code that I 'think' are pertinent. Thanks in advance - Jason XboxController driverXbox = new XboxController(0);
() -> true, false, false); //headingCorrection was true |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 11 replies
-
Have you tried inverting your gyro? I have a setting for it in one of the configs, also turn off heading correction. Maybe try turning off heading correction first. |
Beta Was this translation helpful? Give feedback.
I would like to document our error and close this question out. First, there was / is nothing wrong with YAGSL - it works as designed. The robot that I was implementing this on is a very compact swerve robot, like 10.5" center to center wheel distance compact. This meant that the RoboRio was mounted at a 45 degree angle (in the Z) to the chassis, with a NavX2 mounted on it. This twist in the gyro relative to the frame, even with a full calibration was a problem. The solution was to mount a Pigeon2 to the robot, but that also meant adding a CANivore, because the can bus became saturated. Getting all of the firmware in the right version was a challenge, just because there are some newer 202…