![]() |
WPILibC++ 2025.3.2
|
This class represents the onboard IO of the XRP reference robot. More...
#include <frc/xrp/XRPOnBoardIO.h>
Public Member Functions | |
| XRPOnBoardIO () | |
| bool | GetUserButtonPressed () |
| Gets if the USER button is pressed. | |
| void | SetLed (bool value) |
| Sets the yellow LED. | |
| bool | GetLed () const |
| Gets the state of the yellow LED. | |
Public Attributes | |
| units::second_t | m_nextMessageTime = 0_s |
Static Public Attributes | |
| static constexpr auto | kMessageInterval = 1_s |
This class represents the onboard IO of the XRP reference robot.
This the USER push button and LED.
DIO 0 - USER Button (input only) DIO 1 - LED (output only)
|
inline |
| bool frc::XRPOnBoardIO::GetLed | ( | ) | const |
Gets the state of the yellow LED.
| bool frc::XRPOnBoardIO::GetUserButtonPressed | ( | ) |
Gets if the USER button is pressed.
| void frc::XRPOnBoardIO::SetLed | ( | bool | value | ) |
Sets the yellow LED.
| value | True to activate LED, false otherwise. |
|
staticconstexpr |
| units::second_t frc::XRPOnBoardIO::m_nextMessageTime = 0_s |