embassy-rp

Crates

git

Versions

rp2040

Flavors

embassy_rp

Struct Peripherals

Source
pub struct Peripherals {
Show 72 fields pub PIN_0: PIN_0, pub PIN_1: PIN_1, pub PIN_2: PIN_2, pub PIN_3: PIN_3, pub PIN_4: PIN_4, pub PIN_5: PIN_5, pub PIN_6: PIN_6, pub PIN_7: PIN_7, pub PIN_8: PIN_8, pub PIN_9: PIN_9, pub PIN_10: PIN_10, pub PIN_11: PIN_11, pub PIN_12: PIN_12, pub PIN_13: PIN_13, pub PIN_14: PIN_14, pub PIN_15: PIN_15, pub PIN_16: PIN_16, pub PIN_17: PIN_17, pub PIN_18: PIN_18, pub PIN_19: PIN_19, pub PIN_20: PIN_20, pub PIN_21: PIN_21, pub PIN_22: PIN_22, pub PIN_23: PIN_23, pub PIN_24: PIN_24, pub PIN_25: PIN_25, pub PIN_26: PIN_26, pub PIN_27: PIN_27, pub PIN_28: PIN_28, pub PIN_29: PIN_29, pub PIN_QSPI_SCLK: PIN_QSPI_SCLK, pub PIN_QSPI_SS: PIN_QSPI_SS, pub PIN_QSPI_SD0: PIN_QSPI_SD0, pub PIN_QSPI_SD1: PIN_QSPI_SD1, pub PIN_QSPI_SD2: PIN_QSPI_SD2, pub PIN_QSPI_SD3: PIN_QSPI_SD3, pub UART0: UART0, pub UART1: UART1, pub SPI0: SPI0, pub SPI1: SPI1, pub I2C0: I2C0, pub I2C1: I2C1, pub DMA_CH0: DMA_CH0, pub DMA_CH1: DMA_CH1, pub DMA_CH2: DMA_CH2, pub DMA_CH3: DMA_CH3, pub DMA_CH4: DMA_CH4, pub DMA_CH5: DMA_CH5, pub DMA_CH6: DMA_CH6, pub DMA_CH7: DMA_CH7, pub DMA_CH8: DMA_CH8, pub DMA_CH9: DMA_CH9, pub DMA_CH10: DMA_CH10, pub DMA_CH11: DMA_CH11, pub PWM_SLICE0: PWM_SLICE0, pub PWM_SLICE1: PWM_SLICE1, pub PWM_SLICE2: PWM_SLICE2, pub PWM_SLICE3: PWM_SLICE3, pub PWM_SLICE4: PWM_SLICE4, pub PWM_SLICE5: PWM_SLICE5, pub PWM_SLICE6: PWM_SLICE6, pub PWM_SLICE7: PWM_SLICE7, pub USB: USB, pub RTC: RTC, pub FLASH: FLASH, pub ADC: ADC, pub ADC_TEMP_SENSOR: ADC_TEMP_SENSOR, pub CORE1: CORE1, pub PIO0: PIO0, pub PIO1: PIO1, pub WATCHDOG: WATCHDOG, pub BOOTSEL: BOOTSEL,
}
Expand description

Struct containing all the peripheral singletons.

To obtain the peripherals, you must initialize the HAL, by calling crate::init.

Fields§

§PIN_0: PIN_0

PIN_0 peripheral

§PIN_1: PIN_1

PIN_1 peripheral

§PIN_2: PIN_2

PIN_2 peripheral

§PIN_3: PIN_3

PIN_3 peripheral

§PIN_4: PIN_4

PIN_4 peripheral

§PIN_5: PIN_5

PIN_5 peripheral

§PIN_6: PIN_6

PIN_6 peripheral

§PIN_7: PIN_7

PIN_7 peripheral

§PIN_8: PIN_8

PIN_8 peripheral

§PIN_9: PIN_9

PIN_9 peripheral

§PIN_10: PIN_10

PIN_10 peripheral

§PIN_11: PIN_11

PIN_11 peripheral

§PIN_12: PIN_12

PIN_12 peripheral

§PIN_13: PIN_13

PIN_13 peripheral

§PIN_14: PIN_14

PIN_14 peripheral

§PIN_15: PIN_15

PIN_15 peripheral

§PIN_16: PIN_16

PIN_16 peripheral

§PIN_17: PIN_17

PIN_17 peripheral

§PIN_18: PIN_18

PIN_18 peripheral

§PIN_19: PIN_19

PIN_19 peripheral

§PIN_20: PIN_20

PIN_20 peripheral

§PIN_21: PIN_21

PIN_21 peripheral

§PIN_22: PIN_22

PIN_22 peripheral

§PIN_23: PIN_23

PIN_23 peripheral

§PIN_24: PIN_24

PIN_24 peripheral

§PIN_25: PIN_25

PIN_25 peripheral

§PIN_26: PIN_26

PIN_26 peripheral

§PIN_27: PIN_27

PIN_27 peripheral

§PIN_28: PIN_28

PIN_28 peripheral

§PIN_29: PIN_29

PIN_29 peripheral

§PIN_QSPI_SCLK: PIN_QSPI_SCLK

PIN_QSPI_SCLK peripheral

§PIN_QSPI_SS: PIN_QSPI_SS

PIN_QSPI_SS peripheral

