remoting your rig - Page 1
Forum section: electronics / rf-microwave

author: djacobow
author_rank: Super Contributor
timestamp: March 13, 2017, 11:41:18 pm
content: My radio, IC-7300, like most recentish Icoms, has a built in USB based sound card and serial controller. Now that I've solved my USB hiccup problems, it's really quite elegant.Which got me wondering how hard it would be to remote my rig. Icom has software specifically for this (RS-BA1 -- gets middling reviews), but I thought I'd try my hand at rolling my own to save $100 but also because I would like the radio server to be an RPi 3 rather than a full PC I need to leave on.I'm happy to report some success.Forwarding the serial port is easy from linux to linux using "socat". I can also forward it from linux to windows using a virtual serial port program that will talk to tcp. This runs just fine with an x86 box as the "host" or an RPi, and you can easily put this in an ssh tunnel. So rig control, no problem.# serverstty -F /dev/ttyUSB0 19200 cs8 ixoffsocat -d -d TCP-LISTEN:7001,nodelay,fork /dev/ttyUSB0,raw,b19200,echo=0# clientsocat -d -d pty,raw,b19200 tcp:localhost:7001,nodelaysudo chmod a+rw /dev/pts/9 # or whatever pty was returnedThe audio is harder. I worked for awhile with Linux and PulseAudio to serve streams in both directions. It can be made to work after a fashion, but I find it really complex. Though I got it to work a couple of times, I am not quite sure how.Then I saw programs that can forward USB over IP. This way you can take the entire "device" and ship it to the client machine. In this case, the device is just the "audio card." Most Linux builds seem to have usbip built in, and with that, I was able to forward my audio device to a tcp socket. On the other end, I attach to that device, and the other computer thinks it's connected directly to the radio.I've gotten this to work linux host to linux client, but even after hunting around for windows clients, I have not had any success going to a windows client.# server# load necessary modulesmodprobe vhci-hcdmodprobe usbip-coremodprobe usbip-host# make the device that you want to share availble. Find it with usbip list ...usbip bind -b 3-3.7.2.4# start the usbip server as a daemon (or leave out the -D to let it run in the foreground)usbipd -D# on the client side:# use the server's IP address and the address of the device you previously sharedusbip attach -r 10.0.0.6 -b 3-3.7.2.4On my system most but not all of these need to be done sudo.I don't know how this type of solution would work over the open internet, but at home on the LAN, it seems pretty stable. I use it to access my radio (which is literally in a shack) from my office in the house. It works with fldigi pretty well, but wsjt-x won't work for rig control because the program doesn't let you specify a pty.Anyway, something to play with. There are also commercial hardware USB-over-IP devices, but I suspect they are not much better. There are also commercial hardware devices specifically for remoting a rig, but with their own ADC/DAC, that pretty much lose the charming simplicity of a USB connection only.If anybody has gone further down this path, I'd be interesting in hearing stories and advice.Best,Dave