Struct esp32_hal::peripherals::PCNT

source ·
pub struct PCNT { /* private fields */ }

Implementations§

source§

impl PCNT

source

pub unsafe fn steal() -> PCNT

Unsafely create an instance of this peripheral out of thin air.

§Safety

You must ensure that you’re only using one instance of this type at a time.

source

pub const PTR: *const <PCNT as Deref>::Target = {0x3ff57000 as *const <esp32::PCNT as core::ops::Deref>::Target}

Pointer to the register block

source

pub const fn ptr() -> *const <PCNT as Deref>::Target

Return the pointer to the register block

Methods from Deref<Target = RegisterBlock>§

source

pub fn u_conf0(&self, n: usize) -> &Reg<U_CONF0_SPEC>

0x00..0x20 -

source

pub fn u_conf0_iter(&self) -> impl Iterator<Item = &Reg<U_CONF0_SPEC>>

Iterator for array of: 0x00..0x20 -

source

pub fn u0_conf0(&self) -> &Reg<U_CONF0_SPEC>

0x00 - U0_CONF0

source

pub fn u1_conf0(&self) -> &Reg<U_CONF0_SPEC>

0x0c - U1_CONF0

source

pub fn u2_conf0(&self) -> &Reg<U_CONF0_SPEC>

0x18 - U2_CONF0

source

pub fn u3_conf0(&self) -> &Reg<U_CONF0_SPEC>

0x24 - U3_CONF0

source

pub fn u4_conf0(&self) -> &Reg<U_CONF0_SPEC>

0x30 - U4_CONF0

source

pub fn u5_conf0(&self) -> &Reg<U_CONF0_SPEC>

0x3c - U5_CONF0

source

pub fn u6_conf0(&self) -> &Reg<U_CONF0_SPEC>

0x48 - U6_CONF0

source

pub fn u7_conf0(&self) -> &Reg<U_CONF0_SPEC>

0x54 - U7_CONF0

source

pub fn u_conf1(&self, n: usize) -> &Reg<U_CONF1_SPEC>

0x04..0x24 -

source

pub fn u_conf1_iter(&self) -> impl Iterator<Item = &Reg<U_CONF1_SPEC>>

Iterator for array of: 0x04..0x24 -

source

pub fn u0_conf1(&self) -> &Reg<U_CONF1_SPEC>

0x04 - U0_CONF1

source

pub fn u1_conf1(&self) -> &Reg<U_CONF1_SPEC>

0x10 - U1_CONF1

source

pub fn u2_conf1(&self) -> &Reg<U_CONF1_SPEC>

0x1c - U2_CONF1

source

pub fn u3_conf1(&self) -> &Reg<U_CONF1_SPEC>

0x28 - U3_CONF1

source

pub fn u4_conf1(&self) -> &Reg<U_CONF1_SPEC>

0x34 - U4_CONF1

source

pub fn u5_conf1(&self) -> &Reg<U_CONF1_SPEC>

0x40 - U5_CONF1

source

pub fn u6_conf1(&self) -> &Reg<U_CONF1_SPEC>

0x4c - U6_CONF1

source

pub fn u7_conf1(&self) -> &Reg<U_CONF1_SPEC>

0x58 - U7_CONF1

source

pub fn u_conf2(&self, n: usize) -> &Reg<U_CONF2_SPEC>

0x08..0x28 -

source

pub fn u_conf2_iter(&self) -> impl Iterator<Item = &Reg<U_CONF2_SPEC>>

Iterator for array of: 0x08..0x28 -

source

pub fn u0_conf2(&self) -> &Reg<U_CONF2_SPEC>

0x08 - U0_CONF2

source

pub fn u1_conf2(&self) -> &Reg<U_CONF2_SPEC>

0x14 - U1_CONF2

source

pub fn u2_conf2(&self) -> &Reg<U_CONF2_SPEC>

0x20 - U2_CONF2

source

pub fn u3_conf2(&self) -> &Reg<U_CONF2_SPEC>

0x2c - U3_CONF2

source

pub fn u4_conf2(&self) -> &Reg<U_CONF2_SPEC>

0x38 - U4_CONF2

source

pub fn u5_conf2(&self) -> &Reg<U_CONF2_SPEC>

0x44 - U5_CONF2

source

pub fn u6_conf2(&self) -> &Reg<U_CONF2_SPEC>

