From 40683379719844444f5b173209f30a1da4be57e0 Mon Sep 17 00:00:00 2001 From: Andy Piper Date: Sat, 11 Jun 2022 09:33:39 +0100 Subject: [PATCH] AP_HAL_ChibiOS: correct UART RX stats --- libraries/AP_HAL_ChibiOS/UARTDriver.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/libraries/AP_HAL_ChibiOS/UARTDriver.cpp b/libraries/AP_HAL_ChibiOS/UARTDriver.cpp index 852841ec1f..b39766f1a2 100644 --- a/libraries/AP_HAL_ChibiOS/UARTDriver.cpp +++ b/libraries/AP_HAL_ChibiOS/UARTDriver.cpp @@ -573,6 +573,7 @@ __RAMFUNC__ void UARTDriver::rxbuff_full_irq(void* self, uint32_t flags) we have data to copy out */ uart_drv->_readbuf.write(uart_drv->rx_bounce_buf[bounce_idx], len); + uart_drv->_rx_stats_bytes += len; uart_drv->receive_timestamp_update(); }