Commit Graph

1264 Commits

Author SHA1 Message Date
sjg a8f7e9c8de Revert "[fix](trx-frontend-http): normalize ft8 locator spacing"
This reverts commit 5aa9502e37.
2026-02-09 22:15:00 +01:00
sjg 5aa9502e37 [fix](trx-frontend-http): normalize ft8 locator spacing
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 22:14:22 +01:00
sjg dc376c9afb [fix](trx-frontend-http): detect ft8 grids by scan
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 22:11:37 +01:00
sjg 0073f11c15 [fix](trx-frontend-http): robust ft8 grid highlighting
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 22:09:49 +01:00
sjg 2b6df0e738 [fix](trx-frontend-http): highlight ft8 grid tokens
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 22:06:39 +01:00
sjg 44a4c0df24 [fix](trx-frontend-http): parse ft8 locators reliably
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 22:04:12 +01:00
sjg bfc5e531cc [feat](trx-frontend-http): add ft8 locators and map filters
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:50:23 +01:00
sjg dbb58fa2b7 [feat](trx-frontend-http): add ft8 headers and rf freq
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:44:50 +01:00
sjg 0e856073be [docs](trx-frontend-http): add ft8 to overview
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:43:37 +01:00
sjg 9f2306aa71 [fix](trx-ft8): correct result buffer size
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:41:53 +01:00
sjg 995ddd7306 [fix](trx-ft8): align decode result layout
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:41:08 +01:00
sjg 4d32f017a8 [chore](trx-server): log ft8 toggle and offsets
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:38:18 +01:00
sjg 55693bb6e8 [fix](trx-server): align ft8 decode to time slots
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:35:51 +01:00
sjg a4a3f1464e [fix](trx-ft8): enable stpcpy on linux
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:31:39 +01:00
sjg 5f3ea48ef7 [chore](trx-rs): address clippy warnings
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:26:53 +01:00
sjg cf11c16096 [fix](trx-ft8): make decoder Send
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:25:19 +01:00
sjg c4ca178097 [fix](trx-ft8): make raw decode result copyable
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:23:52 +01:00
sjg 56041874da [fix](trx-ft8): update callsign hash constants
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:22:25 +01:00
sjg 1199ab85e9 [feat](trx-rs): add ft8 decoder
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 21:19:56 +01:00
sjg 7bd1a70607 [fix](trx-frontend-http): align cw controls
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 20:53:07 +01:00
sjg a22a648b5d [fix](trx-frontend-http-json): map cw control commands
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 20:51:55 +01:00
sjg 715e6eb9aa [fix](trx-core): handle cw control commands
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 20:51:14 +01:00
sjg 0daf9e27ae [feat](trx-rs): add cw auto/manual controls
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 20:50:31 +01:00
sjg dfc0f220e8 [feat](trx-frontend-http): show cw auto mode
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 19:58:10 +01:00
sjg f610bf7db3 [fix](trx-frontend-http): update decode status on mode change
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 19:54:32 +01:00
sjg b9c58844f0 [fix](trx-server): gate cw decode strictly by mode
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 19:50:08 +01:00
sjg 3dbf590472 [fix](trx-server): gate aprs decode strictly by mode
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 19:48:55 +01:00
sjg af9b44f4d4 [feat](trx-server): auto-decode cw regardless of mode
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 19:43:43 +01:00
sjg b3293f1de3 [feat](trx-rs): server-side decode and aprs byte rendering
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 19:38:25 +01:00
sjg 7b4bcb6f04 [feat](trx-frontend-http): auto-enable aprs and cw decode
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 19:36:12 +01:00
sjg 1500a26761 [feat](trx-server): retain aprs history for new clients
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 19:26:18 +01:00
sjg 8811aa59ee [fix](trx-core): avoid APRS JSON type collision
Co-authored-by: Codex <codex@openai.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-09 19:21:07 +01:00
sjg 88ccc7ab81 [feat](trx-frontend-http): add decoder toggle/clear UI and endpoints
Add POST endpoints for toggle_aprs_decode, toggle_cw_decode,
clear_aprs_decode, and clear_cw_decode. Add toggle buttons in APRS
and CW tabs. Render decoder enabled state from SSE updates. Clear
button now also resets server-side decoder state.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 23:09:51 +01:00
sjg 4a3273653a [feat](trx-frontend-http-json): map decoder commands
Add SetAprsDecodeEnabled, SetCwDecodeEnabled, ResetAprsDecoder, and
ResetCwDecoder to the JSON TCP frontend command mapping.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 23:09:43 +01:00
sjg 25eec2a7a8 [feat](trx-client): map decoder commands in remote client
Initialize decoder state fields and map new RigCommand/ClientCommand
variants through the remote client TCP bridge.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 23:09:40 +01:00
sjg 548aa540ab [feat](trx-server): handle decoder toggle and reset commands
Process decoder commands as early returns in rig_task (no CAT needed).
Check aprs_decode_enabled/cw_decode_enabled flags in decoder tasks
alongside mode. Track reset_seq to trigger decoder.reset() on clear.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 23:09:37 +01:00
sjg b257f69389 [feat](trx-core): add decoder toggle and reset commands
Add aprs_decode_enabled, cw_decode_enabled, aprs_decode_reset_seq, and
cw_decode_reset_seq fields to RigState and RigSnapshot. Add corresponding
RigCommand and ClientCommand variants for toggling and resetting decoders.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 23:09:32 +01:00
sjg 2feecbfe4f [fix](trx-frontend-http): fix decode SSE status detection
Replace HEAD probe with EventSource readyState check to properly
detect 404 vs connection drop. HEAD requests to SSE endpoints may
not behave reliably across all setups.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:57:19 +01:00
sjg dba2f0a9fb [feat](trx-client): add diagnostic logging for decode pipeline
Log whether audio/decode is enabled at startup and warn when
/decode is requested but the decode channel was not set. Helps
diagnose broken decode pipelines.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:54:12 +01:00
sjg b98475037c [fix](trx-server): use raw bytes for APRS position parsing
The APRS info field is raw AX.25 bytes, not valid UTF-8.
from_utf8_lossy inserts multi-byte replacement characters, causing
panics when the position parser sliced by byte index. Switch
parse_aprs_position, parse_aprs_compressed, parse_aprs_lat, and
parse_aprs_lon to operate on &[u8] instead of &str.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:48:48 +01:00
sjg 10c4b735cf [fix](trx-frontend-http): show decode SSE connection status
The decode EventSource silently retried on 404 leaving the status
stuck on "Waiting for server decode". Probe /decode first to
distinguish 404 (audio disabled) from real SSE errors and update
the APRS/CW status text accordingly.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:44:21 +01:00
sjg 04706151b1 [fix](trx-server): start audio capture when decoder tasks are subscribed
The capture thread only checked Opus broadcast subscribers to decide
whether to start cpal input. PCM tap subscribers (APRS/CW decoders)
were not considered, so decoding never started without a browser
audio client. Include pcm_tx receiver count in the has_receivers
check.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:37:53 +01:00
sjg 3dd02d4208 [refactor](trx-frontend-http): remove browser-side APRS/CW decoding
Server-side decoding makes client-side decoders redundant. Remove
~1000 lines of browser-side Bell 202 AFSK, AX.25/APRS parsing, and
Goertzel CW decoding. The frontend now relies solely on the /decode
SSE endpoint for decoded data.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:34:09 +01:00
sjg 8608ec76ad [feat](trx-frontend-http): add Clear button to APRS decode panel
Clears the packet list, map markers are unaffected.  Also wipes
the persisted packet history from localStorage.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:31:01 +01:00
sjg 998f454a3e [feat](trx-frontend-http): consume server-side APRS/CW decode via SSE
Add /decode SSE endpoint streaming decoded messages from the server.
Add decode channel OnceLock with set/subscribe pattern.

