diff options
| author | JF <jf@codingfield.com> | 2020-09-26 15:09:24 (GMT) |
|---|---|---|
| committer | Gitea <gitea@fake.local> | 2020-09-26 15:09:24 (GMT) |
| commit | b6a910e52ed98b662e6586f45cfe9c6997f8f158 (patch) | |
| tree | d74185cbf682cde40e5de5bfa2f620ae201565a9 /doc/bootloader | |
| parent | be05997272b7b1d1b25b122c8162ac6f4c1c12a2 (diff) | |
| parent | 3e612e79ba82bac69258094d468c996c41b29612 (diff) | |
Merge branch 'develop' of JF/PineTime into master
Diffstat (limited to 'doc/bootloader')
| -rw-r--r-- | doc/bootloader/boot.png | bin | 0 -> 22268 bytes | |||
| -rw-r--r-- | doc/bootloader/boot.puml | 19 | ||||
| -rw-r--r-- | doc/bootloader/recover.png | bin | 0 -> 24165 bytes | |||
| -rw-r--r-- | doc/bootloader/recover.puml | 17 | ||||
| -rw-r--r-- | doc/bootloader/upgrade.png | bin | 0 -> 38616 bytes | |||
| -rw-r--r-- | doc/bootloader/upgrade.puml | 21 |
6 files changed, 57 insertions, 0 deletions
diff --git a/doc/bootloader/boot.png b/doc/bootloader/boot.png Binary files differnew file mode 100644 index 0000000..713f715 --- /dev/null +++ b/doc/bootloader/boot.png diff --git a/doc/bootloader/boot.puml b/doc/bootloader/boot.puml new file mode 100644 index 0000000..00790d7 --- /dev/null +++ b/doc/bootloader/boot.puml @@ -0,0 +1,19 @@ +@startuml + +MCU -> Bootloader: reset +activate Bootloader +Bootloader -> Bootloader: Recover? (no) +Bootloader -> Bootloader: New version? (no) +Bootloader -> Application: Jump to primary slot +deactivate Bootloader + +activate Application +note right: This is the current version of the firmware +Application -> Application: OTA procedure +note right: Download a new firmware version and\n store it in secondary slot +Application -> MCU: Reset +deactivate Application + + + +@enduml
\ No newline at end of file diff --git a/doc/bootloader/recover.png b/doc/bootloader/recover.png Binary files differnew file mode 100644 index 0000000..6c6a940 --- /dev/null +++ b/doc/bootloader/recover.png diff --git a/doc/bootloader/recover.puml b/doc/bootloader/recover.puml new file mode 100644 index 0000000..3f5bafb --- /dev/null +++ b/doc/bootloader/recover.puml @@ -0,0 +1,17 @@ +@startuml + +MCU -> Bootloader: reset +activate Bootloader +Bootloader -> Bootloader: Recover? (yes) +Bootloader -> Bootloader: Restore previous firmware +note left: Copy the previous firmware from secondary to primary slot +Bootloader -> Application: Jump to primary slot +deactivate Bootloader + +activate Application +note right: This is the previous version\nof the firmware +Application -> Application: Normal Operation +Application -> MCU: Reset +deactivate Application + +@enduml
\ No newline at end of file diff --git a/doc/bootloader/upgrade.png b/doc/bootloader/upgrade.png Binary files differnew file mode 100644 index 0000000..ac77d42 --- /dev/null +++ b/doc/bootloader/upgrade.png diff --git a/doc/bootloader/upgrade.puml b/doc/bootloader/upgrade.puml new file mode 100644 index 0000000..c31b911 --- /dev/null +++ b/doc/bootloader/upgrade.puml @@ -0,0 +1,21 @@ +@startuml + +MCU -> Bootloader: reset +activate Bootloader +Bootloader -> Bootloader: Recover? (no) +Bootloader -> Bootloader: New version? (yes) +Bootloader -> Bootloader: Swap firmwares +note left: Copy current firmware from primary to secondary\nand copy the new firmware from secondary to primary +Bootloader -> Application: Jump to primary slot +deactivate Bootloader + + +activate Application +note right: This is the new version of the firmware +Application -> Application: Write the valid bit in flash memory +note right: The application should provide a way to\ncheck that it is running correctly\n(selftest, user confirmation,...)\nbefore setting the valid bit. +Application -> Application: Normal operations... +Application -> MCU: Reset +deactivate Application + +@enduml
\ No newline at end of file |
