Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document the hiddata.c differences of blink1-mini-tool #26

Open
todbot opened this issue Apr 13, 2020 · 0 comments
Open

Document the hiddata.c differences of blink1-mini-tool #26

todbot opened this issue Apr 13, 2020 · 0 comments

Comments

@todbot
Copy link
Owner

todbot commented Apr 13, 2020

Both blink1-tool and blink1-mini-tool have a hiddata.c. This is an alternate, simpler and, for Linux, a libusb-0.1-based way of talking to USB HID devices. The normal preferred way is to use hidapi.

The hiddata.c in blink1-mini-tool attempts to detach the (Linux) kernel driver if it has claimed it for the device and then reattach it when done. Some Linux kernel configurations can be zealous about what USB devices it decides to own. At you may expect, detach/reattach can be a dangerous thing to do. So it's relegated to blink1-mini-tool, which is sort of a last-ditch attempt to talk to blink(1) on minimal embedded Linux systems like WRT routers.

This should be documented somewhere. I need to figure out where.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant