Skip to main content
Hrishikesh
Associate III
March 20, 2021
Question

SPI TxRx callback processing

  • March 20, 2021
  • 0 replies
  • 632 views

I have a Pi that sends data to the MCU via SPI. I have the SPI running in DMA circular buffer mode on the MCU. In the TxRx callback, the data from the Pi is processed, and then the motors are turned ON/OFF, etc.

This works, however, each time the Pi sends data to the MCU, any motors that are already running and are meant to continue running, pause for just a moment and then continue running. Why does this happen and more importantly how do I ensure the motors run continuously without pause?

I know that the callbacks are supposed to be really light on code, but I see the same behavior when I remove the motor control function inside the infinite while loop in main.

This topic has been closed for replies.