[Android Head-Units] aphilgr1:
Project LAZARUS for a totally bricked STM32 MCU unit

It has been a long adventure but I will sum it up in a few bullets:

Disclaimer! I am in no case responsible for any damage that may be caused by the following method. Try at your own risk!

Crime no 1: Flashed an Hal9k custom firmware on my unit straight out of the box. Though my unit was MTCx. It was an STM32

Crime no 2: As if this was not enough, someone in the workshop cut power during first boot.

Ended up with a totally bricked unit. Only black screen

Contacted Erisin and they sent me stock firmware and instructions how to enter recovery and flash from there

Could not enter recovery whatever I tried so I could not flash firmware

Did research on Internet

Learned that for totally bricked Rockchip devices, there is a chance to flash firmware in Maskrom mode using male to male USB cable. Some of them have 2 pins you need to bridge at power on to force Maskrom mode

Downloaded DriverAssitant_v4.6.zip and installed driver

Downloaded AndroidTool_Release_v2.52.zip and run software.

I couldn't get direct access to the chipset in my unit since it had a very strongly attached shielding that I couldn't remove. I even tried with a dremel but I was afraid not to damage the board and stopped.

Without direct access to the chipset, no documentation at hand and being totally desperate, I got kind of bold. I noticed two pinholes next to the usb connector that I bridged on power on and VOILA: the "found new hardware" chime sounded like music in my ears!!! I guess I was lucky!

Unit was recognized in Loader mode

Went to the advanced tab and selected go Maskrom. Unit got recognized in Maskrom mode

Found this link to a Russian forum with STM32 firmware in .img format and downloaded

Loaded .img firmware on AndroidTool second tab and flashed

Unit came back to life but with a 800X480 desktop on my 1024X600 display. As per instructions in Russian forum, I had to apply the 2nd firmware (.zip format)

Trying to apply 2nd firmware from within Android resulted in bricking the unit again. Had to start over (step 15)

Trying to apply Erisin stock firmware (.zip format) from within Android resulted in bricking the unit again. Had to start over (step 15)

Erisin method to enter recovery did not work. I used terminal command "reboot recovery" and entered recovery

Flashing from USB was not a n option in recovery. Only SD and ADB

Flashing from SD resulted in the following message:

-- Install /mnt/extrernal_sd/os_update_KC1E0113-PA1-1.1.4.3.1_20191212_104141.zip

E:Failed to unmount /mnt/extrernal_sd

E:failed to set up expected mounts for install; aborting

Installation aborted

I was instructed to format an SD Card in FAT32 copy the firmware there, insert into unit and restart. In my unit that didn't work but another might work. With 2 new (fast) 8Gig and 16Gig cards the unit would normally boot to Android, where with an old (slow) 1Gig reboot resulted in black screen. In any case card was not big enough to fit the firmware.

As a last resort, there was only one method left to try: apply update from ADB! Went to recovery, followed instructions to sideload the firmware and after a while there it was: LAZARUS WAS ALIVE!!! Fresh and fully functional! I even saw Android 10 in about page but I think this is falsely stated by some Chinese developer.