spaceball -
VRModules						          spaceball (6)


NAME
     spaceball - input module to read device events from a spaceball

SUMMARY
     Name	   spaceball

     Type	   input

     Inputs	   none

     Outputs	   field float 1D 1-space uniform
		   (VR device event field)

     Parameters	   _N_a_m_e		   _T_y_p_e		  _D_e_f_a_u_l_t	 _M_i_n	   _M_a_x
		   Sleep Control   boolean 	  off		 off	   on
		   Z onoff	   boolean	  on		 off	   on
		   Y onoff	   boolean	  on		 off	   on
		   X onoff	   boolean	  on		 off	   on
		   Rot Scale	   float dial	  1		 .001	   10
		   X displacement  boolean	  on		 off	   on
		   Y displacement  boolean	  on		 off	   on
		   X displacement  boolean	  on		 off	   on
		   Trans Scale	   float dial	  1		 .001	   1e5
		   Device Name	   string	  /dev/spaceball

DESCRIPTION

	The Spaceball module will read device events from a spaceball
	connected to the local machine, encode the information into an
	AVS field, and inject it into the network.

	The module is implemented as a coroutine, and as such is
	freely running.

INPUTS
	None


PARAMETERS
	Sleep control - a toggle which, when "off", will permit normal
	module execution.  When set to "on", the module goes to sleep, and
	the module will not execute.  This is a way to turn off the 
	spaceball.

	X onoff, Y onoff, Z onoff - these toggles permit the user to mask
	out portions of the rotation events generated by the spaceball.
	When a toggle is set to the "on" value, the corresponding rotation
	value is encoded into the output field.  This is a way to mask out
	rotation events on one or more axes.

	Rotation scale - a floating point value that will attenuate
	rotation events.  Increasing the value of this parm has the effect
	of increasing the sensitivity of the device.

	X displacement, Y displacement, Z displacement - toggles to mask out
	portions of the translational component of the device event.  When set
	to "on", the event is NOT masked out.

	Translation scale - a floating point value that will attenuate the
	translational component of the device event.  Increasing the value
	of this parm will have the effect of increasing the sensitivity of
	the device.

	Spaceball Device - a string indicating the device name, the port
	to which the spaceball is connected.  You should probably create
	a link from /dev/spaceball to point to the serial port on your
	machine so you don't have to monkey with this parm.

OUTPUT
     	field float 1D 1-space uniform - VR device event field.  A set
	of C-language macros is used internal to the code for this 
	module to encode the device event information into an AVS
	field.  This field is not readily processible (unfortunately)
	by "normal" AVS modules.  This is the case because both
	floating point and boolean values are encoded into the field data.
	

EXAMPLE
	spaceball
	    |
	VR Xform Camera
            |
	Geoemtry Viewer

RELATED	MODULES
	VR Transform Camera, VR Transform Object, VR to acc floats,
	VR to floats, dummy device, VR print field.

BUGS
	1 March 1995
	I've had problems with mysterious hangs under OSF 2 and greater.
	The fix will be not to this module, but to the underlying
	spaceball i/o code.  When using AVS, the only recovery that I'm
	aware of to these hangs is to hammer the module, power-cycle the
	spaceball, then instantiate a fresh copy of the spaceball module.



VRModules					  Lawrence Berkeley Laboratory
