mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
[hal,wpilib] Use new DS available API from mrccomm (#8302)
Instead of just having a max count for joystick values, there's an available mask of values. This is because in the future we're expecting there to be holes in the list of available buttons and axes. This updates everything to support that scenario. Also, Joystick buttons, axes, and POVs all now start at 0 instead of 1.
This commit is contained in:
@@ -70,7 +70,7 @@ class PotentiometerPIDTest : public testing::Test {
|
||||
frc::sim::PauseTiming();
|
||||
frc::sim::DriverStationSim::ResetData();
|
||||
|
||||
m_joystickSim.SetButtonCount(12);
|
||||
m_joystickSim.SetButtonsMaximumIndex(12);
|
||||
|
||||
m_callback =
|
||||
HALSIM_RegisterSimPeriodicBeforeCallback(CallSimPeriodicBefore, this);
|
||||
|
||||
Reference in New Issue
Block a user