nrf54L15 : Unable to use UARTE00 P2.0, P2.2, P2.3, P2.4 not able to send data.

Hello,

I am not able to send any data through the pins of port P2 using Pins : P2.0, P2.2, P2.3, P2.4 , while the pins P1.11, P1,10, and P1.4, P1.5 are working properly.

I referred to this issue and tried to configure accordingly, but still unable to send and receive data. I am using the DK, 

I tried to call nrfx_power_constlat_mode_request(); as well, but I am not sure where I am going wrong.

Parents Reply Children
  • Hello,

    Sorry for the Late Response.

    I did not understand what I need to configure in the Board Configurator. Are we talking about the application in nrf connect for Desktop?

  • Yes, but I can see that the app doesn't support this as of yet, it's planned end of September.

    Kenneth

  • Hello, 

    I wanted to use P2.02 as RXD and P2.03 as TXD in NRF54L15. I am using a custom board. 

    My configuration looks like this on the dts File :

        /omit-if-no-ref/ uart00_default: uart00_default {
            group1 {
                psels = <NRF_PSEL(UART_TX, 2, 3)>;
            };
            group2 {
                psels = <NRF_PSEL(UART_RX, 2, 2)>;
                // bias-pull-up;
            };
        };
    
        /omit-if-no-ref/ uart00_sleep: uart00_sleep {
            group1 {
                psels = <NRF_PSEL(UART_TX, 2, 3)>,
                    <NRF_PSEL(UART_RX, 2, 2)>;
                low-power-enable;
            };
        };
    /////////////////////////////////////////////////////////////////////////////////////////////////////////
    &uart00 {
        compatible = "nordic,nrf-uarte";
        status = "okay";
        current-speed = <9600>;
        pinctrl-0 = <&uart00_default>;
        pinctrl-1 = <&uart00_sleep>;
        pinctrl-names = "default", "sleep";
    };
    
    ///////////////////////////////////////////////////////////////////////////////////////////////////////////
    
    #include "header.h"
    
    #define UART_USB_NODE   DT_NODELABEL(uart00)
    const struct device *uart_dev_usb= DEVICE_DT_GET(UART_USB_NODE);
    char usb_buff[10] = {0};
    const struct uart_config uart_cfg_usb = {
     .baudrate = 9600,
     .parity = UART_CFG_PARITY_NONE,
     .stop_bits = UART_CFG_STOP_BITS_1,
     .data_bits = UART_CFG_DATA_BITS_8,
     .flow_ctrl = UART_CFG_FLOW_CTRL_NONE
    };
    
    static void uart_usb_cb(const struct device *dev, struct uart_event *evt, void *user_data)
    {
    //LOG_INF("uart_cb enum = %d\n\r",evt->type);
     switch (evt->type)
     {
        case UART_TX_DONE:
            printk("UART_TX_DONE \r\n");
        // do something
        break;  
        case UART_TX_ABORTED:
        // do something
        break;
    
    
        case UART_RX_RDY:
            f.gnss_uart_rx_F = 1;
            printk("RX Data :  %s\r\n",usb_buff);
    
            break;  
        case UART_RX_BUF_REQUEST:
        // do something
        break;  
        case UART_RX_BUF_RELEASED:
           
        // do something
        break;
        case UART_RX_DISABLED:
            uart_rx_enable(dev, (uint8_t *)usb_buff, sizeof(usb_buff), 500 * 1000);
            break;  
        case UART_RX_STOPPED:
        // do something
        break;
        default:
        break;
     }
    }
    
    void USB_init(void)
    {  
        int err = 0;
        if (!device_is_ready(uart_dev_usb))
            printk("err : device_is_ready\r\n");
        else
            printk("no err : device_is_ready\r\n");
    
        err = uart_configure(uart_dev_usb, &uart_cfg_usb);  
        if (err == -ENOSYS)
        {
            printk("err = %d : uart_configure\r\n", err);
            // return -ENOSYS;
        }
        else
        {
            printk("err = %d : uart_configure\r\n", err);
        }
    
        err = uart_callback_set(uart_dev_usb, uart_usb_cb, NULL);
        if (err)
        {
            printk("err = %d : uart_callback_set\r\n", err);
            // return err;
        }
        else
        {
            printk("err = %d : uart_callback_set\r\n", err);
        }
        uart_rx_enable(uart_dev_usb, (uint8_t *)usb_buff, sizeof(usb_buff), 1000*1000);
    }
    
    void USB_printk(char *data,int len)
    {
        int err = uart_tx(uart_dev_usb, data, len, 100);
        printk("err = %d\r\n", err);
    }

    Also Before transmitting, I used the function : 
    nrfx_power_constlat_mode_request();
    I am using a loopback format.
    I am using P1.4, P1.5 and P1.10, and P1.11 also, but did not face any issue while using those.
    Is there something i need to change? Am I going wrong somewhere?
  • Hello, 

    Thankyou For Confirming.

    We figured that out later. We need this UART for logging.and we want to use only TX. So I guess it be possible to use P2.2 as TX (Swapping with P2.3) for UARTE00?

Related