Flashing from QSPI in custom board using RT-1176

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Flashing from QSPI in custom board using RT-1176

9,017 次查看
ManikantaRobbi
Contributor II

Hi,

We have custom designed board of MIMXRT1176AVM8A which is connected to QSPI (IS25WP128-JKLE-TR). Trying to Flash using J-link Segger, but unable to flash the code. Getting the error 

1.****** Error: Failed to prepare for programming.
Could not preserve target memory.
Error while determining flash info (Bank @ 0x30000000)
Unspecified error -1
Script processing completed.
****** Error: Could not start CPU core. (ErrorCode: -1)
Unable to perform operation!
Command failed with exit code 1

Full error description & component used are attached below.

 

Please do the needful.

 

0 项奖励
回复
18 回复数

8,951 次查看
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @ManikantaRobbi ,

   Seems your hardware even didn't find the ARM core. This should still related to the hardware.

    Please don't use the IDE at first, your picture mentioned .cfx in the MCUXpresso IDE, it is used for the CMSIS DAP debugger, not the JLINK.

  Please use the JLINK commander to check it at first.

   I mean,  this one:

kerryzhou_0-1691992803679.png

Then try to connect it.

The correct result should like this :

kerryzhou_1-1691992841585.jpeg

If you even can't find the Cortex m7 core, it means your hardware have issues, even not related to the QSPI, you need to check the hardware, the POR sequence, etc.

 

Wish it helps you!

Best Regards,

kerry

 

 

0 项奖励
回复

8,915 次查看
ManikantaRobbi
Contributor II

Hi Kerry,

 

 

Thanks done as per your instructions using J-link commander. Getting MIMXRT1176 CM7 core identified but using loadfile command to flash bin file after connecting, error message -

ManikantaRobbi_0-1692254211195.png

 

 

Kindly do the needful.

0 项奖励
回复

8,901 次查看
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @ManikantaRobbi ,

   Thanks for your updated information.

    Ok, ARM Cortex M7 can be found, just can't download the code to the external flash, right?

    Now, follow me to test it with debugger and IDE.

   Please download the RT1176 SDK, then run the SDK project in the internal RAM.

 1. Download SDK:

https://mcuxpresso.nxp.com/en/builder?hw=MIMXRT1170-EVK

2. import the SDK project to the MCUXPresso IDE:

SDK_2_14_0_MIMXRT1170-EVK\boards\evkmimxrt1170\driver_examples\flexspi\nor\polling_transfer\cm7

kerryzhou_0-1692325649859.png

Run it in the internal RAM.

 

Test the result, whether you can pass the external QSPI flash read, erase , program or not?

Please check it.

If the test is passed, then you can download to the flash again.

 

Wish it helps you!

Best Regards,

Kerry

 

 

0 项奖励
回复

8,887 次查看
ManikantaRobbi
Contributor II
Yes this procedure is working, but when we disable check box Link Application to RAM -again it is throwing error. And we are testing the application using Boot switches-Internal Boot mode
0 项奖励
回复

8,883 次查看
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @ManikantaRobbi ,

   Send the test result of running in the internal RAM to me, I mean, the printf log, which can see the erase, program result.

   On your side, please do the external memory mass erase at first if it already can do the erase.

Best Regards,

Kerry

0 项奖励
回复

8,879 次查看
ManikantaRobbi
Contributor II

Thanks Kerry,   these are the changes done but we are not getting unexpected output.

FlexSPI.png

Link2RAM.png

MCU.png

Result.png

    

0 项奖励
回复

8,878 次查看
ManikantaRobbi
Contributor II
Boot Mode-Internal Boot not(Serial Downloader)
0 项奖励
回复

8,877 次查看
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @ManikantaRobbi ,

   Your printf log is tested from internal boot, and run in internal RAM, right?

  The printf log is not correct, it means your QSPI flash operation is not passed.

  Please help to check your board, whether the flexSPI DQS pin is float or not?

Best Regards,

Kerry

0 项奖励
回复

8,875 次查看
ManikantaRobbi
Contributor II
No it is connected to GPIO_SD_B2_05 same as in EVK kit.
0 项奖励
回复

8,873 次查看
ManikantaRobbi
Contributor II

