Spot trigger — include pan= so external CAT clients can route the spot (#2366)#2369
Merged
Spot trigger — include pan= so external CAT clients can route the spot (#2366)#2369
Conversation
#2366) Without the pan handle the radio broadcasts spot N triggered pan=0x00000000, which leaves multi-pan-aware clients (e.g. SDC Contest) unable to route the spotted callsign to the right QSO entry window. applet->panId() is already in scope at the click site and is "0x..."-formatted. Co-Authored-By: Claude Opus 4.7 <[email protected]>
Contributor
Author
There was a problem hiding this comment.
Looks good — verified the claims against the tree:
PanadapterApplet::panId()(PanadapterApplet.h:27) returns the"0x..."handle as aQString, which is whatarg()will substitute directly. No format conversion needed.- The lambda at
MainWindow.cpp:9026already capturesappletfromwirePanadapter's argument, so no closure changes were required. - The inbound side at
RadioModel.cpp:3294-3308already parsespan=offspot N triggered ...broadcasts (regexpan=(0x[0-9A-Fa-f]+)), so this just symmetrically populates what we already read. - Confirmed via grep that this is the only outbound
spot triggeremitter, and the Memory + passive-local branches above the changed line short-circuit before the radio command, as the PR description states.
Scoped to a single file, single line, no behavioral side effects in the no-pan-handle case (the radio fills in 0x00000000 for empty pan=, same as today's omission). Thanks for the careful writeup linking the FlexLib Spot.Trigger(Panadapter) overload and the SDC Contest report — made this easy to verify.
Owner
|
Claude here on Jeremy's behalf — merged via admin squash. Stale-code audit clean, single-emitter confirmed, FlexLib reference grounding the fix. SDC Contest routing should now work for Yuri (UT4LW) and any other multi-pan-aware CAT client. 73, Jeremy KK7GWY & Claude (AI dev partner) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #2366 — clicking a panadapter spot in AetherSDR was sending
spot trigger Nto the radio without thepan=parameter, so the radio broadcastspot N triggered pan=0x00000000. Multi-pan-aware CAT clients such as SDC Contest (UT4LW) rely on that pan handle to route the spotted callsign to the correct QSO entry window — without it, the callsign never appears.Change
One-line fix in
src/gui/MainWindow.cpp—wirePanadapter()already capturesappletin thespotTriggeredlambda's closure, andapplet->panId()returns the pan stream ID as a"0x..."-formatted string (seePanadapterApplet.h:27). We just include it in the outbound command:m_radioModel.sendCommand( QString("spot trigger %1 pan=%2").arg(spotIndex).arg(applet->panId()));This matches FlexLib's
Spot.Trigger(Panadapter pan)overload (FlexLib/Spot.cs:352-377), which is what SmartSDR uses on click. Our inbound parser atRadioModel.cpp:3223-3242already reads thepan=field off the broadcast — only the outbound command was missing it.Scope notes
spot triggercommand emitter in the codebase.0x00000000filled in by the radio, and any sane downstream falls back to the active pan; adding the explicit handle only ever adds information. Multi-pan setups (the case Yuri reported) gain correct routing.Test plan
pan=0x40000000) instead of0x00000000.🤖 Generated with Claude Code