GNU Radio Radar Toolbox
gr::radar::find_max_peak_c Class Referenceabstract

This block estimates a single peak of a given FFT spectrum as tagged stream. Output is a message with the information of frequency, phase and power of the peak as a f32vector with a single item. All data is tagged with the identifiers (symbols) 'frequency', 'phase' and 'power'. The peak is estimated on the whole spectrum or on the range max_freq if cut_max_freq is true. Furthermore a threshold of the spectrum amplitude can be given with threshold. The DC peak can be cut out with the protected samples samp_protect. This value do not evaluate samp_protect samples around the DC peak. If no suitable peak is found the block returns empty vectors with the identifiers. More...

#include <find_max_peak_c.h>

Inheritance diagram for gr::radar::find_max_peak_c:
gr::radar::find_max_peak_c_impl

Public Types

typedef std::shared_ptr< find_max_peak_csptr
 

Public Member Functions

virtual void set_threshold (float threshold)=0
 
virtual void set_samp_protect (int samp)=0
 
virtual void set_max_freq (std::vector< float > freq)=0
 

Static Public Member Functions

static sptr make (int samp_rate, float threshold, int samp_protect, std::vector< float > max_freq, bool cut_max_freq, const std::string &len_key="packet_len")
 Return a shared_ptr to a new instance of radar::find_max_peak_c.
 

Detailed Description

This block estimates a single peak of a given FFT spectrum as tagged stream. Output is a message with the information of frequency, phase and power of the peak as a f32vector with a single item. All data is tagged with the identifiers (symbols) 'frequency', 'phase' and 'power'. The peak is estimated on the whole spectrum or on the range max_freq if cut_max_freq is true. Furthermore a threshold of the spectrum amplitude can be given with threshold. The DC peak can be cut out with the protected samples samp_protect. This value do not evaluate samp_protect samples around the DC peak. If no suitable peak is found the block returns empty vectors with the identifiers.

Parameters
samp_rateSample rate
thresholdThreshold for detection of the spectrum amplitude
samp_protectProtected samples for cutting DC peak
max_freqFrequency range for cutting spectrum
cut_max_freqToggle cutting the spectrum for peak estimation
len_keyPacket length key for tagged stream

Member Typedef Documentation

◆ sptr

Member Function Documentation

◆ make()

static sptr gr::radar::find_max_peak_c::make ( int  samp_rate,
float  threshold,
int  samp_protect,
std::vector< float >  max_freq,
bool  cut_max_freq,
const std::string &  len_key = "packet_len" 
)
static

Return a shared_ptr to a new instance of radar::find_max_peak_c.

To avoid accidental use of raw pointers, radar::find_max_peak_c's constructor is in a private implementation class. radar::find_max_peak_c::make is the public interface for creating new instances.

◆ set_max_freq()

virtual void gr::radar::find_max_peak_c::set_max_freq ( std::vector< float >  freq)
pure virtual

◆ set_samp_protect()

virtual void gr::radar::find_max_peak_c::set_samp_protect ( int  samp)
pure virtual

◆ set_threshold()

virtual void gr::radar::find_max_peak_c::set_threshold ( float  threshold)
pure virtual

The documentation for this class was generated from the following file: