How To Guide [12.1][13] GSI Guide & Support [PHH][Mojito][Sunny]

Do you believe GSIs overcome custom ROMs in future ?

  • Meh. Both suck. Android devices are increasingly turning restrictive every year.

    Votes: 10 35.7%
  • I don't think so. They'll never overcome custom ROMs.

    Votes: 4 14.3%
  • I have fair skepticism on it. Both will have balanced usershare.

    Votes: 12 42.9%
  • Absolutely. Device tree maintenance is outdated already.

    Votes: 8 28.6%

  • Total voters
    28
Search This thread

RasitAyaz

Member
Feb 14, 2022
8
3
Redmi Note 10
thanks for the guide, how can i easily switch between one gsi rom to another? just flashing img to system via fastbootd would be enough? do i need to wipe anything?
 
  • Like
Reactions: RasitAyaz

ChristianWS

Senior Member
Sep 6, 2016
99
16
Moto G
Redmi Note 10
As per securize script...

Unfortunately, Andy is the only one who ships prerooted lineage gsi ¯\_(ツ)_/¯
Strangely, he quoted to keep both & ignore Abnormal state warning though.
I reflashed the entirety of Stock ROM using Fastboot AGAIN and redid the entire process (including erasing userdata), I don't know what the hell happened but Magisk doesn't complain anymore. I'm really not sure what the hell happened because it should produce the same results.

A few things I noticed:

- No double tap to wake, weird
- My linux partition(Tumbleweed) can't see my device when I connect and try to transfer files, windows can see it no problem
- I think there's something wrong with the notch and status bar. The status bar has the right height, but here they are in the center of the height, which makes the clock really close to the edge. As I remember, on stock it is a little bellow the center so that the bottom of the items align with the bottom edge of the notch.
 
No double tap to wake, weird
I think los doesn't include that. Try phh settings > Misc > Double tap to wake
My linux partition(Tumbleweed) can't see my device when I connect and try to transfer files, windows can see it no problem
Depends on what DE you're on. On gnome & other environments, try gvfs tools (gvfs-mtp). KDE, try kio. I'm on arch & have no issues with mtp.
which makes the clock really close to the edge.
Would you mind screenshot it & annotate the positions
 

ChristianWS

Senior Member
Sep 6, 2016
99
16
Moto G
Redmi Note 10
I think los doesn't include that. Try phh settings > Misc > Double tap to wake
I think LOS itself does, you can see mention of it in the requirements list, but not the GSI, or maybe it's an issue with Neternels, idk
Depends on what DE you're on. On gnome & other environments, try gvfs tools (gvfs-mtp). KDE, try kio. I'm on arch & have no issues with mtp.
I tried, but it didn't work. What's weird is that it always worked before moving to GSI, so again, idk

Would you mind screenshot it & annotate the positions
As far as I can guess it's because Xiaomi put the notch touching the bottom of the navbar, where on most devices it sits in the middle.

Edited everything to be more clear:

I've found some old screenshots so we have a way of comparing how different ROMs worked.

Here's how MIUI 12 worked:
MIUI.jpg


Here's how Alonso's LOS build worked:

Alonso LOS.png


And here's how it shows up with Andy's LOS GSI build:

GSI LOS.png


For some reason, Andy's LOS has a slightly different icon placement on the lockscreen, being closer to the bottom edge of the Status Bar, which feels more natural, IMO

GSI LOS Lockscreen.png


There's a difference on Icon size, but the issue is more clear once you consider the Vertical Alignment of those:

Comparison.png
 
Last edited:
  • Like
Reactions: RasitAyaz

Samir2298

Senior Member
Apr 3, 2015
260
25
Lemme know if overlay stuff is okay so that I need to push relevant changes.
Still testing but just a little update.

Had only one random freeze since new overlay. Happened while watching a video on FB. Got back to normal after like 30 seconds so didn't need to restart device. Not sure if it's related to overlay tho. Other than that so far no crashes/freezes.

Also here's memory usage. Android System and OS alone consuming 2.8 GB. Idk if it's normal or not.
 

Attachments

  • Screenshot_20221003-195253.png
    Screenshot_20221003-195253.png
    147.4 KB · Views: 9
  • Screenshot_20221003-200317.png
    Screenshot_20221003-200317.png
    113.1 KB · Views: 9

Samir2298

Senior Member
Apr 3, 2015
260
25
Ok apps are being force closed if I switch to one another. Overall UI is sluggish as well right now. I'm sure it's due to the android system and os consuming almost all ram. Restarting phone would bring everthing back to normal.
 
Android System and OS alone consuming 2.8 GB. Idk if it's normal or not.
No it's not normal. Did this issue exist on roms ?
I also don't think this is overlay specific. Phhusson said it's nothing to do with power profiles.
Need more details such as on what GSIs it occured, did you test both custom kernels? Also just try using stock kernel from stock boot & lemme know.
 

Samir2298

