Hello NXP team,
Please help us on this query.
We are using i.MXRT1052 with SDK_2_10_0_EVKB-IMXRT1050 in one of our projects. Our board has provision to boot from SD card and eMMC. We are successfully able to flash the image in SD card and boot from it.
Our final aim is to boot from eMMC. The eMMC used on our hardware is Kingston "EMMC04G-W627-X02U". We are able to able to do basic read/write operation on EMMC so connections seems to be fine. However we are not able to boot from EMMC. We have referred other posts, shown below, on NXP forum and Application notes for the same but none of them provides an actual solution for booting from EMMC with imxRT.
https://mcuoneclipse.com/2019/01/22/tutorial-booting-the-nxp-i-mx-rt-from-micro-sd-card/
https://community.nxp.com/thread/352318
https://www.nxp.com/docs/en/application-note/AN12107.pdf
https://community.nxp.com/t5/i-MX-RT/i-MXRT1051-eMMC-boot/td-p/806269
As per the imxrt1050 Reference Manual the BOOT_CFG and BOOT_MODE pins needs to be configured as below to enable boot from EMMC:
BOOT_CFG[0] : 0
BOOT_CFG[1] : 1
BOOT_CFG[2] : 0 or 1(tried both)
BOOT_CFG[3] : 0
BOOT_CFG[4] : 0
BOOT_CFG[5] : 0
BOOT_CFG[6] : 0
BOOT_CFG[7] : 1
BOOT_CFG[8] : 0
BOOT_CFG[9] : 0
BOOT_CFG[10] : 0
BOOT_MODE[0] is LOW
BOOT_MODE[1] is LOW
We have flashed the image in eMMC using NXP_BOOT_UTILITY tool V3.3.0 and also able to read back the data written to EMMC using the tool, however device fails to boot-up from EMMC.
After flashing the code using boot utility tool, we are keeping the switches for BT_CFG[6], BT_CFG[9], BOOT_MODE[0] and BOOT_MODE [1] in low state. But looks like the internal ROM bootloader is not recognizing the changes made.
We also tried probing the EMMC lines during bootup. Our clock line is via GPIO_SD_B1_04. After making the above changes, we probed the CLK line going to eMMC but couldn’t find any clock signal. However clock for SD1_CLK was still there. Seems like the boot device mode is not switching to eMMC.
Is there anything missing that needs to be done for booting from iMXRT050? Any configuration which needs to be enabled to make it work? Any leads would be appreciated.
Solved! Go to Solution.
Hi @ramreddy
Thanks for your reply.
Through some rounds of testing, the RT1050 can boot from the eMMC after populating the R160 and R262.
The attached MCU Boot Utility tool has been fixed the defect of programming the eMMC and hello_world.srec is a simple demo for testing, it can print out a string (hello world from emmc.) via UART port (J24).
Moreover, I'd like to suggest you may need to optimize the hardware circuit of the board, during the testing, I use the Jlink to connect the J16 for debugging and it sometimes works well, sometimes works bad, in a word, the connection is not stable. I also try to program the image which resides in the SD card to eMMC, however, it doesn't boot up successfully every time, I think it may be related to the power supply circuit of the LCD panel.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Hi,
we had tried the below command we are getting the error
C:\Users\rkadathala\Downloads\elftosb_5.1.19\elftosb_5.1.19\bin\win>elftosb.exe -f kinetis -V -c program_mmccard_image_fastboot.bd -o boot_image.sb evkbimxrt1050_hello_world_nopadding.bin
error: line 41: invalid source name 'myUserDataFile'
We had modified the command for normal boot it is building the .sb file successfully.
C:\Users\rkadathala\Downloads\elftosb_5.1.19\elftosb_5.1.19\bin\win>elftosb.exe -f kinetis -V -c program_mmccard_image_normal.bd -o boot_image.sb evkbimxrt1050_hello_world_nopadding.bin
Still we are unable to boot from eMMC (We did not observed any print in the console)
if possible take the remote for further assistance.
Thanks
Hi,
Thanks for your reply.
In previous replies, I forgot to ask you to share the screenshot of Device Configuration when using the NXP_BOOT_UTILITY.
Further, I was wondering if you can share the schematic of your custom board.
Hope it helps.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Hi,
We are able to flash from MFG tool but unable to boot from eMMC. we are observing some data over command, data 0-3 lines.
We are using the below boot configuration with eMMC normal boot mode because we are getting error while building the .sb file with eMMC fast boot mode.
Boot_config_1 is High
Boot_config_6 is Low
Boot_config_7 is High
Boot_config_9 is Low
Boot_Mode_0 is Low
Boot_Mode_1 is High
Here is the Device config screenshot
The below screenshots represents the EMMC and Controller connections
The pullup resistors are populated on D0- D7 lines.
Kindly let us know how to proceed further.
Thanks.
Hi,
Thanks for your reply.
Firstly, refer to the eMMC connection of MCIMX6ULL-EVK to modify your board, especially removing the pull-up resistors.
Next, I'd like to suggest you use the NXP-MCUBootUtility to program evkbimxrt1050_hello_world.s19 with the above eMMc Device Configuration, after that, set the BOOT_CFG pins as the below table shows.
BOOT_CFG1[0] | 0 |
BOOT_CFG1[1] | 1 |
BOOT_CFG1[2] | 0 |
BOOT_CFG1[3] | 0 |
BOOT_CFG1[4] | 0 |
BOOT_CFG1[5] | 0 |
BOOT_CFG1[6] | 0 |
BOOT_CFG1[7] | 1 |
BOOT_CFG2[0] | 0 |
BOOT_CFG2[1] | 0 |
BOOT_CFG2[2] | 0 |
Further, I'd like to suggest you upload the read-back data after programming evkbimxrt1050_hello_world.s19.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Hi,
Thanks for the support.
We tried the suggested changes but it made no difference and the device still couldn't boot from eMMC. I flashed the eMMC with the s19 file provided by you. I have attached the eMMC readback data obtained from NXP boot utility software for your reference.
On our board we have faced an issue wrt reading Extended CSD register during eMMC initialization. During initialization the device is able to get proper response for other commands such as OCR, CID and CSD but for extended CSD, eMMC fails to respond properly. To get around that issue, we have added retries for sending extended CSD command operation in fsl_mmc.c driver file. After failing for multiple times, it eventually succeeds and then only eMMC initialization is successful. After that we are not facing any issues with regards to Extended CSD but not sure whether that is correct way to move forward.
Could it be possible that the internal ROM bootloader is also facing similar issue of failing to get an adequate response for extended CSD command and is aborting the boot-up from eMMC upon failure?
I believe that the issue could be resolved faster if we can take this discussion off this forum and have a call for the same. Kindly do let know whether that is possible and also how to proceed from here.
Regard
Hi,
Thanks for your reply.
Firstly, After going through the readbackBootDeviceMemory.rar, the NXP boot utility program the s19 file (output a string via the LPUART1_TXD_GPIO_AD_B0_12 pin) successfully.
1) Could it be possible that the internal ROM bootloader is also facing similar issue of failing to get an adequate response for extended CSD command and is aborting the boot-up from eMMC upon failure?
-- Actually, I'm not sure, as the ROM code is confidential, even for me.
so I'd like to suggest you use the logic analyzer to capture the data for further analysis.
2) I believe that the issue could be resolved faster if we can take this discussion off this forum and have a call for the same. Kindly do let know whether that is possible and also how to proceed from here.
-- Sorry, we don't provide phone support, however, you can send me your board if it's okay for you, then I can do some tests by myself.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Hi,
We are trying to send one board with you may be it will take some time.
Parallelly we tried one iteration with EVK board where we had removed the hyper flash and connect the respective signal lines to our custom board EMMC.
The boot configuration on the EVK board was as below.
Switch | Value |
SW 5 | 1000 |
SW 6 | 0100 |
SW 7 | 0010 |
we could observe the clock line during the bootup from eMMC but it seems like it couldn't come out from that state. To verify the communication with the eMMC we had used evkbimxrt1050_mmccard_freertos example project. Here also we observed the same issue of failure to read the Extended CSD register. where as that OCR, CID,CSD is getting passed and we are able to see the data and validated that data with eMMC datasheet.
Initially we tried with IO Voltage as 1.8V with that we are able to read the registers except Ex_CSD register.
1. Will the length of the data line cause any issues while reading from the Ex_CSD register?
Hi @ramreddy ,
Firstly, for the MIMXRT1050 EVK board, when the SW7 = 1001, NXP-MCUBootUtility can build the communication with the board, however, your customize board fails to make it actually.
Second, when set the SW1 = 1010 on your board, it can boot from the SD card, however, the settings of BOOT_CFG7 and BOOT_CFG6 for SD and eMMC boots is a conflict with each other, the board already supported the SD card boot, which means the BOOT_CFG7 is low value. We guess it's the root cause, so please check it.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Hi,
Thanks for replying.
We had made changes on the board as you said. Again I'm sharing the details of boot configuration pins. Still we are unable to boot from the eMMC. Also we had tested it by connecting the eMMC to evk board by removing the Hyper flash. This case is also not working.
As per our observation through logic analyzer the IMXRT is trying some communication with the eMMC. But it is not launching/running the application.
thanks,
Ramreddy.
Hi,
According to our testing experience, you'd better choose the USB instead of the UART interface to connect the MCU Boot Utility tool, meanwhile, configure the SW1 = 0000, it seems to improve the connection stability.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Hi @ramreddy
Thanks for your reply.
Through some rounds of testing, the RT1050 can boot from the eMMC after populating the R160 and R262.
The attached MCU Boot Utility tool has been fixed the defect of programming the eMMC and hello_world.srec is a simple demo for testing, it can print out a string (hello world from emmc.) via UART port (J24).
Moreover, I'd like to suggest you may need to optimize the hardware circuit of the board, during the testing, I use the Jlink to connect the J16 for debugging and it sometimes works well, sometimes works bad, in a word, the connection is not stable. I also try to program the image which resides in the SD card to eMMC, however, it doesn't boot up successfully every time, I think it may be related to the power supply circuit of the LCD panel.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Hi,
Thanks for your reply.
1) Will the length of the data line cause any issues while reading from the Ex_CSD register?
-- No, I don't think so and in my opinion, the case may be related to the ROM code, whereas, it needs me to do some testing to validate it.
I'll send my address information via private message later.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------