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 Cloud: Debugger cannot open source file "driverlib.h"



While Debugging my code in CCS Cloud, the debugger is unable to find driverlib.h, i am using this lib for the SPI API

Output from compiler : 

>> Compilation failure subdir_rules.mk:7: recipe for target 'main.obj' failed "../main.c", line 7: fatal error #1965: cannot open source file "driverlib" 1 catastrophic error detected in the compilation of "../main.c". Compilation terminated. gmake: *** [main.obj] Error 1 gmake: Target 'all' not remade because of errors.

My Project Properties 

Family: MSP432 

Device: MSP432P401R

Compiler: TI v15.12.1.LTS

  • Is the project you are building an example project that you imported from Resource Explorer or your own project? If it is an example project, please let us know which one.

  • Yes it is ,
    (Link to Resource: dev.ti.com/.../ )

    it is the spi_3wire_incrementing_data-master.c Peripheral Example

    ive tried the resource without editing and with my edits and still fails to compile (Kept the edited version and the original in separate projects )
  • Can you import the spi_3wire_incrementing_data-master project into CCS Cloud and build it without errors?

    I just imported this project from the Cloud Resource Explorer by clicking on "Import to CCS Cloud". Then built it and did not receive any errors. I have attached my build output so you can compare it against yours.

    If you created a new project (rather than importing the example project) you may be missing the include paths required for the compiler to find driverlib.h. The examples set these up already so you may be better off importing the example, then making a copy of the project or renaming it before customizing or modifying the code.

    **** Clean-only build of configuration Debug for project spi_3wire_incrementing_data-master ****
    
    @ccs/utils/bin/gmake -k clean 
    rm -rf  "spi_3wire_incrementing_data-master.out"  "spi_3wire_incrementing_data-master.bin" 
    rm -rf "spi_3wire_incrementing_data-master.d" "startup_msp432p401r_ccs.d" "system_msp432p401r.d" 
    rm -rf "spi_3wire_incrementing_data-master.obj" "startup_msp432p401r_ccs.obj" "system_msp432p401r.obj" 
    Finished clean
     
    
    **** Build Finished ****
    
    **** Build of configuration Debug for project spi_3wire_incrementing_data-master ****
    
    @ccs/utils/bin/gmake -k all 
    Building file: ../spi_3wire_incrementing_data-master.c
    Invoking: MSP432 Compiler
    "@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/bin/armcl" -mv7M4 --code_state=16 --float_support=FPv4SPD16 -me --include_path="@ccs/ccs_base/arm/include" --include_path="@ccs/ccs_base/arm/include/" --include_path="@ccs/ccs_base/arm/include/CMSIS" --include_path="@workspace/spi_3wire_incrementing_data-master" --include_path="@ti-rex-content/mspware/mspware__3.30.00.18/driverlib/driverlib/MSP432P4xx/" --include_path="@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/include/" --include_path="@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/include" --advice:power=all -g --gcc --define=__MSP432P401R__ --define=TARGET_IS_MSP432P4XX --define=ccs --diag_wrap=off --diag_warning=225 --display_error_number --preproc_with_compile --preproc_dependency="spi_3wire_incrementing_data-master.d" --diag_error=66 --set_error_limit=10  "../spi_3wire_incrementing_data-master.c"
    "../spi_3wire_incrementing_data-master.c", line 115: remark #1527-D: (ULP 2.1) Detected SW delay loop using empty loop. Recommend using a timer module instead
    "../spi_3wire_incrementing_data-master.c", line 139: remark #1527-D: (ULP 2.1) Detected SW delay loop using empty loop. Recommend using a timer module instead
    "../spi_3wire_incrementing_data-master.c", line 147: remark #1527-D: (ULP 2.1) Detected SW delay loop using empty loop. Recommend using a timer module instead
    "../spi_3wire_incrementing_data-master.c", line 76: remark #1534-D: (ULP 7.1) Detected use of global variable "RXData" within one function "EUSCIB0_IRQHandler". Recommend placing variable in the function locally
    Finished building: ../spi_3wire_incrementing_data-master.c
     
    Building file: ../startup_msp432p401r_ccs.c
    Invoking: MSP432 Compiler
    "@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/bin/armcl" -mv7M4 --code_state=16 --float_support=FPv4SPD16 -me --include_path="@ccs/ccs_base/arm/include" --include_path="@ccs/ccs_base/arm/include/" --include_path="@ccs/ccs_base/arm/include/CMSIS" --include_path="@workspace/spi_3wire_incrementing_data-master" --include_path="@ti-rex-content/mspware/mspware__3.30.00.18/driverlib/driverlib/MSP432P4xx/" --include_path="@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/include/" --include_path="@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/include" --advice:power=all -g --gcc --define=__MSP432P401R__ --define=TARGET_IS_MSP432P4XX --define=ccs --diag_wrap=off --diag_warning=225 --display_error_number --preproc_with_compile --preproc_dependency="startup_msp432p401r_ccs.d" --diag_error=66 --set_error_limit=10  "../startup_msp432p401r_ccs.c"
    Finished building: ../startup_msp432p401r_ccs.c
     
    Building file: ../system_msp432p401r.c
    Invoking: MSP432 Compiler
    "@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/bin/armcl" -mv7M4 --code_state=16 --float_support=FPv4SPD16 -me --include_path="@ccs/ccs_base/arm/include" --include_path="@ccs/ccs_base/arm/include/" --include_path="@ccs/ccs_base/arm/include/CMSIS" --include_path="@workspace/spi_3wire_incrementing_data-master" --include_path="@ti-rex-content/mspware/mspware__3.30.00.18/driverlib/driverlib/MSP432P4xx/" --include_path="@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/include/" --include_path="@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/include" --advice:power=all -g --gcc --define=__MSP432P401R__ --define=TARGET_IS_MSP432P4XX --define=ccs --diag_wrap=off --diag_warning=225 --display_error_number --preproc_with_compile --preproc_dependency="system_msp432p401r.d" --diag_error=66 --set_error_limit=10  "../system_msp432p401r.c"
    "../system_msp432p401r.c", line 148: remark #2623-D: (ULP 5.4) Detected an assignment to a type with size less than int. To avoid unnecessary sign extension, use int-sized types for local varaibles and convert to smaller types for static storage.
    "../system_msp432p401r.c", line 196: remark #2623-D: (ULP 5.4) Detected an assignment to a type with size less than int. To avoid unnecessary sign extension, use int-sized types for local varaibles and convert to smaller types for static storage.
    "../system_msp432p401r.c", line 229: remark #2623-D: (ULP 5.4) Detected an assignment to a type with size less than int. To avoid unnecessary sign extension, use int-sized types for local varaibles and convert to smaller types for static storage.
    "../system_msp432p401r.c", line 321: remark #1528-D: (ULP 3.1) Detected flag polling using PCM_CTL1_PMR_BUSY. Recommend using an interrupt combined with enter LPMx and ISR
    "../system_msp432p401r.c", line 323: remark #1528-D: (ULP 3.1) Detected flag polling using PCM_CTL1_PMR_BUSY. Recommend using an interrupt combined with enter LPMx and ISR
    Finished building: ../system_msp432p401r.c
     
    Building target: spi_3wire_incrementing_data-master.out
    Invoking: MSP432 Linker
    "@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/bin/armcl" -mv7M4 --code_state=16 --float_support=FPv4SPD16 -me --advice:power=all -g --gcc --define=__MSP432P401R__ --define=TARGET_IS_MSP432P4XX --define=ccs --diag_wrap=off --diag_warning=225 --display_error_number -z -m"spi_3wire_incrementing_data-master.map" --stack_size=512 -i"@ccs/ccs_base/arm/include" -i"@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/lib" -i"@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/include" --reread_libs --display_error_number --warn_sections --diag_wrap=off --xml_link_info="spi_3wire_incrementing_data-master_linkInfo.xml" --rom_model --set_error_limit=10 -o "spi_3wire_incrementing_data-master.out" "./spi_3wire_incrementing_data-master.obj" "./startup_msp432p401r_ccs.obj" "./system_msp432p401r.obj" "@ti-rex-content/mspware/mspware__3.30.00.18/driverlib/driverlib/MSP432P4xx/ccs/msp432p4xx_driverlib.lib" "../spi_3wire_incrementing_data-master_ccs.cmd"  -llibc.a 
    <Linking>
    remark #10371-D: (ULP 1.1) Detected no uses of low power mode state changing instructions
    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.
    Finished building target: spi_3wire_incrementing_data-master.out
     
    bash "@ccs/utils/tiobj2bin/tiobj2bin" "spi_3wire_incrementing_data-master.out" "spi_3wire_incrementing_data-master.bin" "@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/bin/armofd" "@ccs/tools/compiler/ti-cgt-arm_15.12.1.LTS/bin/armhex" "@ccs/utils/tiobj2bin/mkhex4bin"
     
    
    **** Build Finished ****
    

  • Thank you, Importing directly from the Resource Explorer to CCS Cloud worked for me