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.

AM5749: Following Template App Toot, CCS Mailbox undefined

Part Number: AM5749
Other Parts Discussed in Thread: SYSBIOS

Hello,

This issue is wrt the AM574x Industrial Develop Kit. I am a software developer running CCS in Windows 10 on an Intel Xeon Dell Laptop...

In diligently following the CCS Application Tutorial circa section 9.1.4.6.3 regarding Mailboxes. I have received feedback that the compiler CANNOT resolve the Mailboxes' definition. However, of note, I CAN right click to mailbox.h without issue. Following my own attempts, I outright substituted, the app.c, app.h and app.cfg files (copy paste) into my own app instance. The compiler feedback was the same:

C:\Users\quinn.carver\ccslWorkspace_v10\rtos_template_app_am572x_a15\Debug/../app.c:124: undefined reference to `ti_sysbios_knl_Mailbox_pend__E'

How might I have the mailbox included?

V/R, QC

  • In app.cfg, did you include Mailbox module?

    Please refer to BIOS_User_Guide.pdf for more info on how to configure SYSBIOS.

    In addition, what is the path you use? It should be set like below.

    #include <ti/sysbios/knl/Mailbox.h>

  • inlined:

    >>>>>>

    In app.cfg, did you include Mailbox module?

    yes, ...var Mailbox = xdc.useModule('ti.sysbios.knl.Mailbox'); Please note again, I am using the cheat files (app.h, app.c, app.cfg) which have this.

    Please refer to BIOS_User_Guide.pdf for more info on how to configure SYSBIOS.

    hello, I see this user guide. I see how it explains configuring the Bios using XGCONF (just a gui wrapper me'thinks). Was there something specific?

    In addition, what is the path you use? It should be set like below.

    #include <ti/sysbios/knl/Mailbox.h>

    Yes, I use exactly this include in app.h

    also ... this makes sense b/c:

    PS C:\ti\bios_6_76_03_01\packages\ti\sysbios\knl> dir | grep Mailbox.h
    -a---- 10/8/2019 6:37 PM 29935 Mailbox.h

    <<<<<<<

    Maybe this is a clue but I also see other strange behavior.

    If I use the default template and comment out all references to the i2c and spi (includes for, uses-of, declarations-of, and definitions of) I get the following error on build:

    undefined reference to `I2C_v1_FxnTable'

    Which seems strange if I am not using I2C in the executable...

    However if I go back a comment-in (uncomment) only the i2c include and the function definition (no need declaration - b/c not called) then the build does proceed. Why would the definition of an unused function be important to a function table defined in the RTOS build (FxnTable).

    One other clue. After unsuccessfully building yesterday I assumed perhaps the entire SDK had to be built first so on the command line I:

    cd processor_sdk_rtos_am57xx_6_03_00_106
    set SDK_INSTALL_PATH=C:/ti
    set TOOLS_INSTALL_PATH=C:/ti/
    setupenv.bat

    gmake clean

    gmake all -j4

    Today I still have the same result when I build the app. In fact, if I use the cheat files (app.h, app.c, app.cfg) I also get the same i2s feedback I mention above (b/c the i2s method "i2c_eeprom_read_and_display_task" isn't defined again as above). As follows:

    **** Build of configuration Debug for project rtos_template_app_am572x_a15 ****

    "C:\\ti\\ccs1011\\ccs\\utils\\bin\\gmake" -k -j 8 all -O

    Building file: "../main.c"
    Invoking: GNU Compiler
    "C:/ti/ccs1011/ccs/tools/compiler/gcc-arm-none-eabi-7-2017-q4-major-win32/bin/arm-none-eabi-gcc-7.2.1.exe" -c -mcpu=cortex-a15 -mtune=cortex-a15 -marm -mfloat-abi=hard -Dam5728 -Dcore0 -DevmAM572x -DSOC_AM572x -I"C:/Users/quinn.carver/ccslWorkspace_v10/rtos_template_app_am572x_a15" -I"C:/ti/ccs1011/ccs/tools/compiler/gcc-arm-none-eabi-7-2017-q4-major-win32/arm-none-eabi/include" -Og -g -gdwarf-3 -gstrict-dwarf -Wall -MMD -MP -MF"main.d" -MT"main.o" @"configPkg/compiler.opt" -o"main.o" "../main.c"
    Finished building: "../main.c"

    Building file: "../app.c"
    Invoking: GNU Compiler
    "C:/ti/ccs1011/ccs/tools/compiler/gcc-arm-none-eabi-7-2017-q4-major-win32/bin/arm-none-eabi-gcc-7.2.1.exe" -c -mcpu=cortex-a15 -mtune=cortex-a15 -marm -mfloat-abi=hard -Dam5728 -Dcore0 -DevmAM572x -DSOC_AM572x -I"C:/Users/quinn.carver/ccslWorkspace_v10/rtos_template_app_am572x_a15" -I"C:/ti/ccs1011/ccs/tools/compiler/gcc-arm-none-eabi-7-2017-q4-major-win32/arm-none-eabi/include" -Og -g -gdwarf-3 -gstrict-dwarf -Wall -MMD -MP -MF"app.d" -MT"app.o" @"configPkg/compiler.opt" -o"app.o" "../app.c"
    Finished building: "../app.c"

    Building target: "rtos_template_app_am572x_a15.out"
    Invoking: GNU Linker
    "C:/ti/ccs1011/ccs/tools/compiler/gcc-arm-none-eabi-7-2017-q4-major-win32/bin/arm-none-eabi-gcc-7.2.1.exe" -mtune=cortex-a15 -marm -Dam5728 -Dcore0 -DevmAM572x -DSOC_AM572x -Og -g -gdwarf-3 -gstrict-dwarf -Wall -mfloat-abi=hard -Wl,-Map,"rtos_template_app_am572x_a15.map" -nostartfiles -static -Wl,--gc-sections -L"C:/ti/pdk_am57xx_1_0_17/packages/ti/board/lib/evmAM572x/a15/release/" -L"C:/ti/bios_6_76_03_01/packages/gnu/targets/arm/libs/install-native/arm-none-eabi/lib/hard" -Wl,--defsym,CORE0=1 -Wl,--defsym,STACKSIZE=0x10000 -Wl,--defsym,HEAPSIZE=0x400 --specs=nano.specs -o"rtos_template_app_am572x_a15.out" "./GPIO_evmAM572x_board.o" "./app.o" "./main.o" -Wl,-T"configPkg/linker.cmd" -Wl,--start-group -l:ti.board.aa15fg -lgcc -lm -lrdimon -lc -Wl,--end-group
    makefile:148: recipe for target 'rtos_template_app_am572x_a15.out' failed
    ./app.o: In function `gpio_toggle_led_task':
    C:\Users\quinn.carver\ccslWorkspace_v10\rtos_template_app_am572x_a15\Debug/../app.c:124: undefined reference to `ti_sysbios_knl_Mailbox_pend__E'
    C:\Users\quinn.carver\ccslWorkspace_v10\rtos_template_app_am572x_a15\Debug/../app.c:133: undefined reference to `ti_sysbios_knl_Mailbox_pend__E'
    ./app.o: In function `uart_task':
    C:\Users\quinn.carver\ccslWorkspace_v10\rtos_template_app_am572x_a15\Debug/../app.c:199: undefined reference to `ti_sysbios_knl_Mailbox_post__E'
    ./app.o: In function `appTasksCreate':
    C:\Users\quinn.carver\ccslWorkspace_v10\rtos_template_app_am572x_a15\Debug/../app.c:99: undefined reference to `ti_sysbios_knl_Mailbox_create'
    C:/ti/pdk_am57xx_1_0_17/packages/ti/board/lib/evmAM572x/a15/release/\ti.board.aa15fg(I2C_soc.oa15fg): In function `.LANCHOR2':
    C:/ti/pdk_am57xx_1_0_17/packages/ti/drv/i2c/soc/am572x/I2C_soc.c:207: undefined reference to `I2C_v1_FxnTable'
    C:/ti/pdk_am57xx_1_0_17/packages/ti/board/lib/evmAM572x/a15/release/\ti.board.aa15fg(I2C_soc.oa15fg): In function `.LANCHOR2':
    I2C_soc.c:(.data.I2C_config+0xc): undefined reference to `I2C_v1_FxnTable'
    I2C_soc.c:(.data.I2C_config+0x18): undefined reference to `I2C_v1_FxnTable'
    I2C_soc.c:(.data.I2C_config+0x24): undefined reference to `I2C_v1_FxnTable'
    I2C_soc.c:(.data.I2C_config+0x30): undefined reference to `I2C_v1_FxnTable'
    collect2.exe: error: ld returned 1 exit status
    gmake[1]: *** [rtos_template_app_am572x_a15.out] Error 1
    gmake: *** [all] Error 2
    makefile:144: recipe for target 'all' failed

    C:\ti\pdk_am57xx_1_0_17\packages>env
    !::=::\
    !C:=C:\ti\pdk_am57xx_1_0_17\packages
    !ExitCode=00000002
    ALLUSERSPROFILE=C:\ProgramData
    APPDATA=C:\Users\quinn.carver\AppData\Roaming
    BIN_CMAKE=C:\Program Files\CMake\bin
    BLAH="blah"
    ChocolateyInstall=C:\ProgramData\chocolatey
    ChocolateyLastPathUpdate=132549316431703217
    CMAKE_CXX_COMPILER=C:\Program Files\mingw-w64\x86_64-8.1.0-win32-sjlj-rt_v6-rev0\mingw64\bin\g++.exe
    CMAKE_C_COMPILER=C:\Program Files\mingw-w64\x86_64-8.1.0-win32-sjlj-rt_v6-rev0\mingw64\bin\gcc.exe
    COMMONPROGRAMFILES=C:\Program Files\Common Files
    CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files
    CommonProgramW6432=C:\Program Files\Common Files
    COMPUTERNAME=CTSI-ASSET1876
    COMSPEC=C:\WINDOWS\system32\cmd.exe
    DriverData=C:\Windows\System32\Drivers\DriverData
    GENICAM_GENTL32_PATH=C:\Program Files\Basler\pylon 6\Runtime\Win32\
    GENICAM_GENTL64_PATH=C:\Program Files\Basler\pylon 6\Runtime\x64\
    GMAKE_INSTALL_PATH=C:/ti/xdctools_3_55_02_22_core
    HOMEDRIVE=C:
    HOMEPATH=\Users\quinn.carver
    IDF_PATH=C:\Users\quinn.carver\esp-idf\tools\windows
    IDF_TOOLS_PATH=C:\espressif
    IPC_ALT_PLATFORM=AM572X AM571X
    IPC_PLATFORM=DRA7XX
    LOCALAPPDATA=C:\Users\quinn.carver\AppData\Local
    LOGONSERVER=\\CTSI-DC05
    MINGW_CXX_COMPILER=C:\Program Files\mingw-w64\x86_64-8.1.0-win32-sjlj-rt_v6-rev0\mingw64\bin\g++.exe
    MINGW_C_COMPILER=C:\Program Files\mingw-w64\x86_64-8.1.0-win32-sjlj-rt_v6-rev0\mingw64\bin\g++.exe
    NUMBER_OF_PROCESSORS=8
    OneDrive=C:\Users\quinn.carver\OneDrive
    OneDriveConsumer=C:\Users\quinn.carver\OneDrive
    OPENCV_DIR=C:\opencv\build\x64\vc15
    OS=Windows_NT
    PATH=/c/ti/xdctools_3_55_02_22_core:/c/ti/xdctools_3_55_02_22_core:/c/ti/xdctools_3_55_02_22_core:/c/ti/xdctools_3_55_02_22_core:/c/ti/xdctools_3_55_02_22_core:/c/ti/xdctools_3_55_02_22_core:/c/ti/xdctools_3_55_02_22_core:/c/ti/xdctools_3_55_02_22_core:/c/ti/xdctools_3_55_02_22_core:/c/ti/xdctools_3_55_02_22_core:/c/Python39/Scripts:/c/Python39:/c/Program Files/Basler/pylon 6/Runtime/x64:/c/Program Files/Basler/pylon 6/Runtime/Win32:/c/Program Files (x86)/Common Files/Oracle/Java/javapath:/c/Windows/system32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0:/c/Windows/System32/OpenSSH:/c/Program Files (x86)/NVIDIA Corporation/PhysX/Common:/c/Program Files/CMake/bin:/cmd:/mingw64/bin:/usr/bin:/c/Program Files/MATLAB/MATLAB Runtime/v93/runtime/win64:/c/Users/quinn.carver/bin:/c/Program Files/MATLAB/MATLAB Runtime/v96/runtime/win64:/c/Program Files (x86)/Sennheiser/SoftphoneSDK:/c/WINDOWS/system32:/c/WINDOWS:/c/WINDOWS/System32/Wbem:/c/WINDOWS/System32/WindowsPowerShell/v1.0:/c/WINDOWS/System32/OpenSSH:/c/Program Files (x86)/Intel/Intel(R) Management Engine Components/DAL:/c/Program Files/Intel/Intel(R) Management Engine Components/DAL:/c/Program Files/PuTTY:/c/Program Files (x86)/HID Global/ActivClient:/c/Program Files/HID Global/ActivClient:/c/Program Files/nodejs:/c/ProgramData/chocolatey/bin:/c/Users/quinn.carver/AppData/Roaming/Python/Python39/Scripts:/c/Users/quinn.carver/AppData/Local/Programs/Python/Python37/Scripts:/c/Users/quinn.carver/AppData/Local/Programs/Python/Python37:/c/Users/quinn.carver/AppData/Local/Microsoft/WindowsApps:/c/Program Files/CMake/bin:/c/intelFPGA_lite/18.1/modelsim_ase/win32aloem:/c/Program Files/JetBrains/PyCharm Community Edition 2020.1.2/bin:/c/opencv/build/x64/vc15/bin:/c/Users/quinn.carver/AppData/Roaming/npm
    PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.PY;.PYW
    pdkdir=pdk_am57xx_1_0_17
    pdkdir_ver=1_0_17
    pdksoc=am57xx
    PDK_INSTALL_PATH=C:/ti/pdk_am57xx_1_0_17/packages
    PDK_SOC=am57xx
    PDK_VERSION=1_0_17
    PROCESSOR_ARCHITECTURE=AMD64
    PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 158 Stepping 9, GenuineIntel
    PROCESSOR_LEVEL=6
    PROCESSOR_REVISION=9e09
    procsdk_dir=C:\ti\processor_sdk_rtos_am57xx_6_03_00_106
    PROC_SDK_INSTALL_PATH=C:/ti/processor_sdk_rtos_am57xx_6_03_00_106
    PROC_SDK_VERSION=am57xx_6_03_00_106
    ProgramData=C:\ProgramData
    PROGRAMFILES=C:\Program Files
    ProgramFiles(x86)=C:\Program Files (x86)
    ProgramW6432=C:\Program Files
    PROMPT=$P$G
    PSModulePath=C:\Program Files\WindowsPowerShell\Modules;C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules
    PUBLIC=C:\Users\Public
    PyCharm Community Edition=C:\Program Files\JetBrains\PyCharm Community Edition 2020.1.2\bin;
    python39_scripts=C:\Users\quinn.carver\AppData\Roaming\Python\Python39\Scripts
    QSYS_ROOTDIR=C:\intelFPGA_lite\18.1\quartus\sopc_builder\bin
    QUARTUS_ROOTDIR=C:\intelFPGA_lite\18.1\quartus
    RULES_MAKE=C:/ti/pdk_am57xx_1_0_17/packages/ti/build/Rules.make
    s=C: ti pdk_am57xx_1_0_17
    sdkdir=C:/ti
    SDK_INSTALL_PATH=C:/ti
    SESSIONNAME=Console
    SOC=am57xx
    SOPC_KIT_NIOS2=C:\intelFPGA_lite\18.1\nios2eds
    SYSTEMDRIVE=C:
    SYSTEMROOT=C:\WINDOWS
    TEMP=/tmp
    TMP=/tmp
    TOOLS_INSTALL_PATH=C:/ti/
    USERDNSDOMAIN=CORP.GOCTSI.COM
    USERDOMAIN=CORP
    USERDOMAIN_ROAMINGPROFILE=CORP
    USERNAME=quinn.carver
    USERPROFILE=C:\Users\quinn.carver
    v1=1
    v2=0
    v3=17
    VCPKG_DEFAULT_TRIPLET=x64-windows
    WINDIR=C:\WINDOWS
    xdcver=XDC_VERSION=3_55_02_22_core
    XDC_VERSION=3_55_02_22_core
    TERM=cygwin
    HOME=/c/Users/quinn.carver

     

     

  • Can you check if your project includes main.cfg file?

    Can you share a screenshot of your project in CCS?