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.

TMS320F28P550SJ: CRC Calculation in command line

Part Number: TMS320F28P550SJ
Other Parts Discussed in Thread: UNIFLASH

Tool/software:

Hi Experts,

My customer is developing automation script for the UNIFLASH command line interface. They need to calculate the CRC or other forms of verification code. I can see this in the GUI, but how to calculate CRC in command line?

Regards,

Hang

  • Adding more details.

    Customer needs to confirm the CRC of the image before loading, how can this be done in the command line interface?

  • Hi Hang,

    The customer can calculate CRC Checksum through the UniFlash Command Line Interface (CLI) before loading by doing one of the following changes:

    1. In dslite-C28xx_CPU1.bat, add the "-b CalculateChecksum" argument to the generated command file, for example:

    set GENERATED_COMMAND=-c user_files/configs/f28p550sj9.ccxml -l user_files/settings/generated.ufsettings -s VerifyAfterProgramLoad="No verification" -e -f -v "user_files/images/led_ex1_blinky.out" -b CalculateChecksum
    2. At the command line when calling dslite-C28xx_CPU1.bat, add the arguments for generated command including the "-b CalculateChecksum" option, for example:
    dslite-C28xx_CPU1.bat flash -c user_files/configs/f28p550sj9.ccxml -l user_files/settings/generated.ufsettings -s VerifyAfterProgramLoad="No verification" -e -f -v "user_files/images/led_ex1_blinky.out" -b CalculateChecksum
    Note that the "-b" argument indicates we wish to perform this operation before a program load. Operations can be found in the device's Flash Properties XML file as one of the performAction items.
    Thanks and regards,
    Charles
  • Hi Charles,

    Thanks for the instructions. As I tried it out, the -b option seems belongs to part of the loading process, the customer is looking for a separate CRC calculation.

    Their process goes like:

    1. Calculate check sum 

    2. Confirm the checksum from display to ensure they are using correct image.

    3. Connect to XDS110

    4. Program the device

    Using -b options would have these issue: 

    • It cannot be used when XDS110 is not connected
    • Even if XDS110 is connected, using -b would cause a program load right after calculating the checksum.

    The -b options is like executing step 1 and step 4 in a sequence, they need to insert at least step 2 in between (ideally inserting step3 as well), 

    They need something to execute step 1 only. Does CLI support that? If not, can we share the algorithm so that they can implement it themself?

    Regards,

    Hang

  • Hi Hang,

    The options for checksum before XDS110 usage, do you mean checksum over the image standalone? This is not something that the CLI interface currently supports. Per Vamsi, has the algorithm already been shared to you?

    Thanks and regards,

    Charles

  • Hi Charles,

    Vansi shared a checksum algorithm, is it the same to the CRC we are talking about here?

  • I can see this in the GUI

    There are several types of checksum. Can you provide a screenshot of this particular one that you are interested in?

  • Hi Ki 

    This one

  • Thank you. I don't believe this functionality is available from UniFlash CLI interface. I will need to confirm.