Hardkernel EMMC Module Recovery and use with Rock64

This is for ARMv8 based devices

Hardkernel EMMC Module Recovery and use with Rock64

Postby beakfire » Sat Apr 21, 2018 10:51 pm

Hello,

I spent the better part of last night and this morning troubleshooting one of my v0.4 EMMC modules from hardkernel and thought I would post some information about what I found out in case it helps anyone else.

So what I was doing is using the hardkernel EMMC module with my Rock64 SBC to see if it works, I was able to successfully flash a linux image onto the EMMC module and get the Rock64 to 'mostly' boot, it read the EMMC module and everything and booted most of the way.

I didn't really feel like spending much time troubleshooting the Rock64, my main purpose was to see if the v0.4 hardkernel EMMC module would work with it, which it appeared to even though I did not successfully boot I figured it could be a problem with something I had done.

As another note all of my attempts to load the ArchLinuxARM images onto the same EMMC module and boot the Rock64 from it following the procedures in the wiki were unsuccessful. So using the stock Rock64 images after failing with the ArchLinuxARM images was just a test to see if the problem was the EMMC module or something in the procedure that I may have had wrong.

After I completed this I proceeded to reverting the same EMMC module to be used on my Odroid-XU4 again and found the following problems:

- U-Boot would not successfully flash to the EMMC module
- Fan would not run at all, normally an indication that some bit of software has started to load

Some of the things I did to try to resolve this:

- Successfully loaded the xu3-latest image onto an SDCARD and booted the odroid-xu3
- Placed a freshly loaded EMMC module, using the same procedure into the EMMC slot
- Left the known good SDCARD in the SDCARD slot with the switch set to microSD boot
- Booted the board successfully
- Ran the fusing script successfully on the EMMC module

These normal steps to load U-boot onto the EMMC module failed, I tried every possible combination from following the steps in the installation procedure to the letter, to loading the latest ubuntu linux image provided from odroid onto the EMMC module and attempting to boot using the dd options to load the module and following the procedure to the letter.

Nothing in this manner was successful.

Afterwards I used a recovery tool found here:

https://forum.odroid.com/viewtopic.php?t=6173

I followed the procedure to the letter and afterward successfully booted the Odroid-Xu4 from the EMMC module causing me problems into Android 4.4.4.

Afterwards I again followed the install procedure to place ArchLinuxARM onto the EMMC module. As a test I performed the following:

- Attempted to boot the Odroid-Xu4 from the EMMC module without performing the fusing step of the Arch install on the module

After doing this, boot failed, but the fan turned on - which as I mentioned is an indication that some bit of the software has loaded.
After this I proceeded to do the following on the same module:

- Put the known good SDCARD with ArchLinuxARM on it in the SDCARD slot with the switch set to microSD boot
- Left the EMMC module in question in the EMMC slot of the Odroid-Xu4
- Booted the board successfully
- Ran the fusing script successfully on the EMMC module

After this I was able to placed the switch on the Odroid-Xu4 into the EMMC position and successfully boot into ArchLinuxARM on the odroid-xu4.

There are a couple of reasons for me posting this:

- Someone else may have the same trouble
- It appears that the ArchLinuxARM install procedure may not function for the Rock64 board on hardkernel's v0.4 EMMC modules
- If you change from an Odroid-based image on hardkernel's v0.4 EMMC module to another platform, such as Rock64 and want to go back to using it on an Odroid you will probably need to follow the recovery procedure to get the EMMC module working again


With the knowledge I gained I performed one more test with an EMMC module that was already booting ArchLinuxARM:

- I installed the EMMC module into the rev 0.2 hardkernel SD card adapter and inserted it into a USB 3.0 port on a computer running Arch Linux using the Transcend USB 3.0 MicroSD/SD adapter recommended by AmeriDroid
- I shredded the entire EMMC module from the command line with:

$this->bbcode_second_pass_code('', '# shred -n0 -vzu /dev/sda')

- Re-loaded ArchLinuxARM onto the EMMC module following the Arch Install procedure with the exception: I never ran the script to fuse the images onto the EMMC module

- Installed the EMMC module in the Odroid-Xu4 with the switch set to EMMC
- Booted the board
- It booted successfully.

Last it appears there is a bit of code that is somehow loaded onto hardkernel's v0.4 EMMC modules that perpetuates across installs regardless of using the script to fuse to the various parts of the EMMC module. I suppose that is probably because the EMMC boot block devices are not available when the EMMC module is installed in an SDCARD reader and even though I ran shred on the block device the protected boot blocks persisted across installs.

Additionally as a final conclusion it appears there is some information in at least one of the boot blocks on the EMMC module that is not touched even when performing the script to fuse the images to them, despite it reporting that it was successful.

I do have a v0.3 EMMC module from hardkernel as well and I have not tested any of this using that module yet so I don't know if this will apply to those modules or not.

I also did play around from the command line with the Odroid-XU3 booted from an ArchLinuxARM sdcard and the EMMC module I was troubleshooting in the EMMC slot. It did appear to me that the system was unable to alter the EMMC module despite issuing commands to the /sys/block devices for the EMMC module.
beakfire
 
Posts: 14
Joined: Sat Apr 21, 2018 10:13 pm

Re: Hardkernel EMMC Module Recovery and use with Rock64

Postby summers » Mon Apr 23, 2018 11:36 am

On the odroid c2, there were problems with the timing when using eMMC. Basically the signal was marginal at 200MHz, so this had to be clocked down. This was done by modifying the device tree.

So if you can run uboot from the eMMC, but after loading linux, the default file system is erratic (e.g. Read only) then the same kind of issue.

If not this, in uboot does it find the right device to load the kernel from? Look at /boot/boot.txt for the parameters needed.
summers
 
Posts: 984
Joined: Sat Sep 06, 2014 12:56 pm

Re: Hardkernel EMMC Module Recovery and use with Rock64

Postby beakfire » Mon Apr 23, 2018 9:47 pm

I'll probably try to get the EMMC module working with the rock64 another time, I did notice some errors when I was running the sd2emmc image for Xenial Mate linux provided here:

http://wiki.pine64.org/index.php/ROCK64 ... _Mate_eMMC

Granted that was with the hardkernel v0.4 EMMC module in the Rock64.

And I saw a few error messages relating to the EMMC module that the kernel gave up while attempting to boot the Rock64 from hardkernel's v0.4 EMMC module.

I also noticed it seems like hardkernel's new module is compatible with the C2 as well now, as I bought one from ameridroid for my xu4 and one for my c2 and they sent me two of the same v0.4 EMMC modules with different linux software loaded onto them, one for XU4 and one for C2 but I haven't used one of the new modules on my C2 yet.
beakfire
 
Posts: 14
Joined: Sat Apr 21, 2018 10:13 pm

Re: Hardkernel EMMC Module Recovery and use with Rock64

Postby summers » Tue Apr 24, 2018 9:05 am

Yes, what I found helpful was booting from the sd card, but with the eMMC card installed. Then you can mount the eMMC card from a running operating system, and see what errors you get ...
summers
 
Posts: 984
Joined: Sat Sep 06, 2014 12:56 pm


Return to ARMv8 Devices

Who is online

Users browsing this forum: No registered users and 6 guests