From 3a2f0b7e9fedaa29dbce47fe5d0b61ac8135aefb Mon Sep 17 00:00:00 2001 From: trondeau <trondeau@221aa14e-8319-0410-a670-987f0aec2ac5> Date: Tue, 15 Apr 2008 17:06:46 +0000 Subject: Adjusting structure a bit to redistribute responsibilities. This does not change the behavior or performance at all. The sync. block only calculates the frequency and timing signals and now outputs the fine frequency adjustment signal from output 0 and the timing signal for the start of the packet from output 1. git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@8198 221aa14e-8319-0410-a670-987f0aec2ac5 --- gnuradio-core/src/python/gnuradio/blks2impl/ofdm.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'gnuradio-core/src/python/gnuradio/blks2impl/ofdm.py') diff --git a/gnuradio-core/src/python/gnuradio/blks2impl/ofdm.py b/gnuradio-core/src/python/gnuradio/blks2impl/ofdm.py index cc260d8d7c..2663f7cf87 100644 --- a/gnuradio-core/src/python/gnuradio/blks2impl/ofdm.py +++ b/gnuradio-core/src/python/gnuradio/blks2impl/ofdm.py @@ -1,6 +1,6 @@ #!/usr/bin/env python # -# Copyright 2006,2007 Free Software Foundation, Inc. +# Copyright 2006,2007,2008 Free Software Foundation, Inc. # # This file is part of GNU Radio # @@ -197,10 +197,11 @@ class ofdm_demod(gr.hier_block2): self._snr = options.snr # Use freq domain to get doubled-up known symbol for correlation in time domain + zeros_on_left = int(math.ceil((self._fft_length - self._occupied_tones)/2.0)) ksfreq = known_symbols_4512_3[0:self._occupied_tones] for i in range(len(ksfreq)): - if(i&1): - ksfreq[i] = 0 + if((zeros_on_left + i) & 1): + ksfreq[i] = 0 # hard-coded known symbols preambles = (ksfreq,) -- cgit v1.2.3