From 8b86cd6d331e370e0c4a2e01510af38a3957694c Mon Sep 17 00:00:00 2001 From: tvoid Date: Tue, 8 Apr 2008 14:44:00 -0600 Subject: -added sync/adjust callback for freq trimming -fixed burst function with no outputs -cleanup some old float testing code --- gsm-tvoid/src/lib/gsm_burst_cf.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'gsm-tvoid/src/lib/gsm_burst_cf.cc') diff --git a/gsm-tvoid/src/lib/gsm_burst_cf.cc b/gsm-tvoid/src/lib/gsm_burst_cf.cc index e9fe0fc..a584cd6 100755 --- a/gsm-tvoid/src/lib/gsm_burst_cf.cc +++ b/gsm-tvoid/src/lib/gsm_burst_cf.cc @@ -65,6 +65,7 @@ int gsm_burst_cf::general_work (int noutput_items, int ii=0; int rval = 0; //default to no output + int do_output = output_items.size() > 0 ? 1 : 0; int ninput = ninput_items[0]; //fprintf(stderr,"#i=%d/#o=%d",n_input,noutput_items); @@ -96,7 +97,7 @@ int gsm_burst_cf::general_work (int noutput_items, if (get_burst()) { //found a burst, send to output - if (out) { + if (do_output) { //ensure that output data is in range int b = d_burst_start; if (b < 0) @@ -105,8 +106,8 @@ int gsm_burst_cf::general_work (int noutput_items, b = 2 * MAX_CORR_DIST - 1; memcpy(out+rval*USEFUL_BITS, d_burst_buffer + b, USEFUL_BITS*sizeof(float)); - rval++; } + rval++; switch ( d_clock_options & QB_MASK ) { case QB_QUARTER: //extra 1/4 bit each burst -- cgit v1.2.3