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/TM4C129ENCPDT: How to get TiRTOS sources into C index?

Part Number: TM4C129ENCPDT


Tool/software: Code Composer Studio

Dear forum,

I have to write an driver for half duplex communication over UART. This should be a variant of the origin TiRTOS driver UARTTiva. Unfortunately the driver is not in the index of the project, thus it is very hard to get to the sources. Is there a possibility to get the driver source code into the C index (such that "open declaration" works)?

  • Hello Sven,
    Please refer to the below article. I believe it covers the issue you are dealing with:
    www.eclipse.org/.../article4.php

    Note that in CCS, some of the settings are hidden. You can expose them by clicking on the "Hide Advanced Settings" link in the lower left corner of the dialog.

    Thanks
    ki
  • Hi Ki,

    thank you for providing this helpful link. But I'm quite unexperienced with Eclipse, thus I didn't get it running satisfying.
    What I did so far:
    1) project properties -> C/C++ General -> Indexer -> Configure Workspace settings ... checked checkbox "Index source and header files opened in editor": This helps somehow in a three step manner: a) open declaration -> .h file opens, b) Toggle source / header -> .c file opens, c) go to .h file and "open declaration" -> function definition opens, done
    2) I enabled the Build Output parser as mentioned in the article. But even after a project rebuild and index rebuild it didn't work ...

    Could you provide a more detailed explanation?
  • I had a deeper look into the indexing and build of the TiRTOS examples:
    The libraries aren't build from their c-Sources, but from already compiled .lib files. Therefore the c indexer has no chance to find the sources.
    So far I did not find a solution to add the c source file folders to the c indexer only. The build process seems to be managed.

    For now, there are two possibilities known to me:

    1) project properties (right click on project in project explorer) -> C/C++ General -> Indexer -> Configure Workspace settings ... check checkbox "Index source and header files opened in editor": This helps somehow in a three step manner:
    a) open declaration -> .h file opens,
    b) Toggle source / header -> .c file opens,
    c) go to .h file and "open declaration" -> function definition opens in c file

    2)
    - project properties -> C/C++ General -> Paths and Symbols -> Source Location -> Link Folder
    - define the folder name, e.g. TiRTOS_Src
    - check "Link to folder in file system
    - browse to folder of sources, e.g. "C:/ti/tirtos_tivac_2_16_00_08/products/TivaWare_C_Series-2.1.1.71b" (you can copy it from the "includes" tab)
    - press apply and rebuild index

    You should not build the project now, because all TiRTOS sources will get build also, but in a wrong context!
    After examining the code you can make a right click on your defined folder (in the example "TiRTOS_Src") in the project explorer and select "Exclude from build".
    You can now build the project, but the index will no longer work ...