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.

CC3220SF: sl_FsOpen MAXSIZE_BIT_MASK 0x1FFFF

Part Number: CC3220SF

Hi,

 

I'm using Internal Update of ota_if,The tar file needs to be written to the file system,sl_FsOpen limits open file size to 64kbyes,But OTAs generate tar files that are hundreds of Kbytes in size,

How to solve this problem? I still have some problems in using it. Thank you!

  • Hi,

    There is no problem with maximum size of file at CC3220. Maximum file size is unlimited actually (see SWRU455 chapter 8.2) and depends on sFlash size. Macro SL_FS_OPEN_MAXSIZE_BIT_MASK has nothing to do with maximum size. This macro is a bit mask used for macro SL_FS_CREATE_MAX_SIZE().

    Why you need save whole TAR file into SPI flash? This is unnecessary wasting of resources. You should parse TAR file on-the-fly as is done at TI ota examples.

    Jan

  • my application not use http,I want to use the SOCKET to send tar to CC3220, CC3220 writes to the file system, and then call ota

    mqtt_client demo Has the following description(mqtt_client_CC3220SF_LAUNCHXL_tirtos7_ticlang/README.html):

    Internal Update - in this case the update starts when the OTA (tar) image is already located in the SimpleLink file-system. The OTA_IF will be used to read the image and install the content.

  • Hi,

    It does not mater what way is used for transfer data of the OTA update. You can transfer data via UART, MQTT, HTTP and you can still parse TAR file on-the-fly.

    Jan

  • I find  the function OTAScheduleProcessCmd in ota_if.c,What do you mean use  this function to parse TAR file on-the-fly?

    thanks!

  • I think you mean re-implement these functions(FILE_StartSession,FILE_GetChunk,  FILE_EndSession) in the ota_if.c.
  • Hi,

    OTA TAR file can be processed by chunks, no need to have whole file before processing.

    See here how to processing chunks of TAR file works. At that example I use HTTP and XMLHttpRequest but as transport layer can be used anything you want.

    Jan