Skip to main content
na.1
Associate II
December 12, 2022
Question

LSM303AGR 3-wire SPI interface the STM32WB MCUs

  • December 12, 2022
  • 1 reply
  • 1277 views

0693W00000WKnLzQAL.jpgWe trying to implement the SPI -3 wire communication with the HAL-APIs i.e, HAL_SPI transmit, HAL_SPI_receive, while trying to read data from LSM303 we are receiving the device ID as 0xFF

we are using the LSM303 Accelerometer + Compass Breakout board from the Adafruit.

I2C communication working properly but we are not able to establish communication with the 3-wire SPI,

Is it possible to implement 3-wire SPI communication using the HAL functions (Transmit & receive) or we have to work with low-level libraries to implement SPI-3 wire

This topic has been closed for replies.

1 reply

S.Ma
Principal
December 12, 2022

Start with 4 wire SPI and short miso and mosi together, and disable mosi when reading. The other ways are not working as dreamt.