cancel
Showing results for 
Search instead for 
Did you mean: 

i can't debug slave when ensuring spi communication between two STM32 boards

Bastian Toulelan
Associate II

Hi,

i want to ensure SPI communication between STM32F407VG as master and STM32F429i as slave , i loaded the program of the master to the first board then i loaded the program of the slave to the second board , and then i plugged the two usb wire to the PC to start communication , i tried to debugg the slave to verify if the data is received correctly but always the master is debugged not the slave !!!!

2 REPLIES 2

You aren't going to be able to single-step or view peripheral registers on a slave device being hit with data at real-time rates. You'll need to consider instrumenting your code to understand what's happening.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
S.Ma
Principal

If you reset the slave SPI every NSS rise edge, and the slave sync on NSS falling edge, you should be able to breakpoint and recover event is missed some messages. That's how I do to debug faster. Using SPI Slave with DMA cyclic RAM buffer is also reducing the frequency of slave interrupts.