public class OculusDiy extends Service implements OrientationListener
Modifier and Type | Field and Description |
---|---|
Arduino |
arduino |
static org.slf4j.Logger |
log |
Mpu6050 |
mpu6050 |
cfgDir, dnaPool, MESSAGE_RECORDING_FORMAT_BINARY, MESSAGE_RECORDING_FORMAT_XML
Constructor and Description |
---|
OculusDiy(java.lang.String n) |
Modifier and Type | Method and Description |
---|---|
void |
addOrientationListener(Service service) |
void |
calibrate() |
void |
computeAngles(java.lang.Double roll,
java.lang.Double pitch,
java.lang.Double yaw) |
void |
computeAnglesAndroid(float yaw,
float roll,
float pitch) |
void |
connect(java.lang.String port) |
Arduino |
getArduino() |
static ServiceType |
getMetaData()
This static method returns all the details of the class without it having
to be constructed.
|
static void |
main(java.lang.String[] args) |
Orientation |
onOrientation(Orientation orientation) |
Orientation |
Orientation(Orientation oculus) |
void |
releaseService()
Releases resources, and unregisters service from the runtime
|
void |
startService() |
addListener, addListener, addTask, addTask, addTask, addTaskOneShot, allowDisplay, allowDisplay, attach, attach, broadcastState, buildDna, buildDna, buildDnaKeys, buildDnaNames, clearLastError, close, containsTask, copyShallowFrom, createPeer, createPeer, createRootReserved, detach, detach, detach, echoHeartbeat, error, error, error, getAttached, getCfgDir, getComm, getDeclaredMethodNames, getDeclaredMethods, getDescription, getDna, getDnaString, getHostName, getInbox, getInstanceId, getIntanceName, getInterfaceSet, getLastError, getMessageSet, getMetaData, getMethodMap, getMethodNames, getMethods, getMethodToolTip, getMsg, getName, getNotifyList, getNotifyListKeySet, getOutbox, getPeerKey, getPeerName, getServiceResourceFile, getSimpleName, getTasks, getThisThread, getType, hasError, hasPeers, help, help, in, info, info, invoke, invoke, invoke, invokeOn, isAttached, isAttached, isLocal, isReady, isRunning, isRuntime, isVirtual, load, load, logTimeEnable, mergeDna, mergeDna, mergePeerDna, movePeerDna, out, out, preProcessHook, preRoutingHook, publishError, publishQueueStats, publishState, publishStats, publishStatus, purgeTask, purgeTasks, releasePeers, removeAllListeners, removeListener, requiresSecurity, reserve, reserve, reserveRoot, reserveRoot, reserveRootAs, run, save, save, save, send, send, send, send, sendBlocking, sendBlocking, sendBlocking, sendBlocking, sendPeer, setInstanceId, setName, setPeer, setSecurityProvider, setState, setThisThread, setVirtual, sleep, stackToString, startHeartbeat, startPeer, startPeer, startRecording, stopHeartbeat, stopMsgRecording, stopService, subscribe, subscribe, subscribe, toString, unsubscribe, unsubscribe, unsubscribe, updateStats, warn, warn
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
getName
public static final org.slf4j.Logger log
public transient Arduino arduino
public transient Mpu6050 mpu6050
public void calibrate()
public void computeAngles(java.lang.Double roll, java.lang.Double pitch, java.lang.Double yaw)
public void computeAnglesAndroid(float yaw, float roll, float pitch)
public Orientation Orientation(Orientation oculus)
public void addOrientationListener(Service service)
public void startService()
startService
in interface ServiceInterface
startService
in class Service
public Arduino getArduino()
public void connect(java.lang.String port) throws java.io.IOException
java.io.IOException
public static void main(java.lang.String[] args)
public void releaseService()
Service
releaseService
in interface ServiceInterface
releaseService
in class Service
public static ServiceType getMetaData()
public Orientation onOrientation(Orientation orientation)
onOrientation
in interface OrientationListener