mirror of
https://git.vladimir.cc/vladimir/ewsdr.git
synced 2026-08-25 20:37:33 +00:00
ebca3b413710ada926b6fdbe13592559e2602b73
Opus decodes 960 samples per frame; the TX DSP thread consumes 512-sample blocks. 960 mod 512 = 448, so the ring always kept a sub-threshold tail, causing TTXDSPThread to skip ticks and starve the DUC hardware every ~20 ms. FlushMicToCallback accumulates samples in FMicStageBuf and calls FOnWebMic only when a full 512-sample block is ready. The remainder stays in the buffer until the next Opus frame arrives. This ensures FTXMicRing always receives data in multiples of 512, eliminating the 0 < Avail < 512 dead-zone entirely. FMicStageLen is reset together with FMicPreRollPos on new TX session to prevent stale samples from a previous session mixing in. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…
Languages
Pascal
96.4%
Python
2.9%
Shell
0.6%