-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Full access to TinyUSB as a library? #2922
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
Comments
We could add functionality that seems like it would be generally useful. What are your use cases?
It would not make sense to be able to call TinyUSB in general; you could easily conflict with what we need for CircuitPython. |
Thats what I feared My use case right now would be to add support for HID generic transfers. Access to certain events and functions would also be of interest. f.e. setting the PID VID in user code and events for usb mounted/unmounted. |
There is already some latent support for raw HID, but we haven't written the corresponding Python part of the library yet. User-defined descriptors are a pending issue: #1015. PID/VID would come along with that. Feel free to open issues for specific features. I'll close this one for now, since it's more about how rather than what. |
Sounds good to me, that seems to implement most things I wanted :) |
See PR #2116, which optionally provides a We were contemplating using You opened this issue a long time ago: adafruit/Adafruit_CircuitPython_HID#25 :) |
Yes I have not forgotten about it :D |
I added the |
#7806 fixes a problem that gets in the way of raw HID, and should now allow this. There are some test programs there. |
Something I'm missing in CPY atm is more low level access to TinyUSB.
I can understand that one might not want to expose the whole C API to the Python side but would it be possible to write a library in C that can interact with TinyUSB and only expose a higher abstraction of my desired functionality to Python?
I have no idea how linking works for python modules with native code, can I just call any part of the core or would I need to build my code together with the core?
Also would I run into issues with CPY managing USB stuff and messing with it?
The text was updated successfully, but these errors were encountered: