IMXRT1064 serial boot

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

IMXRT1064 serial boot

20,214 Views
mike_asm
Contributor II

Hi NXP Community,

we use i.MX for several projects. Initially we would like to load our devices via USB (serial mode). The boards that have an IMXRT1170 (3 different projects) work without problems. The boards with IMXRT1064 (2 projects) can boot from flash, but USB is not recognized, an error occurs (Unknown USB Device (Device Descriptor Request Failed)). The HW design of USB interface, boot switches, PoR is the same. The example project "hello-world" also runs. If we erase the chip with the "EnableEraseAllFlashBanks" flag, the USB device reports as expected, but after the reset or trying to connect comes the error again.
What is the difference between IMXRT1170 and IMXRT1064 at the point? What do we have to observe to get a USB connection for serial boot?

0 Kudos
Reply
22 Replies

2,507 Views
diego_charles
NXP TechSupport
NXP TechSupport

Hi @mike_asm 

I hope you are doing well. 

Please correct me if I my understanding is not correct. 

I understand that you are using the i.MX RT1064 serial downloader mode, over USB1 pins, to update application images. Also, that  after an erase there is a successful USB1 enumeration. But, after a reset or power cycle, USB1 can not longer enumerate. 

To double check USB enumeration, while on serial downloader mode you can use our SDPHOST tool (command line tool) to check for the presence of the bootROM. Here is an example.

 

 

 

 

sdphost -u 0x1FC9,0x0130 -j -- error-status 

 

 

 

 

The SDPHOST tool is already integrated by the MCUXpresso Secure Provisioning tool (GUI tool). So there is a button in the tool to check connection over USB or UART, this way you can avoid having to write a command like above.

To  check that the MCU is serial downloader mode, you can check the address of the program counter (PC ). The PC can be read over SWD/JTAG. SWD is used by default.  If the address is something like 0x2xxxx the MCU is probably in serial downlader mode. Also, if you have UART1 pins routed you can make a ping to the ROM bootloader to verify.

As a note, to enter into serial downloader mode the boot mode  pins should be set to 0b01 before releasing reset. Did you made this setting? 

All the best, 

Diego.

0 Kudos
Reply

2,302 Views
mike_asm
Contributor II
Hi Diego,
Thank you for your quick response.
In this case, unfortunately, we cannot use SDPHOST tool because the USB descriptor is corrupted, the Vendor Id and Device Id are incorrect, and no connection is established.
After reset, the MCU is probably in serial downloader mode (address 0x2xxxxx) in a loop. The good case and bad case addresses are different.
So as assume this is a loop in error handler.
Is there a method to determine what is causing the error? Thanks.
0 Kudos
Reply