diff options
author | Ben Hilburn <ben.hilburn@ettus.com> | 2016-07-14 10:18:21 -0400 |
---|---|---|
committer | Ben Hilburn <ben.hilburn@ettus.com> | 2016-07-14 10:18:21 -0400 |
commit | 7c9f29519b709c432284fb6481842f03809ac594 (patch) | |
tree | 66aff20959658b39ba2ccc30e300afbddbe827f6 | |
parent | cc58cdd730b7e680ded447ee8f8cff305c83ecbb (diff) |
Fixing `Sdot` calculation in `fmdet_cf_impl` `work()`
Bug reported on-list. Current code actually results in the S1 terms simply
canceling each other, whereas the second term should be S2.
-rw-r--r-- | gr-analog/lib/fmdet_cf_impl.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gr-analog/lib/fmdet_cf_impl.cc b/gr-analog/lib/fmdet_cf_impl.cc index 2c48ff07e2..38496d189b 100644 --- a/gr-analog/lib/fmdet_cf_impl.cc +++ b/gr-analog/lib/fmdet_cf_impl.cc @@ -106,7 +106,7 @@ namespace gr { while(size-- > 0) { S0 = *iptr++; - Sdot = d_scl * (-S0+d_8*S1-d_8*S1+S4); + Sdot = d_scl * (-S0+d_8*S1-d_8*S2+S4); d_freq = (S2.real()*Sdot.imag()-S2.imag()*Sdot.real()) / (S2.real()*S2.real()+S2.imag()*S2.imag()); |