I have obtained the stock firmware for my device, how hard would it be to build generic android? - General Questions and Answers

Hi, I just registered today to ask this question. Through somewhat simple means using the tools I had available, I was able to readback the stock rom from a TCL 20 XE 5087Z branded under Boost Mobile. I have successfully rooted via magisk and have confirmed that it is indeed the correct stock firmware through a bit of an accident, I forgot to patch vbmeta when flashing magisk_patched_boot.img, so in a panic, I flashed back all the roms I had read back from the device except userdata, and miraculously the device worked! Now the problem I run into is all the bloatware the carrier has installed on the phone. My main reason for rooting my device was I wanted the ability to prevent apps from being killed by the "Smart" manager on the device, because it seems that important apps keep getting killed by the built-in software. I ended up determining that the ram manager on the phone was killing apps based on the amount of ram available. Now that the phone is rooted, you would think I would have no problem getting rid of all the bloatware, except that whenever I forcefully uninstall the ram manager (com.tct.onetouchbooster), the app is still available on my apps menu and clicking on it with pretty much no delay opens the app right up as if the data had just been cleared. Now I have no idea what is causing this, probably another app, but I was wondering if maybe an easier alternative would be to get a generic android image for the device without bloatware that I can install just what I need. Now I say easier, but I find little documentation on how to do this, better yet if it will work. I have limited knowledge of how the android system works, mainly I just understand that /boot contains the bootloader, /system contains the os, and /userdata contains all the extra data apart from the stock image. If someone would enlighten me, would it actually be easier to build a generic image? Are there tools to do this? I understand that firmware is very touchy and that there is no "Generic" image in the sense, but having my stock rom available, would I be able to somehow generate a generic image based on the rom contents? If this would be way harder, how would I go about removing bloatware? I would not want to have to reset my phone each time I uninstall the wrong application, is there a non-data-damaging way to go about removing bloatware? If it ends up not being bloatware that is causing it and some hidden property somewhere in the stock rom config, how hard would it be to find that? Any help would be appreciated, and I am open to any comments and criticism. Please let me know how I might go about this, thanks in advance!
The stock firmware for this device can be found here: https://drive.google.com/file/d/1Q5IDP8V7PvuH2_1z63IFe23O2DF0cXZR/view?usp=sharing
The phone was bought from Walmart with prepaid Boost Mobile and it is a TCL 20 XE 5087Z with a MT6765 processor.
The password for the file is: xda5087Z-MT6765

Is the phone Project Treble enabled? If not don't waste your time.
A GSI is related to Project Treble, which means that the image can be installed on any Project Treble-supported device, regardless of the manufacturer, because it does not contain any hardware-specific components. The advantage is that a GSI can theoretically be used on any Project Treble-supported device.

xXx yYy said:
Is the phone Project Treble enabled? If not don't waste your time.
A GSI is related to Project Treble, which means that the image can be installed on any Project Treble-supported device, regardless of the manufacturer, because it does not contain any hardware-specific components. The advantage is that a GSI can theoretically be used on any Project Treble-supported device.
Click to expand...
Click to collapse
I downloaded the treble info app from the play store and indeed it is available with treble, the system image i need is system-arm64-ab.img.xz, would you mind pointing me in the right direction for how to install this? I'm assuming this just gets installed in the /system partition but let me know if I'm wrong. Thanks!

Can't help you, never did this.
You may look inside here:
[GUIDE] How to build a Project Treble GSI ROM from source? [31/08]
Hello guys, in this guide I'll try to simplify building Treble GSI process. As you read this guide now I'll assume you already have a previous knowledge about How to build android from source, so I won't cover some points with too many basic...
forum.xda-developers.com

Yes, only flash system.img. I recommend Android 10 (Android 11+ introduced restricted permissions)
[DISCONTINUED][GSI][10] LineageOS 17.x GSI (all archs)
Background: This is a natural continuation/extension of the LineageOS 16.0 GSIs I've been making since March 2019. If you clicked in here, I bet you know what LineageOS is already, but just to fill the blank: LineageOS is a free, community built...
forum.xda-developers.com

alecxs said:
Yes, only flash system.img. I recommend Android 10 (Android 11+ introduced restricted permissions)
[DISCONTINUED][GSI][10] LineageOS 17.x GSI (all archs)
Background: This is a natural continuation/extension of the LineageOS 16.0 GSIs I've been making since March 2019. If you clicked in here, I bet you know what LineageOS is already, but just to fill the blank: LineageOS is a free, community built...
forum.xda-developers.com
Click to expand...
Click to collapse
DO NOT DO THIS!!!! The TCL 20 XE is NOT compatible with Android 10 (it only supports something 30, which corresponds to Android 11), and the device will bootloop. I have made this mistake but I can not reach fastboot as the option is not in the recovery, therefore I need to run "adb reboot fastboot" within Android. MTKClient should fix this if you can find a stock super.img file for the 5087z.

note "adb reboot fastboot" is for fastbootd which is in recovery, while "adb reboot bootloader" is for fastboot (you can always enter from Volume button, regardless of destroyed boot/system partition)
boot-loop is probably caused by dm-verity, you forgot vbmeta?

alecxs said:
note "adb reboot fastboot" is for fastbootd which is in recovery, while "adb reboot bootloader" is for fastboot (you can always enter from Volume button, regardless of destroyed boot/system partition)
boot-loop is probably caused by dm-verity, you forgot vbmeta?
Click to expand...
Click to collapse
Fastbootd doesn't have an option in the recovery on my model, I've seen other TCL 20 XE phones have it though (I have the Boost Mobile varient like the thread maker), however Fastbootd let's me boot into recovery. I was only able to flash the stock ROM with MTKClient, which mikedcoombs thankfully provided (I just needed the super partition). For vbmeta, I just have an empty vbmeta that I flashed when I first rooted the phone. I don't think it is dm-verity, because LineageOS 20 as an GSI worked except for the Wi-Fi.

Related

[ROM][UNOFFICIAL] LineageOS 17.1 for Unihertz Atom L (20200828)

