OTA update

Smick updates automatically

When a new release of K interpreter is released, Smick automatically updates via Wi-Fi. This firmware update mode is called Over-The-Air (OTA). At power-on or reset, Smick checks for a firmware upgrade. If so, it downloads the new firmware and removes the old version in less than a minute.

Here is how the firmware is automatically updated

1. Power-on with old firmware version

Smick v.6.26.72 (C) Copyright 2017 by Curci  
SER  Serial enabled forever
FFS flash file system mounting ... wait ...
FFS flash file system mounted
STATE uses a built-in LED
RFTX RF transmitter driver configured
RFRX RF receiver driver configured
DHT DHT driver configured
SOUND Sound driver configured
COM K interpreter loaded
COM automatic 'start'
WIFI WiFi connection to 'MYSSID' enabled
] ..................................................
WIFI  connected with IP: 192.168.1.34
NTP connecting to 0.it.pool.ntp.org
NTP date and time updated 01-08-2017 13:28:02
OTA Check firmware update            

2. OTA check: new firmware version found

3. Download starts and after about 40 seconds it resets

 ets Jan  8 2013,rst cause:2, boot mode:(3,6)
load 0x4010f000, len 1384, room 16 
tail 8
chksum 0x2d
csum 0x2d
v3de0c112
@cp:0
ld
βΈ®

4. and restarts with new firmware version v.7.27.74

Smick v.7.27.74 (C) Copyright 2017 by Curci     
SER Serial enabled forever
FFS flash file system mounting ... wait ...
FFS flash file system mounted

...

How to manage OTA update

You can use the otaupd parameter and the ota and fota commands.

If you set otaupd=0, the OTA update will never happen.

If you set otaupd=k, the OTA update will automatically be requested every k minutes.

With the ota command you can request the update immediately:

] ota
OTA  Check firmware update
OTA no updates
ok

If there are no updates you will get the above answer.

To force the firmware update with the latest available version use the fota command:

] fota
OTA  Check firmware update

 ets Jan  8 2013,rst cause:2, boot mode:(3,6)

load 0x4010f000, len 1384, room 16 
...