<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <title>GNU Radio 3.2.2 C++ API: gr_ofdm_frame_sink Class Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="navtree.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="navtree.js"></script> <script type="text/javascript" src="resize.js"></script> <script type="text/javascript"> $(document).ready(initResizable); </script> <link href="doxygen.css" rel="stylesheet" type="text/css"/> </head> <body> <!-- Generated by Doxygen 1.7.3 --> <div id="top"> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td style="padding-left: 0.5em;"> <div id="projectname">GNU Radio 3.2.2 C++ API</div> </td> </tr> </tbody> </table> </div> </div> <div id="side-nav" class="ui-resizable side-nav-resizable"> <div id="nav-tree"> <div id="nav-tree-contents"> </div> </div> <div id="splitbar" style="-moz-user-select:none;" class="ui-resizable-handle"> </div> </div> <script type="text/javascript"> initNavTree('classgr__ofdm__frame__sink.html',''); </script> <div id="doc-content"> <div class="header"> <div class="summary"> <a href="#pub-methods">Public Member Functions</a> | <a href="#pro-methods">Protected Member Functions</a> | <a href="#friends">Friends</a> </div> <div class="headertitle"> <h1>gr_ofdm_frame_sink Class Reference<div class="ingroups"><a class="el" href="group__sink__blk.html">Signal Sinks</a> | <a class="el" href="group__ofdm__blk.html">OFDM Blocks</a></div></h1> </div> </div> <div class="contents"> <!-- doxytag: class="gr_ofdm_frame_sink" --><!-- doxytag: inherits="gr_sync_block" --> <p>Takes an OFDM symbol in, demaps it into bits of 0's and 1's, packs them into packets, and sends to to a message queue sink.NOTE: The mod input parameter simply chooses a pre-defined demapper/slicer. Eventually, we want to be able to pass in a reference to an object to do the demapping and slicing for a given modulation type. <a href="#_details">More...</a></p> <p><code>#include <<a class="el" href="gr__ofdm__frame__sink_8h_source.html">gr_ofdm_frame_sink.h</a>></code></p> <div class="dynheader"> Inheritance diagram for gr_ofdm_frame_sink:</div> <div class="dyncontent"> <div class="center"><img src="classgr__ofdm__frame__sink__inherit__graph.png" border="0" usemap="#gr__ofdm__frame__sink_inherit__map" alt="Inheritance graph"/></div> <map name="gr__ofdm__frame__sink_inherit__map" id="gr__ofdm__frame__sink_inherit__map"> <area shape="rect" id="node2" href="classgr__sync__block.html" title="synchronous 1:1 input to output with historyOverride work to provide the signal processing implementa..." alt="" coords="21,160,128,189"/><area shape="rect" id="node4" href="classgr__block.html" title="The abstract base class for all 'terminal' processing blocks.A signal processing flow is cons..." alt="" coords="40,83,109,112"/><area shape="rect" id="node6" href="classgr__basic__block.html" title="The abstract base class for all signal processing blocks.Basic blocks are the bare abstraction of an ..." alt="" coords="20,5,129,35"/></map> <center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div> <p><a href="classgr__ofdm__frame__sink-members.html">List of all members.</a></p> <table class="memberdecls"> <tr><td colspan="2"><h2><a name="pub-methods"></a> Public Member Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classgr__ofdm__frame__sink.html#a4408441371b0a5b1b64be1d959b2381b">~gr_ofdm_frame_sink</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="classgr__ofdm__frame__sink.html#a9cbbd6669ff730bc510c7f13b0517920">work</a> (int noutput_items, <a class="el" href="classstd_1_1vector.html">gr_vector_const_void_star</a> &input_items, <a class="el" href="classstd_1_1vector.html">gr_vector_void_star</a> &output_items)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">just like <a class="el" href="classgr__block.html#a137b93d87dc83bbdb6369d33f4ea8197" title="compute output items from input items">gr_block::general_work</a>, only this arranges to call consume_each for you <a href="#a9cbbd6669ff730bc510c7f13b0517920"></a><br/></td></tr> <tr><td colspan="2"><h2><a name="pro-methods"></a> Protected Member Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classgr__ofdm__frame__sink.html#a4c70885da3dccf6e629b755d24021294">gr_ofdm_frame_sink</a> (const <a class="el" href="classstd_1_1vector.html">std::vector</a>< <a class="el" href="gr__complex_8h.html#aec4bfe41433369afae9327f1b0bc9109">gr_complex</a> > &sym_position, const <a class="el" href="classstd_1_1vector.html">std::vector</a>< unsigned char > &sym_value_out, <a class="el" href="classboost_1_1shared__ptr.html">gr_msg_queue_sptr</a> target_queue, unsigned int occupied_tones, float phase_gain, float freq_gain)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classgr__ofdm__frame__sink.html#a3cf5140b2d7b665b66ef1b9ffb0714ea">enter_search</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classgr__ofdm__frame__sink.html#aa632ea6f0d13403e564f56b0687aae66">enter_have_sync</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classgr__ofdm__frame__sink.html#a6faac7711732a155c65a3c7707266415">enter_have_header</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="gc__types_8h.html#a0f2b5d454b7e4dda3861032cfce91085">bool</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classgr__ofdm__frame__sink.html#aa510595d0cc0bc55c7a4ae647cf229bd">header_ok</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top">unsigned char </td><td class="memItemRight" valign="bottom"><a class="el" href="classgr__ofdm__frame__sink.html#a0d478f55e3b444de83dfae334531814a">slicer</a> (const <a class="el" href="gr__complex_8h.html#aec4bfe41433369afae9327f1b0bc9109">gr_complex</a> x)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">unsigned int </td><td class="memItemRight" valign="bottom"><a class="el" href="classgr__ofdm__frame__sink.html#ab38ea04690149eaaaf1e963050183737">demapper</a> (const <a class="el" href="gr__complex_8h.html#aec4bfe41433369afae9327f1b0bc9109">gr_complex</a> *in, unsigned char *out)</td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="gc__types_8h.html#a0f2b5d454b7e4dda3861032cfce91085">bool</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classgr__ofdm__frame__sink.html#a94060d9740588572cae62914e527a558">set_sym_value_out</a> (const <a class="el" href="classstd_1_1vector.html">std::vector</a>< <a class="el" href="gr__complex_8h.html#aec4bfe41433369afae9327f1b0bc9109">gr_complex</a> > &sym_position, const <a class="el" href="classstd_1_1vector.html">std::vector</a>< unsigned char > &sym_value_out)</td></tr> <tr><td colspan="2"><h2><a name="friends"></a> Friends</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classboost_1_1shared__ptr.html">gr_ofdm_frame_sink_sptr</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classgr__ofdm__frame__sink.html#ae6326404ed8917c076d888f1e3c3e50f">gr_make_ofdm_frame_sink</a> (const <a class="el" href="classstd_1_1vector.html">std::vector</a>< <a class="el" href="gr__complex_8h.html#aec4bfe41433369afae9327f1b0bc9109">gr_complex</a> > &sym_position, const <a class="el" href="classstd_1_1vector.html">std::vector</a>< unsigned char > &sym_value_out, <a class="el" href="classboost_1_1shared__ptr.html">gr_msg_queue_sptr</a> target_queue, unsigned int occupied_tones, float phase_gain, float freq_gain)</td></tr> </table> <hr/><a name="_details"></a><h2>Detailed Description</h2> <div class="textblock"><p>Takes an OFDM symbol in, demaps it into bits of 0's and 1's, packs them into packets, and sends to to a message queue sink.</p> <p>NOTE: The mod input parameter simply chooses a pre-defined demapper/slicer. Eventually, we want to be able to pass in a reference to an object to do the demapping and slicing for a given modulation type. </p> </div><hr/><h2>Constructor & Destructor Documentation</h2> <a class="anchor" id="a4c70885da3dccf6e629b755d24021294"></a><!-- doxytag: member="gr_ofdm_frame_sink::gr_ofdm_frame_sink" ref="a4c70885da3dccf6e629b755d24021294" args="(const std::vector< gr_complex > &sym_position, const std::vector< unsigned char > &sym_value_out, gr_msg_queue_sptr target_queue, unsigned int occupied_tones, float phase_gain, float freq_gain)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">gr_ofdm_frame_sink::gr_ofdm_frame_sink </td> <td>(</td> <td class="paramtype">const <a class="el" href="classstd_1_1vector.html">std::vector</a>< <a class="el" href="gr__complex_8h.html#aec4bfe41433369afae9327f1b0bc9109">gr_complex</a> > & </td> <td class="paramname"><em>sym_position</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const <a class="el" href="classstd_1_1vector.html">std::vector</a>< unsigned char > & </td> <td class="paramname"><em>sym_value_out</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="classboost_1_1shared__ptr.html">gr_msg_queue_sptr</a> </td> <td class="paramname"><em>target_queue</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">unsigned int </td> <td class="paramname"><em>occupied_tones</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">float </td> <td class="paramname"><em>phase_gain</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">float </td> <td class="paramname"><em>freq_gain</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td><code> [protected]</code></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="a4408441371b0a5b1b64be1d959b2381b"></a><!-- doxytag: member="gr_ofdm_frame_sink::~gr_ofdm_frame_sink" ref="a4408441371b0a5b1b64be1d959b2381b" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">gr_ofdm_frame_sink::~gr_ofdm_frame_sink </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <hr/><h2>Member Function Documentation</h2> <a class="anchor" id="ab38ea04690149eaaaf1e963050183737"></a><!-- doxytag: member="gr_ofdm_frame_sink::demapper" ref="ab38ea04690149eaaaf1e963050183737" args="(const gr_complex *in, unsigned char *out)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">unsigned int gr_ofdm_frame_sink::demapper </td> <td>(</td> <td class="paramtype">const <a class="el" href="gr__complex_8h.html#aec4bfe41433369afae9327f1b0bc9109">gr_complex</a> * </td> <td class="paramname"><em>in</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">unsigned char * </td> <td class="paramname"><em>out</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td><code> [protected]</code></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="a6faac7711732a155c65a3c7707266415"></a><!-- doxytag: member="gr_ofdm_frame_sink::enter_have_header" ref="a6faac7711732a155c65a3c7707266415" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void gr_ofdm_frame_sink::enter_have_header </td> <td>(</td> <td class="paramname"></td><td>)</td> <td><code> [protected]</code></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="aa632ea6f0d13403e564f56b0687aae66"></a><!-- doxytag: member="gr_ofdm_frame_sink::enter_have_sync" ref="aa632ea6f0d13403e564f56b0687aae66" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void gr_ofdm_frame_sink::enter_have_sync </td> <td>(</td> <td class="paramname"></td><td>)</td> <td><code> [protected]</code></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="a3cf5140b2d7b665b66ef1b9ffb0714ea"></a><!-- doxytag: member="gr_ofdm_frame_sink::enter_search" ref="a3cf5140b2d7b665b66ef1b9ffb0714ea" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void gr_ofdm_frame_sink::enter_search </td> <td>(</td> <td class="paramname"></td><td>)</td> <td><code> [protected]</code></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="aa510595d0cc0bc55c7a4ae647cf229bd"></a><!-- doxytag: member="gr_ofdm_frame_sink::header_ok" ref="aa510595d0cc0bc55c7a4ae647cf229bd" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="gc__types_8h.html#a0f2b5d454b7e4dda3861032cfce91085">bool</a> gr_ofdm_frame_sink::header_ok </td> <td>(</td> <td class="paramname"></td><td>)</td> <td><code> [inline, protected]</code></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="a94060d9740588572cae62914e527a558"></a><!-- doxytag: member="gr_ofdm_frame_sink::set_sym_value_out" ref="a94060d9740588572cae62914e527a558" args="(const std::vector< gr_complex > &sym_position, const std::vector< unsigned char > &sym_value_out)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="gc__types_8h.html#a0f2b5d454b7e4dda3861032cfce91085">bool</a> gr_ofdm_frame_sink::set_sym_value_out </td> <td>(</td> <td class="paramtype">const <a class="el" href="classstd_1_1vector.html">std::vector</a>< <a class="el" href="gr__complex_8h.html#aec4bfe41433369afae9327f1b0bc9109">gr_complex</a> > & </td> <td class="paramname"><em>sym_position</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const <a class="el" href="classstd_1_1vector.html">std::vector</a>< unsigned char > & </td> <td class="paramname"><em>sym_value_out</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td><code> [protected]</code></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="a0d478f55e3b444de83dfae334531814a"></a><!-- doxytag: member="gr_ofdm_frame_sink::slicer" ref="a0d478f55e3b444de83dfae334531814a" args="(const gr_complex x)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">unsigned char gr_ofdm_frame_sink::slicer </td> <td>(</td> <td class="paramtype">const <a class="el" href="gr__complex_8h.html#aec4bfe41433369afae9327f1b0bc9109">gr_complex</a> </td> <td class="paramname"><em>x</em></td><td>)</td> <td><code> [protected]</code></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <a class="anchor" id="a9cbbd6669ff730bc510c7f13b0517920"></a><!-- doxytag: member="gr_ofdm_frame_sink::work" ref="a9cbbd6669ff730bc510c7f13b0517920" args="(int noutput_items, gr_vector_const_void_star &input_items, gr_vector_void_star &output_items)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int gr_ofdm_frame_sink::work </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"><em>noutput_items</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="classstd_1_1vector.html">gr_vector_const_void_star</a> & </td> <td class="paramname"><em>input_items</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="classstd_1_1vector.html">gr_vector_void_star</a> & </td> <td class="paramname"><em>output_items</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td><code> [virtual]</code></td> </tr> </table> </div> <div class="memdoc"> <p>just like <a class="el" href="classgr__block.html#a137b93d87dc83bbdb6369d33f4ea8197" title="compute output items from input items">gr_block::general_work</a>, only this arranges to call consume_each for you </p> <p>The user must override work to define the signal processing code </p> <p>Implements <a class="el" href="classgr__sync__block.html#a0c523f4285a6eb690f677ee6295ab117">gr_sync_block</a>.</p> </div> </div> <hr/><h2>Friends And Related Function Documentation</h2> <a class="anchor" id="ae6326404ed8917c076d888f1e3c3e50f"></a><!-- doxytag: member="gr_ofdm_frame_sink::gr_make_ofdm_frame_sink" ref="ae6326404ed8917c076d888f1e3c3e50f" args="(const std::vector< gr_complex > &sym_position, const std::vector< unsigned char > &sym_value_out, gr_msg_queue_sptr target_queue, unsigned int occupied_tones, float phase_gain, float freq_gain)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classboost_1_1shared__ptr.html">gr_ofdm_frame_sink_sptr</a> gr_make_ofdm_frame_sink </td> <td>(</td> <td class="paramtype">const <a class="el" href="classstd_1_1vector.html">std::vector</a>< <a class="el" href="gr__complex_8h.html#aec4bfe41433369afae9327f1b0bc9109">gr_complex</a> > & </td> <td class="paramname"><em>sym_position</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const <a class="el" href="classstd_1_1vector.html">std::vector</a>< unsigned char > & </td> <td class="paramname"><em>sym_value_out</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype"><a class="el" href="classboost_1_1shared__ptr.html">gr_msg_queue_sptr</a> </td> <td class="paramname"><em>target_queue</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">unsigned int </td> <td class="paramname"><em>occupied_tones</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">float </td> <td class="paramname"><em>phase_gain</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">float </td> <td class="paramname"><em>freq_gain</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td><code> [friend]</code></td> </tr> </table> </div> <div class="memdoc"> </div> </div> <hr/>The documentation for this class was generated from the following file:<ul> <li><a class="el" href="gr__ofdm__frame__sink_8h_source.html">gr_ofdm_frame_sink.h</a></li> </ul> </div> </div> <div id="nav-path" class="navpath"> <ul> <li class="navelem"><a class="el" href="classgr__ofdm__frame__sink.html">gr_ofdm_frame_sink</a> </li> <li class="footer">Generated on Thu Feb 17 2011 for GNU Radio 3.2.2 C++ API by  <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.3 </li> </ul> </div> </body> </html>