AnsweredAssumed Answered

Flasing externally generated hex - KL02z

Question asked by Simon Ansley on Sep 11, 2017
Latest reply on Sep 12, 2017 by Simon Ansley

I'm trying to find a free flashing solution for an MKL02Z32V processor.

I'm using a FRDM-KL02Z board as the SWD interface to my own board.

I have an externally generated hex file (built with Rowley Crossworks, I can download and debug using their tools, using the CMSIS-DAP driver. Application code is working fine.

I have followed the instructions in Flash from File: Downloading a file without the sources , having created an empty project targetted at the MKL02Z32V. GDB appears to connect to the debugger, but always crashes giving a Windows error box 'arm-none-eabi-gdb.exe has stopped working,  with the following crash details:

 

Problem signature:
Problem Event Name: APPCRASH
Application Name: arm-none-eabi-gdb.exe
Application Version: 0.0.0.0
Application Timestamp: 53e000a7
Fault Module Name: msvcrt.dll
Fault Module Version: 7.0.7601.17744
Fault Module Timestamp: 4eeaf722
Exception Code: c0000005
Exception Offset: 000143f9
OS Version: 6.1.7601.2.1.0.256.48
Locale ID: 2057
Additional Information 1: 0a9e
Additional Information 2: 0a9e372d3b4ad19135b953a78882e789
Additional Information 3: 0a9e
Additional Information 4: 0a9e372d3b4ad19135b953a78882e789

Output from the console window is below for reference.

 

Any idea what I'm missing / doing wrong?

 

Thanks,

 

sca

 

Open On-Chip Debugger 0.8.0-dev (2015-01-09-16:22)
Licensed under GNU GPL v2
For bug reports, read
    http://openocd.sourceforge.net/doc/doxygen/bugs.html
Info : only one transport option; autoselect 'cmsis-dap'
Info : CMSIS-DAP: SWD  Supported
Info : CMSIS-DAP: Interface Initialised (SWD)
Info : add flash_bank kinetis kinetis.flash
cortex_m reset_config sysresetreq
adapter speed: 1000 kHz
Started by GNU ARM Eclipse
Info : CMSIS-DAP: FW Version = 1.0
Info : SWCLK/TCK = 0 SWDIO/TMS = 1 TDI = 0 TDO = 0 nTRST = 0 nRESET = 1
Info : DAP_SWJ Sequence (reset: 50+ '1' followed by 0)
Info : CMSIS-DAP: Interface ready
Info : clock speed 1000 kHz
Info : IDCODE 0x0bc11477
Info : kinetis.cpu: hardware has 2 breakpoints, 2 watchpoints
Info : accepting 'gdb' connection from 3333
Info : Probing flash info for bank 0
Warn : acknowledgment received, but no packet pending
undefined debug reason 7 - target needs reset
target state: halted
target halted due to debug-request, current mode: Thread
xPSR: 0x41000000 pc: 0x00000568 msp: 0x20000470
semihosting is enabled
Warn : Any changes to flash configuration field will not take effect until next reset
Warn : Kinetis L Series supports Program Longword execution only.
Info : Kinetis: FLASH Write ...
target state: halted
target halted due to debug-request, current mode: Thread
xPSR: 0x61000000 pc: 0x00000568 msp: 0x20000470, semihosting
===== arm v7m registers
(0) r0 (/32): 0x2000004C
(1) r1 (/32): 0x00003800
(2) r2 (/32): 0x00000125
(3) r3 (/32): 0x00000125
(4) r4 (/32): 0x200004E0
(5) r5 (/32): 0x40020000
(6) r6 (/32): 0x00003C94
(7) r7 (/32): 0xFFFFFF80
(8) r8 (/32): 0x00000000
(9) r9 (/32): 0x00000000
(10) r10 (/32): 0x00000000
(11) r11 (/32): 0x00000000
(12) r12 (/32): 0x20000250
(13) sp (/32): 0x20000470
(14) lr (/32): 0x00001CC1
(15) pc (/32): 0x00000568
(16) xPSR (/32): 0x61000000
(17) msp (/32): 0x20000470
(18) psp (/32): 0x00000000
(19) primask (/1): 0x00
(20) basepri (/8): 0x00
(21) faultmask (/1): 0x00
(22) control (/2): 0x00
===== Cortex-M DWT registers
(23) dwt_ctrl (/32)
(24) dwt_cyccnt (/32)
(25) dwt_0_comp (/32)
(26) dwt_0_mask (/4)
(27) dwt_0_function (/32)
(28) dwt_1_comp (/32)
(29) dwt_1_mask (/4)
(30) dwt_1_function (/32)
Info : dropped 'gdb' connection
target state: halted
target halted due to debug-request, current mode: Handler External Interrupt(18)
xPSR: 0x01000022 pc: 0x00001b7c msp: 0x20000408, semihosting

Outcomes