[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Discuss-gnuradio] Help To Compute Average

From: Andr Jakob
Subject: [Discuss-gnuradio] Help To Compute Average
Date: Sat, 2 Aug 2014 13:19:14 -0700

Hello all

I am new to GNUradio software. I would like to compute the average energy and display it in the status message in real time.

To achieve this I tried to write a simple Python code attached (Simple2.pyw). However, I am not able to retrieve data from the

self.c2ms=gr.complex_to_mag_squared(NFFT) block

1. Could you please help me what method should I use to retrieve the data contents of self.c2ms
2. And perform averaging (This could be performed easily using the function below)
3. Display the average in the right status message (i.e., in self._set_status_msg("Put average here!!!", 1)).

Finally for any given block, how can I see and modify the methods easily.

Note that I am using windows command line to run the python file.


get average_energy(data):
    for i in data
    return avg1/len(data)

Attachment: Simple2.pyw
Description: Text document

reply via email to

[Prev in Thread] Current Thread [Next in Thread]