yashsingh1/xdaforums huggingface dataset:
[Huawei MediaPad M5  Guides, News, & Discussion] Si73:
This is not a guide as such but more of direction to other peoples hard work and effort. I am not a developer, just an experimenter!

Main Credits - [MENTION=7050182]MishaalRahman[/MENTION] and [MENTION=1915408]phhusson[/MENTION].

For me one of the main selling points of the Mediapad M5 was being Project Treble enabled. Being a big Nexus/Pixel fan I am not particularly fond of EMUI.

So after reading this detailed and clear guide by Mishaal Rahman http://www.xda-developers.com/flash-generic-system-image-project-treble-device/, I was able to successfully install an AOSP Generic System Image by phhusion http://xdaforums.com/project-treble/trebleenabled-device-development/experimental-phh-treble-t3709659

My device - CMR-W09 (10.8" non pro wifi).

I flashed v17 with Gapps and SU and apart from an Android System error upon boot it seems to work ok. I have not had much time to play with it but so far Wifi, Bluetooth, sound, camera, fingerprint sensor, MTP and SD card appear to be working. I had issues with google play not downloading apps but worked after clearing data/cache on google play and google play services. Also have issues with superuser force closing.

For the nervous and unsure, you can easily return to stock Huawei firmware by flashing your devices stock system.img in fastboot.

Obviously bootloader needs to be unlocked see guide - https://xdaforums.com/mediapad-m5/how-to/bootloader-unlock-guide-t3781275 by [MENTION=1192060]Apo11on[/MENTION]. You can use Apo11on's root guide to download your firmware to get your stock system.img.

OEM needs to be disabled in developer options.

It is best to factory reset via recovery mode and then boot straight into bootloader to keep FRP unlocked.

Do this at your own risk but please read all the available information and guides on XDA.

pphusion has made other Project Treble roms but I have yet to try them. Hopefully it would be nice if someone could fully develop Lineage for this device.
[Huawei MediaPad M5  Guides, News, & Discussion] florian-m19:
which rom did you use ? the A/B one or A only ?
[Huawei MediaPad M5  Guides, News, & Discussion] fargonaz:
It's an A-only device.

I tried AOSP with GAPPS and SU but SuperSU shows the su binary as being occupied through several reboots. Getting the Lineage GSI now and will root with magisk.

Edit:

Blah... Lineage is not an option until we have twrp :/ (at least for me) No way to install GAPPS.

Edit:

SU works with phh's super user available from the play store.
[Huawei MediaPad M5  Guides, News, & Discussion] florian-m19:
Yes i have the AOSP one now on my AL-09 and it works fine till now. Bugs : home Button not working but fingerprint works, supersu with the phhs one works. Bluetooth sometimes gives an error message. Battery drain is a little bit high. I installed the Huawei camera apk from treble forum and This works also good.

Another Bug is Apps sometimes force closing but Not often.

How is Lineage performing?
[Huawei MediaPad M5  Guides, News, & Discussion] Varyak:
A little bit off topic, but how did you unlock the bootloader on the Wifi only version since the website for the code is offline for a few weeks now?

Thanks in advance.

Fantastic to see that Treble works.
[Huawei MediaPad M5  Guides, News, & Discussion] fargonaz:
On my AL09(ASOP with gapps and su) bluetooth never connects to any of my devices and fc on pairing.

Lineage was a non-starter, since I was unable to get gapps running. I was also getting a vendor mismatch toast. I'm back on the stock .125(C00), no working tether is infinitely more useable than no BT.

It was nice to be able to flash something that didn't brick it and was partially useable.
[Huawei MediaPad M5  Guides, News, & Discussion] florian-m19:
I understand, Do you think it gets more stable for our device in the future?
[Huawei MediaPad M5  Guides, News, & Discussion] fargonaz:
I think so, if you look at the github comments there is a huawei phone having the same problem, so as long as a phone is having problems it should get fixed:eek:
[Huawei MediaPad M5  Guides, News, & Discussion] tabletmen:
We would like some screenshots to see if this is real ;) [MENTION=2188693]AndDiSa[/MENTION] [MENTION=5621191]rcstar6696[/MENTION] [MENTION=1915408]phhusson[/MENTION] [MENTION=7050182]MishaalRahman[/MENTION]
[Huawei MediaPad M5  Guides, News, & Discussion] Varyak:
Just installed it, attached a few screenshots. Haven't tested it a lot, but it boots.
[Huawei MediaPad M5  Guides, News, & Discussion] florian-m19:
Wie are Not joking, its real ??
[Huawei MediaPad M5  Guides, News, & Discussion] florian-m19:
Delete, double post
[Huawei MediaPad M5  Guides, News, & Discussion] darren1:
I will be getting my Mediapad M5 8.4 tomorrow and will be flashing the AOSP treble build straight away. Just a heads up a updated build has just been posted with some Huawei related fixes.
[Huawei MediaPad M5  Guides, News, & Discussion] florian-m19:
i flash it now, and give feedback tomorrow :)
[Huawei MediaPad M5  Guides, News, & Discussion] fargonaz:
I flashed the new one with gapps and su, and for the sht-l09 there is no working bluetooth, so that's as far as I go. It will be nice when the BT is fixed for this device.
[Huawei MediaPad M5  Guides, News, & Discussion] florian-m19:
Works good with dirty flash, Home Button is working now and also Automatic Brightness, but battery draining is really high and it gets hot.
[Huawei MediaPad M5  Guides, News, & Discussion] darren1:
Have you tried changing the cpu governor? Is it set to something like interactive? I got my Mediapad today but I am waiting for the bootloader unlock code from Huawei.
[Huawei MediaPad M5  Guides, News, & Discussion] florian-m19:
yes it is on interactive, should i change this ?
[Huawei MediaPad M5  Guides, News, & Discussion] darren1:
Might be worth experimenting with. Try conservative or ondemand if they are available. You can always change back if it doesn't make any difference.
[Huawei MediaPad M5  Guides, News, & Discussion] florian-m19:
okay i change it in helix engine to ondemand and the suspend engine is now on powersafe.
[Huawei MediaPad M5  Guides, News, & Discussion] kev1807:
Has someone tried on a Pro Version?
[Huawei MediaPad M5  Guides, News, & Discussion] Varyak:
Anyone successfully managed to flash back to stock? I downloaded the original firmware and extracted the system.img, but when flashing with fastboot it fails.
[Huawei MediaPad M5  Guides, News, & Discussion] hellord01:
You can flash back to stock in erecovery mode.
[Huawei MediaPad M5  Guides, News, & Discussion] Varyak:
Can you give any more details? If you mean the thing with the dload folder and the update.app than its not working, because the file is too big.
[Huawei MediaPad M5  Guides, News, & Discussion] hellord01:
Press Volume Up for 3 secs after boot. then you need connect to wifi and will download latest version.
[Huawei MediaPad M5  Guides, News, & Discussion] Si73:
I flashed system. img back to stock via fastboot with no issues. Maybe try a factory reset in recovery first.
[Huawei MediaPad M5  Guides, News, & Discussion] Varyak:
I will try that out. Can you tell me what stock rom did you use if you have a eu version? I've tried the CMR-W09C432B123 full ota.
[Huawei MediaPad M5  Guides, News, & Discussion] Si73:
That's the same firmware I used.
[Huawei MediaPad M5  Guides, News, & Discussion] Varyak:
Okay I tried a factory reset and it made it even worse. Now when trying to do anything via fastboot I get "command not allowed", I've checked the developer options and the "oem unlock" setting is toggled off and greyed out, so I can't set it active again.

