Boot rom enable QE bit in the nor flash

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

Boot rom enable QE bit in the nor flash

Jump to solution
3,531 Views
MCW
Contributor III

Hi all, 

Accroding to https://community.nxp.com/t5/i-MX-RT/boot-header-for-qspi-flash/td-p/1642446 

I am able to set QE bit to 1 successfully by adding QE enable related code in evbmimxrt1060_flexspi_nor_cofig.c file.

And then I considered if I set the QE bit to 0 manually and reboot my board, the QE bit should be set to 1 again.

However, the QE bit was still 0 (not expected) from my experiment. 

Is there any problem in my experiement flow?

 

Best Regards,

Doris

0 Kudos
1 Solution
2,614 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,

    Sorry for my later information.

    Today, our internal side already have the summarize, after a lot testing internally, even with the MXIC FAE debug together in NXP.

    The issue until now, just related to the MXIC QSPI flash with the FCB to enable the QE.

   Reason: MXIC QSPI IO2/IO3 have the reset function, if the QSPI flash is not enable the QE function, the IO2/IO3 also have the reset funtion, and after reset, it nees at least 30us recovery time. But if the QSPI enable the QE, then the IO2/IO3 reset function is disabled.

  The issues is caused by, the ROM will do a reset after boot, and also will pull low the IO2/IO3, it will cause the MXIC QSPI flash enter reset, then ROM even can't use the 1bit to readout the FCB, it cause the issues.

  So, until now, maybe a sad story to you, to the MXIC QSPI, this issue can't be resolved, as the ROM is fixed, but we also tested a lot of other flash no issues, ISSI WP, winbond etc.  We also report to the internal R&D team.

  So, to you, two way: MXIC chip, use auto probe, or use other flash if you must use the FCB QE enabe function.

Wish it helps you!

If you still have questions about it, please help to create the new case, thanks.

Best Regards,

Kerry

View solution in original post

28 Replies
2,615 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,

    Sorry for my later information.

    Today, our internal side already have the summarize, after a lot testing internally, even with the MXIC FAE debug together in NXP.

    The issue until now, just related to the MXIC QSPI flash with the FCB to enable the QE.

   Reason: MXIC QSPI IO2/IO3 have the reset function, if the QSPI flash is not enable the QE function, the IO2/IO3 also have the reset funtion, and after reset, it nees at least 30us recovery time. But if the QSPI enable the QE, then the IO2/IO3 reset function is disabled.

  The issues is caused by, the ROM will do a reset after boot, and also will pull low the IO2/IO3, it will cause the MXIC QSPI flash enter reset, then ROM even can't use the 1bit to readout the FCB, it cause the issues.

  So, until now, maybe a sad story to you, to the MXIC QSPI, this issue can't be resolved, as the ROM is fixed, but we also tested a lot of other flash no issues, ISSI WP, winbond etc.  We also report to the internal R&D team.

  So, to you, two way: MXIC chip, use auto probe, or use other flash if you must use the FCB QE enabe function.

Wish it helps you!

If you still have questions about it, please help to create the new case, thanks.

Best Regards,

Kerry

1,496 Views
MCW
Contributor III

Hi @kerryzhou ,

 

I have a problem about porgamming the code by SEGGER J-flash to the customize board which has auto probe. 

Firstly, the code was programmed into the flash by flash programmer, and the boot_cfg[0](auto probe) was pull-high.

As expected, the code run correctly after boot.

However, I cannot use SEGGER J-flash to program the flash when boot_cfg[0](auto probe) was pull-high. From the information of SEGGER J-flash utility, the target was connected, but it couldn't download file. Next step, we made boot_cfg[0](auto probe) pull-down. And then we can program the code successfully and the code run.

 

The other experiment was programming the code by daplink to the customize board which had auto probe. It was also successful to program the code to the flash.

 

Therefore, I am curious the reason why I cannot use SEGGER J-flash to program my code when boot_cfg[0](auto probe) is high?

Thank you.

 

Best regards,

Doris

0 Kudos
1,413 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,

  For the new issues, please help to create the new question post, then I will help you in your new question post, thanks.

Best Regards,

kerry

