Can I reconnect to MK64FN1M0XXX12 after accidentally reconfiguring debug pin?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Can I reconnect to MK64FN1M0XXX12 after accidentally reconfiguring debug pin?

1,040 Views
apg
Contributor II

I was able to flash my MK64FN1M0xxx12 MCU using JLink until I flashed some sample code which seems to reconfigure one of the pins used for the debug connection. Is there any way to reset the pins without being able to connect?

The JLink commander error:

Device "MK64FN1M0XXX12" selected.

 

Connecting to target via JTAG

InitTarget()

Connect Under Reset

Connect Under Reset

Connect failed. Resetting via Reset pin and trying again.

InitTarget()

Connect Under Reset

Connect Under Reset

 

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

 

InitTarget()

Connect Under Reset

Connect Under Reset

Connect failed. Resetting via Reset pin and trying again.

InitTarget()

Connect Under Reset

Connect Under Reset

 

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

 

Cannot connect to target.

0 Kudos
7 Replies

1,033 Views
ErichStyger
Senior Contributor V

You might try the approach described in https://mcuoneclipse.com/2022/06/16/resurrecting-bricked-nxp-kinetis-devices/

The 'Resurrect' of the J-Link might help, but I hope you have a P&E Multilink which has a dedicated recovery tool which helped me in similar cases.

Erich

1,031 Views
apg
Contributor II

Thanks. Unfortunately the resurrect feature fails to connect too. I don't have access to a Multilink. Could there be a way to achieve the Multilink power glitch technique with the J-Link?

0 Kudos

1,029 Views
ErichStyger
Senior Contributor V

You might try to press the reset buttons at the right moment while connecting. Chances are probably low, but just give it a try.

1,028 Views
ErichStyger
Senior Contributor V

The other idea is: the K64 has a EZ port (kind of bootloading through SPI). You might have a look at that one too.

1,017 Views
apg
Contributor II

For completeness, is the only way my device could not connect under reset if the reset pin had been re-assigned somehow? Looking closer at the code I don't see anything that should have caused the problem (some pin configurations but not touching the debug pins), but it seems like reassigning the pins was the only thing which could have caused this.

0 Kudos

1,013 Views
ErichStyger
Senior Contributor V

Basically there could be many things: from power supply issues, cable/connection issues up to problems on the device itself. Basically usually the debug probe finds out that the device is not responding. I had cases where the debug probe cable had an issue, others with USB cable issues, yet others with devices damaged by ESD somehow, up to locked devices because of security/flash configuration settings. Debug pins disabled is just one thing. Having the reset pin disabled is usually not an issue as long the debug interface is still responsive.

0 Kudos

1,035 Views
apg
Contributor II

The J-Link console:

0 Kudos