The KISS File Transfer Repeater is a specialized application designed for environments where a single TNC must be shared between a file‐transfer sender and receiver. The repeater buffers and forwards complete bursts of KISS‑framed data between the sender and receiver while simultaneously offering two‑way pass‑through connectivity. In addition to file transfers, the application also immediately forwards CMD/RSP (command/response) packets. Furthermore, the repeater enforces allowed callsigns if desired.
The repeater operates with a single TNC connection (via TCP or serial) and employs a state machine to distinguish and manage different packet types: Header, data, ACK, and CMD/RSP packets. When a header packet is received, its payload—containing metadata such as timeout settings, filename, fileID, encoding method (0 = binary, 1 = base64), compression flag, and total packet count—is logged. Once the sender’s burst of data packets is complete, the state machine forwards the entire burst to the receiver.
In addition, the repeater supports two‑way pass‑through connections: Outgoing: Every KISS frame sent to the TNC is immediately broadcast to all connected pass‑through clients. Incoming: Any data received on the pass‑through port is forwarded to the TNC.
A comma‑delimited --callsigns filter allows you to restrict transfers to specific sender and receiver callsigns (wildcards are supported).
When the --save-files option is enabled, the repeater will reassemble received file transfers—decoding (if base64‑encoded) and decompressing (if compressed) as needed—and save the file locally.
The application also automatically attempts to reconnect to the TNC if the connection is lost or if no data is received for a specified period.
To build the application, ensure you have Go installed. Then compile the program:
go build -o repeater repeater.go
This produces an executable named ax25repeater.
The following table lists all available command‑line options along with their descriptions and default values:
| Flag | Description | Default Value |
|---|---|---|
--tnc-connection-type |
Connection type for the TNC. Use tcp for a TCP connection or serial for a serial connection.
|
tcp |
--tnc-host |
TCP host address of the TNC (used when --tnc-connection-type=tcp).
|
127.0.0.1 |
--tnc-port |
TCP port number for the TNC connection (used when --tnc-connection-type=tcp).
|
9000 |
--tnc-serial-port |
Serial port for the TNC (e.g. /dev/ttyUSB0 or COM3). Used when --tnc-connection-type=serial.
|
empty |
--tnc-baud |
Baud rate for the TNC serial connection. | 115200 |
--passthrough-port |
TCP port for pass‑through clients. This repeater supports two‑way pass‑through: Outgoing: All KISS frames sent to the TNC are broadcast to these clients. Incoming: Any data received on this port is forwarded to the TNC. | 5010 |
--callsigns |
Optional comma‑delimited list of valid sender/receiver callsigns with support for wildcards. When set, only packets whose both sender and receiver match one of the allowed callsigns are processed. Otherwise, all callsigns are accepted. | empty |
--debug |
Enable verbose debug logging for detailed state and packet processing information. | false |
--save-files |
When enabled, the repeater reassembles received file transfers from their data packets. The application decodes (if base64‑encoded) and decompresses (if compressed) the file data, then saves the resulting file locally using a unique filename based on the sender, receiver, and file ID. | false |
--send-delay |
Delay in milliseconds before sending frames to the TNC if a recent frame was received. This minimum turnaround delay can help address timing issues with certain TNCs. | 0 |
--tcp-read-deadline |
TCP read deadline (in seconds) for TNC connections. If no complete KISS frame is received within this period, the connection is closed and a reconnect is triggered. | 600 |
The following command runs the repeater using a TCP connection to the TNC at 127.0.0.1:9000.
Pass‑through clients can connect on port 5010.
go run ax25repeater.go
This command uses a serial connection for the TNC (e.g. /dev/ttyUSB0 at 115200 baud)
and allows two‑way communication on the pass‑through port (5010).
go run ax25repeater.go --tnc-connection-type=serial --tnc-serial-port=/dev/ttyUSB0 --tnc-baud=115200
The following command restricts transfers to the callsigns N0CALL and any SSID matching *-R,
while also enabling debug logging.
go run ax25repeater.go --callsigns=N0CALL,*-R --debug
To enable saving of received files, add the --save-files flag.
When enabled, the repeater reassembles the file transfer by decoding (if base64‑encoded) and decompressing (if compressed)
the data, then saves it locally with a filename that includes the sender, receiver, and file ID.
go run ax25repeater.go --save-files
|). This metadata includes parameters such as timeout seconds, timeout retries, filename, file ID, encoding method (0 for binary, 1 for base64), compression flag, and total packets.
These details are logged and used when reassembling file transfers.
--callsigns flag is not provided, all callsigns are accepted.
Otherwise, only packets with both sender and receiver matching one of the allowed patterns are processed.
--save-files is enabled, the repeater accumulates data packets for each file transfer.
Once all packets are received, the file is reassembled in order.
If the data was base64‑encoded, each packet is decoded.
If compression was used, the reassembled data is decompressed via zlib before being saved.
The file is stored locally with a unique filename based on the sender, receiver, file ID, and original filename.
--tcp-read-deadline option sets an application‑level timeout for TCP TNC connections.
If no complete KISS frame is received within the specified period, the connection is closed, triggering an automatic reconnect after a brief delay.
For additional questions, issue reports, or support, please contact the project maintainer or visit the source repository.