Documentation
¶
Overview ¶
Package device provides common interfaces and utilities for virtual USB devices.
Index ¶
Constants ¶
View Source
const ( ExportMetaKey contextKey = iota ConnTimerKey )
Variables ¶
This section is empty.
Functions ¶
func GetConnTimer ¶
GetConnTimer extracts the connection timer from a device context. Returns nil if the context doesn't contain the timer.
func GetDeviceMeta ¶
func GetDeviceMeta(ctx context.Context) *usbip.ExportMeta
GetDeviceMeta extracts the device metadata from a device context. Returns nil if the context doesn't contain device metadata.
Types ¶
type CreateOptions ¶
type ReportBuilder ¶
type ReportBuilder interface {
// BuildReport encodes the input state into a byte slice for USB transfer.
BuildReport() []byte
}
ReportBuilder is an interface for device input states that can build USB reports.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package keyboard provides a HID keyboard device implementation with full N-key rollover.
|
Package keyboard provides a HID keyboard device implementation with full N-key rollover. |
|
Package mouse provides a HID mouse device implementation.
|
Package mouse provides a HID mouse device implementation. |
|
Package xbox360 provides an Xbox 360 controller device implementation.
|
Package xbox360 provides an Xbox 360 controller device implementation. |
Click to show internal directories.
Click to hide internal directories.