protobufs icon indicating copy to clipboard operation
protobufs copied to clipboard

Add rx_frequency_error to meshpacket

Open jp-bennett opened this issue 2 months ago • 3 comments

Radiolib includes the lora.getFrequencyError() function to return the offset from expected frequency center. This can be added to meshpacket and used to help debug mesh problems.

jp-bennett avatar Oct 14 '25 14:10 jp-bennett

The latest Buf updates on your PR. Results from workflow pull-request / build (pull_request).

BuildFormatLintBreakingUpdated (UTC)
❌ failed (0)🚫 cancelled🚫 cancelled🚫 cancelledOct 14, 2025, 2:37 PM

github-actions[bot] avatar Oct 14 '25 14:10 github-actions[bot]

I'll reiterate my comments on Discord. I don't think it's worth saving this in the MeshPacket as it will lead to increased RAM usage quite a lot (~5 bytes per packet in the Tx queue, phone queue, etc.). The value is also very hard to interpret. It can be that the transmitter is off, the receiver, or both. And you’ll not get a value when you didn’t receive the packet. Lastly, it may be that the error is small, but it’s drifting too much during the packet.

It might be worth recording a max. deviation or latest deviation in the LocalStats, or just only printing it in the logs.

GUVWAF avatar Oct 14 '25 15:10 GUVWAF

Currently plan is to add this value to the log as a debug message, and if it proves to be extremely useful, come back and possibly add to meshpacket.

jp-bennett avatar Oct 14 '25 17:10 jp-bennett