This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

UART TI RTOS driver problem tm4c123gh6pm tiva c



Hello,

I am trrying to use UART driver from TI-RTOS. The problem is I dont know what to use as "someUART_configIndexValue" in UART_open.

Here is the code:

UART_Handle handle;
UART_Params params;

UART_Params_init(&params);
params.baudRate = 4800;
params.writeDataMode = UART_DATA_BINARY;
params.readDataMode = UART_DATA_BINARY;
params.readReturnMode = UART_RETURN_FULL;
params.readEcho = UART_ECHO_OFF;
params.dataLength = UART_LEN_8;
handle = UART_open(UART0, &params);
if (!handle) {
System_printf("UART did not open");
}

My programming skills are below averange. Its not the yellow of the egg. If possible german answers, they are easier t understand.

Best Regards,

some Noob

  • Hi Marinkovic,

    The first argument to UART_open() is suppose to be an index into the UART's HWAttrs table. The HWAttrs table may list more than one UARTs and the index tells UART_open() which one you want to open. The UART's HWAttrs table is defined in the board.c file. I have shown a screenshot of this structure below:

    Since you are new to TI-RTOS, I would recommend starting with an existing UART example. TI-RTOS ships with 3 UART examples - UART Console, UART Echo and UART Logging. You can import one of these through TI Resource Explorer in CCS.

    Best,

    Ashish

  • When I include <ti/drivers/uart/UARTTiva.h> I have 4 Errors, which are:
    - #10010 errors encountered during linking; "UART_Typical.out" no built
    - #10234-D unresolved symbols remain
    - unresolved symbol UART_open, first referenced in ./main.obj
    - unresolved symbol UART_Params_init, first referenced in ./main.obj

    I don't want you to programm for me, but I need serious Help.
    Please Help me out.
  • Hi Marinkovic,
    I have the same problem. Did you fix it? how?

    Best,
    Fausto
  • Fausto,

    This is an old thread that is closed. Can you please create a new thread and provide the details of the problem along with the version of TI-RTOS?

    Thanks,
    Vikram