Skip to content

Separate FIFO locations for TX & RX on SX1280 - #3620

Merged
pkendall64 merged 3 commits into
ExpressLRS:masterfrom
pkendall64:4.1/seperate-fifo-locations
Apr 23, 2026
Merged

pkendall64 merged 3 commits into
ExpressLRS:masterfrom
pkendall64:4.1/seperate-fifo-locations

Conversation

@pkendall64

@pkendall64 pkendall64 commented Apr 20, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

On SX1280 receivers, the radio driver was using the same internal packet buffer region for both transmit and receive operations. Under rare conditions this could allow a just-transmitted telemetry payload, such as an OTA LinkStats packet, to be read back through the receive path and misinterpreted as RC data. Because LinkStats and RC packets share the same OTA packet type value; when in MAVLink mode, this could appear on the flight controller as a bogus RC_CHANNELS_OVERRIDE frame and would cause a disarm of the craft if using channel-based arming.

Solution

The SX1280 driver now uses separate FIFO base addresses for transmit and receive. This prevents transmitted telemetry data from being re-read through the RX path and removes the buffer aliasing condition that could cause LinkStats payloads to be decoded as RC data.

Belt-and-braces

As an additional safeguard, the RX path also validates the radio status returned by GET_RXBUFFERSTATUS before reading packet data. The driver only accepts a received packet if the chip reports that it is in RX mode and that data is available for reading.

@pkendall64 pkendall64 linked an issue Apr 20, 2026 that may be closed by this pull request
@pkendall64
pkendall64 marked this pull request as draft April 20, 2026 01:11
@pkendall64
pkendall64 marked this pull request as ready for review April 20, 2026 21:57
@d-papworth

Copy link
Copy Markdown

At the request of @pkendall64 after chatting in the ELRS Discord #mavlink-rc channel I tested with stock ELRS v4.0 for about 30 min on the bench with multiple channel low (881us) events, then flashed this PR and tested on the bench for about 20 min with no occurrences of the channel low (881us) events, which suggests that the fix applied resolves the issue.

With stock ELRS v4.0
image

With this PR flashed to RX and TX
image

@pkendall64

Copy link
Copy Markdown
Collaborator Author

Thanks @d-papworth

@CapnBry CapnBry left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I may have come for the FIFO buffer segmentation but I really think the verification but the verification of the chipStatus is an even stronger fix. I believe that also would have solved the old issue where we were getting too many interrupts per period and faux-advancing the nonce

Comment thread src/lib/SX1280Driver/SX1280.cpp Resolved
Comment thread src/lib/SX1280Driver/SX1280_hal.h Resolved

@CapnBry CapnBry left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Incredible work finding this, it is amazing we've never seen this in testing, and thanks @d-papworth for reporting with all the details.

@mha1 mha1 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

6h run yesterday on a SX1280/SX1280 setup woth no obvious issues.

@pkendall64
pkendall64 merged commit 7828f87 into ExpressLRS:master Apr 23, 2026
26 checks passed
@pkendall64
pkendall64 deleted the 4.1/seperate-fifo-locations branch April 23, 2026 00:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SuperP 14CH RX ELRS 2.4G Receiver reset causes bad channel output

4 participants