#1
|
|||
|
|||
Joystick Nav Vizard4 vs Vizard 5
Hello there,
I recently updated to Vizard 5, but now the code I was using for my joystick no longer works. I've tried following the joystick instructions for Vizard 5, but I can get it the joystick to function like I need it to (i.e., like it did in Vizard 4). Any help would be appreciated. Thanks! The code I used in Vizard 4 is below. Vizard 5 gives the error "no module named sid": Code:
def mytimer(num): y = sid.get()[1] x = sid.get()[0] twist = (180.0 / math.pi) * (sid.aux()[3]) if math.fabs(y) > 0.5: viz.move(0,0,-y*.021) if math.fabs(x) > 0.5: viz.move(x*.021,0,0) if math.fabs(twist) > 20: viz.rotate(viz.BODY_ORI,twist/50.0,0,0) viz.callback(viz.TIMER_EVENT,mytimer) viz.starttimer(1,0.001,viz.FOREVER) viz.mouse.setOverride(viz.ON) |
Tags |
joystick, vizard 5.0 |
Thread Tools | |
Display Modes | Rate This Thread |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Realistic Light and Shadows Using Vizard and 3DS Max | jde | Vizard | 4 | 07-13-2012 10:58 AM |
joystick position | nmohandes | Vizard | 2 | 01-16-2012 10:03 AM |
Vizard 4 Beta Testing | farshizzo | Announcements | 0 | 02-01-2011 10:46 AM |
Vizard 4 Beta Testing | farshizzo | Vizard | 0 | 02-01-2011 10:46 AM |
Vizard tech tip: Using the Python Imaging Library (PIL) | Jeff | Vizard | 0 | 03-23-2009 11:13 AM |