firmware: rolling-hour duty-cycle guard (0.1% default) with measured justification

This commit is contained in:
Lars Nolden
2026-09-01 11:33:04 +02:00
parent 6633cd6f92
commit cafc9dff26
4 changed files with 105 additions and 3 deletions
+35 -1
View File
@@ -8,7 +8,7 @@ repeater. Known deviations:
| 1 | Repeats the raw telegram bit-exact, including hop-related fields | EN 13757-5 repeaters must manage the hop counter / C-field semantics so telegrams are not repeated endlessly |
| 2 | Fixed development repeat delay 20-200 ms (default 50 ms) | OMS repeaters use randomized delays in the seconds range to avoid collisions |
| 3 | Repeats every CRC-valid C1 telegram (optional dev whitelist) | Real repeaters filter by installation list |
| 4 | No duty-cycle accounting | EU 868.95 MHz band has duty-cycle limits (1% for 868.7-869.2 sub-band per ERC 70-03); a production repeater must budget its TX time |
| 4 | Rolling-hour duty-cycle guard, default 0.1 % (1000 ppm), suppresses repeats over budget and counts them (`tx_suppressed_duty`) | A production repeater needs proper duty-cycle management, or LBT+AFA, plus per-sub-band awareness |
| 5 | Duplicate suppression is a 2.5 s hash ring | Standard requires proper duplicate/loop protection semantics |
| 6 | No AES, no decryption, payload treated as opaque | OMS security profiles apply to end devices; a transparent repeater may pass ciphertext, but production behavior needs review |
| 7 | T1 telegrams are detected (shared 0x543D sync) but dropped | A combined C/T repeater would need 3-of-6 decode/encode |
@@ -16,3 +16,37 @@ repeater. Known deviations:
None of these shortcuts may be carried into the production Solenos/Gebos
gateway without explicit review.
## Duty cycle — measured, and why it matters
868.95 MHz falls in the 868.7-869.2 MHz sub-band, which ERC/REC 70-03
(annex h1.6) limits to 25 mW e.r.p. with **<= 0.1 % duty cycle**, unless the
device implements LBT+AFA.
Measured on this bench:
```
TX airtime per repeat : 10.4-14.6 ms (median 13.4 ms), frame-length dependent
observed repeat rate : ~5-6 repeats/min when repeating every valid telegram
resulting duty cycle : ~0.11-0.13 %
```
That is at or slightly above the 0.1 % ceiling — while repeating only the
CRC-valid C1 telegrams audible at a single indoor location. A production
repeater in a denser environment, or one that also handles T-mode, would
exceed the budget substantially.
Consequences for the production gateway:
- Duty-cycle budgeting is a first-class requirement, not an afterthought.
Repeating "every telegram we hear" is not a viable policy.
- Either implement LBT+AFA (which lifts the duty-cycle restriction in this
sub-band) or filter by installation list and/or rate-limit per meter.
- Frame length matters: airtime scales with it, so long encrypted telegrams
cost roughly 40 % more budget than short ones.
The experimental firmware therefore enforces a rolling-hour airtime budget
(`set duty_budget_ppm N`, default 1000 ppm = 0.1 %, 0 disables) purely so
unattended multi-hour runs cannot drift into non-compliance. This guard is
an experiment-safety measure and is NOT the OMS/EN 13757-5 repeater
behaviour a product would need.