Repository navigation
USB HOST implementation on teensy 4.1 #6527
Description
Activity
- changed the title
[-]add ability to get "USB-MIDI Event Packets" for USB HOST implementation[/-][+]problem with USB HOST implementation[/+]on Jun 28, 2022 - changed the title
[-]problem with USB HOST implementation[/-][+]problem with USB HOST implementation on teensy 4.1[/+]on Jun 28, 2022 - changed the title
[-]problem with USB HOST implementation on teensy 4.1[/-][+]USB HOST implementation on teensy 4.1[/+]on Jun 28, 2022 read isn't implemented yet. :-) I mentioned it here: #6125
I should have had it raise an error. Sorry!
I thought I'd get back to it quickly but didn't. I switched off of it while waiting for a TinyUSB API to call.
Would you like to try and add it? It shouldn't be too hard now that TinyUSB has an API for it. (I haven't looked at specifics though.)
Thanks for answer, Scott!
Sure, I want to try to add it. But can you give me brief insight into right direction, please?
Do I need build new circuitpython for my teensy, or I can just add TinyUSB library to my project and write some glue?Sure, I want to try to add it. But can you give me brief insight into right direction, please?
Yup! Happy to. Join us on discord if you haven't yet too. There is a #circuitpython-dev channel where we can help you get over any bumps. https://adafru.it/discord
Do I need build new circuitpython for my teensy, or I can just add TinyUSB library to my project and write some glue?
Yes, you'll need to build your own CircuitPython. I think the steps are:- Upgrade the
lib/tinyusbsubmodule to the latest commit to get the newest USB Host API. You may need to update the existing calls too. - Add calls into the TinyUSB API into the shared-module/usb/core/Device.c source file. It is in shared-module because it'll work on all ports that have the
usb_hostmodule and use TinyUSB.
If you hit any snags, jump on Discord and we'd be happy to try and help.
- Upgrade the
Thanks, Scott!
I'm done with successful build of custom CircuitPython and now I'm trying to understand architecture of api calls for required changes, and this looks like few sleepless nights))- added a commit that references this issue
on Jul 8, 2023 - added a commit that references this issue
on Jul 11, 2023
I can't get data through endpoint of usb host implementation
Where is my mistake?
this is my code:
I'm getting right device manufacturer and product names,
but my "buf" is always empty and "count" of read bytes is always 14...
I also tried 7 and 8 version of CircuitPython and different usb devices...