SPI Signal, long cable and some questions

Anything not related to a specific project.

Re: SPI Signal, long cable and some questions

Postby Bertho » Mon Apr 23, 2012 8:02 pm

michu wrote:
500kHz is a real pain, but you should be able to press 10MHz through the line if setup correctly and all is matched. I pressed 8MHz TTL CGA signals through 15..25m of cable with proper buffering and termination without a hitch.

Do you have released some information about your projects? Sounds interesting.


Hm, no, the CGA stuff was a project I did about 20 years ago. The tech hasn't changed though. Other stuff is on my homepage (http://www.vagrearg.org).

I guess I should write an article about that like I did the decoupling article. It is actually quite an interesting subject to deal with "long" cables and how signals can bounce in all directions. Something that can be easily visualized. Let me think about that a few days; I'll probably will come up with something. And then make some time to write it down. Darn, need to move at light-speed to use a relativistic clock that makes time ;-)

--
Greetings Bertho
User avatar
Bertho
Sr. Member
Sr. Member
 
Posts: 347
Joined: Mon Sep 19, 2011 4:34 pm
Location: Somewhere in the vicinity of Betelgeuse

Re: SPI Signal, long cable and some questions

Postby ian » Tue Apr 24, 2012 1:04 am

Nice followup post and illustrations. Thanks for sharing!
User avatar
ian
Crew
Crew
 
Posts: 10803
Joined: Mon Jul 06, 2009 6:14 am

Re: SPI Signal, long cable and some questions

Postby brian » Tue May 08, 2012 11:09 pm

I honestly didn't read the whole post but I did read the captions/skim (I know the topic well already). I think of lines as basically 3 classes: very sub wavelength (lumped), order wavelength, much greater than wavelength.

The middle class is the hardest to deal with. The first class you pretty much can get away with anything. Transition between very sub-wavelength and wavelength order in my mind is maybe 1-5 degrees in the full cable length.

But what is the wavelength of a square wave? In principle it has harmonics to all frequencies. That hard edge causes the overshoot. So an easy thing to do is just a little capacitance if you can't tolerate ringing (if a larger number of the harmonics of the square freq are << than the cable length then you won't see ringing). I think the second and 3rd classes looked covered in this writeup.

Let's break out the Smith charts.
brian
Sr. Member
Sr. Member
 
Posts: 495
Joined: Sun Nov 14, 2010 12:27 am

Re: SPI Signal, long cable and some questions

Postby Bertho » Wed May 09, 2012 10:03 am

The real problems are the transitions of square wave in a logic signal. The harmonics can be used for analysis, but it is easier to look at the problem from a pulsed energy standpoint. The transition causes a pulse to propagate, which reflects if the line is not terminated. This happens regardless frequency of the logic signal.

For digital logic signals, it is easier to do the look at the problem using transient analysis and leave the harmonics on the side. Only when your digital square wave frequency gets somewhere at 1/10 of the cable wavelength (rule of thumb) it may pay itself to use harmonic analysis. Either way, you have to deal with the reflection, and that is always solved in exactly the same way: terminate your cable.

The use of a 100kHz square wave signal was meant to show that a relatively low frequency on a short (2.3m) cable can cause a lot of trouble (it rings a lot).

--
Greetings Bertho
User avatar
Bertho
Sr. Member
Sr. Member
 
Posts: 347
Joined: Mon Sep 19, 2011 4:34 pm
Location: Somewhere in the vicinity of Betelgeuse

Re: SPI Signal, long cable and some questions

Postby Andrewh » Mon Jul 02, 2012 10:59 pm

There's an Arduino library for the lpd6803 chips. You may have seen it already, but thought I'd pass it along. It does use the ATmega hardware SPI support, so might be alot of work to port, but it might give some good insight.
User avatar
Andrewh
Newbie
Newbie
 
Posts: 1
Joined: Mon Jul 02, 2012 10:38 pm

Previous

Return to General discussion