Also trying to flash something via erecovery always fails with "getting package info failed".

Does anyone have any other idea how to go back to stock?

Edit:

I managed to reflash stock with dc phoenix. Spend a bit of money, but it at least worked.
[Huawei MediaPad M5  Guides, News, & Discussion] rcstar6696:
Anyone tested it on the m5 pro version ? i think it will boot but the interessting thing is does the pen and keyboard are working
[Huawei MediaPad M5  Guides, News, & Discussion] Sebianoti:
Works great on my 10.8 non pro tablet, much better than Hauwei's skin, now if only it didn't think it was a phone and came with all the google apps Pixel C came with by default.
[Huawei MediaPad M5  Guides, News, & Discussion] Sebianoti:
Oh and supported quick charging, by far the biggest con to switching from EMUI is losing quick charge.
[Huawei MediaPad M5  Guides, News, & Discussion] daser4berlin:
And how is the battery life?
[Huawei MediaPad M5  Guides, News, & Discussion] Sebianoti:
I'd say it's on par with EMUI
[Huawei MediaPad M5  Guides, News, & Discussion] rcstar6696:
Today i tested a unreleased LOS build on my m5pro all works great here nothing seems to be broken

Keyboard and pen are still working
[Huawei MediaPad M5  Guides, News, & Discussion] theCroh:
Are there builds that have GApps included or do you just have to do without them until (if) we get TWRP for the device?
[Huawei MediaPad M5  Guides, News, & Discussion] rcstar6696:
No i use a build with gapps

Send me a pm
[Huawei MediaPad M5  Guides, News, & Discussion] kev1807:
Can you please try to extract Nebo for Huawei from Stock? I am really using this on a more than daily basis, so that I would not want to lose it... Note taking when reading texts for Uni or Papers I have to hand in...

It does not come with any special features that are no part of the regular nebo app, so I guess we should be able to install it safely without too much fuzz....

Other than that: As Huawei was kind of doing the minimum for the device I think it's an upside, having root and being able to customize Pen-Buttons etc..... :D

I think you mentioned elsewhere that Quick Charge is ported to Lineage, but I cannot find the thread anymore (probably over at android-hilfe)

Thanks for the great work!

I am waiting for a few more days and I need a way to backup all my important stuff before I switch to anything...

:D
[Huawei MediaPad M5  Guides, News, & Discussion] Sebianoti:
It fails getting info, I'm stuck now, can't go back to stock and something somewhere broke and only Google apps work, everything else crashes on phh-trebble for me.
[Huawei MediaPad M5  Guides, News, & Discussion] darren1:
I had the same problem. Have a look here

https://github.com/phhusson/treble_experimentations/issues/37

Im pretty sure wiping data in fastboot and then booting straight into recovery and letting it format data without booting in between is what fixed mine.
[Huawei MediaPad M5  Guides, News, & Discussion] Sebianoti:
I can't begin to thank you enough, I've spent 8 hours yesterday on this and was starting to go insane. I did fastboot -w then in recovery wiped data again, didn't have many hopes booting after since fastboot commands returned with "FAILED" and the wipe in recovery lasted all but 1 micro-second, but it seems to work, apps are downloading and not crashing!
[Huawei MediaPad M5  Guides, News, & Discussion] darren1:
I lost a fair few hours as well, glad it worked.
[Huawei MediaPad M5  Guides, News, & Discussion] valko8877:
Tried to flash it, too. Worked flawless, even then I forgot to disable OEM. Flashing, wiping, a few bootloops was all it took.
[Huawei MediaPad M5  Guides, News, & Discussion] LOGMD:
I got v20 working on mine. But it's in anwierd state now. Bootloader unlocked, FRP locked and OEM unlock is greyed out (says bootloader already unlock)

Wanted to go back to stock until next build .

I believe I missed booting back into bootloader - any ideas how to solve this?