§PIN_QSPI_SD0: PIN_QSPI_SD0

PIN_QSPI_SD0 peripheral

§PIN_QSPI_SD1: PIN_QSPI_SD1

PIN_QSPI_SD1 peripheral

§PIN_QSPI_SD2: PIN_QSPI_SD2

PIN_QSPI_SD2 peripheral

§PIN_QSPI_SD3: PIN_QSPI_SD3

PIN_QSPI_SD3 peripheral

§UART0: UART0

UART0 peripheral

§UART1: UART1

UART1 peripheral

§SPI0: SPI0

SPI0 peripheral

§SPI1: SPI1

SPI1 peripheral

§I2C0: I2C0

I2C0 peripheral

§I2C1: I2C1

I2C1 peripheral

§DMA_CH0: DMA_CH0

DMA_CH0 peripheral

§DMA_CH1: DMA_CH1

DMA_CH1 peripheral

§DMA_CH2: DMA_CH2

DMA_CH2 peripheral

§DMA_CH3: DMA_CH3

DMA_CH3 peripheral

§DMA_CH4: DMA_CH4

DMA_CH4 peripheral

§DMA_CH5: DMA_CH5

DMA_CH5 peripheral

§DMA_CH6: DMA_CH6

DMA_CH6 peripheral

§DMA_CH7: DMA_CH7

DMA_CH7 peripheral

§DMA_CH8: DMA_CH8

DMA_CH8 peripheral

§DMA_CH9: DMA_CH9

DMA_CH9 peripheral

§DMA_CH10: DMA_CH10

DMA_CH10 peripheral

§DMA_CH11: DMA_CH11

DMA_CH11 peripheral

§PWM_SLICE0: PWM_SLICE0

PWM_SLICE0 peripheral

§PWM_SLICE1: PWM_SLICE1

PWM_SLICE1 peripheral

§PWM_SLICE2: PWM_SLICE2

PWM_SLICE2 peripheral

§PWM_SLICE3: PWM_SLICE3

PWM_SLICE3 peripheral

§PWM_SLICE4: PWM_SLICE4

PWM_SLICE4 peripheral

§PWM_SLICE5: PWM_SLICE5

PWM_SLICE5 peripheral

§PWM_SLICE6: PWM_SLICE6

PWM_SLICE6 peripheral

§PWM_SLICE7: PWM_SLICE7

PWM_SLICE7 peripheral

§USB: USB

USB peripheral

§RTC: RTC

RTC peripheral

§FLASH: FLASH

FLASH peripheral

§ADC: ADC

ADC peripheral

§ADC_TEMP_SENSOR: ADC_TEMP_SENSOR

ADC_TEMP_SENSOR peripheral

§CORE1: CORE1

CORE1 peripheral

§PIO0: PIO0

PIO0 peripheral

§PIO1: PIO1

PIO1 peripheral

§WATCHDOG: WATCHDOG

WATCHDOG peripheral

§BOOTSEL: BOOTSEL

BOOTSEL peripheral

Implementations§

Source§

impl Peripherals

Source

pub unsafe fn steal() -> Self

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.

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> Az for T

Source§

fn az<Dst>(self) -> Dst
where T: Cast<Dst>,

Casts the value.
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<Src, Dst> CastFrom<Src> for Dst
where Src: Cast<Dst>,

Source§

fn cast_from(src: Src) -> Dst

Casts the value.
Source§

impl<T> CheckedAs for T

Source§

fn checked_as<Dst>(self) -> Option<Dst>
where T: CheckedCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> CheckedCastFrom<Src> for Dst
where Src: CheckedCast<Dst>,

Source§

fn checked_cast_from(src: Src) -> Option<Dst>

Casts the value.
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<Src, Dst> LosslessTryInto<Dst> for Src
where Dst: LosslessTryFrom<Src>,

Source§

fn lossless_try_into(self) -> Option<Dst>

Performs the conversion.
Source§

impl<Src, Dst> LossyInto<Dst> for Src
where Dst: LossyFrom<Src>,

Source§

fn lossy_into(self) -> Dst

Performs the conversion.
Source§

impl<T> OverflowingAs for T

Source§

fn overflowing_as<Dst>(self) -> (Dst, bool)
where T: OverflowingCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> OverflowingCastFrom<Src> for Dst
where Src: OverflowingCast<Dst>,

Source§

fn overflowing_cast_from(src: Src) -> (Dst, bool)

Casts the value.
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> SaturatingAs for T

Source§

fn saturating_as<Dst>(self) -> Dst
where T: SaturatingCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> SaturatingCastFrom<Src> for Dst
where Src: SaturatingCast<Dst>,

Source§

fn saturating_cast_from(src: Src) -> Dst

Casts the value.
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.
Source§

impl<T> UnwrappedAs for T

Source§

fn unwrapped_as<Dst>(self) -> Dst
where T: UnwrappedCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> UnwrappedCastFrom<Src> for Dst
where Src: UnwrappedCast<Dst>,

Source§

fn unwrapped_cast_from(src: Src) -> Dst

Casts the value.
Source§

impl<T> WrappingAs for T

Source§

fn wrapping_as<Dst>(self) -> Dst
where T: WrappingCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> WrappingCastFrom<Src> for Dst
where Src: WrappingCast<Dst>,

Source§

fn wrapping_cast_from(src: Src) -> Dst

Casts the value.