I use esp upgrade api (system_upgrade_start) to process FOTA , and it is successful like this:
pusrdata HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Accept-Ranges: bytes
ETag: W/"359508-1463034102000"
Last-Modified: Thu, 12 May 2016 06:21:42 GMT
Content-Type: application/octet-stream
Content-Length: 359508
Date: Thu, 12 May 2016 06:44:26 GMT
Connection: close
?畝
"
userbin sumlength:359508
upgrade_task 94 word left
server response with something else,check it!
upgrade data error!
spi_flash_read error 1
Exit upgrade task.
user_ota_upgrade_successful
upgrade to reboot
upgrade reboot
reboot to use2
state: 5 -> 0 (0)
rm 0
del if0
apnetif->dhcps_pcb = 1073713888
bcn 0
del if1
usl
sul 0 0
when esp restarted , first i use the api to print information about USER.BIN and BIN addr like this:
printf("ESP Flash Size:%d\n",system_get_flash_size_map());
printf("ESP UserBin Addr:%d\n", system_get_userbin_addr());
but esp have already restarted from USER1.BIN like this:
ESP Flash Size:2
ESP UserBin Addr:4096
espFsInit test 0x3fff5420
USER1.BIN and USER2.BIN have different offset addrs, ox1000 is the USER1.BIN ,so
the question is : why not esp start from USER2.BIN after reboot because of FOTA?
Thanks!Statistics: Posted by sdylion — Thu May 12, 2016 3:16 pm
]]>