Liking cljdoc? Tell your friends :D

web.usb.USB

The USB interface of the WebUSB API provides attributes and methods finding and connecting USB devices from a web page.

The USB interface of the WebUSB API provides attributes and methods
finding and connecting USB devices from a web page.
raw docstring

get-devicescljs

(get-devices this)

Method.

[Experimental]

The getDevices method of the web.usb.USB interface returns js.Promise that resolves with an array of web.usb.USBDevice for paired attached devices. For information on pairing devices, USB.requestDevice().

var promise[] = USB.getDevices();

See also: https://developer.mozilla.org/en-US/docs/Web/API/USB/getDevices

Method.

[Experimental]

The getDevices method of the `web.usb.USB` interface returns
`js.Promise` that resolves with an array of `web.usb.USBDevice`
for paired attached devices. For information on pairing devices,
`USB.requestDevice()`.

`var promise[] = USB.getDevices();`

See also: `https://developer.mozilla.org/en-US/docs/Web/API/USB/getDevices`
sourceraw docstring

onconnectcljs

(onconnect this)

Method.

[Experimental]

The onconnect property of the web.usb.USB interface is an event called whenever a paired device is connected.

USB.onconnect = connectFunction

See also: https://developer.mozilla.org/en-US/docs/Web/API/USB/onconnect

Method.

[Experimental]

The onconnect property of the `web.usb.USB` interface is an event
called whenever a paired device is connected.

`USB.onconnect = connectFunction`

See also: `https://developer.mozilla.org/en-US/docs/Web/API/USB/onconnect`
sourceraw docstring

ondisconnectcljs

(ondisconnect this)

Method.

[Experimental]

The ondisconnect property of the web.usb.USB is an event handler whenever a paired device is disconnected.

USB.ondisconnect = disconnectFunction

See also: https://developer.mozilla.org/en-US/docs/Web/API/USB/ondisconnect

Method.

[Experimental]

The ondisconnect property of the `web.usb.USB` is an event handler
whenever a paired device is disconnected.

`USB.ondisconnect = disconnectFunction`

See also: `https://developer.mozilla.org/en-US/docs/Web/API/USB/ondisconnect`
sourceraw docstring

request-devicecljs

(request-device this & args)

Method.

[Experimental]

The requestDevice() method of the web.usb.USB interface returns js.Promise that resolves with an instance of web.usb.USBDevice the specified device is found. Calling this function triggers user agent's pairing flow.

var promise = USB.requestDevice([filters])

See also: https://developer.mozilla.org/en-US/docs/Web/API/USB/requestDevice

Method.

[Experimental]

The requestDevice() method of the `web.usb.USB` interface returns
`js.Promise` that resolves with an instance of `web.usb.USBDevice`
the specified device is found. Calling this function triggers
user agent's pairing flow.

`var promise = USB.requestDevice([filters])`

See also: `https://developer.mozilla.org/en-US/docs/Web/API/USB/requestDevice`
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close