[Moto E4 Guides, News, & Discussion] MotoJunkie01:
•••••• Qualcomm Moto E (4th Gen) Perry ••••••

Factory Firmware & Flashing/Restoration Guide

MetroPCS / T-Mobile Moto E4 (XT1765)

OVERVIEW:

This guide provides factory firmware for both the MetroPCS and T-Mobile branded variants of the Moto E4 Perry (xt1765). While these two packages appear to be similar and multi-compatible, I do not own the xt1765 and cannot confirm this. So, to be safe, use only the firmware package for your branded carrier. This guide can be used to repair a device which is buggy, unstable, or stuck in a boot loop. Likewise, device owners wishing to restore their device to an unmodified, stock factory state will also find this guide beneficial. Installing this firmware will remove any custom mods from your device, such as root binaries, BusyBox binaries, Xposed framework, etc. Also, force encryption and verified boot (dm-verity/avb) will be enabled. If you have TWRP custom recovery installed, it will be replaced by the stock recovery image.

DISCLAIMER:

You are using this guide and flashing firmware to your device solely at your own risk. While these firmwares have been tested and confirmed to work on their respective variants, by proceeding further, you are absolving me of any liability or responsibility in the event you brick your device or otherwise render it inoperable. Follow the simple instructions carefully and things should go smoothly.

SPECIFICATIONS:

••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••

•MetroPCS Moto E4 (xt1765) Perry

•Android Version: 7.1.1 Nougat

•Build No. NCQS26.69-64-3

•System Version: 26.261.9.perry_metropcs.en.US

•Radio Version: M8917TMO_18.08.04.18R

•Security Patch Level: March 1, 2018

•Kernel Version: Linux 3.18.31-perf

•Build Date: March 16, 2018

•Firmware Package Size: 1.36 GB

•Download Link: https://drive.google.com/file/d/17sJS8VpxSAHupqiqJQQb4wa1jHIP61uT/view?usp=drivesdk

•••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••

•••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••

•T-Mobile Moto E4 (xt1765) Perry

•Android Version: 7.1.1 Nougat

•Build No. NCQS26.69-64-6

•System Version: 26.271.7.perry_tmo.tmo.en.US

•Radio Version: M8917TMO_18.08.04.18.01R

•Security Patch Level: May 1, 2018

•Kernel Version: Linux 3.18.31-perf

•Build Date: May 2, 2018

•Firmware Package Size: 1.33 GB

•Download Link: https://drive.google.com/file/d/1C21fgdBVn6hhPtAo5yult-PdB6DSr4HS/view?usp=drivesdk

•••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••

REQUIREMENTS:

This guide assumes that you have the latest version of the Minimal ADB & Fastboot utilities installed on your PC or laptop. If you do not, you can download the latest version, v1.4.3, from this MediaFire link: http://www.mediafire.com/file/ccnnv843a20tqbn/minimal_adb_fastboot_v1.4.3.zip It is also a good idea to have at least a rudimentary understanding of fastboot command line execution. There are some excellent guides here on XDA which outline the subjects of fastboot mode & fastboot commands.

In addition, to ensure that up-to-date USB device drivers are installed on your PC, download & install the latest Motorola Device Manager. You can get the latest version directly from this Motorola support link: https://motorola-global-en-aus.custhelp.com/app/answers/prod_detail/a_id/86934/p/154,4222

NOTE:

Because these are factory firmware packages, in theory, xt1765 owners should be able to flash these packages, using the below instructions, to devices with a locked bootloader. Please note, however, that these firmwares were leaked by the manufacturer and may or may not be digitally signed by the OEM. In sum, I cannot confirm whether these firmwares will flash to a locked bootloader device. I can only confirm that the firmware will install normally on a device with an unlocked bootloader. As confirmation becomes available from other members in this regard, I will add the info to this thread.

On a second note, flashing this factory firmware does not re-lock an already unlocked bootloader. Also, contrary to popular misbelief, re-locking your bootloader IS NOT required in order for your device to be able to install OTA update packages. To enable your device to install OTA updates, you need only install the firmware package for your variant using the below instructions.

WARNING: The below instructions include a command for wiping your /userdata partition (fastboot erase userdata) which will effectively wipe all of your saved files, photos, videos, app data and other media. This is recommended for a clean install of the firmware, and to ensure optimal results. However, if you are stuck in a boot loop, for example, and have important files saved to internal storage that you want to try and salvage, simply skip over the "fastboot erase userdata" command and give it a try.

INSTRUCTIONS:

• 1. Download the firmware package for your branded carrier on your PC or laptop. Extract the contents of the package to your ADB/Fastboot directory;

• 2. Boot your device into fastboot mode and connect your device to your PC with the OEM or a quality equivalent micro USB to USB sync cable;

• 3. Open a command window in the path of your ADB/Fastboot directory and execute:

fastboot devices

If your device and PC are properly connected, the command window will return an alphanumeric value synonymous of your device serial number;

• 4. Once a proper connection has been established, execute the following commands, preferably in this order:

fastboot oem fb_mode_set

fastboot flash partition gpt.bin

fastboot flash bootloader bootloader.img

fastboot flash modem NON-HLOS.bin

fastboot flash fsg fsg.mbn

fastboot erase modemst1

fastboot erase modemst2

fastboot flash dsp adspso.bin

fastboot flash logo logo.bin

fastboot flash boot boot.img

fastboot flash recovery recovery.img

fastboot flash system system.img_sparsechunk.0

fastboot flash system system.img_sparsechunk.1

fastboot flash system system.img_sparsechunk.2

fastboot flash system system.img_sparsechunk.3

fastboot flash system system.img_sparsechunk.4

fastboot flash oem oem.img

fastboot erase userdata

fastboot erase cache

fastboot erase DDR

fastboot oem fb_mode_clear

Done. Now execute:

fastboot reboot

Upon reboot, your device should be restored to unmodified stock condition, and your device will be capable of installing pending or future OTA update packages.