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/TMS320C6457: How do I set the CP1251 text file encoding in Linux in the editor

Part Number: TMS320C6457

Tool/software: Code Composer Studio

After installing the CSS, there is only UTF-xx, US-ASCII and ISO-8859-1 . But my source codes use CP1251. How can I install the required encoding?

Thanks you

  • Andrey,

    The Eclipse platform that CCS uses does not support CP1251 on Linux or macOS.  I believe it has it on Windows.

    Unicode (UTF-8) would be the recommended encoding to use.  Unfortunately that would mean converting the existing files.

    Alternatively you could use an external editor that supports CP1251.  

    Regards,

    John

  • John, thanks for the answer

    Unfortunately, I cannot change the encoding of the sources due to the specifics of the project.

    Your option using an external editor may suit me.

    I tried to specify it ("Kate") in "Prefences"->"Content Types"->"C Source File"->"Associated Editors" but it is added after "C/C++ Editor" and when I double click in the problem window, the built-in editor opens. Adding to "Editors"->"File Associations" for new file type "*.c" also has no effect.

    Can I configure an external editor on the system CCS 10.1.0(Linux) to run from the IDE?

    Thank!

  • There are a couple ways to set this up.  I typically do it like this.

    Right click on one of the source files in the project explorer:

    Select Open With -> Other...

    Then choose to use an external program and select the program you want to use.  I also check the box at the bottom to say do this for all C files.

    At this point it will open that file in the editor but it doesn't set the behaviour perminantly.

    So I go back and right click.  Select Open With -> select the program (it should now be in the list)

    Make sure the file is closed in CCS and now it should always open in the external editor.

    This works on Windows and Mac, I have not tried on Linux.

    Regards,

    John