[Xiaomi 12 (Global)] raul16:
View attachment 5965391

LineageOS 20 is a free, community built, aftermarket firmware distribution of Android 13, which is designed to increase performance and reliability over stock Android for your device.

Disclaimer:

#include <std_disclaimer.h>

/*
* Your warranty is now void.
*
* We are not responsible for bricked devices, dead SD cards,
* thermonuclear war, or you getting fired because the alarm app failed. Please
* do some research if you have any concerns about features included in this ROM
* before flashing it! YOU are choosing to make these modifications, and if
* you point the finger at us for messing up your device, we will laugh at you.
*
*/

LineageOS is based on AOSP with contributions from many people within the Android community. It can be used without any need to have any Google application installed. LineageOS does still include various hardware-specific code, which is also slowly being open-sourced anyway.

The source code for LineageOS is available at GitHub. And if you would like to contribute to Lineage OS, please visit Gerrit Code Review. You can also view the Changelog for a full list of changes & features.

Instructions:

Warning: These instructions only work if you follow every section and step precisely. Do not continue after something fails!

Read through the instructions at least once before actually following them to avoid any problems due to any missed steps!

First install:

make a FULL backup first from your actual system and data;

before installing make sure you are running the latest Android 13 firmware for your region;

If your current installation is newer or older than Android 13, please upgrade or downgrade to the required version before proceeding (guides can be found on the internet!);

install on your computer latest adb and fastboot tools. Setup instructions can be found here;

enable USB debugging on your device;

Unlock the bootloader

Unlocking the bootloader will erase all data on your device (!) so re-enable USB debugging to continue;

Boot to fastboot (press Vol- & PWR simultaneously and keep until “FASTBOOT” appears) and install latest TWRP for cupid using your computer run the commands bellow in power shell:

fastboot flash recovery_ab recovery.img

Reboot to recovery by command:

fastboot reboot recovery

or by using Vol+ & PWR keys pressed simultaneously until MI logo appears;

as installing for the first time, you must do format /data (from wipe option);

reboot to recovery;

Copy the ROM zip file to the internal storage;

Install -> Select the ROM zip file;

Reboot to system;

Done;

Clean install:

download the latest ROM zip from the downloads section below;

do a factory reset in recovery;

install ROM zip;

format /data (from wipe option);

reboot to system and enjoy latest LineageOS 20 [Android 13] on your Xiaomi 12.

Notes:

do not flash GApps as already included in build;

if you do not enable (select) keep TWRP after install you will lose TWRP as it will be overwritten by Lineage recovery app !

if you want to use Lineage Recovery see this post for usage (how to).

Dirty flash/upgrade:

download the latest ROM zip from the downloads section below;

install ROM zip;

reboot to system;

Extra Features:

Passes SafetyNet by default

GApps included

Sensitive quick settings tiles require unlocking

Stock MIUI camera included

Burn-in protection

Blur enabled for quick settings & extended power

Three fingers swipe to screenshot

Downloads:

rom: LineageOS 20

recovery: TWRP

Reporting bugs:

Bug reports without a complete description of the issue and a logcat will be ignored!

DO NOT Report bugs if you're running a custom kernel or you installed Xposed

Grab a logcat right after the problem has occurred. (Please include at least a few pages of the log, not just the last few lines, unless you know what you're doing.)

If it is a random reboot, grab /sys/fs/pstore/console-ramoops and /sys/fs/pstore/dmesg-ramoops-0. (Do not bother getting a logcat unless you can get it just before the reboot. A logcat after a reboot is useless)

Credits:

@ArianK16a for initial DT, Kernel & support

LineageOS Team and contributors (extra features)

CodeLinaro

Xiaomi 12 contributors

GPL compliance: Kernel source

Contributors: raul16

Donations: if you like my work and want to support development or buy me a coffee PayPal Donate

ROM OS Version: Android 13.0.0_r75

ROM Kernel: Linux 5.10 GKI

ROM Firmware Required: V14.0.3.0.TLCMIXM / V14.0.7.0.TLCEUXM

Based On: LineageOS 20

Version Information

Status: Stable

Created on 2023-05-31

Last Updated 2023-12-16

Screeshots:

View attachment 5965439View attachment 5965441View attachment 5965449View attachment 5965451View attachment 5965453View attachment 5965455