[Android Head-Units] alfondehesa:
First of all, thank you so much all for any help!! It's my first time posting in the forum which I think speaks to my desperation state right now:crying:, so anything is greatly appreciated!

I bought an Android 10 unit with the PX6 Rk3399 processor, but it had some bloatware that I wanted to get rid of (mainly a knock-off android auto that started when I plugged my phone in even after disabling the app and it got pretty annoying). I decided to root the unit, but it wouldn't stay rooted after restart. I then decided to let SuperSU update the SU binaries despite knowing that something could go wrong, and of course the unit went straight into bootloop:rolleyes:!

I then accessed Recovery mode by long pressing the power button (waiting for the unit to flash 5 times) then releasing and pressing again (don't ask me how I found this out). It had an option to flash updates, so I tried flashing the Kal9k Android 9 ROM, with no luck (kept getting error 1001). Then I found a firmware in update.zip form for a similar radio, with my processor and ram and etc from sygav, so I decided to flash that one using the update option on recovery. No luck though, as it was still stuck on boolook with a ford logo (as if the original system partition wasn't flashed and was still there). I couldn't access adb from recovery to see if I could delete the SU folder (if I plugged a USB cable on recovery, the computer didn't seem to see anything), so I booted into bootloader from recovery. Which by the way, was a black screen but did get picked up through USB by windows.

After tinkering with drivers for hours, I don't know how, but my unit got connected and recognized by fastboot. But in trying to erase the system partition, there was no way for system to be found:confused:. Every other partition (i.e. cache) could be erased but not system. I also couldn't flash the firmware I found because it being an update.zip, it didn't have a system.img (but it did have an image for everything else, such as boot, recovery, etc).

So I decided to flash a firmware from a guy on the internet that had a soft brick, and I flashall'd it. Now I'm starting to think this guy's firmware was for another completely different system (oh and by the way, System.img failed to flash as it couldn't find the partition, but it really was the only firmware I could find that had a system.img, so since I was completely desperate I stupidly went for it).

Now I can no longer boot into recovery, and I might be booting straight into bootloader mode, but I am not that sure:confused:. After I do the trick with the lights flashing and all, the device gets picked up by my computer, but as an unknown device:

I manually update it's drivers with the downloaded bootloader drivers from the android sdk (google USB drivers) and it gets detected as a Kedacom USB device, not an Android Device, so no fastboot:

Then if I disconnect it and connect it again, it shows up as an unrecognizable USB device or something like that.

It seems like the same problem I had when I first connected to bootloader, but I don't even know what I did to fix that :rolleyes:. I think I might have rebooted into recovery, and then from there booted into bootloader, and somehow my computer then had Android drivers available for install and I manually installed them and it worked? Maybe? I really have no idea, but I can't try that because I can't get to recovery:mad:.

I have an update.zip with what I think is the closest firmware to what my radio had originally, an Android 10 PX6 firmware, from which I was planning to install the boot, bootloader and recovery if I had access to fastboot (which I really don't know how to make windows see that it might be a bootloader device), however, since I don't have a system.img to flash and bootloader doesn't even find the system partition, I don't even know where I would go from there.

What do you guys think I should do? What are my options? Did I just hard brick my unit? I wouldn't think so because windows detects "something" even if it can't assign it the driver. But if it is hard bricked, I am not scared to open it up and to do whatever I have to do, if just am really unsure on what to do and how to do it!

Again, any help is highly appreciated! And thank you so much in advance!:fingers-crossed:;)

SOLUTION:

Alright, this was a ride! It took me about two weeks to find the solution. No matter what I flashed from the recovery, the unit would still be on bootloop, but the last thing I flashed was an update.zip I found on the internet from some guy, and that made my unit completely hard bricked and irrecoverable (no access to recovery). So here's what I did.

Apparently, reading around Rocketchips (PX3,PX5,PX6) have like a "if everything else fails" kind of mode, for stupid people like me, called MASKROM Mode. It's the last resort mode that lets you flash something on the unit when everything fails. That mode is not flashable (you can't mess it up). It's kind of like if a computer had an integrated last resort in case you mess up and break the BIOS.

To get to it though, it is kind of complicated. You need to get to the PX6/5/3 board, which is basically the heart of your radio. So start unscrewing!

The board will look something like this one:

https://sc01.alicdn.com/kf/HTB1f6tCE.R1BeNjy0Fmq6z0wVXaC.jpg

Where the top part is a heatsink that you might also have to remove. PX5s and PX3s may not look exactly like so, but look for something of more or less the same characteristics and form factor, you'll know when you see it.

Go ahead and remove the board from the unit VERY CAREFULLY (the female pin sockets break VERY VERY EASILY from what I've heard, so be very careful).

Next, we will need to connect the PX6/5/3 to the computer through USB. For that, we will have to make a custom cable. Here's the link to the forum where they explain how to make that cable in detail: https://xdaforums.com/android-auto/...px3-5-headunit-mod-recover-flash-som-t3766892

Shoutout to [MENTION=4974080]marchnz[/MENTION] , he's a genius and without his help I certainly would have wasted my $400 I spent on the headunit.

So long story short, take a USB to something cable (the ones for your phone, for instance), strip it, and solder some resistances to it in the EXACT SAME WAY as in the pictures in the first post of the forum.

Now, connect the cable in the same way as the pictures if you have a PX5 or PX3.

IF YOU HAVE A PX6 find out which pins to connect in PAGE 2 of https://xdaforums.com/android-auto/...s-development/px6-maskrom-mode-t3989407/page2 , in the pictures of a post by [MENTION=2184681]oton[/MENTION] .

Now download Androidtool here: https://github.com/rockchip-linux/tools/blob/rk3399/windows/AndroidTool_Release_v2.52.zip . This is the software that is going to let us access the mode I was talking about earlier.

Once you have it install, restart and plug in your USB end of the cable. Open the device manager on windows. If you see an Unrecognized device pop up, or a malfunctioning USB, you will need to install the drivers. Here's the link to where you can find an autoinstaller: https://github.com/rockchip-linux/tools .

If, after all, you still are having issues with the drivers, you'll need to install them manually. So right-click on the unrecognized device, update driver, browse my computer, let me pick, Have Disk, and then you find the drivers that we just downloaded (unzip them, of course). Choose the driver, and close and re-open Androidtool.

If you see Maskrom device detected on the bottom, you're all set! If you see recovery device detected, you'll have to put it on Maskrom, for good measure. It might work on recovery, but I'd put it in maskrom mode anyway. To do that, you'll have to disconnect the usb from the computer (while the other end with the cables is still hooked to the board), short two pins on the other side of the board (where the heatsink was) (for a PX6, you can find out which ones here https://xdaforums.com/showpost.php?p=80641439&postcount=435) (for a PX5, I belive it will be on the thumbnails of the first post here: https://xdaforums.com/android-auto/...px3-5-headunit-mod-recover-flash-som-t3766892) (if you can't figure out which ones, google search for pins to put your unit in maskrom). While you are shorting those pins (maybe with some metallic tweezers), plug in the usb, stop shorting the pins, and the unit should show up in maskrom.

Now dowload an update.img from the following repository: https://yadi.sk/d/umCvHqCDzHccr/RockChip PX5 Android 9/YB . If it tells you to download something, just click on the file until you get to the .rar screen and click on the download arrow on the top right of the screen.

Important: FOR MY UNIT, I HAD TO DOWNLOAD MANY UPDATE.IMG BEFORE 1 WORKED. ONLY ANDROID 8.1 WORKED FOR ME, SO KEEP TRYING! YOU'RE ALMOST THERE!

ALSO, DO NOT DOWNLOAD ANY OTGs (update.zip), ONLY DOWNLOAD IMAGES (update.img).

Now go to upgrade firmware on Androidtool, click on firmware, choose the update.img you downloaded, and start flashing it!

You'll get a progress readout on the right side, and you'll know when its done. Now it's time to put everything back together and hook up the unit and see if it worked. If it didn't or if it's in bootlooop, download another image from the repository and try again. The only one that worked for me was android 8.1.

Okay, so now everything worked and you got your Head Unit back! But what if you had to downgrade android for it?

Here's how to bring it back to its former glory:

From where I stood (android 8.1), the android 8.1 recovery wouldn't allow for android 9 or android 10 flashing. And I found some info on how to flash PX5s recoveries, but nothing on PX6, so I went to Hal9k's website and purchased his modinstaller 2 and followed instructions. Through there, you'll have the chance to update to android 9 or 10 (up to you), by running his apk that will install a new recovery on your machine, and then flashing any update.zip you want. In my case, I decided to also go for his ROM, because of the features it offered. The whole process was 10 bucks but I think it was completely worth it (honest opinion, not sponsored). You can also opt for installing and Android 10 ROM, as I had at the beginning, but I've heard they're pretty unstable.

So that's all! Not an easy project, but at the end you'll have your unit back and running!