13#include <stm32g4xx_hal.h>
22bool core_SPI_init(SPI_TypeDef *spi, GPIO_TypeDef *cs_port, uint16_t cs_pin);
36bool core_SPI_read_write(SPI_TypeDef *spi, uint8_t *txbuf, uint32_t txbuflen, uint8_t *rxbuf, uint32_t rxbuflen);
bool core_SPI_start(SPI_TypeDef *spi)
Set the CS pin for an SPI bus low.
Definition spi.c:150
bool core_SPI_read_write(SPI_TypeDef *spi, uint8_t *txbuf, uint32_t txbuflen, uint8_t *rxbuf, uint32_t rxbuflen)
Transmit data from a buffer on the given SPI bus and store the incoming data in a separate buffer.
Definition spi.c:130
bool core_SPI_init(SPI_TypeDef *spi, GPIO_TypeDef *cs_port, uint16_t cs_pin)
Initialize an SPI module and set up a CS pin for it.
Definition spi.c:20
bool core_SPI_stop(SPI_TypeDef *spi)
Set the CS pin for an SPI bus high.
Definition spi.c:170