Input Device Keyword
<InputDevice text [N1[,N2[,N3]]]>
<id text [N1[,N2[,N3]]]>
Parameter to select an input device. text must be the name of an existing installed DirectInput device (as enumerated by the TimeDX input test) or the name of one of the internal devices built into DMDX (see Input), such as
"PIO12" (the built in MetraByte PIO12 (or clone) interface), "DigitalVOX" or "RecordVocal" (see Audio Input). Once a device is selected there is no way to deselect it without starting a new item file which can be done with the
chain keyword, you can however unmap all the
devices' buttons with <UnMapButtons>.
Names with spaces in them must be in quotes.
A recent problem is devices having cute little symbols as
part of the name making it very hard to get the name of a device into an item
file. To combat this version 188.8.131.52 of DMDX dumps the names of available
input devices into the diagnostics, not only that it also checks a parsed
version of the name that has unusual characters removed from it that is also
printed in brackets.
can also be used to combat weird naming problems.
- If the name of the device is a DirectInput
device and includes a space as a number of devices do then text can be delimited with double quotes, "text name". If the device is a polled device (see Input) N1 specifies the number of milliseconds between polls when DMDX is
idling between jobs (usually waiting for a request), the default interval being 10ms. The second
specifies the time between polls when the clock is on (when a response is to be gathered), the default being 1ms for the PIO12 and 3ms for all other polled input devices.
- If the device is the DigitalVOX only one
parameter, N1, is applicable and that sets the Digital VOX's period (see Audio Input).
- The redesigned RecordVocal device
introduced in version 3.0.0.09 can now use two parameters. When used
without any parameters it runs in legacy mode where it records vocalizations
for the entire timeout period.
if used changes the length of data recorded to be N1
milliseconds longer than the trigger provided by the DigitalVox device.
Currently DMDX only records extra data for approximately the period specified.
The last parameter N2
determines how much overrun protection DMDX allows and is by default 50ms. I
didn't expect anyone would ever have to use this but it would appear that a
number of machines need 500ms of overrun protection so if your recordings are
getting chopped up then try a value of 500 for N2
(see the RecordVocal Notes). If you want RecordVocal to
run in legacy mode but need to lengthen the overrun protection specify N1
as zero. The new RecordVocal code can also be aborted with the
- In the case of the queued input devices (QPIO12
and so forth) the third parameter N3 increases the size of the queue used to buffer data. The default buffer is 16 entries long allowing for 16ms of buffering, some machines may require more buffering indicated by repeated PIO Polling FIFO full at time %dms error messages.
- Input device names mouse, keyboard and joystick can be prepended with a
#. Typically with
non-english input devices its best to use the
# versions of them instead of their named versions.
When a device is mapped this way button names are no longer used, button
numbers are used instead. Then you can use things like
<mr +#0> -- but be careful if you use
more than one
input device as you'll have two #0
buttons and won't be able to map buttons on the second device...
Certain devices come with preinstalled
button mappings, see Input and <MapRequest> etc.
Certain operating systems preclude the use of certain input devices. Most notably Windows NT (not that anyone would want to use DMDX under it), Windows 2000 and Windows XP preclude the use of devices that involve direct access to I/O ports. While InstaCal drivers can be installed and used for the PIO12 devices no such thing is available for the RawJoystick device.