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/AWR1642: Data verification Failed in CCS while loading bin file to AWR1642

Part Number: AWR1642
Other Parts Discussed in Thread: UNIFLASH, MMWAVE-SDK

Tool/software: Code Composer Studio

Hi Team,

       I am trying to load a .XER4F  binary file to AWR1642  through CCS. In that code i am trying to store data into flash memory. But While loading through CCS i am getting error like data verification failed.

      Working on CortexR4_0 in AWR1642.

While loading Error is like below

         CortexR4_0: GEL: File: mss.xer4f: a data verification error occurred, file load failed.      

      If anyone know abt this, please give a reply.

  • Hi,

    These devices usually have an intricate procedure to perform flash programming. Please check the reference below:

    software-dl.ti.com/.../mmwave_sdk_user_guide.pdf

    Hope this helps,
    Rafael
  • Hi Rafael,

             Thanks for the reply.

                   I have followed the complete procedure and written data into flash memory of awr1642.

                  I written data in following address.

              

    flashAddr = QSPIFlash_getExtFlashAddr(QSPIFlashHandle);

    flashAddr = flashAddr + 0x180000U;
    Is it writable address. Please tell what are writable flash addresses of AWR1642.
    Onetime it worked and again i am trying to do same, it was not working.
    How flash erasing will work?
    Regards,
    Raviteja.

      

          

              

  • Raviteja,

    Please apologize; I missed your last reply.

    Are you still having this issue? I may need the help of a device expert to look into this case but this week is a holiday week in the US and therefore this may only progress next week.

    Regards,
    Rafael
  • Rafael,

    I am working on mmwave_sdk_01_02_00_05 and implemented CANTP RX. In CANTP RX application i am trying to store the mmw_demo.bin file (which is received from PCANTP TX app by chunks of 3kb) at an offset of metaimage3(1024kb) in to flash memory of AWR1642 .

    Before doing this I flashed another demo.bin at an offset of metaimage4(1536kb) from uniflash.

    Then I restarted the device and checked in serial console (teraterm), It was skipping the loading of image at metaimage3 and directly loading image at metaimage4 offset.

    I also checked whether it was writing into flash or not by reading back everytime and comparing. I am attaching code here for reference.

    QSPIFlash_sectorErase(QSPIFlashHandle, flashAddr);

    QSPIFlash_singleWrite(QSPIFlashHandle, flashAddr, DataLength, (uint8_t *)Rx_buf);

    QSPIFlash_singleRead(QSPIFlashHandle, flashAddr, DataLength, (uint8_t *)&readDataArray[0]);

    /* Check data */
    retVal = memcmp((void *)&Rx_buf[0], (void *)&readDataArray[0], DataLength);
    if(retVal == 0)
    {
    MCPI_setFeatureTestResult ("QSPIFlash single write /single read API", MCPI_TestResult_PASS);
    }
    else
    {
    MCPI_setFeatureTestResult ("QSPIFlash single write /single read API", MCPI_TestResult_FAIL);
    }

    Everything is fine here.


    But I don't know why it was not loading the image at metaimage3 offset and directly going to image at meataimage4 offset?

    Can you explain what are things need to take care while writing into flash by QSPI?

    Regards,
    Raviteja.
  • Hi Raviteja,
    I assume you are trying to write a SBL (secondary bootloader application) where the new image can be download over an interface to the AWR1642 device and SBL running inside the device will take that data to write it on sFlash.

    For this purpose please refer to SBL application available in mmWave-SDK 3.0
    C:\ti\mmwave_sdk_03_00_00_07\packages\ti\utils\sbl

    This application currently uses UART interface to get the image data from PC but you can easily replace UART with CAN interface (refer SDL_design.pdf: section-6 in the above-mentioned directory)


    Regards,
    Jitendra
  • Hi Jitendra,

          I have tried with that also. I have flashed SBL image at Metaimage1 through Uniflash. According to that code if you don't send any image from UART,  it will directly pick the image stored at Metaimage4(Backup image). I am storing demo.bin in Metaimage4  through QSPI in CANTP Rx application. 

    After resetting i have checked in serial console, SBL is booting up and it is trying to pick the image from Metaimage4.

    But it is printing like 

    Error: Metaimage header absent .

    Regards, 

    Raviteja.

  • Can you first run the SBL application to write the new image over UART to sFlash of the device as mentioned in the user guide. Check if that flow is working then include CAN interface. Store the new image using same SBL application.

    Regards,
    Jitendra
  • First I checked that only, It was working Fine.
  • Then modify same SBL application to add CAN interface to download new image over CAN.
    Code reference is provided in the SBL user guide for CAN interface. I assume 'CANTP Rx' application you are talking here is your written application, better to use existing SBL application to download the application to sFlash.

    Regards,
    Jitendra
  • I am working on mmwave sdk 1.2 and SBL is available from  mmwave sdk 3.0.

    That's why I'm flashing SBL image at metaimage1 offset and writing demo.bin into metaimage4 through CANTP.

    How  QSPIFLASH_SectorErase() (erase 4kb from provided address)  function will behave when you write 3kb of data in flash and increment the flash address by 3kb and writing the next 3kb from that address?

    QSPIFlash_sectorErase(QSPIFlashHandle, flashAddr);

    QSPIFlash_singleWrite(QSPIFlashHandle, flashAddr, DataLength, (uint8_t *)Rx_buf);

    QSPIFlash_singleRead(QSPIFlashHandle, flashAddr, DataLength, (uint8_t *)&readDataArray[0]);

    flashAddr = flashAddr + DataLength;

    Here DataLength is 3Kb.

  • Hi Ravi,
    This query has been answered in other thread
    e2e.ti.com/.../748397

    Regards,
    Jitendra