Hello,
I've been using Arduino M0 (ATSAMD21G18 ) with SEGGER-EDU to test cortex-m0 feature. This time I want to debug the code with Atmel Studio. As soon as debugging process is started, I have an error message "Programming failed".
Now I try to restore bootloader back but the same error again. I've tried to use SEGGER J-Link Commander as suggested by 2016-08-17 Successful JLinkExe session flashing Adafruit Feather M0.txt of [SOLVED] Loadfile fails using JLink with Adafruit Feather M0, it seems to ok with connection but programming failed. Here is log from J-Link Commander
Any suggestion is greatly appreciated.
pak
I've been using Arduino M0 (ATSAMD21G18 ) with SEGGER-EDU to test cortex-m0 feature. This time I want to debug the code with Atmel Studio. As soon as debugging process is started, I have an error message "Programming failed".
Now I try to restore bootloader back but the same error again. I've tried to use SEGGER J-Link Commander as suggested by 2016-08-17 Successful JLinkExe session flashing Adafruit Feather M0.txt of [SOLVED] Loadfile fails using JLink with Adafruit Feather M0, it seems to ok with connection but programming failed. Here is log from J-Link Commander
SEGGER J-Link Commander V6.18d (Compiled Sep 1 2017 18:30:35)
DLL version V6.18d, compiled Sep 1 2017 18:29:59
Connecting to J-Link via USB...O.K.
Firmware: J-Link ARM V8 compiled Nov 28 2014 13:44:46
Hardware version: V8.00
S/N: xxxxxxx
License(s): FlashBP, GDB
OEM: SEGGER-EDU
VTref = 3.170V
Type "connect" to establish a target connection, '?' for help
J-Link>connect
Please specify device / core. <Default>: Unspecified
Type '?' for selection dialog
Device>ATSAMD21G18
Please specify target interface:
J) JTAG (Default)
S) SWD
TIF>s
Specify target interface speed [kHz]. <Default>: 4000 kHz
Speed>1000 kHz
Device "ATSAMD21G18" selected.
Connecting to target via SWD
Found SW-DP with ID 0x0BC11477
Found SW-DP with ID 0x0BC11477
Scanning AP map to find all available APs
AP[1]: Stopped AP scan as end of AP map has been reached
AP[0]: AHB-AP (IDR: 0x04770031)
Iterating through AP map to find AHB-AP to use
AP[0]: Core found
AP[0]: AHB-AP ROM base: 0x41003000
CPUID register: 0x410CC601. Implementer code: 0x41 (ARM)
Found Cortex-M0 r0p1, Little endian.
FPUnit: 4 code (BP) slots and 0 literal slots
CoreSight components:
ROMTbl[0] @ 41003000
ROMTbl[0][0]: E00FF000, CID: B105100D, PID: 000BB4C0 ROM Table
ROMTbl[1] @ E00FF000
ROMTbl[1][0]: E000E000, CID: B105E00D, PID: 000BB008 SCS
ROMTbl[1][1]: E0001000, CID: B105E00D, PID: 000BB00A DWT
ROMTbl[1][2]: E0002000, CID: B105E00D, PID: 000BB00B FPB
ROMTbl[0][1]: 41006000, CID: B105900D, PID: 001BB932 MTB-M0+
Cortex-M0 identified.
J-Link>loadfile D:\featherm0bootloader_160305.hex
Downloading file [D:\featherm0bootloader_160305.hex]...
J-Link: Flash download: Restarting flash programming due to program error (possibly skipped erasure of half-way erased sector).
J-Link: Flash download: Skip optimizations disabled for second try.
Error while programming flash: Programming failed.
Any suggestion is greatly appreciated.
pak
The post was edited 2 times, last by paksoft ().