From: drowe67 Date: Thu, 28 Feb 2013 01:12:38 +0000 (+0000) Subject: modified first 2 tx functions for variable Nc X-Git-Url: http://git.whiteaudio.com/gitweb/?a=commitdiff_plain;h=16fcb73485b5d13d16b850b5d93039517e9266ab;p=freetel-svn-tracking.git modified first 2 tx functions for variable Nc git-svn-id: https://svn.code.sf.net/p/freetel/code@1175 01035d8c-6547-0410-b346-abe4f91aad63 --- diff --git a/codec2-dev/src/fdmdv.c b/codec2-dev/src/fdmdv.c index 1fcd3d59..947ca717 100644 --- a/codec2-dev/src/fdmdv.c +++ b/codec2-dev/src/fdmdv.c @@ -295,14 +295,14 @@ void CODEC2_WIN32SUPPORT fdmdv_get_test_bits(struct FDMDV *f, int tx_bits[]) \*---------------------------------------------------------------------------*/ -void bits_to_dqpsk_symbols(COMP tx_symbols[], COMP prev_tx_symbols[], int tx_bits[], int *pilot_bit) +void bits_to_dqpsk_symbols(COMP tx_symbols[], int Nc, COMP prev_tx_symbols[], int tx_bits[], int *pilot_bit) { int c, msb, lsb; COMP j = {0.0,1.0}; /* map tx_bits to to Nc DQPSK symbols */ - for(c=0; cprev_tx_symbols, tx_bits, &fdmdv->tx_pilot_bit); + bits_to_dqpsk_symbols(tx_symbols, fdmdv->Nc, fdmdv->prev_tx_symbols, tx_bits, &fdmdv->tx_pilot_bit); memcpy(fdmdv->prev_tx_symbols, tx_symbols, sizeof(COMP)*(NC+1)); - tx_filter(tx_baseband, tx_symbols, fdmdv->tx_filter_memory); + tx_filter(tx_baseband, fdmdv->Nc, tx_symbols, fdmdv->tx_filter_memory); fdm_upconvert(tx_fdm, tx_baseband, fdmdv->phase_tx, fdmdv->freq); *sync_bit = fdmdv->tx_pilot_bit; diff --git a/codec2-dev/src/fdmdv_internal.h b/codec2-dev/src/fdmdv_internal.h index 21a8732a..331dc566 100644 --- a/codec2-dev/src/fdmdv_internal.h +++ b/codec2-dev/src/fdmdv_internal.h @@ -152,8 +152,8 @@ struct FDMDV { \*---------------------------------------------------------------------------*/ -void bits_to_dqpsk_symbols(COMP tx_symbols[], COMP prev_tx_symbols[], int tx_bits[], int *pilot_bit); -void tx_filter(COMP tx_baseband[NC+1][M], COMP tx_symbols[], COMP tx_filter_memory[NC+1][NSYM]); +void bits_to_dqpsk_symbols(COMP tx_symbols[], int Nc, COMP prev_tx_symbols[], int tx_bits[], int *pilot_bit); +void tx_filter(COMP tx_baseband[NC+1][M], int Nc, COMP tx_symbols[], COMP tx_filter_memory[NC+1][NSYM]); void fdm_upconvert(COMP tx_fdm[], COMP tx_baseband[NC+1][M], COMP phase_tx[], COMP freq_tx[]); void generate_pilot_fdm(COMP *pilot_fdm, int *bit, float *symbol, float *filter_mem, COMP *phase, COMP *freq); void generate_pilot_lut(COMP pilot_lut[], COMP *pilot_freq);