pavel-a / usb-relay-hid

Software for USB-connected relays with HID interface. See the WIKI for more info.
http://vusb.wikidot.com/project:driver-less-usb-relays-hid-interface
242 stars 105 forks source link

Resolve issue with usb_relay_device_open_with_serial_number (orig. lib) #6

Open pavel-a opened 9 years ago

pavel-a commented 9 years ago

I don't understand what this function should return: the low -level handle or struct usb_relay_device_info *. If the former, how to get the info (number of relays, etc.) from this handle.

Currently in my lib the handle is same as usb_relay_device_info * but this may change later? I'd like this f() to publicly return the struct ptr, or add another f() because I need to know at least the number of relays.

In original package the command util uses only usb_relay_device_open_with_serial_number and the GUI uses only usb_relay_device_enumerate and usb_relay_device_open.