TMS320C28346: Change .projectspec file to output files under the current project folder

Part Number: TMS320C28346

I have a project file as below (.projectspec), when I compile the project in CCS v12 or CCS v20, CCS generates .out and .map files in CCS work space folder.

How can I change it to write these files in the current project folder. For example, assume the project is in the folder "C:/Abc/buck converter (PIL) (C code)", I want the .out file is saved in the folder "C:/Abc/buck converter (PIL) (C code)/RamDebug/".

Tried to load the whole project, it failed.

Thanks,

Jiakai

<projectSpec>
    <project name="buck_converter__SimCoder_"
             device="TMS320F28035"
             cgtVersion="16.9.1.LTS"
             launchWizard="False"
             linkerCommandFile="">
        <configuration name="RamDebug" compilerBuildOptions="--opt_level=off -v28 -ml -mt --diag_warning=225 --diag_suppress=10063 --display_error_number" linkerBuildOptions="--stack_size=0x1B0 -heap=0 --entry_point=code_start" />
        <configuration name="RamRelease" compilerBuildOptions="--opt_level=3 -v28 -ml -mt --diag_warning=225 --diag_suppress=10063 --display_error_number" linkerBuildOptions="--stack_size=0x1B0 -heap=0 --entry_point=code_start" />
        <configuration name="FlashRelease" compilerBuildOptions="--opt_level=3 -v28 -ml -mt --define=_FLASH --diag_warning=225 --diag_suppress=10063 --display_error_number" linkerBuildOptions="--stack_size=0x1B0 -heap=0 --entry_point=code_start" />
        <configuration name="FlashRamRelease" compilerBuildOptions="--opt_level=3 -v28 -ml -mt --define=_FLASH --diag_warning=225 --diag_suppress=10063 --display_error_number" linkerBuildOptions="--stack_size=0x1B0 -heap=0 --entry_point=code_start" />

        <file action="link" path="buck_converter__SimCoder_.c" targetDirectory="" />
        <file action="link" path="passwords.asm" targetDirectory="" />

        
        <file action="link" path="2803x_IQmath_BootROMsymbols.lib" targetDirectory="" />
        <file action="link" path="IQmath.lib" targetDirectory="" />
        <file action="link" path="PsBiosRamF03xFixpt.lib" targetDirectory="" applicableConfigurations="RamDebug,RamRelease"/>
        <file action="link" path="PsBiosRomF03xFixpt.lib" targetDirectory="" applicableConfigurations="FlashRelease,FlashRamRelease"/>

        
        <file action="link" path="F2803x_Headers_nonBIOS.cmd" targetDirectory="" />
        <file action="link" path="F28035_RAM_Lnk.cmd" targetDirectory="" applicableConfigurations="RamDebug,RamRelease" />
        <file action="link" path="F28035_FLASH_Lnk.cmd" targetDirectory="" applicableConfigurations="FlashRelease" />
        <file action="link" path="F28035_FLASH_RAM_Lnk.cmd" targetDirectory="" applicableConfigurations="FlashRamRelease" />

        
    </project>
</projectSpec>

 

  • Hi Jiakai,

    The better way to do this would be from the CCS IDE directly.

    Right click on Project in Project Explorer -> Project Properties → Build → Linker → Basic Options — you'll find fields for --output_file .

    Give the path of your desired folder (where you want to store the .out file) in --output_file.

    Rebuild your project and .out will get saved in the desired folder.

    Thanks,

    Ira

  • Hi Ira,

    I need to create .projectspec file in a program, not just handling one single project.

    Here is the issue, can I specify CCS not to copy the project to CCS work space? if I can, CCS will automatically 

    compile it in the current project, the output files are saved under a sub-folder of the current project folder.

    if the answer is NO, I then need to add -m and -o in linker options. I couldn't use the absolute path here,

    what MACRO do I need to use in -o and -m to specify the current project folder? I found all project related 

    MACROs (or variables) like CCS_PROJECT_DIR, CWD and PWD are pointed to CCS work space.

    thanks,

    Jiakai

  • Hi Jiakai,

    Sorry for the late response. I am unclear on the ask. Do you want for your .out, .map etc files to be created in

    1. A subfolder within your CCS wrokspace

    2. A subfolder not within your CCS workspace

    And you want to do this via the projectspec file and not the CCS IDE? Is that correct?

    Also what do you mean by

    can I specify CCS not to copy the project to CCS work space

    Is this when you import the project? Like you want to build/run/modify the project at its original source location and not copy it into your workspace and then do it? There is an option for that in CCS here via this drop down menu

    Thanks,

    Ira