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

BUG?:UART_INTENSET_RXTO dosen't work

Hi All, I tried to use the nRF51422 device UART RXTO events using nrf51 SDK v6.1. I set the NRF_UART0->INTENSET in app_uart_init() as following:

// Enable UART interrupt
NRF_UART0->INTENCLR = 0xffffffffUL;
NRF_UART0->INTENSET = (UART_INTENSET_RXDRDY_Set << UART_INTENSET_RXDRDY_Pos) |
                      (UART_INTENSET_TXDRDY_Set << UART_INTENSET_TXDRDY_Pos) |
                      (UART_INTENSET_ERROR_Set << UART_INTENSET_ERROR_Pos) |
			          (UART_INTENSET_RXTO_Set << UART_INTENSET_RXTO_Pos) ;

I expected the NRF_UART0->INTENSET should be set as 0x20284, because I found the following defines in nrf51_bitfields.h

#define UART_INTENSET_RXTO_Pos (17UL) /*!< Position of RXTO field. */
#define UART_INTENSET_ERROR_Pos (9UL) /*!< Position of ERROR field. */
#define UART_INTENSET_TXDRDY_Pos (7UL) /*!< Position of TXDRDY field. */
#define UART_INTENSET_RXDRDY_Pos (2UL) /*!< Position of RXDRDY field. */

however, I found the NRF_UART0->INTENSET was set as 0x0284.

Then II tested to set the NRF_UART0->INTENSET = 0xFFFFFFFFUL, the NRF_UART0->INTENSET just became 0x1FFFF; Is this a bug for NRF_UART0->INTENSET ? How can I make the UART RXTO events run?

Parents
  • Thanks for the feedback. I've tried setting up and enabling RXTO as you are doing. I used the default UART example code from the nRF51 SDK 7.2. I added a line that wrote just to RXTO.

    NRF_UART0->INTENSET = 0x00020000;
    

    Then I verified in my debugger that the value is actually written to INTENSET. Even if I write

    NRF_UART0->INTENSET = 0xFFFFFFFF;
    

    I see that INTENSET is set to 0x0007FFFF;

    Have you made any progress on this issue or are you still have trouble with enabling the RXTO interrupt?

Reply
  • Thanks for the feedback. I've tried setting up and enabling RXTO as you are doing. I used the default UART example code from the nRF51 SDK 7.2. I added a line that wrote just to RXTO.

    NRF_UART0->INTENSET = 0x00020000;
    

    Then I verified in my debugger that the value is actually written to INTENSET. Even if I write

    NRF_UART0->INTENSET = 0xFFFFFFFF;
    

    I see that INTENSET is set to 0x0007FFFF;

    Have you made any progress on this issue or are you still have trouble with enabling the RXTO interrupt?

Children
No Data
Related