Firmware Update over Bluetooth LE
Hi All: Here's a proposed plan for supporting PineTime firmware updates over Bluetooth LE. If you're a firmware developer, please take a look...

It covers everything we need to do to implement firmware updates in our firmware: Bootloader, Bluetooth Stack, Firmware Rollback, Flash ROM Layout, Firmware Format, Mobile Apps, ...

We need to adopt a common mechanism for firmware updates if we wish to allow PineTime Owners to switch firmware easily. It's more work for us developers... But it's a huge benefit for PineTime Owners!

Please lemme know what you think... While writing this article I have received really good feedback from firmware developers. Their suggestions have been documented in the "Upcoming Enhancements" section.

The most serious limitation in the proposed design is that the firmware size must not exceed 232 KB. Hence there will be an upcoming enhancement to increase this limit (by moving the Standby Firmware Image to External SPI Flash).

Thanks everyone for the awesome work on PineTime... Now let's make PineTime fun and easy to learn and explore! :-)
Just updating everyone on my MCUBoot Bootloader progress:

(1) Yep it's possible to move the Standby Firmware Image to SPI Flash. Now testing this

(2) This solves a major showstopper with MCUBoot. We now allow application firmware images of up to 464 KB in size

(3) Now putting in a 5 second delay when MCUBoot starts up. If the watch button is pressed and held during the 5 seconds, MCUBoot will roll back the firmware to the previous one

(4) MCUBoot now displays a graphic image stored in SPI Flash while booting. This is needed because we have to show something during the 5 second delay. Also when MCUBoot swaps firmware during upgrade

(5) I have created a tool that loads a 240x240 PNG file into SPI Flash for display by MCUBoot:

So my job this weekend is to do more testing of MCUBoot with SPI Flash

And there shall be a new article to explains how all the above stuff works. So that someone can back me up on the MCUBoot development :-)

Attached Files
.jpg   pinetime-graphic-photo2-small.jpg (Size: 424.73 KB / Downloads: 194)
Here's a video of the Enhanced MCUBoot Bootloader that displays the boot graphic stored in SPI Flash...

Sent from my Pixel 4 XL using Tapatalk

Possibly Related Threads…
Thread Author Replies Views Last Post
  bluetooth GATT questions wilsonjw 2 171 07-08-2021, 08:33 PM
Last Post: wilsonjw
  Update bootlogo and pinetime-app with OTA/DFU lookin 3 1,924 11-25-2020, 04:51 PM
Last Post: lookin
  Article: Bluetooth Time Sync and LVGL on PineTime Mynewt lupyuen 0 905 10-15-2020, 05:51 PM
Last Post: lupyuen
  Remote PineTime for flashing and testing firmware remotely lupyuen 5 2,284 10-06-2020, 12:03 AM
Last Post: lupyuen
  FreeRTOS, RIOT, Mynewt and wasp-os Firmware now auto-building with GitHub Actions lupyuen 1 1,435 08-01-2020, 09:10 AM
Last Post: lupyuen
Information PineTime Updater for Flashing New Bootloader and FreeRTOS Firmware lupyuen 2 1,887 07-31-2020, 05:10 PM
Last Post: lupyuen
  Build PineTime Firmware in the Cloud lupyuen 3 2,344 07-27-2020, 04:54 PM
Last Post: lupyuen
  DaFit Stock Firmware extract for TBH3 TheFuschl 1 1,771 07-03-2020, 07:55 AM
Last Post: sqrtroot
  Article: Your First Bluetooth Low Energy App with Flutter lupyuen 0 1,315 06-03-2020, 05:44 PM
Last Post: lupyuen
  Article: Wireless Firmware Update In Action on PineTime lupyuen 0 945 05-20-2020, 06:03 AM
Last Post: lupyuen

Forum Jump:

Users browsing this thread: 1 Guest(s)