Out of the box, your Xiaomi Redmi 4X codenamed:santoni comes out of the box with Android 6.0.1 (Marshmallow), upgradable to 7.1.2 (Nougat); MIUI 10 with no option to use an SD card as additional internal storage. You can put your pictures, videos and other files but you cannot install those gigabits of mobile games into it! So with the release of android 8 and 9 you can now use your SD card as if it's an internal storage.
In this tutorial I will guide you in installing Lineage OS that is based on Android 8 Oreo.
Before you can install a custom ROM on your Xiaomi Redmi 4x the device's bootloader should be unlocked, if not then follow this;
The following instructions below are from https://wiki.lineageos.org/adb_fastboot_guide.html
I intentionally changed the path so it would be much easier.
Installing
Popular
Setting up
Installing a custom recovery using
In this tutorial I will guide you in installing Lineage OS that is based on Android 8 Oreo.
Before you can install a custom ROM on your Xiaomi Redmi 4x the device's bootloader should be unlocked, if not then follow this;
Unlocking the bootloader
NOTE: The steps below only need to be run once per device.
WARNING: Unlocking the bootloader will erase all data on your device! Before proceeding, ensure the data you would like to retain is backed up to your PC and/or your Google account, or equivalent.
- Visit Xiaomi’s official unlocking website and apply for unlocking permissions. (I just tole them I want to install Oreo on my phone)
- Wait until you get the approval, which may take some days. (Mine took just an hour)
- At the same time, link the device to your Mi account in
Settings
>Additional settings
>Developer options
>Mi Unlock status
. This step is mandatory and will trigger a countdown of 360 hours, the waiting period before a device can be unlocked. - Once you get the approval, visit the website again and you will be redirected to the Mi Unlock app download page.
- Download the Mi Unlock app (Windows is required to run the app).
- Once the 360 hours waiting period is over, run the Mi Unlock app and follow the instructions provided by the app.
- After device and Mi account are successfully verified, the bootloader should be unlocked.
- Since the device resets completely, you will need to re-enable USB debugging to continue.
TIP: A Mi account is required to apply for permissions. You don’t need to re-apply for permissions to unlock new devices, but beware that one account is only allowed to unlock one unique device every 30 days.
TIP: It is highly recommended to have the latest official MIUI dev package installed on the device, before proceeding with unlock.
What we need:
If this is your first time installing this then you need to download and install (adb) and Fastboot. ADB or android debug bridge is like the driver so your phone would be recognized by the computer while fastboot is like the bios where you would be sideloading the ROM.The following instructions below are from https://wiki.lineageos.org/adb_fastboot_guide.html
I intentionally changed the path so it would be much easier.
Installing adb
and fastboot
Google hosts zips including only
adb
and fastboot
. You can set these up for use with the instructions below.On Windows
- Download the Windows zip from Google.
- Extract it somewhere - for example,
c:\Xiaomi\ad-fastboot
- On Windows 7/8:
- From the desktop, right-click My Computer and select Properties
- In the System Properties window, click on the Advanced tab
- In the Advanced section, click the Environment Variables button
- In the Environment Variables window, highlight the Path variable in the Systems Variable section and click the Edit button
- Append c:\Xiaomi\ad-fastboot to the end of the existing Path definition (the semi-colon separates each path entry)
- On Windows 10:
- Open the Start menu, and type “advanced system settings”
- Select “View advanced system settings”
- Click on the Advanced tab
- Open the “Environment Variables” window
- Select the Path variable under “System Variables” and click the “Edit” button
- Click the “Edit Text” button
- Append c:\Xiaomi\ad-fastboot to the end of the existing Path definition (the semi-colon separates each path entry)
- Install the universal adb driver, and reboot.
On macOS
- Download the macOS zip from Google.
- Extract it somewhere - for example,
~/adb-fastboot
. - Add the following to
~/.bash_profile
:if [ -d "$HOME/adb-fastboot/platform-tools" ] ; then export PATH="$HOME/adb-fastboot/platform-tools:$PATH" fi
- Log out and back in.
On Linux
- Download the Linux zip from Google.
- Extract it somewhere - for example,
~/adb-fastboot
. - Add the following to
~/.profile
:if [ -d "$HOME/adb-fastboot/platform-tools" ] ; then export PATH="$HOME/adb-fastboot/platform-tools:$PATH" fi
- Log out and back in.
- You may also need to set up udev rules: see this repository for more info.
Popular adb
commands
adb shell
- launches a shell on the deviceadb push
- pushes the file
toadb pull
- pulls the file[ ]
to
. If
isn’t specified, it will pull to the current folder.adb logcat
- allows you to view the device log in real-time. You can useadb logcat -b radio
to view radio logs, andadb logcat -C
to view logs in colouradb install
- installs the given .apk file to your device
Preparing the phone
Enable USB Debugging on your phone.
To use
adb
with your device, you’ll need to enable developer options and USB debugging:- Open Settings, and select “About”.
- Tap on “Build number” seven times.
- Go back, and select “Developer options”.
- Scroll down, and check the “Android debugging” entry under “Debugging”.
- Plug your device into your computer.
- On the computer, open up a terminal/command prompt and type
adb devices
. - A dialog should show on your device, asking you to allow usb debugging. Check “always allow”, and choose “OK”.
Congratulations!
adb
is now ready to use with your device.
Setting up fastboot
Using
fastboot
(if your device supports it) should simply involve rebooting to fastboot mode. While in fastboot mode, you can type fastboot devices
to verify that your device is being detected.
Installing a custom recovery using fastboot
- Download a custom recovery - you can download TWRP. Simply download the latest recovery file, named something like
twrp-x.x.x-x-santoni.img
. and put it in your c:\Xiaomi folder - Connect your device to your PC via USB.
- On the computer, open a command prompt (on Windows) or terminal (on Linux or macOS) window, and type:
adb reboot bootloader
You can also boot into fastboot mode via a key combination:- With the device powered off, hold Volume Down + Power. Keep holding both buttons until the word “FASTBOOT” appears on the screen, then release.
- Once the device is in fastboot mode, verify your PC finds it by typing:
fastboot devices
fastboot flash recovery twrp-x.x.x-x-santoni.img
TIP: The file may not be named identically to what stands in this command, so adjust accordingly.- Now reboot into recovery to verify the installation:
- With the device powered off, hold Volume Up + Volume Down + Power.
Installing LineageOS from recovery
- Download the LineageOS install package that you’d like to install or build the package yourself.
- Optionally, download additional application packages such as Google Apps (use the
arm64
architecture). I personally used Pico as the variant and put the files in your c:\Xiaomi folder.
- Optionally, download additional application packages such as Google Apps (use the
- If your device isn’t already booted into recovery, do so:
- With the device powered off, hold Volume Up + Volume Down + Power.
- (Optional, but recommended): Tap the Backup button to create a backup. Make sure the backup is created in the external sd card or copy it onto your computer as the internal storage will be formatted later in this process.
- Go back to return to the main menu, then tap Wipe.
- Now tap Format Data and continue with the formatting process. This will remove encryption as well as delete all files stored on the internal storage.
- Return to the previous menu and tap Advanced Wipe.
- Select the Cache and System partitions to be wiped and then Swipe to Wipe.
- Sideload the LineageOS
.zip
package:- On the device, select “Advanced”, “ADB Sideload”, then swipe to begin sideload.
- On the host machine, sideload the package using:
adb sideload filename.zip
- (Optional): Install any additional packages using the same method.
- (Optional): Root the device by installing the LineageOS SU Addon (use the
arm64
package) or using any other method you prefer. - Once the installation has finished, return to the main menu, tap Reboot, and then System.
Instructions are copied and edited from https://wiki.lineageos.org/devices/santoni/install
Comments
Post a Comment