Struct stm32l432xx_hal::spi::Spi [−][src]
pub struct Spi<SPI, PINS> { /* fields omitted */ }
SPI peripheral operating in full duplex master mode
Methods
impl<PINS> Spi<SPI1, PINS>
[src]
impl<PINS> Spi<SPI1, PINS>
pub fn spi1<F>(
spi: SPI1,
pins: PINS,
mode: Mode,
freq: F,
clocks: Clocks,
apb2: &mut APB2
) -> Self where
F: Into<Hertz>,
PINS: Pins<SPI1>,
[src]
pub fn spi1<F>(
spi: SPI1,
pins: PINS,
mode: Mode,
freq: F,
clocks: Clocks,
apb2: &mut APB2
) -> Self where
F: Into<Hertz>,
PINS: Pins<SPI1>,
Configures the SPI peripheral to operate in full duplex master mode
pub fn free(self) -> (SPI1, PINS)
[src]
pub fn free(self) -> (SPI1, PINS)
Releases the SPI peripheral and associated pins
impl<PINS> Spi<SPI3, PINS>
[src]
impl<PINS> Spi<SPI3, PINS>
pub fn spi3<F>(
spi: SPI3,
pins: PINS,
mode: Mode,
freq: F,
clocks: Clocks,
apb2: &mut APB1R1
) -> Self where
F: Into<Hertz>,
PINS: Pins<SPI3>,
[src]
pub fn spi3<F>(
spi: SPI3,
pins: PINS,
mode: Mode,
freq: F,
clocks: Clocks,
apb2: &mut APB1R1
) -> Self where
F: Into<Hertz>,
PINS: Pins<SPI3>,
Configures the SPI peripheral to operate in full duplex master mode
pub fn free(self) -> (SPI3, PINS)
[src]
pub fn free(self) -> (SPI3, PINS)
Releases the SPI peripheral and associated pins
Trait Implementations
impl<PINS> FullDuplex<u8> for Spi<SPI1, PINS>
[src]
impl<PINS> FullDuplex<u8> for Spi<SPI1, PINS>
type Error = Error
An enumeration of SPI errors
fn read(&mut self) -> Result<u8, Error>
[src]
fn read(&mut self) -> Result<u8, Error>
Reads the word stored in the shift register Read more
fn send(&mut self, byte: u8) -> Result<(), Error>
[src]
fn send(&mut self, byte: u8) -> Result<(), Error>
Sends a word to the slave
impl<PINS> Default<u8> for Spi<SPI1, PINS>
[src]
impl<PINS> Default<u8> for Spi<SPI1, PINS>
impl<PINS> Default<u8> for Spi<SPI1, PINS>
[src]
impl<PINS> Default<u8> for Spi<SPI1, PINS>
impl<PINS> FullDuplex<u8> for Spi<SPI3, PINS>
[src]
impl<PINS> FullDuplex<u8> for Spi<SPI3, PINS>
type Error = Error
An enumeration of SPI errors
fn read(&mut self) -> Result<u8, Error>
[src]
fn read(&mut self) -> Result<u8, Error>
Reads the word stored in the shift register Read more
fn send(&mut self, byte: u8) -> Result<(), Error>
[src]
fn send(&mut self, byte: u8) -> Result<(), Error>
Sends a word to the slave
impl<PINS> Default<u8> for Spi<SPI3, PINS>
[src]
impl<PINS> Default<u8> for Spi<SPI3, PINS>
impl<PINS> Default<u8> for Spi<SPI3, PINS>
[src]
impl<PINS> Default<u8> for Spi<SPI3, PINS>