NOR_FLASH Example is running up to vendor id and giving 0xff (it means reading nothing) and going to running mode without stopping at break point.
Kerry I want to mention one point we are using HyperFLash-S26HS512TGABHI000 and we removed 0ohms resistors which is connected to QSPI-IS25WP128-JKLE-TR

0 项奖励
回复

8,804 次查看
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @ManikantaRobbi ,

   You are using hyperflash, not the QSPI flash in the RT1176, then your JLINK firmware download can't work is reasonable, as the JLINK flashloader is for the QSPI flash in default.

  You test the NOR_FLASH Example can't get the correct response, it is also reasonable, as that is also for the QSPI flash in default.

  If you want to use the hyperflash, you need to do the modification.

Please test this code:

SDK_2_14_0_MIMXRT1170-EVK\boards\evkmimxrt1170\driver_examples\fsl_romapi\cm7

change the:

static serial_nor_config_option_t option = {

.option0.U = 0xc0000007U,

.option1.U = 0U,

};

option 0 to the following hyperflash data:

kerryzhou_0-1692596124791.png

Pease try it again.

Best Regards,

Kerry

 

0 项奖励
回复

8,796 次查看
ManikantaRobbi
Contributor II

Thanks Kerry,


Tried as you suggested, but getting error message

ManikantaRobbi_0-1692598179850.png

and our Hyperflash is S26KL512S  not as same vendor  present on EVK kit MX25UM51345GXDI00

 but I can't find any dropdown to select .cfx file for S26KL512S  part number as shown in below Image.

 

 

ManikantaRobbi_0-1692600003163.png

 

0 项奖励
回复

8,791 次查看
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @ManikantaRobbi ,

   Seems your hardware have issues if you can't make it work.

   Please note, MX25UM51345GXDI00 is not the hyperflash, it is octal flash.

  That's why I recommend you use the hyperflash:

• HyperFLASH 1V8: option0 = 0xc0233008 (166MHz)
• HyperFLASH 3V0: option0 = 0xc0333005 (100MHz)

   Which one you have tried?  You also need to do the correct BOOT_CFG pin configuration.

kerryzhou_0-1692599659234.png

You also can refer to the RT1050-EVKB,as that board is using the hypeflash in default.

 

Best Regards,

Kerry

 

0 项奖励
回复

8,782 次查看
ManikantaRobbi
Contributor II
Thanks Kerry,
I tried to change the BOOT_CFG pins i.e. 2 and 3 pins but its has only four options
FLASH_PROBE_TYPE
0 - QuadSPI NOR
1 - MXIC Octal
2 - Micron Octal
3 - Adesto Octal

How to enable no hyperflash option is visible.
0 项奖励
回复

8,776 次查看
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @ManikantaRobbi ,

  Mainly these BOOT_CFG:

kerryzhou_0-1692608490586.png

 

Best Regards,

Kerry

 

0 项奖励
回复

8,698 次查看
ManikantaRobbi
Contributor II
Yes Kerry Done as per this configuration and try to flash by enabling check box LINK TO RAM
1. In EVK kit it is detecting.
2. In custom designed board unable to detect external HYPERFLASH.
0 项奖励
回复

8,603 次查看
ManikantaRobbi
Contributor II

Hi Kerry,

Thanks for the support. Now we removed Hyperflash from our custom board, only using QSPI IS25WP128-JKLE-TR.

Step 1. We will try to flash flexSPI_NOR_Example by link to RAM Enabling (Checkbox). 

Note: Boot Mode Switches is 10 i.e., Internal Boot same as EVK.

Check the result vendor ID.

Step 2. Need to Disable the check Box. And try to flash again right.

Is there any modifications need to be done except Boot Configurations switches[11:0]=0 (Based of RM) for QSPI operation.

 

Thanks & Regards,

Manikanta Robbi.

 

 

0 项奖励
回复

8,555 次查看
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @ManikantaRobbi ,

  Sorry for my later reply.

   To the QSPI flash, the BOOT_CFG is 0, you just need to set the BOOT_MODE to the internal boot mode is OK.

  Then the SDK default is for the QSPI flash.

  Now, can you make it work?

Best Regards,

Kerry

0 项奖励
回复