timeout version for the SPI api ?

Use this forum for requesting small changes in ChibiOS. Large changes should be discussed in the development forum. This forum is NOT for support.
User avatar
Posts: 348
Joined: Fri May 25, 2012 10:23 am
Location: toulouse, france
Has thanked: 34 times
Been thanked: 53 times

timeout version for the SPI api ?

Postby alex31 » Fri Sep 24, 2021 8:15 am


SPI been a simple serializer, there should be no need for timeout version of spiSend and spiExchange, but I have seen that in the case of the STM32, if there is hardware problem (in our case a short on a board between CLK and MOSI), the peripheral do not raise signal of end of serialization, so DMA end transfert callback is never called, and the task which call SPISend is suspended forever. Perhaps a timout version of SPI API could help to detect and diagnose that kind of problem ?


User avatar
Site Admin
Posts: 13751
Joined: Wed May 27, 2009 8:48 am
Location: Salerno, Italy
Has thanked: 922 times
Been thanked: 787 times

Re: timeout version for the SPI api ?

Postby Giovanni » Fri Sep 24, 2021 8:34 am


Can be implemented using the existing asynchronous API and a virtual timer for timeout, there is already a function for stopping the ongoing operation.


Return to “Small Change Requests”

Who is online

Users browsing this forum: No registered users and 5 guests