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

Migrating from SDK14.2.0 to SDK15.0.0, nrfx uart

Hi,

I am migrating from SDK14.2 to SDK15.0 and I can compile now, but when runnning the nrfx_uart_init the hardware handshake signal RTS is high from the beginning.

Also if I dont use hardware handshake the event handler is not trigged by incoming data.

nrfx_uart_t g_Uart = NRFX_UART_INSTANCE(0);

void uart_init()
{
    nrfx_uart_config_t g_UartCfg = NRFX_UART_DEFAULT_CONFIG;

    g_UartCfg.pselrxd = RX_PIN_NUMBER;
    g_UartCfg.pseltxd = TX_PIN_NUMBER;
    g_UartCfg.pselrts = RTS_PIN_NUMBER;
    g_UartCfg.pselcts = CTS_PIN_NUMBER;
    g_UartCfg.hwfc = NRF_UART_HWFC_ENABLED;
    g_UartCfg.baudrate = NRF_UART_BAUDRATE_115200;
    g_UartCfg.interrupt_priority = 6;

    err_code = nrfx_uart_init(&g_Uart, &g_UartCfg, uart_event_handle);
}

As per recommendation from nordic I have ditched the app_uart( previously used in SDK14.2), because when I include the app_uart_fifo.c in the makefile, all the app_uart_put and get are not found, and gone fully nrfx uart ;(...

BR

Parents Reply
  • Have you copied a lot of library files or drivers from your old SDK? I suggest that you start with a project from the new SDK that you are porting to, and replace the main.c file, and add the files that you have written yourself. This way everything should be set up. Or are you just trying to backport the drivers from the later SDK to your current SDK?

    If you started off with a new SDK, then I just want to make you aware of the file "apply_old_config.h". I am not convinced that this is the cause of your issues, but it is worth knowing that it exists.

    BR,

    Edvin

Children
  • I have not copied any library driver from the old SDK, I have 1 c file that holds the UART communication in my program.

    I can see that the examples uses the nrfx driver, but the legacy integration drivers are also included....

    I have also included those, otherwise the app_uart would not work.

    I will try one of the uart examples, and test if it will work at all.

    BR

Related