2,288 Views
MCW
Contributor III

Hi @kerryzhou ,

 

The information is very clear and helpful.

Appreciate your efforts in these days.

 

Best regards,

Doris

0 Kudos
2,763 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,

    A good news to you, you can use the auto probe function, that can help you enable the QE bit and the FCB directly.

   

kerryzhou_0-1686046351411.png

kerryzhou_1-1686046371551.png

Connect the R325, you can find the led is blinking again.

So, here, please try to use the auto probe in the meanwhile.

 

Best Regards,

Kerry

 

 

0 Kudos
2,629 Views
MCW
Contributor III

Hi @kerryzhou ,

 

I have tested it on my customize board and program the code to MX25L12833F by the flash programmer, and I found both the code with enable QE bit code and without enable QE bit code runs successfully after rebooting the board.

Hence, there are some points needed to comfirm with you.

1. The control of the QE bit is not related to the config in the evbmimxrt1060_flexspi_nor_cofig.c file anymore when the R325 was connected, right?

2. Is there any software solution for enable the QE bit?

3. In this issue, the root cause maybe comes from the not flash ?

 

Best regards,

Doris

0 Kudos
2,568 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,

   Sorry for my later reply because of my PTO.

  Now, reply your questions:

1. The control of the QE bit is not related to the config in the evbmimxrt1060_flexspi_nor_cofig.c file anymore when the R325 was connected, right?

=>Answer: Yes, you are right, as the R325 connect, it will use auto probe function, then the RT1060 ROM will help to generate the related FCB to configure the flexspi flash, your customer app even don't need to add the FCB.

2. Is there any software solution for enable the QE bit?

=>Answer: our expert will debug the rom for it. any updated information, I will let you know, in the meanwhile, please use the Auto probe as the workaround.

3. In this issue, the root cause maybe comes from the not flash ?

=>Answer: The root cause maybe related to the ROM with the MXIC flash, as the ISSI flash works OK when the QE bit is disabled.

Your customer board works, it should caused by your flash programmer enable the QE bit in the flashdriver.

 

Wish it helps you!

Best Regards,

Kerry

2,415 Views
MCW
Contributor III

Hi @kerryzhou ,

 

I found the QSPI Flash Support list from this document Section 5 .  

But I don't have MX25L6433F now, so I am curious have you ever tested QE experiement with MX25L6433F?

I will try to get MX25L6433F or MX25U6435E, and I will share my result here if I have any update.

 

Best regards,

Doris

0 Kudos
2,349 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,

   You can use MX25L12833F, don't need to change the chip.

   Our AE already let the MXIC FAE debug it together, the FCB QE enable issues is caused by a reset after reading the FCB when the QE is not enabled. More details, after our AE expert back from PTO, I will get the information and share it with you.

  In the meanwhile, please use the auto probe as the workaround at first.

  

Wish it helps you!

Best Regards,

Kerry

0 Kudos
2,682 Views
MCW
Contributor III

Hi @kerryzhou ,

 

I have connected R325 to the EVB. And the blink led code runs again after reboot the board.

Next step, I will try it on my customize board to make sure the result is the same.

Moreover, the code will be programmed by flash programmer directly, instead of MCUXpresso and SEGGER J-flash.

If I have any update, I will share with you.

Thanks for your help again.

 

Best regards,

Doris

2,752 Views
MCW
Contributor III

Hi @kerryzhou ,

 

I'm glad to hear from you.

I will try it and upadte my test result as soon  as possible.

Really appreciate your effort.

 

Best regards,

Doris

0 Kudos
2,768 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,

     Still in the checking process, I also contact with our internal expert, who will help to debug the ROM for this situation, but in the future 3 days, I will PTO, so, any updated information, I will reply you on the next Monday, thanks a lot for your understanding.

Best Regards,

Kerry

0 Kudos
2,803 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,

   I already reproduce your issues on my side, still in the checking process, any updated information, I will let you know, please keep patient, thanks.

Best Regards,

Kerry

3,154 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,

  What's the board and RT chip you are using?

  I have tested that, and the community project is also from my test, it works Ok on my side, even I firmware QE to 0 with polling code, then FCB is enable QE bit, then after boot, the QE bit will be 1 with the FCB which enable QE.

  So, if you meet issues, tell me you detail test steps, board, RT chip, then I will help you to check it.

 

