pub struct AdcConfig { /* private fields */ }
Expand description
Configuration for the adc. There are some additional parameters on the adc peripheral that can be added here when needed but this covers several basic usecases.
Implementations§
Source§impl AdcConfig
impl AdcConfig
Sourcepub fn resolution(self, resolution: Resolution) -> Self
pub fn resolution(self, resolution: Resolution) -> Self
change the resolution field
Sourcepub fn external_trigger(
self,
trigger_mode: TriggerMode,
trigger: ExternalTrigger,
) -> Self
pub fn external_trigger( self, trigger_mode: TriggerMode, trigger: ExternalTrigger, ) -> Self
change the external_trigger field
Sourcepub fn continuous(self, continuous: Continuous) -> Self
pub fn continuous(self, continuous: Continuous) -> Self
change the continuous field
Sourcepub fn end_of_conversion_interrupt(
self,
end_of_conversion_interrupt: Eoc,
) -> Self
pub fn end_of_conversion_interrupt( self, end_of_conversion_interrupt: Eoc, ) -> Self
change the end_of_conversion_interrupt field
Sourcepub fn default_sample_time(self, default_sample_time: SampleTime) -> Self
pub fn default_sample_time(self, default_sample_time: SampleTime) -> Self
change the default_sample_time field
Sourcepub fn reference_voltage(self, vdda_mv: u32) -> Self
pub fn reference_voltage(self, vdda_mv: u32) -> Self
Trait Implementations§
Source§impl Format for AdcConfigwhere
Clock: Format,
Resolution: Format,
Align: Format,
Scan: Format,
(TriggerMode, ExternalTrigger): Format,
Continuous: Format,
Dma: Format,
Eoc: Format,
SampleTime: Format,
Option<u32>: Format,
impl Format for AdcConfigwhere
Clock: Format,
Resolution: Format,
Align: Format,
Scan: Format,
(TriggerMode, ExternalTrigger): Format,
Continuous: Format,
Dma: Format,
Eoc: Format,
SampleTime: Format,
Option<u32>: Format,
impl Copy for AdcConfig
impl Eq for AdcConfig
impl StructuralPartialEq for AdcConfig
Auto Trait Implementations§
impl Freeze for AdcConfig
impl RefUnwindSafe for AdcConfig
impl Send for AdcConfig
impl Sync for AdcConfig
impl Unpin for AdcConfig
impl UnwindSafe for AdcConfig
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