Introduction
This thread contains the LineageOS 17.1 custom firmware images for the Unihertz Atom L, a rugged Android phone released by Unihertz in July 2020, and the accompanying LineageOS Recovery used for flashing the firmware.
Please note that this ROM is one of my side projects, for which I could provide zero warranty. By installing this ROM, you acknowledge that you take all the risks that come with installing custom firmwares on your devices, including but not limited to bricking your device, losing your data, etc. You are always suggested to keep backups and make sure you know how to flash back to official ROM before trying any custom ROMs.
Please find the download links in the Download section. The following sections are guides to installing the ROM.
WARNING: DO NOT try to install this on Atom XL. This is ONLY for the Atom L.
Working Features
- All basic features (Telephony, VoLTE, Audio, Camera, NFC, WiFi, Bluetooth, ....)
- Programmable PTT (red) button (Functionality can be set in Settings - System - Buttons, under the "Search Button" section)
- 48MP camera seems to be working (unlike on many other super resolution devices)
Known Issues
- VoLTE is working (at least for me) but sometimes quirky. If you find it somehow stopped working, usually turning it off and back on again (in Settings - Network - Mobile Network) will fix it. Putting the device to SELinux Permissive mode also fixes most of the VoLTE quirks but this is not recommended (a few quirks in Enforcing mode is better than having the whole device Permissive)
Unlocking
1. Boot your Atom L to the official OS
2. Go into Settings - About phone, tap "build number" several times to enable developer settings
3. Go to Settings - System - Developer Settings, enable OEM unlocking and ADB debugging
4. Run `adb reboot bootloader` on your PC (there is no way to enter bootloader directly, only possible through adb)
5. Run `adb flashing unlock` and comfirm unlock on device (THIS WILL WIPE ALL DATA)
6. Reboot and now you should see an unlocked warning during boot screen.
Installing LineageOS Recovery
For now the only working recovery is the LineageOS Recovery, because the device's kernel does not load the touch driver in recovery mode for whatever reason, rendering TWRP useless.
1. Download `lineage_recovery_XXX.img` and `vbmeta.zip`, unpack `vbmeta.zip` to get three .img files starting with `vbmeta`
2. Run `adb reboot bootloader` to put your device in bootloader mode
3. Run `fastboot flash --disable-verification --disable-verity vbmeta vbmeta.img`
4. Run `fastboot flash --disable-verification --disable-verity vbmeta_system vbmeta_system.img`
5. Run `fastboot flash --disable-verification --disable-verity vbmeta_vendor vbmeta_vendor.img`
6. Run `fastboot flash recovery lineage_recovery_XXX.img`
7. Run `fastboot reboot recovery` to reboot into the newly-installed LineageOS Recovery
The LineageOS Recovery is operated by volume keys as selection and power as confirmation (or entering sub-menus). To return to upper levels of menus from sub-menus, press volume up until the selection goes to the first item and then disappears, then press power (i.e. there's a hidden "Go Back" item at the very top of each sub-menu).
The recovery will show a verification failed prompt for most packages that are not signed with the AOSP keys. This is safe to ignore.
Installing LineageOS 17.1
The LineageOS image must be installed via LineageOS recovery.
1. Download `lineage-17.1-Atom_L-XXX.zip`
2. Reboot your device into recovery (`adb reboot recovery` or simply hold volume up while turning power on)
3. Wipe all data (factory reset) (THIS DELETES EVEN INTERNAL STORAGE)
4. Choose Apply Update, then Apply Update from ADB
5. Run `adb sideload lineage-17.1-Atom_L-XXX.zip` from your PC
6. Wait for the process to finish. (The recovery might prompt something about verification failure, just ignore it and continue anyway)
7. At this point, you can then sideload the LATEST Magisk and OpenGAPPS Nano at your will (note that the size of the system partition might only be enough for the `nano` variant of OpenGAPPS) (If installing Magisk / OpenGAPPS fails, you can try rebooting into recovery again in advanced menus, then try installing them again)
8. Reboot into system and enjoy (Note that Magisk might cause your device to boot loop once or two but it will eventually boot)
When updating to a newer build, you have to flash the new zip, and then re-flash whatever mod you have installed previously (Magisk / GAPPS).
Download Links
LineageOS:
lineage-17.1-Atom_L-20200828-peter-signed.zip: https://mega.nz/file/bAgh1BZA#jzMs_0e9NUR9NcALXWp51ZeWttM5rl_3K5T8Or9hAW0
- Synchronized updates from LineageOS upstream.
lineage-17.1-Atom_L-20200728-peter-signed.zip: https://mega.nz/file/vBwlmL5D#wpw8RovBHyVFCLFlhQ2H5QAIb0ECXkT4of0FRijiP6A
LineageOS Recovery:
lineage_recovery_20200728.img: https://mega.nz/file/yc4Dnbyb#yx0Ci9p3q9_lfAiXkGfgWDFnRJI-JSGrv3kyawkU3fw
vbmeta:
vbmeta.zip: https://mega.nz/file/nF51mBoY#ZNY4j92wc_6a1dXch3l5r-w4VFl9QjN7YJaRMKRoEGk
XDA:DevDB Information
LineageOS 17.1 for Unihertz Atom L, ROM for the Android General
Contributors
PeterCxy
Source Code: https://cgit.typeblog.net/android/device/unihertz/Atom_L/
ROM OS Version: Android 10
Version Information
Status: Alpha
Created 2020-07-28
Last Updated 2020-07-28
How different is the Atom XL?
PeterCxy said:
Introduction
WARNING: DO NOT try to install this on Atom XL. This is ONLY for the Atom L.
Unfortunately I've got the XL version which I thought only varied from the L by the presence of a UHF radio! Can you explain to me why its not a suitable candidate for your mods which sound very good!?
And before you ask, I only got this radio for hacking so I don't mind experimenting if that is required. Please let me know if I can help.
The Bitfarmer
Click to expand...
Click to collapse
tvroman said:
PeterCxy said:
Introduction
WARNING: DO NOT try to install this on Atom XL. This is ONLY for the Atom L.
Unfortunately I've got the XL version which I thought only varied from the L by the presence of a UHF radio! Can you explain to me why its not a suitable candidate for your mods which sound very good!?
And before you ask, I only got this radio for hacking so I don't mind experimenting if that is required. Please let me know if I can help.
The Bitfarmer
Click to expand...
Click to collapse
Because Unihertz publishes completely different firmware files for the L and XL, so the safest assumption is that there is more difference than just the UHF radio. If you want to risk it, then you CAN try using this ROM on the XL, as long as you know how to revert back to official if things go wrong. (But I cannot guarantee if the kernel image from L that this ROM uses will not cause serious issues like corrupted baseband or something on the XL)
My suggestion is that instead of trying this ROM directly on the XL, someone with XL can try to modify my device tree for L, replacing the kernel, dtbo images and other vendor blobs from the ones from XL, and then re-compile the ROM for XL. This would be the proper way to handle these two devices.
Click to expand...
Click to collapse
Going XL
Hi.
Great work. :good:
I want to built a ROM for the Atom XL myself. And because I'm no expert on this (for now) I'm in search of guides and hints on how to achieve my goal.
As far as I know the biggest problem with Unihertz is that they use a Mediatek chipset with which they are not allowed to provide the sourcecode of the kernel. Or at least you have to pay for it from Mediatek.
But there are some variants of the chipset (Helio P60; mt6771) used in other mobile phones (e.g. Nokia X5) for which I was able to find kernelsources on Github. Using these and the latest Android kernel from google I tried to compile a kernel as a starting point. I was able to extract the build.config directly from the phone which helped tremendously. This should at least get me to the point where I'm able to assemble a TWRP build. But I believe that I'm still missing some (vital?) drivers which are specific to the actual device. This includes I think the missing touchscreen driver that you mentioned is preventing the recovery to be useful.
So now I'm a little bit stuck, because most of the guides to arrange a LineageOS (or any other custom ROM) build tree I found require the sourcecode from the manufacturer which we don't have. All other guides to build from scratch were too generic for my current level of expertise.
Can you please share your approach to create this build?
If you don't want to do this in the open you could also PM me.
With kind regards
ADT
a-dead-trousers said:
Hi.
Great work. :good:
I want to built a ROM for the Atom XL myself. And because I'm no expert on this (for now) I'm in search of guides and hints on how to achieve my goal.
As far as I know the biggest problem with Unihertz is that they use a Mediatek chipset with which they are not allowed to provide the sourcecode of the kernel. Or at least you have to pay for it from Mediatek.
But there are some variants of the chipset (Helio P60; mt6771) used in other mobile phones (e.g. Nokia X5) for which I was able to find kernelsources on Github. Using these and the latest Android kernel from google I tried to compile a kernel as a starting point. I was able to extract the build.config directly from the phone which helped tremendously. This should at least get me to the point where I'm able to assemble a TWRP build. But I believe that I'm still missing some (vital?) drivers which are specific to the actual device. This includes I think the missing touchscreen driver that you mentioned is preventing the recovery to be useful.
So now I'm a little bit stuck, because most of the guides to arrange a LineageOS (or any other custom ROM) build tree I found require the sourcecode from the manufacturer which we don't have. All other guides to build from scratch were too generic for my current level of expertise.
Can you please share your approach to create this build?
If you don't want to do this in the open you could also PM me.
With kind regards
ADT
Click to expand...
Click to collapse
You don't need the kernel source code to build a working ROM -- just look at my device tree for Atom L. I think you can build a working ROM for the XL by just replacing the prebuilt kernel in my device tree with the one from Atom XL and also re-extracting the vendor blobs from XL using the script in my devcie tree, then rename everything to Atom XL instead of L. I don't know if the integrated amateur radio would still work though.
PeterCxy said:
You don't need the kernel source code to build a working ROM -- just look at my device tree for Atom L. I think you can build a working ROM for the XL by just replacing the prebuilt kernel in my device tree with the one from Atom XL and also re-extracting the vendor blobs from XL using the script in my devcie tree, then rename everything to Atom XL instead of L. I don't know if the integrated amateur radio would still work though.
Click to expand...
Click to collapse
I'm already on to that.
But I seem to have trouble extracting the prebuilt kernel. None of the tools I found gave me the exact files you have got (dtb.img, dtbo.img, Image.gz). What did you use?
The best I could get were "dtb", "kernel" and "dtborecovery" (without extensions) which roughly had the same size as yours.
Also, as far as I understand it, with your initial commit (without the modifications for Lineage itself) I should be able to at least compile a recovery image but I got an error regarding a missing dtb.img file in the "out" directory.
Something seems to be missing because, my dtb file is in the "device" directory and not being transfered into "out" during building.
I'm not sure that is because I have got a different naming scheme (renamig it didn't help) or I did something wrong with the extraction.
---------- Post added at 07:30 ---------- Previous post was at 07:14 ----------
Another question I have:
Are the vbmeta-files you used to flash the recovery the ones from the original firmeware zip from unihertz or did you get them from the lineage built?
And reguarding the rather smallish system partition:
I have an idea to bypass that by using the SPFlash Tool from Mediatek. As far as I understand the settings in the scatter-file this tool does a repartitioning of the internal storage. So we only need to "decrease" the userdata, "move" some partitions inbetween and "increase" the system. Only problem is, I couldn't find a partition designated as "system" in the scatter-file, only one big "super" and a "vbmeta-system" (which for my understaning is for verified boot) partition.
What do you think?
a-dead-trousers said:
I'm already on to that.
But I seem to have trouble extracting the prebuilt kernel. None of the tools I found gave me the exact files you have got (dtb.img, dtbo.img, Image.gz). What did you use?
The best I could get were "dtb", "kernel" and "dtborecovery" (without extensions) which roughly had the same size as yours.
Also, as far as I understand it, with your initial commit (without the modifications for Lineage itself) I should be able to at least compile a recovery image but I got an error regarding a missing dtb.img file in the "out" directory.
Something seems to be missing because, my dtb file is in the "device" directory and not being transfered into "out" during building.
I'm not sure that is because I have got a different naming scheme (renamig it didn't help) or I did something wrong with the extraction.
---------- Post added at 07:30 ---------- Previous post was at 07:14 ----------
Another question I have:
Are the vbmeta-files you used to flash the recovery the ones from the original firmeware zip from unihertz or did you get them from the lineage built?
And reguarding the rather smallish system partition:
I have an idea to bypass that by using the SPFlash Tool from Mediatek. As far as I understand the settings in the scatter-file this tool does a repartitioning of the internal storage. So we only need to "decrease" the userdata, "move" some partitions inbetween and "increase" the system. Only problem is, I couldn't find a partition designated as "system" in the scatter-file, only one big "super" and a "vbmeta-system" (which for my understaning is for verified boot) partition.
What do you think?
Click to expand...
Click to collapse
> None of the tools I found gave me the exact files you have got (dtb.img, dtbo.img, Image.gz). What did you use?
There is a tool called `unpack_bootimg` in the Android source code. Just run `make unpack_bootimg` in the root directory of the Android source tree and you will get one in the output directory. (btw I have renamed those extracted files so the names won't exactly match, but you need this tool to extract the correct images. All other tools won't work properly).
> my dtb file is in the "device" directory and not being transfered into "out" during building.
Because most tools other than `unpack_bootimg` extracts dtb incorrectly.
> Are the vbmeta-files you used to flash the recovery the ones from the original firmeware zip from unihertz or did you get them from the lineage built?
Those don't matter. Either will work as long as you flash it with the correct parameters as given in my post.
> And reguarding the rather smallish system partition
No don't do that. Android 10 does not use a separate system partition anymore, instead both system, vendor and product are sub-partitions in a huge super partition. When flashing a new ROM, the partitions are automatically resized to match the new image exactly, instead of leaving free space unused like before Android 10. That's why I need to reserve space in BoardConfig.mk for gapps to be installed correctly.
Still not able to build.
PeterCxy said:
There is a tool called `unpack_bootimg` in the Android source code. Just run `make unpack_bootimg` in the root directory of the Android source tree and you will get one in the output directory. (btw I have renamed those extracted files so the names won't exactly match, but you need this tool to extract the correct images. All other tools won't work properly).
Click to expand...
Click to collapse
I'm still getting an error:
Code:
FAILED: ninja: 'out/target/product/Atom_XL/dtb.img', needed by 'out/target/product/Atom_XL/boot.img', missing and no known rule to make it
Comparing your BoardConfig.mk with mine shows a slight difference in the offset and size values which could be associated with the different kernels of the phones.
But using "unpack_bootimg" I didn't get a value for "BOARD_KERNEL_OFFSET" like you have it in your config. Could this be the problem?
Your BoardConfig.mk
My BoardConfig.mk
Do you see anything else out of the ordinary?
(Because I'm doing everything what you did step-by-step the links point to the best matching commits)
Despite not being able to compile right now I tried to press on with integrating your changes in the hopes that it will be fixed somehow later on
So I'm currently stuck on this commit of yours:
Atom_L: import overlay from official vendor
Where did you get the "config.xml" and "power_profile.xml" from? The best thing I could find was a "power_profile.xml" inside "/vendor/overlay/FrameworkResOverlay/FrameworkResOverlay.apk" which seems to be a "compiled" version of the aforementioned xml-file.
a-dead-trousers said:
I'm still getting an error:
Code:
FAILED: ninja: 'out/target/product/Atom_XL/dtb.img', needed by 'out/target/product/Atom_XL/boot.img', missing and no known rule to make it
Comparing your BoardConfig.mk with mine shows a slight difference in the offset and size values which could be associated with the different kernels of the phones.
But using "unpack_bootimg" I didn't get a value for "BOARD_KERNEL_OFFSET" like you have it in your config. Could this be the problem?
Your BoardConfig.mk
My BoardConfig.mk
Do you see anything else out of the ordinary?
(Because I'm doing everything what you did step-by-step the links point to the best matching commits)
Despite not being able to compile right now I tried to press on with integrating your changes in the hopes that it will be fixed somehow later on
So I'm currently stuck on this commit of yours:
Atom_L: import overlay from official vendor
Where did you get the "config.xml" and "power_profile.xml" from? The best thing I could find was a "power_profile.xml" inside "/vendor/overlay/FrameworkResOverlay/FrameworkResOverlay.apk" which seems to be a "compiled" version of the aforementioned xml-file.
Click to expand...
Click to collapse
> Comparing your BoardConfig.mk with mine shows a slight difference in the offset and size values which could be associated with the different kernels of the phones.
TARGET_KERNEL_OFFSET should normally always be 0x00008000. Also, your other offset values seem to be wrong too -- those values from `unpack_bootimg` cannot be filled in directly to BoardConfig.mk. Instead, you need to subtract BOARD_KERNEL_BASE from them (e.g. BOARD_RAMDISK_OFFSET should be 0x55000000 - 0x40078000, which is 0x14f88000, the same as mine). In fact, I think those parameters should be exactly the same for XL and L. Other than that, I don't think I can see much of a problem about your makefiles.
However, note that not all of my historical commits represent a compilable state of the device tree. I'd suggest you start directly from the latest state and just replace whatever is relevant instead of starting over. And there should not be much that needs changing at all except device names, fingerprints and the proprietary vendor files.
> Where did you get the "config.xml" and "power_profile.xml" from
Exactly from those apks. Just decompile them using apktool.
PeterCxy said:
TARGET_KERNEL_OFFSET should normally always be 0x00008000. Also, your other offset values seem to be wrong too -- those values from `unpack_bootimg` cannot be filled in directly to BoardConfig.mk. Instead, you need to subtract BOARD_KERNEL_BASE from them (e.g. BOARD_RAMDISK_OFFSET should be 0x55000000 - 0x40078000, which is 0x14f88000, the same as mine). In fact, I think those parameters should be exactly the same for XL and L. Other than that, I don't think I can see much of a problem about your makefiles.
Click to expand...
Click to collapse
Still giving me errors.
So I tried a very unconventional approach: I just copied the file myself into the mentioned "out/target/product/Atom_XL" folder.
For now it's still compiling. Fingers crossed.
PeterCxy said:
However, note that not all of my historical commits represent a compilable state of the device tree. I'd suggest you start directly from the latest state and just replace whatever is relevant instead of starting over. And there should not be much that needs changing at all except device names, fingerprints and the proprietary vendor files.
Click to expand...
Click to collapse
I just reached your biggest commit yet.
Can you tell me how you got the list of needed files? I hope it's not through trial-and-error.
Except for the values in "setup-makefiles.sh" only the "proprietary-files.txt" seems to be device specific. Is there anything else I need to be aware of in this commit?
P.S.: I know it is tedious to go through your commits one by one but I want to learn something of it not just simply copying what you did. To get a feeling where the biggest pitfalls are and what you did to circumvent them.
a-dead-trousers said:
Still giving me errors.
So I tried a very unconventional approach: I just copied the file myself into the mentioned "out/target/product/Atom_XL" folder.
For now it's still compiling. Fingers crossed.
I just reached your biggest commit yet.
Can you tell me how you got the list of needed files? I hope it's not through trial-and-error.
Except for the values in "setup-makefiles.sh" only the "proprietary-files.txt" seems to be device specific. Is there anything else I need to be aware of in this commit?
P.S.: I know it is tedious to go through your commits one by one but I want to learn something of it not just simply copying what you did. To get a feeling where the biggest pitfalls are and what you did to circumvent them.
Click to expand...
Click to collapse
> Still giving me errors.
Looks like that dtb.img error was totally my fault -- it was due to my jerry-rigged solution of using prebuilt dtb image that conflicted with one of Lineage's update in August and I haven't built the ROM for a month. Now I have fixed it in the latest commit.
> Can you tell me how you got the list of needed files?
All of those files are for VoLTE support and I started with the list from a commit in Redmi Note 7 Pro's device tree that imported those VoLTE blobs, and then added what was missing one by one (when something is missing the Phone process will crash and you can see what got missing in the logs). I don't think the list will be any different on Atom XL so you can just use the one in my device tree.
Hi.
Thanks to you everything is running smoothly here. But what bugs me is that TWRP is not working on our devices.
Although for the Atom there is a possibility: https://forum.xda-developers.com/android/development/twrp-modded-to-unihertz-atom-t3885793
Before I want to go public with my build I wanted to solve this last "mystery".
So I tried to include it in my current source tree according to the (official?) guide but some errors prevented me from a successful build.
Naturally I asked for some guidance at the most reasonable places I know of but got nothing so far:
https://forum.xda-developers.com/showpost.php?p=83443611&postcount=4622
https://forum.xda-developers.com/showpost.php?p=83455271&postcount=4623
https://github.com/TeamWin/android_bootable_recovery/issues/70
I even tried different repositories (omnirom/android_bootable_recovery) and revisions (android-9.0) but these resulted in missing library "type" (static vs. shared) errors so I assume these are too old for LineageOS 17.1
What I want to know is how you managed to get TWRP to built for your device even though the touchscreen wasn't working?
Did you use your LineageOS source tree or one of the many "minimal" manifests? If so, which one would be the "best" to use?
wkr ADT
@PeterCxy and @a-dead-trousers
Thanks for all the work on this so far. I've got an Atom L and have gotten the ROM's PeterCxy posted running on them as in the OP. Do either of you have a quick step-by-step workflow of how you got all the Lineage sources set up and built into the various ROMs? I'd like to be able to build the ROMs from scratch and understand the process.
If I can get caught up to where you two are at with the builds, I can help debug, test and work through issues.
dirtylimerick said:
[MENTION=5351691] Do either of you have a quick step-by-step workflow of how you got all the Lineage sources set up and built into the various ROMs? I'd like to be able to build the ROMs from scratch and understand the process.
If I can get caught up to where you two are at with the builds, I can help debug, test and work through issues.
Click to expand...
Click to collapse
I documented my steps to setup up the build environment in the readme of my repo:
https://github.com/ADeadTrousers/android_device_Unihertz_Atom_XL
But leave out the TWRP part. It isn't working yet mostly because TeamWin/android_bootable_recovery and LineageOS/android_bootable_recovery are too similar.
To figure out all the bits and pieces needed for the device I followed the commit log of @PeterCxy build.
Hi, @PeterCxy.
Finally I was able to build a TWRP recovery and surprise, surprise the touchscreen isn't working.
But during my attempts to get a working TWRP build I came acros a guide that explains how to patch the kernel to get the touchscreen to work.
https://forum.hovatek.com/thread-27132.html
So I tried to follow it but failed to identify the "end" of the zipped Image-file (step 18) to remove the payload from the gz-file. Regardless of which of the null-bytes I use for cutting I always get a warning from 7-zip that there is still data at the end.
Do you know a better approach to achieve this whole patching? Maybe even come up with a scripting solution to easily apply this patch in later builds?
wkr ADT
a-dead-trousers said:
Hi, @PeterCxy.
Finally I was able to build a TWRP recovery and surprise, surprise the touchscreen isn't working.
But during my attempts to get a working TWRP build I came acros a guide that explains how to patch the kernel to get the touchscreen to work.
https://forum.hovatek.com/thread-27132.html
So I tried to follow it but failed to identify the "end" of the zipped Image-file (step 18) to remove the payload from the gz-file. Regardless of which of the null-bytes I use for cutting I always get a warning from 7-zip that there is still data at the end.
Do you know a better approach to achieve this whole patching? Maybe even come up with a scripting solution to easily apply this patch in later builds?
wkr ADT
Click to expand...
Click to collapse
There is no sane way to solve the problem without kernel source code. Basically the stock kernel just does not load the touch screen driver in recovery mode. That patching guide is pretty out of date and I imagine it won't work on most recent kernels. The only proper way is to pressure Unihertz to actually obey GPLv2 and release their kernel source code. Or maybe someone can try reverse-engineering the kernel, but at least I won't do it because it'll just be too much of a hassle.
PeterCxy said:
There is no sane way to solve the problem without kernel source code. Basically the stock kernel just does not load the touch screen driver in recovery mode. The only proper way is to pressure Unihertz to actually obey GPLv2 and release their kernel source code.
Click to expand...
Click to collapse
I'm with you on this one, but as long as we don't have the source code we need to resort to other means to achieve our goals.
PeterCxy said:
That patching guide is pretty out of date and I imagine it won't work on most recent kernels.
Click to expand...
Click to collapse
Yeah it's from way back in 2019
Anyway, with a little bit of tinkering I was able to modify my kernel to load the touchscreen driver in recovery mode.
Here is the device tree and the manifest i used.
I wouldn't recommend to use it in it's current state at all though because the fstab needs a little bit of tinkering. Everything seems to be either unordered or not mounted properly and I fear anything you do in there now will mess up the whole device. BUT I got the touchscreen goin for me which is nice.
PeterCxy said:
Or maybe someone can try reverse-engineering the kernel, but at least I won't do it because it'll just be too much of a hassle.
Click to expand...
Click to collapse
As soon as I have everything sorted out that needs to be fixed on my build (e.g. signing, radio, included gapps working properly, TWRP) I want to dig deeper into the kernel.
There are some devices with Helios P60 out there from other vendors which offer kernel sources.
P.S.: I also uploaded a HOW-TO in my device tree.
If you or someone else wants to try it. Also if you want to you can send me a "symbl.txt" (see to the HOW-TO) extracted from your device then I can do the patching for the Atom_L too.
a-dead-trousers said:
I'm with you on this one, but as long as we don't have the source code we need to resort to other means to achieve our goals.
Yeah it's from way back in 2019
Anyway, with a little bit of tinkering I was able to modify my kernel to load the touchscreen driver in recovery mode.
Here is the device tree and the manifest i used.
I wouldn't recommend to use it in it's current state at all though because the fstab needs a little bit of tinkering. Everything seems to be either unordered or not mounted properly and I fear anything you do in there now will mess up the whole device. BUT I got the touchscreen goin for me which is nice.
As soon as I have everything sorted out that needs to be fixed on my build (e.g. signing, radio, included gapps working properly, TWRP) I want to dig deeper into the kernel.
There are some devices with Helios P60 out there from other vendors which offer kernel sources.
P.S.: I also uploaded a HOW-TO in my device tree.
If you or someone else wants to try it. Also if you want to you can send me a "symbl.txt" (see to the HOW-TO) extracted from your device then I can do the patching for the Atom_L too.
Click to expand...
Click to collapse
Happy to hear that you were able to figure the touchscreen out. I tried to port TWRP at the very beginning when I started tinkering with the device but quickly grew frustrated and just ported Lineage Recovery instead. I guess I might try patching the kernel image too at some point later.
BTW, for TWRP to work with devices released after Android 10, I'm pretty sure you need an extra set of patches that are not yet fully merged to the main TWRP repository. I remember there's some guy providing another manifest with all the patches applied but I couldn't remember the name.
Hi.
I just officially announced my build for the Atom XL:
https://forum.xda-developers.com/android/development/rom-lineageos-17-1-unihertz-atom-xl-t4171407
Could you please put a link in your first post for those in search of the Atom XL and found your thread instead. Thanks.
wkr ADT
hi @PeterCxy.
During my daily usage of the phone I encountered a strage problem:
The audio jack isn't working. Plugging in some headphones I get this slight click in the earpieces when the circuits connect but nothing else happens. Neither a "headphone" icon in the status bar nor hearing anything coming from the headphones itself. The main speaker of the phone keeps playing the music. Using bluetooth everything is working as expected though. So I used logcat to see if something is coming up during plugging in but nothing "catchy" shows up in the logs. My guess is that some (vendor?) service is missing or not started during booting. Next I checked If something shows up on logcat during boot but I'm not sure for what to look exactly. There are quite a few errors and warnings though. In my despair I started to "fix" the "avc: denied" (SEPolicy) entries. Thats when I found a specific error reguarding VoLTE. Maybe this would fix the problems you had with VoLTE in enforcing mode:
https://github.com/ADeadTrousers/an..._Atom_XL/blob/master/sepolicy/private/init.te
(The line with "socket_device:sock_file")
My provider doesn't support VoLTE so I'm not sure if this helps or not. Maybe you could check it.
Anyway can you please tell me if your device's audio jack is working or not?
If you're (by some mysterious coincidence) not affected by this, can you at least give me some pointers for what to look for to get this fixed on my side.
The Internet Is not very helpful when searching for "android audio jack" or something similiar.
Thanks in advance.
wkr ADT

[Discussion] Treble on V20 (Its possible with some help)

Ok so heres the full story (It's short):
So my V20 bricked itself for no reason (I was on stock for a few days unrooted no unlock nothing)
and while going through xda I stumbled upon this:https://forum.xda-developers.com/on...eble-lineageos-15-1-treble-oneplus-3-t3830455
Treble on the oneplus 3 and 3t. Why this one you might ask
well it is because our V20 and the Oneplus are similar.
So here is what somebody who is willing to help with a h990ds or H990 (It wont brick your device don't worry)needs to do:
1.First install this modded twrp here is the Link (Made from Pheonix591's twrp): https://drive.google.com/file/d/1pBrjWnKqRFFsQ-By_ElE3pW3LbWsg9sx/view?usp=sharing
2. Boot into the TWRP and go to advanced options then select terminal
Now type Treble and wait for a few seconds (This command is taken from the trebel port for oneplus 3 @simonsh)
Next reboot to whatever rom you are using(If it doesn't boot or bootloops something went wrong retry from step 2)
After it boots successfully go back to twrp and check in wipe and advanced wipe for Vendor
Now here is the problem the partition is only about 100 megabytes which we cant really use for treble it is too small.
So I am pinging a person who might be able to help us :
@runningnak3d I need your help in making the partition larger as it is again only about 100megabytes
Edit: So Runningnak3d has stopped developing for the V20 :crying: and I had just remembered that @x86cpu might be able to help so pinging him, we want as much people as possible.
Uhh so seems like my wifi is not properly working I will upload the twrp
Mysteriouslog6 said:
Ok so heres the full story (It's short):
So my V20 bricked itself for no reason (I was on stock for a few days unrooted no unlock nothing)
and while going through xda I stumbled upon this:https://forum.xda-developers.com/on...eble-lineageos-15-1-treble-oneplus-3-t3830455
Treble on the oneplus 3 and 3t. Why this one you might ask
well it is because our V20 and the Oneplus are similar.
So here is what somebody who is willing to help with a h990ds or H990 (It wont brick your device don't worry)needs to do:
1.First install this modded twrp here is the Link (Made from Pheonix591's twrp):
2. Boot into the TWRP and go to advanced options then select terminal
Now type Treble and wait for a few seconds (This command is taken from the trebel port for oneplus 3 @simonsh)
Next reboot to whatever rom you are using(If it doesn't boot or bootloops something went wrong retry from step 2)
After it boots successfully go back to twrp and check in wipe and advanced wipe for Vendor
Now here is the problem the partition is only about 100 megabytes which we cant really use for treble it is too small.
So I am pinging a person who might be able to help us :
@runningnak3d I need your help in making the partition larger as it is again only about 100megabytes
Click to expand...
Click to collapse
Running naked moved on and stopped developing for the V20 a long time ago.
Sent from my LG-H910 using XDA Labs
cnjax said:
Running naked moved on and stopped developing for the V20 a long time ago.
Sent from my LG-H910 using XDA Labs
Click to expand...
Click to collapse
That's really sad I was hoping someone can help me with the partition problem, what about @x86cpu ?
Mysteriouslog6 said:
Ok so heres the full story (It's short):
So my V20 bricked itself for no reason (I was on stock for a few days unrooted no unlock nothing)
and while going through xda I stumbled upon this:https://forum.xda-developers.com/on...eble-lineageos-15-1-treble-oneplus-3-t3830455
Treble on the oneplus 3 and 3t. Why this one you might ask
well it is because our V20 and the Oneplus are similar.
So here is what somebody who is willing to help with a h990ds or H990 (It wont brick your device don't worry)needs to do:
1.First install this modded twrp here is the Link (Made from Pheonix591's twrp): https://drive.google.com/file/d/1pBrjWnKqRFFsQ-By_ElE3pW3LbWsg9sx/view?usp=sharing
2. Boot into the TWRP and go to advanced options then select terminal
Now type Treble and wait for a few seconds (This command is taken from the trebel port for oneplus 3 @simonsh)
Next reboot to whatever rom you are using(If it doesn't boot or bootloops something went wrong retry from step 2)
After it boots successfully go back to twrp and check in wipe and advanced wipe for Vendor
Now here is the problem the partition is only about 100 megabytes which we cant really use for treble it is too small.
So I am pinging a person who might be able to help us :
@runningnak3d I need your help in making the partition larger as it is again only about 100megabytes
Edit: So Runningnak3d has stopped developing for the V20 :crying: and I had just remembered that @x86cpu might be able to help so pinging him, we want as much people as possible.
Click to expand...
Click to collapse
Mind if I help I recently acquired a vs995 for cheap so for know at least im back. I experimented with trebe on the g5 and was able to build a treblized los 15.1 but the problem was no gsi would boot here's what I used to build it.
https://review.lineageos.org/c/LineageOS/android_device_lge_h850/+/222974
https://review.lineageos.org/c/LineageOS/android_device_lge_msm8996-common/+/221553
https://review.lineageos.org/c/LineageOS/android_kernel_lge_msm8996/+/222018
I then added this to BoardConfigCommon.mk:
# Treble
BOARD_PROPERTY_OVERRIDES_SPLIT_ENABLED := true
BOARD_VNDK_RUNTIME_DISABLE := true
BOARD_VNDK_VERSION := current
PRODUCT_FULL_TREBLE_OVERRIDE := true
I would also like to mention that a few years ago @King_lilrowrow said he was working on/achieved treble on the G5 I'd contact him as well for help.
What is 'treble' / 'treblizing'... Curious what it does.
kaluna00 said:
What is 'treble' / 'treblizing'... Curious what it does.
Click to expand...
Click to collapse
The command does this (From @simonsh thread)
Code:
/sbin/sgdisk --typecode=5:8300 /dev/block/sdf
/sbin/sgdisk --change-name=5:vendor /dev/block/sdf
It basically makes the sdf block the vendor partition (Works as nothing has interfered with the working of the phone so the partition is unused but it is too small need help with that)
kaluna00 said:
What is 'treble' / 'treblizing'... Curious what it does.
Click to expand...
Click to collapse
So treble aka project treble is something google implemented with android 8 that splits system/vendor to / system and /vendor basically it gives vendor files which are device-specific code and drivers used to interact with the phone's hardware there own separate partition. Now since /system without vendor is mostly free of device-specific code it means that the phones os can be upgraded with messing with building and modifying the device-specific code, this is were GSIs (generic system images) come in, flashing a gsi essentially means we can modify and upgrade our OS like a custom rom but instead of spending hours working on a custom rom we can just build a system image which is very fast and easy and it can do just as much as a custom rom as far as enhancing the user experience goes.
That's the best I can explain it here is an article explaining it more and as far as trebilizing goes it's just a term used when someone gets treble working on an old device that doesn't support it from the factory.
ROMSG said:
Mind if I help I recently acquired a vs995 for cheap so for know at least im back. I experimented with trebe on the g5 and was able to build a treblized los 15.1 but the problem was no gsi would boot here's what I used to build it.
https://review.lineageos.org/c/LineageOS/android_device_lge_h850/+/222974
https://review.lineageos.org/c/LineageOS/android_device_lge_msm8996-common/+/221553
https://review.lineageos.org/c/LineageOS/android_kernel_lge_msm8996/+/222018
I then added this to BoardConfigCommon.mk:
# Treble
BOARD_PROPERTY_OVERRIDES_SPLIT_ENABLED := true
BOARD_VNDK_RUNTIME_DISABLE := true
BOARD_VNDK_VERSION := current
PRODUCT_FULL_TREBLE_OVERRIDE := true
I would also like to mention that a few years ago @King_lilrowrow said he was working on/achieved treble on the G5 I'd contact him as well for help.
Click to expand...
Click to collapse
Thanks for wanting to help I will send a link for the vs995 with a custom twrp. Also isn't the BoardConfigCommon.MK in the source for lineage os I will try building it with the modifications
Mysteriouslog6 said:
Thanks for wanting to help I will send a link for the vs995 with a custom twrp. Also isn't the BoardConfigCommon.MK in the source for lineage os I will try building it with the modifications
Click to expand...
Click to collapse
Thanks, BoardConfigCommon.mk is a device tree file and specific to any rom. Here this Commit outlines one of the issues @x86cpu had with getting treble working.
@ROMSG
Thanks a bunch for the explanation. I appreciate you breaking it down I like that. I'll do some homework and check out that link after work. Take care!
Mysteriouslog6 said:
Thanks for wanting to help I will send a link for the vs995 with a custom twrp. Also isn't the BoardConfigCommon.MK in the source for lineage os I will try building it with the modifications
Click to expand...
Click to collapse
Any update on the vs995 custom twrp?
ROMSG said:
Any update on the vs995 custom twrp?
Click to expand...
Click to collapse
Sorry for the late reply I will send it tomorrow itself (Will have to somehow see if the TWRP boots or not)
Heres the link:
twrp-treble-vs995.img
drive.google.com
ROMSG said:
Any update on the vs995 custom twrp?
Click to expand...
Click to collapse
I have sent the TWRP just check the latest post
Mysteriouslog6 said:
I have sent the TWRP just check the latest post
Click to expand...
Click to collapse
Just saw it thanks
Mysteriouslog6 said:
Ok so heres the full story (It's short):
So my V20 bricked itself for no reason (I was on stock for a few days unrooted no unlock nothing)
and while going through xda I stumbled upon this:https://forum.xda-developers.com/on...eble-lineageos-15-1-treble-oneplus-3-t3830455
Treble on the oneplus 3 and 3t. Why this one you might ask
well it is because our V20 and the Oneplus are similar.
So here is what somebody who is willing to help with a h990ds or H990 (It wont brick your device don't worry)needs to do:
1.First install this modded twrp here is the Link (Made from Pheonix591's twrp): https://drive.google.com/file/d/1pBrjWnKqRFFsQ-By_ElE3pW3LbWsg9sx/view?usp=sharing
2. Boot into the TWRP and go to advanced options then select terminal
Now type Treble and wait for a few seconds (This command is taken from the trebel port for oneplus 3 @simonsh)
Next reboot to whatever rom you are using(If it doesn't boot or bootloops something went wrong retry from step 2)
After it boots successfully go back to twrp and check in wipe and advanced wipe for Vendor
Now here is the problem the partition is only about 100 megabytes which we cant really use for treble it is too small.
So I am pinging a person who might be able to help us :
@runningnak3d I need your help in making the partition larger as it is again only about 100megabytes
Edit: So Runningnak3d has stopped developing for the V20 :crying: and I had just remembered that @x86cpu might be able to help so pinging him, we want as much people as possible.
Click to expand...
Click to collapse
Hello, since Android 12 beta has released recently, i get to know that we can use the GSI image to update “any” (in terms of project treble supported) device to a newer android version without the need of building the rom per device.
So that i started to explore on a few xda threads trying to get Treble on LG V20. After digging into it, i updated my TWRP to the latest image (official TWRP 3.5.2_9 H990 which is the Official TWRP build commit based on Pheonix591's twrp build), then i saw that the /vendor shows up on mount, but not on either Wipe or Backup, which Phoenix591’s reddit post stated that this means there’s no vendor partition on it.
I followed this thread, since my TWRP is not modded (as the link in your comment does not work) I typed two sgdisk commands which the Treble command does, after a reboot, i saw a Vendor partition in Backup showed 0mb, Vendor partition DOES NOT appears on Wipe.
Next, as what i saw from @x86cpu ’s comment, he said he repartitioned and created the /vendor partition of 512mb by resizing the /system partition, unfortunately i am new to partitioning the Android device, i haven’t figured out how i can do that.
I tried to do sgdisk —print /dev/block/mmcblk0, it showed a single 64gb MBR FAT32 Partition instead of showing the system partition, it seems to be showing the micro sd card instead of the system volume, so i tried to unplug the sd card and reboot, now /dev/block/mmcblk0 is not found. I also tried to list info of /dev/block/sdf which we have wrote the partition name “vendor” to the 5th parnum of /sdf, it shows that the partition is only 4kb.
Since i have a H990N (Hong Kong version of the H990) i used the Dirty Santa patch to get TWRP installed on the device, that means the device’s bootloader is NOT fully unlocked, so the device might have difference between official unlocked device like the VS995.
Is there anything i could try ?
kwankiu said:
Hello, since Android 12 beta has released recently, i get to know that we can use the GSI image to update “any” (in terms of project treble supported) device to a newer android version without the need of building the rom per device.
So that i started to explore on a few xda threads trying to get Treble on LG V20. After digging into it, i updated my TWRP to the latest image (official TWRP 3.5.2_9 H990 which is the Official TWRP build commit based on Pheonix591's twrp build), then i saw that the /vendor shows up on mount, but not on either Wipe or Backup, which Phoenix591’s reddit post stated that this means there’s no vendor partition on it.
I followed this thread, since my TWRP is not modded (as the link in your comment does not work) I typed two sgdisk commands which the Treble command does, after a reboot, i saw a Vendor partition in Backup showed 0mb, Vendor partition DOES NOT appears on Wipe.
Next, as what i saw from @x86cpu ’s comment, he said he repartitioned and created the /vendor partition of 512mb by resizing the /system partition, unfortunately i am new to partitioning the Android device, i haven’t figured out how i can do that.
I tried to do sgdisk —print /dev/block/mmcblk0, it showed a single 64gb MBR FAT32 Partition instead of showing the system partition, it seems to be showing the micro sd card instead of the system volume, so i tried to unplug the sd card and reboot, now /dev/block/mmcblk0 is not found. I also tried to list info of /dev/block/sdf which we have wrote the partition name “vendor” to the 5th parnum of /sdf, it shows that the partition is only 4kb.
Since i have a H990N (Hong Kong version of the H990) i used the Dirty Santa patch to get TWRP installed on the device, that means the device’s bootloader is NOT fully unlocked, so the device might have difference between official unlocked device like the VS995.
Is there anything i could try ?
Click to expand...
Click to collapse
So in regards to partitioning you have to build a ROM with that partiton table in place for it too work and I have gotten treble to work (this was on myt h830) however no gsi will boot. I had to use this tool to add vender in order to flash my treble rom. I used the 800MB option in order for vender to show up.
Here are some 15.1 device tress I made for tbe VS995. I used the changes from x86cpu
GitHub - ROMSG/Treble-android_device_lge_msm8996-common
Contribute to ROMSG/Treble-android_device_lge_msm8996-common development by creating an account on GitHub.
github.com
GitHub - ROMSG/android_device_lge_vs995
Contribute to ROMSG/android_device_lge_vs995 development by creating an account on GitHub.
github.com
GitHub - ROMSG/Treble_android_device_lge_v20-common
Contribute to ROMSG/Treble_android_device_lge_v20-common development by creating an account on GitHub.
github.com
ROMSG said:
So in regards to partitioning you have to build a ROM with that partiton table in place for it too work and I have gotten treble to work (this was on myt h830) however no gsi will boot. I had to use this tool to add vender in order to flash my treble rom. I used the 800MB option in order for vender to show up.
Here are some 15.1 device tress I made for tbe VS995. I used the changes from x86cpu
GitHub - ROMSG/Treble-android_device_lge_msm8996-common
Contribute to ROMSG/Treble-android_device_lge_msm8996-common development by creating an account on GitHub.
github.com
GitHub - ROMSG/android_device_lge_vs995
Contribute to ROMSG/android_device_lge_vs995 development by creating an account on GitHub.
github.com
GitHub - ROMSG/Treble_android_device_lge_v20-common
Contribute to ROMSG/Treble_android_device_lge_v20-common development by creating an account on GitHub.
github.com
Click to expand...
Click to collapse
Thanks for your reply ! I used the tool in your comment, at first i tried take use /system space to resize a 512mb /vendor partition unfortunately this makes the /system partition only at 5gb which result in Error:7 while flashing new ROMs, so i removed the partition and did it again by adding a 512mb /vendor using space AFTER /data, i checked the partition by fdisk -l /dev/block/sda the /vendor partition is created successfully with 512gb partition size, but no “/vendor” Partition was shown on the Wipe page of TWRP (while the partition was shown in Backup and Mount), not sure whether this affect us on going Treble or not, but wiping /vendor should be possible via terminal commands.
ROMSG said:
So in regards to partitioning you have to build a ROM with that partiton table in place for it too work and I have gotten treble to work (this was on myt h830) however no gsi will boot. I had to use this tool to add vender in order to flash my treble rom. I used the 800MB option in order for vender to show up.
Here are some 15.1 device tress I made for tbe VS995. I used the changes from x86cpu
GitHub - ROMSG/Treble-android_device_lge_msm8996-common
Contribute to ROMSG/Treble-android_device_lge_msm8996-common development by creating an account on GitHub.
github.com
GitHub - ROMSG/android_device_lge_vs995
Contribute to ROMSG/android_device_lge_vs995 development by creating an account on GitHub.
github.com
GitHub - ROMSG/Treble_android_device_lge_v20-common
Contribute to ROMSG/Treble_android_device_lge_v20-common development by creating an account on GitHub.
github.com
Click to expand...
Click to collapse
One more thing, I actually misunderstood the partition yesterday that i said it was 0mb, in fact, the backup page shows 0mb is a normal behaviour as the vendor partition is empty, i didnt check how big is the partition size, but I believe it should be 100mb after running the command “Treble”. Anyways, thanks for pointing out the tools which makes it 512mb now !

Question Many questions from a total Android newbie

Hi,
Although I passed my 40 I just bought my first smartphone a few week ago. It’s a Doogee S96Pro. As somebody who like to understand how it works, I already learn a few thing on the Android ecosystem.
I’ve been able to activate the developer mode and to use adb to uninstall some apps. I also managed to boot in fastboot mode to unlock the phone.
My first attempt at flashing was a fail, the phone was rebooting in a loop, indicating "Red state". I guess I should have never "fastboot flash boot/recovery foo.img" if "fastboot boot foo.img" didn’t work? What’s your opinion on this?
The Doogee support sent me a link to the files for my phone. In fact someone on this forum has had already posted it. The two archives are named :
S9S88A7.DGE.DOOGEE.EEA.HB.HJ.AYYDVFAZ.1130.V3.02.zip
S9S88A7.DGE.DOOGEE.HB.HJ.AYYDVFAZ.1203.V3.04.zip
To make the phone boot again I flashed the boot partition with the boot.img file I found in the second archive. If I understood what I read, the file with "EEA" in it’s name is the "European version" while the other one is the "Global version".
Although I flashed with the boot.img that was in S9S88A7.DGE.DOOGEE.HB.HJ.AYYDVFAZ.1203.V3.04.zip, if I go to the update info (About the phone > Update), I can see the string S9S88A7.DGE.DOOGEE.EEA.HB.HJ.AYYDVFAZ.0128.V3.03_20210128-1612. I don’t understand why this difference (v3.03 vs. v3.04).
Then I used the Magisk Manager to patch this boot.img file and flash it again. I now have root access on the phone which is nice.
Now the questions!
When booting the phone says: “Orange state, your phone’s unlocked”, then it boots normally. What’s the implication of this? I’m not sure but I think I tried to lock it again (fastboot flashing lock) but the message remains. Does it sound possible to you? I should check again this point…
In the Magisk Manager I also tried the "SafetyNet" check, which is refused. Is it OK? What does it imply? Why would I need to pass this SafetyNet test for?
I’m not sure I understood how the recovery thing works… I understand it’s another partition than "boot", and I know I can boot on it using the boot menu (pressing volume up when turning on the phone). What I don’t know is if it starts a recovering of the system automatically when booting on this partition (then erasing all data on the phone), or not.
Let’s say I flash the boot.img on the recovery partition (fastboot flash recovery boot.img). If I do a normal boot it should boot as usual, but if I boot on recovery it would boot on a virgin system. Am I right? Let says I configure nothing and reboot again, a normal boot this time. I then should get back to my usual, already configured system, as the "boot" partition hasn’t been modified. Is this also right?
Before doing anymore tests I would like to be able to backup an image with the phone already configured, with data and root access and applications. One (or maybe two or three?) file I can keep on my computer, and in case I break the boot on the phone, I could just fastboot flash boot my_custom_image.img to recover my phone configured. Oy maybe also flashing a "userdata" partition? Would I need some other partition? Is it more complicated than that?
It seems I have to identify the right partition(s) and carefully use dd to dump the partition to an image file… Before trying to do so I’d like to have some advice, hence this post!
Also. I read about a software called TWPR. Should I use it, and why ? I understand it’s a system aimed to be flashed on the recovery partition, is it right? What’s its use?
Finally I read about LineageOS which is the ultimate customization for the phone, it’s a “pure” Android, which is totally opensource (but it has to uses a lot of proprietary blob for devices AFAIK). I don’t think I’ll get there anyway. If I’m not mistaken it’s hard to do, especially with new phones nobody has ran LineageOS on, and there is something like no probability all the devices would work anyway.
Have a nice day.
there's no implication when you see "Orange state, your phone’s unlocked” unless you didn't the one who did it that means your device is tampered ..
also on SafetyNet is broad topic you can learn what it is here https://www.didgeridoohan.com/magisk/MagiskHideSafetyNet also
"Why would I need to pass this SafetyNet test for?" there are multiple reason such as you can't install banking apps,netflix, ...etc nor download them via playstore
moving on it is not recommend to backup userdata partition since it just contain all contains evidence of user activity. It contains call and SMS records, contacts, user-installed apps, app data, settings, and so-on-and-so-forth. In most newer phones, it also is likely to contain photos and videos and other user-generated files unless an external SD card is present. Also it would be impossible to restore userdata partition since android is encrypting it with unique key every time you set up your device https://source.android.com/security/encryption/full-disk
this prevent rooted application crawling on other application data such as paypal just stealing your login info and money
TWRP is like recovery mode but more feature packed (you can backup partition with it not available on stock recovery)
also experience is the best teacher you must experience failure to improve
ineedroot69 said:
Also it would be impossible to restore userdata partition since android is encrypting it with unique key every time you set up your device https://source.android.com/security/encryption/full-disk
this prevent rooted application crawling on other application data such as paypal just stealing your login info and money
Click to expand...
Click to collapse
With a simple ADB command you can decrypt Android partitions:
Code:
adb shell "recovery --set_encrypted_filesystem=on|off" <- enables / diasables encrypted fs
Hi,
Many thx for your answers.
also experience is the best teacher you must experience failure to improve
Click to expand...
Click to collapse
I can confirm that. I accidentally uninstalled the stock launcher with ADB. I’ve been able to install another launcher (I think I’ll keep on Nova Launcher). I tested a few (Launcher<3 and KISS Launcher), although they work fine none of them support switching between running apps. It’s a little bit annoying but I have another way to stop running apps (with App Manager). I guess the only way to get this functionality back is to flash again the boot partition with the Magisk patched image I already used, and to re-configure all the phone again (this is good to learn and luckily I don’t have important data in the phone yet).
Also it would be impossible to restore userdata partition since android is encrypting it with unique key every time you set up your device https://source.android.com/security/encryption/full-disk
Click to expand...
Click to collapse
Couldn’t be possible to dump both boot and userdata partitions and then flash them back both “at once”. The key for encrypting/decrypting the user data being contains in the boot (system ?) partition?
I realize Android has a bunch of security configuration you rarely find on a Linux server. Also the hardware is full of devices which require close-source firmware to operate. This is definitively not a good platform for hacking, like most PC are or a Rasberry Pi is . And I bet Windows and Apple phones are evermore closed…
About encrypting, I have a file called "googlekey/kb_0000000000.bin", which is the same in two archives the support sent me
$ md5sum S9S88A7.DGE.DOOGEE.*/googlekey/kb*
ead8a1d0f11e5f12bdda0f7a22935c2b S9S88A7.DGE.DOOGEE.EEA.HB.HJ.AYYDVFAZ.1130.V3.02/googlekey/kb_0000000000.bin
ead8a1d0f11e5f12bdda0f7a22935c2b S9S88A7.DGE.DOOGEE.HB.HJ.AYYDVFAZ.1203.V3.04/googlekey/kb_0000000000.bin
Click to expand...
Click to collapse
This file is not “per device” knowing every S96Pro users get the same archives. What’s its purpose?
I wonder the same for many files in this archive but I won’t bother you, I’ll make some search.
The one thing I’d like to understand is why the archive is labelled "1203.V3.04" and the system on my phone (after I flashed the boot partition with (a Magisk patched made from) the boot.img in this archive says : "0128.V3.03_20210128". Could it be related to the Magisk patching? (I didn’t check what I had with the stock boot.img). Or I have been downgraded by Google during install?
With a simple ADB command you can decrypt Android partitions:
Click to expand...
Click to collapse
Thx for this. What does it imply to do so? Will the Android system run with this unencrypted data partition? Is there a way to encrypt it again? (With ADB or directly in the phone?)
I’ve seen there are dozens of partitions on a running Android. So far this is what I understood (is this correct?) : There are three important partitions : boot, recovery and userdata. "boot" et "recovery" are the only ones the device can boot on (except booting from an image in fastboot mode using "fastboot boot boot.img"?). Are they some other important partitions this is important to be aware of?
Having a bootable "boot" and a bootable "recovery" partitions, it should be possible to install two different Android OS? I guess this is not possible and the "recovery" partition is dedicated to recovering (ie: reinstall the system) but I don’t understand how and why exactly. The encrypting thing maybe? The system must have a userdata partition and this one can’t be shared between to system…
I think I should buy an older Android smartphone to make all that kind of test, especially knowing I don’t have any other phone I can use for everyday use… Do you have some advice on brands and models which are more friendly with customization of the system?
Apart of ADB and fastboot, what are the other important tools to know about?
For Android development (I mean development of apps for Android), does everyone use an emulator? What’s the best option for such an emulator on Linux?
Have a nice day.
Marotte said:
For Android development (I mean development of apps for Android), does everyone use an emulator? What’s the best option for such an emulator on Linux?
Click to expand...
Click to collapse
My recommendation is GenyMotion for Linux. This emulator requires VirtualBox for Linux gets installed before.
Install GenyMotion
How To Install GenyMotion (Android Emulator) On Linux | 2DayGeek
2daygeek.com Linux Tips, Tricks & News today :- How to Install GenyMotion (Android Emulator) on Ubuntu, Debian, Linux Mint, openSUSE, Arch Linux, Fedora, CentOS, RHEL, Mageia, Manjaro
www.2daygeek.com
DL VirtualBox
Linux_Downloads – Oracle VM VirtualBox
www.virtualbox.org
Marotte said:
Having a bootable "boot" and a bootable "recovery" partitions, it should be possible to install two different Android OS? I guess this is not possible and the "recovery" partition is dedicated to recovering (ie: reinstall the system) but I don’t understand how and why exactly. The encrypting thing maybe?
Click to expand...
Click to collapse
Partitions /boot & /recovery explained:
/boot
This is the partition that enables the phone to boot, as the name suggests. It includes the kernel and the ramdisk. Without this partition, the device will simply not be able to boot.
/recovery
The recovery partition can be considered as an alternative boot partition that lets you boot the device into a recovery console for performing advanced recovery and maintenance operations on it.
That's what you can do from within the recovery console:
Reboot system now
Install ZIP from SD-card
Install ZIP from Sideload
Wipe data / factory reset
Wipe cache partition
Backup and restore
Hi,
Many thx for your answers.
also experience is the best teacher you must experience failure to improve
Click to expand...
Click to collapse
I can confirm that. I accidentally uninstalled the stock launcher with ADB. I’ve been able to install another launcher (I think I’ll keep on Nova Launcher). I tested a few (Launcher<3 and KISS Launcher), although they work fine none of them support switching between running apps. It’s a little bit annoying but I have another way to stop running apps (with App Manager). I guess the only way to get this functionality back is to flash again the boot partition with the Magisk patched image I already used, and to re-configure all the phone again (this is good to learn and luckily I don’t have important data in the phone yet).
Also it would be impossible to restore userdata partition since android is encrypting it with unique key every time you set up your device https://source.android.com/security/encryption/full-disk
Click to expand...
Click to collapse
Couldn’t be possible to dump both boot and userdata partitions and then flash them back both “at once”. The key for encrypting/decrypting the user data being contains in the boot (system ?) partition?
I realize Android has a bunch of security configuration you rarely find on a Linux server. Also the hardware is full of devices which require close-source firmware to operate. This is definitively not a good platform for hacking, like most PC are or a Rasberry Pi is . And I bet Windows and Apple phones are evermore closed…
About encrypting, I have a file called "googlekey/kb_0000000000.bin", which is the same in two archives the support sent me
$ md5sum S9S88A7.DGE.DOOGEE.*/googlekey/kb*
ead8a1d0f11e5f12bdda0f7a22935c2b S9S88A7.DGE.DOOGEE.EEA.HB.HJ.AYYDVFAZ.1130.V3.02/googlekey/kb_0000000000.bin
ead8a1d0f11e5f12bdda0f7a22935c2b S9S88A7.DGE.DOOGEE.HB.HJ.AYYDVFAZ.1203.V3.04/googlekey/kb_0000000000.bin
Click to expand...
Click to collapse
This file is not “per device” knowing every S96Pro users get the same archives. What’s its purpose?
I wonder the same for many files in this archive but I won’t bother you, I’ll make some search.
The one thing I’d like to understand is why the archive is labelled "1203.V3.04" and the system on my phone (after I flashed the boot partition with (a Magisk patched made from) the boot.img in this archive says : "0128.V3.03_20210128". Could it be related to the Magisk patching? (I didn’t check what I had with the stock boot.img). Or I have been downgraded by Google during install?
With a simple ADB command you can decrypt Android partitions:
Click to expand...
Click to collapse
Thx for this. What does it imply to do so? Will the Android system run with this unencrypted data partition? Is there a way to encrypt it again? (With ADB or directly in the phone?)
I’ve seen there are dozens of partitions on a running Android. So far this is what I understood (is this correct?) : There are three important partitions : boot, recovery and userdata. "boot" et "recovery" are the only ones the device can boot on (except booting from an image in fastboot mode using "fastboot boot boot.img"?). Are they some other important partitions this is important to be aware of?
Having a bootable "boot" and a bootable "recovery" partitions, it should be possible to install two different Android OS? I guess this is not possible and the "recovery" partition is dedicated to recovering (ie: reinstall the system) but I don’t understand how and why exactly. The encrypting thing maybe? The system must have a userdata partition and this one can’t be shared between to system…
I think I should buy an older Android smartphone to make all that kind of test, especially knowing I don’t have any other phone I can use for everyday use… Do you have some advice on brands and models which are more friendly with customization of the system?
Apart of ADB and fastboot, what are the other important tools to know about?
For Android development (I mean development of apps for Android), does everyone use an emulator? What’s the best option for such an emulator on Linux?
Have a nice day.
Have a nice day.
jwoegerbauer said:
My recommendation is GenyMotion for Linux. This emulator requires VirtualBox for Linux gets installed before.
Install GenyMotion
How To Install GenyMotion (Android Emulator) On Linux | 2DayGeek
2daygeek.com Linux Tips, Tricks & News today :- How to Install GenyMotion (Android Emulator) on Ubuntu, Debian, Linux Mint, openSUSE, Arch Linux, Fedora, CentOS, RHEL, Mageia, Manjaro
www.2daygeek.com
DL VirtualBox
Linux_Downloads – Oracle VM VirtualBox
www.virtualbox.org
Click to expand...
Click to collapse
I went for the official Android Studio from Google. I guess it’s the best for a complete newbie like me. I’ve been able to start a virtual phone with it.

Question A newbie question about X3 Pro with LineageOS

Hi Fellows,
First of all, I’m newbie to flashing (or so-called) phones. I want to change my phone for de-googled one. I’m thinking about POCO X3 Pro with LineageOS 18.1.
I’ve been recently reading a lot about changing OS, but I feel completely overwhelmed by how complex knowledge it is. Even on the forum there is so much info, so much specific vocabulary/acronyms
Can you advise me, how to start?
Or maybe different way... do you know any reliable service/somebody in the UK, who could help? I've already checked services in my town - no one does software modifications
kamien8 said:
Hi Fellows,
First of all, I’m newbie to flashing (or so-called) phones. I want to change my phone for de-googled one. I’m thinking about POCO X3 Pro with LineageOS 18.1.
I’ve been recently reading a lot about changing OS, but I feel completely overwhelmed by how complex knowledge it is. Even on the forum there is so much info, so much specific vocabulary/acronyms
Can you advise me, how to start?
Or maybe different way... do you know any reliable service/somebody in the UK, who could help? I've already checked services in my town - no one does software modifications
Click to expand...
Click to collapse
You don´t need to pay someone else for that, you can do it by your own.
I will give you the topics in order, one by one, and just search for the info till understand what you are want to achieve.
1-Unlocking bootloader.
2-Flashing a custom recovery.
3-Rooting (optional)
4-installing a custom ROM (like LineageOS)
Search for these topics in your own forum, read carefully and apply them when you are sure what you are doing.
Copied these from my old post in other forums, I updated a little but still might be a little outdated
Spoiler: How to unlock bootloader
Link your poco x3 pro to your MI account
Activate "Find my device" for Mi account
Settings > About Phone > Tab "MIUI version (For POCO)" until developer mode unlocked
Settings > Additional Settings > Developer Options
OEM unlocking - Checked
Mi Unlock status > Add account and device - Do only once, anymore will reset 168 hours unlock counter
Go to https://en.miui.com/unlock/and download the mi unlock software
Latest version to date of this post is https://miuirom.xiaomi.com/rom/u1106245679/5.5.224.55/miflash_unlock-en-5.5.224.55.zip
Prepare for future unlock
Turn off your mobile
Boot into fastboot mode - Volume Down + Power
Run "MiUsbDriver.exe" located in the miflash_unlock_en zip
Connect mobile to PC or laptop
Poco X3 Pro driver should be installed
Run "miflash_unlock.exe" and proceed through the software
If you yet to apply for permission to unlock, you can apply from there (I think, the last I applied was years ago, not sure still a thing now or not)
The software will tell you the countdown which is 168 hours aka 1 week.
Exit fastboot mode on phone by holding the power button.
A week later, time to unlock.
Backup your file, if you have used the phone intensively, unlocking will result in factory reset.
Turn off mobile
Boot into fastboot mode - Volume Down + Power
Run "miflash_unlock.exe"
Connect mobile to PC
Proceed through "miflash_unlock.exe"
Unlocked
Spoiler: How to Flash Custom Recovery
Download google platform tool from https://developer.android.com/studio/releases/platform-tools
Extract the tool
In the tool folder, type "cmd" at "Address bar" to open command prompt to that folder
Press enter after you type "cmd", if it isn't obvious.
Turn off mobile
Boot into fastboot mode - Volume Down + Power
Connect mobile to PC
Go to command prompt window, type "fastboot devices".
Your phone will be shown if detected, otherwise, fix your driver.
Download Custom Recovery
OrangeFox - https://orangefox.download/device/vayu
TWRP - https://forum.xda-developers.com/t/recovery-unofficial-teamwin-recovery-project.4269551/
Lineage OS Recovery - https://download.lineageos.org/vayu
Don't use LOS recovery if you are rooting, it doesn't support OTA data decryption thus magisk need to be reflashed everytime during OTA.
Extract the "img" recovery file to the tool's folder
Type "fastboot flash recovery <filename>"
Done, type "fastboot reboot recovery" or Volume Up + Power on mobile to enter recovery
Spoiler: How to Flash Custom Rom
Connect mobile to PC
Copy files to mobile
Firmware - https://xiaomifirmwareupdater.com/firmware/vayu/
Rom
XDA Roms - https://forum.xda-developers.com/f/xiaomi-poco-x3-pro.12163/?prefix_id=33
Xiaomi EU Rom - https://xiaomi.eu/community/forums/miui-rom-releases.103/
Gapp (if you want)
MindtheGapps
NikGapps
FlameGapps
OpenGapps (Personally Recommended)
Magisk (If rooting) - https://github.com/topjohnwu/Magisk/releases
Boot into recovery - Vol up + Power
install in order
Firmware
Rom
Gapps (if you want)
Magisk (if rooting)
Format data in recovery
Wipe Cache and Dalvik/Art Cache (If the recovery support it)
Reboot into system
Done
If you mess up the format data sequence, don't worry, you can always use "adb sideload". Also, if you use LOS recovery, you need to use sideload.
Look for sideload in recovery
Open command prompt in your tool folder, type "adb sideload <filename>" to install the things you want.
Spoiler: How to flash back or to official rom along with official recovery
Download xiaomi flash tool - https://xiaomiflashtool.com/
Download fastboot package - https://xiaomifirmwareupdater.com/archive/miui/vayu/
Extract xiaomi flash tool, run "XiaoMiFlash.exe"
Extract fastboot package to somewhere, preferably root subfolder of c:\ or whatever drive
Long pathname can cause "XiaoMiFlash.exe" to run into error
Boot mobile into fastboot - Vol down + power
Connect mobile to pc
In "XiaoMiFlash.exe", select folder of fastboot package
Bottom right of the software, choose "clean all" or "clean and lock (bootloader)"
Click flash
Once done, it will auto reboot into MIUI
Spoiler: How to pass safetynet for custom rom
At the moment of this post, most custom roms fail safetynet. It is not absolutely necessary to get safetynet to work. Only do this if the gapps you want to install require it.
Install magisk (No way around it)
Install props config module
Reboot
Run any terminal app - https://play.google.com/store/apps/details?id=com.termux
Type "su" and enter
Grant super user rights to it
Type "props" and enter
Type "1" and enter
Type "f" and enter
Type "22" and enter
Type "6" and enter
Basically, you are choosing "Poco X3 Pro (Global)"
Type "y"
Reboot and test your safetynet
Spoiler: How to make Nasty Anti-Root Apps work with Magisk
In magisk, install Riru module
Download Unshare - https://github.com/vvb2060/riru-unshare/releases
In magisk, install Unshare
In magisk, enable "Magisk Hide" in settings
In magisk, "hide Magisk" in settings, choose some really unpredictable name
In magisk, press "Shield", hide all options (dropdown) for the targetted App
Reboot
Try run the apps multiple times
If fail
Install App Manager - https://f-droid.org/en/packages/io.github.muntashirakon.AppManager/
In App Manager, look for the apps, go to "Services", disable that one "(Isolated)" service.
Double make sure it is applied
Reboot
Try run the apps multiple times
Still fail
Try this, some say it worked
In magisk, install LsPosed module
Install XPrivacyLua - https://repo.xposed.info/module/eu.faircode.xlua
In LsPosed, enable XprivacyLua and Singpass in that same list
Reboot
In XPrivacyLua, look for the app, enable restrict on "Get Applications"
Reboot
Try run the apps multiple times
this is the last resort
Install Shelter - https://play.google.com/store/apps/details?id=net.typeblog.shelter
Clone the App in Shelter
In shelter, under work profile, make sure no rooted apps in there
Reboot
Try run the App in work profile multiple times
SubwayChamp said:
You don´t need to pay someone else for that, you can do it by your own [...]
Click to expand...
Click to collapse
Thanks a lot. It makes sense.
I was also told, that before flashing it is esential to do a backup.
What's your opinion? How to do so?
kamien8 said:
Thanks a lot. It makes sense.
I was also told, that before flashing it is esential to do a backup.
What's your opinion? How to do so?
Click to expand...
Click to collapse
About backup the first important is what is important for one, I mean personal information like messages, call, WhatsApp and so on.
But the most important in other sense is about the well functioning of the device itself, for example EFS where is stored the IMEIs, sometimes vendor, dtbo and persist images depending on the custom recovery if it includes these options.
Particularly, I never need any other partition from recovering eventually my device/s.
I would like to suggest you to try flashing some roms on any other device which you don't use(for ex. an old abandoned phone) and gain some experience before trying on your poco x3 pro.
dey18 said:
I would like to suggest you to try flashing some roms on any other device [...]
Click to expand...
Click to collapse
That was my idea. Unfortunately the only 'old' phone I've got is Huawei P9 Lite 2017 with Android 7. I haven't found any information, that there is a way to install LineageOS on the device.
However, for training purposes I could install any different OS, suitable for the device. Do you know any?
By the way, is the following link the only valid repository for the OS?
LineageOS Downloads
download.lineageos.org
kamien8 said:
That was my idea. Unfortunately the only 'old' phone I've got is Huawei P9 Lite 2017 with Android 7. I haven't found any information, that there is a way to install LineageOS on the device.
However, for training purposes I could install any different OS, suitable for the device. Do you know any?
By the way, is the following link the only valid repository for the OS?
LineageOS Downloads
download.lineageos.org
Click to expand...
Click to collapse
yes, thats the official site
kamien8 said:
That was my idea. Unfortunately the only 'old' phone I've got is Huawei P9 Lite 2017 with Android 7. I haven't found any information, that there is a way to install LineageOS on the device.
However, for training purposes I could install any different OS, suitable for the device. Do you know any?
By the way, is the following link the only valid repository for the OS?
LineageOS Downloads
download.lineageos.org
Click to expand...
Click to collapse
If you had no experience of flashing a phone, read and follow this guide with Pictures :
https://forum.xda-developers.com/t/4288121/post-85137963
It should be sufficient to help you flash a ROM.
No tutorial about backup data from phone in that guide, you have to do it on your own.
pl1992aw said:
If you had no experience of flashing a phone, read and follow this guide with Pictures :
https://forum.xda-developers.com/t/4288121/post-85137963
It should be sufficient to help you flash a ROM.
No tutorial about backup data from phone in that guide, you have to do it on your own.
Click to expand...
Click to collapse
I like this method, and this specific guide is what helped me flash custom rom on my X3 pro.
It is detailed and even gives notice if in case we get lost in a step.
I hope the OP can read this as the guide was really helpful. I know they used arrowOS for example, but I applied the method with different rom.
kamien8 said:
That was my idea. Unfortunately the only 'old' phone I've got is Huawei P9 Lite 2017 with Android 7. I haven't found any information, that there is a way to install LineageOS on the device.
However, for training purposes I could install any different OS, suitable for the device. Do you know any?
By the way, is the following link the only valid repository for the OS?
LineageOS Downloads
download.lineageos.org
Click to expand...
Click to collapse
I suggest you to try any other roms available for your device and not just lineage.
Try flashing multiple roms one by one and identify and rectify your errors.
And don't forget to read documentation provided by the wiki completely and also check out some vids on youtube(people on telegram would tell you to watch yt channel named "Munchy" because he has got this phone).
I wouldn't try and flash an old p9 lite. I remember when I had a p9 and tried to flash it it was a nightmare and was an unorthodox method. If you could grab an old Moto like the Moto g as that would be ideal for a practise flash.
Warren_Orange said:
[...] Moto g [...]
Click to expand...
Click to collapse
I've never used Motorola before. Which G would be good to start gaining an experience?
I'll try to find a pre-owned one.
I'd go for a moto g 2nd or 3rd Gen. You can get them for peanuts on eBay and there is still development for them even now.
I recommend Moto G5.. pretty active community on xda, replacable battery and should be very cheap
k3lcior said:
I recommend Moto G5.. pretty active community on xda, replacable battery and should be very cheap
Click to expand...
Click to collapse
Moto G5
Warren_Orange said:
I'd go for a moto g 2nd or 3rd Gen. You can get them for peanuts on eBay and there is still development for them even now.
Click to expand...
Click to collapse
Do you mean something like this?
gsmarena_moto_g
Will it be possible to go with LineageOS 18.1 on such an old phone?
kamien8 said:
Moto G5
Do you mean something like this?
gsmarena_moto_g
Will it be possible to go with LineageOS 18.1 on such an old phone?
Click to expand...
Click to collapse
Yes that's the one. After having a quick look at the forums I don't think you'd get 18.1 on it. There is a micro g 17.1 rom that seems active.
Is this for practice or for use as well? If it's for using I'd probably go with the g5 for a few bucks extra as the Moto g is quite old but it's not a bad spare spare phone. I picked one up as a backup and I liked the feel of it (if your into small phones) . It reminded me of the first Moto X.

[GUIDE] Assurance Wireless KonnectONE Moxee m2160 (MH-T6000) Rooting Guide

Assurance Wireless
KonnectONE Moxee m2160
4G-LTE Smartphone
Model No. MH-T6000
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Rooting Guide​
OVERVIEW:
This guide outlines simplified instructions for rooting the Assurance Wireless Moxee MH-T6000 4G-LTE smartphone. To cater this guide to new and inexperienced members, I have provided a stock boot image pre-patched with the Magisk v26.1 systemless root solution.
PREREQUISITES:
First and foremost, you need an unlocked bootloader. If your bootloader is not yet unlocked, complete that task and then return here. XDA hosts a plethora of how-to guides on standard bootloader unlocking. You will also need a Windows PC or laptop running the Minimal ADB & Fastboot Tools (link provided below). It should be noted that this guide can be carried out on a Mac or Linux computer as well; however, for purposes of this guide, I am focusing solely on a Windows setup. It is highly recommended that your device be running firmware build number MH-T6000V1.0.OB010, with the March 5, 2023 security patch level. As OTA updates are rolled out for this device, I will try to keep this guide updated with a patched boot image that corresponds with the latest firmware build.
Finally, you will need the factory supplied, or a quality equivalent USB-A to USB-C charging/syncing cable.
DISCLAIMER:
By proceeding further, you are assuming sole responsibility for the integrity and operability of your smartphone. Rooting your device is a task that carries with it the inherent risk of bricking or otherwise rendering your phone inoperable. While this guide has been thoroughly tested on my own device, you have been warned. Proceed at your own risk.
INSTRUCTIONS:​
Download the ADB & Fastboot tools from the link below and install the program on your PC or laptop;​
Open your Windows File Explorer, navigate to your C: drive, Program Files x86, and locate the Minimal ADB & Fastboot folder. Copy this folder and paste it to your desktop. (This step is not required, but is recommended for easier access of the ADB & Fastboot path);​
Download the patched boot image from the below link and save the image in your ADB & Fastboot folder. Note: the filename for the patched boot image is patched_boot.img. The flashing commands assume that you leave the filename unchanged;​
Boot your phone into fastboot mode by first powering your device off, and then holding the power and volume down keys simultaneously until fastboot mode appears on your device display;​
Connect your smartphone to your Windows computer using the factory supplied or a quality equivalent USB-A to USB-C charging/syncing cable;​
Open your ADB & Fastboot folder and double click cmd-here.exe to open a command window. Execute this command to verify a proper fastboot connection:
Code:
fastboot devices
If properly connected, the command window will return an alphanumeric string consistent with your device serial number;​
Once a proper connection has been verified, execute this command:
Code:
fastboot flash boot patched_boot.img
Now execute:
Code:
fastboot reboot
Upon reboot, open your app drawer and tap on the Magisk app or its placeholder stub. Ensure you are connected to the internet, grant any permissions, and follow any prompts given by Magisk to update to the full version in order to complete the root environment setup. Magisk may reboot your device during this process.​
That's it. You're now rooted via the Magisk v26.1 systemless root solution.​
IMPORTANT NOTE:
In the unfortunate event that you get stuck in a boot loop or brick your device using this guide, my guide on unbricking this smartphone will get you back up and running fairly quickly. This guide can be used to restore both soft bricked and hard bricked devices. You can then return here and give rooting another go.
Moxee MH-T6000 Unbricking Guide​DOWNLOADS:
• Minimal ADB & Fastboot v1.4.3
• Magisk Patched Boot Image
THANKS & MENTIONS:
A huge thanks and shout-out to @omb714.1980 for donating the Moxee smartphone that made this rooting guide possible. You are a scholar and a gentleman, good sir. Thanks also to KonnectONE support specialist Faith Flores for releasing to me the factory firmware for this device.​
Viva La Android said:
Assurance Wireless
Moxee MH-T6000 4G-LTE
View attachment 5893661
Rooting Guide​
OVERVIEW:
This guide outlines simplified instructions for rooting the Assurance Wireless Moxee MH-T6000 4G-LTE smartphone. To cater this guide to new and inexperienced members, I have provided a stock boot image pre-patched with the Magisk v26.1 systemless root solution.
PREREQUISITES:
First and foremost, you need an unlocked bootloader. If your bootloader is not yet unlocked, complete that task and then return here. You will also need a Windows PC or laptop running the Minimal ADB & Fastboot Tools (link provided below). It should be noted that this guide can be carried out on a Mac or Linux computer as well; however, for purposes of this guide, I am focusing solely on a Windows setup. It is highly recommended that your device be running firmware build number MH-T6000V1.0.OB010, with the March 5, 2023 security patch level. Finally, you will need the factory supplied, or a quality equivalent USB-A to USB-C charging/syncing cable.
DISCLAIMER:
By proceeding further, you are assuming sole responsibility for the integrity and operability of your smartphone. Rooting your device is a task that carries the inherent risk of bricking or otherwise rendering your phone inoperable. While this guide has been thoroughly tested on my own device, you have been warned. Proceed at your own risk.
INSTRUCTIONS:​
Download the ADB & Fastboot tools from the link below and install the program on your PC or laptop;​
Open your Windows File Explorer, navigate to your C: drive, Program Files x86, and locate the Minimal ADB & Fastboot folder. Copy this folder and paste it to your desktop. (This step is not required, but is recommended for easier access of the ADB & Fastboot path);​
Download the patched boot image from the below link and save the image in your ADB & Fastboot folder;​
Boot your phone into fastboot mode by first powering your device off, and then holding the power and volume down keys simultaneously until fastboot mode appears on your device display;​
Connect your smartphone to your Windows computer using the factory supplied or a quality equivalent USB-A to USB-C charging/syncing cable;​
Open your ADB & Fastboot folder and double click cmd-here.exe to open a command window. Execute this command to verify a proper fastboot connection:
Code:
fastboot devices
If properly connected, the command window will return an alphanumeric string consistent with your device serial number;​
Once a proper connection has been verified, execute this command:
Code:
fastboot flash boot patched_boot.img
Now execute:
Code:
fastboot reboot
Upon reboot, open your app drawer and tap on the Magisk app or its placeholder stub. Ensure you are connected to the internet, grant any permissions, and follow any prompts given by Magisk to update to the full version in order to complete the root environment setup. Magisk may reboot your device during this process.​
That's it. You're now rooted via the Magisk v26.1 systemless root solution.​
DOWNLOADS:
• Minimal ADB & Fastboot v1.4.3
• Magisk Patched Boot Image
THANKS & MENTIONS:
A huge thanks and shout-out to @omb714.1980 for donating the Moxee smartphone that made this rooting guide possible. You are a scholar and a gentleman, good sir. Thanks also to the KonnectONE support team for releasing to me the factory firmware for this device.​
Click to expand...
Click to collapse
Lol. Now you post this. After unsuccessfully scouring the internet for the stock firmware. I finally did the same as you and simply reached out to konnectone and asked for it. I just came here to see if there was anyone here that is by far more knowledgeable than myself (not hard) interested to have the firmware and would post a guide like this one. Well done!
Would you happen to have a twrp recovery compiled for this device by chance? Or if not but planning on it would you let me know please. I would appreciate it!
scottfan81 said:
Lol. Now you post this. After unsuccessfully scouring the internet for the stock firmware. I finally did the same as you and simply reached out to konnectone and asked for it. I just came here to see if there was anyone here that is by far more knowledgeable than myself (not hard) interested to have the firmware and would post a guide like this one. Well done!
Would you happen to have a twrp recovery compiled for this device by chance? Or if not but planning on it would you let me know please. I would appreciate it!
Click to expand...
Click to collapse
I just got KonnectONE to agree to release firmware a couple of days before you mentioned having firmware. It's been a long wait indeed.
I don't have source code to compile TWRP; only the firmware. I will be attempting to port a TWRP build for this phone very soon. My legal battle with KonnectONE was in regards to source code under the General Public License 2.0. Because they were ultimately unable to provide kernel source, their legal team and support department finally acquiesced to provide firmware to device owners upon written request. I compromised for the firmware release, but was not able to get kernel source code for building TWRP. I am pretty confident that a ported TWRP can be ironed out as a stable build. I already have the base build selected.
Thank you so much! I have 3 of these devices and been waiting lol. I see the stock kernel has hot-plug . What's some good tuning profiles? I tried to debloat permanently with LP but it didn't work. I think it's read-only so I flashed the magisk overlay for rw and going to play. We definitely need TWRP! I see a port may be in the works. Awesome. Thanks again
Viva La Android said:
I just got KonnectONE to agree to release firmware a couple of days before you mentioned having firmware. It's been a long wait indeed.
I don't have source code to compile TWRP; only the firmware. I will be attempting to port a TWRP build for this phone very soon. My legal battle with KonnectONE was in regards to source code under the General Public License 2.0. Because they were ultimately unable to provide kernel source, their legal team and support department finally acquiesced to provide firmware to device owners upon written request. I compromised for the firmware release, but was not able to get kernel source code for building TWRP. I am pretty confident that a ported TWRP can be ironed out as a stable build. I already have the base build selected.
Click to expand...
Click to collapse
They never replied when I emailed them about it several months ago . This is so awesome. I got rid of most of the lag with kernel manager. Kudos
Argonon said:
They never replied when I emailed them about it several months ago . This is so awesome. I got rid of most of the lag with kernel manager. Kudos
Click to expand...
Click to collapse
Several months ago they weren't releasing firmware to the public. I got it released by battling with them over open source code and I ultimately compromised for factory firmware. It was only recently made public.
Yeah I've noticed a nice performance boost too with some debloating and sone kernel tweaks. I'm using EX Kernel Manager. Keep in mind this device uses dynamic partitioning (super.img). As such, even with root, it isn't always possible to mount /system r/w. I extracted the super.img on a PC and then mounted /system, /vendor and /product, debloated, and then repacked and reflashed super img.
Awesome. I don't have a good pc now unfortunately. I do have viper4android repackaged version with driver and effects pre-installed. I used smart pack kernel manager to tweak kernel. The device is very useable now! I have a Blu View 3 android 11 mtk device id love to root but can't even unlock bootloader. Maybe I should look into emailing them
Argonon said:
Awesome. I don't have a good pc now unfortunately. I do have viper4android repackaged version with driver and effects pre-installed. I used smart pack kernel manager to tweak kernel. The device is very useable now! I have a Blu View 3 android 11 mtk device id love to root but can't even unlock bootloader. Maybe I should look into emailing them
Click to expand...
Click to collapse
BLU won't unlock your bootloader. It is locked per contractual agreement with the branded carrier of the phone. However, if it's MediaTek, you may be able to use MTK Client to exploit the bootloader into an unlocked state.
Viva La Android said:
Several months ago they weren't releasing firmware to the public. I got it released by battling with them over open source code and I ultimately compromised for factory firmware. It was only recently made public.
Yeah I've noticed a nice performance boost too with some debloating and sone kernel tweaks. I'm using EX Kernel Manager. Keep in mind this device uses dynamic partitioning (super.img). As such, even with root, it isn't always possible to mount /system r/w. I extracted the super.img on a PC and then mounted /system, /vendor and /product, debloated, and then repacked and reflashed super img.
Click to expand...
Click to collapse
Would you plz share your super.img ? I'm on latest firmware and have attached screenshot of build etc.... I understand if you can't or don't want to. Can I pull mine since I'm rooted? Problem is I have a old Chromebook that I installed endeavor os on its arch based Linux but I don't have much hard drive space to do work
Viva La Android said:
Several months ago they weren't releasing firmware to the public. I got it released by battling with them over open source code and I ultimately compromised for factory firmware. It was only recently made public.
Yeah I've noticed a nice performance boost too with some debloating and sone kernel tweaks. I'm using EX Kernel Manager. Keep in mind this device uses dynamic partitioning (super.img). As such, even with root, it isn't always possible to mount /system r/w. I extracted the super.img on a PC and then mounted /system, /vendor and /product, debloated, and then repacked and reflashed super img.
Click to expand...
Click to collapse
Would you plz share your super.img ? I'm on latest firmware and have attached screenshot of build etc.... I understand if you can't or don't want to. Can I pull mine since I'm rooted? Problem is I have a old Chromebook that I installed endeavor os on its arch based Linux but I don't have much hard drive space to do work
Viva La Android said:
I just got KonnectONE to agree to release firmware a couple of days before you mentioned having firmware. It's been a long wait indeed.
I don't have source code to compile TWRP; only the firmware. I will be attempting to port a TWRP build for this phone very soon. My legal battle with KonnectONE was in regards to source code under the General Public License 2.0. Because they were ultimately unable to provide kernel source, their legal team and support department finally acquiesced to provide firmware to device owners upon written request. I compromised for the firmware release, but was not able to get kernel source code for building TWRP. I am pretty confident that a ported TWRP can be ironed out as a stable build. I already have the base build selected.
Click to expand...
Click to collapse
I have 3 of these devices. I surly can test TWRP port if needed
Argonon said:
Would you plz share your super.img ? I'm on latest firmware and have attached screenshot of build etc.... I understand if you can't or don't want to. Can I pull mine since I'm rooted? Problem is I have a old Chromebook that I installed endeavor os on its arch based Linux but I don't have much hard drive space to do work
I have 3 of these devices. I surly can test TWRP port if needed
Click to expand...
Click to collapse
Sure. I don't mind sharing my super.img. I'll need to upload it and then I'll message you a link. It's pretty much exactly 2.5 GB in file size, so I'll first compress it to a zip before uploading.
The edited one. Just clarifying so appreciated
Argonon said:
The edited one. Just clarifying so appreciated
Click to expand...
Click to collapse
I don't yet have all my mods made to the /super partition in that regard. Having encountered some force close issues with certain apps, I debloated from scratch and and have now begun my kernel tweaks and edits to the.varuous .prop files. So when finished, I'll share both my boot.img and super.img.
Just the stock super.img would be fine then. I think I can figure how to decompile, debloat and recompile then flash.
Argonon said:
Just the stock super.img would be fine then. I think I can figure how to decompile, debloat and recompile then flash.
Click to expand...
Click to collapse
MH-T6000 super.img unmodified
I was experimenting and flashed the super.img with dsu side loader apk as a gsi lol. The app description said can replace various partitions and I was just trying to get system rw on the dsu loader. I know that makes no sense. What windows 11 compatible software do you recommend to unpack, repack etc? I see a few magisk modules but not quite sure how to use. Like ro2rw magisk module
Viva La Android said:
MH-T6000 super.img unmodified
Click to expand...
Click to collapse
Thank you!
Argonon said:
Thank you!
Click to expand...
Click to collapse
When I have completed debloating, kernel tweaks and .prop files edits of the OS, I'll share my modified super.img and boot.img. I have a TWRP v3.6.0 port build that is currently booting properly on this phone. But, I have bugs to work out on logical partition mounting, as well as the backup & restore functionality.
Argonon said:
I was experimenting and flashed the super.img with dsu side loader apk as a gsi lol. The app description said can replace various partitions and I was just trying to get system rw on the dsu loader. I know that makes no sense. What windows 11 compatible software do you recommend to unpack, repack etc? I see a few magisk modules but not quite sure how to use. Like ro2rw magisk module
Click to expand...
Click to collapse
Check out CRB Android Kitchen here on XDA. Great for unpacking / repacking partition images, including super.img.
Viva La Android said:
When I have completed debloating, kernel tweaks and .prop files edits of the OS, I'll share my modified super.img and boot.img. I have a TWRP v3.6.0 port build that is currently booting properly on this phone. But, I have bugs to work out on logical partition mounting, as well as the backup & restore
Click to expand...
Click to collapse
Have you had anymore luck with this

Categories

Resources