In the browser, connect to /decode EventSource and dispatch to
onServerAprs/onServerCw handlers.  APRS and CW plugins now receive
server-decoded data automatically while keeping browser-side decoding
as a fallback.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:28:56 +01:00
sjg 50e1c44722 [feat](trx-client): relay server-side decoded messages to frontends
Handle APRS/CW decode message types (0x03/0x04) in audio_client,
deserialize and forward via broadcast channel.  Create decode channel
and pass to audio client and HTTP frontend.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:28:48 +01:00
sjg f7f0e46021 [feat](trx-server): add server-side APRS and CW decoders
Port Bell 202 AFSK demodulator (correlation detector, PLL clock
recovery, NRZI+HDLC, AX.25/APRS parser) and Goertzel CW decoder
(auto tone scan, auto WPM via k-means, Morse lookup) from browser JS
to Rust.

Add PCM tap to audio capture thread, spawn APRS/CW decoder tasks
gated by rig mode (PKT for APRS, CW/CWR for CW).  Forward decoded
messages over the audio TCP wire using new message types 0x03/0x04.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:28:43 +01:00
sjg 042aab7199 [feat](trx-core): add decode types and wire protocol for APRS/CW
Add shared DecodedMessage enum (tagged serde), AprsPacket and CwEvent
types for server-side decoding.  Add AUDIO_MSG_APRS_DECODE (0x03) and
AUDIO_MSG_CW_DECODE (0x04) wire protocol constants.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:28:34 +01:00
sjg 90d57a290e [feat](trx-frontend-http): persist settings and APRS state across refresh
Add localStorage persistence (trx_ prefix) for UI settings:
- Jog step, RX/TX volume (app.js)
- CW WPM, tone, threshold, auto-detect flags (cw.js)
- APRS decoded packets and running state (aprs.js)

APRS decoder auto-restarts on page refresh if it was active,
and all decoded packets plus map markers are restored from storage.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 22:05:44 +01:00
sjg 3489a74855 [feat](trx-frontend-http): display non-ASCII bytes as yellow hex in APRS info
Render non-ASCII characters in decoded APRS info text as yellow
[0xNN] hex tags. Printable ASCII is HTML-escaped to prevent XSS.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
2026-02-08 21:52:44 +01:00