feat(chirp): Down Chirp — the exact time-mirror of the Up Chirp (ticket 40) #36
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
ykp/gensig!36
Loading…
Reference in a new issue
No description provided.
Delete branch "down-chirp"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Backlog ticket 40 (chirp-directions round, second ticket). Adds the Down Chirp waveform on the SAME two-phase core as the Up Chirp, differing only by the sweep direction.
Operator-confirmed semantics
ChirpDuration/ChirpIsCsteBT/ChirpMode), same guard / blend / COLA behavior — only the direction differs.|down[n]| == |up[N−1−n]|(max diff 4.4e-16).Implementation (code-reuse architecture)
chirp.py:SWEEP_UP(+1) /SWEEP_DOWN(−1) direction constants (validated);_preparelays the band segments in the direction's order;_assemble_basewalks the direction-ordered sequence (per-band start edgefmax/fmin, negative rate); phase continuity (Q2) stays generic in(a, k)— verified at the blend midpoint with negative rates;generate_chirpand the newgenerate_down_chirpboth delegate to the shared_generate_sweepcore.model.py:WAVEFORM_DOWN_CHIRP(7 options) +CHIRP_WAVEFORM_TYPESfamily tuple.generate.py), validation (L7/L8/L16 via the family tuple), UI policy (chirp controls + hints, neutral labels), GUI Down-Chirp generate test.spec.md: §5.2.1b Down Chirp, §3.3 row, 7 options, §5.0 phase-1 table, L8 wording.Gate
pytest: 1189 passed / 63 skipped (headless tier), coverage 95.32 %ruff+mypy: cleantests/test_down_chirp.py(16 tests): mirror symmetry, contiguous descending ramp (analytic-line probes), seam flatness, Q2a 0.75 level dip, BT mode, band-isolated reversed concatenation, determinism, memory preflight, dispatch, invalid direction.Adds the "Down Chirp" waveform on the SAME two-phase core as the Up Chirp, differing only by the sweep direction (operator-confirmed: same parameter set, same guard/blend/COLA behavior; multiband = ONE continuous descending ramp over the union span): - chirp.py: direction parameterization (SWEEP_UP +1 / SWEEP_DOWN -1, validated); _prepare lays the band segments in the direction's order (up = table order sorted by Fmin; down = REVERSED order, highest band first) so the seams stay frequency-contiguous — the phase-1 COLA blend remains flat and the mirror is EXACT (measured |down[n]| == |up[N-1-n]|, max diff 4.4e-16); per-band sweeps descend fmax->fmin with negative rate; phase continuity (Q2) generic in (a, k), verified at the midpoint with negative rates; new public generate_down_chirp (generate_chirp delegates to the shared _generate_sweep core) - model.py: WAVEFORM_DOWN_CHIRP (2nd slot of WAVEFORM_TYPES, 7 options) + CHIRP_WAVEFORM_TYPES (the shared chirp family tuple) - generate.py: dispatch branch (same post chain + write); Multi IQ / Other IQ still raise NotImplementedError - validation.py: L7/L8/L16 chirp branches cover the whole family via CHIRP_WAVEFORM_TYPES - ui/policy.py + main_window.py: chirp controls (BT checkbox, constant BT, chirp-duration visibility), duration hints and the chirp-periods note cover the whole family; labels stay neutral - tests: new tests/test_down_chirp.py (16 tests: mirror symmetry, contiguous descending ramp, seam flatness to 1e-9, Q2a level dip 0.75, BT mode, band-isolated reversed concatenation, determinism, memory preflight, dispatch, invalid direction); premise tests updated (7 options, __all__ surface); GUI Down Chirp generate test added - spec.md: section 5.2.1b Down Chirp, section 3.3 row, 7 options, section 5.0 phase-1 table, L8 wording ('all chirp types') Gate: pytest 1189 passed / 63 skipped (headless tier), coverage 95.32%; ruff + mypy clean.