[fix](trx-frontend-http): fix APRS HDLC decoder and add debug logging

Fix three bugs in the Bell 202 AFSK demodulator preventing frame
decoding:
- Separate NRZI state from clock recovery (shared lastBit variable
  caused NRZI to always output 1)
- Buffer 1-bits in ones counter instead of pushing to frameBits
  immediately, preventing flag/stuff bits from contaminating frame
  data and corrupting byte alignment
- Detect flags via ones-count on decoded bits instead of shift
  register on raw bits

Also add framed packet log container styling, remove redundant
description text, and add debug counters logging pipeline health
to the browser console.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Stanislaw Grams <stanislawgrams@gmail.com>
This commit is contained in:
2026-02-08 14:29:35 +01:00
parent d44390db00
commit b042d679fa
3 changed files with 70 additions and 30 deletions
@@ -126,7 +126,7 @@
<div class="plugin-item">
<strong>APRS Decoder</strong>
<div style="color:var(--text-muted); font-size:0.85rem; margin-top:0.2rem;">
Decodes APRS packets from RX audio using Bell 202 AFSK (1200 baud). Switch to the APRS tab to start.
Decodes APRS packets from RX audio using Bell 202 AFSK (1200 baud).
</div>
</div>
</div>