Help me understand oscilloscope peak acquisition mode - Page 1
Forum section: electronics / testgear

author: AJ528
author_rank: Regular Contributor
timestamp: December 04, 2023, 08:19:48 pm
content: Hello all,I have a Siglent SDS 2000X Plus oscilloscope, and I have been trying to wrap my head around what Peak Acquisition mode does. The manual says, "The oscilloscope acquires the maximum and minimum values of the signal within the sample interval so that the peak (maximum – minimum) in the interval is obtained". While I understand the intent of peak acquisition mode, I'm confused how Siglent is implementing it.For example, let's say that during the sample interval there is a maximum value of +1 V and a minimum value of -1 V. The manual says peak = (maximum - minimum) = (1 - (-1)) = 2 V. Does that mean the oscilloscope plots a point at 2V? That doesn't make sense.I also tried answering my own question using a signal generator. I set the oscilloscope to capture 10kSa/s, then fed in a 1 Vpp sine wave. When measuring in normal acquisition mode, I saw what I expected to see (an approximate DC line since the sample rate and frequency matched). However, when I switched the oscilloscope to peak detect mode, the data points are frequently alternating between the min and max sine wave values, but not always. Sometimes it is 2 max points in a row, sometimes 2 min points. Can anyone explain what is happening here? How exactly are these points being selected during the sample interval?P.S. Please see the attached screen capture for an example of alternating min/max points during peak detect mode. Note that linear interpolation is being used to better highlight the data points.

author: tautech
author_rank: Super Contributor
timestamp: December 04, 2023, 08:32:12 pm
content: Please see Peak explanation on P79/80 in the User manual:https://int.siglent.com/u_file/download/22_05_18/SDS2000X%20Plus_UserManual_EN01D.pdf

author: AJ528
author_rank: Regular Contributor
timestamp: December 04, 2023, 09:05:33 pm
content: Hi Tautech,Thanks for the reply. I have read the explanation in that part of the user manual. In fact, that's where I got the quote for what the user manual says. However, after reading that, I can't explain the data points I am seeing. Do you have any thoughts why the data points are appearing how they are?

author: Someone
author_rank: Super Contributor
timestamp: December 04, 2023, 09:15:39 pm
content: Quote from: AJ528 on December 04, 2023, 08:19:48 pmTry again, but with the frequency significantly larger and smaller than the sample rate.

author: tautech
author_rank: Super Contributor
timestamp: December 04, 2023, 09:18:19 pm
content: Zoom mode reduces sampling rates and user settings for mem depth reduce the # of sample points available for detailed analysis.Max mem depth and trigger settings can assist in getting accurate results.

author: AJ528
author_rank: Regular Contributor
timestamp: December 04, 2023, 09:55:47 pm
content: Quote from: tautech on December 04, 2023, 09:18:19 pmI know. I'm not looking to accurately measure this signal, I'm trying to understand what is happening when I select "peak detect" mode on the scope. I don't understand why I'm seeing maximum points sometimes, minimum points other times, and why they are alternating in the pattern shown.Quote from: Someone on December 04, 2023, 09:15:39 pmWhen the frequency is much less than the sample rate, I see an accurate representation of the sine wave. When it is much larger, it looks similar to when I'm at 10kHz. What motivates this suggestion? I don't see how that helps me understand what peak detect is doing.

author: tooki
author_rank: Super Contributor
timestamp: December 04, 2023, 10:12:44 pm
content: Quote from: AJ528 on December 04, 2023, 08:19:48 pmWhile I can’t answer when it selects the min or max value, what I can say is that when they say “(maximum - minimum)” in the manual, they don’t mean “subtract the minimum from the maximum” but rather “capture the maximum and the minimum within the sample period”.Basically, what peak detect does is to run the ADC faster than your final sample rate, and then chooses the maxima and minima from those oversampled sample periods. (High-res mode works similarly, but averages the oversamples within the period, rather than selecting the maxima and minima.)See:https://www.baldengineer.com/how-oscilloscope-acquisition-modes-work.html

