Some of our younger students are working on code for a small tank drive robot. We have tested the code that they have written and if given a hardcoded value, the motors all spin, but when they try to control it with the y-values of an Xbox controller, the input seems to get lost somewhere. Any help would be much appreciated. The code can be found here.
This needs to send a supplier, drivetrain.setDefaultCommand(new TankDriveCommand(m_driverController::getLeftY, m_driverController::getRightY, drivetrain));
and this needs to accept a supplier.
private final DoubleSupplier left, right;
public TankDriveCommand(DoubleSupplier left, DoubleSupplier right, Drivetrain drivetrain){