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 ADC V2 with Async support #814

Draft
wants to merge 38 commits into
base: master
Choose a base branch
from
Draft

Conversation

rnd-ash
Copy link
Contributor

@rnd-ash rnd-ash commented Jan 23, 2025

Summary

This PR adds a new ADC API, based around a similar system to channels used by EIC and DMA peripherals.

At the moment I'll keep this as a draft PR for feedback whilst I am still finalizing bits and also adding SAMD11/21 support

Features

  • A new settings builder system for configuring the ADC
  • Channels system (Each Analog capable pin has its own channel)
  • Both blocking and Async read support
  • Buffer filling support (Free running continuous mode)
  • CPU temperature reading
  • Internal voltages reading

Progress checklist

  • SAMx51 support
  • SAMx11/21 support
  • Channels API
  • Settings builder (Mostly completed, need to add settings for Vref calibration)
  • Async/Blocking single reads
  • Async/Blocking buffer reads
  • CPU temperature reading (Restricted to primary ADC if applicable to chip)
  • CPU internal voltages reading (Restricted to primary ADC if applicable to chip)

rnd-ash and others added 30 commits January 5, 2025 11:14
Automatically convert pins to correct mode in Channel::with_pins
`wait_flags` and buffered read methods
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