Imported Upstream version 3.2.2
[debian/gnuradio] / gnuradio-core / src / lib / general / gr_clock_recovery_mm_ff.h
index 87823c44e3cf9985b6c74de1c8c5d7bb8bfa0c7d..d2ec6d3e6da11613837dbc714e6c502afdaedfef 100644 (file)
@@ -24,6 +24,7 @@
 #define        INCLUDED_GR_CLOCK_RECOVERY_MM_FF_H
 
 #include <gr_block.h>
+#include <gr_math.h>
 #include <stdio.h>
 
 class gri_mmse_fir_interpolator;
@@ -38,7 +39,7 @@ gr_make_clock_recovery_mm_ff (float omega, float gain_omega, float mu, float gai
 
 /*!
  * \brief Mueller and Müller (M&M) based clock recovery block with float input, float output.
- * \ingroup block
+ * \ingroup sync_blk
  *
  * This implements the Mueller and Müller (M&M) discrete-time error-tracking synchronizer.
  *
@@ -67,6 +68,7 @@ class gr_clock_recovery_mm_ff : public gr_block
     d_omega = omega;
     d_min_omega = omega*(1.0 - d_omega_relative_limit);
     d_max_omega = omega*(1.0 + d_omega_relative_limit);
+    d_omega_mid = 0.5*(d_min_omega+d_max_omega);
   }
 
 protected:
@@ -76,7 +78,8 @@ protected:
  private:
   float                        d_mu;           // fractional sample position [0.0, 1.0]
   float                        d_omega;        // nominal frequency
-  float                                d_min_omega;    // minimum allowed omega
+  float                                d_min_omega;    // minimum allowed omega 
+  float                         d_omega_mid;   // average omega
   float                                d_max_omega;    // maximum allowed omega
   float                         d_gain_omega;  // gain for adjusting omega
   float                         d_gain_mu;     // gain for adjusting mu