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.

OTA ISSUE for CC2538SF23

Other Parts Discussed in Thread: TIMAC, Z-STACK

Hi Ti,

there are 2 issues for my project about the OTA.

1:some time the download is failed at the end of the OTA, I debugged and found the image CRC is wrong, I don't know how this occurs?

if ( HalOTAChkDL ( HAL_OTA_CRC_OSET ) != SUCCESS )
            {
#if (defined HAL_LCD) && (HAL_LCD == TRUE)
              HalLcdWriteString ( "OTA CRC Fail", HAL_LCD_LINE_3 );
#endif
              return ZCL_STATUS_INVALID_IMAGE;
            }

2:some time it go to the next step when everything is ok and before reset the system it is wrong like below:

if (pMsg->hdr.status == ZSuccess)
    {
      // Reset the CRC Shadow and reboot.  The bootloader will see the
      // CRC shadow has been cleared and switch to the new image
      //Timac_Zstack_mode=0U;
     //osal_nv_write(WTM_IN_TIMAC_OR_ZSTACK_MODE, 0, 1, &Timac_Zstack_mode);
      HalOTAInvRC();
      SystemReset();
    }

I set the breakpoint in the SystemReset(), and it can not arrive here, but it can go into the function HalOTAInvRC();

so I think it is another CRC question.

sometime I just changed a little bit code and compile the .zigbee file for the upgrade.

Thank you can show me some information.

BR,

  • Could you share what software stack you are using including the version and also which example project are you using as a base for your project.

    Thanks,
    Hector
  • Hi Hector,
    thank you for reply, the stack version is Z-Stack Home 1.2.2a.44539, and the end device is used the "SampleSwitch" sample and the Coordinator is used the "OTA_Dongle" sample.
    I think if this is happened, I think maybe the .zigbee file is broken otherwise it can not happen this.
    and my CPU is CC2538SF23, which only has 256K flash, and I have modification some of the flash mapping and now some time the OTA is normal but some time if I changed some code maybe it is not ok.