Remotely open audio channels and a serial port to an Icom RS-BA1 server (for ex. Icom IC-705 transceiver).
Find a file
2020-10-29 20:50:56 +01:00
.vscode Use serial port for debug launch 2020-10-28 22:12:29 +01:00
.gitignore Init 2020-10-16 17:13:46 +02:00
args.go Run a cmd (rigctld by default) when connected to the server 2020-10-29 20:28:17 +01:00
audio-linux.go Init virtual sound card, serial port and serial port TCP server only once 2020-10-28 22:32:45 +01:00
audiostream.go Fine tune buffer lengths 2020-10-29 17:05:40 +01:00
civdecoder.go Add displaying PTT/freq/mode info to the status bar 2020-10-29 09:39:13 +01:00
controlstream.go Run a cmd (rigctld by default) when connected to the server 2020-10-29 20:28:17 +01:00
demo.gif Add displaying PTT/freq/mode info to the status bar 2020-10-29 09:39:13 +01:00
go.mod Add displaying PTT/freq/mode info to the status bar 2020-10-29 09:39:13 +01:00
go.sum Add displaying PTT/freq/mode info to the status bar 2020-10-29 09:39:13 +01:00
kappanhang.code-workspace Init 2020-10-16 17:13:46 +02:00
LICENSE Add trademark information to the license 2020-10-27 10:18:07 +02:00
log.go Run a cmd (rigctld by default) when connected to the server 2020-10-29 20:28:17 +01:00
main.go Run a cmd (rigctld by default) when connected to the server 2020-10-29 20:28:17 +01:00
netstat.go Restructure status log handling 2020-10-28 18:03:35 +01:00
passcode.txt Add listing of encoding used in usernames/passwords 2020-10-25 09:27:23 +01:00
pkt0.go Add missing log separators 2020-10-29 17:23:31 +01:00
pkt7.go Reduce pkt7 send interval 2020-10-29 17:38:51 +01:00
README.md Fix typo 2020-10-29 20:31:24 +01:00
runcmd.go Run a cmd (rigctld by default) when connected to the server 2020-10-29 20:28:17 +01:00
seqbuf.go Cleanup 2020-10-26 19:46:08 +01:00
serial-linux.go Init virtual sound card, serial port and serial port TCP server only once 2020-10-28 22:32:45 +01:00
serialstream.go Add displaying PTT/freq/mode info to the status bar 2020-10-29 09:39:13 +01:00
serialtcpsrv.go Fix deinit hang 2020-10-28 22:40:35 +01:00
statuslog.go Reduce uptime padding 2020-10-29 20:50:56 +01:00
streamcommon.go Reduce max. retransmit request packet count 2020-10-29 12:14:07 +01:00
txseqbuf.go Fine tune buffer lengths 2020-10-29 17:05:40 +01:00
util.go Cleanup 2020-10-27 09:25:36 +01:00

kappanhang

kappanhang remotely opens audio channels and a serial port to an Icom RS-BA1 server. The app is mainly developed for connecting to the Icom IC-705 transceiver, which has built-in Wi-Fi and RS-BA1 server. All features of the protocol are implemented including packet retransmission on packet loss.

kappanhang currently only supports Linux, but support for other platforms can be easily added if anyone is interested (volunteers needed).

Compiling

You'll need Go installed on your computer.

go get https://github.com/nonoo/kappanhang
go install https://github.com/nonoo/kappanhang

Required settings on the RS-BA1 server (the transceiver)

You can find these settings on the Icom IC-705 in: Menu -> Set -> WLAN set -> Remote settings.

  • Make sure Network control is turned on.
  • Set the Network user 1 username to beer and the password to beerbeer. These are fixed as the password encoding of the RS-BA1 protocol has not been decrypted yet. See passcode.txt for more information.
  • Leave the UDP ports on their default values:
    • Control port: 50001
    • Serial port: 50002
    • Audio port: 50003
  • Leave the Internet access line on the default FTTH value.

Make sure the DATA MOD (you can find this setting on the Icom IC-705 in: Menu -> Set -> Connectors -> MOD Input -> DATA MOD) is set to WLAN.

Running

You can get the available command line parameters with the -h command line argument.

If no command line arguments are set, then the app will try to connect to the host ic-705 (ic-705.local or ic-705.localdomain).

After it is connected and logged in:

  • Creates a virtual PulseAudio sound card (48kHz, s16le, mono). This can be used to record/play audio from/to the server (the radio). You can also set this sound card in WSJT-X.

    If you want to listen to the audio coming from this sound card in real time, then you can create a PulseAudio loopback between the kappanhang sound card and your real sound card. You can also create a loopback for your microphone using this tool, so you'll be able to transmit your voice.

  • Starts a TCP server on port 4533 for exposing the serial port. This can be used for controlling the server (the transceiver) with Hamlib (rigctld).

  • Runs the command rigctld -m 3085 -r :4533 which starts rigctld and connects it to kappanhang's TCP serial port server. You can specify a custom command with the -r command line argument. Running any command can be disabled with -r -.

    3085 is the model number for the Icom IC-705. rigctld will connect to kappanhang's TCP serial port server, and waits connections on it's default TCP port 4532.

    To use this with for example WSJT-X, open WSJT-X settings, go to the Radio tab, set the rig type to Hamlib NET rigctl, and the Network server to 127.0.0.1:4532.

If the -s command line argument is specified, then kappanhang will create a virtual serial port, so other apps which don't support Hamlib can access the transceiver directly. Look at the app log to find out the name of the virtual serial port.

Icom IC-705 Wi-Fi notes

Note that the built-in Wi-Fi in the Icom IC-705 has very limited range, and sensitive to interference. If you see a lot of retransmits in the log, or packet loss, then:

  • Place the IC-705 close to your Wi-Fi AP/router, or use a Wi-Fi range extender device
  • Make sure the Wi-Fi bandwith is set to max. 20Mhz in the Wi-Fi router (see explanation here)
  • Try switching Wi-Fi channel on your Wi-Fi router. Only channels 1, 6 or 11 should be used (see explanation here)

Sometimes rebooting the transceiver helps, as the network stack in the IC-705 is not quite free of bugs. :)

Status bar

kappanhang displays a "realtime" status bar (when the audio/serial connection is up) with the following info:

  • First status bar line:

    • state: RX/TX/TUNE depending on the PTT status
    • freq: operating frequency in MHz, mode (LSB/USB/FM...), active filter
  • Second status bar line:

    • up: how long the audio/serial connection is active
    • rtt: roundtrip communication latency with the server
    • up/down: currently used upload/download bandwidth (only considering UDP payload to/from the server)
    • retx: audio/serial retransmit request count to/from the server
    • lost: lost audio/serial packet count from the server

Data for the first status bar line is acquired by monitoring CiV traffic in the serial stream.

retx and lost are displayed in a 1 minute window, which means they will be reset to 0 if they don't increase for 1 minute. A retx value other than 0 indicates issues with the connection (probably a poor Wi-Fi connection), but if loss stays 0 then the issues were fixed using packet retransmission. loss indicates failed retransmit sequences, so packet loss. This can cause audio and serial communication disruptions.

If status bar interval (can be changed with the -i command line argument) is equal to or above 1 second, then the realtime status bar will be disabled and the contents of the second line of the status bar will be written as new console log lines. This is also the case if a Unix/VT100 terminal is not available.

Authors

Donations

If you find this app useful then buy me a beer. :)