[hal,wpilib] Add support for joystick outputs (#8385)

Support joystick outputs, including Rumble and LEDs.

Also requires an update to Joystick descriptors, as that has also
changed in mrccomm to support showing what outputs are supported.
This commit is contained in:
Thad House
2025-11-17 14:36:14 -08:00
committed by GitHub
parent 5db6d2f500
commit ce6fd225a6
54 changed files with 1607 additions and 854 deletions

View File

@@ -2,6 +2,8 @@
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.
#include <utility>
#include "wpi/hal/proto/ControlData.h"
#include "wpi/util/protobuf/ProtobufCallbacks.hpp"
@@ -85,7 +87,7 @@ std::optional<mrc::ControlData> wpi::util::Protobuf<mrc::ControlData>::Unpack(
ControlData.SetJoystickCount(Joysticks.size());
for (size_t i = 0; i < ControlData.GetJoystickCount(); i++) {
ControlData.Joysticks()[i] = Joysticks[i];
ControlData.Joysticks()[i] = std::move(Joysticks[i]);
}
return ControlData;