Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 3 additions & 34 deletions header.d.ts
Original file line number Diff line number Diff line change
@@ -1,35 +1,4 @@
export type USBSpeed = 'low' | 'full' | 'high' | 'super' | 'superPlus';
export type USBSpeed = 'low' | 'full' | 'high' | 'super' | 'superPlus' | undefined;

export declare interface UsbDevice extends USBDevice {
/**
* The USB bus the device is connected to (e.g. `1-1`, `2-3.4`, etc.)
*/
bus: string;

/**
* The USB address the device is connected to
*/
address: number;

/**
* The USB port numbers the device is connected through (e.g. `[1]`, `[3, 4]`, etc.)
*/
ports: Array<number>

/**
* The USB speed of the device (e.g. `Low`, `Full`, `High`, `Super`, `SuperPlus` or `undefined` if unknown)
*/
speed?: USBSpeed;

/**
* Detaches the kernel driver from the specified interface number (Linux only)
* @param interfaceNumber
*/
detachKernelDriver(interfaceNumber: number): Promise<void>;

/**
* Attaches the kernel driver for the specified interface number (Linux only)
* @param interfaceNumber
*/
attachKernelDriver(interfaceNumber: number): Promise<void>;
}
// This declaration merges with the napi-generated `class UsbDevice` below.
export declare interface UsbDevice extends USBDevice {}
59 changes: 4 additions & 55 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading