AnsweredAssumed Answered

KW41Z J-LINK Error PCode -1 cannot connect under reset

Question asked by Nick Powers on Jan 9, 2020
Latest reply on Jan 13, 2020 by Mario Ignacio Castaneda Lopez

I have an Arrow SmartEverything MCS27561-TIGER board with a Kinetis KW41Z512VHT4 which I have been using with MCUXpresso IDE 11.1 and had luck getting it to program the "hello world" example and "bluetooth beacon freertos" example via a J-LINK mini on port J10. I went to program the "bluetooth ble shell freertos example" and the red LED connected to KW41 PTC1 continuously flashes and I can no longer connect to the board with the J-LINK.

 

J-LINK commander initiates a Connect Under Reset and I notice the RGB LED plash green for a moment then back to flashing red and J-LINK commander error's out with "Error: InitTarget(): PCode returned with error code -1".

 

Is there a way to wipe the KW41 to a blank slate or for a flash mode?

 

Thanks,

~Nick

 

Full J-LINK Commander output below:

SEGGER J-Link Commander V6.54c (Compiled Nov 7 2019 17:01:56)
DLL version V6.54c, compiled Nov 7 2019 17:01:02

Connecting to J-Link via USB...O.K.
Firmware: J-Link EDU Mini V1 compiled Oct 22 2019 16:28:45
Hardware version: V1.00
S/N: 801009322
License(s): FlashBP, GDB
VTref=1.813V


Type "connect" to establish a target connection, '?' for help
J-Link>connect
Please specify device / core. <Default>: MKW41Z512XXX4
Type '?' for selection dialog
Device>
Please specify target interface:
J) JTAG (Default)
S) SWD
T) cJTAG
TIF>S
Specify target interface speed [kHz]. <Default>: 4000 kHz
Speed>
Device "MKW41Z512XXX4" selected.


Connecting to target via SWD
InitTarget()
Connect Under Reset
Connect Under Reset
InitTarget()
Connect Under Reset
Connect Under Reset

****** Error: InitTarget(): PCode returned with error code -1

InitTarget()
Connect Under Reset
Connect Under Reset
InitTarget()
Connect Under Reset
Connect Under Reset

****** Error: InitTarget(): PCode returned with error code -1

Cannot connect to target.

Outcomes