Maker Pro
Maker Pro

SPI info

J

joble

Jan 1, 1970
0
I'm using an ST72264 to drive 44 SPI switches (ST: L9822E).
Communicating with those devices works fine, but i'm looking for
practical information about SPI.

ST only has an app note for communication with one single EEPROM. Also
other manufacturers i've looked at do not have this information.

I'm planning to not to daisy chain all 44 of them, but make 4 chains
with 11 SPI-devices. The MCU sends 4 independent enable signals, one
for each chain. I do this to prevent all 44 devices to stop working
when one fails.

How long can an SPI connection be? Can i bring the SPI to another PCB
without trouble?

Can anybody help me find an appnote or give advice.
Greets!!!
 
L

Leon Heller

Jan 1, 1970
0
joble said:
I'm using an ST72264 to drive 44 SPI switches (ST: L9822E).
Communicating with those devices works fine, but i'm looking for
practical information about SPI.

ST only has an app note for communication with one single EEPROM. Also
other manufacturers i've looked at do not have this information.

I'm planning to not to daisy chain all 44 of them, but make 4 chains
with 11 SPI-devices. The MCU sends 4 independent enable signals, one
for each chain. I do this to prevent all 44 devices to stop working
when one fails.

How long can an SPI connection be? Can i bring the SPI to another PCB
without trouble?

SPI should be OK over a few inches of wire. It depends how fast it is.

Leon
 
S

Stefan Heinzmann

Jan 1, 1970
0
joble said:
How long can an SPI connection be? Can i bring the SPI to another PCB
without trouble?

It can be potentionally very long if you control edge speeds and use low
clock frequencies. This is not rigorously specified, you have to work
this out yourself. Going from one PCB to another will probably require
some passive filtering on the signal lines.
 
T

Tim Wescott

Jan 1, 1970
0
joble said:
I'm using an ST72264 to drive 44 SPI switches (ST: L9822E).
Communicating with those devices works fine, but i'm looking for
practical information about SPI.

ST only has an app note for communication with one single EEPROM. Also
other manufacturers i've looked at do not have this information.

I'm planning to not to daisy chain all 44 of them, but make 4 chains
with 11 SPI-devices. The MCU sends 4 independent enable signals, one
for each chain. I do this to prevent all 44 devices to stop working
when one fails.

How long can an SPI connection be? Can i bring the SPI to another PCB
without trouble?

Can anybody help me find an appnote or give advice.
Greets!!!

Within a board you should be OK. Going off board you'll have to pay
attention to signal grounding and EMI -- you may have to slow down your
data rate to compensate.
 
J

joble

Jan 1, 1970
0
Tim Wescott said:
Within a board you should be OK. Going off board you'll have to pay
attention to signal grounding and EMI -- you may have to slow down your
data rate to compensate.



Thanks for your responses!

The application permits me to run the spi line "very" slow. When i
check the signal with a scope on the slave boards, i do not expect
troubles. I'll do EMI tests either, but i do not think there will be
any problem her either.


What is the usual way to connect multiple SPI receivers to an mcu?
Daisy chaining, in parallel, or a combination? For a prototype i have
chosen the combination and i seems to work fine.

Greets!
 
S

Stefan Heinzmann

Jan 1, 1970
0
joble said:
What is the usual way to connect multiple SPI receivers to an mcu?
Daisy chaining, in parallel, or a combination? For a prototype i have
chosen the combination and i seems to work fine.

It depends (you expected this answer, right?).

Normally you would wire them in parallel, since that allows addressing
them separately. If you have a bunch of shift registers that are always
accessed together, you'll daisy chain them. Let the software
requirements decide.
 
S

Spehro Pefhany

Jan 1, 1970
0
Thanks for your responses!

The application permits me to run the spi line "very" slow. When i
check the signal with a scope on the slave boards, i do not expect
troubles. I'll do EMI tests either, but i do not think there will be
any problem her either.

Unless your environment is extremely benign and shielded you may well
have problems. Slow on the desired signals doesn't matter, if there
are brief transients, the slaves may respond. Or the noise may screw
up your MCU.
What is the usual way to connect multiple SPI receivers to an mcu?
Daisy chaining, in parallel, or a combination? For a prototype i have
chosen the combination and i seems to work fine.

Greets!

Whichever way works best. There's even a third possibility. If the MCU
has to do SPI access inside an ISR it may be better to use a separate
interface (perhaps even bit-banged) to some slaves rather than set up
semaphores or whatever and perhaps increase interrupt latency. There
are more timing issues and perhaps ground-bounce issues with
daisy-chaining, but it saves a port pin for each /CS.

Best regards,
Spehro Pefhany
 
Top