Package frc.spectrumLib.hardware
Enum Class Rio
- All Implemented Interfaces:
Serializable,Comparable<Rio>,Constable
Identifies the roboRIO that is running, keyed by its serial number, so a robot-specific config
can be selected at startup.
Serial numbers are on the label on the back of the roboRIO, and a short one needs a leading zero. Reflashing the roboRIO can change the serial number.
Based on: https://github.com/Team100/all24/blob/2a109b28467cfddcafb93c7fc85ef60b56a628a2/lib/src/main/java/org/team100/lib/config/Identity.java
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum Constants -
Field Summary
Fields -
Method Summary
-
Enum Constant Details
-
PHOTON2026
-
PM_2026
-
FM_2026
-
OM_2026
-
FM_2025
-
FM_2024
-
SIM
-
UNKNOWN
-
-
Field Details
-
id
The constant matching the roboRIO this code is running on. -
CANIVORE
Bus name that selects the first CANivore the system has.- See Also:
-
RIO_CANBUS
Bus name of the roboRIO's own CAN interface.- See Also:
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
isRio2
public boolean isRio2()True for a RIO 2.0 controller, false for a RIO 1.0.
-