Skip to main content

Peripherals

Struct Peripherals 

Source
pub struct Peripherals {
Show 46 fields pub WDT: WDT, pub RTCC: RTCC, pub TMR1: TMR1, pub TMR2: TMR2, pub TMR3: TMR3, pub TMR4: TMR4, pub TMR5: TMR5, pub ICAP1: ICAP1, pub ICAP2: ICAP2, pub ICAP3: ICAP3, pub ICAP4: ICAP4, pub ICAP5: ICAP5, pub OCMP1: OCMP1, pub OCMP2: OCMP2, pub OCMP3: OCMP3, pub OCMP4: OCMP4, pub OCMP5: OCMP5, pub I2C1: I2C1, pub I2C2: I2C2, pub SPI1: SPI1, pub SPI2: SPI2, pub UART1: UART1, pub UART2: UART2, pub PMP: PMP, pub ADC: ADC, pub CVR: CVR, pub CMP1: CMP1, pub CMP2: CMP2, pub CMP3: CMP3, pub CMP: CMP, pub CTMU: CTMU, pub OSC: OSC, pub CFG: CFG, pub NVM: NVM, pub RCON: RCON, pub PPS: PPS, pub INT: INT, pub BMX: BMX, pub DMAC: DMAC, pub DMAC0: DMAC0, pub DMAC1: DMAC1, pub DMAC2: DMAC2, pub DMAC3: DMAC3, pub USB: USB, pub PORTA: PORTA, pub PORTB: PORTB,
}
Expand description

All the peripherals.

Fields§

§WDT: WDT

WDT

§RTCC: RTCC

RTCC

§TMR1: TMR1

TMR1

§TMR2: TMR2

TMR2

§TMR3: TMR3

TMR3

§TMR4: TMR4

TMR4

§TMR5: TMR5

TMR5

§ICAP1: ICAP1

ICAP1

§ICAP2: ICAP2

ICAP2

§ICAP3: ICAP3

ICAP3

§ICAP4: ICAP4

ICAP4

§ICAP5: ICAP5

ICAP5

§OCMP1: OCMP1

OCMP1

§OCMP2: OCMP2

OCMP2

§OCMP3: OCMP3

OCMP3

§OCMP4: OCMP4

OCMP4

§OCMP5: OCMP5

OCMP5

§I2C1: I2C1

I2C1

§I2C2: I2C2

I2C2

§SPI1: SPI1

SPI1

§SPI2: SPI2

SPI2

§UART1: UART1

UART1

§UART2: UART2

UART2

§PMP: PMP

PMP

§ADC: ADC

ADC

§CVR: CVR

CVR

§CMP1: CMP1

CMP1

§CMP2: CMP2

CMP2

§CMP3: CMP3

CMP3

§CMP: CMP

CMP

§CTMU: CTMU

CTMU

§OSC: OSC

OSC

§CFG: CFG

CFG

§NVM: NVM

NVM

§RCON: RCON

RCON

§PPS: PPS

PPS

§INT: INT

INT

§BMX: BMX

BMX

§DMAC: DMAC

DMAC

§DMAC0: DMAC0

DMAC0

§DMAC1: DMAC1

DMAC1

§DMAC2: DMAC2

DMAC2

§DMAC3: DMAC3

DMAC3

§USB: USB

USB

§PORTA: PORTA

PORTA

§PORTB: PORTB

PORTB

Implementations§

Source§

impl Peripherals

Source

pub fn take() -> Option<Peripherals>

Returns all the peripherals once.

Source

pub unsafe fn steal() -> Peripherals

Unchecked version of Peripherals::take.

§Safety

Each of the returned peripherals must be used at most once.

Auto Trait Implementations§

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>,

Source§

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>,

Source§

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.