M-File Help: joy2tr | View code for joy2tr

# joy2tr

Update transform from joystick

T = joy2tr(T, options) updates the homogeneous transform according to a connected joystick device.

## Options

'delay', D | Pause for D seconds after reading (default 0.1)
'scale', S | A 2-vector which scales joystick translational and rotational to rates (default [0.5m/s, 0.25rad/s])
'world' | Joystick motion is in the world frame
'tool' | Joystick motion is in the tool frame (default)
'rotate', R | Index of the button used to enable rotation (default 7)

## Notes

- Joystick axes 0,1,3 map to X,Y,Z or R,P,Y motion.
- A joystick button enables the mapping to translation OR rotation.
- A 'delay' of zero means no pause
- If 'delay' is non-zero 'scale' maps full scale to m/s or rad/s.
- If 'delay' is zero 'scale' maps full scale to m/sample or rad/sample.

© 1990-2014 Peter Corke.