Package frc.lib5k.game
Class Match
- java.lang.Object
-
- frc.lib5k.game.Match
-
public class Match extends java.lang.Object
Methods for reading Match data
-
-
Constructor Summary
Constructors Constructor Description Match()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static edu.wpi.first.wpilibj.DriverStation.Alliance
getAlliance()
Get the current alliancestatic int
getAllianceStationID()
Get the alliance station ID of the humans (where we are set up on the field)static java.lang.String
getEventName()
Get the FRC event namestatic java.lang.String
getGSM()
Get the game specific message (data sent by FMS about current match)static int
getMatchNumber()
Get the current match numberstatic double
getMatchTime()
Get an estimation of the time remaining in the current match (current mode)static edu.wpi.first.wpilibj.DriverStation.MatchType
getMatchType()
Get the match typestatic int
getReplayNumber()
Get the current match replay numberstatic boolean
isOfficialMatch()
Check if the robot is currently on a field
-
-
-
Method Detail
-
getGSM
public static java.lang.String getGSM()
Get the game specific message (data sent by FMS about current match)- Returns:
- Current GSM
-
getMatchTime
public static double getMatchTime()
Get an estimation of the time remaining in the current match (current mode)- Returns:
- Estimated time left in match
-
isOfficialMatch
public static boolean isOfficialMatch()
Check if the robot is currently on a field- Returns:
- Is the robot on a field
-
getEventName
public static java.lang.String getEventName()
Get the FRC event name- Returns:
- Event name
-
getMatchType
public static edu.wpi.first.wpilibj.DriverStation.MatchType getMatchType()
Get the match type- Returns:
- Match type
-
getMatchNumber
public static int getMatchNumber()
Get the current match number- Returns:
- Current match number
-
getReplayNumber
public static int getReplayNumber()
Get the current match replay number- Returns:
- Match replay number
-
getAlliance
public static edu.wpi.first.wpilibj.DriverStation.Alliance getAlliance()
Get the current alliance- Returns:
- Current alliance
-
getAllianceStationID
public static int getAllianceStationID()
Get the alliance station ID of the humans (where we are set up on the field)- Returns:
- Alliance station ID
-
-