0x50 - U6_CONF2

source

pub fn u7_conf2(&self) -> &Reg<U_CONF2_SPEC>

0x5c - U7_CONF2

source

pub fn u_cnt(&self, n: usize) -> &Reg<U_CNT_SPEC>

0x60..0x80 -

source

pub fn u_cnt_iter(&self) -> impl Iterator<Item = &Reg<U_CNT_SPEC>>

Iterator for array of: 0x60..0x80 -

source

pub fn u0_cnt(&self) -> &Reg<U_CNT_SPEC>

0x60 - U0_CNT

source

pub fn u1_cnt(&self) -> &Reg<U_CNT_SPEC>

0x64 - U1_CNT

source

pub fn u2_cnt(&self) -> &Reg<U_CNT_SPEC>

0x68 - U2_CNT

source

pub fn u3_cnt(&self) -> &Reg<U_CNT_SPEC>

0x6c - U3_CNT

source

pub fn u4_cnt(&self) -> &Reg<U_CNT_SPEC>

0x70 - U4_CNT

source

pub fn u5_cnt(&self) -> &Reg<U_CNT_SPEC>

0x74 - U5_CNT

source

pub fn u6_cnt(&self) -> &Reg<U_CNT_SPEC>

0x78 - U6_CNT

source

pub fn u7_cnt(&self) -> &Reg<U_CNT_SPEC>

0x7c - U7_CNT

source

pub fn int_raw(&self) -> &Reg<INT_RAW_SPEC>

0x80 -

source

pub fn int_st(&self) -> &Reg<INT_ST_SPEC>

0x84 -

source

pub fn int_ena(&self) -> &Reg<INT_ENA_SPEC>

0x88 -

source

pub fn int_clr(&self) -> &Reg<INT_CLR_SPEC>

0x8c -

source

pub fn u_status(&self, n: usize) -> &Reg<U_STATUS_SPEC>

0x90..0xb0 -

source

pub fn u_status_iter(&self) -> impl Iterator<Item = &Reg<U_STATUS_SPEC>>

Iterator for array of: 0x90..0xb0 -

source

pub fn u0_status(&self) -> &Reg<U_STATUS_SPEC>

0x90 - U0_STATUS

source

pub fn u1_status(&self) -> &Reg<U_STATUS_SPEC>

0x94 - U1_STATUS

source

pub fn u2_status(&self) -> &Reg<U_STATUS_SPEC>

0x98 - U2_STATUS

source

pub fn u3_status(&self) -> &Reg<U_STATUS_SPEC>

0x9c - U3_STATUS

source

pub fn u4_status(&self) -> &Reg<U_STATUS_SPEC>

0xa0 - U4_STATUS

source

pub fn u5_status(&self) -> &Reg<U_STATUS_SPEC>

0xa4 - U5_STATUS

source

pub fn u6_status(&self) -> &Reg<U_STATUS_SPEC>

0xa8 - U6_STATUS

source

pub fn u7_status(&self) -> &Reg<U_STATUS_SPEC>

0xac - U7_STATUS

source

pub fn ctrl(&self) -> &Reg<CTRL_SPEC>

0xb0 -

source

pub fn date(&self) -> &Reg<DATE_SPEC>

0xfc -

Trait Implementations§

source§

impl Debug for PCNT

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl Deref for PCNT

§

type Target = <PCNT as Deref>::Target

The resulting type after dereferencing.
source§

fn deref(&self) -> &<PCNT as Deref>::Target

Dereferences the value.
source§

impl DerefMut for PCNT

source§

fn deref_mut(&mut self) -> &mut <PCNT as Deref>::Target

Mutably dereferences the value.
source§

impl Peripheral for PCNT

§

type P = PCNT

Peripheral singleton type
source§

unsafe fn clone_unchecked(&mut self) -> <PCNT as Peripheral>::P

Unsafely clone (duplicate) a peripheral singleton. Read more
source§

fn into_ref<'a>(self) -> PeripheralRef<'a, Self::P>
where Self: 'a,

Convert a value into a PeripheralRef. Read more

Auto Trait Implementations§

§

impl RefUnwindSafe for PCNT

§

impl Send for PCNT

§

impl Sync for PCNT

§

impl Unpin for PCNT

§

impl UnwindSafe for PCNT

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.