This page is dedicated to how to use the KX3 remotely with the KX3 Companion App.
Starting from version 8 (Uranus) the Piglet support has been “expanded” and now it not only suports the Pigremote device but also can be used to control the KX3 remotely via KX3 Companion.
THIS IS STILL EXPERIMENTAL.
The page will be updated as I update the code both for the app and for the host side.
Actually you’ll only be able to control the radio, no audio in/out is streamed but I’m working on a separate background app able to do that.
So here are the instructions to setup the host (the device attached to the KX3).
You need a PC or a device able to the ser2net application. I personally used a Raspberry Pi that works particularly well with this setup.
If you have a Windows PC:
- download Socat binaries for Windows: http://blog.gentilkiwi.com/programmes/socat#englishversion
- You’ll need to execute it from the command line so you’ll need to open CMD.exe and move to where you saved the “Socat” program
- plug the USB Serial cable to the KX3 ACC1 port and to one of the USB ports of your PC
- socat /dev/ttyS7,raw,echo=0,crnl TCP-LISTEN:7777
instead of /dev/ttyS7 you have to put the COM number (-1) so for example if the COM port for the serial USB cable is COM4, then use /dev/ttyS3.
On the Raspberry Pi (Linux):
- plug the USB Serial cable to the KX3 ACC1 port and to one of the two Raspberry Pi USB ports
- install ser2net:
sudo apt-get update
sudo apt-get install ser2net
- edit the /etc/ser2net.conf file:sudo nano /etc/ser2net.conf
- add the following line:
7777:raw:0:/dev/ttyUSB0:38400 8DATABITS NONE 1STOPBITand save the file by pressing CTRL+X and then Y
- execute the ser2net:
sudo /etc/init.d/ser2net restart
Once you’re done with the host you can open the app on your Android mobile device.
Make sure that you have the latest version.
To enable the KX3 Remote functionality you have to edit 3 options (“Remote Settings” section)
- Check the “Use KX3Remote/Piglet/Pigremote” option
- Set your PC/Raspberry Pi IP address in the “KX3Remote/Piglet/Pigremote IP” option
- Set the choosen Port number (7777) on the PC/Raspberry Pi IP address in the “KX3Remote/Piglet/Pigremote Port” option
For a first test, use the internal network IP address.
But to use it from out of home/office you’ll need a public address/IP for your Host PC/Raspberry Pi.
I suggest you to use a “dynamic dns” service that will give you a unique public hostname (mine for example is “kx3remote.raspctl.com”) to connect to your host from anywhere
I personally use the raspctl.com service. More information here:
And here are the instructions to install the raspctl.com service on the Raspberry Pi:
One more thing that you may need to do is modify your router to allow external access to your host/network using a specific port.
More information about that here:
And that’s it for the remote control for now. This is experimental and I’m working
And The Audio?
I’m still working on the audio part and thinking about integrating SIP services support and the next version will probably support it already. When it’ll be here you’ll find detailed instructions about how to manage audio as well.
In the meanwhile there’s a “quick and dirty” way to have the audio using Skype.
Skype is available for every platform. You can install on Windows, OS X and Linux. All you have to do is:
- create an account for the KX3 🙂
- Add your personal contact to it
- make it so that the KX3 Skype automatically answers calls from your personal account
- make sure that on the KX3 VOX is enabled on every modality
This way you can call the KX3 Skype account from your Android tablet/phone, it’ll automatically answer and you’ll be able to listen/talk to the KX3. Just to make sure that the noise coming from the Android device doesn’t open the KX3 mic, set the Android Skype on MUTE and UNMUTE it only when you want to talk/transmit.
Note that on Android you can easily set Skype on background and still listen to it.
Use A Raspberry Pi2 and KX3 Companion App To Remotely Control The KX3 With Audio Streaming!
Thanks to Trung W6TN I’m able to show you detailed information on how to control remotely your KX3 using a Raspberry Pi and an Android device with KX3 Companion in it.
Here are the instructions by Trung W6TN:
These steps are only about the audio part of KX3Companion Remote.
I used three devices: an Android phone (OnePlus One), a Raspberry Pi2, and a Macbook Pro. I bought a USB Audio card from plugable.com (via Amazon)
- Go to this website to install both Mumble Server & Mumble Client on the Raspberry Pi2
There is a link to mumble.org where all Mumble Client for different OS are there.
Note: There is a circular way to install Mumble Client for Raspberry Pi2, you can click on the “Download Linux Client Version 1.2.8”, which will lead to another link
Essentially, the command is “apt-get install mumble” or “sudo apt-get install mumble”
- Install a Mumble Client on Macbook (or Windows-based computer)
- Install Plumble (a Mumble Client) on an Android phone (or tablet)
- Force default sound module to be disabled and the new usb sound card is enabled by following instruction here:
- Adjust input and output level of the USB sound card by following instruction here:
Use an iPod or sound source (like Pandora from a smartphone) to play continuously while recording a test as suggested on this link. Remember the card number of the USB sound card, more likely zero (not 1).
- Run Mumble client from multiple devices: Pi2, Macbook, or Android phone. Try testing connection at least from the Macbook and the Android phone.
- Run the recorded sound test from Pi2 and listen from either Macbook or Android phone. Adjust the volume as previously stated.
- Finally, start from fresh then either run KX3Companion first, Mumble second or vice versa
Thanks a lot again to Trung W6TN for spending so much time testing the solution.
It works great and simply needs a Raspberry Pi2 (maybe it also works on with a Raspberry Pi but haven’t tried it yet) and a USB Audio card for it.
Another way to enable Serial Over TCP in Linux (Raspberry Pi) using “netcat”
- install netcat:sudo apt-get update
sudo apt-get install netcat
- run netcat redirect:
netcat -l 7777 > /dev/ttyUSB0 < /dev/ttyUSB0
Or you can use Socat on Linux (Raspberry Pi) as well:
- install socat:sudo apt-get update
sudo apt-get install socat
- run netcat redirect:
socat /dev/ttyUSB0 ,raw,echo=0,crnl TCP-LISTEN:7777