Closed kshitij9192 closed 2 years ago
You're likely hit by the issue that is trying to be addressed here: https://github.com/zephyrproject-rtos/zephyr/pull/40998.
Have you manage to observe any correct SPI transaction otherwise ?
Thanks @erwango for the information. I have not been able to perform any successful transaction on the SPI device yet so mostly I am stuck with the specified issue here. So can we conclude that we can't use SPI1/2/3 currently on stm32h7 boards with Zephyr or is there some work-around possible?
So can we conclude that we can't use SPI1/2/3 currently on stm32h7 boards with Zephyr or is there some work-around possible?
Current situation is that there are some specific clock configuration cases where SPI baud rate caclulation goes wrong, cf https://github.com/heinwessels. Otherwise it is expected to be functional.
I see similar lock with the spi_loopback tests with DMA @Kshitij4kk, I guess the SPI in your example is not using DMA transfer
Rebasing on 5d4e08bb9f584f7d2d11a6daa3b39f7bbde8aaf6, I can pass the spi_loopback testcase with Interrupt Mode on the nucleo_h753zi board, with this tests/drivers/spi/spi_loopback/boards/nucleo_h753zi.conf :
CONFIG_SPI_LOOPBACK_DRV_NAME="SPI_1"
CONFIG_SPI_STM32_DMA=n
CONFIG_SPI_STM32_INTERRUPT=y
CONFIG_SPI_ASYNC=y
CONFIG_SPI_LOOPBACK_MODE_LOOP=n
@Kshitij4kk, Could you please check if PR https://github.com/zephyrproject-rtos/zephyr/pull/41560 helps
Thanks, I will be closing this issue.
Describe the bug I am trying to interface ADXL345 accelerometer using SPI communication to my STM32H723ZG board. I am using the SPI1 device for this purpose.
I have done the following modifications in dts overlay file to enable the device node.
I have used the following code for spi configuration:
Other than that I am using following code to read the device id of ADXL345 to ensure the communication channel is up and running.
I can't see any response once the spi_transceive() routine is called.
It would be great if I could get some guidance on this.