PEMicro MU unable to write RT1020 QSPI FLASH

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

PEMicro MU unable to write RT1020 QSPI FLASH

1,037 Views
gtalocchino
Contributor II

We have a custom board using MIMXRT1021CAG4A connected to a ISSI IS25LP064A NOR serial flash memory (same as EVK for RT1020). We have debugged the example called "flexspi_nor_polling_transfer" provided in the SDK for the EVK first to set the QE bit. Image with the console output seems OK and id vendor matches.

sdk example.png

Then, we tried to debug the blinking led example in the FLASH but when the session starts it crashes because memory is erased and never programmed (assumed seeing all 0xFF  in  dissasembly window). Image attached with a breakpoint in ResetISR.

rt1020.png

When we tried using the GUI FLASH tool in the IDE we have this output:

Executing flash operation 'Program' (Program file into flash: evkmimxrt1020_blinking_led_iled_blinky.axf) - Thu Mar 31 10:29:36 ART 2022
Checking MCU info...
Scanning for targets...
Executing flash action...
P&E GDB Server for Arm(R) devices, Version 8.80.00.00
Copyright 2018, P&E Microcomputer Systems Inc, All rights reserved
Loading library /usr/local/mcuxpressoide-11.4.0_6237/ide/plugins/com.pemicro.debug.gdbjtag.pne.expansion_5.2.0.202203211842/lin/gdi/unit_ngs_arm_internal.so ... Done.
Command line arguments: -interface=USBMULTILINK -port=USB1 -speed=500 -flashobjectfile=/home/gianfranco/MCU/evkmimxrt1020_blinking_led_iled_blinky/Debug/evkmimxrt1020_blinking_led_iled_blinky.axf -device=NXP_iMX_IMXRT1021 -programmingtype=0 -startserver -singlesession -quitafterprogramming
Device selected is NXP_iMX_IMXRT1021
User Specified Hardware Selection : Interface=USBMULTILINK and Port=USB1
Connecting to target.
PEmicro Interface detected - Flash Version 10.84
Device is NXP_iMX_IMXRT1021.
Mode is In-Circuit Debug.
(C)opyright 2012, P&E Microcomputer Systems, Inc. (www.pemicro.com)
API version is 101
TARGET XML PATH is /usr/local/mcuxpressoide-11.4.0_6237/ide/plugins/com.pemicro.debug.gdbjtag.pne.expansion_5.2.0.202203211842/lin/gdi/P&E/supportFiles_ARM/target_v7m_vfp.xml
Server 1 running on 127.0.0.1:7224
Server 2 running on 127.0.0.1:7226
Server 3 running on 127.0.0.1:7228
Server 4 running on 127.0.0.1:7230
Server 5 running on 127.0.0.1:7232
Server 6 running on 127.0.0.1:7234
Server 7 running on 127.0.0.1:7236
Server 8 running on 127.0.0.1:7238
Server 9 running on 127.0.0.1:7240
Server 10 running on 127.0.0.1:7242
Copyright 2022 P&E Microcomputer Systems,Inc.
Command Line :/usr/local/mcuxpressoide-11.4.0_6237/ide/plugins/com.pemicro.debug.gdbjtag.pne.expansion_5.2.0.202203211842/lin/pegdbserver_console -interface=USBMULTILINK -port=USB1 -speed=500 -flashobjectfile=/home/gianfranco/MCU/evkmimxrt1020_blinking_l�
PEmicro Interface detected - Flash Version 10.84
CMD>RE
Initializing.
Target has been RESET and is active.
CMD>CM /usr/local/mcuxpressoide-11.4.0_6237/ide/plugins/com.pemicro.debug.gdbjtag.pne.expansion_5.2.0.202203211842/lin/gdi/P&E/supportFiles_ARM/NXP/iMX/issi_is25lp064_1x32x2meg_imxrt1021.arp
Initializing.
Initialized.
;version 1.02, 04/29/2019, Copyright 2019 P&E Microcomputer Systems, www.pemicro.com  [issi_is25lp064]
;device issi, is25lp064, 1x32x2meg, proc=imxrt1021
;begin_cs device=$60000000, length=$00800000, ram=$20000000
Loading programming algorithm ...
WARNING - Selected .ARP file has been modified. CRC16 = $32EE

Programming sequency is : erase, blank check, program, and verify {default}
CMD>VC
Command is inactive for this .ARP file.
VC is not implemented, falling back to VM
CMD>VM
Verifying.
Verify error at address $60000000.
Byte in module is $FF and should be $46.
Current content of flash does not match application to be programmed
CMD>EO
Erasing.
Range could not be erased.
Error Erasing flash of device
Error occured during Flash programming.
All Servers Running
Target Disconnected.

 It is connected in the same way as the EVK (same pins), the QE bit was set and the debug session starts without errors or warnings. Why the memory wasn't programmed?

We are using PEMicro Multilink Universal

Tags (3)
0 Kudos
2 Replies

988 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @gtalocchino ,

   Do you set your boot mode in internal boot mode?

   From your RAM flexspi_polling test result, your QSPI flash already works OK, erase, write, read all OK.

   Now, do you have any other debugger except the the PEMicro MU, eg, Segger JLINK or CMSIS DAP, whether other debugger works OK or not?

  About the code, please use the SDK led_blinky, download it to the flash, your log indicates the readout data is not correct:

CMD>VM
Verifying.
Verify error at address $60000000.
Byte in module is $FF and should be $46

 So, you also can use the MCUbootUtility to download the app to your flash in serial download mode, and check, whether the readout data is correct?

Then check boot, if it works OK.

Then back to your PE Mulitlink, download again, use the MCUbootUtility readout the flash memory, whether it is the same as the APP image.

 If you have other debugger, also try it with MCUxpresso IDE.

MCUBootUtility tool:
https://github.com/JayHeng/NXP-MCUBootUtility/archive/refs/tags/v3.4.0.zip
the related user manual is:
https://github.com/JayHeng/NXP-MCUBootUtility

 

Best Regards,

Kerry

0 Kudos

1,003 Views
jay_heng
NXP Employee
NXP Employee

 It seems to be MCUX flash algo issue under PEMicro, Can you please try another IDE? for example IAR.