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)  
 wget http://sourceforge.net/projects/hamlib/files/hamlib/1.2.15.3/hamlib-1.2.15.3.tar.gz  
 tar -xvzf hamlib*  
 cd hamlib*  
 ./configure  
 make  
 make install  
 ldconfig   

 


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  
 Trying 127.0.0.1...  
 Connected to localhost.  
 Escape character is '^]'.  
 f <---- I sent this and got back below:  
 1590000  


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.

{Update}
http://ok1zia.nagano.cz/wiki/WebRig

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

3 comments:

Andy Webster said...

Great page, thanks for sharing. I've just started playing with this idea (http://alloutput.com/amateur-radio/remote-transceiver-operation/) 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

Stan Anderton said...

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.

Unknown said...

Hi,

I think this also could be usefull.. :)
https://www.aa6e.net/wiki/W1HQ_remote

73 de Iz1glg - Federico Briata