# Rx\_ofdm Does Not Work Past Synchronizer

**URL:** <https://www.ruby-forum.com/t/rx-ofdm-does-not-work-past-synchronizer/239897>\
**Category:** GNU Radio\
**Created:** [March 19, 2014, 12:34am UTC](https://www.ruby-forum.com/t/rx-ofdm-does-not-work-past-synchronizer/239897 "2014-03-19T00:34:51Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![musicdenotation](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/m/ea666f/32.png) [@musicdenotation](https://www.ruby-forum.com/u/musicdenotation)\
**Post date:** [March 19, 2014, 12:34am UTC](https://www.ruby-forum.com/t/rx-ofdm-does-not-work-past-synchronizer/239897/1 "2014-03-19T00:34:51Z")

</div>

So I have the stock python scripts (tx\_ofdm and rx\_ofdm) located in the  
gr-digital examples and put USRP sources and sinks in the appropriate  
spots. I left sampling alone (100K for TX, 3.2M for RX) and had the  
TX/RX  
frequency at 500 MHz. The USRPs used are N210s with WBX daughterboards.  
I  
tested the USRP used for TX out by outputting a signal to another and  
looking at it on the GNU Radio spectrum analyzer. Also, this is through  
SMA  
cables and a 30 dB attenuator, no over the air transmission. I placed  
file  
sinks after each block in the process; each file is a binary file. After  
multiple runs I felt like something wasn’t working after looking at the  
binary files.

When I execute, only the file sinks placed after the Schmidl & Cox OFDM  
Synchronizer freq\_offset and detect have data in them, at least their  
files  
have some size to them, implying something has been written. The file  
sinks  
after FFT (or the header/payload demux) have no data, 0 KB.

When I discovered that the receive didn’t work, I took the grc file  
another  
user made back in October with both TX mod and RX demod in the same  
flowgraph to see if that would work (files attached). Again same issue,  
all  
the binary files after the FFT have no data so something is getting  
screwed  
up in my demod.

Has any user on this list run into this issue before or can offer some  
insight to why the receiver is failing?

Thank you,

Jon

Attached is the python script, grc file, and screen shot of the TXRX  
combo  
in GRC.

---

<div class="post-metadata">

**Author:** ![jfaulkenberry](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/c2a13f/32.png) [@jfaulkenberry](https://www.ruby-forum.com/u/jfaulkenberry)\
**Post date:** [March 19, 2014, 12:54am UTC](https://www.ruby-forum.com/t/rx-ofdm-does-not-work-past-synchronizer/239897/2 "2014-03-19T00:54:09Z")

</div>

Hi Jon,

Disclaimer: I haven’t run your code, but based on eyeballing the png  
file:

It looks like your “delay” block is not configured properly. The delay  
should be fft\_len + cp\_len which is 80 (instead of 72).

Best,  
Aditya

---

<div class="post-metadata">

**Author:** ![jfaulkenberry](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/c2a13f/32.png) [@jfaulkenberry](https://www.ruby-forum.com/u/jfaulkenberry)\
**Post date:** [March 19, 2014, 1:04am UTC](https://www.ruby-forum.com/t/rx-ofdm-does-not-work-past-synchronizer/239897/3 "2014-03-19T01:04:40Z")

</div>

And if you are running over the air, try setting the TX and RX sampling  
rate to have the same value.

In any case, I would first run in loopback mode (as shown in your png  
file)  
and save the over-the-air transmissions for later.

---

<div class="post-metadata">

**Author:** ![jfaulkenberry](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/c2a13f/32.png) [@jfaulkenberry](https://www.ruby-forum.com/u/jfaulkenberry)\
**Post date:** [March 19, 2014, 12:51pm UTC](https://www.ruby-forum.com/t/rx-ofdm-does-not-work-past-synchronizer/239897/4 "2014-03-19T12:51:24Z")

</div>

On 03/19/2014 12:25 AM, Jonathan F. wrote:

> So I have the stock python scripts (tx\_ofdm and rx\_ofdm) located in the  
> gr-digital examples and put USRP sources and sinks in the appropriate  
> spots. I left sampling alone (100K for TX, 3.2M for RX) and had the  
> TX/RX frequency at 500 MHz. The USRPs used are N210s with WBX  
> daughterboards. I tested the USRP used for TX out by outputting a signal  
> to another and looking at it on the GNU Radio spectrum analyzer. Also,  
> this is through SMA cables and a 30 dB attenuator, no over the air  
> transmission. I placed file sinks after each block in the process; each  
> file is a binary file. After multiple runs I felt like something wasn’t  
> working after looking at the binary files.

Maybe you’re probably screwing up your tx signal by clipping, although I  
can’t say for sure from your flow graphs (where exactly do you put the  
UHD sink?) See  
[http://video.fosdem.org/2014/AW1125/Sunday/Tutorial\_OFDM\_Packet\_Transceivers.webm](http://video.fosdem.org/2014/AW1125/Sunday/Tutorial_OFDM_Packet_Transceivers.webm),  
starting around ~27 mins for an explanation, or search the mailing list  
archive.

Martin

---

<div class="post-metadata">

**Author:** ![jfaulkenberry](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/c2a13f/32.png) [@jfaulkenberry](https://www.ruby-forum.com/u/jfaulkenberry)\
**Post date:** [March 19, 2014, 8:42pm UTC](https://www.ruby-forum.com/t/rx-ofdm-does-not-work-past-synchronizer/239897/5 "2014-03-19T20:42:11Z")

</div>

Thanks for the responses.

When I use the USRPs the UHD sink is placed after the OFDM Cyclic  
Prefixer,  
right after the Mutliply Const (50m). I haven’t changed any settings  
because I remember reading in a few previous emails that the most common  
question people ask is “Did you change anything?”

Sadly, the delay wasn’t the case, at least for the loopback mode.

I reduced the amplitude of the signal by an additional 0.02, so the  
multiply constant is at 0.03 as opposed to 0.05. It brought the clipping  
well within +1, -1. Before the signal clipped past -1 but never rose  
above  
+1. No effect but I am not ruling out that it wouldn’t help.

The video is interesting enough that I am going to continue watching  
after  
the first half, maybe I can figure out more from there.

Jon

---

<div class="post-metadata">

**Author:** ![jfaulkenberry](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/c2a13f/32.png) [@jfaulkenberry](https://www.ruby-forum.com/u/jfaulkenberry)\
**Post date:** [March 20, 2014, 10:06am UTC](https://www.ruby-forum.com/t/rx-ofdm-does-not-work-past-synchronizer/239897/6 "2014-03-20T10:06:57Z")

</div>

A good way to test is to use the hier blocks for OFDM (you still need to  
reduce amplitude), they will set up everything in a way that will work  
for sure. See the loopback example in gr-digital/examples/ofdm.

M

---

<div class="post-metadata">

**Author:** ![jfaulkenberry](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/c2a13f/32.png) [@jfaulkenberry](https://www.ruby-forum.com/u/jfaulkenberry)\
**Post date:** [March 20, 2014, 5:15pm UTC](https://www.ruby-forum.com/t/rx-ofdm-does-not-work-past-synchronizer/239897/7 "2014-03-20T17:15:46Z")

</div>

So I found the loopback script, tied the ends together with a multiply  
const block and was successful in modding and demodding that sinusoidal  
waveform. Added a UHD source and sink, success again. Then I split the  
process into two separate GRC files, a TX and a RX script. Everything  
works. I am extremely happy right now to see OFDM work. Thank you for  
the  
nudge in the right direction.

So the next question I have is why I have success with the hierarchal  
blocks in the loopback script but not so much with rx\_ofdm or that  
custom  
loopback I posted? Even with a binary file source with the modulated  
signal, that rx script won’t work. I wouldn’t say too terribly important  
but it is interesting to learn how OFDM works. But for what I am working  
on, those hierarchical blocks will suffice.

Thanks again.

Jon

---

<div class="post-metadata">

**Author:** ![jfaulkenberry](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/c2a13f/32.png) [@jfaulkenberry](https://www.ruby-forum.com/u/jfaulkenberry)\
**Post date:** [March 20, 2014, 7:47pm UTC](https://www.ruby-forum.com/t/rx-ofdm-does-not-work-past-synchronizer/239897/8 "2014-03-20T19:47:39Z")

</div>

On 03/20/2014 05:14 PM, Jonathan F. wrote:

> modulated signal, that rx script won’t work. I wouldn’t say too terribly  
> important but it is interesting to learn how OFDM works. But for what I  
> am working on, those hierarchical blocks will suffice.

Well, it’s hard to say from a distance, but you could check the output  
on the header path after the header/payload demuxer to see what’s going  
on.

M
