Tool/software:
I have encountered an odd CCS behaviour. When the compiler command input passes over the ~8000 char threshold, CCS will put the args into a x_ccsCompiler.opt file to then pass to the compiler. However, this specifically fails when compiling the FreeRTOS kernel code. See the snippet below that shows the compilation of the queue.c file failing. Note that below I have replaced our project root directory with C:/root, so the command line looks considerably shorter.
Building file: "C:/root/lib/c2000/kernel/FreeRTOS/Source/queue.c" Invoking: C2000 Compiler Flags: -v28 -ml -mt --cla_support=cla2 --float_support=fpu32 --tmu_support=tmu0 --vcu_support=vcrc -O3 --opt_for_speed=1 --fp_mode=relaxed --include_path="C:/root/src/brompton/device" --include_path="C:/root/src/brompton" --include_path="C:/root/lib/etl/include" --include_path="C:/root/lib/brixton-library/inc" --include_path="C:/root/lib/c2000/kernel/FreeRTOS/Source/include" --include_path="C:/root/lib/c2000/device_support/f28p55x/headers/include" --include_path="C:/root/lib/c2000/device_support/f28p55x/common/include" --include_path="C:/root/shared_linker" --include_path="C:/root/lib/c2000" --include_path="C:/root/lib/c2000/driverlib/f28p55x/driverlib/" --include_path="C:/ti/ccs2020/ccs/tools/compiler/ti-cgt-c2000_22.6.2.LTS/include" --include_path="C:/root/lib/c2000/kernel/FreeRTOS/Source/portable/CCS/C2000_C28x" --include_path="C:/root/lib/c2000/driverlib/f28p55x/driverlib/inc" --include_path="C:/root/syscfg_gen/launchpad" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/control/ctrl/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/control/pi/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/control/vsf/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/control/fwc/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/control/mtpa/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/control/vs_freq/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/control/dclink_ss/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/filter/filter_fo/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/filter/filter_so/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/observers/est_lib/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/observers/est/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/observers/esmo/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/observers/speedfr/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/observers/speedcalc/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/observers/ssipd/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/observers/isbldc/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/observers/encoder/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/observers/hall/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/observers/mpid/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/transforms/clarke/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/transforms/ipark/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/transforms/park/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/transforms/svgen/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/transforms/volts/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/utilities/angle_gen/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/utilities/cpu_time/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/utilities/datalog/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/utilities/step_response/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/utilities/traj/include/" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/utilities/rimpulse/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/utilities/mod6cnt/include" --include_path="C:/root/lib/c2000ware-motorcontrol-sdk/libraries/utilities/types/include" --include_path="C:/root/lib/c2000/libraries/dsp/VCU/c28/include/vcu0" --define=_FLASH --define=_LAUNCHXL_F28P55X --define=_DUAL_HEADERS --define=CPU1 --define=F28P55x_DEVICE --define=DEBUG --define=_FULL_FAST_LIB --define=__TI_EABI__ --define=__STDC_LIMIT_MACROS --define=_BOOSTXL_DRV8320RS -g --symdebug:dwarf_version=4 --c11 --c++03 --relaxed_ansi --float_operations_allowed=all --printf_support=full --diag_suppress=10063 --diag_warning=225 --diag_wrap=off --display_error_number --verbose_diagnostics --gen_func_subsections=on --abi=eabi --cla_background_task=off --cla_signed_compare_workaround=off --silicon_errata_fpu1_workaround=off --sat_reassoc=off --preproc_with_compile --preproc_dependency="lib/c2000/kernel/FreeRTOS/Source/queue.d_raw" --include_path="C:/root/F28P55x_FLASH/syscfg" Flags (cont-d): --obj_directory="lib/c2000/kernel/FreeRTOS/Source" --cmd_file="syscfg/board.opt" --cmd_file="syscfg/c2000ware_libraries.opt" --cmd_file="syscfg/c2000_freertos.opt" "C:/ti/ccs2020/ccs/tools/compiler/ti-cgt-c2000_22.6.2.LTS/bin/cl2000" -@"c2000/kernel/FreeRTOS/Source/queue_ccsCompiler.opt" The system cannot find the path specified. The system cannot find the path specified. The system cannot find the path specified. >> ERROR: Cannot open command file 'c2000/kernel/FreeRTOS/Source/queue_ccsCompiler.opt': No such file or directory >> ERROR: no source files, nothing to do Finished building: "C:/root/lib/c2000/kernel/FreeRTOS/Source/queue.c"
One thing that I have observed, is that the RTOS files are compiled using the absolute path, where the other files (c2000, local project source) are compiled using the relative path. See below a working compilation call. From my CCS project, I cannot figure out why the file paths might be different for the FreeRTOS source files vs other source files.
Building file: "../src/brompton/device/gate_driver/drv8353_decoder.cpp" Invoking: C2000 Compiler Flags: -v28 -ml -mt --cla_support=cla2 --float_support=fpu32 --tmu_support=tmu0 --vcu_support=vcrc -O3 --opt_for_speed=1 --fp_mode=relaxed --include_path="C:/root/f28p55x-application/src/brompton/device" --include_path="C:/root/f28p55x-application/src/brompton" --include_path="C:/root/f28p55x-application/lib/etl/include" --include_path="C:/root/f28p55x-application/lib/brixton-library/inc" --include_path="C:/root/f28p55x-application/lib/c2000/kernel/FreeRTOS/Source/include" --include_path="C:/root/f28p55x-application/lib/c2000/device_support/f28p55x/headers/include" --include_path="C:/root/f28p55x-application/lib/c2000/device_support/f28p55x/common/include" --include_path="C:/root/f28p55x-application/shared_linker" --include_path="C:/root/f28p55x-application/lib/c2000" --include_path="C:/root/f28p55x-application/lib/c2000/driverlib/f28p55x/driverlib/" --include_path="C:/ti/ccs2020/ccs/tools/compiler/ti-cgt-c2000_22.6.2.LTS/include" --include_path="C:/root/f28p55x-application/lib/c2000/kernel/FreeRTOS/Source/portable/CCS/C2000_C28x" --include_path="C:/root/f28p55x-application/lib/c2000/driverlib/f28p55x/driverlib/inc" --include_path="C:/root/f28p55x-application/syscfg_gen/launchpad" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/control/ctrl/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/control/pi/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/control/vsf/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/control/fwc/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/control/mtpa/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/control/vs_freq/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/control/dclink_ss/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/filter/filter_fo/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/filter/filter_so/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/observers/est_lib/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/observers/est/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/observers/esmo/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/observers/speedfr/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/observers/speedcalc/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/observers/ssipd/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/observers/isbldc/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/observers/encoder/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/observers/hall/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/observers/mpid/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/transforms/clarke/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/transforms/ipark/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/transforms/park/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/transforms/svgen/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/transforms/volts/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/utilities/angle_gen/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/utilities/cpu_time/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/utilities/datalog/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/utilities/step_response/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/utilities/traj/include/" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/utilities/rimpulse/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/utilities/mod6cnt/include" --include_path="C:/root/f28p55x-application/lib/c2000ware-motorcontrol-sdk/libraries/utilities/types/include" --include_path="C:/root/f28p55x-application/lib/c2000/libraries/dsp/VCU/c28/include/vcu0" --define=_FLASH --define=_LAUNCHXL_F28P55X --define=_DUAL_HEADERS --define=CPU1 --define=F28P55x_DEVICE --define=DEBUG --define=_FULL_FAST_LIB --define=__TI_EABI__ --define=__STDC_LIMIT_MACROS --define=_BOOSTXL_DRV8320RS -g --symdebug:dwarf_version=4 --c11 --c++03 --relaxed_ansi --float_operations_allowed=all --printf_support=full --diag_suppress=10063 --diag_warning=225 --diag_wrap=off --display_error_number --verbose_diagnostics --gen_func_subsections=on --abi=eabi --cla_background_task=off --cla_signed_compare_workaround=off --silicon_errata_fpu1_workaround=off --sat_reassoc=off --preproc_with_compile --preproc_dependency="src/brompton/device/gate_driver/drv8353_decoder.d_raw" --include_path="C:/root/f28p55x-application/F28P55x_FLASH/syscfg" Flags (cont-d): --obj_directory="src/brompton/device/gate_driver" --cmd_file="syscfg/board.opt" --cmd_file="syscfg/c2000ware_libraries.opt" --cmd_file="syscfg/c2000_freertos.opt" "C:/ti/ccs2020/ccs/tools/compiler/ti-cgt-c2000_22.6.2.LTS/bin/cl2000" -@"src/brompton/device/gate_driver/drv8353_decoder_ccsCompiler.opt" Finished building: "../src/brompton/device/gate_driver/drv8353_decoder.cpp"
I should note that in our project we are not using the C2000 SDK as a product installed, instead it is a git submodule within the project itself.