[Xiaomi Redmi Note 4 [Snapdragon] ROMs, Kernels, Re] julio8888:
Install guide from scratch

Just got my Note 4X yesterday and had this up and running within hours. Many thanks to the ROM developers!

I thought I'd share my notes here for anyone else interested in getting this ROM up and running. Sorry if they're a bit vague, but I really don't understand the unlocking process.

My model is the 32GB/3GB SD625 version on Gearbest, I turned it on and approved the OTA MIUI 8.2.5.0 update as soon as I got it out of the box. I then went through the unlocking process of:

1. Make a Xiaomi Mi account

2. Log into that account on my phone, associating it with the account

3. Apply for unlock, which I received approval of within 15 minutes

4. Download the unlock program, tried it (reboot into fastboot, attach and...) that didn't work

5. Read that you might need to be on the developer MIUI ROM so tried to download that

6. Stress because it refused to install the one I got (the latest "developer ROM" available on the miui.com/download page for Redmi Note 4X)

7. Then I started mucking around looking at the developer options in the "hidden" menu only to find that actually the bootloader was listed as unlocked. So, I don't know if a) the phone came like that or b) Xiaomi somehow sent something to my phone unlocking the bootloader, but either way the unlock app on the PC got to 50% and "failed to verify phone" or something like this, and booting into the Power+Volume Up button thing which wants you to install the Mi PC Suite also gave me nothing (wouldn't even identify my device).

So I really don't know how I got the think unlocked, suffice to say I did in the end. Then, as a newbie to flashing a Redmi Note 4X with Lineage, I stumbled my way through the following:

1. Download the Google ADB platform-tools: https://developer.android.com/studio/releases/platform-tools.html (I did all of this on Windows), extract them somewhere

2. download twrp for mido, lazyflash from here:

https://xdaforums.com/redmi-note-4/...er-development/recovery-twrp-3-0-2-0-t3550061

3. download lineage image for mido, firmware, gapps (arm64, Android 7.1, stock for me but choose what you like, I probably would go fewer apps next time) from this thread (I didn't get the Lineage extras/addons, not sure what they are)

4. Attach the phone to the PC, make it available to copy files (USB MTP mode) copy all downloads (except twrp recovery.img) onto directory on phone (so lazyflasher, lineage ROM, mido firmware, gapps)

4a. Enable developer options (documented elsewhere but I think it's click on the kernel version in Settings->About Phone 7 times or so) and then enable USB debugging, I guess also double check the bootloader is unlocked

5. Launch a console in administrator mode (I use mobaxterm but whatever works for you, I found I had to run the following in a console with admin privileges on my PC) and CD into the platform-tools directory:

5a) command: ./adb.exe reboot bootloader

That'll reboot the phone into the fastboot thing with the dude wearing the Russian hat tinkering with his Android

5b) command: ./fastboot.exe flash recovery recovery.img

I think this somehow installs the TWRP app into the recovery partition, anyway now when you boot and do Power+Volume Up it'll go into the TWRP app not the stupid thing asking you to attach to your PC and go to pcsuite.mi.com or whatever

5c) command: ./fastboot.exe boot recovery.img

This will cause the phone to reboot into the TWRP app.

5d) in TWRP go Install-><browse to directory with all of the zip files>->lazflasher-no-verify-opt-encrypt.zip->Swipe to confirm Flash

At this stage I was a bit paranoid and had a look around the app but ultimately rebooted the phone to check the original MIUI ROM still worked, which it did. Phew.

When exiting TWRP it'll ask if you want to install the TWRP app, I never did

6. Then I soldiered on, rebooted into TWRP (Power+Volume Up instead of adb method), and got on with flashing the ROM.

I did not do a backup of the original ROM as it had nothing on there I really wanted. So my process of flashing was:

6a) (in TWRP) Wipe->Swipe to Factory Reset

6b) Install->cm-14.1-mido-firmware-20170430.zip

Add more Zips->lineage-14.1-20170430-UNOFFICIAL-mido.zip

Add more Zipz->open_gapps-arm64-7.1-stock-20170509.zip

Swipe to confirm Flash

At the end I cleared the dalvik cache and rebooted and hey presto, I'd gotten rid of the terrible MIUI and had a nice clean Android experience on an awesome value piece of hardware.

I hope that's helpful!

Again my thanks to the people who put this ROM together.