Associate III
March 24, 2014
Question
Strange SPI problem
- March 24, 2014
- 3 replies
- 1193 views
Posted on March 24, 2014 at 11:47
Hello everybody,
I am trying to interface two STM32F3 boards with SPI port in full duplex with interruption.
One board acts as Master and the other one as a Slave. The Master sends a command, then the 4 Byte from TxBuffer. When the slave receives this command, it enables the transmission buffer interrupt to send an ACK, then a4 Byte from TxBuffer.
The problem is that the 4 Bytes sent by the slave, i received only 2 Bytes. My BaudRate set up is : SPI_BaudRatePrescaler_8;If i slow down this by putting : SPI_BaudRatePrescaler_256; i can receive 3 Bytes You find enclosed the code written for the Master and the Slave. Thanks in advance of any help.