From 7966b01900467d0255139f306b908c3083afa274 Mon Sep 17 00:00:00 2001 From: rouggy Date: Sun, 30 Aug 2026 02:20:40 +0200 Subject: [PATCH] fix(icom): the console PTT carries the microphone on a network station MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Keying alone is right on USB, where the operator talks into the radio's own mic; over the LAN it transmitted silence. The console button now goes through one binding that picks the road: network To-radio → the same key-and-stream path as the Talk button, USB → key and nothing more. --- app.go | 20 ++++++++++++++++++++ changelog.json | 6 ++++-- frontend/src/components/IcomPanel.tsx | 6 ++++-- frontend/wailsjs/go/main/App.d.ts | 2 ++ frontend/wailsjs/go/main/App.js | 4 ++++ 5 files changed, 34 insertions(+), 4 deletions(-) diff --git a/app.go b/app.go index 64e8a63..b63cb91 100644 --- a/app.go +++ b/app.go @@ -21156,3 +21156,23 @@ func (a *App) CheckHamlogKey(key string) (string, error) { func (a *App) GetAudioMonitorPref() bool { return a.settingOr(keyAudioMonitorOn, "1") == "1" } + +// IcomConsolePTT is the console's PTT button. On a USB station it keys the +// rig and nothing more — the operator talks into the radio's own microphone. +// When the transmit audio goes over the NETWORK, keying alone transmits +// silence: the PC microphone must be routed with it, exactly as the Talk +// button does. One button, the right road picked here. +func (a *App) IcomConsolePTT(on bool) error { + cfg, _ := a.GetAudioSettings() + if cfg.ToRadio == audio.NetworkDeviceID { + if on { + return a.AudioStartTX() + } + a.AudioStopTX() + return nil + } + if a.cat == nil { + return fmt.Errorf("cat not initialized") + } + return a.cat.SetPTT(on) +} diff --git a/changelog.json b/changelog.json index 3442fdb..76a8ea3 100644 --- a/changelog.json +++ b/changelog.json @@ -29,7 +29,8 @@ "Icom console: the SUB display shows the sub receiver’s frequency at all times (it was blank until split), and engaging split copies the mode to the TX VFO so it matches the main.", "Icom network audio: the stream now opens regardless of the speaker choice — speakers-off (or a failed output device) was silently disabling the whole stream: no audio session, no recordings, no voice keyer, despite the RX-audio option being ticked.", "Icom network: a radio in standby keeps its session and the console’s ON button — the quiet-CI-V recovery was tearing the session down every 15 s, so a radio that was off when OpsLog started could never be powered on.", - "Icom console: PTT and Split move up under the dial — one PTT button, and Split as OFF/+1k/+5k/+10k, DXpedition style. Engaging split also aligns the TX VFO’s mode with the main." + "Icom console: PTT and Split move up under the dial — one PTT button, and Split as OFF/+1k/+5k/+10k, DXpedition style. Engaging split also aligns the TX VFO’s mode with the main.", + "Icom console: the PTT button carries your microphone on a network station — it used to only key the rig, which transmitted silence over the LAN." ], "fr": [ "Console Elecraft : le S-mètre est calibré sur un vrai K3 — S9 et les +dB correspondent désormais à l’affichage de la radio (il lisait environ deux points S trop bas).", @@ -58,7 +59,8 @@ "Console Icom : l’affichage SUB montre la fréquence du sub receiver en permanence (il restait vide hors split), et activer le split copie le mode sur le VFO TX pour qu’il suive le main.", "Audio réseau Icom : le flux s’ouvre désormais indépendamment du choix d’écoute — enceintes coupées (ou périphérique de sortie en échec) désactivait silencieusement tout le flux : pas de session audio, ni enregistrements, ni voice keyer, malgré la case RX audio cochée.", "Réseau Icom : une radio en veille garde sa session et le bouton ON de la console — la récupération du CI-V muet détruisait la session toutes les 15 s, donc une radio éteinte au lancement d’OpsLog ne pouvait jamais être allumée.", - "Console Icom : le PTT et le Split remontent sous le cadran — un bouton PTT, et le Split en OFF/+1k/+5k/+10k, façon DXpedition. Activer le split aligne aussi le mode du VFO TX sur le main." + "Console Icom : le PTT et le Split remontent sous le cadran — un bouton PTT, et le Split en OFF/+1k/+5k/+10k, façon DXpedition. Activer le split aligne aussi le mode du VFO TX sur le main.", + "Console Icom : le bouton PTT emporte votre micro sur une station réseau — il ne faisait que keyer la radio, ce qui émettait du silence par le LAN." ] }, { diff --git a/frontend/src/components/IcomPanel.tsx b/frontend/src/components/IcomPanel.tsx index c7dd0c4..066c3f3 100644 --- a/frontend/src/components/IcomPanel.tsx +++ b/frontend/src/components/IcomPanel.tsx @@ -5,7 +5,7 @@ import { IcomSetAFGain, IcomSetRFGain, IcomSetNB, IcomSetNBLevel, IcomSetNR, IcomSetNRLevel, IcomSetANF, IcomSetAPF, IcomSetAGC, IcomSetPreamp, IcomSetAtt, IcomSetFilter, AudioMonitorActive, AudioStartMonitor, AudioStopMonitor, - IcomSetRFPower, IcomSetMicGain, IcomSetSplit, IcomSetSplitOffset, IcomTune, IcomSetPTT, + IcomSetRFPower, IcomSetMicGain, IcomSetSplit, IcomSetSplitOffset, IcomTune, IcomConsolePTT, IcomSetScope, IcomScopeData, IcomSetScopeMode, IcomSetScopeEdges, GetCATState, SetCATFrequency, SetCATMode, IcomSetRIT, IcomSetRITOn, IcomSetXITOn, IcomSetAntenna, IcomSetPBTInner, IcomSetPBTOuter, IcomSetManualNotch, IcomSetNotchPos, @@ -649,7 +649,9 @@ export function IcomPanel({ onReportRST, isNetwork = false }: { onReportRST?: (r const toggleMox = () => { const next = !txRef.current; txRef.current = next; - set({ transmitting: next }, () => IcomSetPTT(next)); + // Through the console binding: on a network station the PC microphone + // rides with the PTT (silence otherwise); on USB it keys and nothing more. + set({ transmitting: next }, () => IcomConsolePTT(next)); }; const tune = async () => { diff --git a/frontend/wailsjs/go/main/App.d.ts b/frontend/wailsjs/go/main/App.d.ts index b4fe1d2..033be14 100644 --- a/frontend/wailsjs/go/main/App.d.ts +++ b/frontend/wailsjs/go/main/App.d.ts @@ -630,6 +630,8 @@ export function HaltDecodeTx(arg1:string,arg2:boolean):Promise; export function HasBuiltinReferences(arg1:string):Promise; +export function IcomConsolePTT(arg1:boolean):Promise; + export function IcomRefresh():Promise; export function IcomScopeData():Promise; diff --git a/frontend/wailsjs/go/main/App.js b/frontend/wailsjs/go/main/App.js index c345049..59553af 100644 --- a/frontend/wailsjs/go/main/App.js +++ b/frontend/wailsjs/go/main/App.js @@ -1198,6 +1198,10 @@ export function HasBuiltinReferences(arg1) { return window['go']['main']['App']['HasBuiltinReferences'](arg1); } +export function IcomConsolePTT(arg1) { + return window['go']['main']['App']['IcomConsolePTT'](arg1); +} + export function IcomRefresh() { return window['go']['main']['App']['IcomRefresh'](); }