author: pdenisowski
author_rank: Super Contributor
timestamp: December 05, 2023, 06:19:47 am
content: Can't comment on how Siglent implements this, but here is how peak detect works on R&S oscilloscopes: (45 seconds starting at this point)https://youtu.be/oS9PT98m69c?t=150

author: 2N3055
author_rank: Super Contributor
timestamp: December 05, 2023, 09:15:39 am
content: Quote from: pdenisowski on December 05, 2023, 06:19:47 amYeah they work the same.I guess OPs problem is how do you apply this in practice.... What do you see on the screen when do "this and this" type of question.

author: Performa01
author_rank: Super Contributor
timestamp: December 05, 2023, 11:39:19 am
content: You might want to read the section "Peak Detect" in my review document part 2 (SDS1104X-E Review 26-50):https://www.eevblog.com/forum/testgear/siglent-sds1104x-e-in-depth-review/msg1371771/This is for the little SDS1104X-E, but the working principle is the same on all higher class models too. So you should easily be able to reproduce the examples given in that article.EDIT: Maybe you shoud read the section about the Normal Acquisition mode first, to see the problem that can be solved by peak detect.

author: rf-loop
author_rank: Super Contributor
timestamp: December 05, 2023, 01:07:14 pm
content: Quote from: Performa01 on December 05, 2023, 11:39:19 amManual have this:"The oscilloscope acquires the maximumandminimum values of the signalwithinthe sample interval" (However, it does not specify exactly how they are displayed.)If the logic of the sentence is strictly interpreted, I could add it as an extension: "or maybe not" (based to SDS2kXHD).For now, under Deeper investigation... (after I get SDS2kX+ on my table)

author: Performa01
author_rank: Super Contributor
timestamp: December 05, 2023, 02:11:46 pm
content: Quote from: rf-loop on December 05, 2023, 01:07:14 pmMy document states:QuoteSo the fuzziness of the description in the manual is the definition of "sample interval".It should be obvious, that it cannot be the raw sample interval, which might be as short as 500 ps at 2 GSa/s.It is the decimated sample interval instead, which is now twice as wide as for decimation in normal mode, because it contains a sample pair (min/max) instead of a single sample.

author: rf-loop
author_rank: Super Contributor
timestamp: December 05, 2023, 03:33:36 pm
content: Quote from: Performa01 on December 05, 2023, 02:11:46 pmIf set sample interval 100us. (decimated samplerate 10kSa/s)Now if example OP use 10kHz signal he get as he have explained. And his signal was 10kHz. One full wave in every 100us sample interval and now important - IF this is sample interval in this matter.It's quite sloppy to talk in User Manual about a sample interval but not say that it's not the same as a sample interval but something else, like 2*sample interval. If I think 10kSa/s, it really means that the time between samples is 100us, which is also the sample interval.Now if we think about this R&S axle. There it takes the minimum and maximum that is within that one interval when it reads the undecimated samples of the ADC (the ADC actual sample rate). +But Siglent does NOT work like this example. And at least I no longer know how it works exactly, because now I have SDS2kX+ in front of me.It looks like it can detect the 200us interval, but... more tests are needed.

author: RoGeorge
author_rank: Super Contributor
timestamp: December 05, 2023, 03:47:09 pm
content: Quote from: AJ528 on December 04, 2023, 08:19:48 pmThat in the user manual is some wrong phrasing.For each "sample" in peak mode, the oscilloscope always displays 2 points, the max and the min value. Not added, not subtracted, but both the min and the max one after another. Always pairs of dots, even when max == min.For your example with +1 and -1 in the same interval, it will display two consecutive dots, one display dot at -1V, followed by another dot at +1V.

