qspectrumanalyzer icon indicating copy to clipboard operation
qspectrumanalyzer copied to clipboard

Zero the sweep

Open calston opened this issue 6 years ago • 1 comments

I want to modify the code to add a feature to do a zero of the span which is handy for using a noise source to do filter measurements and such. I think big expensive spectrum analyzers have that feature (NOT the same thing as zero-span mode) which lets you remove the effect of test leads and environmental noise from measurements.

Just wondering the best way to go about this. There will always be some noise regardless, that's fine. So what I'm thinking is a button that captures a few averaged sweeps into a buffer. Then while the button is left toggled the displayed line is the difference between the recorded dB level at that frequency and the dB level in the buffer.

Two concerns come to mind - doing the vector subtraction over the whole dataset can be quite slow. The memory consumption of the buffer, but it's probably no worse than the existing average calculations.

Any thoughts or gotcha's I might have missed? One glaring one is I'm not sure where technically the "zero" point should be, or if subtracting dB is linear. Would the span move to zero dB and then measurements after that are positive?

calston avatar Jun 13 '18 09:06 calston

Oh I think this is already implemented as "subtract baseline", doh

calston avatar Jun 17 '18 20:06 calston