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.

Unresolved symbol platform_uart_write

I'm using CCS 5.5 and attempting to use the platform_uart_write() function to write to the UART. I get an error:

"unresolved symbol platform_uart_write, ..."

I take it I need to include a library somehow, but which one?

I had a similar problem with  Timestamp_getFreq and found a post saying to add the following to my .cfg file:

var Timestamp = xdc.useModule('xdc.runtime.Timestamp');


That worked, but how are you supposed to know these things? I can't seem to find any documentation of available functions along with how to link them. Suffice it to say I'm new to CCS.

  • Hi,

    'Unresolved symbols' happen during the link phase, so you have already included the header where the function is declared, but the compiler can't find its definition and you have to add the .c/.cpp with its definition or a .lib.

    You didn't mention what device you're using, I'll answer for 6678. Other devices should be similar.

    In the .cfg add the following line:

    var PlatformLib  = xdc.loadPackage('ti.platform.evmc6678l');

    Depending on what functions you use from the platform, you may also need platform_osal.c that's located in MCSDK folder. IN file platform.c located in PDK folder (PDK6678_INSTALL_DIR/packages\ti\platform\evmc6678l\platform_lib\src), you have all functions of the platform.

    Regards

    J

  • J,

    Thanks, the loadPackage did the trick (evm6670l in my case).

    At first it could not find the headers as you say, but then I checked the MCSDK PDK TMS3206670 in the RTSC tab of the Properties. It then found the headers and I had thought this effectively included that functionality in my project. I guess there's a lot more to it. It's all a bit confusing at the moment.

    Thanks,
    Dave