mirror of
https://github.com/pyMC-dev/pyMC_Repeater.git
synced 2026-06-11 08:44:46 +02:00
541b25b47c
Wires the TCPLoRaRadio and USBLoRaRadio drivers that landed in pyMC_core on 2026-05-13 (PR pyMC-dev/pyMC_core#68) into get_radio_for_board() so they can be selected from a repeater config file without any code change in main.py / api_endpoints. Both branches follow the existing pattern: read host/port (TCP) or serial port (USB) plus auth/LBT options from their own config section, share the LoRa parameters from the common `radio` section, fall back to the firmware-default sync word 0x12, and surface ImportError as a clear RuntimeError if the installed pymc_core is too old to ship the drivers. config.yaml.example documents both sections and updates the radio_type header comment with the full supported list. Five new tests in tests/test_radio_config.py monkeypatch the radio classes and verify the section/parameter wiring + missing-required-field errors. No web UI / endpoint changes — the deployment this targets edits the config file directly. A GUI wizard for these radio types can land separately if there's appetite.