Detect input devices and start Input Manager
inputtrap [-f device] [-k] [-l device] [-s] [-V...] [-v...] [-X class]... [-x device]... [start|query]
The inputtrap utility probes for input devices and writes invocation commands along with the appropriate options and arguments for starting the found devices to the /etc/config/trap/input.node file. The probing order is as follows:
The device names (given above) are recognized as arguments to -f and -x.
If a /etc/config/trap/input.node file exists, inputtrap uses the contents of this file as arguments to Input.
Although Photon supports the following input hardware drivers, inputtrap doesn't detect all of the associated hardware devices:
Driver module | Detected? |
---|---|
ahl | no |
airmse | yes |
busmse | yes |
carrol | bus interface adapters only |
compaq | no |
cyber | no |
devmse | yes |
dyna | no |
gm | no |
intellitch | bus interface adapters only |
kbd | yes |
microtch | no |
msoft | yes |
msys | yes |
ps2 | yes |
smartset | bus interface adapters only |
wacom | no |
If inputtrap can't find your device, see "Setting up a pointing device" in the Configuring Photon chapter.
Do a check for input devices. Once one of each class of device has been recognized, spawn Input with an appropriate command line:
inputtrap
The first device for each class of device recognized will be chosen (recognized classes are keyboard, relative, and absolute coordinate pointing devices). If a pointing device manager is running (i.e. /dev/touch or /dev/mouse exists), then assume this resource manager is properly configured - use its pointing devices and terminate probing.
The presence of /dev/kbd will not terminate probing. |
Do a check (as above) for pointing devices. Don't start the driver, but print the command line required to start the driver:
inputtrap query
Do a check (as above) for input devices, starting with a check for a UART-based pointing device. This can be useful when you want a serial device to be detected instead of a builtin pointing device (e.g. on laptops and notebooks with builtin PS/2-style mice):
inputtrap -f uart start
Given the following /etc/config/trap/input.node file:
kbd fd -d/dev/kbd intellitch -z uart -2
running inputtrap start will start Input with an fd-based keyboard and an intellitch protocol, getting its input directly from a UART on COM port 2 (port 2f8 IRQ 3).
Adding invalid information to the input.node file can cause the system to hang. If your hardware changes, remember to remove the old input.node file. |