author: AJ528
author_rank: Regular Contributor
timestamp: December 05, 2023, 09:35:22 pm
content: Hi everyone,Thanks for the responses! This is the sort of discussion I was hoping to prompt; I've already learned so much from this!Quote from: Performa01 on December 05, 2023, 11:39:19 amThanks for pointing me to that in-depth review (frankly it's more of an instruction manual/characterization at that length, which is not a bad thing!) The example problem you highlight is actually what prompted me to investigate how peak detect worked on my scope.Quote from: Performa01 on December 05, 2023, 02:11:46 pmQuote from: RoGeorge on December 05, 2023, 03:47:09 pmThis is very interesting. Until now, I was assuming that, when in peak detect mode, the oscilloscope would measure at its max sample rate, then throw out all samples but one for each sample period (I couldn't figure out how it was deciding to keep the min vs max value each time, which is why I originally posted this question). The idea of collecting samples for two sample periods, then retaining a pair of min/max samples hadn't occurred to me. However, that certainly appears to be what is happening here.I generated a single 100MHz sine wave, and even though the entire signal was complete within 20ns, I still see a minimum and maximum point plotted 100us apart from each other. I have attached the actual sine wave being generated, as well as what peak detect mode shows me when I am zoomed out to 10kSa/s

author: Performa01
author_rank: Super Contributor
timestamp: December 06, 2023, 10:02:05 am
content: Quote from: AJ528 on December 05, 2023, 09:35:22 pmYes, this is a very nice demonstration of Peak Detect mode – let’s examine that for the ones who can’t imagine exactly what’s going on:That single signal period is 10 ns wide and the original sample rate is 2 GSa/s, i.e. 500 ps sample interval. No problem capturing a 10 ns period.Now you lower theeffectivesample rate to just 10 kSa/s by increasing the time base to 200 ms/div and limiting the record length to 20 kpts at the same time. Now Peak Detect has to come into play:Of course, the ADC still samples at 2 GSa/s, so we have an accurate representation of the input signal in the original data. Now these data at 500 ps sample interval have to be decimated to a 100 µs sample interval. That means keeping only one out of 200k samples.Now we work on two decimated sample intervals at the same time, by finding the min. and max. value within a 200 µs interval. It is most likely that we will get one such min/max pair that is [-0.5V,+0.5V]. This is now split again to get the final effective sample rate with 100 µs sample interval by generating two samples, -0.5V followed by the next one +0.5V 100 µs later. For this to work, we need also consider the order of the two extrema, i.e. know which one comes first, the minimum or the maximum.If the transition between two 200 µs sample intervals happens to be exactly in the middle of the signal period, then we would get [0V,+0.5V] for one 200 µs interval and [-0.5V,0V] for the following one. In this case, we also get the correct decimated samples with 100 µs interval following the same scheme as above: 0V, -0.5V, +0.5V, 0V.

author: Performa01
author_rank: Super Contributor
timestamp: December 06, 2023, 04:19:06 pm
content: Quote from: PeDre on December 06, 2023, 12:14:54 pmThank you for showing us how Peak Detect is implemented on a scope from a so called A-brand.It's so much nicer to have just a fat blob instead of a hint on the true waveform (which we can't get with the peak detect crouch anyway)...

author: colorado.rob
author_rank: Frequent Contributor
timestamp: December 06, 2023, 06:24:45 pm
content: Quote from: PeDre on December 06, 2023, 12:14:54 pmGiven the description in the Siglent manual, this is exactly how I would expect it to be displayed. I find this much more intuitive. In vector mode, is it joining all minimum points together and all maximum points together to form two distinct waveform displays per channel?

author: 2N3055
author_rank: Super Contributor
timestamp: December 06, 2023, 06:48:16 pm
content: Quote from: PeDre on December 06, 2023, 05:15:46 pmNo need for argument on any side...R&S has one display representation. Siglent has other. On every "vertical double point" R&S plots in time, Siglent will plot two samples, one Max other Min. When viewed at some normal timebase they will show exactly the same.This super high zoom ratio displayed was very useful to see what scopes actually do. But in practice it is not supposed to be used like that.Purpose of Peek detect mode is to show very short pulses on longer timebases. If you look at main (not zoomed window) both scopes show a spike, positive and negative (that would not be there in normal mode and slow sampling) and that is extent of it's usability.On both RTB2000 and even more on Siglent SDS2000X+ (that has order of magnitude more memory), Peak mode is pretty much unnecessary.I know I didn't use one in ages...

