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/TMS320F28379D: #Cannot open source file error

Part Number: TMS320F28379D
Other Parts Discussed in Thread: C2000WARE

Tool/software: Code Composer Studio

I am a beginner level user at Code Composer Studio(7.3.0) and I have to generate PWM and use ADC using TMS320F28379D processor. When I "build" the codes that I wrote for my project, I got the error I mentioned in the visual. I would be grateful if anyone helps.

  • This is a common error described in this page: https://processors.wiki.ti.com/index.php/Compiler/diagnostic_messages/5

    To resolve the error, add the location of the file F28x_Project.h to the compiler's list of include paths. In CCS, include paths are set under --include_path dialog in Project Properties → Build → Compiler → Include Options.

  • Hello AartiG, i did what you said and also i downloaded the C2000ware software and added F28x_Project.h commons and headers but i got new error with defining CPU1 or CPU2. I searched the forums about that but I can't find the CPU1_RAM etc. I reached to Processor Options, but Configuration didn't contain CPU1_RAM instead there was

    Debug {Active}

    Release

    {All configurations}



  • As indicated in the message, you should define either CPU1 or CPU2 in your project properties. This definition sets up other things to ensure the code runs properly on the designated CPU. 

    The best way to understand how and where these settings are is to import example projects from C2000Ware.

    If you import one of the example projects from C2000Ware (for example, the one shown below), you can go into Project Properties and observe the Predefined Symbol setting.  The definition is then used in a #def context in several source files. 

  • Sorry for my late replying AartG, i couldn't spend time on CCS because of coronavirus preqautions. If we come to our main subject, I really don't know much about this importing or adding paths smh. But i imported an example from C2000Ware example blinky_cpu01. I compared everything with my empty main.c.The empty project which is mine, has no CPU1 or CPU2 named configuration only debug or release. When i ignored it and added the new predefined symbols named CPU1 the builded code gave errors about naming the codes. The screenshots that i add in below can give info about my knowledge problem about CCS and my troubles about can't filling the blanks on first step to final steps of your comments. I added header and common include paths also. Lots of thanks for spending your valuable time for my big problems but i hope it will take little time of yours :) I think our problem will be end soon.

     


  • The CPU1_RAM and CPU1_FLASH configurations in the blinky example are build configurations. This is different from the CPU1/CPU2 predefined symbol that is set as a compiler option.

    In the blinky example, they have set up 4 custom configurations to make it easy for users to get started with building and running an example on Launchpads/controlcards. 
    When you create a new project in CCS using the project wizard, the Debug and Release build configurations are created by default. From there you are free to customize, copy, rename them as you wish. 

    To save development time and effort I would suggest starting with one of the examples from C2000Ware (as you have done). These examples have a lot of pre-work already done in terms of the required build settings for the specific device/family. You can make a copy of the example project if you wish and then customize it for your needs by adding/removing source files.This will be a lot easier than starting a project from scratch.

    Hope this helps.