pub struct Saadc { /* private fields */ }
Expand description
Analog to Digital Converter
Implementations§
Source§impl Saadc
impl Saadc
pub const unsafe fn from_ptr(ptr: *mut ()) -> Self
pub const fn as_ptr(&self) -> *mut ()
Sourcepub const fn tasks_start(self) -> Reg<u32, W>
pub const fn tasks_start(self) -> Reg<u32, W>
Start the ADC and prepare the result buffer in RAM
Sourcepub const fn tasks_sample(self) -> Reg<u32, W>
pub const fn tasks_sample(self) -> Reg<u32, W>
Take one ADC sample, if scan is enabled all channels are sampled
Sourcepub const fn tasks_stop(self) -> Reg<u32, W>
pub const fn tasks_stop(self) -> Reg<u32, W>
Stop the ADC and terminate any on-going conversion
Sourcepub const fn tasks_calibrateoffset(self) -> Reg<u32, W>
pub const fn tasks_calibrateoffset(self) -> Reg<u32, W>
Starts offset auto-calibration
Sourcepub const fn events_started(self) -> Reg<u32, RW>
pub const fn events_started(self) -> Reg<u32, RW>
The ADC has started
Sourcepub const fn events_end(self) -> Reg<u32, RW>
pub const fn events_end(self) -> Reg<u32, RW>
The ADC has filled up the Result buffer
Sourcepub const fn events_done(self) -> Reg<u32, RW>
pub const fn events_done(self) -> Reg<u32, RW>
A conversion task has been completed. Depending on the mode, multiple conversions might be needed for a result to be transferred to RAM.
Sourcepub const fn events_resultdone(self) -> Reg<u32, RW>
pub const fn events_resultdone(self) -> Reg<u32, RW>
A result is ready to get transferred to RAM.
Sourcepub const fn events_calibratedone(self) -> Reg<u32, RW>
pub const fn events_calibratedone(self) -> Reg<u32, RW>
Calibration is complete
Sourcepub const fn events_stopped(self) -> Reg<u32, RW>
pub const fn events_stopped(self) -> Reg<u32, RW>
The ADC has stopped
Sourcepub const fn resolution(self) -> Reg<Resolution, RW>
pub const fn resolution(self) -> Reg<Resolution, RW>
Resolution configuration
Sourcepub const fn oversample(self) -> Reg<Oversample, RW>
pub const fn oversample(self) -> Reg<Oversample, RW>
Oversampling configuration. OVERSAMPLE should not be combined with SCAN. The RESOLUTION is applied before averaging, thus for high OVERSAMPLE a higher RESOLUTION should be used.
Sourcepub const fn samplerate(self) -> Reg<Samplerate, RW>
pub const fn samplerate(self) -> Reg<Samplerate, RW>
Controls normal or continuous sample rate
Trait Implementations§
impl Copy for Saadc
impl Eq for Saadc
impl Send for Saadc
impl StructuralPartialEq for Saadc
impl Sync for Saadc
Auto Trait Implementations§
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)