# "QAM Demod" error in GRC

**URL:** <https://www.ruby-forum.com/t/qam-demod-error-in-grc/220585>\
**Category:** GNU Radio\
**Created:** [June 13, 2012, 4:57pm UTC](https://www.ruby-forum.com/t/qam-demod-error-in-grc/220585 "2012-06-13T16:57:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![aris](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/258eb7/32.png) [@aris](https://www.ruby-forum.com/u/aris)\
**Post date:** [June 13, 2012, 4:57pm UTC](https://www.ruby-forum.com/t/qam-demod-error-in-grc/220585/1 "2012-06-13T16:57:49Z")

</div>

Hi all,

I’m using GRC and the simple flow graph(1) at receiver is as follows:

Usrp source----\>qam demod----\>file sink

It works fine at first. However, when I tried to execute another similar  
flow graph(2) that was built before UPDATING GNURADIO from 3.5.0 to  
3.6.0.  
an error occurs:

Generating:"/home/azalea/exp/top\_block.py"

executing:"/home/azalea/exp/top\_block.py"

File :"/home/azalea/exp/top\_block.py", line 79

Self.digital\_qam\_demod\_0=-----------\>

Syntax error: invalid syntax

(I looked up the python file, line 79 and line 80 are:

Self.digital\_qam\_demod\_0=-----------\>

Cannot find ‘gray\_coded’: digital.qam.qam\_demod(

)

Then, I return to the mentioned flow graph(1), same error again.

I also tried to start a new flow graph or make/make install gnuradio,  
but in  
vain.

I’m just confused. The flow graph(1) worked well even after updating  
gnuradio. After that and before the error I didn’t remove or modify any  
module in gnuradio.

Thanks a lot!

Best,

Jia

---

<div class="post-metadata">

**Author:** ![jiajue\_ou](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/47e85d/32.png) [@jiajue\_ou](https://www.ruby-forum.com/u/jiajue_ou)\
**Post date:** [June 14, 2012, 4:58pm UTC](https://www.ruby-forum.com/t/qam-demod-error-in-grc/220585/2 "2012-06-14T16:58:33Z")

</div>

This is a bug.  
In file gr-digital/grc/digital\_qa\_demod.xml the line  
gray\_coded = $gray\_coded  
should be changed to  
mod\_code = $mod\_code

---

<div class="post-metadata">

**Author:** ![jiajue\_ou](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/47e85d/32.png) [@jiajue\_ou](https://www.ruby-forum.com/u/jiajue_ou)\
**Post date:** [June 28, 2012, 8:53pm UTC](https://www.ruby-forum.com/t/qam-demod-error-in-grc/220585/3 "2012-06-28T20:53:04Z")

</div>

jiajue ou wrote in post #1064430:

> Hi all,
> 
> I’m using GRC and the simple flow graph(1) at receiver is as follows:
> 
> Usrp source----\>qam demod----\>file sink
> 
> It works fine at first. However, when I tried to execute another similar  
> flow graph(2) that was built before UPDATING GNURADIO from 3.5.0 to  
> 3.6.0.  
> an error occurs:
> 
> Generating:“/home/azalea/exp/top\_block.py”
> 
> executing:“/home/azalea/exp/top\_block.py”
> 
> File :“/home/azalea/exp/top\_block.py”, line 79
> 
> Self.digital\_qam\_demod\_0=-----------\>
> 
> Syntax error: invalid syntax
> 
> (I looked up the python file, line 79 and line 80 are:
> 
> Self.digital\_qam\_demod\_0=-----------\>
> 
> Cannot find ‘gray\_coded’: digital.qam.qam\_demod(
> 
> )
> 
> Then, I return to the mentioned flow graph(1), same error again.
> 
> I also tried to start a new flow graph or make/make install gnuradio,  
> but in  
> vain.
> 
> I’m just confused. The flow graph(1) worked well even after updating  
> gnuradio. After that and before the error I didn’t remove or modify any  
> module in gnuradio.
> 
> Thanks a lot!
> 
> Best,
> 
> Jia

I solved by editing the file  
/usr/local/share/gnuradio/grc/block/digital\_qam\_demod.xml

and by changing of the line

mod\_code

to

gray\_coded

I used that for 3.6.1 version

Joeldo
