Versions in this module Expand all Collapse all v0 v0.0.1 Feb 8, 2022 Changes in this version + const ProductIDAny + const VendorIDAny + var ErrTimeout = errors.New("timeout") + func Enumerate(vid, pid uint16, enumFn EnumFunc) error + func Exit() error + func Init() error + type Device struct + func Open(vid, pid uint16, serial string) (*Device, error) + func OpenFirst(vid, pid uint16) (*Device, error) + func OpenPath(path string) (*Device, error) + func (d *Device) Close() error + func (d *Device) Error() error + func (d *Device) GetFeatureReport(b []byte) (int, error) + func (d *Device) GetIndexedStr(index int) (string, error) + func (d *Device) GetMfrStr() (string, error) + func (d *Device) GetProductStr() (string, error) + func (d *Device) GetSerialNbr() (string, error) + func (d *Device) Read(b []byte) (int, error) + func (d *Device) ReadWithTimeout(b []byte, timeout time.Duration) (int, error) + func (d *Device) SendFeatureReport(b []byte) (int, error) + func (d *Device) SetNonblock(nonblocking bool) error + func (d *Device) Write(b []byte) (int, error) + type DeviceInfo struct + InterfaceNbr int + MfrStr string + Path string + ProductID uint16 + ProductStr string + ReleaseNbr uint16 + SerialNbr string + Usage uint16 + UsagePage uint16 + VendorID uint16 + type EnumFunc func(info *DeviceInfo) error