Interactions with Teensy USB Stack #35
Replies: 2 comments 1 reply
-
I'm not familiar with Teensy's USB stack. When you say "the Joystick", I assume you mean this: https://www.pjrc.com/teensy/td_joystick.html ? And by |
Beta Was this translation helpful? Give feedback.
-
Yes, You can probably just upload your code to a GitHub repo and send me the link. I can take a look at the stuff involving AceRoutine. I don't know much about USB code so probably won't have much to add. |
Beta Was this translation helpful? Give feedback.
-
This isn't an issue per se, but I was curious on if there are any considerations with using AceRoutine and implementing a custom USB HID device. The custom USB device USB code is essentially identical to the Joystick implementation.
I have a few coroutines gathering data, and one coroutine calling the lower-level function to place that data in the USB buffer to be collected during a polling interval (function is almost identical to the Joystick.send() function example provided with Teensyduino).
When those lower-level functions execute, my assumption is that those will run to completion, instead of the switching that happens during running the main loop with the coroutines, and then once those have completed and returned to the main loop the context switching will resume. Is this a correct assumption, or is my example not clear enough for you to answer this question?
Beta Was this translation helpful? Give feedback.
All reactions