Skip to content

RNode: add Germany Ruhrgebiet preset and raise custom TX power cap to 27 dBm - #1131

Merged
torlando-tech merged 6 commits into
mainfrom
feature/rnode-ruhrgebiet-preset
Sep 10, 2026
Merged

RNode: add Germany Ruhrgebiet preset and raise custom TX power cap to 27 dBm#1131
torlando-tech merged 6 commits into
mainfrom
feature/rnode-ruhrgebiet-preset

Conversation

@torlando-tech

Copy link
Copy Markdown
Owner

Summary

Two small RNode changes, isolated from unrelated in-flight work.

1. New "Popular Local Preset" for Germany - Ruhrgebiet

  • freq 869462500 Hz (869.4625 MHz), bw 125 kHz, SF 8, CR 5, TX max 27 dBm, LT airtime 10%.
  • The frequency is in EU sub-band P (869.4-869.65 MHz), whose regulatory limit is 27 dBm / 10% duty, so the preset is compliant.
  • RNodeRegionalPreset gains an optional longTermAirtimeLimit, applied to the lt_alock field on selection (short-term st_alock untouched). A "10% LT" chip is shown on the preset card when a preset defines it.

2. Custom config TX power cap 22 -> 27 dBm

  • RNodeConfigValidator.DEFAULT_MAX_TX_POWER 22 -> 27, plus the ReviewConfigStep fallback and the ReticulumConfig doc comment.
  • No backend change needed: the Python backend already permits TX up to 36 dBm and surfaces device capability errors (0x40).

Testing

  • Verified against main: :app:testNoSentryKotlinBackendDebugUnitTest for the touched classes = 258 tests, 0 failures/errors.
  • New/updated tests: exact Ruhrgebiet field set; selectPreset applies TX 27 + LT 10%; preset without an airtime limit preserves the existing ltAlock; validator default max is now 27.

Notes

  • Scoped to the 9 RNode files only; no unrelated changes included.

Popular Local Presets:
- Add a Germany "Ruhrgebiet" preset (freq 869462500, bw 125000, SF8,
  CR5, 27 dBm, 10% long-term airtime). The frequency sits in EU
  sub-band P (869.4-869.65 MHz), whose regulatory limit is 27 dBm /
  10% duty, so the preset is compliant.

Preset airtime support:
- RNodeRegionalPreset gains an optional longTermAirtimeLimit, applied
  to the lt_alock field when a preset is selected; a "10% LT" chip is
  shown on the preset card when set.

Custom config TX cap:
- Raise the no-region/custom default max TX power from 22 to 27 dBm in
  RNodeConfigValidator, the ReviewConfigStep fallback, and the
  ReticulumConfig doc. The Python backend already permits up to 36 dBm
  and surfaces device errors, so no backend change is required.

Tests:
- RNodeRegionalPresetsTest: assert the exact Ruhrgebiet field set.
- RNodeWizardViewModelTest: selectPreset applies tx 27 + lt 10%, and a
  preset without an airtime limit preserves the existing ltAlock.
- RNodeConfigValidatorTest: updated for the new 27 dBm default.
@greptile-apps

greptile-apps Bot commented Sep 10, 2026

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

The PR appears safe to merge, with no outstanding findings after the earlier layout and compilation concerns were resolved.

Summary

  • Adds optional preset-specific long-term airtime and transmit-power fields.
  • Applies preset airtime limits while preserving existing values when an override is absent.
  • Uses a wrapping settings layout and displays only the preset attributes that are defined.
  • Updates validation, documentation, and unit tests for the new preset and power ceiling.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart LR
    A[Select frequency region] --> B[Region-default TX power]
    B --> C[Select local preset]
    C --> D{Preset TX override?}
    D -->|Yes| E[Apply preset TX power]
    D -->|No| F[Keep current TX power]
    C --> G{Preset LT airtime limit?}
    G -->|Yes| H[Apply lt_alock]
    G -->|No| I[Keep current lt_alock]
    E --> J[Review and save]
    F --> J
    H --> J
    I --> J
Loading

Reviews (6) · Last reviewed commit: "Revert "Remove TX power from RNode prese..."

@codecov

codecov Bot commented Sep 10, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

Greptile found the new LT-airtime chip pushes the Ruhrgebiet preset
to five labels in a single non-wrapping Row, which can overflow or clip
on narrow screens / larger fonts. Switch the settings-preview row to
FlowRow (with vertical spacing), matching how chips wrap elsewhere in
this wizard (ModemPresetStep), so the card stays usable on constrained
displays.
Match the module convention used by every other FlowRow consumer
(ModemPresetStep, DiscoveredInterfacesScreen, ...) by importing
ExperimentalLayoutApi and annotating PopularPresetCard with
@OptIn(ExperimentalLayoutApi::class).
Only the Heltec v4 reaches above the 17-22 dBm ceiling that most RNode
radios cap at, so the preset no longer forces 27 dBm. The preset's
txPower field is now optional (null = keep the frequency region's
default) and the wizard only overrides the current value when a preset
actually specifies one. The 27 dBm custom-config cap from the previous
commit stays for manual use.
TX power is hardware-dependent: most RNode radios top out at 17-22 dBm
while the Heltec v4 reaches the higher EU868 sub-band-P ceiling, so a
preset cannot know what its target board supports. The preset model no
longer carries a txPower field, selectPreset never touches the wizard's
TX power (region default or user-set value is preserved), and the
preset card no longer shows a dBm chip.
@torlando-tech
torlando-tech merged commit b6ed144 into main Sep 10, 2026
12 checks passed
@torlando-tech
torlando-tech deleted the feature/rnode-ruhrgebiet-preset branch September 10, 2026 18:39
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