[Share] Unbricked your phone without SP Flash tool - Redmi Note 8 Pro Guides, News, & Discussion

hello just sharing and for my reference also
last sept 25 i bricked my phone totally . all partitions broke, and try to use the SP Flash tool with bypass but unfortunately i don't know why bypass tool doesn't work on my phone
so i search a lot on google and ask some help and then i found MTK Client Tool
its a small tool with bugs below
[It can't flash preloader]
yes you can flash the preloader using the tool but it will not boot your phone
the method below is the actual steps i had done , my phone is Redmi note 8 pro Begonia Global , you can improvise it to make it easier ,
What you need
1. python
2. Windows/ Mac or Linux
3. MTK client tool you can download it here https://github.com/bkerler/mtkclient
4. Stock rom , any stock rom (fastboot version)
5. adb/fastboot tool
follow the instruction on the github how to install it
1. assuming you have the stockrom files , go to the firmware/images folder and create a file (mtkflash.bat)
2. paste below
set command=python3 C:\path\of\mtkclient\mtk
echo 'flashing recovery'
%command% wo 0x8000 0x4000000 recovery.img
echo 'flashing vbmeta'
%command% wo 0x5988000 0x800000 vbmeta.img
echo 'flashing md1'
%command% wo 0x1b580000 0x9600000 md1img.img
echo 'flashing spmfw'
%command% wo 0x26580000 0x100000 spmfw.img
echo 'flashing audio_dsp'
%command% wo 0x26680000 0x400000 audio_dsp.img
echo 'flashing scp'
%command% wo 0x26a80000 0x600000 scp.img
%command%wo 0x27080000 0x600000 scp.img
echo 'flashing sspm'
%command% wo 0x27680000 0x100000 sspm.img
%command% wo 0x27780000 0x100000 sspm.img
echo 'flashing cam vpus'
%command% wo 0x27880000 0xf00000 cam_vpu1.img
%command% wo 0x28780000 0xf00000 cam_vpu2.img
%command% wo 0x29680000 0xf00000 cam_vpu3.img
echo 'flashing gzs'
%command% wo 0x2a580000 0x2000000 gz.img
%command% wo 0x2c580000 0x2000000 gz.img
echo 'flashing lks'
%command% wo 0x2e580000 0x200000 lk.img
%command% wo 0x2e780000 0x200000 lk.img
echo 'flashing boot'
%command% wo 0x2e980000 0x4000000 boot.img
echo 'flashing logo'
%command% wo 0x32980000 0x4000000 logo.bin
echo 'flashing dtbo'
%command% wo 0x36980000 0x2000000 dtbo.img
echo 'flashing tees'
%command% wo 0x38980000 0x500000 tee.img
%command% wo 0x38e80000 0x500000 tee.img
echo 'flashing vendor'
%command% wo 0x39800000 0x60000000 vendor.img
echo 'flashing system'
%command% wo 0x99800000 0xe0000000 system.img
echo 'flashing caches'
%command% wo 0x179800000 0x1b000000 cache.img
echo 'flashing gsort'
%command% wo 0x194800000 0x1000000 gsort.img
echo "flashing oems"
%command% wo 0x195800000 0x1000000 oem_misc1.img
echo "flashing exaid"
%command% wo 0x196800000 0x8000000 exaid.img
echo "flashing cust"
%command% wo 0x19e800000 0x34000000 cust.img
echo "flashing userdata"
%command% wo 0x1d2800000 0x300000000 userdata.img
Click to expand...
Click to collapse
3. then disconnect your phone if you already connected it
4. run the bat file from the cmd or just by clicking it
5. now it will wait for your phone to connect , hold vol up+ vol down + power on and connect it to your laptop/pc , don't release until flashing start
6. it will take few hours to finish it so take a cup of coffee
7. once done , the phone will still not boot (see the note for the bugs above)
8. still on the cmd disconnect the phone again and run this python mtk plstage --preloader=/path/of/your/stock/rom/preloader_begonia.bin
9. repeat step 5
10. once finish the phone will temporary boot , setup your redmi note 8 pro as usual
11. once setup complete go to settings and activate developer option
12. on the cmd run adb reboot fastboot / adb reboot bootloader
13. the phone will not turn on , don't worry repeat step 8
14. it will now boot to your fastboot
15. flash the preloader using fastboot , fastboot flash preloader /path/of/your/stock/rom/preloader_begonia.bin
16. once done , reboot and you will see that the phone will now boot :3
Credits to owner of mtkclient
Edit:
i forgot to mention , be aware on those android sparse file , mtkclient supports only a raw image file not android sparse file , you can flash android sparse file anyway but it will not boot your android .
you need first convert those sparse file to raw image file it can be done by linux /mac os(macport)/windows(WSL)
using simg2img command , once done you can reflash
Btw , if you had bricked your phone during flashing custom rom using twrp , custom rom contains only some of firmware files , boot , dbto , recovery , vendor , vbmeta and system , so you can flash those affected partition , using the command above , just copy and paste the line that you need to flash and then volla , your phone boots and recovered lucky if you have your backup rom , you just need to flash affected files with your backup file .
Wait for my simple tool to make this easier :3 and will work on other MTK phones ^^

it says python was not found; run without arguments to install from the Microsoft Store, or disable this shortcut from Settings > Manage App Execution Aliases but i added it to PATH

Enderboy986 said:
it says python was not found; run without arguments to install from the Microsoft Store, or disable this shortcut from Settings > Manage App Execution Aliases but i added it to PATH
Click to expand...
Click to collapse
Use some alternative tools. It's more easier to use than python one

Related

Issues with Twrp, gapps, magisk

What I do with that mess ?
fastboot -w
fastboot flash dtbo dtbo.img
fastboot boot twrp.img
TWRP work
fastboot -w
fastboot flash dtbo dtbo.img
fastboot flash rom.img
fastboot boot twrp.img
TWRP work
fastboot -w
fastboot flash dtbo dtbo.img
fastboot flash rom.img
Start rom to enable usb debugging for twrp adb push
fastboot boot twrp.img
TWRP don't work
No sd card around so I aim to use Twrp to add Gapps and Magisk mostly
Google play store won't download even if in custom rom
Magisk manager worked but Magisk can't be added
Various little errors :
(bootloader) is-logical:logo_b: not found
(bootloader) is-logical:boot_b: not found
(bootloader) Image signed with key bad key
(bootloader) is-logical:recovery: not found
(bootloader) Invalid partition name recovery
FAILED (remote: '')
fastboot: error: Command failed
Erase successful, but not automatically formatting.
File system type raw not supported.
(bootloader) Permission denied
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:dtbo_b: not found
...

Moto G8 play boot loop

Hi
my moto g8 (xt2015-2) went into boot looping after I tried to root using this tutorial:
https://www.getdroidtips.com/root-moto-g8-play/
I have already made several attempts to install several roms stocks, like these:
https://www.stockrom.net/2020/04/xt2015-2-pie-retail-latam-pmd29-70-81.html
https://mirrors.lolinet.com/firmware/moto/lima_32/official/RETAIL/
I used adb flash tools as the method in flashfile.xml inside the rom.
my device:
(bootloader) version: 0.5
(bootloader) version-bootloader: MBM-2.1-lima_32_retail-dd9cedf-190906
(bootloader) product: lima
(bootloader) board: lima
(bootloader) secure: yes
(bootloader) hwrev: PVT
(bootloader) radio: 2
(bootloader) storage-type: eMMC
(bootloader) emmc: 32GB SAMSUNG 4X6KMB RV=08 PV=00 FV=0000000000000003
(bootloader) ram: 2GB SAMSUNG LP4x DIE=16Gb M5=01 M6=07 M7=00 M8=12
(bootloader) cpu: MT6771V/WL
(bootloader) serialno: ZF522784QB
(bootloader) cid: 0x0032
(bootloader) channelid: 0x19
(bootloader) uid: 32AA9F6547C0BDE1000000000000
(bootloader) securestate: flashing_unlocked
(bootloader) factory-modes: disabled
(bootloader) iswarrantyvoid: yes
(bootloader) max-download-size: 268435456
(bootloader) reason: Volume down key pressed
(bootloader) meid:
(bootloader) date: 11-13-2019
(bootloader) sku: XT2015-2
(bootloader) carrier_sku: XT2015-2
(bootloader) battid: SB18C55376
(bootloader) iccid:
(bootloader) max-sparse-size: 268435456
(bootloader) current-time: "Wed Jan 2 3:10:57 UTC 2019"
(bootloader) ro.build.fingerprint[0]: motorola/lima_32/lima:9/PMDS29.70-
(bootloader) ro.build.fingerprint[1]: 70-2/ac5451:user/release-keys
(bootloader) poweroffalarm: 0
(bootloader) ro.build.version.full[0]: Blur_Version.29.251.2.lima_32.ret
(bootloader) ro.build.version.full[1]: ail.en.US
(bootloader) ro.build.version.mtk: alps-mp-p0.mp1.tc2sp-V1.47
(bootloader) version-baseband: MT6771_V16.03.01.88R
(bootloader) kernel.version[0]: Linux version 4.4.146+ ([email protected]
(bootloader) kernel.version[1]: 55) (gcc version 4.9.x 20150123 (prerele
(bootloader) kernel.version[2]: ase) (GCC) ) #1 SMP PREEMPT Thu Dec 26 1
(bootloader) kernel.version[3]: 0:20:37 CST 2019
(bootloader) frp-state: no protection (77)
(bootloader) ro.carrier: retbr
(bootloader) current-slot: b
(bootloader) running-boot-lun: 0
(bootloader) running-slot: _b
(bootloader) slot-successful:_a: no
(bootloader) slot-successful:_b: yes
(bootloader) slot-bootable:_a: no
(bootloader) slot-bootable:_b: yes
(bootloader) slot-retry-count:_a: 0
(bootloader) slot-retry-count:_b: 0
(bootloader) slot-suffixes: _a,_b
(bootloader) slot-count: 2
(bootloader) pcb-part-no: SB28C70602
all: listed above
finished. total time: 0.007s
Click to expand...
Click to collapse
adrianosk8 said:
Hi
my moto g8 (xt2015-2) went into boot looping after I tried to root using this tutorial:
https://www.getdroidtips.com/root-moto-g8-play/
I have already made several attempts to install several roms stocks, like these:
https://www.stockrom.net/2020/04/xt2015-2-pie-retail-latam-pmd29-70-81.html
https://mirrors.lolinet.com/firmware/moto/lima_32/official/RETAIL/
I used adb flash tools as the method in flashfile.xml inside the rom.
my device:
Click to expand...
Click to collapse
You should be using
https://mirrors.lolinet.com/firmware/moto/lima_32/official/RETBR/
Sent from my ali using XDA Labs
sd_shadow said:
You should be using
https://mirrors.lolinet.com/firmware/moto/lima_32/official/RETBR/
Click to expand...
Click to collapse
I already installed all these RETBR roms. None started. when the Motorola logo appears, the device restarts.
I was searching the net and I found some articles saying that it could be because the processor is MIDIATEK (MT6771V / WL). AND THAT WOULD HAVE TO DOWNLOAD MTK / Sp flashing tools:
https://flashtool.org/5/download-sp-flash-tool.html
to install the rom on devices with this processor.
then I installed this program, but it needs the rom to have a file called "mt6771-scatter- android-file.txt "- what my device's roms don't have.
So I found a program that would generate this file (mt6xxx -scatter-android-file.txt):
https://mega.nz/file/YAogUAAL#cAbYxrWcUODmyVLD6p2Oz-YTsxm9Fb61A0RUq6OmkYI
but as nothing is so easy in this life, the program does not identify my device. not even after I installed the MidiaTek drivers (MTK drivers):
I don't know what to do.
I managed to solve it!
The problem is that the system image is divided into 7 or 8 different files. And when you run the "flash" command it also deletes the previous file so you have to use the "-u" parameters right after the "flash". Only for system images and after the first part of the images. Code below. I hope it helps you.
fastboot flash gpt PGPT
fastboot flash preloader preloader.bin
fastboot flash lk_a lk.img
fastboot flash tee_a tee.img
fastboot flash md1img_a md1img.img
fastboot flash spmfw_a spmfw.img
fastboot flash scp_a scp.img
fastboot flash sspm_a sspm.img
fastboot flash cam_vpu1_a cam_vpu1.img
fastboot flash cam_vpu2_a cam_vpu2.img
fastboot flash cam_vpu3_a cam_vpu3.img
fastboot flash vbmeta_a vbmeta.img
fastboot flash oem_a oem.img
fastboot flash logo_a logo.bin
fastboot flash boot_a boot.img
fastboot flash dtb_a dtb.img
fastboot flash dtbo_a dtbo.img
fastboot flash system_a system.img_sparsechunk.0
fastboot flash -u system_a system.img_sparsechunk.1
fastboot flash -u system_a system.img_sparsechunk.2
fastboot flash -u system_a system.img_sparsechunk.3
fastboot flash -u system_a system.img_sparsechunk.4
fastboot flash -u system_a system.img_sparsechunk.5
fastboot flash -u system_a system.img_sparsechunk.6
fastboot flash -u system_a system.img_sparsechunk.7
fastboot flash -u system_a system.img_sparsechunk.8
fastboot flash system_b system_other.img_sparsechunk.0
fastboot flash -u system_b system_other.img_sparsechunk.1
fastboot flash vendor_a vendor.img
fastboot reboot
adrianosk8 said:
I managed to solve it!
The problem is that the system image is divided into 7 or 8 different files. And when you run the "flash" command it also deletes the previous file so you have to use the "-u" parameters right after the "flash". Only for system images and after the first part of the images. Code below. I hope it helps you.
fastboot flash gpt PGPT
fastboot flash preloader preloader.bin
fastboot flash lk_a lk.img
fastboot flash tee_a tee.img
fastboot flash md1img_a md1img.img
fastboot flash spmfw_a spmfw.img
fastboot flash scp_a scp.img
fastboot flash sspm_a sspm.img
fastboot flash cam_vpu1_a cam_vpu1.img
fastboot flash cam_vpu2_a cam_vpu2.img
fastboot flash cam_vpu3_a cam_vpu3.img
fastboot flash vbmeta_a vbmeta.img
fastboot flash oem_a oem.img
fastboot flash logo_a logo.bin
fastboot flash boot_a boot.img
fastboot flash dtb_a dtb.img
fastboot flash dtbo_a dtbo.img
fastboot flash system_a system.img_sparsechunk.0 fastboot flash -u system_a system.img_sparsechunk.1 fastboot flash -u system_a system.img_sparsechunk.2 fastboot flash -u system_a system.img_sparsechunk.3 fastboot flash -u system_a system.img_sparsechunk.4 fastboot flash -u system_a system.img_sparsechunk.5 fastboot flash -u system_a system.img_sparsechunk.6 fastboot flash -u system_a system.img_sparsechunk.7 fastboot flash -u system_a system.img_sparsechunk.8 fastboot flash system_b system_other.img_sparsechunk.0 fastboot flash -u system_b system_other.img_sparsechunk.1
fastboot flash vendor_a vendor.img
fastboot reboot
Click to expand...
Click to collapse
did it work? and could you install magisk after that?
Matiasfh01 said:
did it work? and could you install magisk after that?
Click to expand...
Click to collapse
Yes, It does. But i don't install the magisk after that because i don't want It happend the same error.
adrianosk8 said:
Yes, It does. But i don't install the magisk after that because i don't want It happend the same error.
Click to expand...
Click to collapse
can u poste the final flashfile here pls
Matiasfh01 said:
can u poste the final flashfile here pls
Click to expand...
Click to collapse
fastboot flash gpt PGPT
fastboot flash preloader preloader.bin
fastboot flash lk_a lk.img
fastboot flash tee_a tee.img
fastboot flash md1img_a md1img.img
fastboot flash spmfw_a spmfw.img
fastboot flash scp_a scp.img
fastboot flash sspm_a sspm.img
fastboot flash cam_vpu1_a cam_vpu1.img
fastboot flash cam_vpu2_a cam_vpu2.img
fastboot flash cam_vpu3_a cam_vpu3.img
fastboot flash vbmeta_a vbmeta.img
fastboot flash oem_a oem.img
fastboot flash logo_a logo.bin
fastboot flash boot_a boot.img
fastboot flash dtb_a dtb.img
fastboot flash dtbo_a dtbo.img
fastboot flash system_a system.img_sparsechunk.0
fastboot flash -u system_a system.img_sparsechunk.1
fastboot flash -u system_a system.img_sparsechunk.2
fastboot flash -u system_a system.img_sparsechunk.3
fastboot flash -u system_a system.img_sparsechunk.4
fastboot flash -u system_a system.img_sparsechunk.5
fastboot flash -u system_a system.img_sparsechunk.6
fastboot flash -u system_a system.img_sparsechunk.7
fastboot flash -u system_a system.img_sparsechunk.8
fastboot flash system_b system_other.img_sparsechunk.0
fastboot flash -u system_b system_other.img_sparsechunk.1
fastboot flash vendor_a vendor.img
fastboot reboot
Watter flash het u gebruik?
adrianosk8 said:
fastboot flash gpt PGPT
fastboot flash preloader preloader.bin
fastboot flash lk_a lk.img
fastboot flash tee_a tee.img
fastboot flash md1img_a md1img.img
fastboot flash spmfw_a spmfw.img
fastboot flash scp_a scp.img
fastboot flash sspm_a sspm.img
fastboot flash cam_vpu1_a cam_vpu1.img
fastboot flash cam_vpu2_a cam_vpu2.img
fastboot flash cam_vpu3_a cam_vpu3.img
fastboot flash vbmeta_a vbmeta.img
fastboot flash oem_a oem.img
fastboot flash logo_a logo.bin
fastboot flash boot_a boot.img
fastboot flash dtb_a dtb.img
fastboot flash dtbo_a dtbo.img
fastboot flash system_a system.img_sparsechunk.0
fastboot flash -u system_a system.img_sparsechunk.1
fastboot flash -u system_a system.img_sparsechunk.2
fastboot flash -u system_a system.img_sparsechunk.3
fastboot flash -u system_a system.img_sparsechunk.4
fastboot flash -u system_a system.img_sparsechunk.5
fastboot flash -u system_a system.img_sparsechunk.6
fastboot flash -u system_a system.img_sparsechunk.7
fastboot flash -u system_a system.img_sparsechunk.8
fastboot flash system_b system_other.img_sparsechunk.0
fastboot flash -u system_b system_other.img_sparsechunk.1
fastboot flash vendor_a vendor.img
fastboot reboot
Click to expand...
Click to collapse
i need the firmware i use to fix the xt2015-2 please brother I could not solve
I could not solve
adrianosk8 said:
I managed to solve it!
The problem is that the system image is divided into 7 or 8 different files. And when you run the "flash" command it also deletes the previous file so you have to use the "-u" parameters right after the "flash". Only for system images and after the first part of the images. Code below. I hope it helps you.
fastboot flash gpt PGPT
fastboot flash preloader preloader.bin
fastboot flash lk_a lk.img
fastboot flash tee_a tee.img
fastboot flash md1img_a md1img.img
fastboot flash spmfw_a spmfw.img
fastboot flash scp_a scp.img
fastboot flash sspm_a sspm.img
fastboot flash cam_vpu1_a cam_vpu1.img
fastboot flash cam_vpu2_a cam_vpu2.img
fastboot flash cam_vpu3_a cam_vpu3.img
fastboot flash vbmeta_a vbmeta.img
fastboot flash oem_a oem.img
fastboot flash logo_a logo.bin
fastboot flash boot_a boot.img
fastboot flash dtb_a dtb.img
fastboot flash dtbo_a dtbo.img
fastboot flash system_a system.img_sparsechunk.0
fastboot flash -u system_a system.img_sparsechunk.1
fastboot flash -u system_a system.img_sparsechunk.2
fastboot flash -u system_a system.img_sparsechunk.3
fastboot flash -u system_a system.img_sparsechunk.4
fastboot flash -u system_a system.img_sparsechunk.5
fastboot flash -u system_a system.img_sparsechunk.6
fastboot flash -u system_a system.img_sparsechunk.7
fastboot flash -u system_a system.img_sparsechunk.8
fastboot flash system_b system_other.img_sparsechunk.0
fastboot flash -u system_b system_other.img_sparsechunk.1
fastboot flash vendor_a vendor.img
fastboot reboot
Click to expand...
Click to collapse
you have saved my phone Bro!
this works..
Does anyone have the controls for the moto g 8 xt2045-1 to flash the stock rom?
BrenoSilva1997 said:
Does anyone have the controls for the moto g 8 xt2045-1 to flash the stock rom?
Click to expand...
Click to collapse
You can use LMSA to flash g8 stock rom
adrianosk8 said:
I managed to solve it!
The problem is that the system image is divided into 7 or 8 different files. And when you run the "flash" command it also deletes the previous file so you have to use the "-u" parameters right after the "flash". Only for system images and after the first part of the images. Code below. I hope it helps you.
fastboot flash gpt PGPT
fastboot flash preloader preloader.bin
fastboot flash lk_a lk.img
fastboot flash tee_a tee.img
fastboot flash md1img_a md1img.img
fastboot flash spmfw_a spmfw.img
fastboot flash scp_a scp.img
fastboot flash sspm_a sspm.img
fastboot flash cam_vpu1_a cam_vpu1.img
fastboot flash cam_vpu2_a cam_vpu2.img
fastboot flash cam_vpu3_a cam_vpu3.img
fastboot flash vbmeta_a vbmeta.img
fastboot flash oem_a oem.img
fastboot flash logo_a logo.bin
fastboot flash boot_a boot.img
fastboot flash dtb_a dtb.img
fastboot flash dtbo_a dtbo.img
fastboot flash system_a system.img_sparsechunk.0
fastboot flash -u system_a system.img_sparsechunk.1
fastboot flash -u system_a system.img_sparsechunk.2
fastboot flash -u system_a system.img_sparsechunk.3
fastboot flash -u system_a system.img_sparsechunk.4
fastboot flash -u system_a system.img_sparsechunk.5
fastboot flash -u system_a system.img_sparsechunk.6
fastboot flash -u system_a system.img_sparsechunk.7
fastboot flash -u system_a system.img_sparsechunk.8
fastboot flash system_b system_other.img_sparsechunk.0
fastboot flash -u system_b system_other.img_sparsechunk.1
fastboot flash vendor_a vendor.img
fastboot reboot
Click to expand...
Click to collapse
hello, I know this is more than I year old but still I wanted to thank you for posting this solution, I was having a really hard time trying to fix my mom's phone and just with this all got solved, thank you
adrianosk8 said:
fastboot flash gpt PGPT
fastboot flash preloader preloader.bin
fastboot flash lk_a lk.img
fastboot flash tee_a tee.img
fastboot flash md1img_a md1img.img
fastboot flash spmfw_a spmfw.img
fastboot flash scp_a scp.img
fastboot flash sspm_a sspm.img
fastboot flash cam_vpu1_a cam_vpu1.img
fastboot flash cam_vpu2_a cam_vpu2.img
fastboot flash cam_vpu3_a cam_vpu3.img
fastboot flash vbmeta_a vbmeta.img
fastboot flash oem_a oem.img
fastboot flash logo_a logo.bin
fastboot flash boot_a boot.img
fastboot flash dtb_a dtb.img
fastboot flash dtbo_a dtbo.img
fastboot flash system_a system.img_sparsechunk.0
fastboot flash -u system_a system.img_sparsechunk.1
fastboot flash -u system_a system.img_sparsechunk.2
fastboot flash -u system_a system.img_sparsechunk.3
fastboot flash -u system_a system.img_sparsechunk.4
fastboot flash -u system_a system.img_sparsechunk.5
fastboot flash -u system_a system.img_sparsechunk.6
fastboot flash -u system_a system.img_sparsechunk.7
fastboot flash -u system_a system.img_sparsechunk.8
fastboot flash system_b system_other.img_sparsechunk.0
fastboot flash -u system_b system_other.img_sparsechunk.1
fastboot flash vendor_a vendor.img
fastboot reboot
Click to expand...
Click to collapse
i love u

Moto z2 force Flash Stock Wifi Issues x1789-04 tmobile

Notice there is a huge issue with the modem in another post https://forum.xda-developers.com/z2-force/help/0-imei-pie-xt-1789-03-sprint-t3957851 please stay tune
I am having an issue with Wifi, I attempted to update lineage os 17.1 did process to clean flash. After did all the process provided with the guide of lineage os official wiki of my moto Z2 when it booted it got stuck on the loop lineage logo for over 15 minutes than usual with it configures. I decided to flash it back to stock, did a script for it of course(using an example of rcmaehl here XDA) due to long periods test fail I was able to boot it in stock oreo, but when I got to set it up, it does not show any wifi and not even data of carrier. went to the bootloader again to notice that broadband is unknown(not found). long story short I have a half soft brick phone. Any idea and suggestion.
The script I was able to make flash to stock oreo:
Code:
@echo off
adb reboot bootloader
fastboot --set-active=a
ECHO Switched to partition A press any key to continue flashing...
pause
fastboot getvar max-sparse-size
fastboot oem fb_mode_set
fastboot flash partition gpt.bin
fastboot flash bootloader bootloader.img
fastboot flash modem_a NON-HLOS.bin
fastboot flash fsg_a fsg.mbn
fastboot flash bluetooth_a BTFM.bin
fastboot flash dsp_a adspso.bin
fastboot flash logo_a logo.bin
fastboot flash boot_a boot.img
fastboot flash gpt gpt.bin
fastboot flash system_a system.img_sparsechunk.0
fastboot flash system_a system.img_sparsechunk.1
fastboot flash system_a system.img_sparsechunk.2
fastboot flash system_a system.img_sparsechunk.3
fastboot flash system_a system.img_sparsechunk.4
fastboot flash system_a system.img_sparsechunk.5
fastboot flash system_b system_b.img_sparsechunk.0
fastboot flash system_b system_b.img_sparsechunk.1
fastboot flash oem_a oem.img
fastboot erase modemst1
fastboot erase modemst2
fastboot erase carrier
fastboot erase cache
fastboot erase ddr
fastboot flash fsg_a fsg.mbn
fastboot flash bluetooth_a BTFM.bin
fastboot oem fb_mode_clear
echo Finished. Press any key to rebooting to flash to B.
pause
adb reboot bootloader
pause
adb --set-active=b
echo Switched to partition A press any key to continue flashing...
pause
fastboot getvar max-sparse-size
fastboot oem fb_mode_set
fastboot flash partition gpt.bin
fastboot flash bootloader bootloader.img
fastboot flash modem_a NON-HLOS.bin
fastboot flash fsg_a fsg.mbn
fastboot flash bluetooth_a BTFM.bin
fastboot flash dsp_a adspso.bin
fastboot flash logo_a logo.bin
fastboot flash boot_a boot.img
fastboot flash gpt gpt.bin
fastboot flash system_a system.img_sparsechunk.0
fastboot flash system_a system.img_sparsechunk.1
fastboot flash system_a system.img_sparsechunk.2
fastboot flash system_a system.img_sparsechunk.3
fastboot flash system_a system.img_sparsechunk.4
fastboot flash system_a system.img_sparsechunk.5
fastboot flash system_b system_b.img_sparsechunk.0
fastboot flash system_b system_b.img_sparsechunk.1
fastboot flash oem_a oem.img
fastboot erase modemst1
fastboot erase modemst2
fastboot erase carrier
fastboot erase cache
fastboot erase ddr
fastboot flash fsg_a fsg.mbn
fastboot flash bluetooth_a BTFM.bin
fastboot oem fb_mode_clear
echo Finished. Press any key to reboot.
pause
fastboot reboot
Looks like your script is wonky. It flashes everything from slot_a to slot_a, fine. Then it switches to slot_b and flashes everything to slot_a again. You just need a basic flashall. I've attached a zip with newer adb/fastboot files if neededm but the is also a flashfile convertor script courtesy of RootJunky. Just put the script in your extracted firmware folder and run it, it will create a flashall for that firmware. Then you can use the flashall to flash stock properly.
As far as installing Los17.1, follow the install guide, and use the prep zip to copy your modem etc to the other slot.
41rw4lk said:
Looks like your script is wonky. It flashes everything from slot_a to slot_a, fine. Then it switches to slot_b and flashes everything to slot_a again. You just need a basic flashall. I've attached a zip with newer adb/fastboot files if neededm but the is also a flashfile convertor script courtesy of RootJunky. Just put the script in your extracted firmware folder and run it, it will create a flashall for that firmware. Then you can use the flashall to flash stock properly.
As far as installing Los17.1, follow the install guide, and use the prep zip to copy your modem etc to the other slot.
Click to expand...
Click to collapse
I attempted as avised with script convertor of RootJunky. First attempt running the script
Code:
max-sparse-size: 268435456
Finished. Total time: 0.000s
OKAY [ 0.000s]
Finished. Total time: 0.000s
(bootloader) is-logical:partition: not found
Sending 'partition' (206 KB) OKAY [ 0.016s]
Writing 'partition' (bootloader) Validating 'gpt.default.xml'
(bootloader) Committing 'gpt.default.xml'
(bootloader) - flashing 'gpt_main0.bin' to 'partition:0'
(bootloader) - flashing 'gpt_main1.bin' to 'partition:1'
(bootloader) - flashing 'gpt_main2.bin' to 'partition:2'
(bootloader) - flashing 'gpt_main3.bin' to 'partition:3'
(bootloader) - flashing 'gpt_main4.bin' to 'partition:4'
(bootloader) - flashing 'gpt_main5.bin' to 'partition:5'
OKAY [ 0.185s]
Finished. Total time: 0.216s
(bootloader) is-logical:bootloader: not found
Sending 'bootloader' (9884 KB) OKAY [ 0.331s]
Writing 'bootloader' (bootloader) Validating 'bootloader.default.xml'
(bootloader) Committing 'bootloader.default.xml'
(bootloader) - flashing 'xbl.elf' to 'xbl'
(bootloader) - flashing 'cmnlib.mbn' to 'cmnlib'
(bootloader) - flashing 'cmnlib64.mbn' to 'cmnlib64'
(bootloader) - flashing 'abl.elf' to 'abl'
(bootloader) - flashing 'keymaster.mbn' to 'keymaster'
(bootloader) - flashing 'rpm.mbn' to 'rpm'
(bootloader) - flashing 'pmic.elf' to 'pmic'
(bootloader) - flashing 'hyp.mbn' to 'hyp'
(bootloader) - flashing 'tz.mbn' to 'tz'
(bootloader) - flashing 'devcfg.mbn' to 'devcfg'
(bootloader) - flashing 'storsec.mbn' to 'storsec'
(bootloader) - flashing 'prov64.mbn' to 'prov'
OKAY [ 0.169s]
Finished. Total time: 0.501s
(bootloader) is-logical:modem__a: not found
Sending 'modem__a' (97431 KB) ^CTerminate batch job (Y/N)? n
Sending 'fsg' (5596 KB) FAILED (Write to device failed (Invalid argument))
fastboot: error: Command failed
< waiting for any device >
(bootloader) is-logical:bluetooth__a: not found
Sending 'bluetooth__a' (4500 KB) OKAY [ 0.135s]
Writing 'bluetooth__a' (bootloader) Invalid partition name bluetooth__a
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:dsp__a: not found
Sending 'dsp__a' (16384 KB) OKAY [ 0.594s]
Writing 'dsp__a' (bootloader) Invalid partition name dsp__a
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:logo__a: not found
Sending 'logo__a' (3151 KB) OKAY [ 0.085s]
Writing 'logo__a' (bootloader) Invalid partition name logo__a
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:boot__a: not found
Sending 'boot__a' (23357 KB) OKAY [ 0.721s]
Writing 'boot__a' (bootloader) Invalid partition name boot__a
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:system__a: not found
Sending 'system__a' (516201 KB) OKAY [ 16.038s]
Writing 'system__a' (bootloader) Invalid partition name system__a
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:system__a: not found
Sending 'system__a' (495129 KB) OKAY [ 15.564s]
Writing 'system__a' (bootloader) Invalid partition name system__a
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:system__a: not found
Sending 'system__a' (519125 KB) OKAY [ 16.524s]
Writing 'system__a' (bootloader) Invalid partition name system__a
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:system__a: not found
Sending 'system__a' (523779 KB) OKAY [ 16.152s]
Writing 'system__a' (bootloader) Invalid partition name system__a
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:system__a: not found
Sending 'system__a' (516309 KB) OKAY [ 16.016s]
Writing 'system__a' (bootloader) Invalid partition name system__a
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:system__a: not found
Sending 'system__a' (420583 KB) OKAY [ 13.061s]
Writing 'system__a' (bootloader) Invalid partition name system__a
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:system_b: not found
Sending 'system_b' (515183 KB) OKAY [ 16.010s]
Writing 'system_b' OKAY [ 2.907s]
Finished. Total time: 25.177s
(bootloader) is-logical:system_b: not found
Sending 'system_b' (307220 KB) OKAY [ 9.615s]
Writing 'system_b' OKAY [ 1.648s]
Finished. Total time: 14.835s
(bootloader) is-logical:oem__a: not found
Sending 'oem__a' (175682 KB) OKAY [ 5.476s]
Writing 'oem__a' (bootloader) Invalid partition name oem__a
FAILED (remote: '')
fastboot: error: Command failed
Erasing 'modemst1' OKAY [ 0.001s]
Finished. Total time: 0.005s
Erasing 'modemst2' OKAY [ 0.001s]
Finished. Total time: 0.005s
Erasing 'carrier' OKAY [ 0.001s]
Finished. Total time: 0.004s
Erasing 'cache' OKAY [ 0.000s]
Finished. Total time: 0.004s
Erasing 'userdata' OKAY [ 0.075s]
Finished. Total time: 0.082s
Erasing 'ddr' OKAY [ 0.001s]
Finished. Total time: 0.006s
(bootloader) is-logical:fsg__a: not found
Sending 'fsg__a' (5596 KB) OKAY [ 0.173s]
Writing 'fsg__a' (bootloader) Invalid partition name fsg__a
FAILED (remote: '')
fastboot: error: Command failed
(bootloader) is-logical:bluetooth__a: not found
Sending 'bluetooth__a' (4500 KB) OKAY [ 0.137s]
Writing 'bluetooth__a' (bootloader) Invalid partition name bluetooth__a
FAILED (remote: '')
fastboot: error: Command failed
OKAY [ 0.001s]
Finished. Total time: 0.004s
I notice the error, then proceeded to fix which it should be flash. all it flashes well, but went attempt to reboot to see if system boots up and go back to bootloader .
I'm aware that my scripting is the worst:laugh:, but funny part it got the job done to able to see the system up and running of course without data or wifi connection. :silly: I do appreciate the assistance and Hopefully keep having the assist with suggestions or guides of course. thankfully I have back up the phone(Not Moto z2) but really wish to go back this phone to able to use it as my main again...
If you look at your output you can see that it's putting double__underscores before the partition name, that's incorrect. To save a lot of time and trouble and since you're on Sprint which is the same as TMO when it comes to flashalls, I'll attach a flashall that will flash both slots so you should have a clean slate to start with. Also the rebooting to bootloader is because fastboot oem fb_mode_set wasn't cleared at the end, no big deal. The flashall I've attached should clear it when it's done.
it flashed successfully, but modem(wifi not working)when attempted to choose a connection . it is quite odd...that is not working. any ideas?
insanegrim said:
it flashed successfully, but modem(wifi not working)when attempted to choose a connection . it is quite odd...that is not working. any ideas?
Click to expand...
Click to collapse
Go back to fastboot and flash the modem only.
fastboot flash modem (drag and drop the NON-HLOS.bin from your firmware here)
fastboot erase modemst1
fastboot erase modemst2
fastboot reboot
If that doesn't work it may be possible that your persist partition is full and not letting the modem initialize. You'll need root for this.
adb shell
su
cd /mnt/vendor/persist/cache/recovery
rm log
rm last_log
exit
exit
adb reboot
41rw4lk said:
If you look at your output you can see that it's putting double__underscores before the partition name, that's incorrect. To save a lot of time and trouble and since you're on Sprint which is the same as TMO when it comes to flashalls, I'll attach a flashall that will flash both slots so you should have a clean slate to start with. Also the rebooting to bootloader is because fastboot oem fb_mode_set wasn't cleared at the end, no big deal. The flashall I've attached should clear it when it's done.
Click to expand...
Click to collapse
This soft bricked and now it bootloops my xt1789-04

MOTO G8 ENTERING THE FASTBOOT SCREEN AND DOES NOT START

Hello friends, how are you?
I'm Jeferson and I'm sorry if I'm in the wrong place and (my English).
I have a Moto G8 XT2045-1 it is going straight to the fastboot screen after an android error.
I tried to pass the software on it through "RESCUE" it completes successfully but the device appears the motorola logo and restarts (this process happens 4 times) after that it enters a FAIL BOOT screen.
I tried to use some ADB commands but I don't have much knowledge about these commands, I'll leave the commands I used and their results, in case anyone has gone through this problem I appreciate any help.
Thanks.
Cod.
fastboot oem fb_mode_set
fastboot getvar max-sparse-size
fastboot flash partition gpt.bin
fastboot flash bootloader bootloader.img
fastboot flash logo logo.bin
fastboot flash boot boot.img
fastboot flash recovery recovery.img
fastboot flash dsp adspso.bin
fastboot flash oem oem.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 system system.img_sparsechunk.5
fastboot flash system system.img_sparsechunk.6
fastboot flash system system.img_sparsechunk.7
fastboot flash system system.img_sparsechunk.8
fastboot flash system system.img_sparsechunk.9
fastboot flash system system.img_sparsechunk.10
fastboot flash system system.img_sparsechunk.11
fastboot flash system system.img_sparsechunk.12
fastboot flash system system.img_sparsechunk.13
fastboot flash system system.img_sparsechunk.14
fastboot flash modem NON-HLOS.bin
fastboot erase modemst1
fastboot erase modemst2
fastboot flash fsg fsg.mbn
fastboot erase cache
fastboot erase userdata
fastboot reboot
Result.
fastboot oem fb_mode_set
...
OKAY [ 0.003s]
finished. total time: 0.004s
fastboot getvar max-sparse-size
max-sparse-size: 268435456
finished. total time: 0.002s
fastboot flash partition gpt.bin
target reported max download size of 805263360 bytes
sending 'partition' (37 KB)...
OKAY [ 0.003s]
writing 'partition'...
(bootloader) Validating 'gpt.default.xml'
(bootloader) Committing 'gpt.default.xml'
(bootloader) - flashing 'gpt_main0.bin' to 'partition:0'
OKAY [ 0.383s]
finished. total time: 0.389s
fastboot flash bootloader bootloader.img
target reported max download size of 805263360 bytes
sending 'bootloader' (14204 KB)...
OKAY [ 0.343s]
writing 'bootloader'...
(bootloader) Validating 'bootloader.default.xml'
(bootloader) Committing 'bootloader.default.xml'
(bootloader) - flashing 'cmnlib.mbn' to 'cmnlib'
(bootloader) - flashing 'cmnlib64.mbn' to 'cmnlib64'
(bootloader) - flashing 'keymaster.mbn' to 'keymaster'
(bootloader) - flashing 'hyp.mbn' to 'hyp'
(bootloader) - flashing 'tz.mbn' to 'tz'
(bootloader) - flashing 'devcfg.mbn' to 'devcfg'
(bootloader) - flashing 'uefi_sec.mbn' to 'uefisecapp'
(bootloader) - flashing 'prov64.mbn' to 'prov'
(bootloader) - flashing 'rpm.mbn' to 'rpm'
(bootloader) - flashing 'abl.elf' to 'abl'
(bootloader) - flashing 'qupfw.elf' to 'qupfw'
(bootloader) - flashing 'xbl_config.elf' to 'xbl_config'
(bootloader) - flashing 'xbl.elf' to 'xbl'
OKAY [ 0.349s]
finished. total time: 0.696s
fastboot flash logo logo.bin
target reported max download size of 805263360 bytes
sending 'logo' (2667 KB)...
OKAY [ 0.063s]
writing 'logo'...
(bootloader) Preflash validation failed
FAILED (remote failure)
finished. total time: 0.203s
fastboot flash boot boot.img
target reported max download size of 805263360 bytes
sending 'boot' (65536 KB)...
OKAY [ 1.499s]
writing 'boot'...
OKAY [ 0.915s]
finished. total time: 2.421s
fastboot flash recovery recovery.img
target reported max download size of 805263360 bytes
sending 'recovery' (65536 KB)...
OKAY [ 1.472s]
writing 'recovery'...
OKAY [ 1.087s]
finished. total time: 2.562s
fastboot flash dsp adspso.bin
error: cannot load 'adspso.bin'
fastboot flash oem oem.img
error: cannot load 'oem.img'
fastboot flash system system.img_sparsechunk.0
error: cannot load 'system.img_sparsechunk.0'
fastboot flash system system.img_sparsechunk.1
error: cannot load 'system.img_sparsechunk.1'
fastboot flash system system.img_sparsechunk.2
error: cannot load 'system.img_sparsechunk.2'
fastboot flash system system.img_sparsechunk.3
error: cannot load 'system.img_sparsechunk.3'
fastboot flash system system.img_sparsechunk.4
error: cannot load 'system.img_sparsechunk.4'
fastboot flash system system.img_sparsechunk.5
error: cannot load 'system.img_sparsechunk.5'
fastboot flash system system.img_sparsechunk.6
error: cannot load 'system.img_sparsechunk.6'
fastboot flash system system.img_sparsechunk.7
error: cannot load 'system.img_sparsechunk.7'
fastboot flash system system.img_sparsechunk.8
error: cannot load 'system.img_sparsechunk.8'
fastboot flash system system.img_sparsechunk.9
error: cannot load 'system.img_sparsechunk.9'
fastboot flash system system.img_sparsechunk.10
error: cannot load 'system.img_sparsechunk.10'
fastboot flash system system.img_sparsechunk.11
error: cannot load 'system.img_sparsechunk.11'
fastboot flash system system.img_sparsechunk.12
error: cannot load 'system.img_sparsechunk.12'
fastboot flash system system.img_sparsechunk.13
error: cannot load 'system.img_sparsechunk.13'
fastboot flash system system.img_sparsechunk.14
error: cannot load 'system.img_sparsechunk.14'
fastboot flash modem NON-HLOS.bin
error: cannot load 'NON-HLOS.bin'
fastboot erase modemst1
erasing 'modemst1'...
OKAY [ 0.014s]
finished. total time: 0.015s
fastboot erase modemst2
erasing 'modemst2'...
OKAY [ 0.005s]
finished. total time: 0.008s
fastboot flash fsg fsg.mbn
error: cannot load 'fsg.mbn'
fastboot erase cache
erasing 'cache'...
OKAY [ 0.002s]
finished. total time: 0.004s
fastboot erase userdata
erasing 'userdata'...
OKAY [ 0.219s]
finished. total time: 0.220s
fastboot reboot

[Fix] Motorola_XML_To_Batch_Script

If your output looks like this do the following.
Code:
sending 'modema' (65420 KB)...
OKAY [ 1.495s]
writing 'modema'...
(bootloader) Invalid partition name modema
FAILED (remote failure)
finished. total time: 1.525s
target reported max download size of 536870912 bytes
sending 'fsga' (9192 KB)...
OKAY [ 0.213s]
writing 'fsga'...
(bootloader) Invalid partition name fsga
FAILED (remote failure)
finished. total time: 0.232s
target reported max download size of 536870912 bytes
sending 'dspa' (16384 KB)...
OKAY [ 0.378s]
writing 'dspa'...
(bootloader) Invalid partition name dspa
FAILED (remote failure)
finished. total time: 0.393s
target reported max download size of 536870912 bytes
sending 'logoa' (1285 KB)...
OKAY [ 0.034s]
writing 'logoa'...
(bootloader) Invalid partition name logoa
FAILED (remote failure)
finished. total time: 0.046s
target reported max download size of 536870912 bytes
sending 'boota' (32768 KB)...
OKAY [ 0.820s]
writing 'boota'...
(bootloader) Invalid partition name boota
FAILED (remote failure)
finished. total time: 0.834s
You need to specify the A/B partitions like the following. Just add "_" to the Invalid partition name.
Code:
echo off
fastboot getvar max-sparse-size
fastboot oem fb_mode_set
fastboot flash partition gpt.bin
fastboot flash bootloader bootloader.img
fastboot flash modem_a NON-HLOS.bin
fastboot flash fsg_a fsg.mbn
fastboot flash dsp_a adspso.bin
fastboot flash logo_a logo.bin
fastboot flash boot_a boot.img
fastboot flash dtbo_a dtbo.img
fastboot flash system_a system.img_sparsechunk.0
fastboot flash system_a system.img_sparsechunk.1
fastboot flash system_a system.img_sparsechunk.2
fastboot flash system_a system.img_sparsechunk.3
fastboot flash system_a system.img_sparsechunk.4
fastboot flash system_a system.img_sparsechunk.5
fastboot flash system_a system.img_sparsechunk.6
fastboot flash system_a system.img_sparsechunk.7
fastboot flash system_a system.img_sparsechunk.8
fastboot flash system_a system.img_sparsechunk.9
fastboot flash system_a system.img_sparsechunk.10
fastboot flash system_b system_b.img_sparsechunk.0
fastboot flash system_b system_b.img_sparsechunk.1
fastboot flash system_b system_b.img_sparsechunk.2
fastboot flash vendor_a vendor.img_sparsechunk.0
fastboot flash vendor_a vendor.img_sparsechunk.1
fastboot flash oem_a oem.img
fastboot flash oem_b oem_other.img
fastboot erase modemst1
fastboot erase modemst2
fastboot erase userdata
fastboot erase DDR
fastboot flash fsg_a fsg.mbn
fastboot oem fb_mode_clear
echo -------------------------------------------------------------------------
echo please scroll up and check your flash for any errors
echo -------------------------------------------------------------------------
pause
fastboot reboot
exit

Categories

Resources