CC1310的SPI使用回调函数模式怎样能够实现超时退出。
程序是SDK中SPIslave,正常需要在回调函数中释放阻塞信号,这样的话如果传输中断就会一直阻塞在里面,怎么实现超时退出呢。谢谢。
Susan Yang:
请您参考一下
e2e.ti.com/…/594074
In SPI master mode you probably want to set the timeout to BIOS_WAIT_FOREVER, since you typically never want to abort your ongoing SPI transfer.
However in slave mode you might want to set an actual timeout, even though you call SPI_transfer(…) the master might never actually send anything, and then you’d be waiting forever if you don’t have a timeout…
liu shr:
回复 Susan Yang:
这个只能用在在block模式,callback模式无法使用