Senior Member
Apr 3, 2015
260
25
Just increased 100 MB more in usage
 

Attachments

  • Screenshot_20221003-201558_1.png
    Screenshot_20221003-201558_1.png
    29.7 KB · Views: 9
Can you share stock kernel and boot?
Just flash boot image from your stock mojito firmware. Both kernel & recoveries get replaced btw.
Only tested with Neternels on Phhusson's rom.
I'm on neternels/phh aosp too, but it's 6 gig variant (with avg memory of 3.1gB). So I'm not sure it's a specific issue with 4 gig variants. Try without overlay too once (you might face some issues like brightness & usage stats).

Also screenshot this page once.
 
  • Like
Reactions: Samir2298

Samir2298

Senior Member
Apr 3, 2015
260
25
Update:

I think phone just restarted "System UI", coz it went into full brightness for a second and took me to lockscreen. And everything seems normal now(I didn't restart myself)

Memory stats still show 2+ gb but I believe it will gradually go down in next 3 hrs.

Sorry for spamming too much. If you want, I can keep you updated in PM and keep this thread clean.
 

Attachments

  • Screenshot_20221003-204455.png
    Screenshot_20221003-204455.png
    145.2 KB · Views: 8
Last edited:
The screenshot I actually wanted to see was Android System (as Android OS is the lesser one in your case)
Memory stats still show 2+ gb but I believe it will get updated gradually in next 3 hrs.
Issue might be something completely different. Did you have developer options enabled? Lemme know if you have the same issue after disabling it.
Caz sometimes dev options mess up graphics allocator, hardware acceleration, etc.
Sorry for spamming too much. If you want, I can keep you updated in PM and keep this thread clean.
No prob. Spam in this thread as much as you want. I just want all discussions to be public.
 

ChristianWS

Senior Member
Sep 6, 2016
99
16
Moto G
Redmi Note 10
Apologies for the Portuguese in the screenshot, but I do have a 4 gig device so it might be useful to compare it, I'm on LOS, btw
 

Attachments

  • Screenshot_20221003-134559_Configurações.png
    Screenshot_20221003-134559_Configurações.png
    147.3 KB · Views: 12
  • Like
Reactions: Samir2298

Samir2298

Senior Member
Apr 3, 2015
260
25
@MPK99

Btw found this on TG from 27 Sept.
 

Attachments

  • Screenshot_20221003-220738_1.png
    Screenshot_20221003-220738_1.png
    338.9 KB · Views: 9
  • Screenshot_20221003-220810_1.png
    Screenshot_20221003-220810_1.png
    52.1 KB · Views: 9
  • 20221003_220907.jpg
    20221003_220907.jpg
    153.8 KB · Views: 7
  • 20221003_220911.jpg
    20221003_220911.jpg
    150.1 KB · Views: 8

ChristianWS

Senior Member
Sep 6, 2016
99
16
Moto G
Redmi Note 10
When did you restart phone last time?
35 hours ago
Are you facing any crashes/freeze or anything?
Nope.

Bear in mind, I flashed the latest Stock Rom through fastboot (mojito_global_images_V13.0.10.0.SKGMIXM_20220829.0000.00_12.0_global), so I might have a different firmware than you.

An easy way to tell was that before flashing the stock rom, my Fastboot screen had the Xiaomi mascot (a white Rabbit), after flashing it was simply the word "FASTBOOT"
 

Top Liked Posts

  • There are no posts matching your filters.
  • 1
    Update on my situation, I decided to use pixel experience custom rom for now since I can't get GSI to reliably work for me. Unfortunate as it is, I need a stable device for my needs at the moment.
    1
    View attachment 5767333
    I got this error and also tried AOSP, but same error
    Reboot to fastboot "fastboot reboot fastboot" and try again

    Use any kernel manager (spkm from "extras")
    Note that SmartPack-Kernel Manager is no more in extras section
    1

    UPDATE​

    On Android 13 (AOSP-td) some phhusson fixes need to be modified
    As @bobtear1 faced bluetooth audio output issues, make sure to disable Misc/Force disable A2DP Offload

    To fix camcorder, 3nable Misc/Force Enable Cam2API HAL3

    Updated OP post configuration too.
  • 12

    Why should I use a GSI ? Mojito already have custom ROMs ¯\_(ツ)_/¯

    Yes. But this thread exists due to the following reasons:
    • You have issues daily driving custom roms​
    • You don't wanna re-flash your custom recovery & kernel after each update​
    • You don't wanna fear about devs dropping support & stop giving monthly OTA updates​
    • You don't want to depend on / trust buildbot roms lurking on xda & telegram​
    • All GSIs support signature spoofing out of the box​
    AOSP GSI project is being alive for almost many years now. I've been daily driving his project on this device for almost an year. Everyone claim GSIs are buggy & not daily drivable, which is a complete false claim.

    PREREQUISITES

    Recommended GSIs :
    Right now lineage is the only stable A13 GSI.

    All phh based GSIs are dirty flashable, unless you try switching from vanilla to gapps or viceversa (or from A12->13 migration).

    INSTALLATION​

    NOTE: I'm assuming you've already unlocked bootloader, backed up your data & know all the technical consequences of flashing & modding.
    • Download / extract all prerequisites in one place.​
    • From stock firmware, edit flash_all_except_data_storage.bat/sh & modify last line to fastboot reboot fastboot
    • Enter fastboot mode {vol_down+power}, connect to PC & flash firmware using above edited script (make sure there are no spaces in folder names). When device enters fastbootd, from terminal/cmd execute :​
    • fastboot erase userdata
    • fastboot flash vbmeta vbmeta.img
    • fastboot flash system <gsi-file.img> (ignore INVALID SPARSE warning)​
    • fastboot reboot & make sure your GSI boots up. Power off & return to fastboot again.​
    • fastboot boot <twrp-file.img>, head to Advanced & run flash current TWRP to make recovery persistent across reboots.​
    • Flash Magisk (for safetynet fixes) and NetErnels / WCSF-PLC (for performance), either by twrp (copying them into an SD card), or through TWRP > Advanced > adb sideload <zip-file>.
    BUG_1: Don't touch the screen while booting, else it'll make the display unresponsive, leading you to force reboot. A minor bug, but can be ignored.
    BUG_2: Don't set up password on startup wizard. Instead, set it up later & then disable Android Setup app if it exists. Else it'll crash fingerprint settings.

    POST CONFIGURATION​

    • Setup Magisk from app-drawer. Follow in-app prompts & reboots.​
    • From magisk settings, hide the Magisk app, enable Zygisk & Enforce Denylist.​
    • Use SafetyNet Fix magisk module to pass CTS. Still won't pass? Try Pixel-Props that ensures fingerprinting.​
    • microG module if you chose vanilla variant (Safety net works. Most of the banking apps work except gpay).​
    • Enable the following Settings > Phh Treble Settings:
    • Qualcomm features / Use alternate audio policy
    • Misc features / Disable audio effects & Force Enable Cam2API HAL3.​
    • IMS features / Request IMS network & Force the presense of 4G calling. Also Install IMS Apk for Qualcomm vendor from notification panel.​
    NOTE: Reflash kernels only through your custom recovery. Updating through apps like FKM or SPKM is not suggested.

    OVERLAY​

    Skip this part, unless you have the following issues :
    • Brightness stack​
    • Status bar cut offs​
    • Missing battery usage stats​
    • Missing night light toggle​
    • Ambient light & doze​
    Extract this overlay into /product/overlay/ through any root explorer.
    NOTE: If there's no space available issue, remove these two folders /system_ext/apex/com.android.vndk.{v28/v29}, reboot & try again.

    EXTRAS​

    My Recommendations for great experience:
    • Lawnchair / Quickswitch for launcher customization with gesture navigation support.​
    • Lineage Dialer for built-in call recording (push into /product/priv-app/Dialer/Dialer.apk).​
    • ANXCam for MIUI camera's post processing.​
    • GCam for google camera's post processing.​
    • SPKM to set GPU on performance mode (GPU > GPU Governor > Performance)​
    • Aurora Store / Droid for microg users.​
    • Bromite (arm64_SystemWebView.apk) for uptodate android webview (& disable built-in android webview).​
    • Kiwi Browser for chrome extensions support.​
    • Migrate to backup & restore user apps & data, incase you lose your setup.​
    Thanks for reading all the way through here.
    4
    UPDATE: Overlay has been merged. No need of manual overlay injection for the upcoming phh based A13 GSIs.
    3
    it is okay for us to give review about the GSI that we have been tested ? or better on the other thread ? asking for an opinion here 😅
    I don't really care. Discuss anything mate. This thread is all about gsi support for community.
    The more you guys talk, the more better.
    (just dont private msg. I want all discussions to be public✌️)
    3
    Followed exactly as in OP.

    I did remove some apps tho from product app/priavpp and system app/privapp, so maybe that caused an issue? Is there anything related to fingerprint in those folders?
    If you want to gain more space (≈ 200mb) in system you can delete 2 folders safely without problems :
    /system/system_ext/apex/com.android.vndk.v28/
    and
    /system/system_ext/apex/com.android.vndk.v29/
    Already did it in DSSI builds without issues.
    2
    I have been using GSIs on my old Huawei P10 lite for almost 3 years, and it was a very good experience.
    Now with mojito I find myself lazy always using Roms -_- '
    Thanks for the guide!
    The only official dev for this device, who's actually from core development of a reputed project (PE), is Zid. There aren't any, as I do not find others to be helping from core (except couple of kernel devs).

    ROMs have no complete guarantees for future updates. Although you can use other project GSIs such as crD by Nazim, LOS by Andy, phhusson's the one who's consistently providing regular monthly updates with built-in OTA.