2019-01-14 02:38 AM
Hello all
I have a problem with updating the filesystem over http
AT+S.HTTPDFSUPDATE=192.168.3.2,/fs.img,8079
this is the command i use to update the fs.
The logs of the local webserver tell
192.168.3.1 - - [14/Jan/2019:13:29:51 +0300] "GET /fs.img HTTP/1.0" 200 14600 "-" "SPWF01SC1"
so the download happens. on the spwf01 console i see
Image length 20694 (offset 0x00080000, block len 4096)
Write len 2694 -> 0x80000 (final)
Wrote 2694 bytes
Error (-3 @ 2690/20696), cleaning up..
so i get an error and the filesystem is not updated.
the firmware of the wifi module is the latest (updated a week ago)
2019-01-14 08:40 AM
Hello,
it seems the SPWF01 is running low on memory.
Could you please:
Thanks,
Regards,
Elio
2019-01-14 09:30 AM
Hello,
> RELEASE
+WIND:1:Poweron (170111-665d284-SPWF01S)
> BEFORE
# free_heap = 15600
# min_heap = 10848
> UPDATE
Image length 20694 (offset 0x00080000, block len 4096)
Write len 3424 -> 0x80000 (final)
Wrote 3424 bytes
Error (-3 @ 3420/20696), cleaning up..
> AFTER
# free_heap = 17232
# min_heap = 6040
2019-01-14 09:42 AM
Just to add,
sometimes, very rarely, 1 of many tries, the update IS succeseful
# free_heap = 17152
# min_heap = 7624
Image length 20694 (offset 0x00080000, block len 4096)
Write len 4096 -> 0x80000
Write len 4096 -> 0x81000
Write len 4096 -> 0x82000
Write len 4096 -> 0x83000
Write len 4096 -> 0x84000
Write len 220 -> 0x85000 (final)
Wrote 20700 bytes
Complete! Please reboot. (at+cfun=1)
# free_heap = 17152
# min_heap = 7592
2019-01-14 09:51 AM
Hello,
actually the HTTPDFSUPDATE command will fail if the available memory is too low or too fragmented.
If your use case allow it, I suggest to perform the FS update as soon as possible after a boot.
Regards,
Elio