Signal strength block

Hi,

I’m trying to determine the strength of a complex filtered signal from a
USRP board; that is, I take the data from the USRP board and I lowpass
filter it, and now I’d like to either fft then integrate the complex
output
to get the signal energy, or just straight away do a sum on the
sequence (a
la Parseval’s theorem). Which method would be easier? Are there any
blocks
that do this already?

Thanks a lot,
Ben

Ben Olsen wrote:

I’m trying to determine the strength of a complex filtered signal from a
USRP board; that is, I take the data from the USRP board and I lowpass
filter it, and now I’d like to either fft then integrate the complex
output to get the signal energy, or just straight away do a sum on the
sequence (a la Parseval’s theorem). Which method would be easier? Are
there any blocks that do this already?

The “quick and dirty” method would be to run the signal through
gr.complex_to_mag() and then through gr.single_pole_iir_filter_ff() with
a suitable time constant. This would give you a running average of the
signal magnitude.

The latest SVN code has a complex_to_mag_squared block; you do the same
as the above to get a running average of the RMS value. You can use
gr.nlog10_ff() to convert either of these to a log scale.

For exact calculation of the energy of a specific interval you’ll have
to write a new block that accepts a length of input equal to the
interval and outputs a single value (the energy). In the block ‘work’
function you’d accumulate the square of the sequence and output that
value at the right time.

So it all depends on what you’re using the value for and how exact you
need it.

-Johnathan

On Tue, Sep 12, 2006 at 07:33:20AM -0700, Johnathan C. wrote:

gr.complex_to_mag() and then through gr.single_pole_iir_filter_ff() with
a suitable time constant. This would give you a running average of the
signal magnitude.

The latest SVN code has a complex_to_mag_squared block; you do the same
as the above to get a running average of the RMS value. You can use
gr.nlog10_ff() to convert either of these to a log scale.

This is all good info. If you think about computational efficiency,
you probably don’t want to be computing the square root and log on
every sample, thus the complex_to_mag_squared followed by
gr.single_pole_iir_filter_ff is probably the way to go. When you care
you can compute the sqrt and possibly log on a possible decimated
stream, etc.

Eric