Repository navigation
Optional AGWPE extension exposing per-frame signal quality - #669
Merged
Merged
Conversation
Direwolf measures a per-frame signal metric — audio level rec(mark/space)
plus the retry/FEC decode level — but only emits it to stdout and the
APRS-only CSV log, never over the AGWPE monitor API. This adds an opt-in,
backwards-compatible way for an AGWPE client to receive it in-band.
A client enables the feature with a new 'q' command; the server replies
with a 'q' frame carrying "ExtSig=1". For clients that opted in, the
per-frame metrics are packed into the four otherwise-zero user_reserved
header bytes of 'U'/'S'/'I' monitor frames:
user_reserved[0] = rec (0..255)
user_reserved[1] = mark (0..255; 0xFF = N/A for non-AFSK)
user_reserved[2] = space (0..255; 0xFF = N/A)
user_reserved[3] = retries (0 = clean copy)
Backwards compatibility is structural: the bytes are written only in the
copy sent to a client that sent 'q', after the header is zeroed, so any
client that does not opt in — every stock AGWPE client — receives
byte-identical frames. A stock Direwolf ignores the unknown 'q' command,
so a client requesting the extension against stock never sees the ACK and
leaves the feature off.
alevel and the retry count are threaded from app_process_rec_packet
through server_send_rec_packet into server_send_monitored. Own
transmitted ('T') frames and synthetic packets (AIS objects, APRStt) pass
a rec = -1 sentinel, which suppresses the reserved-byte write.
Owner
|
Thank you for this useful enhancement. |
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.
Direwolf measures a per-frame signal metric — audio level rec(mark/space) plus the retry/FEC decode level — but only emits it to stdout and the APRS-only CSV log, never over the AGWPE monitor API. This adds an opt-in, backwards-compatible way for an AGWPE client to receive it in-band.
A client enables the feature with a new 'q' command; the server replies with a 'q' frame carrying "ExtSig=1". For clients that opted in, the per-frame metrics are packed into the four otherwise-zero user_reserved header bytes of 'U'/'S'/'I' monitor frames:
Backwards compatibility: the bytes are written only in the copy sent to a client that sent 'q', after the header is zeroed, so any client that does not opt in — every stock AGWPE client — receives byte-identical frames. A stock Direwolf ignores the unknown 'q' command, so a client requesting the extension against stock never sees the ACK and leaves the feature off.
alevel and the retry count are threaded from app_process_rec_packet through server_send_rec_packet into server_send_monitored. Own transmitted ('T') frames and synthetic packets (AIS objects, APRStt) pass a rec = -1 sentinel, which suppresses the reserved-byte write.
This is used in the "BBS2" project at github.com/elafargue/bbs2 where the "heard" plugin is able to display link quality for neighbors.