Browse Source
chirpmodem_tx_cw_id smoothed the keying envelope with a direct convolution (5 ms raised cosine, kr = 0.005 fs taps, for every sample): 6 s for 5.1 s of CW at 600 kS/s, 16 s at 1 MS/s, slower than real time, which stalled the SDRangel modulator. The envelope is 0/1 and its runs are at least a dot long, so each output sample is a sum over at most a few runs of differences of the window's cumulative sum: O(n). Output is bit-identical (float32) to before at 125 k, 250 k, 600 k and 1 MS/s, 13 and 20 WPM; 600 kS/s now takes 0.08 s. The stream detector's metric divided a window's peak bin by its mean power. On exact zeros (silence in transmit files, SDRangel FileOutput and loopback paths) that is 0/0 = NaN, and NaN passed "met < 4.0" as not below the threshold: 583 false "preamble found, header fail" per 5 s of zeros. An all-zero window now has ratio 1, and the threshold test is written so that NaN fails. Decoded frames, SNRs and offsets are identical on all captures (ota.cu8 49, live_rx 42, ota_tx, ota_cw, soak_tx, sweep_tx, live_tx, modtx); only the spurious failures on digital silence are gone (ota_tx 181 -> 0). make test and tools/check_c.py pass. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>master
2 changed files with 44 additions and 13 deletions
Loading…
Reference in new issue