Friday, April 12, 2013

Raspberry Pi web based rig control?

A while back my friend and I found hamlib, a development library designed to remotely control nearly any CAT/CIV capable transceiver or receiver.  It compiles and works just fine on the Raspberry Pi.

 Before-hand ensure you have these dependencies installed:  
 libltdl-dev or libltdl-devel or libtool-ltdl-devel (use yum/apt-get)  
 tar -xvzf hamlib*  
 cd hamlib*  
 make install  


So we have been using SSH and hamlib to control a remote Icom 706.  We have been using speak freely to stream the audio.

I have been meaning to try and create a PHP/CGI web based front end for this.  Couple that with darkice and icecast for a way to stream audio to that browser.

There is network daemon version of rigctl that works like so:

rigctld -r /dev/ttyUSB0 -m 311 & 

Then control can be done via TCP port 4532:
 root@darkpi-ice:/# telnet localhost 4532  
 Connected to localhost.  
 Escape character is '^]'.  
 f <---- I sent this and got back below:  

Here is a screen shot of my web control front end:

Here is the radio with the Raspberry Pi, USB sound input, USB TTL converter for CIV.
Basically a way to enable web based control of a radio with CIV.  Remi, F4ECW has some example PHP code for this that I snagged from a Yahoo group.  It also appears to have a start for remote fldigi.


Another good project would be to layout a small board with jumper selectable COR and PTT transistor configurations than can be interfaced to the Raspberry Pi GPIO.  So far I have just been bread-boarding this.

I just haven't had the time to create such art work and submit it to Far Circuits.

Again if anyone wants to beat me to the punch on either of this, please do.
Worth reading: "Raspberry Pi: A Tiny Computer for Big Projects" by; Matt, KB3TAN - CQ Magazine, March 2013


  1. Great page, thanks for sharing. I've just started playing with this idea ( but hadn't realised hamlib could do the whole serial proxy bit. I expect speakeasy is easier than Pulseaudio to so I'll check that out. Really useful, thanks and 73, Andy G7UHN

  2. I see this blog post was a while back and the newer Raspberry Pi models are substantially faster, the Pi2 being a quad core. Have you done more with the rig control using newer Pi's? I have a couple B+'s and the Pi2, and just acquired a 706MkIIg to add to my shack. In my new house I don't really have a fixed place for my shack so am thinking that remote control may be the answer. I have several 'real' computers, but I love the Pi and would like to utilize one or more of them to run my radios.

    Any updates?

    AD7LX from Washington State.

  3. Hi,

    I think this also could be usefull.. :)

    73 de Iz1glg - Federico Briata