author: David Hess
author_rank: Super Contributor
timestamp: December 07, 2023, 12:53:55 am
content: Quote from: 2N3055 on December 06, 2023, 06:48:16 pmThat is going to depend on how the acquisition record is processed to produce the display record. If the processing produces an analog like display, then a fast peak should be invisible despite being present in the data. So peak detect mode could still be useful if it highlights the envelope of the signal.Below is an example of peak detect mode on a Tektronix 2232, but it is identical on the 2230 which is the first DSO that I know of with peak detection. The display is 50 points per horizontal division so 2ms/50 is 40us or 25 ksamples/second which is way too slow to detect the high frequency switching which would otherwise cause severe aliasing, but peak detection forces the maximum sample rate of 100 Msamples/second and then decimates to record the highest and lowest values which are *both* displayed during the sample interval.

author: alm
author_rank: Super Contributor
timestamp: December 07, 2023, 01:21:58 am
content: Quote from: David Hess on December 07, 2023, 12:53:55 amI did tests a while ago, though I can't find the post right now, on a Lecroy WavePro 7300A. So MAUI, on which the current software for their X-Stream and MAUI light scopes are based. I used a pulse train with as low a duty cycle as I could generate with my pulse generator, and as long as the combination of memory depth and sweep speed were such that the sample rate stayed high enough to sample the pulses, the pulses would be displayed regardless of the zoom. Even if the pulse width was way below a pixel width at that zoom level. So at least those scopes appear to be doing some sort of envelope filter during downsampling.

author: David Hess
author_rank: Super Contributor
timestamp: December 07, 2023, 05:23:05 am
content: Quote from: alm on December 07, 2023, 01:21:58 amI did the same thing on my 2230 and 2232 when I first got them, using a variable width pulse which could be smaller or larger than the sample interval. These old DSOs lack a graded index display so they will always show a pulse at full brightness if it is recorded.But if a more modern instrument produces a graded index display, then a narrow recorded peak will be too dim to view, like on an analog oscilloscope, unless the display record processing takes this into account. I am not surprised that some DSOs do this even if it sacrifices display accuracy.

author: 2N3055
author_rank: Super Contributor
timestamp: December 07, 2023, 06:20:02 am
content: Quote from: David Hess on December 07, 2023, 05:23:05 amWe spoke about this many times. It won't be too dim to view. Modern scopes produce "analog like" view. Pixel brightness is nonlinear, and there is a lowest value that it will go.So basically, if you have only one repetition of sample in area you will still get, say, 30% of brightness.Brightness (and color mapping in color mode) is not done from 0-100% in linear fashion.When done right, this is superior how CRT works because it shows signals CRT wouldn't show but still convey repetition/density info..

author: David Hess
author_rank: Super Contributor
timestamp: December 07, 2023, 12:02:10 pm
content: Quote from: 2N3055 on December 07, 2023, 06:20:02 amI think the most that can be said about graded index DSO response is that it is proportional in some way, which may or may not accurately convey repetition/density info. This would have to be tested and nobody does, but it would be easy with amark 1 eyeball tangential measurement.The response of an analog CRT is not even close to linear; it is a power function, and it conveys quantitative repetition/density info very accurately.

author: AJ528
author_rank: Regular Contributor
timestamp: December 08, 2023, 03:42:11 pm
content: Quote from: 2N3055 on December 06, 2023, 06:48:16 pmYeah, this is my takeaway too. However I am glad I now understand how Siglent implements this mode. It's always good to be aware of quirks.I think the R&S way of displaying peaks is more accurate, but they do both convey similar information.