Author Topic: Scope Bandwidth to decode SPI data  (Read 4490 times)

0 Members and 1 Guest are viewing this topic.

Offline frequencydriveTopic starter

  • Newbie
  • Posts: 7
Scope Bandwidth to decode SPI data
« on: June 20, 2018, 12:41:05 am »
I am an electrical engineering student.  I have a need to decode in real time an SPI signal at a clock frequency of 10mhz.  Besides the decode features built into many scopes what kinda bandwidth would I need to be looking at in order to be able to capture data in real time and decode it?  I thought a 100mhz scope would be good enough, but after googling a little bit I am starting to doubt that. 
« Last Edit: June 20, 2018, 12:47:43 am by frequencydrive »
 

Online tautech

  • Super Contributor
  • ***
  • Posts: 28137
  • Country: nz
  • Taupaki Technologies Ltd. Siglent Distributor NZ.
    • Taupaki Technologies Ltd.
Re: Scope Bandwidth to decode SPI data
« Reply #1 on: June 20, 2018, 12:50:23 am »
I am an electrical engineering student. 
Then you should know Mega Hertz is expressed as MHz, please use it, this is an engineering forum !
Avid Rabid Hobbyist
Siglent Youtube channel: https://www.youtube.com/@SiglentVideo/videos
 
The following users thanked this post: egonotto, nugglix, newbrain

Offline frequencydriveTopic starter

  • Newbie
  • Posts: 7
Re: Scope Bandwidth to decode SPI data
« Reply #2 on: June 20, 2018, 12:58:36 am »
Yeah, I didn't think I was going to held accountable for capitalization error.
« Last Edit: June 20, 2018, 01:02:36 am by frequencydrive »
 

Offline ataradov

  • Super Contributor
  • ***
  • Posts: 11228
  • Country: us
    • Personal site
Re: Scope Bandwidth to decode SPI data
« Reply #3 on: June 20, 2018, 01:03:20 am »
Yeah, I didn't think I was going to held to accountable for capitalization error.
That's not capitalization error. It is a factual error. "MHz", "mHz" and "mhz" are very different things.
Alex
 
The following users thanked this post: egonotto

Online tautech

  • Super Contributor
  • ***
  • Posts: 28137
  • Country: nz
  • Taupaki Technologies Ltd. Siglent Distributor NZ.
    • Taupaki Technologies Ltd.
Re: Scope Bandwidth to decode SPI data
« Reply #4 on: June 20, 2018, 02:54:35 am »
I am an electrical engineering student.  I have a need to decode in real time an SPI signal at a clock frequency of 10mhz.  Besides the decode features built into many scopes what kinda bandwidth would I need to be looking at in order to be able to capture data in real time and decode it?  I thought a 100mhz scope would be good enough, but after googling a little bit I am starting to doubt that.
It's not so much BW as processing capability when it comes to Decoding. 10 MHz BW requirement is pedestrian and any 100 MHz DSO should eat this.
I've seen it with SDS2kX, SDS1kX models and now with SDS1kX-E models that now run a much gruntier FPGA than their predecessors and so much better able to get 'somewhere near' realtime. Trigger settings get you to see what you want, more than anything else.
Once you step past the current offerings of entry level DSO's decode performance gets better however the perfect scope is yet to be built.
Have a squis at SDS1104X-E.
Avid Rabid Hobbyist
Siglent Youtube channel: https://www.youtube.com/@SiglentVideo/videos
 
The following users thanked this post: mtdoc

Offline evgen.05

  • Regular Contributor
  • *
  • Posts: 50
  • Country: ru
Re: Scope Bandwidth to decode SPI data
« Reply #5 on: June 20, 2018, 05:51:27 am »
My opinion is - Logic analyzer is much better for decoding protocols. SPI, I2C or USART - doesn't matter. It's much cheaper and smaller than oscilloscope
 

Offline Ice-Tea

  • Super Contributor
  • ***
  • Posts: 3063
  • Country: be
    • Freelance Hardware Engineer
Re: Scope Bandwidth to decode SPI data
« Reply #6 on: June 20, 2018, 06:16:08 am »
Yeah, I didn't think I was going to held accountable for capitalization error.

I teach. You would be held accountable.

Also: welcome to the forum ;)
 
The following users thanked this post: JPortici

Offline Fungus

  • Super Contributor
  • ***
  • Posts: 16561
  • Country: 00
Re: Scope Bandwidth to decode SPI data
« Reply #7 on: June 20, 2018, 07:31:02 am »
Yeah, I didn't think I was going to held accountable for capitalization error.

It's not a "capitalization error", it's a completely different unit.

m = milli
M = mega

Do you want 0.01 Hertz or 10000000 Hertz?

Space ships have crashed for much less error than that.

I thought a 100mhz scope would be good enough, but after googling a little bit I am starting to doubt that. 

If it's a 10 MegaHertz SPI signal then you're right on the limit but you should be OK.

My opinion is - Logic analyzer is much better for decoding protocols. SPI, I2C or USART - doesn't matter. It's much cheaper and smaller than oscilloscope

