Slow the spinel link down so it survives traffic bursts

otbr-agent ran for hours, then died on a burst of Matter traffic:

  [W] P-RadioSpinel-: radio tx timeout
  [C] P-RadioSpinel-: Failed to communicate with RCP
  otbr-agent exited with code 6

The RCP itself was fine -- its frame timestamps showed 18 hours of
uninterrupted uptime across the crash, so nothing on the device reset.
The host simply lost bytes and desynchronised.

Nordic's nrf54l15dk overlay runs uart20 at 1 Mbaud, and this board's
overlay copied that, but the DK pairs it with hw-flow-control. The XIAO
cannot: uart20's pinctrl defines only TX and RX, and the CMSIS-DAP
bridge carries no RTS/CTS. Without back-pressure a single late RX
interrupt drops a byte, and a dropped byte corrupts the HDLC frame
around it.

460800 keeps roughly 4x headroom over peak 802.15.4 throughput while
widening the per-byte service window from 10 us to 21.7 us. The receive
queue goes to 8192 bytes for the same reason -- with no flow control,
whatever does not fit is lost rather than deferred.

The RadioURL on the border router host must set the matching
uart-baudrate=460800.
This commit is contained in:
2026-08-22 14:20:57 +02:00
parent 0ce983b5ed
commit a0f6e875be
2 changed files with 29 additions and 2 deletions

View File

@@ -42,3 +42,11 @@ CONFIG_OPENTHREAD_DEFAULT_TX_POWER=8
CONFIG_GPIO=y
CONFIG_REGULATOR=y
CONFIG_REGULATOR_FIXED=y
# Give the spinel link a deeper receive queue.
#
# The default 2048 bytes is sized for a link with RTS/CTS, where the host stops
# sending once the buffer fills. This one has no flow control, so anything that
# does not fit is simply lost. 8192 covers a burst of full-size frames arriving
# while the OpenThread thread is busy.
CONFIG_OPENTHREAD_COPROCESSOR_UART_RING_BUFFER_SIZE=8192