Hi Loboris,loboris wrote: ↑Sun Nov 18, 2018 10:56 ambrp80000 wrote: ↑Sun Nov 18, 2018 7:02 amPlease explain that contains the "factory"...
OTA_0 and OTA_1 contain alternately updating the firmware.
As I understand it, in the "factory" area you can write a simple initial firmware, which will be loaded into the OTA_0 area.
If a piece of the program from OTA_0 in the future will start the firmware update it will be located in OTA_1. Continue alternating OTA_0 and OTA_1.
Is the "factory" area no longer used?
You can use OTA_0 and OTA_1 without factory partition.
If the factory partition is used, the the code will run from it only until the 1st OTA upgrade, after that, the code will run from OTA_0 or OTA_1, whichever was updated last.
If both OTA_0 and OTA_1 gets corrupted, the code will run from factory partition again.
You can force running from factory partition (or ota partition different from the currently active partition) from application code or from the 2nd stage bootloader.
You can upgrade your factory partition while running from one of the OTA partitions by slightly modifying the the OTA upgrade code.
So, If we create two OTA partion then default firmware will be started from default partition. Then we can update firmware between 2 OTA partirion. So, Default partition will be used to keep safe image in case both OTA partion will be failed to boot firmware image. Also we can update default partition as well to keep sync it with updated image from OTA 0 or OTA 1 partitions based on firmware running state.
Let me correct if I am wrong at any place.