hidapi
(require hidapi) | package: hidapi |
This package provides bindings to hidapi library.
The library name is searched in the order:
"libhidapi" "libhidapi-libusb" "libhidapi-hidraw"
struct
(struct hid-device-info ( path vendor-id product-id serial-number release-number manufacturer-string product-string usage-page usage interface-number)) path : path? vendor-id : integer? product-id : integer? serial-number : string? release-number : integer? manufacturer-string : string? product-string : string? usage-page : integer? usage : integer? interface-number : integer?
procedure
(hid-device? d) → boolean?
d : any/c
procedure
(hid-enumerate [ #:vendor-id v #:product-id p]) → (listof hid-device-info?) v : integer? = 0 p : integer? = 0
procedure
(hid-open #:vendor-id v #:product-id p #:serial-number s) → (or/c hid-device? #f) v : integer? p : integer? s : string?
procedure
(hid-open-path p) → (or/c hid-device? #f)
p : path?
procedure
(hid-set-nonblocking d b) → void?
d : hid-device? b : boolean?
procedure
d : hid-device?
procedure
d : hid-device? bstr : bytes? size : integer?
procedure
(hid-write-full d bstr) → integer?
d : hid-device? bstr : bytes?
procedure
d : hid-device? bstr : bytes? size : integer?
procedure
(hid-read-bytes d size) → bytes?
d : hid-device? size : integer?
procedure
(hid-read-timeout d bstr size millis) → integer?
d : hid-device? bstr : bytes? size : integer? millis : integer?
procedure
(hid-read-bytes/timeout d size millis) → bytes?
d : hid-device? size : integer? millis : integer?
procedure
(hid-get-feature-report d bstr size) → integer?
d : hid-device? bstr : bytes? size : integer?
procedure
(hid-send-feature-report d bstr size) → integer?
d : hid-device? bstr : bytes? size : integer?
procedure
(hid-get-manufacturer-string d size) → string?
d : hid-device? size : integer?
procedure
(hid-get-product-string d size) → string?
d : hid-device? size : integer?
procedure
(hid-get-serial-number-string d size) → string?
d : hid-device? size : integer?
procedure
(hid-get-indexed-string d idx size) → string?
d : hid-device? idx : integer? size : integer?