[ZTE Axon 7 Guides, News, & Discussion] otaconremo:
This is for Marshmallow B13. However, I can confirm that installing twrp using tenfars tool still works even on latest B17 nougat or B08 mifavor 5.

However, some users don't have luck with it.

I advise to check first on Axon Toolkit located here:

https://xdaforums.com/axon-7/development/tool-axon7toolkit-t3573108

I made this guide for users who haven't unlocked and rooted their A2017 B13 chinese version.

After reading so many guides here from [MENTION=540283]tenfar[/MENTION], [MENTION=3044858]DrakenFX[/MENTION], and many others, I finally unlocked bootloader, rooted, installed TWRP and Xposed.

I take no responsibility if anything happens to your phone while doing this process. Just follow every step stated here and hope you don't mess around. Please READ all the instructions here first before doing anything.

Backup all your important data before you do any steps below. This process will delete all contents of your phone except external sdcard.

Step 1: Download the zip file and extract all files to your local disk in one folder.

TWRP recovery 3.1.0-0

axon7root.zip

TWRP_UnlockBootloaderPackage_by_DrakenFX.zip do not extract this file.

Step 2: Enable USB debugging and OEM unlocking under Developer options. to show Developer options, go to Settings, About phone, tap Build Number 7x.

Step 3: Open Windows Explorer and browse to the folder where you extracted the files downloaded above. Press and hold SHIFT key then right click and choose Open Command Window here. type:

adb reboot edl

This will reboot the phone in edl mode where it's just black screen.

Step 4: Install the Qualcomm's driver .

Download Qualcomm driver to your local disk ,extract and install it

Qualcomm 9008 driver : http://d-h.st/35tx

in the install process choose WWAN, the first option.

Alternative: you could just also install the native drivers provided by the phone. If you have done step 2 already, just long press Power button for about 10seconds to reboot to its system. Once booted, connect your phone to your pc via usb and swipe down from the notification. Choose "install drivers" from the connect options. Open your Windows Explorer and find the new drive containing the driver. After installing, repeat step 3.

Step 5 : open your PC's device manager and find out the com port number which your phone is from COM ports & LPT tree.

Usage Example: axon7root.exe -p COM4 -b -r
Options:
-p Port number eg: COM8 or 8
-b write boot.img only
-r write recovery.img only
-d dump boot.img and recovery.img from phone(not impl yet)

Step 6: in the command window from step 3, type:

axon7backup.exe -p COM# -d

replace # with the number of your COM PORT.

This will save the backup files for you stock boot and recovery image.

Step 7: to install TWRP, type:

axon7root.exe -p COM# -r

Step 8: reboot to TWRP by holding POWER + UP buttons.

Optional:

Step 8a: Copy twrp-3.1.0-0-ailsa_ii.img to your sdcard/extsd. Update to latest TWRP. Install -> IMG (lower right button) -> choose twrp-3.1.0-0-ailsa_ii.img. (Don't reboot to system yet)

Step 8b: From the TWRP, find Reboot to recovery. verify that you have version 3.1.0-0 already.

Step 9: Copy TWRP_UnlockBootloaderPackage_by_DrakenFX.zip to your sdcard/extsd.

Step 10: Back-up and pull current fastboot image. Type:

adb shell dd if=/dev/block/bootdevice/by-name/fbop of=/sdcard/fbop_lock.img
adb pull /sdcard/fbop_lock.img

Step 11: Flash/Install TWRP_UnlockBootloaderPackage_by_DrakenFX.zip. (do not reboot yet)

Step 12: Type:

adb reboot bootloader

Step 13: Now let's Unlock the Bootloader. (THIS WILL WIPE DATA+INTERNAL STORAGE)

Type:

fastboot oem unlock

Confirm yes from your phone.

Step 14: You'll boot in TWRP. once there do the following:

* tap CANCEL
* tap WIPE
* tap FORMAT DATA and Follow the Instructions

Step 15: Once done, REBOOT system. Follow the setup wizard to gain access to your phone. enable USB debugging again.

Optional: To install root, Boot to recovery again and install/flash SUPERSU 2.79. download at UPDATE-SuperSU-v2.79-20161211114519.zip and copy to your sdcard.

To install Xposed (for MM only), flash xposed-v87-sdk23-arm64.zip and install the apk XposedInstaller_3.1.1.apk.

Do not REBOOT after installation of Supersu and Xposed. Instead, go to Terminal and type:

reboot disemmcwp

Credits to all the great minds here in xda for doing all their best.

UPDATE: TWRP flashable zips available. Credits to [MENTION=5382068]parazite69[/MENTION] and the russians for these.