Ham Radio Command Center 🙏
Portable executable webserver/client that can be run on Windows/MacOS/Linux.
RESTful WebServer in Go that talks to radios via serial port calls.
Frontend is in Hyperapp
Currently ICOM is the main development focus.
However you can input any SERIAL_PORT/BAUD_RATE/HEX you like, so technically anything (like sending hex to an arduino)!
Please check the releases page: https://github.com/selfup/hmrcmd/releases
Go to the releases page: https://github.com/selfup/hmrcmd/releases
- Windows, download the latest
.exe
release - MacOS, download the latest
darwin-
release - Linux, download the latest
linux-
release
Once downloaded:
-
Windows:
- Double click the
exe
- Warning Protected Screen click -> More Info -> Allow
- Firewall -> Allow
- Done!
- Double click the
-
MacOS/Linux execute the file via the commandline:
./path/to/latest/release
It will auto open a browser window and be ready to run 🎉
-
ICOM Endpoint
- Url:
http://localhost:8792
- Route:
/api/v1/icom-cmd
- Method:
POST
- Body (JSON):
{SerialPort: '', IcomCommand: '', BaudRate: ''}
- Example payload:
{SerialPort: 'COM3', IcomCommand: 'FE FE 94 E0 26 00 05 00 01 FD', BaudRate: '9600'}
- Url:
😄
Please read the CODE_OF_CONDUCT.md
file 🙏
I use VSCode with three extensions for this project:
Please fork the project and make a Pull Request (PR) to contribute!
Install Go Deps: go mod download
Install JS deps: npm install
npm start
Caveats
Can make API calls when running the go server but you have to kill and reload the go server for new backend functionality.
To make calls to the radio while using the frontend:
go run main.go
To test API calls without using the frontend there are scripts!
Windows
./scripts/post.cmd.ps1
MacOS / Linux
./scripts/post.cmd.sh
./scripts/releases.sh
Windows
Observing commands on Windows
Create a virtual port pair with com0com and then connect to one of the port pairs with RealTerm.
Set baudrate to 9600 and on the display tab set to either hex [with space] or binary (up to you)
Now make sure to send the commands to the other end of the pair!
Example:
- com0com pair: COM12 - COM13
- RealTerm listen to: COM12
- SerialPort for HEX command: COM13
MacOS/Linux
MacOS
Install socat brew install socat
or install the binary yourself.
Linux (Ubuntu)
Install socat sudo apt install socat
or install the binary yourself.
Observing commands on MacOS/Linux
Ok this gets interesting
In a terminal/pane/tab can either run:
socat -d -d pty,raw,echo=0 pty,raw,echo=0
./scripts/virtual.pair.sh
You will see output like so
2018/07/29 09:43:54 socat[20004] N PTY is /dev/ttys007
2018/07/29 09:43:54 socat[20004] N PTY is /dev/ttys008
2018/07/29 09:43:54 socat[20004] N starting data transfer loop with FDs [5,5] and [7,7]
Now you will want to pick on of the tty pairs and cat the hexdump in another terminal/pane/tab:
cat /dev/ttys007 | hexdump
Now when you make an API call make sure to use the other port in the pair.
Once you send the message to 008, you will see the hexdump from 007!
It seems you have to make two calls to see it... 🤔
Do not be discouraged! 😄
Example screenshot:
- HEX to BIN table
- CI-V Reference Manual
- ICOM IC-7610 Reference Manual
- Old CT-17 Reference Manual with BASIC code blocks
- Decimal Array to Binary
$port.Write/3
- System.IO.Ports.SerialPort.Write .NET API
CI-V Manual Message Format Snippet