Yonder D51
The ATSAMD51 is an ARM Cortex-M4F microcontroller manufactured by Microchip (Atmel).
As of Oct 13 2019, -> CBA ❤️ D51 <-
Circuits using the D51
Bare(ish) Metal Toolchains
Bootloader Based Toolchains
Since Adafruit has adopted the SAMD51, it is well supported by the open source community, and we can borrow their development tools. For instructions on how to burn your board with a bootloader, see the bootloader directory.
Once you've got a bootloader on your board, you have a lot of options for programming it.
Platformio
To write code and load it, Jake uses PlatformIO, which is an open source 'IOT' (embedded) programming tool written as a package for either atom code-editor, or vscode. See their doc for setting up a new project for the D51 / Feather M4.
Arduino IDE
We're not going to beat Adafruit's documentation on setting up the Arduino IDE, so just take a gander over here. It's their bootloader, after all. An example sketch lives in the blink-arduino directory.
Real Registers in an Arduino World
One of the troubles with Arduino is that people forget that it is just a big C++ library. This means that everything under the sun (that compiles) is legal here. That means that we can use Arduino as a crutch, but write really nice Special Function Register code inside of the same executable. Great!
Indeed, in the PlatformIO environment, we even have wonderful autocomplete handles on the D51's core register map. For some examples of this kind of manipulation, check out the hunks
in the ponyo project.