SPI data corruption

ChibiOS public support forum for topics related to the STMicroelectronics STM32 family of micro-controllers.

Moderator: RoccoMarco

rocky
Posts: 11
Joined: Thu Sep 12, 2013 4:21 am

Re: SPI data corruption

Post by rocky »

Right I agree. Currently I don't believe it has that facility, let me check the document further for this.

Aside from the efficiency issue, any suggestions on the corruption problem? Thanks.
User avatar
Giovanni
Site Admin
Posts: 14892
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: SPI data corruption

Post by Giovanni »

It is hard to imagine what could cause an overwrite of the last byte with a zero. Are you sure the DMA is actually writing a zero? could you try to fill the buffer with a pattern and verify if the DMA is really writing zeros?

Giovanni
rocky
Posts: 11
Joined: Thu Sep 12, 2013 4:21 am

Re: SPI data corruption

Post by rocky »

Yes I tested that, pre-filled the buffer with a pattern, and all get overwritten as 0. What I'm not sure is whether only the last byte get corrupted or all get corrupted, because the external device is supposed to return {0, 0, 0, 0, 0, 4}. I'll poke around and try to come up with more information. Thanks.
Post Reply