biomech_dave
09-09-2016, 04:12 PM
Hello! I'm using the Vive for proprioceptive reseach and need to get the coordinates of the controllers. I am new to Python but I tried manipulating the steamvr example like this:
import viz
import vizact
import vizshape
import steamvr
for controller in steamvr.getControllerList():
print "connected"
total = 0
if total == 0:
left_controller = controller
total += 1
else:
right_controller = controller
print right_controller.getPosition()
I get an error that 'right_controller' is not defines. I'd like to get the Euler angle and position output continuously while the programming is running. Any thoughts would be helpful.
Thanks!
Dave
import viz
import vizact
import vizshape
import steamvr
for controller in steamvr.getControllerList():
print "connected"
total = 0
if total == 0:
left_controller = controller
total += 1
else:
right_controller = controller
print right_controller.getPosition()
I get an error that 'right_controller' is not defines. I'd like to get the Euler angle and position output continuously while the programming is running. Any thoughts would be helpful.
Thanks!
Dave