If your main task is "to capture data in real time and decode it" then an oscilloscope is the wrong tool for the job (IMHO). If there's more than a couple of packets of data then you'll be very frustrated by using twisty knobs, tiny screens and small memory. Keyboard, mouse and gigabytes of RAM are the way to go.


« Last Edit: June 20, 2018, 08:23:37 am by Fungus »
 
The following users thanked this post: nugglix

Offline BillB

  • Supporter
  • ****
  • Posts: 615
  • Country: us
Re: Scope Bandwidth to decode SPI data
« Reply #8 on: June 20, 2018, 07:45:41 am »
I don't think I'd have the patience to wait for 10 mhz SPI to decode.  :D

I didn't mean to pile-on, I think OP has learned his lesson.

I agree about a logic analyzer being a better choice.   However, if money is an issue, and you need a scope anyway, having one that can do serial decoding as well is very handy.  For SPI, a 4 channel scope is the way to go but is more expensive of course.  I second the recommendation for the Siglent SDS1104X-E. 

 

Offline Fungus

  • Super Contributor
  • ***
  • Posts: 16561
  • Country: 00
Re: Scope Bandwidth to decode SPI data
« Reply #9 on: June 20, 2018, 08:28:30 am »
However, if money is an issue, and you need a scope anyway, having one that can do serial decoding as well is very handy.  For SPI, a 4 channel scope is the way to go but is more expensive of course.  I second the recommendation for the Siglent SDS1104X-E.

If 'money is an issue' then a Rigol DS1054Z will do it for half the price (you could get a Rigol and a logic analyzer for the price of a Siglent).

But, as people have said: If you're going to be doing a lot of this then then an oscilloscope will just frustrate you. Better to buy a logic analyzer.


« Last Edit: June 20, 2018, 08:30:41 am by Fungus »
 

Offline JPortici

  • Super Contributor
  • ***
  • Posts: 3452
  • Country: it
Re: Scope Bandwidth to decode SPI data
« Reply #10 on: June 20, 2018, 08:32:39 am »
My opinion is - Logic analyzer is much better for decoding protocols. SPI, I2C or USART - doesn't matter. It's much cheaper and smaller than oscilloscope

It depends.
Many logic analyzers aren't realtime, or when used in realtime they drop the sample rate to a minimum, or have a great blind time between acquisitions. This, at least, for all the USB logic analyzer i've seen and used.

A scope on the other hand lets you see the waveforms with much more detail, and not what they look like after the LA input circuitry and the comparators.. a lot can be happening that you won't be able to see.
A scope will be bettere in realtime mode, as would be any standalone instrument.
A scope will also be able to trigger on more conditions, always related to the shape of the signal.
A scope will also be easier to set up to see a time correlation between the serial bus data and other analog signals
 

Offline Fungus

  • Super Contributor
  • ***
  • Posts: 16561
  • Country: 00
Re: Scope Bandwidth to decode SPI data
« Reply #11 on: June 20, 2018, 08:32:52 am »
The other option is a USB oscilloscope, eg. Picoscope.

This gives you a worse oscilloscope (although some people like them) but a better serial decoder.  :popcorn:



https://www.picotech.com/library/oscilloscopes/serial-protocol-decoding-spi

 

Offline Fungus

  • Super Contributor
  • ***
  • Posts: 16561
  • Country: 00
Re: Scope Bandwidth to decode SPI data
« Reply #12 on: June 20, 2018, 08:35:42 am »
A scope on the other hand lets you see the waveforms with much more detail, and not what they look like after the LA input circuitry and the comparators.. a lot can be happening that you won't be able to see.

If you're building a new circuit and want to look at signal integrity then a 'scope is essential, yes.

But he said "capture data in real time and decode it".
 

Online nctnico

  • Super Contributor
  • ***
  • Posts: 26754
  • Country: nl
    • NCT Developments
Re: Scope Bandwidth to decode SPI data
« Reply #13 on: June 20, 2018, 11:50:57 am »
I am an electrical engineering student.  I have a need to decode in real time an SPI signal at a clock frequency of 10mhz.  Besides the decode features built into many scopes what kinda bandwidth would I need to be looking at in order to be able to capture data in real time and decode it?  I thought a 100mhz scope would be good enough, but after googling a little bit I am starting to doubt that.
100MHz should be more than enough to decode a 10MHz SPI. What can be a problem is the minimum samplerate required. You might end up needing a higher samplerate than you'd expect because the oscilloscope uses decimated data for decoding. If the samplerate is too low it won't decode properly even though the signal on screen looks OK. An exception are the MicSig tBook (1000) mini series; these seem to have a seperate decoding engine running at a fixed samplerate.
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 16545
  • Country: us
  • DavidH
Re: Scope Bandwidth to decode SPI data
« Reply #14 on: June 20, 2018, 02:24:56 pm »
For 10 MHz SPI, 100 MHz of bandwidth is plenty for decoding which probably goes along with a sample rate of 200 MS/s or better.  As others point out, sample rate may be a problem if the record length is insufficient and a DSO is not going to decode in real time.

