[][src]Struct stm32l4xx_hal::tsc::Tsc

pub struct Tsc<SPIN> { /* fields omitted */ }

Methods

impl<SPIN> Tsc<SPIN>[src]

pub fn tsc(
    tsc: TSC,
    sample_pin: SPIN,
    ahb: &mut AHB1,
    cfg: Option<Config>
) -> Self where
    SPIN: SamplePin<TSC>, 
[src]

pub fn start<PIN>(&self, _input: &mut PIN) where
    PIN: ChannelPin<TSC>, 
[src]

Starts a charge acquisition

pub fn clear(&self, event: Event)[src]

Clear interrupt & flags

pub fn acquire<PIN>(&self, input: &mut PIN) -> Result<u16, Error> where
    PIN: ChannelPin<TSC>, 
[src]

Blocks waiting for a acquisition to complete or for a Max Count Error

pub fn read<PIN>(&self, _input: &mut PIN) -> Result<u16, Error> where
    PIN: ChannelPin<TSC>, 
[src]

Reads the tsc group 2 count register

pub fn read_unchecked(&self) -> u16[src]

Reads the tsc group 2 count register WARNING, just returns the contents of the register! No validation of the correct pin

pub fn in_progress(&mut self) -> bool[src]

Is the tsc performing an aquisition

pub fn listen(&mut self, event: Event)[src]

Enables an interrupt event

pub fn unlisten(&self, event: Event)[src]

Disables an interrupt event

pub fn free(self) -> (TSC, SPIN)[src]

Releases the TSC peripheral and associated pins

Auto Trait Implementations

impl<SPIN> Send for Tsc<SPIN> where
    SPIN: Send

impl<SPIN> !Sync for Tsc<SPIN>

Blanket Implementations

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Same for T

type Output = T

Should always be Self