Skip to content

feat: support for multi-mode channels #46

Description

@pskillen

Problem

Some radios (e.g. the Baofeng DM-32) support dual-mode channels — a single channel entity that carries both analog and digital configuration. Other radios (e.g. OpenGD77) require these to be modelled as two separate channels with distinct names and CPS rows.

Today our internal model assumes one mode per channel. Operators who think in terms of "one repeater, FM or DMR" must manually duplicate channel data or maintain parallel entries.

Intended outcome

Let a single logical channel represent a multi-mode entity in our internal data models, and denormalise into the vendor-specific channel rows required at the export boundary.

Modelling

  • Per-channel opt-in flag (e.g. multiMode or similar) — when off, behaviour is unchanged (single mode per channel).
  • When enabled, the channel carries multiple mode configurations (e.g. FM + DMR sharing common identity: name/callsign/location/frequencies where applicable, with mode-specific fields nested or keyed by mode).
  • Exact schema to be finalised during design; should compose cleanly with the richer mode enum from the mode-field refactor issue.

Export (required)

Import (best-effort, NOT a blocker)

  • On import, best-effort merge of related vendor channels back into one logical multi-mode channel — e.g. group by shared name stem + rx/tx frequencies + location, differing only by mode/type.
  • Explicitly not required to ship export-side support.
  • Vendor exports are flat and lossy; mis-grouping is acceptable. If merge fails, channels arrive as separate rows (no regression).

Pattern

This mirrors #36 (multi-talkgroup channels): model intent cleanly internally, denormalise at the vendor boundary, optional re-normalisation on import.

Concept #36 This issue
Logical entity One channel, many talk groups One channel, many modes
Denormalise on export channel × TG pairs channel × mode rows
Import Best-effort collapse by name + freqs + varying TG Best-effort collapse by name + freqs + varying mode

Affected

Notes / dependencies

Out of scope

  • Changing radio firmware behaviour.
  • Guaranteed loss-free import re-normalisation.

Workflow note

Likely multi-commit work: branch from origin/main, atomic conventional commits, PR linking Closes #. Pair with docs/features / progress-tracking skills.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestquality-of-lifefeature to improve the QOL of the person making a codeplug

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions