Flash Android to eMMC

Hello,

erased my eMMC and flashed another OS on it. Now I want to go back to Android but it doesn’t work.

I used following documentation and tried it on Windows 10: https://wiki.radxa.com/Zero/install/eMMC_Android9

The flash-all.bat disconnects the device and I had to reconnect and switch to fastbootmode again. Then the script goes further. When the script is done the OS should be flashed. But in my case it only shows the first splash screen again and again. I tried it so many times and with so many things but always the same result.
Now im at a point where im not be able to turn the Radxa Zero in Fastboot mode. The bootloader.bin and the factory-loader.bin are not working anymore for it.

What am I doing wrong?
Is there a IMG file for Android to just flash with BalenaEtcher?

i have the exactly same problem. i tried so many different things from the wiki guide, and no result.
I feel like my problem is connected to Uboot. It seems like it doesnt boot at all. Screen is just black.

Same issue here. I tried In windows and Ubuntu. No Luck. I gave up and switched to Lineage OS (Used AML Flash Tool in Ubuntu to flash LineageOS)

Coreelec and Ubuntu also work fine. Their Android Image instructions are non working

Do you know if Manjaro on SD Card boots with LineageOS in eMMC?

My goal is to run Manjaro and this only works with Android installed in the eMMC.

Haven’t tried Manjaro, not a fan of Arch Based stuff.

I just reflashed Stock Android to emmc, stuck at “MBOX” logo.

Tried in both Windows and Ubuntu, same result. They need to fix this

Heres an error i got in Ubuntu

/tmp/TemporaryFile-lvYJfl: Unimplemented ext2 library function while setting up superblock
/usr/lib/android-sdk/platform-tools/mke2fs failed with status 1
mke2fs failed: 1
error: Cannot generate image for userdata

******** Did you mean to fastboot format this ext4 partition?

Android stuck at boot screen

Yes I stuck on the first boot screen too. I tried it so many times and always the same result.

Im stopping, i dont want to burn out the emmc. I switched to Coreelec. I erased with radxa-erase-emmc.bin. Plugged into Ubuntu and flashed with etcher. K*di works perfectly on the Zero

I GOT IT !!!

Install ADB/Fastboot tools (just google it) and add them Both to PATH in Windows 10 (It has to be added to path to work) (add both adb.exe and fastboot.exe to PATH)

Step 1: Hold USB Boot button and Use RZ Boot Helper to flash radxa-zero-erase-emmc.bin (this will erase the emmc so back up first if necessary)

Step 2: Open RZ Boot Helper and also Open Flash-All.bat, then Replug in while holding USB Button and flash bootloader.img from the Android image folder, the moment it stops flashing it it’ll reboot into Fastboot mode and the Flash-All.bat script will start.

Step 3: The Flash-All.bat script will STOP early and your device will disconnect, just unplug it and plug it back in. The script will finish. And board will boot into Android 9…

I already had my monitor plugged in. The MBOX logo takes a few, be patient

2 Likes

No I don’t get it. The first half of the “flash-all.bat” runs fine. But when I replug the device I have to press the USB Boot button and run the “bootloader.bin” from the android folder again. Then the script goes further. But the writing for near everything fails. How exactly do you reconnect the device? Just replug the USB cable or what you have done?

error: no devices/emulators found
< waiting for any device >
OKAY [ 0.040s]
Finished. Total time: 0.040s
OKAY [ 0.040s]
Finished. Total time: 0.040s
Sending ‘bootloader’ (1181 KB) OKAY [ 0.059s]
Writing ‘bootloader’ OKAY [ 0.060s]
Finished. Total time: 0.250s
Sending ‘bootloader-boot0’ (1181 KB) OKAY [ 0.080s]
Writing ‘bootloader-boot0’ OKAY [ 0.085s]
Finished. Total time: 0.320s
Sending ‘bootloader-boot1’ (1181 KB) OKAY [ 0.060s]
Writing ‘bootloader-boot1’ OKAY [ 0.092s]
Finished. Total time: 0.267s
Erasing ‘env’ OKAY [ 0.038s]
Finished. Total time: 0.123s
Rebooting into bootloader OKAY [ 0.000s]
Finished. Total time: 0.016s
< waiting for any device >

At this point it disconnects and I have to reconnect it.

OKAY [ 0.035s]
Finished. Total time: 0.045s
OKAY [ 0.040s]
Finished. Total time: 0.040s
Sending ‘dts’ (74 KB) OKAY [ 0.015s]
Writing ‘dts’ FAILED (Device sent unknown status code: )
fastboot: error: Command failed
Sending ‘dtbo’ (0 KB) OKAY [ 0.010s]
Writing ‘dtbo’ OKAY [ 0.025s]
Finished. Total time: 0.230s
Erasing ‘userdata’ OKAY [ 0.387s]
mke2fs 1.46.2 (28-Feb-2021)
Creating filesystem with 14238204 4k blocks and 3563520 inodes
Filesystem UUID: 3cc0c9ee-85ef-11ec-a363-63e393b01378
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424
Allocating group tables: done
Writing inode tables: done
Creating journal (65536 blocks): done
Writing superblocks and filesystem accounting information: done
Sending ‘userdata’ (316 KB) OKAY [ 0.016s]
Writing ‘userdata’ OKAY [ 0.047s]
Erasing ‘cache’ FAILED (Device sent unknown status code: )
fastboot: error: Command failed
******** Did you mean to fastboot format this ext4 partition?
Erasing ‘param’ OKAY [ 0.031s]
Finished. Total time: 0.108s
******** Did you mean to fastboot format this ext4 partition?
Erasing ‘tee’ OKAY [ 0.031s]
Finished. Total time: 0.115s
Sending ‘vbmeta’ (4 KB) OKAY [ 0.016s]
Writing ‘vbmeta’ OKAY [ 0.016s]
Finished. Total time: 0.163s
Sending ‘odm’ (524 KB) OKAY [ 0.031s]
Writing ‘odm’ FAILED (Device sent unknown status code: )
fastboot: error: Command failed
Sending ‘logo’ (1386 KB) OKAY [ 0.069s]
Writing ‘logo’ OKAY [ 0.069s]
Finished. Total time: 0.277s
Sending ‘boot’ (9390 KB) OKAY [ 0.443s]
Writing ‘boot’ FAILED (Device sent unknown status code: )
fastboot: error: Command failed
Sending sparse ‘system’ 1/6 (131068 KB) OKAY [ 6.003s]
Writing ‘system’ FAILED (Device sent unknown status code: )
fastboot: error: Command failed
Sending sparse ‘vendor’ 1/2 (120948 KB) OKAY [ 5.611s]
Writing ‘vendor’ FAILED (Device sent unknown status code: )
fastboot: error: Command failed
Sending ‘recovery’ (15920 KB) OKAY [ 0.733s]
Writing ‘recovery’ FAILED (Device sent unknown status code: )
fastboot: error: Command failed
Sending ‘product’ (3680 KB) OKAY [ 0.178s]
Writing ‘product’ OKAY [ 0.142s]
Finished. Total time: 0.457s
OKAY [ 0.031s]
Finished. Total time: 0.031s
OKAY [ 0.038s]
Finished. Total time: 0.038s
Rebooting OKAY [ 0.000s]
Finished. Total time: 0.000s

All I did was run the flashall.bat when it disconnected I just unplugged and plugged back in. I didn’t hold down the USB button at the point where it disconnects

Holding down the USB button puts it in Maskrom Mode. You want it in fastboot mode not Maskrom

When I unplug and replug it, it wants to boot the half flashed OS and it shows the first splashscreen again and again. To come in fastboot mode again I have to replug it with the USB button and execute the bootloader again.

Did I forgot something to execute that my Radxa Zero doesn’t comes into Fastboot mode again in the middle of the flash-all script?

Can you try modify the flash-all.bat and delete fastboot reboot-bootloader line that’s above ping command? I flashed Android with flash-all.sh in Linux before without problem so this is the difference between those 2 files.

hi, have your rom setting wifi?

Hello Radxa,
in my case the flash-all.bat does not run till the end. It always seems to fail at
fastboot flash system system.img

I tried to erase fastboot reboot-bootloader. That did not change anything. Re-plugging in also did not change anything in the script.


OKAY [ 0.035s]
finished. total time: 0.035s

