Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

SPI Master-Slave Communication

Mtech1

Junior Member level 1
Joined
Mar 18, 2023
Messages
17
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
164
I'm looking for someone to correct my basic understanding if I am thinking wrong. I believe SPI is a protocol that work on a master and multiple slave architecture, where only one master communicates with multiple slaves by selecting a specific slave device. It doesn't work like a multimaster multi slave architecture, because slave device can't identify master on SPI. Only master can select slave device and I'm unsure how slave device.
 
Hi,

you want to be corrected:

Then SPI is not a protocol. It is an interface.
(a protocol tells you the meaning of the bits .. and more)

But the rest is correct so far.
SPI is designed
* for one master
* multiple slaves
* only one slave per time selected by individual /SS or /CS lines.

For sure one may find solutions for multi master ... but SPI was not designed for this.

Master to slave .. with sending data via MOSI is not critical. One master sends on MOSI, many slaves theoretically can listen on MOSI.
But the other way round is problematic. When a slave is not active it´s MISO line is high impedance.
In case multiple slaves are connected then multiple slaves try to drive the MISO line causing short circuit.Communcation will fail. In wors case the slave gets killed.

because slave device can't identify master on SPI.
I´m not sure what you mean.
Even in multi master interfaces it is not necessary that the slave identifies the master.
Example: I2C. It may contain multiple masters, but no slave will ever know which master tries to communicate.

Only master can select slave device and I'm unsure how slave device.
The slave is a slave. It only becomes active when a master activates it.
If one wants an SPI slave to establish to communicate with a master then the usual way is to use InterruptRequest lines ... but this is not part of SPI.

Klaus
 

LaTeX Commands Quick-Menu:

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top