If you are interested in signal integrity, then the bandwidth of the oscilloscope needs to support a rise time faster than the signals and 100 MHz may be too slow for a system intended to support 10 MHz SPI.  This is where bandwidth is king whether it is achieved with an analog oscilloscope or equivalent time sampling DSO or not.
« Last Edit: June 22, 2018, 08:27:46 am by David Hess »
 

Offline frequencydriveTopic starter

  • Newbie
  • Posts: 7
Re: Scope Bandwidth to decode SPI data
« Reply #15 on: June 22, 2018, 03:34:16 am »
A capital M is a capital M, which is a capitalization error. If you don't want to answer the question then just keep moving. 
 

Offline frequencydriveTopic starter

  • Newbie
  • Posts: 7
Re: Scope Bandwidth to decode SPI data
« Reply #16 on: June 22, 2018, 03:35:09 am »
On a test maybe but not on a forum.
 

Offline frequencydriveTopic starter

  • Newbie
  • Posts: 7
Re: Scope Bandwidth to decode SPI data
« Reply #17 on: June 22, 2018, 03:41:16 am »
Ok I appreciate that recommendation.  I haven't graduated yet, so I'm not making buckets full of money.
 

Online tautech

  • Super Contributor
  • ***
  • Posts: 28137
  • Country: nz
  • Taupaki Technologies Ltd. Siglent Distributor NZ.
    • Taupaki Technologies Ltd.
Re: Scope Bandwidth to decode SPI data
« Reply #18 on: June 22, 2018, 03:44:33 am »
A capital M is a capital M, which is a capitalization error. If you don't want to answer the question then just keep moving.
And your Prof when looking for M as in MHz is gunna mark mHz as FAIL !

Keep your standards up frequencydrive and I'm sure you'll be a fine EE someday.
Avid Rabid Hobbyist
Siglent Youtube channel: https://www.youtube.com/@SiglentVideo/videos
 

Offline KaneTW

  • Frequent Contributor
  • **
  • Posts: 805
  • Country: de
Re: Scope Bandwidth to decode SPI data
« Reply #19 on: June 22, 2018, 03:50:58 am »
No, it's a factual error, because mHz is millihertz and MHz is megahertz. Never count on context clues for units, just press that shift key. Every professor and TA will take points off if you do not use SI prefixes properly.
 

Offline frequencydriveTopic starter

  • Newbie
  • Posts: 7
Re: Scope Bandwidth to decode SPI data
« Reply #20 on: June 22, 2018, 03:52:50 am »
I appreciate your answers.  Although I have read the Tektronix "The basic of oscilloscopes" whitepaper that paper is no substitute for real world experience.  I can't read that paper and decide on what scope specifications I need.  If I drop $1600 on a basic Rigol 200 MHz 4 channel scope I want to make sure it will actually decode a 10 MHz SPI signal.  I know $1600 isn't a lot for someone who has a job and is making $135K as a practicing engineer, but right now I am in school and need to buy something that can so kinda everything kinda well. I'm not looking for the Higgs Boson in the Large Hadron Collider, so I figure a 2000 series Keysight or the equivalent Rigol would be good enough to get me through my last year.

I appreciate your answer.  I will look into logic analyzers.  Thank you. 
 

Offline Fungus

  • Super Contributor
  • ***
  • Posts: 16561
  • Country: 00
Re: Scope Bandwidth to decode SPI data
« Reply #21 on: June 22, 2018, 06:05:43 am »
A capital M is a capital M, which is a capitalization error.

Not to an engineer in that context.

(which is what you're training to be)

 

Online tggzzz

  • Super Contributor
  • ***
  • Posts: 19280
  • Country: gb
  • Numbers, not adjectives
    • Having fun doing more, with less
Re: Scope Bandwidth to decode SPI data
« Reply #22 on: June 22, 2018, 06:46:58 am »
I am an electrical engineering student.  I have a need to decode in real time an SPI signal at a clock frequency of 10mhz.  Besides the decode features built into many scopes what kinda bandwidth would I need to be looking at in order to be able to capture data in real time and decode it?  I thought a 100mhz scope would be good enough, but after googling a little bit I am starting to doubt that.

Quite apart from the units faux pas (which lumps you in with clueless amateurs :) ), you also need to define:
  • how much data you need to capture; I'm told some DSOs only decode the little that is visible on the screen
  • whether triggering/filtering is necessary/beneficial, e.g. don't capture anything until message X1 followed by X2 is found, then only show Y*
  • what you will do with the captured information; you aren't going to eyeball the captured information in real time!

Overall the a good strategy is usually:
  • in the analogue domain use a scope to ensure good signal integrity, i.e. that the analogue signals will be correctly interpreted by the digital receiver
  • then flip to the digital domain and use a logic analyser of some sort. Which type is best will depend on the information defined above
Once you have defined those requirements, you will probably find that you don't need to spend any where near £1600 !

An engineer is someone that can do something for $1 that any fool can do for $10. And see the aphorism in my .sig :)
There are lies, damned lies, statistics - and ADC/DAC specs.
Glider pilot's aphorism: "there is no substitute for span". Retort: "There is a substitute: skill+imagination. But you can buy span".
Having fun doing more, with less
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf