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

Make hardware SPI, I2C, ADC optional and add config to optimize for size #560

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

vvuk
Copy link
Contributor

@vvuk vvuk commented Jan 27, 2025

Our good friend STM32F042 has very tiny flash, and I'm stuffing it full of ldc1612 code. There's some hacks I've been doing to get this to fit, and I wanted to turn those into config options. This adds:

  • WANT_GPIO_{ADC, SPI, I2C} configs. They depend on their HAVE_GPIO_* base.
  • Changes features that depended on HAVE_GPIO_* to WANT_GPIO_*
  • Adds a config to optionally compile with -Os instead of -O2

This certainly needs some test cases added at least for compilation, but I want to get this up to see if it would be accepted in general.

Checklist

  • pr title makes sense
  • squashed to 1 commit
  • added a test case if possible
  • [-] if new feature, added to the readme
  • ci is happy and green

@vvuk vvuk requested a review from a team as a code owner January 27, 2025 06:43
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.

1 participant