We are struggling to pass parameters to a command. We have a PIDController in a Command, and we are trying to program a couple of buttons to call the same Command with different setpoints.
new JoystickButton(driverController, XboxController.Button.kRightBumper.value).onTrue(new armExtendToValue(m_armsystem, 0));
new JoystickButton(driverController, XboxController.Button.kLeftBumper.value).onTrue(new armExtendToValue(m_armsystem, 5000));
The issue is that it will keep only the setpoint of the 2nd command created. So it always try to reach 5000. It does not matter which button you are using…
Any insight would be greatly appreciated!