From: Gaëtan C. <gc...@gm...> - 2014-09-04 14:53:31
|
Hello, I have problems when trying to flash the TWRK70F120M board from Freescale using J-Link probe with OpenOCD version 0.9.0-dev-00131-gbd0409a. Here is my script: $ openocd -d0 \ -f interface/jlink.cfg \ -c "transport select jtag" \ -f board/twr-k60f120m.cfg \ -c "adapter_khz 400" \ -c init \ -c "reset init" \ -c "reset halt" \ -c "sleep 500" \ -c "flash probe 0" \ -c "kinetis mdm mass_erase 0" \ -c "reset halt" \ -c "sleep 500" \ -c "flash write_bank 0 app.bin 0" \ -c "reset halt" \ -c "verify_image app.bin 0" And the when verifying (very slow), i have this error (full log at the end): ... wrote 524288 bytes from file app.bin to flash bank 0 at offset 0x00000000 in 21.998293s (23.275 KiB/s) Error: timed out while waiting for target halted target state: halted target halted due to debug-request, current mode: Thread xPSR: 0xa1000000 pc: 0x0000511c psp: 0x1fff4bf8 Error: error executing cortex_m crc algorithm verified 524288 bytes in 65.222839s (7.850 KiB/s) ... If I shutdown script just after "flash write" command, board stay halted. But when verify_image command is issued/started, the board is reset and application is runinng until "Error: timed out" appears. Even with a "reset halt" after "flash write" command, the error occurs. I used the patched version of k60.cfg with SRAM area enabled (http://openocd.zylin.com/2277) Thank you for your help, Regards, Gaëtan Carlier. log: Open On-Chip Debugger 0.9.0-dev-00131-gbd0409a (2014-08-29-12:56) Licensed under GNU GPL v2 For bug reports, read http://openocd.sourceforge.net/doc/doxygen/bugs.html debug_level: 0 xsvf cortex_m reset_config sysresetreq adapter speed: 400 kHz START... END... START... END... target state: halted target halted due to debug-request, current mode: Thread xPSR: 0x01000000 pc: 0x00000420 msp: 0x2000fef0 -event reset-init occured START... END... target state: halted target halted due to debug-request, current mode: Thread xPSR: 0x01000000 pc: 0x00000420 msp: 0x2000fef0 flash 'kinetis' found at 0x00000000 START... END... target state: halted target halted due to debug-request, current mode: Thread xPSR: 0x01000000 pc: 0xfffffffe msp: 0xfffffffc wrote 524288 bytes from file app.bin to flash bank 0 at offset 0x00000000 in 21.998293s (23.275 KiB/s) Error: timed out while waiting for target halted target state: halted target halted due to debug-request, current mode: Thread xPSR: 0xa1000000 pc: 0x0000511c psp: 0x1fff4bf8 Error: error executing cortex_m crc algorithm verified 524288 bytes in 65.222839s (7.850 KiB/s) shutdown command invoked |