I plot the signal before the tx and after the rx on same graph to compare between them while increasing noise to know how much noise can affect it for different types of channel & frequency offset . But when I set noise to zero , I find that the 2 signals are not the same ! why ?! They may be the same but they are not synchronized . How to solve this problem ?
(Attached the loopback.grc & the graph)
------------------------------------------------------------------------------------------------------
Second , There is a variable called sync word , I know that it is for synchronization using schmidl and cox algorithm & I know that is takes fft length & occupied carriers & pilot carriers
as it is written in "ofdm_rxrx.py
"if sync_word1 is None:
self.sync_word1 = _make_sync_word1(fft_len, occupied_carriers, pilot_carriers)"
But why I get an error syaying that " sync words must be fft length" when I write in sync word 1 & sync word 2 fields in the tx & rx block : (128, (range(-61,-42)+range(-41, -14) + range(-13, -7) + range(-6, 0) + range(1, 7) + range(7, 14) + range(15, 42)+range(43,62),) , ((-42, -14, 14, 42,),) ) ?
------------------------------------------------------------------------------------------------------------
Third , I tried my parameters in loopback example & I got no error , but I want to try tx_ofdm.grc with my parameters & put file sink after each block to understand , but I got an error in tx_ofdm.grc . Why I got an error while the same parameters don't give an error in loopback ?!!
Only I changed these parameters to be mine in tx & rx :
fft len=128 , CP =fft_len/8=16 , packet length=87
occupied carriers = (range(-61,-42)+range(-41, -14) + range(-13, -7) + range(-6, 0) + range(1, 7) + range(7, 14) + range(15, 42)+range(43,62),)
pilot carriers : ((-42, -14, 14, 42,),)
pilot symbols : (((-1+1j),(1-1j),(-1+1j),(-1-1j),),)
sync_word1=None , sync_word2=None
Here is the full output when executing :
Using Volk machine: sse4_2_64_orc
Traceback (most recent call last):
File "/home/sara/trials/tx_ofdm.py", line 241, in <module>
tb = tx_ofdm()
File "/home/sara/trials/tx_ofdm.py", line 100, in __init__
self.digital_ofdm_carrier_allocator_cvc_0 = digital.ofdm_carrier_allocator_cvc(fft_len, occupied_carriers, pilot_carriers, pilot_symbols, (sync_word1, sync_word2), length_tag_key)
File "/usr/local/lib/python2.7/dist-packages/gnuradio/digital/digital_swig.py", line 4312, in make
return _digital_swig.ofdm_carrier_allocator_cvc_make(*args, **kwargs)
TypeError: in method 'ofdm_carrier_allocator_cvc_make', argument 5 of type 'std::vector< std::vector< gr_complex,std::allocator< gr_complex > >,std::allocator< std::vector< gr_complex,std::allocator< gr_complex > > > > const &'
Thanks is advance