source [find interface/stlink.cfg]
transport select hla_swd
# source [find interface/cmsis-dap.cfg]
# transport select swd

adapter speed 400

# Reset handling for proper halt
# reset_config srst_nogate connect_assert_srst

#set WORKAREASIZE 0x4000
set CPUTAPID 0x0bc11477
set CHIPNAME at91samd21g18
source [find target/at91samdXX.cfg]

# Ensure halt and allow manual debugging
# init
# halt
# at91samd chip-erase