Skip to content

chore: build on meshcore-go v1.9.0 and let the radio supply airtime - #39

Merged
tuzzmaniandevil merged 1 commit into
devfrom
chore/meshcore-go-v1.9.0
Oct 13, 2026
Merged

tuzzmaniandevil merged 1 commit into
devfrom
chore/meshcore-go-v1.9.0

Conversation

@tuzzmaniandevil

Copy link
Copy Markdown
Contributor

What changed

  • All four meshcore-go modules move from v1.7.0 to v1.9.0.
  • main.go drops node.WithMuxAirtimeEstimator and hardware.WithTxAirtimeEstimator. Since meshcore-go v1.8.0 each modem reports its own airtime (EstAirtime), and the mux and the bot's nodes read it themselves.
  • WithMuxAirtimeFactor stays. It was inside if ms.radioConfig != nil, but radioConfig is always set before the mux is built, so the check was dead and is gone.
  • The bot's MQTT airtime figures (duration, rx_air_secs, tx_air_secs) use the library's estimator, which now matches firmware to the millisecond (up to 1 ms per packet lower than before).

The v1.9.0 upgrade note about SendTextMessage and CLI commands doesn't apply: the bot doesn't call it.

Testing

  • go vet and go test -race ./... pass against the published v1.9.0, with no go.work.
  • On air, with a release-style binary built against the meshcore-go code that became v1.9.0 (same diff size against v1.8.0 for every code file). The OwlShack session sent #westest triggers from the other radio. 917.375 / 62.5 / SF7 / CR5.
    • KISS (RAK4631), two rounds: 6 replies sent, all 6 heard relayed back.
    • openHop TCP: 3 replies sent, all 3 heard relayed back.
    • An instrumented scratchpad copy of the bot logged mux.TxStats().AirtimeMs: 0 before any send, then 915 ms after 3 sends on each radio. That is exactly 3 x 305 ms, the estimate for a 69-byte reply, so the mux takes its airtime from the modem with no override.
    • No warnings or errors in any run, and no "radio gives no airtime estimate" warning across 75 received packets. The node asks for an estimate on every received packet, so a missing estimate would have logged it.

Not tested

  • SPI (SX1262 on the Pi).
  • The KISS TX_DONE wait sized from the modem's estimate. There were no TX failures or timeouts, but at SF7 the old default wait was already long enough, so this doesn't show the sizing.
  • A duty-cycle limit actually holding a send back. The budget is a 1-hour bucket, so a few replies never drain it.
  • The final v1.9.0 build on air. The code matched by diff size, not file by file.

The modems now report their own airtime estimate, so drop the
WithMuxAirtimeEstimator and WithTxAirtimeEstimator overrides. Keep
WithMuxAirtimeFactor, which no longer needs the radioConfig guard.
@tuzzmaniandevil
tuzzmaniandevil merged commit f8f0d41 into dev Oct 13, 2026
1 check passed
@tuzzmaniandevil
tuzzmaniandevil deleted the chore/meshcore-go-v1.9.0 branch October 13, 2026 06:11
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