ERecovery keeps showing errors for package info
[Huawei MediaPad M5  Guides, News, & Discussion] dkk6:
Hi, does anyone have this problem with the device trying to boot every time connected to a USB, when the tablet is in power off state? I tried with Phhs treble and Resurrection, but I aways get this behaviour. I am flashing it on SHT-W09. It looks like it tries to load the charge animation, but it can't and it ends up in the Huawei eRecovery after few attempts. This happens only when I connect it from power off state only, if I just try to power it on from the hardware button it's all fine.
[Huawei MediaPad M5  Guides, News, & Discussion] LOGMD:
I just tried this and had the same result - this may be a problem on completely dead tablet. On my Lenovo p8 on compete dead it would vibrate and try booting on usb connect. The vibrate killed the battery and the it cycled like that. Hopefully the M5 is designed well enough not to allow that to happen
[Huawei MediaPad M5  Guides, News, & Discussion] dkk6:
I get this behaviour every time the tablet is in power off state no matter the battery level. I posted the same question on the Resurrection Treble tread (the ROM I'm with), and they suggested it's a matter of treble ROMs not supporting fast charge. Wish there was a way of disabling this or at least making it boot straight into system when connected to a USB from power off.
[Huawei MediaPad M5  Guides, News, & Discussion] LOGMD:
Strange because v20 added Huawei fast charge and the M5 has a Huawei fast charge compatible charger. Are you on v19 or 20? I can't switch because my frp got locked and imnstock on v20 until magic happens or I hack another solution out of this
[Huawei MediaPad M5  Guides, News, & Discussion] dkk6:
I will try today v20, because I don't remember if I have tried that, but I've tested v19 and it wasn't working and now I am with Resurrection Remix v4 and it's not working as well.
[Huawei MediaPad M5  Guides, News, & Discussion] Lee82UK:
Can anyone comment on the GPU performance (gaming etc) on the treble roms? Is it comparable to the stock EMUI oreo?
[Huawei MediaPad M5  Guides, News, & Discussion] dkk6:
[MENTION=2680726]LOGMD[/MENTION] , just tested charging on v20 and the same result. The tablet goes into eRecovery. It looks like charging from power off is not working on any of the trebles.
[Huawei MediaPad M5  Guides, News, & Discussion] LOGMD:
Yeah i realised this now too when I tried recovering my device. Did your frp not get locked when moving over to v20? Or have u not factory reset yet.

For phh ROM maybe it's a bug that they don't take into account frp is locked for the OEM unlock status. If the code checks both bootloader unlock and frp locked them this problem can go away

Aside from Bluetooth issues the ROM runs fairly stable.

Do any of you guys get adb connection when in the recovery? (Not twrp - stock) seems to be a log running issue for huawei
[Huawei MediaPad M5  Guides, News, & Discussion] Marcopoloy13:
Hey,

I want to buy the MediaPad M5 10" now finally and want to unlock, root and install an GSI directly, but after reading the threads here about it I still have some questions about it.

I read a few times that after installing the phh GSI v20 the "frp is locked", what is it and what does it mean? Is it that unpossible to flash any img file so no GSI updates can't installed or is it just impossible to get back to stock?

I understand that I have to choose an img file with SU and GApps, but I also find a thread with a guide to root by patching the ramdisk. Do I have to do this first or is it enough to flash the GSI to get root?

Its my first Huawei device and I see that's way more complicated to root and get an custom GSI to work, but have to get root and a vanilla android ROM - If I buy one now, I know I can't get an unlock code by Huawei anymore, but its still working with the dc-unlocker or? And if its failed to unlock, nobody can see that I have tried to unlock, so I still can send it back, right?
[Huawei MediaPad M5  Guides, News, & Discussion] JamesBott:
[MENTION=3338024]Marcopoloy13[/MENTION]

If you buy 1 actual Huawei/Honor device with OREO - root is simpel.

Now give us Huawei the bootloader unlock-code (for next 2..3 Weeks), then close Huawei this for the future.

dc-unlocker work simpel if you get the unlock-code over this way. the cost is 4€.

Have you the bootloader unlockt - it's a very good idea BEFORE you flash anything : look in HuaweiFirmwareFinder and search

"your build" (my Pad : Huawei Mediapad M5 - CMR-AL09 8.0.0.151(C432) / search in FF = CMR-AL09C432B151)

Download your build (C432 = country, B151 = build-nr). A lower "Bxxx" is better as nothing !

With HuaweiUpdateExtractor extract from Update.app(inside Update.zip) 3 Partitions

- ramdisk.img

- recovery_ramdisk.img

- system.img

the Extractor make automatic for *.img 1 *.img.header. Copy this 6 files to your ADB-Folder.

NOW you can experiments with other ROM ...

AND you have a good chance for reset your device to stock-rom !!!

To root the device - install the magisk.app, run this, let magisk your "boot" modify (copy ramdisk.img to device/download)

magisk ask you "how is boot.img" then select device/download/ramdisk.img (boot is inside ramdisk)

magisk modify ramdisk.img and save to device/MagiskManager/patched_boot.img

copy patched_boot.img to your PC in your ADB-Folder

boot your device in bootloader.mode

- fastboot flash ramdisk patched_boot.img

reboot device and run magisk.app and check "device is rooted"

If you need : fastboot flash ramdisk ramdisk.img AND device is reset to stock-rom.

VERY IMPORTANT : All what you do with your device - you do at your own RISK !

more info ? read

https://xdaforums.com/mediapad-m5/how-to/huawei-mediapad-m5-twrp-test-t3798349

https://xdaforums.com/mediapad-m5/how-to/huawei-mediapad-m5-install-magisk-t3795753
[Huawei MediaPad M5  Guides, News, & Discussion] Marcopoloy13:
[MENTION=3600801]JamesBott[/MENTION]

Thx.

That means I have to do this first, it's not enoch to flash an GSI img with SU?

And what's about the frp is locked thing?
[Huawei MediaPad M5  Guides, News, & Discussion] JamesBott:
[MENTION=3338024]Marcopoloy13[/MENTION]

If you flash an GSI "system.img" and all work : no problem.

If inside GSI SU and all work : no problem and device is rootet.

The FullUpdate and the extracted 3 Partitions is Backup for Error's and for self-repair. This is the "save-way" :)

FRP = Factory Reset Protection

For more info search inside xda-developer

1 save-way : if you boot in bootloader-mode look

- BL=unlocked

- FRP=unlock

check in Menu/Developer-Options if "OEM-Entsperrung aktivieren" activ

if FRP=locked you NOT can flash anything
[Huawei MediaPad M5  Guides, News, & Discussion] 04nd01:
Does this mean the device would essentially be bricked if you ever let the battery run empty? Or will it still boot while plugged in?
[Huawei MediaPad M5  Guides, News, & Discussion] MP420:
I unlocked my M5 8.4" (SHT-AL09) with this Guide [1]. But auto-detection (step #9) didn't work, had to install the HiSuite - i used HiSuite_5.0.2.301_OVE.exe.

Then i flashed "LineageOS Beta 4" from OpenKirin [2], following this instructions [3]. Now I've got "15.1-20180611-UNOFFICIAL-treble" running. No problems so far. The Netflix app won't install from the Play Store, but an apk worked. Looks like it only streams in SD by now, but thats ok for me.

[1] https://xdaforums.com/mediapad-m5/how-to/bootloader-unlock-guide-t3781275

[2] https://openkirin.net/download/

[3] https://openkirin.net/user_guide/openkirin-rom-installation-instructions/
[Huawei MediaPad M5  Guides, News, & Discussion] Marcopoloy13:
Hey thx so far.

I have the Tablet now and tried following youre steps, but I have a problem.

My build is CMR-W09 8.0.0.122(C432),

the HuaweiFirmwareFinder cant find this exactly, it shows CMR-W09 builds but with different country codes, no C432. I thing that could be a problem or?

I mean I can give in CMR-W09C432 - its in the search list on the main page but on the Firmware tab its listes CMR-W09C00B128 (8.0.0.128), CMR-W09C567B156 (8.0.0.156)

and 5 more with different C numbers.
[Huawei MediaPad M5  Guides, News, & Discussion] JamesBott:
[MENTION=3338024]Marcopoloy13[/MENTION]

Find owen build on FF is a problem.

On FF is stored what other Users have saved on Updates.

All User need the "owen build". We can not update with other "C".

If you not find your "C" (C432) you can not update/repair with other "C" (example: C00).

There are differences from "C" to other "C".

You have 2 Chance:

- check FF if sometime your build is available

- wait if Update in your Device with OTA available

- - if your device rooted

- - if File-Explorer with root installed

- - your device write "new Update install now ?"

then answer "not now, later" and copy the Update from /data/update... to external-sd and from there to your PC

then you can install the Update (Attention: OTA-Update work ONLY with stock-recovery)

Other chance i dont see
[Huawei MediaPad M5  Guides, News, & Discussion] Marcopoloy13:
Ok, I searched a little bit and found the right build - CMR-W09C432B123 (8.0.0.123) FullOTA

The weird thing is, I found it on the website from the Firmware Finder so I don't know why the App didn't show me the right download but whatever.

Did extract the 3 files you mention and have the 6 files now.

On my first try importing the file to the UpdateExtractor it give my an Error, something with Invalid Header, first after unchecking the 2 option for verifying it works - can this be become a problem later or doesn't it matter?
[Huawei MediaPad M5  Guides, News, & Discussion] JamesBott:
un-check in Extractor is "normal"

i have un-check all. all devices work with extracted *.img - no problems

all user how flash any - "must have" = the 3 *.img !

congratulation : now you have 1 backup if any problem !
[Huawei MediaPad M5  Guides, News, & Discussion] Marcopoloy13:
Thx [MENTION=3600801]JamesBott[/MENTION] for youre help, have now unlocked Bootloader.

I want to flash a Trebels ROM - system.img for A-only ARM64 devices with GApps and SU - right?

I read here earlier, that with flashing v20 frp get locked - is this still a problem with v21 and how can I avoid it?

How to flash it right, just flashing the system.img via adb in bootloader and after it to recovery and doing a factory reset? And how can I get to recovery then?

Edit:

Ok just read first factory reset than in Bootloader "fastboot erase system" that "fastboot -u flash system name_of_system.img", is this right this way?
[Huawei MediaPad M5  Guides, News, & Discussion] JamesBott:
My interest for developer-rom (system.img) at this moment is purely academic :)

i have tested many (last phhouson a-only system.img) and after ALL reset to stock-rom.

On my devices is stock-rom good for me for work - to for stock no updates available.

This is the time-point for me to install other system.img. I think after 2 year from now :)

If you need self testing treble-system.img is the save way

- install TWRP (with encrypting)

- TWRP / Backup : system and data

- TWRP wipe data

- boot from TWRP to Bootloader

- fastboot flash system new-system.img (fastboot erase system = not needed, flash new-system overwrite old-system)

now you can test

if you need restore last state

- TWRP Recovery from last Backup

I am LineageOS Fan (many years). With OREO and Treble is new era comming.

The first developer-rom were adapted Nougat - creepy !

Now work developer on treble-images - all ways better :)

The other question is - what's my device in 2 years ;)