|
j3d.org Code | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.j3d.device.input.spaceball.SpaceballTypeDetector
Class to automatically detect the type of the connected Spaceball device and instantiate the appropriate driver.
Currently Spaceball 2003, Spaceball 3003 and Spaceball 4000 are detected.
Spaceball, Spaceball 2003, Spaceball 3003 and Spaceball 4000 are Trademarks of Labtec Inc.
| Constructor Summary | |
SpaceballTypeDetector()
|
|
| Method Summary | |
static SpaceballDriver |
createSpaceballDriver(java.lang.String portDescriptor,
int timeout)
Creates the appropriate driver object, claims ownership over the port and opens it for reading and writing. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public SpaceballTypeDetector()
| Method Detail |
public static SpaceballDriver createSpaceballDriver(java.lang.String portDescriptor,
int timeout)
throws NoSuchPortException,
PortInUseException,
java.io.IOException,
UnsupportedCommOperationException
Blocking until response from the Spaceball device received or timeout period is over.
In order to receive data SpaceballDriver.enableDevice(int) must be
called.
portDescriptor - Must be a descriptor of a serial port.
For Windows 95 and Windows 98 the Java communications API will
always enumerate the serial ports COMM 1 through COMM 4 and the
parallel ports LPT1 and LPT2. For Windows NT the Java communications
API will enumerate the serial ports entered in the Registry and the
parallel port LPT1 and LPT2.
For Solaris the Java communications API enumerates both the actual
port names and the aliases to the ports.timeout - for the Spaceball device response
java.io.IOException - If the device could not be detected.
NoSuchPortException
PortInUseException
UnsupportedCommOperationException
|
j3d.org Code | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||