Continuous data Transfer on SPI via DMA

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Hello,

   

Recently, I post similar topic but I think I am facing with another problem. I want to take data from accelerometer sensor(mcu9255). I look at the EP56273 example. In this example, when button is switched SPI transmission occurs. I did it in MCU9255. However, in my project, I want to do it continuous cycle with DMA.  But I am facing with some problems. When I did it continuously, my spi rx interrupt work only one time. 
Do you have any experience like that ? 

   

I just think that it can be do with DMA but I don't know what's the point ! 

Thank you
Burak

0 Likes
3 Replies
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

The SPI component is already working continuously: Increase the Rx and Tx buffers. When sending data, they will be copied into the Tx buffer and transferred interrupt driven. Read off the bytes from Rx buffer in a tight loop until buffer empty. This will give you plenty of time for other jobs.

   

 

   

Bob

0 Likes
Anonymous
Not applicable

I think I need to clear a Tx buffer. Also for high sample rate, I need to read rx buffer from DMA too. So I will write data with DMA and read data with DMA which triggered with rx and tx interrupt channels. But in continuous mode, rx interrupt don't give drq signal from rx channel. 

0 Likes
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

Sorry, I also need to attach the project,

0 Likes