Package edu.wpi.first.hal.simulation
Class SimDeviceDataJNI
java.lang.Object
edu.wpi.first.hal.JNIWrapper
edu.wpi.first.hal.simulation.SimDeviceDataJNI
public class SimDeviceDataJNI extends JNIWrapper
JNI for sim device data.
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
SimDeviceDataJNI.SimDeviceInfo
static class
SimDeviceDataJNI.SimValueInfo
-
Method Summary
Modifier and Type Method Description static void
cancelSimDeviceCreatedCallback(int uid)
static void
cancelSimDeviceFreedCallback(int uid)
static void
cancelSimValueChangedCallback(int uid)
static void
cancelSimValueCreatedCallback(int uid)
static void
cancelSimValueResetCallback(int uid)
static SimDeviceDataJNI.SimDeviceInfo[]
enumerateSimDevices(String prefix)
static SimDeviceDataJNI.SimValueInfo[]
enumerateSimValues(int device)
static int
getSimDeviceHandle(String name)
static String
getSimDeviceName(int handle)
static int
getSimValueDeviceHandle(int handle)
static double[]
getSimValueEnumDoubleValues(int handle)
static String[]
getSimValueEnumOptions(int handle)
static int
getSimValueHandle(int device, String name)
static boolean
isSimDeviceEnabled(String name)
static int
registerSimDeviceCreatedCallback(String prefix, SimDeviceCallback callback, boolean initialNotify)
static int
registerSimDeviceFreedCallback(String prefix, SimDeviceCallback callback, boolean initialNotify)
static int
registerSimValueChangedCallback(int handle, SimValueCallback callback, boolean initialNotify)
static int
registerSimValueCreatedCallback(int device, SimValueCallback callback, boolean initialNotify)
static int
registerSimValueResetCallback(int handle, SimValueCallback callback, boolean initialNotify)
Register a callback for SimDeviceJNI.resetSimValue().static void
resetSimDeviceData()
static void
setSimDeviceEnabled(String prefix, boolean enabled)
-
Method Details
-
setSimDeviceEnabled
-
isSimDeviceEnabled
-
registerSimDeviceCreatedCallback
public static int registerSimDeviceCreatedCallback(String prefix, SimDeviceCallback callback, boolean initialNotify) -
cancelSimDeviceCreatedCallback
-
registerSimDeviceFreedCallback
public static int registerSimDeviceFreedCallback(String prefix, SimDeviceCallback callback, boolean initialNotify) -
cancelSimDeviceFreedCallback
-
getSimDeviceHandle
-
getSimDeviceName
-
getSimValueDeviceHandle
-
enumerateSimDevices
-
registerSimValueCreatedCallback
public static int registerSimValueCreatedCallback(int device, SimValueCallback callback, boolean initialNotify) -
cancelSimValueCreatedCallback
-
registerSimValueChangedCallback
public static int registerSimValueChangedCallback(int handle, SimValueCallback callback, boolean initialNotify) -
cancelSimValueChangedCallback
-
registerSimValueResetCallback
public static int registerSimValueResetCallback(int handle, SimValueCallback callback, boolean initialNotify)Register a callback for SimDeviceJNI.resetSimValue(). The callback is called with the old value.- Parameters:
handle
- simulated value handlecallback
- callbackinitialNotify
- ignored (present for consistency)- Returns:
- TODO
-
cancelSimValueResetCallback
-
getSimValueHandle
-
enumerateSimValues
-
getSimValueEnumOptions
-
getSimValueEnumDoubleValues
-
resetSimDeviceData
-