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.
11 years, 7 months ago.
Is it possible to connect 3 SPI devices to the same mbed at once?
Hello,
I'm trying to connect three SPI devices at once on the same MBED and I was wondering if this is possible?
Thanks, James
2 Answers
11 years, 7 months ago.
James,
There are two SPI interfaces on the mbed but you can connect multiple devices to each one. For example you could connect three SPI devices as shown below.
Pins 5,6 & 7 are the one of the mbed's SPI interfaces and are shared with all 3 devices. Each SPI device has it's own CS (chip select) line (8, 9 & 10) which you would set low to select the device. You can see an example of a single SPI device being selected and deselected on the SPI handbook page.
You might also choose to connect one of your SPI devices to one SPI interface and 2 to the other.
Steve
Hi James,
i know this is an old question but i am trying to do the same thing and i wanted to ask if you have any code example that you used to connect and save data to the three spi devices.
posted by Elvi Fiscali 30 Jan 2016