public class HAL extends JNIWrapper
Modifier and Type | Field and Description |
---|---|
static int |
kMaxJoystickAxes |
static int |
kMaxJoystickPOVs |
Constructor and Description |
---|
HAL() |
Modifier and Type | Method and Description |
---|---|
static AllianceStationID |
getAllianceStation() |
static boolean |
getBrownedOut() |
static void |
getControlWord(ControlWord controlWord) |
static short |
getJoystickAxes(byte joystickNum,
float[] axesArray) |
static int |
getJoystickAxisType(byte joystickNum,
byte axis) |
static int |
getJoystickButtons(byte joystickNum,
java.nio.ByteBuffer count) |
static int |
getJoystickIsXbox(byte joystickNum) |
static java.lang.String |
getJoystickName(byte joystickNum) |
static short |
getJoystickPOVs(byte joystickNum,
short[] povsArray) |
static int |
getJoystickType(byte joystickNum) |
static double |
getMatchTime() |
static boolean |
getSystemActive() |
static int |
initialize(int mode) |
static void |
observeUserProgramAutonomous() |
static void |
observeUserProgramDisabled() |
static void |
observeUserProgramStarting() |
static void |
observeUserProgramTeleop() |
static void |
observeUserProgramTest() |
static void |
report(int resource,
int instanceNumber) |
static void |
report(int resource,
int instanceNumber,
int context) |
static int |
report(int resource,
int instanceNumber,
int context,
java.lang.String feature)
Report the usage of a resource of interest.
|
static int |
sendError(boolean isError,
int errorCode,
boolean isLVCode,
java.lang.String details,
java.lang.String location,
java.lang.String callStack,
boolean printMsg) |
static int |
setErrorData(java.lang.String error) |
static int |
setJoystickOutputs(byte joystickNum,
int outputs,
short leftRumble,
short rightRumble) |
static void |
waitForDSData() |
getPort, getPortWithModule
public static int kMaxJoystickAxes
public static int kMaxJoystickPOVs
public HAL()
public static void waitForDSData()
public static int initialize(int mode)
public static void observeUserProgramStarting()
public static void observeUserProgramDisabled()
public static void observeUserProgramAutonomous()
public static void observeUserProgramTeleop()
public static void observeUserProgramTest()
public static void report(int resource, int instanceNumber)
public static void report(int resource, int instanceNumber, int context)
public static int report(int resource, int instanceNumber, int context, java.lang.String feature)
Original signature: uint32_t report(tResourceType, uint8_t, uint8_t, const
char*)
resource
- one of the values in the tResourceType above (max value 51). instanceNumber
- an index that identifies the resource instance. context
- an optional additional context number for some cases (such as module
number). Set to 0 to omit. feature
- a string to be included describing features in use on a specific
resource. Setting the same resource more than once allows you to change
the feature string.public static void getControlWord(ControlWord controlWord)
public static AllianceStationID getAllianceStation()
public static short getJoystickAxes(byte joystickNum, float[] axesArray)
public static short getJoystickPOVs(byte joystickNum, short[] povsArray)
public static int getJoystickButtons(byte joystickNum, java.nio.ByteBuffer count)
public static int setJoystickOutputs(byte joystickNum, int outputs, short leftRumble, short rightRumble)
public static int getJoystickIsXbox(byte joystickNum)
public static int getJoystickType(byte joystickNum)
public static java.lang.String getJoystickName(byte joystickNum)
public static int getJoystickAxisType(byte joystickNum, byte axis)
public static double getMatchTime()
public static boolean getSystemActive()
public static boolean getBrownedOut()
public static int setErrorData(java.lang.String error)
public static int sendError(boolean isError, int errorCode, boolean isLVCode, java.lang.String details, java.lang.String location, java.lang.String callStack, boolean printMsg)