Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs
This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nrfx_uart bug

Hi,

nrfx_uart.c has a bug where, once there is a RX error, the receiver gets stuck in a disabled state forever.  This is because p_cb->rx_enabled is never set true, so the error handler in uart_irq_handler disables the RX task.  This fixes it:

@@ -406,60 +408,12 @@ nrfx_err_t nrfx_uart_rx(nrfx_uart_t const * p_instance,
 
     if ((!p_cb->rx_enabled) && (!second_buffer))
     {
-        rx_enable(p_instance);
+        nrfx_uart_rx_enable(p_instance);
     }

Related