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

NRF_UART0->ERRORSRC = 0xC - what does it mean?

Hi,

I'm porting a nrf51822 evaluation board 10001 tested application to a custom board. Part of the application is using UART interrupts to raise a flag and start data transfer through BLE. When i run the application on the custom board, i seem to be getting a NRF_UART0->EVENT_ERROR with ERRORSRC = 0xC.

I've searched and the only thing i found about this in the documentation is the description of ERRORSRC "Error source. Write error field to 1 to clear error."(what is "error field"?) and some posts here in devzone, although the problems here seem to be a little different(ERRORSRC was 2 and explained as an overflow error. i've made sure no data is sent through UART after initialization so i doubt it's the problem here). Could anyone please give me an explanation what the value of ERRORSRC is supposed to represent exactly and direct me to a table of possible values? Currently i'm stuck on this - although when running the same project with only the UART pins changed everything is OK.

Parents
  • See nRF51 Series Reference Manual (version 2.1) table 28.9.8.

    0xC = 0b1100 which means you have two errors that are not cleared. In your case this is a break condition error and a framing error. Quoting the reference manual: 0b0100: "Framing error occurred. A valid stop bit is not detected on the serial data input after all bits in a character have been received." 0b1000: "Break condition. The serial data input is '0' for longer than the length of a data frame. (The data frame length is 10 bits without parity bit, and 11 bits with parity bit)."

  • If I'm not mistaken, it means that if you write the same bit back to this register (e.g. write 0b1000 / 0x08) that specific error bit will be cleared. To clear and acknowledge the 0x0C error, you would have to write 0x0C back to the same register. This is shown in the Reference Manual as R and W on the individual bits.

Reply Children
No Data
Related