# Gr-pyserial

**URL:** <https://www.ruby-forum.com/t/gr-pyserial/232999>\
**Category:** GNU Radio\
**Created:** [November 10, 2014, 1:51pm UTC](https://www.ruby-forum.com/t/gr-pyserial/232999 "2014-11-10T13:51:02Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![addis\_a](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/c4cdca/32.png) [@addis\_a](https://www.ruby-forum.com/u/addis_a)\
**Post date:** [November 10, 2014, 1:51pm UTC](https://www.ruby-forum.com/t/gr-pyserial/232999/1 "2014-11-10T13:51:02Z")

</div>

Hi all! I’m working with gr-pyserial but when i run my blocks i get the  
following:

Loading: “/home/iua/gr-pyserial-master/examples/vsp\_connect.grc”

> > > Done

Showing: “/home/iua/gr-pyserial-master/examples/vsp\_connect.grc”

Generating: “/home/iua/gr-pyserial-master/examples/vsp\_connect.py”

> > > Warning: This flow graph may not have flow control: no audio or usrp  
> > > blocks found. Add a Misc-\>Throttle block to your flow graph to avoid CPU  
> > > congestion.

Executing: “/home/iua/gr-pyserial-master/examples/vsp\_connect.py”

linux; GNU C++ version 4.6.3; Boost\_104601;  
UHD\_003.004.003-175-g09de3c07

Traceback (most recent call last):  
File “/home/iua/gr-pyserial-master/examples/vsp\_connect.py”, line 50,  
in  
  
tb = vsp\_connect()  
File “/home/iua/gr-pyserial-master/examples/vsp\_connect.py”, line 32,  
in  
**init**  
self.serial\_port\_1\_0 =  
grpyserial.serial\_port("/dev/tty1",0,9600,0,1,True)  
File  
“/usr/local/lib/python2.7/dist-packages/grpyserial/serial\_port.py”,  
line 62, in **init**  
num\_msg\_outputs = 1,  
TypeError: **init** () got an unexpected keyword argument  
‘num\_msg\_inputs’

Some who maybe has any experience with gr-pyserial could help me? Is  
there  
a code error or is something wrong with gnuradio?

Thanks all for your help

---

<div class="post-metadata">

**Author:** ![JuliSSn\_AndrSSs\_Que](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/839c29/32.png) [@JuliSSn\_AndrSSs\_Que](https://www.ruby-forum.com/u/JuliSSn_AndrSSs_Que)\
**Post date:** [November 10, 2014, 2:07pm UTC](https://www.ruby-forum.com/t/gr-pyserial/232999/2 "2014-11-10T14:07:45Z")

</div>

Hi Julian,

blind guess: gr-pyserial is from 2012 and thus likely uses GNU Radio  
3.6.something, whereas you’re trying to use it with a more modern  
version of GNU Radio, whose python block object doesn’t have the num…  
argument.  
I think the easiest (and most sensible) solution to this is honoring  
jmalsbury’s work by using an up-to-date version of GNU Radio, employing  
“gr\_modtool nm” to make a new module, add a new block to that using  
“gr\_modtool -l python add” and then copy&paste over most of the code  
into the skeleton you’ve just created.

Best regards,  
Marcus

---

<div class="post-metadata">

**Author:** ![JuliSSn\_AndrSSs\_Que](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/839c29/32.png) [@JuliSSn\_AndrSSs\_Que](https://www.ruby-forum.com/u/JuliSSn_AndrSSs_Que)\
**Post date:** [November 12, 2014, 6:49am UTC](https://www.ruby-forum.com/t/gr-pyserial/232999/3 "2014-11-12T06:49:25Z")

</div>

Well, the whole functionality from the python/ file into the  
corresponding new block

---

<div class="post-metadata">

**Author:** ![JuliSSn\_AndrSSs\_Que](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/839c29/32.png) [@JuliSSn\_AndrSSs\_Que](https://www.ruby-forum.com/u/JuliSSn_AndrSSs_Que)\
**Post date:** [November 12, 2014, 8:30am UTC](https://www.ruby-forum.com/t/gr-pyserial/232999/4 "2014-11-12T08:30:49Z")

</div>

Julian,

again: please always reply to the list; we’re always eager to help, but  
understand that we usually are not willing to offer free debugging if it  
happens for you in private.

Also, how do you think should I guess what goes wrong if you write “I’m  
getting an error”?  
I’d like to refer you to  
[http://gnuradio.org/redmine/projects/gnuradio/wiki/ReportingErrors](http://gnuradio.org/redmine/projects/gnuradio/wiki/ReportingErrors)

Greetings,  
Marcus

---

<div class="post-metadata">

**Author:** ![JuliSSn\_AndrSSs\_Que](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/839c29/32.png) [@JuliSSn\_AndrSSs\_Que](https://www.ruby-forum.com/u/JuliSSn_AndrSSs_Que)\
**Post date:** [November 11, 2014, 7:32am UTC](https://www.ruby-forum.com/t/gr-pyserial/232999/5 "2014-11-11T07:32:24Z")

</div>

No, that should not happen. gr\_modtool is as much part of GNU Radio as  
is the gnuradio-companion.

This sounds like you might have mixed multiple installations of GNU  
Radio.  
Greetings,  
Marcus
