[−][src]Struct stm32_fmc::Sdram
SDRAM Controller
Implementations
impl<IC: SdramChip, FMC: FmcPeripheral> Sdram<FMC, IC>
[src]
pub fn new<PINS, BANK>(fmc: FMC, _pins: PINS, _chip: IC) -> Self where
PINS: PinsSdram<BANK>,
BANK: SdramPinSet,
[src]
PINS: PinsSdram<BANK>,
BANK: SdramPinSet,
New SDRAM instance
_pins
must be a set of pins connecting to an SDRAM on the FMC
controller
Panics
-
Panics if there are not enough address lines in
PINS
to access the whole SDRAM -
Panics if there are not enough bank address lines in
PINS
to access the whole SDRAM
pub fn new_unchecked(
fmc: FMC,
bank: impl Into<SdramTargetBank>,
_chip: IC
) -> Self
[src]
fmc: FMC,
bank: impl Into<SdramTargetBank>,
_chip: IC
) -> Self
New SDRAM instance
bank
denotes which SDRAM bank to target. This can be either bank 1 or
bank 2.
Safety
The pins are not checked against the requirements for the SDRAM chip. So you may be able to initialise a SDRAM without enough pins to access the whole memory
pub fn init<D>(&mut self, delay: &mut D) -> *mut u32 where
D: DelayUs<u8>,
[src]
D: DelayUs<u8>,
Initialise SDRAM instance. Delay is used to wait the SDRAM powerup delay
Returns a raw pointer to the memory-mapped SDRAM block
Panics
-
Panics if any setting in
IC::CONFIG
cannot be achieved -
Panics if the FMC source clock is too fast for maximum SD clock in
IC::TIMING
Auto Trait Implementations
impl<FMC, IC> Send for Sdram<FMC, IC> where
FMC: Send,
IC: Send,
FMC: Send,
IC: Send,
impl<FMC, IC> Sync for Sdram<FMC, IC> where
FMC: Sync,
IC: Sync,
FMC: Sync,
IC: Sync,
impl<FMC, IC> Unpin for Sdram<FMC, IC> where
FMC: Unpin,
IC: Unpin,
FMC: Unpin,
IC: Unpin,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,