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

New RTT USB class #30

Draft
wants to merge 58 commits into
base: new_basestation
Choose a base branch
from
Draft

Conversation

casdoorn
Copy link
Contributor

@casdoorn casdoorn commented Feb 22, 2023

With the new BaseStation design a new USB implementation is needed because the USB class provided by ST only works for the old BaseStation. As the code for the previous USB was not clear, very basic, and documentation was lacking a modification to that code is not recommended and prone to new issues. So a new USB class has been written with REM in mind.

Features:

  • USB 2.0 HS instead of USB 1.2 FS --> reduced latency and higher bandwidth.
  • Random stopping bug fixed!
  • 2 interfaces for high- and low-priority messages instead of 1, with alternate interface option(s) per priority interface.
  • Reserved bandwidth and fixed (low) latency for high-priority messages using Interrupt Transfers (can be changed to ISO in the future).
  • New user interface with marked user callable functions and callbacks structs for clear separation of code and code flow.
  • Documentation about flow, structure reasoning, and documented pitfalls with links to more information about USB.

Issues/Outstanding Tasks:

  • STM32CubeMX should still be updated in order to allow for two separate interfaces. Once code will be regenerated the configuration should for now be changed by hand.
  • Needs RobotHub changes to USB code to handle the different Interfaces and Endpoints control flow/settings before it can be used with AI.
  • Needs a different Python USB library scripts that has a lower level abstraction function calls, a working setup is already available, but not implemented for the test scripts.
  • Needs better integration with In/Out buffers in main, but out of scope for this pull request. (Also Logging should not control USB sending).

WARNING

Does not work with old BaseStation!!! (But can be ported)

emielsteerneman and others added 30 commits September 21, 2022 21:44
casdoorn and others added 28 commits November 30, 2022 17:36
…y packets can be sent before the device disconnects
…-to-peripheral is needed for both SX1280's to work properly;
…dded RX led; Updated some wrong calculations (might still be wrong);
…enerates two buffers for transmissions, but we need three of them
… new and old basestations

 This has to do with the USB connectivity. Which basestation version to use is automatically determined.
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

Successfully merging this pull request may close these issues.

5 participants