# Error Running uhd\_tx\_dpsk.grc and uhd\_rx\_dpsk.grc

**URL:** <https://www.ruby-forum.com/t/error-running-uhd-tx-dpsk-grc-and-uhd-rx-dpsk-grc/221418>\
**Category:** GNU Radio\
**Created:** [July 13, 2012, 10:08am UTC](https://www.ruby-forum.com/t/error-running-uhd-tx-dpsk-grc-and-uhd-rx-dpsk-grc/221418 "2012-07-13T10:08:57Z")\
**Posts on this page:** 4\
**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:** [July 13, 2012, 10:08am UTC](https://www.ruby-forum.com/t/error-running-uhd-tx-dpsk-grc-and-uhd-rx-dpsk-grc/221418/1 "2012-07-13T10:08:57Z")

</div>

Hi everyone,

I have just started on GNURadio for an undergraduate project and I would  
require a little assistance.

I tried to run the dpsk transmitter and receiver examples, found in  
gnuradio/examples/uhd/uhd\_rx\_dpsk.grc and  
gnuradio/examples/uhd/uhd\_tx\_dpsk.grc. I am using the N210 USRP with the  
WBX  
daughterboard and the VERT2450 antenna, with GNURadio version 3.6.0  
running  
on Ubuntu 12.04 LTS.

When I run the transmit file, I receive the following error:  
Traceback (most recent call last):  
File “/tmp/uhd\_tx\_dpsk.py”, line 234, in   
tb = uhd\_tx\_dpsk(samp\_rate=options.samp\_rate, freq=options.freq,  
gain=options.gain, address=options.address)  
File “/tmp/uhd\_tx\_dpsk.py”, line 150, in **init**  
log=False)  
File “/usr/lib/python2.7/dist-packages/gnuradio/digital/qpsk.py”, line  
139, in **init**  
\*args, \*\*kwargs)  
TypeError: **init** () got an unexpected keyword argument ‘mod\_code’

When I run the receive file, I receive the following error:  
Traceback (most recent call last):  
File “/tmp/uhd\_rx\_dpsk.py”, line 327, in   
tb = uhd\_rx\_dpsk(samp\_rate=options.samp\_rate, freq=options.freq,  
gain=options.gain, address=options.address,  
freq\_offset=options.freq\_offset)  
File “/tmp/uhd\_rx\_dpsk.py”, line 217, in **init**  
log=False  
File “/usr/lib/python2.7/dist-packages/gnuradio/digital/qpsk.py”, line  
165, in **init**  
\*args, \*\*kwargs)  
TypeError: **init** () got an unexpected keyword argument ‘mod\_code’

Both errors look similar and have something to do with “mod\_code”. Does  
anyone know how to solve it? Also, any suggestions on another GRC  
receive/transmit example I can use to test out my N210 USRP boards?  
Thank  
you very much!

## Tan Chong Min Undergraduate National University of Singapore

View this message in context:  
[http://old.nabble.com/Error-Running-uhd\_tx\_dpsk.grc-and-uhd\_rx\_dpsk.grc-tp34154704p34154704.html](http://old.nabble.com/Error-Running-uhd_tx_dpsk.grc-and-uhd_rx_dpsk.grc-tp34154704p34154704.html)  
Sent from the GnuRadio mailing list archive at [Nabble.com](http://Nabble.com).

---

<div class="post-metadata">

**Author:** ![chongmin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/df705f/32.png) [@chongmin](https://www.ruby-forum.com/u/chongmin)\
**Post date:** [July 13, 2012, 7:12pm UTC](https://www.ruby-forum.com/t/error-running-uhd-tx-dpsk-grc-and-uhd-rx-dpsk-grc/221418/2 "2012-07-13T19:12:24Z")

</div>

On 07/13/2012 01:08 AM, chongmin wrote:

> on Ubuntu 12.04 LTS.  
> \*args, \*\*kwargs)  
> TypeError: **init** () got an unexpected keyword argument ‘mod\_code’

I believe that this grc file has suffered bit rot due to new  
developments in the code, specifically gr-digital component. I think Tom  
would know whats missing.

> Both errors look similar and have something to do with “mod\_code”. Does  
> anyone know how to solve it? Also, any suggestions on another GRC  
> receive/transmit example I can use to test out my N210 USRP boards? Thank  
> you very much!

If you happen to have a spectrum analyzer and signal generator. Its  
often very nice to make a simple GRC app that sends and receives a test  
tone.

Be careful if you plan to loopback TX into RX port on the daughterboard.  
Use low gain and lots of attenuation!

-josh

---

<div class="post-metadata">

**Author:** ![chongmin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/df705f/32.png) [@chongmin](https://www.ruby-forum.com/u/chongmin)\
**Post date:** [July 17, 2012, 7:47am UTC](https://www.ruby-forum.com/t/error-running-uhd-tx-dpsk-grc-and-uhd-rx-dpsk-grc/221418/3 "2012-07-17T07:47:45Z")

</div>

Dear Martin and Josh,

Thank you for your assistance. I realized the error was that I  
downloaded a  
binary which was outdated. After using the build-gnuradio script by  
Marcus,  
the error is no longer there.

Chong Min

chongmin wrote:

> running on Ubuntu 12.04 LTS.  
> \*args, \*\*kwargs)  
> File “/usr/lib/python2.7/dist-packages/gnuradio/digital/qpsk.py”, line  
> Undergraduate  
> National University of Singapore

–  
View this message in context:  
[http://old.nabble.com/Error-Running-uhd\_tx\_dpsk.grc-and-uhd\_rx\_dpsk.grc-tp34154704p34171805.html](http://old.nabble.com/Error-Running-uhd_tx_dpsk.grc-and-uhd_rx_dpsk.grc-tp34154704p34171805.html)  
Sent from the GnuRadio mailing list archive at [Nabble.com](http://Nabble.com).

---

<div class="post-metadata">

**Author:** ![chongmin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/df705f/32.png) [@chongmin](https://www.ruby-forum.com/u/chongmin)\
**Post date:** [July 16, 2012, 9:06am UTC](https://www.ruby-forum.com/t/error-running-uhd-tx-dpsk-grc-and-uhd-rx-dpsk-grc/221418/4 "2012-07-16T09:06:41Z")

</div>

On Fri, Jul 13, 2012 at 01:08:12AM -0700, chongmin wrote:

> TypeError: **init** () got an unexpected keyword argument ‘mod\_code’  
> Hi chongmin,

pull a recent git, it should be fixed there.

## MB

Karlsruhe Institute of Technology (KIT)  
Communications Engineering Lab (CEL)

Dipl.-Ing. Martin B.  
Research Associate

Kaiserstraße 12  
Building 05.01  
76131 Karlsruhe

Phone: +49 721 608-43790  
Fax: +49 721 608-46071  
www.cel.kit.edu

KIT – University of the State of Baden-Württemberg and  
National Laboratory of the Helmholtz Association
