MCUXpresso and MCU-LINK PRO in J-Link emulation mode will not flash i.MX RT1062

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

MCUXpresso and MCU-LINK PRO in J-Link emulation mode will not flash i.MX RT1062

678 Views
Gra67
Contributor III

Hello,

I wonder if anyone could help me get my MCUXpresso and an MCU-LINK_PRO in J-Link emulation mode to flash and debug my CoM board.

I definitely had this working a few years ago but can't remember the MCUXpresso version.

 

Versions used

Processor: Embedded Artist’s i.MX RT1062 OEM (uses a 32 Mbit ATXP032 OctalSPI flash).

IDE: MCUXpresso V24.12.148

Debug Probe: MCU-LINK_PRO, connected to the CoM board via SWD.

 

Using the above I can build and debug code using the MCU-LINK_PRO probe running V3.153.

However, if I convert the probe to a J-Link, by running “program_JLINK.cmd script” from MCU-LINK_installer 3.153, to make it emulate a J-Link device, it consistently fails to write to flash and therefore debug. I deleted all the debug launch files to allow MCUXpresso to create the j-link configuration automatically, as suggested by IDE guide.

I then tried using the latest driver from Segger “V8.12e” instead of the one bundled with the IDE. On the first debug attempt the Segger driver updated the MCU-LINK_PRO to Seggers’s latest firmware for the connected emulator. However, it still does not work. Repeated builds and debugging do not bring up the flashing window and the output from Debugger Console is as below.

Gra67_0-1739886774969.png

I can use Segger’s JLink.exe to connect to CoM board and get all the RT1062 information.

A short-term fix is to use “https://github.com/JayHeng/NXP-MCUBootUtility” to attach serially and erase the flash. Then a build and debug work perfectly. But the following build and debug fails as before. According to a post I found here: Solved: RT1064+Jlink debug issue - NXP Community the symptoms imply an issue with my code, but I can’t see what would do this. I’ve even removed areas I thought could cause this.

I have reconfigured the flexRAM, as below, but the code runs directly from flash, so I can't see this being an issue.

Gra67_1-1739886938748.png

 

Does anyone have any other ideas I can try? I want to switch to using the Segger debug probes, but I don't want to risk buying one if I can't get this working.

 

Many thanks

Graeme

 

0 Kudos
Reply
2 Replies

657 Views
EdwinHz
NXP TechSupport
NXP TechSupport

Hi @Gra67,

Does this issue also happen on your side with the SDK's example codes? I tried it on my side with the EVKB and I saw no issues on MCUXpresso 24.12.148. I would say it is likely an issue with your code as well, which is why you can recover the debug session once using MCU Boot Utility or Secure Provisioning Tool, and after flashing your code again, the issue appears once again.

BR,
Edwin.

0 Kudos
Reply

630 Views
Gra67
Contributor III

Hi Edwin

I've just gone back to Embedded Artist’s latest SDK for our board and built the "hello world" example. It does exactly the same, as in I need to wipe the flash between successful debugging.

Good idea though, simplifies the issue reporting.

Thanks,

Graeme

 

0 Kudos
Reply