Skip to content

Rework TinyUSB lib #80

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

Merged
merged 29 commits into from
May 18, 2021
Merged

Rework TinyUSB lib #80

merged 29 commits into from
May 18, 2021

Conversation

hathach
Copy link
Member

@hathach hathach commented May 10, 2021

This PR rework how TinyUSB arduino lib is organized, making it more portable and less effort to maintain the library across arduino cores and as intented to be release as initial v1. Major changes includes:

  • All the sources file are kept within this repository (include tinyusb stack and user class) instead of splitting sources with https://github.com/adafruit/Adafruit_TinyUSB_ArduinoCore, which will be obsoleted and archived once this is merge.
  • Reduce footprint on core bsp with new Adafruit_TinyUSB_API with core, and port API. Both APIs (along with tusb_config.h) can be implemented at sketch level should the core doesn't support TinyUSB lib. (though you still need to forward IRQ to tinyusb).
  • Minor API renaming, though most user API still works as it is
  • Since TinyUSB is not part of the core anymore, all the sketches want to use TinyUSB lib must explicitly have #include <Adafruit_TinyUSB.h> same way as you would like to use SPI. Even if the sketch only Serial otherwise the linker will failed to find tinyusb lib sources.

Note: CI is failed since both samd and arduino core need to be updated

@hathach hathach requested a review from ladyada May 10, 2021 08:32
@timonsku
Copy link
Contributor

Sounds great! Will there be a list of API changes? I'm currently working on a larger library that uses TinyUSB in the background.

@hathach
Copy link
Member Author

hathach commented May 11, 2021

@timonsku no noticable API or behavior changes to application, only a couple of least used renaming. You will know when it shows up in compiling.

@hathach hathach merged commit daeef23 into master May 18, 2021
@hathach hathach deleted the major-v1 branch May 18, 2021 10:20
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.

2 participants