samd21: Initial support for SAMD21 micro-controllers

Add initial support for the Atmel SAMD21 micro-controllers.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor
2018-07-27 19:22:44 -04:00
parent 71db5fbe31
commit 74cf4dc9e0
9 changed files with 351 additions and 0 deletions

41
src/samd21/Kconfig Normal file
View File

@@ -0,0 +1,41 @@
# Kconfig settings for SAMD21 processors
if MACH_SAMD21
config SAMD_SELECT
bool
default y
config BOARD_DIRECTORY
string
default "samd21"
config CLOCK_FREQ
int
default 48000000
choice
prompt "Bootloader offset"
config FLASH_START_0000
bool "No bootloader"
config FLASH_START_2000
bool "2K bootloader (Arduino Zero)"
config FLASH_START_4000
bool "4K bootloader (Arduino M0)"
endchoice
config FLASH_START
hex
default 0x4000 if FLASH_START_4000
default 0x2000 if FLASH_START_2000
default 0x0000
config SERIAL
bool
default y
config SERIAL_BAUD
depends on SERIAL
int "Baud rate for serial port"
default 250000
endif