usb 2.0.0-alpha.2 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.gitmodules +1 -1
- package/CHANGELOG.md +100 -0
- package/README.md +573 -0
- package/binding.gyp +12 -2
- package/dist/index.d.ts +4 -4
- package/dist/index.js +14 -8
- package/dist/index.js.map +1 -1
- package/dist/usb/bindings.d.ts +13 -0
- package/dist/usb/bindings.js +2 -1
- package/dist/usb/bindings.js.map +1 -1
- package/dist/usb/index.js +86 -2
- package/dist/usb/index.js.map +1 -1
- package/dist/usb/interface.js.map +1 -1
- package/dist/webusb/index.d.ts +32 -19
- package/dist/webusb/index.js +163 -67
- package/dist/webusb/index.js.map +1 -1
- package/dist/webusb/webusb-device.d.ts +1 -1
- package/dist/webusb/webusb-device.js +27 -15
- package/dist/webusb/webusb-device.js.map +1 -1
- package/libusb/.private/pre-commit.sh +7 -1
- package/libusb/.travis.yml +49 -0
- package/libusb/AUTHORS +44 -3
- package/libusb/Brewfile +4 -0
- package/libusb/ChangeLog +74 -2
- package/libusb/README.md +32 -0
- package/libusb/TODO +1 -1
- package/libusb/Xcode/common.xcconfig +12 -0
- package/libusb/Xcode/config.h +25 -0
- package/libusb/Xcode/libusb.xcodeproj/project.pbxproj +959 -1
- package/libusb/android/README +4 -2
- package/libusb/android/config.h +75 -0
- package/libusb/appveyor.yml +41 -0
- package/libusb/appveyor_cygwin.bat +11 -0
- package/libusb/appveyor_minGW.bat +19 -0
- package/libusb/autogen.sh +1 -1
- package/libusb/bootstrap.sh +3 -16
- package/libusb/configure.ac +108 -80
- package/libusb/doc/doxygen.cfg.in +1785 -739
- package/libusb/examples/Makefile.am +1 -1
- package/libusb/examples/dpfp.c +3 -1
- package/libusb/examples/dpfp_threaded.c +23 -10
- package/libusb/examples/ezusb.c +3 -3
- package/libusb/examples/ezusb.h +2 -2
- package/libusb/examples/fxload.c +31 -9
- package/libusb/examples/hotplugtest.c +35 -7
- package/libusb/examples/listdevs.c +3 -1
- package/libusb/examples/sam3u_benchmark.c +3 -3
- package/libusb/examples/testlibusb.c +277 -0
- package/libusb/examples/xusb.c +40 -34
- package/libusb/libusb/Makefile.am +49 -23
- package/libusb/libusb/core.c +855 -457
- package/libusb/libusb/descriptor.c +72 -78
- package/libusb/libusb/hotplug.c +122 -76
- package/libusb/libusb/hotplug.h +42 -25
- package/libusb/libusb/io.c +625 -390
- package/libusb/libusb/libusb-1.0.def +12 -0
- package/libusb/libusb/libusb.h +218 -150
- package/libusb/libusb/libusbi.h +346 -176
- package/libusb/libusb/os/darwin_usb.c +604 -319
- package/libusb/libusb/os/darwin_usb.h +61 -20
- package/libusb/libusb/os/haiku_pollfs.cpp +367 -0
- package/libusb/libusb/os/haiku_usb.h +113 -0
- package/libusb/libusb/os/haiku_usb_backend.cpp +533 -0
- package/libusb/libusb/os/haiku_usb_raw.cpp +267 -0
- package/libusb/libusb/os/haiku_usb_raw.h +188 -0
- package/libusb/libusb/os/linux_netlink.c +186 -146
- package/libusb/libusb/os/linux_udev.c +36 -14
- package/libusb/libusb/os/linux_usbfs.c +426 -225
- package/libusb/libusb/os/linux_usbfs.h +5 -3
- package/libusb/libusb/os/netbsd_usb.c +21 -77
- package/libusb/libusb/os/openbsd_usb.c +32 -115
- package/libusb/libusb/os/poll_posix.c +38 -5
- package/libusb/libusb/os/poll_posix.h +3 -0
- package/libusb/libusb/os/poll_windows.c +277 -626
- package/libusb/libusb/os/poll_windows.h +11 -44
- package/libusb/libusb/os/sunos_usb.c +1695 -0
- package/libusb/libusb/os/sunos_usb.h +80 -0
- package/libusb/libusb/os/threads_posix.c +24 -26
- package/libusb/libusb/os/threads_posix.h +73 -21
- package/libusb/libusb/os/threads_windows.c +71 -157
- package/libusb/libusb/os/threads_windows.h +68 -44
- package/libusb/libusb/os/wince_usb.c +276 -420
- package/libusb/libusb/os/wince_usb.h +23 -28
- package/libusb/libusb/os/windows_common.h +78 -58
- package/libusb/libusb/os/windows_nt_common.c +1010 -0
- package/libusb/libusb/os/windows_nt_common.h +110 -0
- package/libusb/libusb/os/windows_nt_shared_types.h +147 -0
- package/libusb/libusb/os/windows_usbdk.c +830 -0
- package/libusb/libusb/os/windows_usbdk.h +103 -0
- package/libusb/libusb/os/windows_winusb.c +4391 -0
- package/libusb/libusb/os/windows_winusb.h +783 -0
- package/libusb/libusb/strerror.c +41 -7
- package/libusb/libusb/sync.c +41 -13
- package/libusb/libusb/version.h +1 -1
- package/libusb/libusb/version_nano.h +1 -1
- package/libusb/libusb-1.0.pc.in +1 -1
- package/libusb/msvc/appveyor.bat +27 -0
- package/libusb/msvc/config.h +5 -4
- package/libusb/msvc/ddk_build.cmd +87 -43
- package/libusb/msvc/fxload_2010.vcxproj +24 -104
- package/libusb/msvc/fxload_2012.vcxproj +24 -107
- package/libusb/msvc/fxload_2013.vcxproj +24 -107
- package/libusb/msvc/fxload_2015.vcxproj +91 -0
- package/libusb/msvc/fxload_2017.vcxproj +114 -0
- package/libusb/msvc/fxload_sources +1 -1
- package/libusb/msvc/getopt_2010.vcxproj +16 -75
- package/libusb/msvc/getopt_2012.vcxproj +16 -79
- package/libusb/msvc/getopt_2013.vcxproj +16 -79
- package/libusb/msvc/getopt_2015.vcxproj +73 -0
- package/libusb/msvc/getopt_2017.vcxproj +98 -0
- package/libusb/msvc/getopt_sources +6 -2
- package/libusb/msvc/hotplugtest_2010.vcxproj +18 -99
- package/libusb/msvc/hotplugtest_2012.vcxproj +18 -102
- package/libusb/msvc/hotplugtest_2013.vcxproj +18 -102
- package/libusb/msvc/hotplugtest_2015.vcxproj +83 -0
- package/libusb/msvc/hotplugtest_2017.vcxproj +106 -0
- package/libusb/msvc/hotplugtest_sources +1 -1
- package/libusb/msvc/libusb_2005.sln +20 -20
- package/libusb/msvc/libusb_2010.sln +57 -46
- package/libusb/msvc/libusb_2012.sln +57 -46
- package/libusb/msvc/libusb_2013.sln +57 -50
- package/libusb/msvc/libusb_2015.sln +59 -52
- package/libusb/msvc/libusb_2017.sln +186 -0
- package/libusb/msvc/libusb_dll.dsp +2 -2
- package/libusb/msvc/libusb_dll_2005.vcproj +30 -2
- package/libusb/msvc/libusb_dll_2010.vcxproj +26 -90
- package/libusb/msvc/libusb_dll_2012.vcxproj +28 -96
- package/libusb/msvc/libusb_dll_2013.vcxproj +28 -96
- package/libusb/msvc/libusb_dll_2015.vcxproj +107 -0
- package/libusb/msvc/libusb_dll_2017.vcxproj +134 -0
- package/libusb/msvc/libusb_dll_wince.vcproj +9 -1
- package/libusb/msvc/libusb_sources +10 -5
- package/libusb/msvc/libusb_static.dsp +2 -2
- package/libusb/msvc/libusb_static_2005.vcproj +32 -4
- package/libusb/msvc/libusb_static_2010.vcxproj +24 -83
- package/libusb/msvc/libusb_static_2012.vcxproj +25 -87
- package/libusb/msvc/libusb_static_2013.vcxproj +25 -87
- package/libusb/msvc/libusb_static_2015.vcxproj +98 -0
- package/libusb/msvc/libusb_static_2017.vcxproj +117 -0
- package/libusb/msvc/libusb_static_wince.vcproj +20 -26
- package/libusb/msvc/libusb_wince.sln +88 -88
- package/libusb/msvc/listdevs_2010.vcxproj +16 -99
- package/libusb/msvc/listdevs_2012.vcxproj +16 -102
- package/libusb/msvc/listdevs_2013.vcxproj +16 -102
- package/libusb/msvc/listdevs_2015.vcxproj +83 -0
- package/libusb/msvc/listdevs_2017.vcxproj +106 -0
- package/libusb/msvc/listdevs_sources +2 -1
- package/libusb/msvc/stress_2010.vcxproj +20 -101
- package/libusb/msvc/stress_2012.vcxproj +20 -104
- package/libusb/msvc/stress_2013.vcxproj +20 -104
- package/libusb/msvc/stress_2015.vcxproj +87 -0
- package/libusb/msvc/stress_2017.vcxproj +110 -0
- package/libusb/msvc/stress_sources +21 -0
- package/libusb/msvc/testlibusb_2010.vcxproj +82 -0
- package/libusb/msvc/testlibusb_2012.vcxproj +83 -0
- package/libusb/msvc/testlibusb_2013.vcxproj +83 -0
- package/libusb/msvc/testlibusb_2015.vcxproj +83 -0
- package/libusb/msvc/testlibusb_2017.vcxproj +106 -0
- package/libusb/msvc/testlibusb_sources +20 -0
- package/libusb/msvc/xusb_2010.vcxproj +17 -98
- package/libusb/msvc/xusb_2012.vcxproj +17 -101
- package/libusb/msvc/xusb_2013.vcxproj +17 -101
- package/libusb/msvc/xusb_2015.vcxproj +83 -0
- package/libusb/msvc/xusb_2017.vcxproj +106 -0
- package/libusb/msvc/xusb_sources +1 -1
- package/libusb/tests/stress.c +2 -2
- package/libusb/tests/testlib.c +0 -4
- package/libusb/travis-autogen.sh +39 -0
- package/libusb.gypi +21 -2
- package/package.json +18 -13
- package/prebuilds/android-arm/node.napi.node +0 -0
- package/prebuilds/android-arm64/node.napi.node +0 -0
- package/prebuilds/darwin-x64+arm64/node.napi.node +0 -0
- package/prebuilds/linux-arm/node.napi.node +0 -0
- package/prebuilds/linux-arm64/node.napi.node +0 -0
- package/prebuilds/linux-ia32/node.napi.node +0 -0
- package/prebuilds/linux-x64/node.napi.node +0 -0
- package/prebuilds/win32-ia32/node.napi.node +0 -0
- package/prebuilds/win32-x64/node.napi.node +0 -0
- package/src/device.cc +7 -7
- package/src/node_usb.cc +43 -1
- package/src/node_usb.h +1 -0
- package/src/uv_async_queue.h +33 -25
- package/test/usb.coffee +6 -0
- package/tsc/index.ts +13 -7
- package/tsc/usb/bindings.ts +19 -1
- package/tsc/usb/index.ts +67 -19
- package/tsc/usb/interface.ts +2 -2
- package/tsc/webusb/index.ts +197 -74
- package/tsc/webusb/webusb-device.ts +30 -17
- package/.github/workflows/prebuild.yml +0 -48
- package/Readme.md +0 -339
- package/dist/webusb/typed-event-target.d.ts +0 -11
- package/dist/webusb/typed-event-target.js +0 -21
- package/dist/webusb/typed-event-target.js.map +0 -1
- package/docs/assets/css/main.css +0 -2660
- package/docs/assets/images/icons.png +0 -0
- package/docs/assets/images/icons@2x.png +0 -0
- package/docs/assets/images/widgets.png +0 -0
- package/docs/assets/images/widgets@2x.png +0 -0
- package/docs/assets/js/main.js +0 -248
- package/docs/assets/js/search.js +0 -1
- package/docs/classes/usb_bindings.device.html +0 -1338
- package/docs/classes/usb_bindings.libusbexception.html +0 -234
- package/docs/classes/usb_bindings.transfer.html +0 -344
- package/docs/classes/usb_capability.capability.html +0 -297
- package/docs/classes/usb_device.extendeddevice.html +0 -766
- package/docs/classes/usb_endpoint.endpoint.html +0 -472
- package/docs/classes/usb_endpoint.inendpoint.html +0 -766
- package/docs/classes/usb_endpoint.outendpoint.html +0 -582
- package/docs/classes/usb_interface.interface.html +0 -648
- package/docs/classes/webusb.webusb-1.html +0 -615
- package/docs/classes/webusb_mutex.mutex.html +0 -270
- package/docs/classes/webusb_typed_event_target.typedeventtarget.html +0 -443
- package/docs/classes/webusb_webusb_device.webusbdevice.html +0 -904
- package/docs/index.html +0 -500
- package/docs/interfaces/usb.deviceevents.html +0 -242
- package/docs/interfaces/usb_descriptors.bosdescriptor.html +0 -293
- package/docs/interfaces/usb_descriptors.capabilitydescriptor.html +0 -274
- package/docs/interfaces/usb_descriptors.configdescriptor.html +0 -388
- package/docs/interfaces/usb_descriptors.devicedescriptor.html +0 -464
- package/docs/interfaces/usb_descriptors.endpointdescriptor.html +0 -370
- package/docs/interfaces/usb_descriptors.interfacedescriptor.html +0 -407
- package/docs/interfaces/webusb.usboptions.html +0 -226
- package/docs/modules/index.html +0 -304
- package/docs/modules/usb.html +0 -173
- package/docs/modules/usb_bindings.html +0 -2248
- package/docs/modules/usb_capability.html +0 -156
- package/docs/modules/usb_descriptors.html +0 -176
- package/docs/modules/usb_device.html +0 -156
- package/docs/modules/usb_endpoint.html +0 -164
- package/docs/modules/usb_interface.html +0 -156
- package/docs/modules/webusb.html +0 -165
- package/docs/modules/webusb_mutex.html +0 -156
- package/docs/modules/webusb_typed_event_target.html +0 -156
- package/docs/modules/webusb_webusb_device.html +0 -156
- package/docs/modules.html +0 -156
- package/libusb/INSTALL +0 -234
- package/libusb/README +0 -28
- package/libusb/libusb/os/windows_usb.c +0 -5347
- package/libusb/libusb/os/windows_usb.h +0 -971
- package/libusb/msvc/fxload_2010.vcxproj.filters +0 -25
- package/libusb/msvc/fxload_2012.vcxproj.filters +0 -25
- package/libusb/msvc/getopt_2010.vcxproj.filters +0 -26
- package/libusb/msvc/getopt_2012.vcxproj.filters +0 -26
- package/libusb/msvc/hotplugtest_2010.vcxproj.filters +0 -14
- package/libusb/msvc/hotplugtest_2012.vcxproj.filters +0 -14
- package/libusb/msvc/libusb_dll_2010.vcxproj.filters +0 -81
- package/libusb/msvc/libusb_dll_2012.vcxproj.filters +0 -84
- package/libusb/msvc/libusb_static_2010.vcxproj.filters +0 -74
- package/libusb/msvc/libusb_static_2012.vcxproj.filters +0 -74
- package/libusb/msvc/listdevs_2010.vcxproj.filters +0 -14
- package/libusb/msvc/listdevs_2012.vcxproj.filters +0 -14
- package/libusb/msvc/stress_2010.vcxproj.filters +0 -25
- package/libusb/msvc/stress_2012.vcxproj.filters +0 -25
- package/libusb/msvc/xusb_2010.vcxproj.filters +0 -14
- package/libusb/msvc/xusb_2012.vcxproj.filters +0 -14
- package/tsc/webusb/typed-event-target.ts +0 -23
|
@@ -1,648 +0,0 @@
|
|
|
1
|
-
<!doctype html>
|
|
2
|
-
<html class="default no-js">
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="utf-8">
|
|
5
|
-
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
6
|
-
<title>Interface | Node USB</title>
|
|
7
|
-
<meta name="description" content="Documentation for Node USB">
|
|
8
|
-
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
9
|
-
<link rel="stylesheet" href="../assets/css/main.css">
|
|
10
|
-
<script async src="../assets/js/search.js" id="search-script"></script>
|
|
11
|
-
</head>
|
|
12
|
-
<body>
|
|
13
|
-
<header>
|
|
14
|
-
<div class="tsd-page-toolbar">
|
|
15
|
-
<div class="container">
|
|
16
|
-
<div class="table-wrap">
|
|
17
|
-
<div class="table-cell" id="tsd-search" data-index="../assets/js/search.json" data-base="..">
|
|
18
|
-
<div class="field">
|
|
19
|
-
<label for="tsd-search-field" class="tsd-widget search no-caption">Search</label>
|
|
20
|
-
<input id="tsd-search-field" type="text" />
|
|
21
|
-
</div>
|
|
22
|
-
<ul class="results">
|
|
23
|
-
<li class="state loading">Preparing search index...</li>
|
|
24
|
-
<li class="state failure">The search index is not available</li>
|
|
25
|
-
</ul>
|
|
26
|
-
<a href="../index.html" class="title">Node USB</a>
|
|
27
|
-
</div>
|
|
28
|
-
<div class="table-cell" id="tsd-widgets">
|
|
29
|
-
<div id="tsd-filter">
|
|
30
|
-
<a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a>
|
|
31
|
-
<div class="tsd-filter-group">
|
|
32
|
-
<div class="tsd-select" id="tsd-filter-visibility">
|
|
33
|
-
<span class="tsd-select-label">All</span>
|
|
34
|
-
<ul class="tsd-select-list">
|
|
35
|
-
<li data-value="public">Public</li>
|
|
36
|
-
<li data-value="protected">Public/Protected</li>
|
|
37
|
-
<li data-value="private" class="selected">All</li>
|
|
38
|
-
</ul>
|
|
39
|
-
</div>
|
|
40
|
-
<input type="checkbox" id="tsd-filter-inherited" checked />
|
|
41
|
-
<label class="tsd-widget" for="tsd-filter-inherited">Inherited</label>
|
|
42
|
-
</div>
|
|
43
|
-
</div>
|
|
44
|
-
<a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a>
|
|
45
|
-
</div>
|
|
46
|
-
</div>
|
|
47
|
-
</div>
|
|
48
|
-
</div>
|
|
49
|
-
<div class="tsd-page-title">
|
|
50
|
-
<div class="container">
|
|
51
|
-
<ul class="tsd-breadcrumb">
|
|
52
|
-
<li>
|
|
53
|
-
<a href="../modules.html">Node USB</a>
|
|
54
|
-
</li>
|
|
55
|
-
<li>
|
|
56
|
-
<a href="../modules/usb_interface.html">usb/interface</a>
|
|
57
|
-
</li>
|
|
58
|
-
<li>
|
|
59
|
-
<a href="usb_interface.interface.html">Interface</a>
|
|
60
|
-
</li>
|
|
61
|
-
</ul>
|
|
62
|
-
<h1>Class Interface</h1>
|
|
63
|
-
</div>
|
|
64
|
-
</div>
|
|
65
|
-
</header>
|
|
66
|
-
<div class="container container-main">
|
|
67
|
-
<div class="row">
|
|
68
|
-
<div class="col-8 col-content">
|
|
69
|
-
<section class="tsd-panel tsd-hierarchy">
|
|
70
|
-
<h3>Hierarchy</h3>
|
|
71
|
-
<ul class="tsd-hierarchy">
|
|
72
|
-
<li>
|
|
73
|
-
<span class="target">Interface</span>
|
|
74
|
-
</li>
|
|
75
|
-
</ul>
|
|
76
|
-
</section>
|
|
77
|
-
<section class="tsd-panel-group tsd-index-group">
|
|
78
|
-
<h2>Index</h2>
|
|
79
|
-
<section class="tsd-panel tsd-index-panel">
|
|
80
|
-
<div class="tsd-index-content">
|
|
81
|
-
<section class="tsd-index-section ">
|
|
82
|
-
<h3>Constructors</h3>
|
|
83
|
-
<ul class="tsd-index-list">
|
|
84
|
-
<li class="tsd-kind-constructor tsd-parent-kind-class"><a href="usb_interface.interface.html#constructor" class="tsd-kind-icon">constructor</a></li>
|
|
85
|
-
</ul>
|
|
86
|
-
</section>
|
|
87
|
-
<section class="tsd-index-section ">
|
|
88
|
-
<h3>Properties</h3>
|
|
89
|
-
<ul class="tsd-index-list">
|
|
90
|
-
<li class="tsd-kind-property tsd-parent-kind-class"><a href="usb_interface.interface.html#altsetting" class="tsd-kind-icon">alt<wbr>Setting</a></li>
|
|
91
|
-
<li class="tsd-kind-property tsd-parent-kind-class"><a href="usb_interface.interface.html#descriptor" class="tsd-kind-icon">descriptor</a></li>
|
|
92
|
-
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><a href="usb_interface.interface.html#device" class="tsd-kind-icon">device</a></li>
|
|
93
|
-
<li class="tsd-kind-property tsd-parent-kind-class"><a href="usb_interface.interface.html#endpoints" class="tsd-kind-icon">endpoints</a></li>
|
|
94
|
-
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><a href="usb_interface.interface.html#id" class="tsd-kind-icon">id</a></li>
|
|
95
|
-
<li class="tsd-kind-property tsd-parent-kind-class"><a href="usb_interface.interface.html#interfacenumber" class="tsd-kind-icon">interface<wbr>Number</a></li>
|
|
96
|
-
</ul>
|
|
97
|
-
</section>
|
|
98
|
-
<section class="tsd-index-section ">
|
|
99
|
-
<h3>Methods</h3>
|
|
100
|
-
<ul class="tsd-index-list">
|
|
101
|
-
<li class="tsd-kind-method tsd-parent-kind-class"><a href="usb_interface.interface.html#attachkerneldriver" class="tsd-kind-icon">attach<wbr>Kernel<wbr>Driver</a></li>
|
|
102
|
-
<li class="tsd-kind-method tsd-parent-kind-class"><a href="usb_interface.interface.html#claim" class="tsd-kind-icon">claim</a></li>
|
|
103
|
-
<li class="tsd-kind-method tsd-parent-kind-class"><a href="usb_interface.interface.html#detachkerneldriver" class="tsd-kind-icon">detach<wbr>Kernel<wbr>Driver</a></li>
|
|
104
|
-
<li class="tsd-kind-method tsd-parent-kind-class"><a href="usb_interface.interface.html#endpoint" class="tsd-kind-icon">endpoint</a></li>
|
|
105
|
-
<li class="tsd-kind-method tsd-parent-kind-class"><a href="usb_interface.interface.html#iskerneldriveractive" class="tsd-kind-icon">is<wbr>Kernel<wbr>Driver<wbr>Active</a></li>
|
|
106
|
-
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected"><a href="usb_interface.interface.html#refresh" class="tsd-kind-icon">refresh</a></li>
|
|
107
|
-
<li class="tsd-kind-method tsd-parent-kind-class"><a href="usb_interface.interface.html#release" class="tsd-kind-icon">release</a></li>
|
|
108
|
-
<li class="tsd-kind-method tsd-parent-kind-class"><a href="usb_interface.interface.html#setaltsetting" class="tsd-kind-icon">set<wbr>Alt<wbr>Setting</a></li>
|
|
109
|
-
</ul>
|
|
110
|
-
</section>
|
|
111
|
-
</div>
|
|
112
|
-
</section>
|
|
113
|
-
</section>
|
|
114
|
-
<section class="tsd-panel-group tsd-member-group ">
|
|
115
|
-
<h2>Constructors</h2>
|
|
116
|
-
<section class="tsd-panel tsd-member tsd-kind-constructor tsd-parent-kind-class">
|
|
117
|
-
<a name="constructor" class="tsd-anchor"></a>
|
|
118
|
-
<h3>constructor</h3>
|
|
119
|
-
<ul class="tsd-signatures tsd-kind-constructor tsd-parent-kind-class">
|
|
120
|
-
<li class="tsd-signature tsd-kind-icon">new <wbr>Interface<span class="tsd-signature-symbol">(</span>device<span class="tsd-signature-symbol">: </span><a href="usb_bindings.device.html" class="tsd-signature-type" data-tsd-kind="Class">Device</a>, id<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="usb_interface.interface.html" class="tsd-signature-type" data-tsd-kind="Class">Interface</a></li>
|
|
121
|
-
</ul>
|
|
122
|
-
<ul class="tsd-descriptions">
|
|
123
|
-
<li class="tsd-description">
|
|
124
|
-
<aside class="tsd-sources">
|
|
125
|
-
<ul>
|
|
126
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L16">tsc/usb/interface.ts:16</a></li>
|
|
127
|
-
</ul>
|
|
128
|
-
</aside>
|
|
129
|
-
<h4 class="tsd-parameters-title">Parameters</h4>
|
|
130
|
-
<ul class="tsd-parameters">
|
|
131
|
-
<li>
|
|
132
|
-
<h5>device: <a href="usb_bindings.device.html" class="tsd-signature-type" data-tsd-kind="Class">Device</a></h5>
|
|
133
|
-
</li>
|
|
134
|
-
<li>
|
|
135
|
-
<h5>id: <span class="tsd-signature-type">number</span></h5>
|
|
136
|
-
</li>
|
|
137
|
-
</ul>
|
|
138
|
-
<h4 class="tsd-returns-title">Returns <a href="usb_interface.interface.html" class="tsd-signature-type" data-tsd-kind="Class">Interface</a></h4>
|
|
139
|
-
</li>
|
|
140
|
-
</ul>
|
|
141
|
-
</section>
|
|
142
|
-
</section>
|
|
143
|
-
<section class="tsd-panel-group tsd-member-group ">
|
|
144
|
-
<h2>Properties</h2>
|
|
145
|
-
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
|
|
146
|
-
<a name="altsetting" class="tsd-anchor"></a>
|
|
147
|
-
<h3>alt<wbr>Setting</h3>
|
|
148
|
-
<div class="tsd-signature tsd-kind-icon">alt<wbr>Setting<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> = 0</span></div>
|
|
149
|
-
<aside class="tsd-sources">
|
|
150
|
-
<ul>
|
|
151
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L10">tsc/usb/interface.ts:10</a></li>
|
|
152
|
-
</ul>
|
|
153
|
-
</aside>
|
|
154
|
-
<div class="tsd-comment tsd-typography">
|
|
155
|
-
<div class="lead">
|
|
156
|
-
<p>Integer alternate setting number.</p>
|
|
157
|
-
</div>
|
|
158
|
-
</div>
|
|
159
|
-
</section>
|
|
160
|
-
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
|
|
161
|
-
<a name="descriptor" class="tsd-anchor"></a>
|
|
162
|
-
<h3>descriptor</h3>
|
|
163
|
-
<div class="tsd-signature tsd-kind-icon">descriptor<span class="tsd-signature-symbol">:</span> <a href="../interfaces/usb_descriptors.interfacedescriptor.html" class="tsd-signature-type" data-tsd-kind="Interface">InterfaceDescriptor</a></div>
|
|
164
|
-
<aside class="tsd-sources">
|
|
165
|
-
<ul>
|
|
166
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L13">tsc/usb/interface.ts:13</a></li>
|
|
167
|
-
</ul>
|
|
168
|
-
</aside>
|
|
169
|
-
<div class="tsd-comment tsd-typography">
|
|
170
|
-
<div class="lead">
|
|
171
|
-
<p>Object with fields from the interface descriptor -- see libusb documentation or USB spec.</p>
|
|
172
|
-
</div>
|
|
173
|
-
</div>
|
|
174
|
-
</section>
|
|
175
|
-
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class tsd-is-protected">
|
|
176
|
-
<a name="device" class="tsd-anchor"></a>
|
|
177
|
-
<h3><span class="tsd-flag ts-flagProtected">Protected</span> device</h3>
|
|
178
|
-
<div class="tsd-signature tsd-kind-icon">device<span class="tsd-signature-symbol">:</span> <a href="usb_bindings.device.html" class="tsd-signature-type" data-tsd-kind="Class">Device</a></div>
|
|
179
|
-
<aside class="tsd-sources">
|
|
180
|
-
</aside>
|
|
181
|
-
</section>
|
|
182
|
-
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
|
|
183
|
-
<a name="endpoints" class="tsd-anchor"></a>
|
|
184
|
-
<h3>endpoints</h3>
|
|
185
|
-
<div class="tsd-signature tsd-kind-icon">endpoints<span class="tsd-signature-symbol">:</span> <a href="usb_endpoint.endpoint.html" class="tsd-signature-type" data-tsd-kind="Class">Endpoint</a><span class="tsd-signature-symbol">[]</span></div>
|
|
186
|
-
<aside class="tsd-sources">
|
|
187
|
-
<ul>
|
|
188
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L16">tsc/usb/interface.ts:16</a></li>
|
|
189
|
-
</ul>
|
|
190
|
-
</aside>
|
|
191
|
-
<div class="tsd-comment tsd-typography">
|
|
192
|
-
<div class="lead">
|
|
193
|
-
<p>List of endpoints on this interface: InEndpoint and OutEndpoint objects.</p>
|
|
194
|
-
</div>
|
|
195
|
-
</div>
|
|
196
|
-
</section>
|
|
197
|
-
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class tsd-is-protected">
|
|
198
|
-
<a name="id" class="tsd-anchor"></a>
|
|
199
|
-
<h3><span class="tsd-flag ts-flagProtected">Protected</span> id</h3>
|
|
200
|
-
<div class="tsd-signature tsd-kind-icon">id<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span></div>
|
|
201
|
-
<aside class="tsd-sources">
|
|
202
|
-
</aside>
|
|
203
|
-
</section>
|
|
204
|
-
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
|
|
205
|
-
<a name="interfacenumber" class="tsd-anchor"></a>
|
|
206
|
-
<h3>interface<wbr>Number</h3>
|
|
207
|
-
<div class="tsd-signature tsd-kind-icon">interface<wbr>Number<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span></div>
|
|
208
|
-
<aside class="tsd-sources">
|
|
209
|
-
<ul>
|
|
210
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L7">tsc/usb/interface.ts:7</a></li>
|
|
211
|
-
</ul>
|
|
212
|
-
</aside>
|
|
213
|
-
<div class="tsd-comment tsd-typography">
|
|
214
|
-
<div class="lead">
|
|
215
|
-
<p>Integer interface number.</p>
|
|
216
|
-
</div>
|
|
217
|
-
</div>
|
|
218
|
-
</section>
|
|
219
|
-
</section>
|
|
220
|
-
<section class="tsd-panel-group tsd-member-group ">
|
|
221
|
-
<h2>Methods</h2>
|
|
222
|
-
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class">
|
|
223
|
-
<a name="attachkerneldriver" class="tsd-anchor"></a>
|
|
224
|
-
<h3>attach<wbr>Kernel<wbr>Driver</h3>
|
|
225
|
-
<ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
|
|
226
|
-
<li class="tsd-signature tsd-kind-icon">attach<wbr>Kernel<wbr>Driver<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
|
|
227
|
-
</ul>
|
|
228
|
-
<ul class="tsd-descriptions">
|
|
229
|
-
<li class="tsd-description">
|
|
230
|
-
<aside class="tsd-sources">
|
|
231
|
-
<ul>
|
|
232
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L135">tsc/usb/interface.ts:135</a></li>
|
|
233
|
-
</ul>
|
|
234
|
-
</aside>
|
|
235
|
-
<div class="tsd-comment tsd-typography">
|
|
236
|
-
<div class="lead">
|
|
237
|
-
<p>Re-attaches the kernel driver for the interface.</p>
|
|
238
|
-
</div>
|
|
239
|
-
<p>The device must be open to use this method.</p>
|
|
240
|
-
</div>
|
|
241
|
-
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
|
|
242
|
-
</li>
|
|
243
|
-
</ul>
|
|
244
|
-
</section>
|
|
245
|
-
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class">
|
|
246
|
-
<a name="claim" class="tsd-anchor"></a>
|
|
247
|
-
<h3>claim</h3>
|
|
248
|
-
<ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
|
|
249
|
-
<li class="tsd-signature tsd-kind-icon">claim<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
|
|
250
|
-
</ul>
|
|
251
|
-
<ul class="tsd-descriptions">
|
|
252
|
-
<li class="tsd-description">
|
|
253
|
-
<aside class="tsd-sources">
|
|
254
|
-
<ul>
|
|
255
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L43">tsc/usb/interface.ts:43</a></li>
|
|
256
|
-
</ul>
|
|
257
|
-
</aside>
|
|
258
|
-
<div class="tsd-comment tsd-typography">
|
|
259
|
-
<div class="lead">
|
|
260
|
-
<p>Claims the interface. This method must be called before using any endpoints of this interface.</p>
|
|
261
|
-
</div>
|
|
262
|
-
<p>The device must be open to use this method.</p>
|
|
263
|
-
</div>
|
|
264
|
-
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
|
|
265
|
-
</li>
|
|
266
|
-
</ul>
|
|
267
|
-
</section>
|
|
268
|
-
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class">
|
|
269
|
-
<a name="detachkerneldriver" class="tsd-anchor"></a>
|
|
270
|
-
<h3>detach<wbr>Kernel<wbr>Driver</h3>
|
|
271
|
-
<ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
|
|
272
|
-
<li class="tsd-signature tsd-kind-icon">detach<wbr>Kernel<wbr>Driver<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
|
|
273
|
-
</ul>
|
|
274
|
-
<ul class="tsd-descriptions">
|
|
275
|
-
<li class="tsd-description">
|
|
276
|
-
<aside class="tsd-sources">
|
|
277
|
-
<ul>
|
|
278
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L126">tsc/usb/interface.ts:126</a></li>
|
|
279
|
-
</ul>
|
|
280
|
-
</aside>
|
|
281
|
-
<div class="tsd-comment tsd-typography">
|
|
282
|
-
<div class="lead">
|
|
283
|
-
<p>Detaches the kernel driver from the interface.</p>
|
|
284
|
-
</div>
|
|
285
|
-
<p>The device must be open to use this method.</p>
|
|
286
|
-
</div>
|
|
287
|
-
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
|
|
288
|
-
</li>
|
|
289
|
-
</ul>
|
|
290
|
-
</section>
|
|
291
|
-
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class">
|
|
292
|
-
<a name="endpoint" class="tsd-anchor"></a>
|
|
293
|
-
<h3>endpoint</h3>
|
|
294
|
-
<ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
|
|
295
|
-
<li class="tsd-signature tsd-kind-icon">endpoint<span class="tsd-signature-symbol">(</span>addr<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="usb_endpoint.endpoint.html" class="tsd-signature-type" data-tsd-kind="Class">Endpoint</a></li>
|
|
296
|
-
</ul>
|
|
297
|
-
<ul class="tsd-descriptions">
|
|
298
|
-
<li class="tsd-description">
|
|
299
|
-
<aside class="tsd-sources">
|
|
300
|
-
<ul>
|
|
301
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L164">tsc/usb/interface.ts:164</a></li>
|
|
302
|
-
</ul>
|
|
303
|
-
</aside>
|
|
304
|
-
<div class="tsd-comment tsd-typography">
|
|
305
|
-
<div class="lead">
|
|
306
|
-
<p>Return the InEndpoint or OutEndpoint with the specified address.</p>
|
|
307
|
-
</div>
|
|
308
|
-
<p>The device must be open to use this method.</p>
|
|
309
|
-
</div>
|
|
310
|
-
<h4 class="tsd-parameters-title">Parameters</h4>
|
|
311
|
-
<ul class="tsd-parameters">
|
|
312
|
-
<li>
|
|
313
|
-
<h5>addr: <span class="tsd-signature-type">number</span></h5>
|
|
314
|
-
<div class="tsd-comment tsd-typography">
|
|
315
|
-
</div>
|
|
316
|
-
</li>
|
|
317
|
-
</ul>
|
|
318
|
-
<h4 class="tsd-returns-title">Returns <a href="usb_endpoint.endpoint.html" class="tsd-signature-type" data-tsd-kind="Class">Endpoint</a></h4>
|
|
319
|
-
</li>
|
|
320
|
-
</ul>
|
|
321
|
-
</section>
|
|
322
|
-
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class">
|
|
323
|
-
<a name="iskerneldriveractive" class="tsd-anchor"></a>
|
|
324
|
-
<h3>is<wbr>Kernel<wbr>Driver<wbr>Active</h3>
|
|
325
|
-
<ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
|
|
326
|
-
<li class="tsd-signature tsd-kind-icon">is<wbr>Kernel<wbr>Driver<wbr>Active<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">boolean</span></li>
|
|
327
|
-
</ul>
|
|
328
|
-
<ul class="tsd-descriptions">
|
|
329
|
-
<li class="tsd-description">
|
|
330
|
-
<aside class="tsd-sources">
|
|
331
|
-
<ul>
|
|
332
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L117">tsc/usb/interface.ts:117</a></li>
|
|
333
|
-
</ul>
|
|
334
|
-
</aside>
|
|
335
|
-
<div class="tsd-comment tsd-typography">
|
|
336
|
-
<div class="lead">
|
|
337
|
-
<p>Returns <code>false</code> if a kernel driver is not active; <code>true</code> if active.</p>
|
|
338
|
-
</div>
|
|
339
|
-
<p>The device must be open to use this method.</p>
|
|
340
|
-
</div>
|
|
341
|
-
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">boolean</span></h4>
|
|
342
|
-
</li>
|
|
343
|
-
</ul>
|
|
344
|
-
</section>
|
|
345
|
-
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-protected">
|
|
346
|
-
<a name="refresh" class="tsd-anchor"></a>
|
|
347
|
-
<h3><span class="tsd-flag ts-flagProtected">Protected</span> refresh</h3>
|
|
348
|
-
<ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-protected">
|
|
349
|
-
<li class="tsd-signature tsd-kind-icon">refresh<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
|
|
350
|
-
</ul>
|
|
351
|
-
<ul class="tsd-descriptions">
|
|
352
|
-
<li class="tsd-description">
|
|
353
|
-
<aside class="tsd-sources">
|
|
354
|
-
<ul>
|
|
355
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L22">tsc/usb/interface.ts:22</a></li>
|
|
356
|
-
</ul>
|
|
357
|
-
</aside>
|
|
358
|
-
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
|
|
359
|
-
</li>
|
|
360
|
-
</ul>
|
|
361
|
-
</section>
|
|
362
|
-
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class">
|
|
363
|
-
<a name="release" class="tsd-anchor"></a>
|
|
364
|
-
<h3>release</h3>
|
|
365
|
-
<ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
|
|
366
|
-
<li class="tsd-signature tsd-kind-icon">release<span class="tsd-signature-symbol">(</span>callback<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-symbol">(</span>error<span class="tsd-signature-symbol">?: </span><a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> => </span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
|
|
367
|
-
<li class="tsd-signature tsd-kind-icon">release<span class="tsd-signature-symbol">(</span>closeEndpoints<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">boolean</span>, callback<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-symbol">(</span>error<span class="tsd-signature-symbol">?: </span><a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> => </span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
|
|
368
|
-
</ul>
|
|
369
|
-
<ul class="tsd-descriptions">
|
|
370
|
-
<li class="tsd-description">
|
|
371
|
-
<aside class="tsd-sources">
|
|
372
|
-
<ul>
|
|
373
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L55">tsc/usb/interface.ts:55</a></li>
|
|
374
|
-
</ul>
|
|
375
|
-
</aside>
|
|
376
|
-
<div class="tsd-comment tsd-typography">
|
|
377
|
-
<div class="lead">
|
|
378
|
-
<p>Releases the interface and resets the alternate setting. Calls callback when complete.</p>
|
|
379
|
-
</div>
|
|
380
|
-
<p>It is an error to release an interface with pending transfers.</p>
|
|
381
|
-
<p>The device must be open to use this method.</p>
|
|
382
|
-
</div>
|
|
383
|
-
<h4 class="tsd-parameters-title">Parameters</h4>
|
|
384
|
-
<ul class="tsd-parameters">
|
|
385
|
-
<li>
|
|
386
|
-
<h5><span class="tsd-flag ts-flagOptional">Optional</span> callback: <span class="tsd-signature-symbol">(</span>error<span class="tsd-signature-symbol">?: </span><a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> => </span><span class="tsd-signature-type">void</span></h5>
|
|
387
|
-
<div class="tsd-comment tsd-typography">
|
|
388
|
-
</div>
|
|
389
|
-
<ul class="tsd-parameters">
|
|
390
|
-
<li class="tsd-parameter-signature">
|
|
391
|
-
<ul class="tsd-signatures tsd-kind-type-literal">
|
|
392
|
-
<li class="tsd-signature tsd-kind-icon"><span class="tsd-signature-symbol">(</span>error<span class="tsd-signature-symbol">?: </span><a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
|
|
393
|
-
</ul>
|
|
394
|
-
<ul class="tsd-descriptions">
|
|
395
|
-
<li class="tsd-description">
|
|
396
|
-
<h4 class="tsd-parameters-title">Parameters</h4>
|
|
397
|
-
<ul class="tsd-parameters">
|
|
398
|
-
<li>
|
|
399
|
-
<h5><span class="tsd-flag ts-flagOptional">Optional</span> error: <a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a></h5>
|
|
400
|
-
</li>
|
|
401
|
-
</ul>
|
|
402
|
-
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
|
|
403
|
-
</li>
|
|
404
|
-
</ul>
|
|
405
|
-
</li>
|
|
406
|
-
</ul>
|
|
407
|
-
</li>
|
|
408
|
-
</ul>
|
|
409
|
-
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
|
|
410
|
-
</li>
|
|
411
|
-
<li class="tsd-description">
|
|
412
|
-
<aside class="tsd-sources">
|
|
413
|
-
<ul>
|
|
414
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L69">tsc/usb/interface.ts:69</a></li>
|
|
415
|
-
</ul>
|
|
416
|
-
</aside>
|
|
417
|
-
<div class="tsd-comment tsd-typography">
|
|
418
|
-
<div class="lead">
|
|
419
|
-
<p>Releases the interface and resets the alternate setting. Calls callback when complete.</p>
|
|
420
|
-
</div>
|
|
421
|
-
<p>It is an error to release an interface with pending transfers. If the optional closeEndpoints
|
|
422
|
-
parameter is true, any active endpoint streams are stopped (see <code>Endpoint.stopStream</code>),
|
|
423
|
-
and the interface is released after the stream transfers are cancelled. Transfers submitted
|
|
424
|
-
individually with <code>Endpoint.transfer</code> are not affected by this parameter.</p>
|
|
425
|
-
<p>The device must be open to use this method.</p>
|
|
426
|
-
</div>
|
|
427
|
-
<h4 class="tsd-parameters-title">Parameters</h4>
|
|
428
|
-
<ul class="tsd-parameters">
|
|
429
|
-
<li>
|
|
430
|
-
<h5><span class="tsd-flag ts-flagOptional">Optional</span> closeEndpoints: <span class="tsd-signature-type">boolean</span></h5>
|
|
431
|
-
</li>
|
|
432
|
-
<li>
|
|
433
|
-
<h5><span class="tsd-flag ts-flagOptional">Optional</span> callback: <span class="tsd-signature-symbol">(</span>error<span class="tsd-signature-symbol">?: </span><a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> => </span><span class="tsd-signature-type">void</span></h5>
|
|
434
|
-
<div class="tsd-comment tsd-typography">
|
|
435
|
-
</div>
|
|
436
|
-
<ul class="tsd-parameters">
|
|
437
|
-
<li class="tsd-parameter-signature">
|
|
438
|
-
<ul class="tsd-signatures tsd-kind-type-literal">
|
|
439
|
-
<li class="tsd-signature tsd-kind-icon"><span class="tsd-signature-symbol">(</span>error<span class="tsd-signature-symbol">?: </span><a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
|
|
440
|
-
</ul>
|
|
441
|
-
<ul class="tsd-descriptions">
|
|
442
|
-
<li class="tsd-description">
|
|
443
|
-
<h4 class="tsd-parameters-title">Parameters</h4>
|
|
444
|
-
<ul class="tsd-parameters">
|
|
445
|
-
<li>
|
|
446
|
-
<h5><span class="tsd-flag ts-flagOptional">Optional</span> error: <a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a></h5>
|
|
447
|
-
</li>
|
|
448
|
-
</ul>
|
|
449
|
-
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
|
|
450
|
-
</li>
|
|
451
|
-
</ul>
|
|
452
|
-
</li>
|
|
453
|
-
</ul>
|
|
454
|
-
</li>
|
|
455
|
-
</ul>
|
|
456
|
-
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
|
|
457
|
-
</li>
|
|
458
|
-
</ul>
|
|
459
|
-
</section>
|
|
460
|
-
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class">
|
|
461
|
-
<a name="setaltsetting" class="tsd-anchor"></a>
|
|
462
|
-
<h3>set<wbr>Alt<wbr>Setting</h3>
|
|
463
|
-
<ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
|
|
464
|
-
<li class="tsd-signature tsd-kind-icon">set<wbr>Alt<wbr>Setting<span class="tsd-signature-symbol">(</span>altSetting<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">number</span>, callback<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-symbol">(</span>error<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> => </span><span class="tsd-signature-type">void</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
|
|
465
|
-
</ul>
|
|
466
|
-
<ul class="tsd-descriptions">
|
|
467
|
-
<li class="tsd-description">
|
|
468
|
-
<aside class="tsd-sources">
|
|
469
|
-
<ul>
|
|
470
|
-
<li>Defined in <a href="https://github.com/tessel/node-usb/blob/639b0a3/tsc/usb/interface.ts#L146">tsc/usb/interface.ts:146</a></li>
|
|
471
|
-
</ul>
|
|
472
|
-
</aside>
|
|
473
|
-
<div class="tsd-comment tsd-typography">
|
|
474
|
-
<div class="lead">
|
|
475
|
-
<p>Sets the alternate setting. It updates the <code>interface.endpoints</code> array to reflect the endpoints found in the alternate setting.</p>
|
|
476
|
-
</div>
|
|
477
|
-
<p>The device must be open to use this method.</p>
|
|
478
|
-
</div>
|
|
479
|
-
<h4 class="tsd-parameters-title">Parameters</h4>
|
|
480
|
-
<ul class="tsd-parameters">
|
|
481
|
-
<li>
|
|
482
|
-
<h5>altSetting: <span class="tsd-signature-type">number</span></h5>
|
|
483
|
-
</li>
|
|
484
|
-
<li>
|
|
485
|
-
<h5><span class="tsd-flag ts-flagOptional">Optional</span> callback: <span class="tsd-signature-symbol">(</span>error<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol"> => </span><span class="tsd-signature-type">void</span></h5>
|
|
486
|
-
<div class="tsd-comment tsd-typography">
|
|
487
|
-
</div>
|
|
488
|
-
<ul class="tsd-parameters">
|
|
489
|
-
<li class="tsd-parameter-signature">
|
|
490
|
-
<ul class="tsd-signatures tsd-kind-type-literal">
|
|
491
|
-
<li class="tsd-signature tsd-kind-icon"><span class="tsd-signature-symbol">(</span>error<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li>
|
|
492
|
-
</ul>
|
|
493
|
-
<ul class="tsd-descriptions">
|
|
494
|
-
<li class="tsd-description">
|
|
495
|
-
<h4 class="tsd-parameters-title">Parameters</h4>
|
|
496
|
-
<ul class="tsd-parameters">
|
|
497
|
-
<li>
|
|
498
|
-
<h5>error: <span class="tsd-signature-type">undefined</span><span class="tsd-signature-symbol"> | </span><a href="usb_bindings.libusbexception.html" class="tsd-signature-type" data-tsd-kind="Class">LibUSBException</a></h5>
|
|
499
|
-
</li>
|
|
500
|
-
</ul>
|
|
501
|
-
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
|
|
502
|
-
</li>
|
|
503
|
-
</ul>
|
|
504
|
-
</li>
|
|
505
|
-
</ul>
|
|
506
|
-
</li>
|
|
507
|
-
</ul>
|
|
508
|
-
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4>
|
|
509
|
-
</li>
|
|
510
|
-
</ul>
|
|
511
|
-
</section>
|
|
512
|
-
</section>
|
|
513
|
-
</div>
|
|
514
|
-
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
|
|
515
|
-
<nav class="tsd-navigation primary">
|
|
516
|
-
<ul>
|
|
517
|
-
<li class=" ">
|
|
518
|
-
<a href="../modules.html">Exports</a>
|
|
519
|
-
</li>
|
|
520
|
-
<li class=" tsd-kind-module">
|
|
521
|
-
<a href="../modules/index.html">index</a>
|
|
522
|
-
</li>
|
|
523
|
-
<li class=" tsd-kind-module">
|
|
524
|
-
<a href="../modules/usb.html">usb</a>
|
|
525
|
-
</li>
|
|
526
|
-
<li class=" tsd-kind-module">
|
|
527
|
-
<a href="../modules/usb_bindings.html">usb/bindings</a>
|
|
528
|
-
</li>
|
|
529
|
-
<li class=" tsd-kind-module">
|
|
530
|
-
<a href="../modules/usb_capability.html">usb/capability</a>
|
|
531
|
-
</li>
|
|
532
|
-
<li class=" tsd-kind-module">
|
|
533
|
-
<a href="../modules/usb_descriptors.html">usb/descriptors</a>
|
|
534
|
-
</li>
|
|
535
|
-
<li class=" tsd-kind-module">
|
|
536
|
-
<a href="../modules/usb_device.html">usb/device</a>
|
|
537
|
-
</li>
|
|
538
|
-
<li class=" tsd-kind-module">
|
|
539
|
-
<a href="../modules/usb_endpoint.html">usb/endpoint</a>
|
|
540
|
-
</li>
|
|
541
|
-
<li class="current tsd-kind-module">
|
|
542
|
-
<a href="../modules/usb_interface.html">usb/interface</a>
|
|
543
|
-
</li>
|
|
544
|
-
<li class=" tsd-kind-module">
|
|
545
|
-
<a href="../modules/webusb.html">webusb</a>
|
|
546
|
-
</li>
|
|
547
|
-
<li class=" tsd-kind-module">
|
|
548
|
-
<a href="../modules/webusb_mutex.html">webusb/mutex</a>
|
|
549
|
-
</li>
|
|
550
|
-
<li class=" tsd-kind-module">
|
|
551
|
-
<a href="../modules/webusb_typed_event_target.html">webusb/typed-<wbr>event-<wbr>target</a>
|
|
552
|
-
</li>
|
|
553
|
-
<li class=" tsd-kind-module">
|
|
554
|
-
<a href="../modules/webusb_webusb_device.html">webusb/webusb-<wbr>device</a>
|
|
555
|
-
</li>
|
|
556
|
-
</ul>
|
|
557
|
-
</nav>
|
|
558
|
-
<nav class="tsd-navigation secondary menu-sticky">
|
|
559
|
-
<ul class="before-current">
|
|
560
|
-
</ul>
|
|
561
|
-
<ul class="current">
|
|
562
|
-
<li class="current tsd-kind-class tsd-parent-kind-module">
|
|
563
|
-
<a href="usb_interface.interface.html" class="tsd-kind-icon">Interface</a>
|
|
564
|
-
<ul>
|
|
565
|
-
<li class=" tsd-kind-constructor tsd-parent-kind-class">
|
|
566
|
-
<a href="usb_interface.interface.html#constructor" class="tsd-kind-icon">constructor</a>
|
|
567
|
-
</li>
|
|
568
|
-
<li class=" tsd-kind-property tsd-parent-kind-class">
|
|
569
|
-
<a href="usb_interface.interface.html#altsetting" class="tsd-kind-icon">alt<wbr>Setting</a>
|
|
570
|
-
</li>
|
|
571
|
-
<li class=" tsd-kind-property tsd-parent-kind-class">
|
|
572
|
-
<a href="usb_interface.interface.html#descriptor" class="tsd-kind-icon">descriptor</a>
|
|
573
|
-
</li>
|
|
574
|
-
<li class=" tsd-kind-property tsd-parent-kind-class tsd-is-protected">
|
|
575
|
-
<a href="usb_interface.interface.html#device" class="tsd-kind-icon">device</a>
|
|
576
|
-
</li>
|
|
577
|
-
<li class=" tsd-kind-property tsd-parent-kind-class">
|
|
578
|
-
<a href="usb_interface.interface.html#endpoints" class="tsd-kind-icon">endpoints</a>
|
|
579
|
-
</li>
|
|
580
|
-
<li class=" tsd-kind-property tsd-parent-kind-class tsd-is-protected">
|
|
581
|
-
<a href="usb_interface.interface.html#id" class="tsd-kind-icon">id</a>
|
|
582
|
-
</li>
|
|
583
|
-
<li class=" tsd-kind-property tsd-parent-kind-class">
|
|
584
|
-
<a href="usb_interface.interface.html#interfacenumber" class="tsd-kind-icon">interface<wbr>Number</a>
|
|
585
|
-
</li>
|
|
586
|
-
<li class=" tsd-kind-method tsd-parent-kind-class">
|
|
587
|
-
<a href="usb_interface.interface.html#attachkerneldriver" class="tsd-kind-icon">attach<wbr>Kernel<wbr>Driver</a>
|
|
588
|
-
</li>
|
|
589
|
-
<li class=" tsd-kind-method tsd-parent-kind-class">
|
|
590
|
-
<a href="usb_interface.interface.html#claim" class="tsd-kind-icon">claim</a>
|
|
591
|
-
</li>
|
|
592
|
-
<li class=" tsd-kind-method tsd-parent-kind-class">
|
|
593
|
-
<a href="usb_interface.interface.html#detachkerneldriver" class="tsd-kind-icon">detach<wbr>Kernel<wbr>Driver</a>
|
|
594
|
-
</li>
|
|
595
|
-
<li class=" tsd-kind-method tsd-parent-kind-class">
|
|
596
|
-
<a href="usb_interface.interface.html#endpoint" class="tsd-kind-icon">endpoint</a>
|
|
597
|
-
</li>
|
|
598
|
-
<li class=" tsd-kind-method tsd-parent-kind-class">
|
|
599
|
-
<a href="usb_interface.interface.html#iskerneldriveractive" class="tsd-kind-icon">is<wbr>Kernel<wbr>Driver<wbr>Active</a>
|
|
600
|
-
</li>
|
|
601
|
-
<li class=" tsd-kind-method tsd-parent-kind-class tsd-is-protected">
|
|
602
|
-
<a href="usb_interface.interface.html#refresh" class="tsd-kind-icon">refresh</a>
|
|
603
|
-
</li>
|
|
604
|
-
<li class=" tsd-kind-method tsd-parent-kind-class">
|
|
605
|
-
<a href="usb_interface.interface.html#release" class="tsd-kind-icon">release</a>
|
|
606
|
-
</li>
|
|
607
|
-
<li class=" tsd-kind-method tsd-parent-kind-class">
|
|
608
|
-
<a href="usb_interface.interface.html#setaltsetting" class="tsd-kind-icon">set<wbr>Alt<wbr>Setting</a>
|
|
609
|
-
</li>
|
|
610
|
-
</ul>
|
|
611
|
-
</li>
|
|
612
|
-
</ul>
|
|
613
|
-
<ul class="after-current">
|
|
614
|
-
</ul>
|
|
615
|
-
</nav>
|
|
616
|
-
</div>
|
|
617
|
-
</div>
|
|
618
|
-
</div>
|
|
619
|
-
<footer>
|
|
620
|
-
<div class="container">
|
|
621
|
-
<h2>Legend</h2>
|
|
622
|
-
<div class="tsd-legend-group">
|
|
623
|
-
<ul class="tsd-legend">
|
|
624
|
-
<li class="tsd-kind-class"><span class="tsd-kind-icon">Class</span></li>
|
|
625
|
-
<li class="tsd-kind-class tsd-has-type-parameter"><span class="tsd-kind-icon">Class with type parameter</span></li>
|
|
626
|
-
<li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li>
|
|
627
|
-
<li class="tsd-kind-property tsd-parent-kind-class"><span class="tsd-kind-icon">Property</span></li>
|
|
628
|
-
<li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li>
|
|
629
|
-
</ul>
|
|
630
|
-
<ul class="tsd-legend">
|
|
631
|
-
<li class="tsd-kind-variable"><span class="tsd-kind-icon">Variable</span></li>
|
|
632
|
-
<li class="tsd-kind-function"><span class="tsd-kind-icon">Function</span></li>
|
|
633
|
-
<li class="tsd-kind-function tsd-has-type-parameter"><span class="tsd-kind-icon">Function with type parameter</span></li>
|
|
634
|
-
</ul>
|
|
635
|
-
<ul class="tsd-legend">
|
|
636
|
-
<li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected property</span></li>
|
|
637
|
-
<li class="tsd-kind-method tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected method</span></li>
|
|
638
|
-
</ul>
|
|
639
|
-
<ul class="tsd-legend">
|
|
640
|
-
<li class="tsd-kind-interface"><span class="tsd-kind-icon">Interface</span></li>
|
|
641
|
-
</ul>
|
|
642
|
-
</div>
|
|
643
|
-
</div>
|
|
644
|
-
</footer>
|
|
645
|
-
<div class="overlay"></div>
|
|
646
|
-
<script src="../assets/js/main.js"></script>
|
|
647
|
-
</body>
|
|
648
|
-
</html>
|