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.

LAUNCHXL-F280049C: Code Composer Studio 20 - How to Copy Expression Value of array and struct variables in WATCH section of DEBUG pane?

Part Number: LAUNCHXL-F280049C

Tool/software:

When I right click on a variable name in the WATCH section of the DEBUG pane and chose "Copy Expression Value" I get a copy of the base address of the array variable. The same happens for a struct variable.

However, I am not interested in the base address of the variable, I am interested in the content of the array or struct variable.

In Code Composer Studio 12.8 it was possible to copy content of an array or struct variable to the clipboard from the Watch Expression Window.

How do I do this in Code Composer Studio 20?

Is it possible to export the value of an array or struct variable into a file?

Information:

Code Composer Studio 20.0.1.4 

Edition Windows 11 Enterprise
Version 23H2
Installed on ‎2024-‎07-‎03
OS build 22631.4751
Experience Windows Feature Experience Pack 1000.22700.1055.0

Best Regards

Christian Wolf

  • Hi Christian,

    Unfortunately this is not supported but the CCS team plans on incorporating this feature in the near term. I have filed a ticket to track this feature. The only other work around would be to extract the memory contents from the memory view and cast the values as needed. 

    Best,

    Ryan Ma

  • Hi Ryan,

    What is near term, is it weeks, months, or years?

    I look forward to be able to either copy or save to a file the contents of an array or struct variables directly.

    In the mean time I will try to follow your advice and see if I can copy the content of the memory and convert the hex content into a 32-bit floating-point variable.

    Best Regards

    Christian Wolf

  • Hi Christian,

    May of 2025 is the planned timeframe in which this feature gets updated.

    Best,

    Ryan Ma

  • Hi Ryan,

    Thank you for estimate on when the feature will be available.

    I followed your advice and was able to save the memory content in the Intel Hex format into a text file.

    Using the information given here https://en.wikipedia.org/wiki/Intel_HEX ,I was able to read the text file and convert the hex digits into a floating-point value by writing a small Python program using the Python Struct library and the information given here https://www.geeksforgeeks.org/convert-hex-string-to-float-in-python/ .

    I was logging the data in the C program with a C struct variable with 4 × float32_t values. Using the Python program I wrote, it was easy to store the floating -point data from the struct variable after conversion in a Python Pandas Dataframe. and subsequently plot the data with the aid of the Python Matplotlib library.

    So, this way of extracting data from CCS seems to work very well for me for now.

    Best Regards

    Christian Wolf