Transport¶
The transport is the only layer that knows about the USB/IP wire. Every device and
host entry point takes an optional transport; omit it (or pass None) and you get
the default local transport - a loopback to the host kernel on 127.0.0.1:3240.
The device side listens on the transport and the host side connects to it, following the USB/IP roles.
Local (default)¶
Remote (TCP)¶
Name a USBIP transport to bind/serve on a specific address
or to reach a remote server. One process serves one device; to export several
devices, run several processes on different ports.
Loopback (tests)¶
Loopback / usbip_loopback() connects a device and a
host in the same process - no sockets, no kernel, no root. The test suite uses this
to drive a device from a host directly, including across languages.
Defaults and custom transports¶
usbip.transport.use(t) sets the process-wide default transport, picked up by any
call that doesn't name one. To carry USB/IP over something other than TCP, subclass
Transport and implement serve() / connect().
See Going remote, capturing traffic and the Transport API.