Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
10 years, 10 months ago.
SPI shared between two or more devices.
If I was to connect up two or more devices using different drivers to the same SPI, would I need to coordinate the use of the SPI using a mutex or similar? I'm thinking of an LCD screen and SD card where the devices could be accessed from different threads. Most of these devices such as the NOKIA6610 and the standard SD card already have drivers written, but I don't know if they would assume exclusive use of the SPI or if there are any other interface setting issues I need to be aware of.
Thanks for your help. David.
1 Answer
10 years, 10 months ago.
Yes, these generally won't have mutexes in place, and if different threads want to use the same SPI hardware you need to add mutexes.