Documentation
¶
Overview ¶
Example client demonstrates attaching a remote USB/IP device via pkg/usbip.Importer and detaching it cleanly after a brief hold.
Usage:
go run ./examples/client HOST BUSID
Produces output similar to:
attached bus-id 1-1 to port 0 at 10.0.0.5:3240 detached port 0
The example exits non-zero on any failure. It is intentionally the smallest path through the public API: NewImporter, Attach, Detach, Close. Error handling uses the sentinels exported by pkg/usbip so consumers can see how errors.Is-based classification is expected to work.
Click to show internal directories.
Click to hide internal directories.