Module hid

Hid class

Functions

new (id, name, types, codes, dev) constructor
add (dev) static callback when any hid device is added; user scripts can redefine
remove (dev) static callback when any hid device is removed; user scripts can redefine
connect (n) create device, returns object with handler and send
cleanup () clear handlers


Functions

new (id, name, types, codes, dev)
constructor

Parameters:

  • id integer : arbitrary numeric identifier
  • name string : name
  • types string : array of supported event types. keys are type codes, values are strings
  • codes userdata : array of supported codes. each entry is a table of codes of a given type. subtables are indexed by supported code numbers; values are code names
  • dev userdata : opaque pointer to device
add (dev)
static callback when any hid device is added; user scripts can redefine

Parameters:

  • dev : a Hid table
remove (dev)
static callback when any hid device is removed; user scripts can redefine

Parameters:

  • dev : a Hid table
connect (n)
create device, returns object with handler and send

Parameters:

  • n
cleanup ()
clear handlers
generated by LDoc 1.4.6 Last updated 2019-11-14 23:40:48