Best Regards,

Kerry

0 Kudos
3,137 Views
MCW
Contributor III

Hi @kerryzhou ,

 

Thanks for your relpy in advance.

The chip that I used is IMXRT1061CVL5B, and the qspi flash is MX25L12833F.

Following the information is the details about my experiment:

1. Erase the whole qspi flash by the flash write, including QE disable

2. Use the flash writer to read back the status register of the qspi flash to make sure I have disabled QE (0x00) and there is not any code in the qspi flash

3. Program the code which contain QE enable related code in evbmimxrt1060_flexspi_nor_cofig.c file to the qspi flash

4.  As I expected, the QE bit is set to 1 and run my code correctly

5. Use the code that is revised from your project called evkmimxrt1060_flexspi_nor_polling_transfer to disable QE bit. I only revised the QE command for MX25L12833F, and I also checked the QE bit was disabled by reading it back from the status register of the qspi flash. At this point, the code that I have programmed in the step3. still in my qspi flash. Therefore, I supposed the QE bit should be set to 1 when I reboot my board, but it was still 0 and I cannot get any log that should be shown on the putty.

 

Is this related to the design of the imxrt1061 Boot Rom?

 

Best regards,

Doris

0 Kudos
3,074 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,

   When you run this  evkmimxrt1060_flexspi_nor_polling_transfer project, do you down it to the internal RAM or the flash? This should run from the internal RAM, as I just use it to disable the QE for the testing.

   From your description:

1. Erase the whole qspi flash by the flash write, including QE disable

2. Use the flash writer to read back the status register of the qspi flash to make sure I have disabled QE (0x00) and there is not any code in the qspi flash

3. Program the code which contain QE enable related code in evbmimxrt1060_flexspi_nor_cofig.c file to the qspi flash

4.  As I expected, the QE bit is set to 1 and run my code correctly

Seems the step 4 already works.

So, now, when you run evkmimxrt1060_flexspi_nor_polling_transfer to disable the QE, then the app boot can't work?

Please also share some log to me, include the evkmimxrt1060_flexspi_nor_polling_transfer test result.

My steps is:

1. download the app, eg, led_blinky, FCB enable the QE bit. in fact, it is the write status in FCB after boot. and the QE bit position. 

2.  Use the evkmimxrt1060_flexspi_nor_polling_transfer, to disable the QE bit.

   Then power off the board, power on it again, we can see the led still blinking, it means FCB QE bit enable works.

 

If you still have issues, please also test it on the MIMXRT1060-EVK board, whether you can reproduce the issues or not, or just with your MX25L12833F?

 

Best Regards,

kerry

 

0 Kudos
3,059 Views
MCW
Contributor III

Hi @kerryzhou ,

 

Yes, I run evkmimxrt1060_flexspi_nor_polling_transfer in the internal RAM.

InternalRAM.jpg

I have tried the steps you mentioned with my board and MIMXRT1060-EVK board, and the result of MIMXRT1060-EVK board was the same as yours. So, as you said, maybe the issue is caused by the qspi flash.

Thanks for your support.

 

Best regards,

Doris

0 Kudos
3,051 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,

   Which board did you test the MX25L12833F? Your customer board or the MIMXRT1060-EVK changed the QSPI?

    Just want to know, whether the MIMXRT1060-EVK can reproduce the issues with your QSPI.

    

Best Regards,

Kerry

3,045 Views
MCW
Contributor III

Hi @kerryzhou ,

 

Now I just test MX25L12833F on my board, not MIMXRT1060-EVK.

 

Best regards,

Doris

0 Kudos
3,041 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi @MCW ,   

If your MX25L12833F package is OK to solder to the MIMXRT1060-EVK, you can test that chip on the EVK, whether the issue still can be reproduced or not? I don't have that chip packge to solder to the MIMXRT1060-EVK, so need your testing result.

To the software, you don't need to modify, just test it as the orginal MIMXRT1060-EVK board.

Any test result, kindly let me know.

Best Regards,

Kerry