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/TMS320DM642: How to Read the .dat file into the CCS project?

Part Number: TMS320DM642

Tool/software: Code Composer Studio

I have convert the .bmp graph files in to the .dat format by MATLAB, and then i loading the .dat file into the array created in my simulation project! The Head line of the .dat file is setting like this:1651 2 8cc0 0 1a70c.I want to know what the means of the head line,and when i an going to convert a audio file into .dat file to using in my project,how can i set the Head line of my .dat file?

  • Hello,

    user4763388 said:
    The Head line of the .dat file is setting like this:1651 2 8cc0 0 1a70c.I want to know what the means of the head line

    This is documented in the CCS Help (Help -> Help Contents -> Code Composer Studio Help -> Views and Editors -> Memory View -> Data File Formats)

    Right from this help:

    MagicNumber Format StartingAddress PageNum Length [NewFormat]

    MagicNumber—fixed at 1651.
    Format—a number from 1 to 4, indicating the format of the samples in the file. This number represents a data format: (1) hexadecimal, (2) integer, (3) long, (4) float, or (9) Use new scheme
    StartingAddress—starting address of the block that was saved.
    PageNum—page number the block was taken from.
    Length—number of samples in the block.
    NewFormat—Format (9); the new scheme. This is optional when usign the legacy formats 1 - 4

    In your case:

    user4763388 said:
    1651 2 8cc0 0 1a70c

    1651 is a fixed value indicating it is a CCS *.dat file

    2 indicates that the vales in the *.dat file are integers

    0x8cc0 is the start address of where the values in the *.dat file will be loaded to in target memory

    0 indicates that the values will be loaded to page 0 (which is program memory page on a C55x)

    0x1a70c indicates the hexidecimal number of data samples in the file

    This header is generated when saving target memory to a *.dat file on your PC via CCS. If you manually create a *.dat for input into CCS, you can create the header yourself. If there is no header, I believe CCS will ask you for the information.

    Thanks

    ki

  • Thanks a lot!