Skip to main content

AdcChannels

Trait AdcChannels 

Source
pub trait AdcChannels {
    type AdcUnit: AdcUnit;
    type Iterator<'a>: Iterator<Item = (adc_channel_t, adc_atten_t)>
       where Self: 'a;

    // Required method
    fn iter(&self) -> Self::Iterator<'_>;
}

Required Associated Types§

Source

type AdcUnit: AdcUnit

Source

type Iterator<'a>: Iterator<Item = (adc_channel_t, adc_atten_t)> where Self: 'a

Required Methods§

Source

fn iter(&self) -> Self::Iterator<'_>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<A> AdcChannels for EmptyAdcChannels<A>
where A: AdcUnit,

Source§

type AdcUnit = A

Source§

type Iterator<'a> = Empty<(u32, u32)> where Self: 'a

Source§

impl<C, const N: usize> AdcChannels for AdcChannelsArray<C, N>
where C: AdcChannels,

Source§

type AdcUnit = <C as AdcChannels>::AdcUnit

Source§

type Iterator<'a> = FlatMap<Iter<'a, C>, <C as AdcChannels>::Iterator<'a>, fn(&'a C) -> <C as AdcChannels>::Iterator<'a>> where Self: 'a

Source§

impl<F, S> AdcChannels for ChainedAdcChannels<F, S>
where F: AdcChannels, S: AdcChannels<AdcUnit = F::AdcUnit>,

Source§

type AdcUnit = <F as AdcChannels>::AdcUnit

Source§

type Iterator<'a> = Chain<<F as AdcChannels>::Iterator<'a>, <S as AdcChannels>::Iterator<'a>> where Self: 'a

Source§

impl<P> AdcChannels for P
where P: ADCPin,

Source§

type AdcUnit = <<P as ADCPin>::AdcChannel as AdcChannel>::AdcUnit

Source§

type Iterator<'a> = Once<(u32, u32)> where Self: 'a

Source§

impl<const A: adc_atten_t, C> AdcChannels for Attenuated<A, C>
where C: AdcChannels,

Source§

type AdcUnit = <C as AdcChannels>::AdcUnit

Source§

type Iterator<'a> = Map<<C as AdcChannels>::Iterator<'a>, fn((u32, u32)) -> (u32, u32)> where Self: 'a