This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

APP_UART_COMMUNICATION_ERROR on app UART event handler when connected to BMD101

I am using the NRF52840 controller to connect BMD101(ECG sensor) uart based having a baud rate of 57600.

Note: Using UART peripheral example on SDK17

I am trying to parse the UART data as per the sensor datasheet (Given here)and the sensor is working fine with other hosts(UART COM PORT on PC).

As soon as I start the sequence and the sensor got enable, the event handler keeps on throwing APP_UART_COMMUNICATION_ERROR, and when I try to read FIFO in between using

app_uart_get API, it returns error code 5.

Parents
  • Hi,

    The communication errors corresponds to the error bits in ERRORSRC register. Error 4 (FRAMING) typically means that the level of the UART RX line is incorrect (low when it should be high, etc). Error 1 (OVERRUN) means that the internal FIFO in the UART(E) peripheral is full and incoming data will be lost. This happens if the application does not read our the data fast enough after enabling UART RX.

    Can you post your code used for initializing and reading/writing the UART? You can avoid the reset by not passing the error to APP_ERROR_CHECK in the UART event handler in case of a APP_UART_COMMUNICATION_ERROR event.

    Best regards,
    Jørgen

Reply
  • Hi,

    The communication errors corresponds to the error bits in ERRORSRC register. Error 4 (FRAMING) typically means that the level of the UART RX line is incorrect (low when it should be high, etc). Error 1 (OVERRUN) means that the internal FIFO in the UART(E) peripheral is full and incoming data will be lost. This happens if the application does not read our the data fast enough after enabling UART RX.

    Can you post your code used for initializing and reading/writing the UART? You can avoid the reset by not passing the error to APP_ERROR_CHECK in the UART event handler in case of a APP_UART_COMMUNICATION_ERROR event.

    Best regards,
    Jørgen

Children
Related