Skip to main content
Explorer
March 6, 2025
Question

SPI Master, Slave Issue

  • March 6, 2025
  • 1 reply
  • 797 views

Dear ST Team,

I am currently working with the STM32F407 board and implementing SPI communication between a Master and a slave. While the slave does respond to data sent by the Master, I am encountering an issue where the received data sometimes rolls and contains unexpected garbage values.

Could you please provide guidance on possible causes and troubleshooting steps to resolve this issue? Any insights into proper SPI configuration, clock synchronization, or handling of buffer overflows would be greatly appreciated.

Looking forward to your support.

    This topic has been closed for replies.

    1 reply

    Graduate
    March 6, 2025

    Search the forum for topics on SPI slave - you will find some info there.

    To keep it short: it is close to impossible to implement SPI slave in a microcontroller unless the master is kind enough to implement specially relaxed timing for it.

    Explorer
    March 6, 2025

    Any better way of handling this issue.
    Because we have a STM32F407 as a SPI Slave and MCP2210 as the SPI Master

    Super User
    March 6, 2025

    Looks like you can set the delay after chip select. Set it high enough that your code can keep up.

    TDK_0-1741270715734.png