diff options
author | n4hy | 2006-12-14 18:03:00 +0000 |
---|---|---|
committer | n4hy | 2006-12-14 18:03:00 +0000 |
commit | 8046aa32043bf58ef0a6657b2fba8fe357a294af (patch) | |
tree | 45bb3e5f928219087c9017ca44eae571fe40eafc /gnuradio-core | |
parent | 65ee33a8122bf23dad5721ff115e80ae7bb8e523 (diff) | |
download | gnuradio-8046aa32043bf58ef0a6657b2fba8fe357a294af.tar.gz gnuradio-8046aa32043bf58ef0a6657b2fba8fe357a294af.tar.bz2 gnuradio-8046aa32043bf58ef0a6657b2fba8fe357a294af.zip |
These routines have been modified to use fast atan2
git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@4084 221aa14e-8319-0410-a670-987f0aec2ac5
Diffstat (limited to 'gnuradio-core')
-rw-r--r-- | gnuradio-core/src/lib/general/gr_pll_freqdet_cf.cc | 3 | ||||
-rw-r--r-- | gnuradio-core/src/lib/general/gr_pll_refout_cc.cc | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/gnuradio-core/src/lib/general/gr_pll_freqdet_cf.cc b/gnuradio-core/src/lib/general/gr_pll_freqdet_cf.cc index f090a3e00..8f27e3a00 100644 --- a/gnuradio-core/src/lib/general/gr_pll_freqdet_cf.cc +++ b/gnuradio-core/src/lib/general/gr_pll_freqdet_cf.cc @@ -29,6 +29,7 @@ #include <gr_pll_freqdet_cf.h> #include <gr_io_signature.h> #include <math.h> +#include <gr_math.h> #define M_TWOPI (2*M_PI) @@ -63,7 +64,7 @@ float gr_pll_freqdet_cf::phase_detector(gr_complex sample,float ref_phase) { float sample_phase; - sample_phase = atan2(sample.imag(),sample.real()); + sample_phase = gr_fast_atan2f(sample.imag(),sample.real()); return mod_2pi(sample_phase-ref_phase); } diff --git a/gnuradio-core/src/lib/general/gr_pll_refout_cc.cc b/gnuradio-core/src/lib/general/gr_pll_refout_cc.cc index 3208c5841..e39f8dd4a 100644 --- a/gnuradio-core/src/lib/general/gr_pll_refout_cc.cc +++ b/gnuradio-core/src/lib/general/gr_pll_refout_cc.cc @@ -30,6 +30,7 @@ #include <gr_io_signature.h> #include <gr_sincos.h> #include <math.h> +#include <gr_math.h> #define M_TWOPI (2*M_PI) @@ -64,7 +65,7 @@ float gr_pll_refout_cc::phase_detector(gr_complex sample,float ref_phase) { float sample_phase; - sample_phase = atan2(sample.imag(),sample.real()); + sample_phase = gr_fast_atan2f(sample.imag(),sample.real()); return mod_2pi(sample_phase-ref_phase); } |