Code Problemo

We got problems. When we attempt to deploy the robot code to the RoboRio we get this error:

ERROR  1  Unhandled exception: java.lang.IllegalArgumentException: Subsystem must not be null.  frc.robot.commands.ChimneyGo.(ChimneyGo.java:20) 
Warning at edu.wpi.first.wpilibj.RobotBase.startRobot(RobotBase.java:274): Robots should not quit, but yours did! 
ERROR  1  The startCompetition() method (or methods called by it) should have handled the exception above.  edu.wpi.first.wpilibj.RobotBase.startRobot(RobotBase.java:276) 
ERROR  1  Unhandled exception: java.lang.IllegalArgumentException: Subsystem must not be null.  frc.robot.commands.ChimneyGo.(ChimneyGo.java:20) 
Warning at edu.wpi.first.wpilibj.RobotBase.startRobot(RobotBase.java:274): Robots should not quit, but yours did! 
ERROR  1  The startCompetition() method (or methods called by it) should have handled the exception above.  edu.wpi.first.wpilibj.RobotBase.startRobot(RobotBase.java:276) 
ERROR  1  Unhandled exception: java.lang.IllegalArgumentException: Subsystem must not be null.  frc.robot.commands.ChimneyGo.(ChimneyGo.java:20) 
Warning at edu.wpi.first.wpilibj.RobotBase.startRobot(RobotBase.java:274): Robots should not quit, but yours did! 
ERROR  1  The startCompetition() method (or methods called by it) should have handled the exception above.  edu.wpi.first.wpilibj.RobotBase.startRobot(RobotBase.java:276) 
ERROR  1  Unhandled exception: java.lang.IllegalArgumentException: Subsystem must not be null.  frc.robot.commands.ChimneyGo.(ChimneyGo.java:20) 
Warning at edu.wpi.first.wpilibj.RobotBase.startRobot(RobotBase.java:274): Robots should not quit, but yours did! 
ERROR  1  The startCompetition() method (or methods called by it) should have handled the exception above.  edu.wpi.first.wpilibj.RobotBase.startRobot(RobotBase.java:276)

Plz help

That tells you what and where the problem is. You’re passing a null subsystem value at line 20 of ChimneyGo.java. You’re probably not initializing the subsystem you’re passing before you pass it. For us to give more specific advice, you’ll need to upload your code somewhere (e.g. to GitHub) and provide a link to it.

https://www.twilio.com/blog/how-to-read-and-understand-a-java-stacktrace

1 Like

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