Unable to Recover Colibri iMX6

Hello,

I have a few Colibri iMX6’s that are in need of recovery. I am able to boot them into recovery mode, but when I run the update.sh scripts it fails.

Am I doing something wrong or is the iMX6 lost?

Output:

~/Downloads/Colibri_iMX6_LinuxImageV2.6$ ./update.sh -d
Colibri iMX6 rootfs detected
config file <./imx_usb.conf>
vid=0x066f pid=0x3780 file_name=mx23_usb_work.conf
vid=0x15a2 pid=0x004f file_name=mx28_usb_work.conf
vid=0x15a2 pid=0x0052 file_name=mx50_usb_work.conf
vid=0x15a2 pid=0x0054 file_name=mx6_usb_work.conf
vid=0x15a2 pid=0x0061 file_name=mx6_usb_work.conf
vid=0x15a2 pid=0x0063 file_name=mx6_usb_work.conf
vid=0x15a2 pid=0x0071 file_name=mx6_usb_work.conf
vid=0x15a2 pid=0x007d file_name=mx6_usb_work.conf
vid=0x15a2 pid=0x0076 file_name=mx7_usb_work.conf
vid=0x15a2 pid=0x0041 file_name=mx51_usb_work.conf
vid=0x15a2 pid=0x004e file_name=mx53_usb_work.conf
vid=0x15a2 pid=0x006a file_name=vybrid_usb_work.conf
vid=0x066f pid=0x37ff file_name=linux_gadget.conf
config file <./mx6_usb_work.conf>
parse ./mx6_usb_work.conf
15a2:0061(mx6_qsb) bConfigurationValue =1
Interface 0 claimed
HAB security state: development mode (0x56787856)
== work item
filename ../colibri-imx6_bin/u-boot.imx
load_size 0 bytes
load_addr 0x00000000
dcd 1
clear_dcd 0
plug 1
jump_mode 2
jump_addr 0x00000000
== end work item
main dcd length 310
sub dcd length 30c
w3 in err=-7, last_trans=0  00 00 00 00
addr=0x021b001c, val=0x04008032
w4 in err=-7, last_trans=0  00 00 00 00
!!perform_dcd returned -7
HAB security state: development mode (0x00000000)

Thanks in advance!

I have a few Colibri iMX6’s that are in need of recovery. I am able to boot them into recovery mode,

What exactly do you mean by boot them into recovery mode?

I assume you are able to set them to recovery mode and they respond as follows when connected via USB device cable to your development workstation, correct?

[user@host ~]$ lsusb | grep -i free
Bus 002 Device 017: ID 15a2:0061 Freescale Semiconductor, Inc. i.MX 6Solo/6DualLite SystemOnChip in RecoveryMode

but when I run the update.sh scripts it fails.

...
w3 in err=-7, last_trans=0  00 00 00 00
addr=0x021b001c, val=0x04008032
w4 in err=-7, last_trans=0  00 00 00 00
!!perform_dcd returned -7
HAB security state: development mode (0x00000000)

Yes, it looks like there is an issue in actually loading/transferring the u-boot.imx binary. The working case would instead look as follows:

...
loading binary file(../colibri-imx6_bin/u-boot.imx) to 177ff400, skip=0, fsize=4cc00 type=aa

<<<314368, 314368 bytes>>>
succeeded (status 0x88888888)
jumping to 0x177ff400

Am I doing something wrong or is the iMX6 lost?

Good question. Let me first get some more information concerning your environment.

  1. What exactly have you done to those modules that they are in need of recovering in the first place?
  2. I assume you are trying this with our stable V2.6_20160826 BSP, correct?
  3. Have you tried using a different USB cable?
  4. Have you tried using a different carrier board (BTW: what carrier board are you using)?
  5. Have you tried a different USB port on your development workstation?
  6. Have you tried going through a USB hub vs. using a direct connection?

One thing we saw happening in the past is that for some reason the i.MX 6 boot ROM may still partially load some albeit corrupt configuration before entering the recovery mode which then later will fail. If that is the case one would need to prevent it getting access to the eMMC in the first place. Rather then shortening the recovery mode pad one would need to shorten the two round test points right next to the i.MX 6 SoC, waiting a few seconds for the boot ROM to exceed its retries and it should enter recovery mode this time with a truly clean slate.

I assume you are able to set them to recovery mode and they respond as follows when connected via USB device cable to your development workstation, correct?

Yes, that is correct.

  1. What exactly have you done to those modules that they are in need of recovering in the first place?

We followed Qt 5.7 device creation tutorial and their pre-built image updates the u-boot. The iMX6 stopped worked right after that.
We have been in contact with Qt Support and they admitted there was something wrong in their image and documentation. They told us to following the Toradex Flashing from scratch documentation.

  1. I assume you are trying this with our stable V2.6_20160826 BSP, correct?

Yes

  1. Have you tried using a different USB cable?

I will try

  1. Have you tried using a different carrier board (BTW: what carrier board are you using)?

I only have the Colibri Eval 3.2B carrier board.

  1. Have you tried a different USB port on your development workstation?

Yes, I have. It made no difference. I have flashed other modules before, without any errors.

  1. Have you tried going through a USB hub vs. using a direct connection?

I have tried both.

Rather then shortening the recovery mode pad one would need to shorten the two round test points right next to the i.MX 6 SoC, waiting a few seconds for the boot ROM to exceed its retries and it should enter recovery mode this time with a truly clean slate.

Do you mean those 2 lonely points right beneath the SoC? Between the Soc and the 2 blocks with the stickers on?

Thanks for your help so far :slight_smile:

We followed Qt 5.7 device creation tutorial and their pre-built image updates the U-Boot. The Colibri iMX6 stopped working right after that. We have been in contact with Qt support and they admitted there was something wrong in their image and documentation. They told us to following the Toradex flashing from scratch documentation.

I won’t comment on their stuff.

One thing we saw happening in the past is that for some reason the i.MX 6 boot ROM may still partially load some albeit corrupt configuration before entering the recovery mode which then later will fail. If that is the case one would need to prevent it getting access to the eMMC in the first place. Rather then shortening the recovery mode pad one would need to shorten the two round test points right next to the i.MX 6 SoC, waiting a few seconds for the boot ROM to exceed its retries and it should enter recovery mode this time with a truly clean slate.

Do you mean those 2 lonely points right beneath the SoC? Between the Soc and the 2 blocks with the stickers on?

No, it would be the two little round ones right next to the i.MX 6 chip on the same side as the real recovery pads.

Thanks for your help so far :slight_smile:

You are very welcome.

Of course, would’ve been impossible to reach those points when it’s in the eval board.

I’ll try this method when I get back in the office.

I have successfully recovered and flashed the modules.

Again, many thanks!

Glad that worked for you and thanks for the heads-up.