fix: clicking an OpsLog spot on the Flex panadapter now sets the mode too — cluster spots get a mode inferred (comment/band plan) and SendSpot converts it to a real Flex mode (SSB->USB/LSB, FT8->DIGU), so SmartSDR actually switches mode on the click; changelog 0.20.10
This commit is contained in:
@@ -1162,7 +1162,11 @@ func (f *Flex) SendSpot(s SpotInfo) error {
|
||||
}
|
||||
cmd := fmt.Sprintf("spot add rx_freq=%.6f callsign=%s color=%s source=OpsLog lifetime_seconds=%d trigger_action=Tune timestamp=%d",
|
||||
float64(s.FreqHz)/1e6, call, color, life, time.Now().Unix())
|
||||
if m := flexEncode(s.Mode); m != "" {
|
||||
// Convert to a real Flex mode (USB/LSB/CW/DIGU/…): SmartSDR only switches the
|
||||
// slice mode on a spot click when mode= is one of ITS mode names — "SSB" or a
|
||||
// bare cluster label is ignored, so the mode wouldn't change. adifModeToFlex
|
||||
// also resolves SSB→USB/LSB from the spot frequency.
|
||||
if m := flexEncode(adifModeToFlex(s.Mode, s.FreqHz)); m != "" {
|
||||
cmd += " mode=" + m
|
||||
}
|
||||
if c := flexEncode(s.Comment); c != "" {
|
||||
|
||||
Reference in New Issue
Block a user