OKAY [ 0.036s]
finished. total time: 0.037s
target reported max download size of 134217728 bytes
sending ‘bootloader’ (1181 KB)…
OKAY [ 0.063s]
writing ‘bootloader’…
OKAY [ 0.099s]
finished. total time: 0.163s
target reported max download size of 134217728 bytes
sending ‘bootloader-boot0’ (1181 KB)…
OKAY [ 0.064s]
writing ‘bootloader-boot0’…
OKAY [ 0.951s]
finished. total time: 1.016s
target reported max download size of 134217728 bytes
sending ‘bootloader-boot1’ (1181 KB)…
OKAY [ 0.063s]
writing ‘bootloader-boot1’…
OKAY [ 0.950s]
finished. total time: 1.014s
erasing ‘env’…
OKAY [ 0.031s]
finished. total time: 0.032s

OKAY [ 0.035s]
finished. total time: 0.036s

OKAY [ 0.034s]
finished. total time: 0.035s
target reported max download size of 134217728 bytes
sending ‘dts’ (74 KB)…
OKAY [ 0.014s]
writing ‘dts’…
OKAY [ 0.164s]
finished. total time: 0.179s
target reported max download size of 134217728 bytes
sending ‘dtbo’ (0 KB)…
OKAY [ 0.012s]
writing ‘dtbo’…
OKAY [ 0.025s]
finished. total time: 0.038s
Creating filesystem with parameters:
Size: 4271882240
Block size: 4096
Blocks per group: 32768
Inodes per group: 8160
Inode size: 256
Journal blocks: 16295
Label:
Blocks: 1042940
Block groups: 32
Reserved block group size: 255
Created filesystem with 11/261120 inodes and 34738/1042940 blocks
target reported max download size of 134217728 bytes
Creating filesystem with parameters:
Size: 1174405120
Block size: 4096
Blocks per group: 32768
Inodes per group: 7968
Inode size: 256
Journal blocks: 4480
Label:
Blocks: 286720
Block groups: 9
Reserved block group size: 71
Created filesystem with 11/71712 inodes and 9348/286720 blocks
erasing ‘userdata’…
OKAY [ 0.068s]
sending ‘userdata’ (68573 KB)…
OKAY [ 3.022s]
writing ‘userdata’…
OKAY [ 2.771s]
erasing ‘cache’…
OKAY [ 0.045s]
sending ‘cache’ (20320 KB)…
OKAY [ 0.903s]
writing ‘cache’…
OKAY [ 0.875s]
finished. total time: 7.687s
******** Did you mean to fastboot format this partition?
erasing ‘param’…
OKAY [ 0.035s]
finished. total time: 0.036s
******** Did you mean to fastboot format this partition?
erasing ‘tee’…
OKAY [ 0.034s]
finished. total time: 0.035s
target reported max download size of 134217728 bytes
sending ‘vbmeta’ (4 KB)…
OKAY [ 0.010s]
writing ‘vbmeta’…
OKAY [ 0.024s]
finished. total time: 0.036s
target reported max download size of 134217728 bytes
erasing ‘odm’…
OKAY [ 0.036s]
sending ‘odm’ (524 KB)…
OKAY [ 0.033s]
writing ‘odm’…
OKAY [ 0.054s]
finished. total time: 0.126s
target reported max download size of 134217728 bytes
sending ‘logo’ (1386 KB)…
OKAY [ 0.072s]
writing ‘logo’…
OKAY [ 0.086s]
finished. total time: 0.159s
target reported max download size of 134217728 bytes
sending ‘boot’ (9392 KB)…
OKAY [ 0.424s]
writing ‘boot’…
OKAY [ 0.415s]
finished. total time: 0.841s
target reported max download size of 134217728 bytes
erasing ‘system’…
OKAY [ 0.077s]
sending sparse ‘system’ (131068 KB)…
OKAY [ 5.850s]
writing ‘system’…
OKAY [ 5.427s]
sending sparse ‘system’ (131068 KB)…
OKAY [ 5.853s]
writing ‘system’…
OKAY [ 5.183s]
sending sparse ‘system’ (131068 KB)…
FAILED (unknown status code)
finished. total time: 22.444s

Hi. Any luck fixing this?

I tried several times to load Android onto a Zero but no luck.

If I remove the line fastboot reboot-bootloader from flash-all.bat the system loads but the Zero is stuck in the MBOX screen.

I can adb into the Zero. The command ps -A shows lots of processes running.

Anybody any thoughts?

MPC

All I did was run the flashall.bat when it disconnected I just unplugged and plugged back in. I didn’t hold down the USB button at the point where it disconnects