cancel
Showing results for 
Search instead for 
Did you mean: 

SPI Bus Impedance

Albi G.
Senior

Hi guys, i am going to connect 2 STM32 via 3 SPI busses for high speed data transfer throughput (STM32H7 <-> STM32G4).

The STM32G4 will be Master and the SCLK-frequency will be 84MHz - i will use the associated pins in the highest speed mode setting.

I am having an extremely hard time to find any information about layout guidelines for the SPI-Busses in general. Same is true for the MCO-output.

Are there any recommendations which trace impedance to aim for? If possible i like to avoid series resistors for the SPI-Lines - people seem to include those via trial and error or because of good faith... thats not engineering in my mind.

I dont have very long traces (60mm) but i have EMI-sensitive circuitry on board.

Thank you.

12 REPLIES 12
LMI2
Lead

At 84MHz 60cm wire looks like a transmission line. I would start with a lower speed and add termination when needed. Series termination is one way to terminate transmission lines. That termination resistance you should use depends on what line you are using, I think common IDC cable impedance is around 120ohms. I would use an IDC cable rather than coaxial cable, because IDC cable has higher impedance.

Perhaps you should Google RF transmission line and/or series termination (resistor value).

S.Ma
Principal

too bad there is no qspi slave mode, would ease things. play with speed gpio and pull down internal resistor to reduce ringing. on the master side, consider spi1 as master and spi2 & 3 as slave using sck1 as reference so all are in sync and toggling at near same time... 84 mhz means master and slave sysclk being 2x or 4x faster...

Albi G.
Senior

60 _mm_ ! Only. And i am on PCB, no cable. :-)

.: I understand your intentions, but i am not sure if everything synchronized issnt a worse experience at the end.

TDK
Guru

A signal travels 1.8m in the period of one clock cycle at 84 MHz. I can't imagine it'll matter too much if you leave a 60mm trace unterminated. And if it's unterminated, the trace impedance isn't going to matter much.

If you feel a post has answered your question, please click "Accept as Solution".
Albi G.
Senior

That makes no sense in my head.

One should try to match either the source or the load (best both) to reduce the number of reflections - if you have a perfectly unmachted system, the wave is going to be stuck in the trace with no way to escape but radiate away (heat / EMI).

If your load is high impedance, like an MCU pin, you’re not matching it. You’d need to add a terminating resistor and then match that. Which you can do, of course, but it’ll add a complexity. I thought you didnt want to add any resistors.
I think you’ll find modern chips are more tolerant than you’d expect based on internet forums.
Not sure what a “perfectly unmatched�? system is. There are plenty of ways for the signal to dissipate.
Take a nucleo board and test it out.
Just my opinion.
If you feel a post has answered your question, please click "Accept as Solution".

It's not the data rate which matters here, but frequency content of the signal, i.e. edges slew rate. With sharp edges capable of low 100s of MHz, the harmonic content gets easily into GHz.

Electronics is all about abstraction, i.e. omitting details in order to make the otherwise overly complex problem of signals practically tractable. Digital electronics is all about these abstractions and simplifications. The craft is in judging when these simplifications stop being valid and what to do about it.

You can err on the safe side by massive overengineering and you often do, think about decoupling capacitors: when was it last time when you actually *calculated* what decoupling is needed, and/or actually *verified* validity of chosen decoupling?

Exactly same applies to high speed signals, their integrity, and coupling to neighbouring signals.

Generally, I'd be worried maybe less about termination and track impedances, and more about proper signal return (a.k.a. "ground" which is just another abstraction, and probably the most omitted and most heavily violated one).

HTH,

JW

You do not think far enough:

Yes, the Input pin (destination) is unmatched - no discussion there... but what happens, after the wave reflects? Yes - it hits the transmitter again. And what happens next?

a) the transmitter is machted: the wave is absorbed

b) the transmitter is unmatched, the wave reflects again, has no chance do dissipate into heat and/or EMI.

Do you now understand the benefit of even a partial source matching?

I see now that it is only 60mm and not 60cm. It makes things easier.