embassy-stm32

Crates

git

Versions

stm32f779ai

Flavors

Struct Fmc

Source
pub struct Fmc<'d, T: Instance> { /* private fields */ }
Expand description

FMC driver

Implementations§

Source§

impl<'d, T> Fmc<'d, T>
where T: Instance,

Source

pub fn new_raw(_instance: Peri<'d, T>) -> Self

Create a raw FMC instance.

Note: This is currently used to provide access to some basic FMC functions for manual configuration for memory types that stm32-fmc does not support.

Source

pub fn enable(&mut self)

Enable the FMC peripheral and reset it.

Source

pub fn memory_controller_enable(&mut self)

Enable the memory controller on applicable chips.

Source

pub fn source_clock_hz(&self) -> u32

Get the kernel clock currently in use for this FMC instance.

Source§

impl<'d, T: Instance> Fmc<'d, T>

Source

pub fn sdram_a12bits_d16bits_4banks_bank1<CHIP: SdramChip>( _instance: Peri<'d, T>, a0: Peri<'d, impl A0Pin<T>>, a1: Peri<'d, impl A1Pin<T>>, a2: Peri<'d, impl A2Pin<T>>, a3: Peri<'d, impl A3Pin<T>>, a4: Peri<'d, impl A4Pin<T>>, a5: Peri<'d, impl A5Pin<T>>, a6: Peri<'d, impl A6Pin<T>>, a7: Peri<'d, impl A7Pin<T>>, a8: Peri<'d, impl A8Pin<T>>, a9: Peri<'d, impl A9Pin<T>>, a10: Peri<'d, impl A10Pin<T>>, a11: Peri<'d, impl A11Pin<T>>, ba0: Peri<'d, impl BA0Pin<T>>, ba1: Peri<'d, impl BA1Pin<T>>, d0: Peri<'d, impl D0Pin<T>>, d1: Peri<'d, impl D1Pin<T>>, d2: Peri<'d, impl D2Pin<T>>, d3: Peri<'d, impl D3Pin<T>>, d4: Peri<'d, impl D4Pin<T>>, d5: Peri<'d, impl D5Pin<T>>, d6: Peri<'d, impl D6Pin<T>>, d7: Peri<'d, impl D7Pin<T>>, d8: Peri<'d, impl D8Pin<T>>, d9: Peri<'d, impl D9Pin<T>>, d10: Peri<'d, impl D10Pin<T>>, d11: Peri<'d, impl D11Pin<T>>, d12: Peri<'d, impl D12Pin<T>>, d13: Peri<'d, impl D13Pin<T>>, d14: Peri<'d, impl D14Pin<T>>, d15: Peri<'d, impl D15Pin<T>>, nbl0: Peri<'d, impl NBL0Pin<T>>, nbl1: Peri<'d, impl NBL1Pin<T>>, sdcke: Peri<'d, impl SDCKE0Pin<T>>, sdclk: Peri<'d, impl SDCLKPin<T>>, sdncas: Peri<'d, impl SDNCASPin<T>>, sdne: Peri<'d, impl SDNE0Pin<T>>, sdnras: Peri<'d, impl SDNRASPin<T>>, sdnwe: Peri<'d, impl SDNWEPin<T>>, chip: CHIP, ) -> Sdram<Fmc<'d, T>, CHIP>

Create a new FMC instance.

Source

pub fn sdram_a12bits_d32bits_4banks_bank1<CHIP: SdramChip>( _instance: Peri<'d, T>, a0: Peri<'d, impl A0Pin<T>>, a1: Peri<'d, impl A1Pin<T>>, a2: Peri<'d, impl A2Pin<T>>, a3: Peri<'d, impl A3Pin<T>>, a4: Peri<'d, impl A4Pin<T>>, a5: Peri<'d, impl A5Pin<T>>, a6: Peri<'d, impl A6Pin<T>>, a7: Peri<'d, impl A7Pin<T>>, a8: Peri<'d, impl A8Pin<T>>, a9: Peri<'d, impl A9Pin<T>>, a10: Peri<'d, impl A10Pin<T>>, a11: Peri<'d, impl A11Pin<T>>, ba0: Peri<'d, impl BA0Pin<T>>, ba1: Peri<'d, impl BA1Pin<T>>, d0: Peri<'d, impl D0Pin<T>>, d1: Peri<'d, impl D1Pin<T>>, d2: Peri<'d, impl D2Pin<T>>, d3: Peri<'d, impl D3Pin<T>>, d4: Peri<'d, impl D4Pin<T>>, d5: Peri<'d, impl D5Pin<T>>, d6: Peri<'d, impl D6Pin<T>>, d7: Peri<'d, impl D7Pin<T>>, d8: Peri<'d, impl D8Pin<T>>, d9: Peri<'d, impl D9Pin<T>>, d10: Peri<'d, impl D10Pin<T>>, d11: Peri<'d, impl D11Pin<T>>, d12: Peri<'d, impl D12Pin<T>>, d13: Peri<'d, impl D13Pin<T>>, d14: Peri<'d, impl D14Pin<T>>, d15: Peri<'d, impl D15Pin<T>>, d16: Peri<'d, impl D16Pin<T>>, d17: Peri<'d, impl D17Pin<T>>, d18: Peri<'d, impl D18Pin<T>>, d19: Peri<'d, impl D19Pin<T>>, d20: Peri<'d, impl D20Pin<T>>, d21: Peri<'d, impl D21Pin<T>>, d22: Peri<'d, impl D22Pin<T>>, d23: Peri<'d, impl D23Pin<T>>, d24: Peri<'d, impl D24Pin<T>>, d25: Peri<'d, impl D25Pin<T>>, d26: Peri<'d, impl D26Pin<T>>, d27: Peri<'d, impl D27Pin<T>>, d28: Peri<'d, impl D28Pin<T>>, d29: Peri<'d, impl D29Pin<T>>, d30: Peri<'d, impl D30Pin<T>>, d31: Peri<'d, impl D31Pin<T>>, nbl0: Peri<'d, impl NBL0Pin<T>>, nbl1: Peri<'d, impl NBL1Pin<T>>, nbl2: Peri<'d, impl NBL2Pin<T>>, nbl3: Peri<'d, impl NBL3Pin<T>>, sdcke: Peri<'d, impl SDCKE0Pin<T>>, sdclk: Peri<'d, impl SDCLKPin<T>>, sdncas: Peri<'d, impl SDNCASPin<T>>, sdne: Peri<'d, impl SDNE0Pin<T>>, sdnras: Peri<'d, impl SDNRASPin<T>>, sdnwe: Peri<'d, impl SDNWEPin<T>>, chip: CHIP, ) -> Sdram<Fmc<'d, T>, CHIP>

Create a new FMC instance.

Source

pub fn sdram_a13bits_d32bits_4banks_bank1<CHIP: SdramChip>( _instance: Peri<'d, T>, a0: Peri<'d, impl A0Pin<T>>, a1: Peri<'d, impl A1Pin<T>>, a2: Peri<'d, impl A2Pin<T>>, a3: Peri<'d, impl A3Pin<T>>, a4: Peri<'d, impl A4Pin<T>>, a5: Peri<'d, impl A5Pin<T>>, a6: Peri<'d, impl A6Pin<T>>, a7: Peri<'d, impl A7Pin<T>>, a8: Peri<'d, impl A8Pin<T>>, a9: Peri<'d, impl A9Pin<T>>, a10: Peri<'d, impl A10Pin<T>>, a11: Peri<'d, impl A11Pin<T>>, a12: Peri<'d, impl A12Pin<T>>, ba0: Peri<'d, impl BA0Pin<T>>, ba1: Peri<'d, impl BA1Pin<T>>, d0: Peri<'d, impl D0Pin<T>>, d1: Peri<'d, impl D1Pin<T>>, d2: Peri<'d, impl D2Pin<T>>, d3: Peri<'d, impl D3Pin<T>>, d4: Peri<'d, impl D4Pin<T>>, d5: Peri<'d, impl D5Pin<T>>, d6: Peri<'d, impl D6Pin<T>>, d7: Peri<'d, impl D7Pin<T>>, d8: Peri<'d, impl D8Pin<T>>, d9: Peri<'d, impl D9Pin<T>>, d10: Peri<'d, impl D10Pin<T>>, d11: Peri<'d, impl D11Pin<T>>, d12: Peri<'d, impl D12Pin<T>>, d13: Peri<'d, impl D13Pin<T>>, d14: Peri<'d, impl D14Pin<T>>, d15: Peri<'d, impl D15Pin<T>>, d16: Peri<'d, impl D16Pin<T>>, d17: Peri<'d, impl D17Pin<T>>, d18: Peri<'d, impl D18Pin<T>>, d19: Peri<'d, impl D19Pin<T>>, d20: Peri<'d, impl D20Pin<T>>, d21: Peri<'d, impl D21Pin<T>>, d22: Peri<'d, impl D22Pin<T>>, d23: Peri<'d, impl D23Pin<T>>, d24: Peri<'d, impl D24Pin<T>>, d25: Peri<'d, impl D25Pin<T>>, d26: Peri<'d, impl D26Pin<T>>, d27: Peri<'d, impl D27Pin<T>>, d28: Peri<'d, impl D28Pin<T>>, d29: Peri<'d, impl D29Pin<T>>, d30: Peri<'d, impl D30Pin<T>>, d31: Peri<'d, impl D31Pin<T>>, nbl0: Peri<'d, impl NBL0Pin<T>>, nbl1: Peri<'d, impl NBL1Pin<T>>, nbl2: Peri<'d, impl NBL2Pin<T>>, nbl3: Peri<'d, impl NBL3Pin<T>>, sdcke: Peri<'d, impl SDCKE0Pin<T>>, sdclk: Peri<'d, impl SDCLKPin<T>>, sdncas: Peri<'d, impl SDNCASPin<T>>, sdne: Peri<'d, impl SDNE0Pin<T>>, sdnras: Peri<'d, impl SDNRASPin<T>>, sdnwe: Peri<'d, impl SDNWEPin<T>>, chip: CHIP, ) -> Sdram<Fmc<'d, T>, CHIP>

Create a new FMC instance.

Source

pub fn sdram_a12bits_d16bits_4banks_bank2<CHIP: SdramChip>( _instance: Peri<'d, T>, a0: Peri<'d, impl A0Pin<T>>, a1: Peri<'d, impl A1Pin<T>>, a2: Peri<'d, impl A2Pin<T>>, a3: Peri<'d, impl A3Pin<T>>, a4: Peri<'d, impl A4Pin<T>>, a5: Peri<'d, impl A5Pin<T>>, a6: Peri<'d, impl A6Pin<T>>, a7: Peri<'d, impl A7Pin<T>>, a8: Peri<'d, impl A8Pin<T>>, a9: Peri<'d, impl A9Pin<T>>, a10: Peri<'d, impl A10Pin<T>>, a11: Peri<'d, impl A11Pin<T>>, ba0: Peri<'d, impl BA0Pin<T>>, ba1: Peri<'d, impl BA1Pin<T>>, d0: Peri<'d, impl D0Pin<T>>, d1: Peri<'d, impl D1Pin<T>>, d2: Peri<'d, impl D2Pin<T>>, d3: Peri<'d, impl D3Pin<T>>, d4: Peri<'d, impl D4Pin<T>>, d5: Peri<'d, impl D5Pin<T>>, d6: Peri<'d, impl D6Pin<T>>, d7: Peri<'d, impl D7Pin<T>>, d8: Peri<'d, impl D8Pin<T>>, d9: Peri<'d, impl D9Pin<T>>, d10: Peri<'d, impl D10Pin<T>>, d11: Peri<'d, impl D11Pin<T>>, d12: Peri<'d, impl D12Pin<T>>, d13: Peri<'d, impl D13Pin<T>>, d14: Peri<'d, impl D14Pin<T>>, d15: Peri<'d, impl D15Pin<T>>, nbl0: Peri<'d, impl NBL0Pin<T>>, nbl1: Peri<'d, impl NBL1Pin<T>>, sdcke: Peri<'d, impl SDCKE1Pin<T>>, sdclk: Peri<'d, impl SDCLKPin<T>>, sdncas: Peri<'d, impl SDNCASPin<T>>, sdne: Peri<'d, impl SDNE1Pin<T>>, sdnras: Peri<'d, impl SDNRASPin<T>>, sdnwe: Peri<'d, impl SDNWEPin<T>>, chip: CHIP, ) -> Sdram<Fmc<'d, T>, CHIP>

Create a new FMC instance.

Source

pub fn sdram_a12bits_d32bits_4banks_bank2<CHIP: SdramChip>( _instance: Peri<'d, T>, a0: Peri<'d, impl A0Pin<T>>, a1: Peri<'d, impl A1Pin<T>>, a2: Peri<'d, impl A2Pin<T>>, a3: Peri<'d, impl A3Pin<T>>, a4: Peri<'d, impl A4Pin<T>>, a5: Peri<'d, impl A5Pin<T>>, a6: Peri<'d, impl A6Pin<T>>, a7: Peri<'d, impl A7Pin<T>>, a8: Peri<'d, impl A8Pin<T>>, a9: Peri<'d, impl A9Pin<T>>, a10: Peri<'d, impl A10Pin<T>>, a11: Peri<'d, impl A11Pin<T>>, ba0: Peri<'d, impl BA0Pin<T>>, ba1: Peri<'d, impl BA1Pin<T>>, d0: Peri<'d, impl D0Pin<T>>, d1: Peri<'d, impl D1Pin<T>>, d2: Peri<'d, impl D2Pin<T>>, d3: Peri<'d, impl D3Pin<T>>, d4: Peri<'d, impl D4Pin<T>>, d5: Peri<'d, impl D5Pin<T>>, d6: Peri<'d, impl D6Pin<T>>, d7: Peri<'d, impl D7Pin<T>>, d8: Peri<'d, impl D8Pin<T>>, d9: Peri<'d, impl D9Pin<T>>, d10: Peri<'d, impl D10Pin<T>>, d11: Peri<'d, impl D11Pin<T>>, d12: Peri<'d, impl D12Pin<T>>, d13: Peri<'d, impl D13Pin<T>>, d14: Peri<'d, impl D14Pin<T>>, d15: Peri<'d, impl D15Pin<T>>, d16: Peri<'d, impl D16Pin<T>>, d17: Peri<'d, impl D17Pin<T>>, d18: Peri<'d, impl D18Pin<T>>, d19: Peri<'d, impl D19Pin<T>>, d20: Peri<'d, impl D20Pin<T>>, d21: Peri<'d, impl D21Pin<T>>, d22: Peri<'d, impl D22Pin<T>>, d23: Peri<'d, impl D23Pin<T>>, d24: Peri<'d, impl D24Pin<T>>, d25: Peri<'d, impl D25Pin<T>>, d26: Peri<'d, impl D26Pin<T>>, d27: Peri<'d, impl D27Pin<T>>, d28: Peri<'d, impl D28Pin<T>>, d29: Peri<'d, impl D29Pin<T>>, d30: Peri<'d, impl D30Pin<T>>, d31: Peri<'d, impl D31Pin<T>>, nbl0: Peri<'d, impl NBL0Pin<T>>, nbl1: Peri<'d, impl NBL1Pin<T>>, nbl2: Peri<'d, impl NBL2Pin<T>>, nbl3: Peri<'d, impl NBL3Pin<T>>, sdcke: Peri<'d, impl SDCKE1Pin<T>>, sdclk: Peri<'d, impl SDCLKPin<T>>, sdncas: Peri<'d, impl SDNCASPin<T>>, sdne: Peri<'d, impl SDNE1Pin<T>>, sdnras: Peri<'d, impl SDNRASPin<T>>, sdnwe: Peri<'d, impl SDNWEPin<T>>, chip: CHIP, ) -> Sdram<Fmc<'d, T>, CHIP>

Create a new FMC instance.

Source

pub fn sdram_a13bits_d32bits_4banks_bank2<CHIP: SdramChip>( _instance: Peri<'d, T>, a0: Peri<'d, impl A0Pin<T>>, a1: Peri<'d, impl A1Pin<T>>, a2: Peri<'d, impl A2Pin<T>>, a3: Peri<'d, impl A3Pin<T>>, a4: Peri<'d, impl A4Pin<T>>, a5: Peri<'d, impl A5Pin<T>>, a6: Peri<'d, impl A6Pin<T>>, a7: Peri<'d, impl A7Pin<T>>, a8: Peri<'d, impl A8Pin<T>>, a9: Peri<'d, impl A9Pin<T>>, a10: Peri<'d, impl A10Pin<T>>, a11: Peri<'d, impl A11Pin<T>>, a12: Peri<'d, impl A12Pin<T>>, ba0: Peri<'d, impl BA0Pin<T>>, ba1: Peri<'d, impl BA1Pin<T>>, d0: Peri<'d, impl D0Pin<T>>, d1: Peri<'d, impl D1Pin<T>>, d2: Peri<'d, impl D2Pin<T>>, d3: Peri<'d, impl D3Pin<T>>, d4: Peri<'d, impl D4Pin<T>>, d5: Peri<'d, impl D5Pin<T>>, d6: Peri<'d, impl D6Pin<T>>, d7: Peri<'d, impl D7Pin<T>>, d8: Peri<'d, impl D8Pin<T>>, d9: Peri<'d, impl D9Pin<T>>, d10: Peri<'d, impl D10Pin<T>>, d11: Peri<'d, impl D11Pin<T>>, d12: Peri<'d, impl D12Pin<T>>, d13: Peri<'d, impl D13Pin<T>>, d14: Peri<'d, impl D14Pin<T>>, d15: Peri<'d, impl D15Pin<T>>, d16: Peri<'d, impl D16Pin<T>>, d17: Peri<'d, impl D17Pin<T>>, d18: Peri<'d, impl D18Pin<T>>, d19: Peri<'d, impl D19Pin<T>>, d20: Peri<'d, impl D20Pin<T>>, d21: Peri<'d, impl D21Pin<T>>, d22: Peri<'d, impl D22Pin<T>>, d23: Peri<'d, impl D23Pin<T>>, d24: Peri<'d, impl D24Pin<T>>, d25: Peri<'d, impl D25Pin<T>>, d26: Peri<'d, impl D26Pin<T>>, d27: Peri<'d, impl D27Pin<T>>, d28: Peri<'d, impl D28Pin<T>>, d29: Peri<'d, impl D29Pin<T>>, d30: Peri<'d, impl D30Pin<T>>, d31: Peri<'d, impl D31Pin<T>>, nbl0: Peri<'d, impl NBL0Pin<T>>, nbl1: Peri<'d, impl NBL1Pin<T>>, nbl2: Peri<'d, impl NBL2Pin<T>>, nbl3: Peri<'d, impl NBL3Pin<T>>, sdcke: Peri<'d, impl SDCKE1Pin<T>>, sdclk: Peri<'d, impl SDCLKPin<T>>, sdncas: Peri<'d, impl SDNCASPin<T>>, sdne: Peri<'d, impl SDNE1Pin<T>>, sdnras: Peri<'d, impl SDNRASPin<T>>, sdnwe: Peri<'d, impl SDNWEPin<T>>, chip: CHIP, ) -> Sdram<Fmc<'d, T>, CHIP>

Create a new FMC instance.

Trait Implementations§

Source§

impl<'d, T> FmcPeripheral for Fmc<'d, T>
where T: Instance,

Source§

const REGISTERS: *const ()

Pointer to the register block
Source§

fn enable(&mut self)

Enables the FMC on its peripheral bus
Source§

fn memory_controller_enable(&mut self)

Enables the FMC memory controller (not always required)
Source§

fn source_clock_hz(&self) -> u32

The frequency of the clock used as a source for the fmc_clk. Read more
Source§

impl<'d, T> Send for Fmc<'d, T>
where T: Instance,

Auto Trait Implementations§

§

impl<'d, T> Freeze for Fmc<'d, T>

§

impl<'d, T> RefUnwindSafe for Fmc<'d, T>
where T: RefUnwindSafe,

§

impl<'d, T> Sync for Fmc<'d, T>
where T: Sync,

§

impl<'d, T> Unpin for Fmc<'d, T>

§

impl<'d, T> !UnwindSafe for Fmc<'d, T>

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.