Skip to content

feat(syntonia): UV-5R EEPROM memory map + channel codec#17

Merged
forkwright merged 1 commit intomainfrom
p1-03/eeprom-codec
Mar 16, 2026
Merged

feat(syntonia): UV-5R EEPROM memory map + channel codec#17
forkwright merged 1 commit intomainfrom
p1-03/eeprom-codec

Conversation

@forkwright
Copy link
Owner

Summary

  • BCD frequency codec (lbcd4 encode/decode) with 10 Hz step resolution
  • Tone codec mapping ul16 values to CTCSS/DCS/None with full 104-code DCS table
  • Channel encode/decode with full bit field handling (power, bandwidth, scan, BCL)
  • Memory map constants for all UV-5R EEPROM regions
  • MemoryImage type with bounds-checked slice/write access
  • Plan-level decode_all_channels / encode_all_channels
  • Round-trip tested: decode → encode produces identical bytes
  • 42 baofeng-specific tests covering all codecs

Test plan

  • cargo build && cargo test --workspace
  • cargo clippy --workspace --all-targets -- -D warnings
  • cargo fmt --all -- --check
  • BCD round-trip on known frequencies (146.520, 446.000, 462.5625 MHz)
  • Tone round-trip for all 50 CTCSS + 104 DCS codes (both polarities)
  • Channel decode/encode round-trip with fixture image
  • Byte-level round-trip: decode → encode produces identical bytes

🤖 Generated with Claude Code

@github-actions
Copy link
Contributor

⚠️ Large PR detected — 18 files, 2426 lines changed.

Consider splitting into smaller PRs for easier review. Not a blocker, just a signal.

- BCD frequency codec (lbcd4 encode/decode) with 10 Hz step resolution
- Tone codec mapping ul16 values to CTCSS/DCS/None with full DCS table
- Channel encode/decode with bit field handling (power, bandwidth, scan, BCL)
- Memory map constants for all UV-5R EEPROM regions
- MemoryImage type with bounds-checked read/write access
- Plan-level decode_all_channels / encode_all_channels
- Round-trip tested: decode → encode produces identical bytes
- 42 baofeng-specific tests covering all codecs

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@forkwright forkwright merged commit 1a3deea into main Mar 16, 2026
11 of 13 checks passed
@forkwright forkwright deleted the p1-03/eeprom-codec branch March 16, 2026 14:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant