Created
May 15, 2017 21:34
-
-
Save xaxxontech/2c0c825354d8694443bada6940011f03 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import oculusprimesocket, time | |
# set reconnect (to run as daemon) | |
oculusprimesocket.reconnect = True | |
# connect to local Oculusprime java server | |
oculusprimesocket.connect() | |
while True: # loop forever | |
t = int(round(time.time() * 1000)) # time since epoch in milliseconds | |
oculusprimesocket.sendString("state lastusercommand "+str(t)) | |
time.sleep(60) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment