How to flash bootloader to ATSAMD board?

Discussion and questions about boards that can run MicroPython but don't have a dedicated forum.
Target audience: Everyone interested in running MicroPython on other hardware.
Post Reply
User avatar
water
Posts: 75
Joined: Sun Sep 24, 2017 9:16 am

How to flash bootloader to ATSAMD board?

Post by water » Fri May 06, 2022 8:03 pm

I want to flash MicroPython .uf2 firmware to ATSAMD board, is it have specific MicroPython version of bootloader? how?

Or can I refer this:
https://github.com/adafruit/uf2-samdx1/ ... -README.md
To flash CircuitPython bootloader, then use the bootloader to flash MicroPython firmware?

Or if I use J-Link to flash .bin firmware to ATSAMD board, which address should I specific (SAMD21, SAMD51)?

User avatar
Roberthh
Posts: 3359
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: How to flash bootloader to ATSAMD board?

Post by Roberthh » Sat May 07, 2022 6:28 am

The data sheet tells_:
After Reset has been released, the CPU starts fetching PC and SP values from the Reset address, 0x00000000. This points to the first executable address in the internal Flash memory.
The lowest area of the Flash is usually reserved for a bootloader. The MicroPython firmware is built to start at 0x2000 for SAMD21 and 0x4000 for SAMD51.

User avatar
water
Posts: 75
Joined: Sun Sep 24, 2017 9:16 am

Re: How to flash bootloader to ATSAMD board?

Post by water » Sun May 08, 2022 7:03 pm

Thanks, that works.
And I try flash Adafruit UF2 bootloader to 0x0000, then flash MicroPython .uf2 firmware seems fine.

Post Reply