BLE disconnected while using virtual UART and HW_UART

Hello,

In my project i am using nrf52840 and i have change the default UART pins to P1.3 (TX) and P1.4(RX) and while using virtual UART like BLE UART  i mean in the sense sending data from the APP TO MCU and vice versa here at the same time if  i am trying to use the HW_UART BLE gets disconnected.

1. why its happening like this.??

2. Please suggest me to resolve this.

thank you.

Parents Reply
  • depends on what error it is.
    You can check the source of the error when using app_uart like below in the uart callback handler

            case APP_UART_COMMUNICATION_ERROR:
                APP_ERROR_HANDLER(p_event->data.error_communication);

    If using nrfx drivers, you can directly get and clear the errorsrc usingnrfx_uarte_errorsrc_get. Based on the type of error you get, you can handle that error as per the application need (for example, flush the RX FIFO or restart the uart communication etc)

    .

Children
No Data
Related