GNU Radio 3.7.1-52 C++ API
gr::blocks::bin_statistics_f Class Referenceabstract

control scanning and record frequency domain statistics More...

#include <bin_statistics_f.h>

Inheritance diagram for gr::blocks::bin_statistics_f:
gr::sync_block gr::block gr::basic_block gr::msg_accepter gr::messages::msg_accepter

Public Types

typedef boost::shared_ptr
< bin_statistics_f
sptr
 

Static Public Member Functions

static sptr make (unsigned int vlen, gr::msg_queue::sptr msgq, feval_dd *tune, size_t tune_delay, size_t dwell_delay)
 

Protected Member Functions

virtual size_t vlen () const =0
 
virtual double center_freq () const =0
 
virtual gr::msg_queue::sptr msgq () const =0
 
virtual void reset_stats ()=0
 
virtual void accrue_stats (const float *input)=0
 
virtual void send_stats ()=0
 
- Protected Member Functions inherited from gr::sync_block
 sync_block (void)
 
 sync_block (const std::string &name, gr::io_signature::sptr input_signature, gr::io_signature::sptr output_signature)
 
- Protected Member Functions inherited from gr::block
 block (void)
 
 block (const std::string &name, gr::io_signature::sptr input_signature, gr::io_signature::sptr output_signature)
 
void set_fixed_rate (bool fixed_rate)
 
void add_item_tag (unsigned int which_output, uint64_t abs_offset, const pmt::pmt_t &key, const pmt::pmt_t &value, const pmt::pmt_t &srcid=pmt::PMT_F)
 Adds a new tag onto the given output buffer. More...
 
void add_item_tag (unsigned int which_output, const tag_t &tag)
 Adds a new tag onto the given output buffer. More...
 
void remove_item_tag (unsigned int which_input, uint64_t abs_offset, const pmt::pmt_t &key, const pmt::pmt_t &value, const pmt::pmt_t &srcid=pmt::PMT_F)
 Removes a tag from the given input buffer. More...
 
void remove_item_tag (unsigned int which_input, const tag_t &tag)
 Removes a tag from the given input buffer. More...
 
void get_tags_in_range (std::vector< tag_t > &v, unsigned int which_input, uint64_t abs_start, uint64_t abs_end)
 Given a [start,end), returns a vector of all tags in the range. More...
 
void get_tags_in_range (std::vector< tag_t > &v, unsigned int which_input, uint64_t abs_start, uint64_t abs_end, const pmt::pmt_t &key)
 Given a [start,end), returns a vector of all tags in the range with a given key. More...
 
- Protected Member Functions inherited from gr::basic_block
 basic_block (void)
 
 basic_block (const std::string &name, gr::io_signature::sptr input_signature, gr::io_signature::sptr output_signature)
 Protected constructor prevents instantiation by non-derived classes. More...
 
void set_input_signature (gr::io_signature::sptr iosig)
 may only be called during constructor More...
 
void set_output_signature (gr::io_signature::sptr iosig)
 may only be called during constructor More...
 
void set_color (vcolor color)
 Allow the flowgraph to set for sorting and partitioning. More...
 
vcolor color () const
 
virtual bool has_msg_handler (pmt::pmt_t which_port)
 Tests if there is a handler attached to port which_port. More...
 
virtual void dispatch_msg (pmt::pmt_t which_port, pmt::pmt_t msg)
 

Protected Attributes

std::vector< float > d_max
 

Additional Inherited Members

- Public Member Functions inherited from gr::sync_block
virtual int work (int noutput_items, gr_vector_const_void_star &input_items, gr_vector_void_star &output_items)=0
 just like gr::block::general_work, only this arranges to call consume_each for you More...
 
void forecast (int noutput_items, gr_vector_int &ninput_items_required)
 Estimate input requirements given output request. More...
 
int general_work (int noutput_items, gr_vector_int &ninput_items, gr_vector_const_void_star &input_items, gr_vector_void_star &output_items)
 compute output items from input items More...
 
int fixed_rate_ninput_to_noutput (int ninput)
 Given ninput samples, return number of output samples that will be produced. N.B. this is only defined if fixed_rate returns true. Generally speaking, you don't need to override this. More...
 
int fixed_rate_noutput_to_ninput (int noutput)
 Given noutput samples, return number of input samples required to produce noutput. N.B. this is only defined if fixed_rate returns true. Generally speaking, you don't need to override this. More...
 
- Protected Types inherited from gr::basic_block
enum  vcolor { WHITE, GREY, BLACK }
 

Detailed Description

control scanning and record frequency domain statistics

Member Typedef Documentation

Member Function Documentation

virtual void gr::blocks::bin_statistics_f::accrue_stats ( const float *  input)
protectedpure virtual
virtual double gr::blocks::bin_statistics_f::center_freq ( ) const
protectedpure virtual
static sptr gr::blocks::bin_statistics_f::make ( unsigned int  vlen,
gr::msg_queue::sptr  msgq,
feval_dd tune,
size_t  tune_delay,
size_t  dwell_delay 
)
static

Build a bin statistics block. See qa_bin_statistics.py and gr-uhd/examples/python/usrp_spectrum_sense.py for examples of its use, specifically how to use the callback function.

Parameters
vlenvector length
msgqmessage queue
tunea feval_dd callback function
tune_delaynumber of samples for the tune delay
dwell_delaynumber of samples for the dwell delay
virtual gr::msg_queue::sptr gr::blocks::bin_statistics_f::msgq ( ) const
protectedpure virtual
virtual void gr::blocks::bin_statistics_f::reset_stats ( )
protectedpure virtual
virtual void gr::blocks::bin_statistics_f::send_stats ( )
protectedpure virtual
virtual size_t gr::blocks::bin_statistics_f::vlen ( ) const
protectedpure virtual

Member Data Documentation

std::vector<float> gr::blocks::bin_statistics_f::d_max
protected

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