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.

CCS/MSP-EXP432P401R: Linking TI Driver Files in Project

Part Number: MSP-EXP432P401R


Tool/software: Code Composer Studio

Hi, I am trying to use the included drivers from TI in a project. I have my project compile successfully, but then when it goes to link, their exists undefined symbols which are the functions from the TI drivers. I am confused because my program compiles just fine and I have the header files included in the file. I am not familiar with this environment so I think I am not linking the source files properly, but I have no idea how to do this. Can someone give any advice?

I am simply trying to use the drivers from "C:/ti/simplelink_msp432p4_sdk_2_30_00_14/source/ti/drivers"

Attached is the log. 


**** Build of configuration Debug for project Synthesizer ****

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

Building target: "Synthesizer.out"
Invoking: ARM Linker
"C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/bin/armcl" -mv7M4 --code_state=16 --float_support=FPv4SPD16 -me --advice:power="all" --define=__MSP432P401R__ --define=ccs -g --gcc --diag_warning=225 --diag_wrap=off --display_error_number --abi=eabi -z -m"Synthesizer.map" --heap_size=1024 --stack_size=512 -i"C:/ti/ccsv8/ccs_base/arm/include" -i"C:/ti/simplelink_msp432p4_sdk_2_30_00_14/source" -i"C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/lib" -i"C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/include" --reread_libs --diag_wrap=off --display_error_number --warn_sections --xml_link_info="Synthesizer_linkInfo.xml" --rom_model -o "Synthesizer.out" "./main.obj" -llibc.a
<Linking>
warning #10247-D: creating output section ".text" without a SECTIONS specification
warning #10247-D: creating output section ".const" without a SECTIONS specification
warning #10247-D: creating output section ".data" without a SECTIONS specification
warning #10247-D: creating output section ".bss" without a SECTIONS specification
warning #10247-D: creating output section ".cinit" without a SECTIONS specification
warning #10247-D: creating output section ".stack" without a SECTIONS specification
warning #10247-D: creating output section ".sysmem" without a SECTIONS specification

undefined first referenced
symbol in file
--------- ----------------
ADC_Params_init ./main.obj
ADC_close ./main.obj
ADC_convert ./main.obj
ADC_init ./main.obj
ADC_open ./main.obj
GPIO_init ./main.obj
GPIO_read ./main.obj
GPIO_setConfig ./main.obj
GPIO_write ./main.obj
SPI_Params_init ./main.obj
SPI_init ./main.obj
SPI_open ./main.obj
SPI_transfer ./main.obj
Timer_Params_init ./main.obj
Timer_open ./main.obj
Timer_start ./main.obj

error #10234-D: unresolved symbols remain
remark #10371-D: (ULP 1.1) Detected no uses of low power mode state changing instructions
error #10010: errors encountered during linking; "Synthesizer.out" not built
remark #10372-D: (ULP 4.1) Detected uninitialized Port 1 in this project. Recommend initializing all unused ports to eliminate wasted current consumption on unused pins.
remark #10372-D: (ULP 4.1) Detected uninitialized Port 2 in this project. Recommend initializing all unused ports to eliminate wasted current consumption on unused pins.
remark #10372-D: (ULP 4.1) Detected uninitialized Port 3 in this project. Recommend initializing all unused ports to eliminate wasted current consumption on unused pins.
remark #10372-D: (ULP 4.1) Detected uninitialized Port 4 in this project. Recommend initializing all unused ports to eliminate wasted current consumption on unused pins.
remark #10372-D: (ULP 4.1) Detected uninitialized Port 5 in this project. Recommend initializing all unused ports to eliminate wasted current consumption on unused pins.
remark #10372-D: (ULP 4.1) Detected uninitialized Port 6 in this project. Recommend initializing all unused ports to eliminate wasted current consumption on unused pins.
remark #10372-D: (ULP 4.1) Detected uninitialized Port 7 in this project. Recommend initializing all unused ports to eliminate wasted current consumption on unused pins.
remark #10372-D: (ULP 4.1) Detected uninitialized Port 8 in this project. Recommend initializing all unused ports to eliminate wasted current consumption on unused pins.
remark #10372-D: (ULP 4.1) Detected uninitialized Port 9 in this project. Recommend initializing all unused ports to eliminate wasted current consumption on unused pins.
remark #10372-D: (ULP 4.1) Detected uninitialized Port 10 in this project. Recommend initializing all unused ports to eliminate wasted current consumption on unused pins.

>> Compilation failure
makefile:140: recipe for target 'Synthesizer.out' failed
gmake[1]: *** [Synthesizer.out] Error 1
gmake: *** [all] Error 2
makefile:136: recipe for target 'all' failed

**** Build Finished ****

  • Aaron,

       I would recommend starting from an example from the SDK and then move your application into a copy of the example to inherit the project settings.  

    Building target: "gpio_input_interrupt_MSP_EXP432P401R_nortos_ccs.out"
    Invoking: ARM Linker
    "C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/bin/armcl" -mv7M4 --code_state=16 --float_support=FPv4SPD16 -me --advice:power=none --define=__MSP432P401R__ --define=DeviceFamily_MSP432P401x -g --diag_warning=225 --diag_warning=255 --diag_wrap=off --display_error_number --gen_func_subsections=on -z -m"gpio_input_interrupt_MSP_EXP432P401R_nortos_ccs.map" --stack_size=512 -i"C:/ti/simplelink_msp432p4_sdk_2_30_00_14/source" -i"C:/ti/ccsv8/tools/compiler/ti-cgt-arm_18.1.4.LTS/lib" --diag_wrap=off --display_error_number --warn_sections --xml_link_info="gpio_input_interrupt_MSP_EXP432P401R_nortos_ccs_linkInfo.xml" --rom_model -o "gpio_input_interrupt_MSP_EXP432P401R_nortos_ccs.out" "./gpio_input_interrupt.obj" "./system_msp432p401r.obj" "./ccs/startup_msp432p401r_ccs.obj" "../msp432p401r.cmd"  -l"ti/display/lib/display.aem4f" -l"ti/grlib/lib/ccs/m4f/grlib.a" -l"third_party/spiffs/lib/ccs/m4f/spiffs.a" -l"ti/drivers/lib/drivers_msp432p401x.aem4f" -l"third_party/fatfs/lib/ccs/m4f/fatfs.a" -l"ti/devices/msp432p4xx/driverlib/ccs/msp432p4xx_driverlib.lib" -llibc.a 

    Alternatively you can go through and add the symbols manually.

    Regards,

    Chris

  • Aaron,

    at least you need to update your linker paths and libraries.
    Check the following example: