[feat](trx-rs): display APRS-IS connection status on About page
Thread aprs_is_status through RigState, RigSnapshot, and the protocol layer following the same pattern as pskreporter_status. Show the connection target and callsign when enabled, or "Disabled" otherwise. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
This commit is contained in:
@@ -765,6 +765,7 @@ mod tests {
|
||||
server_latitude: None,
|
||||
server_longitude: None,
|
||||
pskreporter_status: Some("Disabled".to_string()),
|
||||
aprs_is_status: Some("Disabled".to_string()),
|
||||
aprs_decode_enabled: false,
|
||||
hf_aprs_decode_enabled: false,
|
||||
cw_decode_enabled: false,
|
||||
|
||||
@@ -403,6 +403,7 @@ mod tests {
|
||||
server_latitude: None,
|
||||
server_longitude: None,
|
||||
pskreporter_status: Some("Disabled".to_string()),
|
||||
aprs_is_status: Some("Disabled".to_string()),
|
||||
aprs_decode_enabled: false,
|
||||
hf_aprs_decode_enabled: false,
|
||||
cw_decode_enabled: false,
|
||||
|
||||
@@ -3021,6 +3021,9 @@ function render(update) {
|
||||
if (update.pskreporter_status) {
|
||||
document.getElementById("about-pskreporter").textContent = update.pskreporter_status;
|
||||
}
|
||||
if (update.aprs_is_status) {
|
||||
document.getElementById("about-aprs-is").textContent = update.aprs_is_status;
|
||||
}
|
||||
if (update.info) {
|
||||
const parts = [update.info.manufacturer, update.info.model, update.info.revision].filter(Boolean).join(" ");
|
||||
if (parts) document.getElementById("about-rig-info").textContent = parts;
|
||||
|
||||
@@ -981,6 +981,7 @@
|
||||
<tr><td>Rigctl endpoint</td><td id="about-rigctl-endpoint">--</td></tr>
|
||||
<tr><td>Rigctl clients</td><td id="about-rigctl-clients">--</td></tr>
|
||||
<tr><td>PSK Reporter</td><td id="about-pskreporter">--</td></tr>
|
||||
<tr><td>APRS-IS</td><td id="about-aprs-is">--</td></tr>
|
||||
<tr><td>Client version</td><td>{pkg} v{ver}</td></tr>
|
||||
<tr><td>Connected clients</td><td id="about-clients">--</td></tr>
|
||||
</table>
|
||||
|
||||
@@ -2104,6 +2104,7 @@ async fn wait_for_view(mut rx: watch::Receiver<RigState>) -> Result<RigSnapshot,
|
||||
server_latitude: state.server_latitude,
|
||||
server_longitude: state.server_longitude,
|
||||
pskreporter_status: state.pskreporter_status,
|
||||
aprs_is_status: state.aprs_is_status,
|
||||
aprs_decode_enabled: state.aprs_decode_enabled,
|
||||
hf_aprs_decode_enabled: state.hf_aprs_decode_enabled,
|
||||
cw_decode_enabled: state.cw_decode_enabled,
|
||||
|
||||
@@ -655,6 +655,7 @@ mod tests {
|
||||
server_latitude: None,
|
||||
server_longitude: None,
|
||||
pskreporter_status: None,
|
||||
aprs_is_status: None,
|
||||
aprs_decode_enabled: false,
|
||||
hf_aprs_decode_enabled: false,
|
||||
cw_decode_enabled: false,
|
||||
|
||||
Reference in New Issue
Block a user