Robot Code deploys but doesn't work

Been having a lot of intermittent issues with our code. Sometimes it is unresponsive to joystick commands, while others it runs “ok”. I can see the joysticks and buttons in the drive station. This is our first year doing command-based, but I think my students’ code looks correct. Is it possible our Rio is bad? I can see all the motors controllers and sensors on the CAN network just fine. I do see loop overruns in the log:
“Warning at edu.wpi.first.wpilibj.IterativeRobotBase.printLoopOverrunMessage(IterativeRobotBase.java:359): Loop time of 0.02s overrun”

Here is a link to our repo:

1 Like

Update to WPILib 2022.3.1 and RoboRIO image v4.0. Both are required for competition. This issue was fixed in 2022.2.1.

Our team had the same issue, but beware because the joysticks lose control, but keep their last command. This resulted in our robot putting a hole in our school’s drywall. The issue is with WPILib. Update to at least 2022.2.1(this is the version with the fix but 2022.3.1 is out too). You’ll also need to update the rio image to v4 (reinstall NI game tool). It should work fine after this.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.