Thanks, i could get it (nearly) working with the double definition of the signal in the guide (which is ugly because not orthogonal) and the clear/set function.
The build and PE build works without warnings/errors.
But the debugger starts with some errors:
SEGGER J-Link GDB Server V5.00d Command Line Version
JLinkARM.dll V5.00d (DLL compiled Jun 17 2015 22:33:29)
-----GDB Server start settings-----
GDBInit file: none
GDB Server Listening port: 2331
SWO raw output listening port: 2332
Terminal I/O port: 2333
Accept remote connection: localhost only
Generate logfile: off
Verify download: on
Init regs on start: on
Silent mode: off
Single run mode: on
Target connection timeout: 0 ms
------J-Link related settings------
J-Link Host interface: USB
J-Link script: none
J-Link settings file: none
------Target related settings------
Target device: Cortex-M4
Target interface: SWD
Target interface speed: 1000kHz
Target endian: little
Connecting to J-Link...
J-Link is connected.
Firmware: J-Link V9 compiled May 22 2015 17:20:50
Hardware: V9.30
S/N: 269300706
OEM: SEGGER-EDU
Feature(s): FlashBP, GDB
Checking target voltage...
Target voltage: 3.28 V
Listening on TCP/IP port 2331
Connecting to target...Connected to target
Waiting for GDB connection...Connected to 127.0.0.1
Reading all registers
Read 4 bytes @ address 0x00000000 (Data = 0x20008000)
Target interface speed set to 1000 kHz
Resetting target
Halting target CPU...
...Target halted (PC = 0x000004D8)
R0 = 00000000, R1 = 00000000, R2 = 00000000, R3 = 00000000
R4 = 00000000, R5 = 00000000, R6 = 00000000, R7 = 00000000
R8 = 00000000, R9 = 00000000, R10= 00000000, R11= 00000000
R12= 00000000, R13= 20008000, MSP= 20008000, PSP= 00000000
R14(LR) = FFFFFFFF, R15(PC) = 000004D8
XPSR 01000000, APSR 00000000, EPSR 01000000, IPSR 00000000
CFBP 00000000, CONTROL 00, FAULTMASK 00, BASEPRI 00, PRIMASK 00
Reading all registers
Select auto target interface speed (2000 kHz)
Flash breakpoints enabled
Semi-hosting enabled (VectorAddr = 0x08)
Semihosting I/O set to TELNET Client
SWO disabled succesfully.
ERROR: CPU clock frequency detection is not supported for this device!
Failed to enable SWO. Could not measure target CPU frequency.
Downloading 480 bytes @ address 0x00000000 - Verify failed
Downloading 16 bytes @ address 0x00000400 - Verify failed
Downloading 1720 bytes @ address 0x00000410 - Verify failed
Downloading 8 bytes @ address 0x00000AC8 - Verify failed
Downloading 4 bytes @ address 0x00000AD0 - Verify failed
Downloading 4 bytes @ address 0x00000AD4 - Verify failed
Downloading 96 bytes @ address 0x00000AD8 - Verify failed
Downloading 36 bytes @ address 0x00000B38 - Verify failed
Writing register (PC = 0x000006d4)
Read 4 bytes @ address 0x000006D4 (Data = 0xFA270320)
Resetting target
Halting target CPU...
...Target halted (PC = 0x000004D8)
Read 2 bytes @ address 0x000004DE (Data = 0xF001)
Read 2 bytes @ address 0x000004DE (Data = 0xF001)
Read 2 bytes @ address 0x000004DE (Data = 0xF001)
R0 = 00000000, R1 = 00000000, R2 = 00000000, R3 = 00000000
R4 = 00000000, R5 = 00000000, R6 = 00000000, R7 = 00000000
R8 = 00000000, R9 = 00000000, R10= 00000000, R11= 00000000
R12= 00000000, R13= 20008000, MSP= 20008000, PSP= 00000000
R14(LR) = FFFFFFFF, R15(PC) = 000004D8
XPSR 01000000, APSR 00000000, EPSR 01000000, IPSR 00000000
CFBP 00000000, CONTROL 00, FAULTMASK 00, BASEPRI 00, PRIMASK 00
Reading all registers
Read 4 bytes @ address 0x000004D8 (Data = 0xF001B672)
Setting breakpoint @ address 0x000004DE, Size = 2, BPHandle = 0x0002
Starting target CPU...
And the debugger always stops at main, at
/* Write your code here */
LED0_ON;
with the define in the header:
#define LED0_ON GPIO1_ClearPortBits(NULL, GPIO1_LED0_MASK);
Is it impossible do debug with the MK60DNZVLL10?