If you're here it means you got Error 7 while flashing a CyanogenMod build, welcome! To use a newer CyanogenMod build on your device, you need to update some things in it. You deserve some explainations first: Before the Lollipop era, Xiaomi used to have some "duplicated" software (2 "system", "boot" and "modem" partitions to be specific) on their devices to prevent breakage during upgrades. During official MiUi MM upgrade Xiaomi removed those duplicated and updated modem and other things to a newer version that is build to work on Marshmallow. CyanogenMod supported Kitkat baseband / modem and partition layout for a while, but users with these had more issues than those who upgraded their devices to stock MM. So it's better for everyone to upgrade. Unfortunately these things cannot be updated with a simple CM ota, you need to update them "manually". If you want to follow the official Xiaomi tutorial to update to marshmallow "base", feel free to do it, but here you get a step-by-step easy tutorial that allows you to upgrade without having to wipe any of your data (except system partitions).
What do you need
- The device running CyanogenMod 13
- A pc
- This zip file - cm13Upgrade.zip
- CyanogenMod 13 zip and Gapps zip on the pc
- Fastboot drivers installed and configured *
How to upgrade - the cm way
Once you plug your device into the pc, make sure you never unplug it until everything is done, also if you have a laptop, make sure it has a stable power source to avoid breakage to your device.
- Turn your device off
- Boot your device into bootloader mode (Press "Vol Down" and "Power" at the same time for a few seconds)
- Plug it into your pc
- Unzip the cm13ParitionMerge.zip file
- Run flash_all.bat (on windows) or flash_all.sh (on OS x and Linux - it's suggested to open it from a terminal in these systems)
- The device will reboot itself a few times
- Once the upgrade ends the device will boot into recovery mode automatically
- Install the downloaded rom following this guide, you don't have to wipe your data. Make sure you flash GApps too if you want to use Google services
- Reboot and enjoy
- The pc does not recognize the device in fastboot mode (script stays on waiting for device): make sure you have enough permissions to run fastboot command and the fastboot driver is configured to work with your device.
- The device does not boot anymore after the upgrade, something went wrong because of odd reasons (THIS SHOULD NEVER HAPPEN): follow this tutorial to get your device back working (Unfortunately you'll loose your data this time).