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/TMS320F28377S: Setting up a project

Part Number: TMS320F28377S
Other Parts Discussed in Thread: CONTROLSUITE, C2000WARE

Tool/software: Code Composer Studio

Hello there,

So far I have been developing for ARM devices, mostly STM32. With ST I get MxCube which generates a startup project for me with all necessary peripheral .c/.h files. I am trying to get started with C2000 launchpad. I create a new project but its quite empty, auto complete does not know anything as well. I cant seem to find any peripheral libraries available, as well as higher level procedures (HAL).

Is there any straight forward guide explaining how to create and develop a project fast with all needed peripheral libraries for IO, UART, FLASH etc. Does it provide any examples? Also does the library for C2000 include HAL framework of similar?

I have downloaded controlSUITE but it seems to only include some mathematical/ dsp algorithms. I would appreciate all help.

  • Hi Lukasz,
    controlSUITE is definitely what you want to start with. I'm sure the examples you are looking for are in there. I will move this thread to the C2000 forum. The experts there can help you best.

    Thanks
    ki
  • You may want to check out C2000ware: www.ti.com/.../C2000Ware
    "...any new device support packages will only be pulled into C2000ware."

    I have run some C2000ware examples on CCS v.7, and I recommend CCS v.7 and C2000ware as a starting point.
  • Hi, thank you for answers,

    Is it something experimental...?

  • No, I think it is a migration thing. ControlSuite has been around for years, but C2000ware is relatively new. So until everything is migrated, TI has said they will be using both (ControlSuite and C2000ware).
  • Lukasz,

    There are F28377S example projects in both releases. I should point out that there are two programming models available.

    The first is register-centric where you have easy access to each register field. These are located in the device_support directories of controlSUITE and C2000Ware:
    \controlSUITE\device_support\F2837xS\v210\F2837xS_examples_Cpu1\
    \C2000Ware_1_00_00_00\device_support\f2837xs\examples\cpu1\

    The second is more abstract where common actions are wrapped into function calls. These are located in the driverlib directory of C2000Ware:
    \C2000Ware_1_00_00_00\driverlib\f2837xs\examples\cpu1

    -Tommy
  • Thank you for answer.
    It seems more clear to me now but I still have 2 questions:
    1. If I want to for example to use ADC peripheral, do I manually have to include the link to the folder (or copy it) with F2837xS_adc.h/.c, then add it as source folder and add to includes in the project properties?
    2. I cant seem to find the registers definitions macros with their respective addresses from datasheet. For example in I found "C:\ti\c2000\C2000Ware_1_00_00_00\device_support\f2837xs\headers\include\F2837xS_can.h". There I can find all structs and unions defining a register but how does the compiller know where is tris register in the memory map?
  • Lukasz Przenioslo said:
    1. If I want to for example to use ADC peripheral, do I manually have to include the link to the folder (or copy it) with F2837xS_adc.h/.c, then add it as source folder and add to includes in the project properties?

    The *.h directories are already referenced by the project, and the individual *.h files are usually included by higher level include files like F28x_Project.h.

    The *.c files will need to be added as needed when you use functions or variables defined in the files.  You can add files by:

    1. Right-clicking on the project, or
    2. Using the Project menu, or
    3. Dragging & dropping *.c files from windows explorer to the project in CCS

    Lukasz Przenioslo said:
    2. I cant seem to find the registers definitions macros with their respective addresses from datasheet. For example in I found "C:\ti\c2000\C2000Ware_1_00_00_00\device_support\f2837xs\headers\include\F2837xS_can.h". There I can find all structs and unions defining a register but how does the compiller know where is tris register in the memory map?

    This is determined by a combination of F2837xS_GlobalVariableDefs.c and F2837xS_Headers_nonBIOS.cmd.

    The *.cmd files used to be linked as Project source files along with *.c / *.asm, but C2000Ware has moved them into Project >> Properties >> Build >> C2000 Linker >> File Search Path >> Include library file or command file as input.

    A useful CCS shortcut to seek the declaration of a function is to move the cursor onto the function call (or prototype) and then hit F3. This also works for variables and #include directives.

  • The problem is when I create a new project I dont have anything ibcluded there, its very plain. Theres only one .h file with some generic functions and linker script I think.

    So what are the .cmd files exacly?

  • Hi Lukasz,

    Let me explain to you in very simple words.... All you've to do is import the projects you find in controlSuite or C2000ware to CCS instead of creating new projects and then importing the files linked to it.

    Here's an example: Go to CCS -> Projects -> Import CCS Projects -> Navigate to C:\ti\c2000\C2000Ware_1_00_00_00\device_support\f2837xs\examples\cpu1\adc_soc_epwm\cpu01 -> Import

    As simple as that.  In this way you'll understand the source & header files that needs to be linked.

    Lukasz Przenioslo said:
    So what are the .cmd files exacly?

    Its the linker file that has all memory allocation information. Additionally you can check this wiki page:

    Regards,

    Gautam

  • Thank you for answers, I think ill get the hand of it eventually.

    Although (just a personal thought) for a modern IDE this seems to be way to manual for me. Comparing it to ARM world (for example STM32) and their IDE's (even eclipse with addons which are free) this is simply difficult.

  • So for CCS v7 you've inbuilt Resource Explorer that you can simply import example projects to your workspace. Simply Click on View -> Resource Explorer -> Software -> C2000ware