yashsingh1/xdaforums huggingface dataset:
[Xiaomi Mi 5 Questions & Answers] Spws:
Hi

Today stopped working fingerpoint button of my Xiaomi mi5 phone.the menu item disappeared fingerpoint.

Help me please!!!
[Samsung Galaxy S7 Questions and Answers] Jopponius:
Just a noob question from my side.

Reading lately on xda and noticed a bunch of problems downgrading and upgrading firmwares and custon recoverys these days.

Does this have to do with tighter firmware security updates these days or what exactly? What is patched or changed with every update regarding these problems.
[Xiaomi Mi A1 Guides, News, & Discussion] emprazol:
Very good job man tnx
[Xiaomi Mi A1 Guides, News, & Discussion] rubenswing:
First of all it doesn't work for me with a locked bootloader, I had to unlock the bootloader and followed the instructions, after opening the program and selecting any option in the tool simply closes the window and nothing happens. I tried it 4 times but no use, it just closes the command prompt window
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
Oh derp to me; of course locked bootloader can't access fastboot at all can it! Shows how experienced I am with locked devices :p thanks - updated thread with statement of unlocked BL requirement.

Re: Your crash, I realized right away that that is very likely because the program path has spaces in it. I fixed that now, just download the tool again and it should work. If not though, there is now a _debug tool that will show you the error instead of instantly closing. But I'm 90% sure that the problem you had is now fixed.
[Xiaomi Mi A1 Guides, News, & Discussion] cherryb8844:
So you mention that all partition. Mean I can make persist and IMEI partition (I don't know whatever it called in our device in Samsung it's called efs) backup to. I did backup of IMEI partition via qpst tool (it's .qcnfile) but I wanted to make more backup. My WiFi is broken since I installed custom rom so I restored it via persist resurrect tool.

Thanks for your hardwork making thing easy for us.
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
If IMEI is on EFS, yes it will do that but TWRP also has EFS backup/restore.

This tool will do absolutely every partition, there is literally nothing else on the storage that needs to be backed up. Only thing it can't do is repartition device, that has to be done manually (I have another thread about that).
[Xiaomi Mi A1 Guides, News, & Discussion] rubenswing:
Yep it's working very much now as expected and a big thank you :good: I now could backup up all the partitions on my device :)
[Xiaomi Mi A1 Guides, News, & Discussion] ekistece:
flash_factory.bat

Which are the files that are nuked when you do a flash_factory? I know modemst1, modemst2 and persist are the important ones that are mentioned in the threads. There's any other data you should backup? I see there's a lot more partitions other than the usual ones, they hold irrecoverable data too? Also I'have seen that to recover IMEI people use a qualcomm tool, do you need that process or you can just flash modemst1 and modemst2 to recover IMEI?
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
Check the factory_flash.bat, it flashes everything. Also the rawpartition0.xml (which is used in edl mode, factory_flash.bat is only for fastboot mode). So backup everything.

I don't know where Imei is stores, so just backup everything.

Qualcomm tool IMEI recovery is for injecting IMEI into existing partition somewhere. Not necessary if you already have full IMG backups.
[Xiaomi Mi A1 Guides, News, & Discussion] thepandas:
Noob Questions :confused:

1. Ok, so consider i have used your tool and worked as intended. so currently the Phone will be in 'edl mode' how can i reboot it back to system (i guess fastboot commands wont work in edl mode).

2. After creating backup, How should i restore partions ?...

using twrp or CMD....?

(Does Tool backup Partitions as img or zip file....?)

3. Does this tool allows user to restore partition individually or one has restore all the backup data as a whole (i.e all backup partions)

Thanks again for the amazing tool :angel: :good:
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
1) Hold power button for 10+ seconds to reboot

2) You restore them with the same tool, there is a restore option in the menu, it's right there ?

3) The restore will restore everything listed in rawpartitions0.xml inside the IMG backup folder. If you want to exclude some partitions in restore, delete the corresponding XML line. This is already explained in the OP.
[Xiaomi Mi A1 Guides, News, & Discussion] SmallTarzan:
Great job. Was just wondering if is everything going well if is this error displayed in the log:

Version 2.15
PblHack: Error - 1836597052
Did not receive Sahara hello packet from device

!!!!!!!! WARNING: Flash programmer failed to load trying to continue !!!!!!!!!

Dumping data to file RR-FULL\system_b.img
Dumping at start sector: 0 for sectors: 0 to file: RR-FULL\system_b.img
.0" encoding="UTF-8" ?><data><log value="XML (0 bytes) not validated" /></data><?xml version="1.0" encoding="UTF-8" ?><data><response value="NAK" /></data>
Programming device using SECTOR_SIZE=512

<?xml version = "1.0" ?><data><configure MemoryName="emmc" ZLPAwareHost="1" SkipStorageInit="0" SkipWrite="0" MaxPayloadSizeToTargetInBytes="16384"/></data>
<?xml version="1.0" encoding="UTF-8" ?><data><log value="logbuf@0x0806CEC0 fh@0x08069D28" /></data>
<?xml version="1.0" encoding="UTF-8" ?><data><response value="ACK" MinVersionSupported="1" MemoryName="eMMC" MaxPayloadSizeFromTargetInBytes="4096" MaxPayloadSizeToTargetInBytes="16384" MaxPayloadSizeToTargetInBytesSupported="1048576" MaxXMLSizeInBytes="4096" Version="1" TargetName="8953" /></data>
<?xml version="1.0" encoding="UTF-8" ?><data><response value="ACK" MinVersionSupported="1" MemoryName="eMMC" MaxPayloadSizeFromTargetInBytes="4096" MaxPayloadSizeToTargetInBytes="16384" MaxPayloadSizeToTargetInBytesSupported="1048576" MaxXMLSizeInBytes="4096" Version="1" TargetName="8953" /></data>
Connected to flash programmer, starting dump
<?xml version="1.0" ?><data>
<read SECTOR_SIZE_IN_BYTES="512" num_partition_sectors="1" physical_partition_number="0" start_sector="1"/>
</data>
<?xml version="1.0" encoding="UTF-8" ?><data><response value="ACK" rawmode="true" /></data>
Sectors remaining 1

Downloaded raw image at speed 30 KB/s
<?xml version="1.0" encoding="UTF-8" ?><data><log value="Finished sector address 0" /></data>
<?xml version="1.0" encoding="UTF-8" ?><data><response value="ACK" rawmode="false" /></data>
<?xml version="1.0" ?><data>
<read SECTOR_SIZE_IN_BYTES="512" num_partition_sectors="32" physical_partition_number="0" start_sector="2"/>
</data>
<?xml version="1.0" encoding="UTF-8" ?><data><response value="ACK" rawmode="true" /></data>
Sectors remaining 32

Downloaded raw image at speed 16384 KB/s
<?xml version="1.0" encoding="UTF-8" ?><data><log value="Finished sector address 0" /></data>
<?xml version="1.0" encoding="UTF-8" ?><data><response value="ACK" rawmode="false" /></data>
<?xml version="1.0" ?><data>
<read SECTOR_SIZE_IN_BYTES="512" num_partition_sectors="6291456" physical_partition_number="0" start_sector="7477248"/>
</data>
<?xml version="1.0" encoding="UTF-8" ?><data><response value="ACK" rawmode="true" /></data>
hRead = INVALID_HANDLE_VALUE, zeroing input buffer

Should I leave it and let it continue? Because it's been frozen for some time now.
[Xiaomi Mi A1 Guides, News, & Discussion] rubenswing:
At the very end of the log file does it give a status?
[Xiaomi Mi A1 Guides, News, & Discussion] SmallTarzan:
No, it doesn't.

Sectors remaining 1792
Sectors remaining 1760
Sectors remaining 1728
Sectors remaining 1696
Sectors remaining 1664
Sectors remaining 1632
Sectors remaining 1600
Sectors remaining 1568
Sectors remaining 1536
Sectors remaining 1504
Sectors remaining 1472
Sectors remaining 1440
Sectors remaining 1408
Sectors remaining 1376
Sectors remaining 1344
Sectors remaining 1312
Sectors remaining 1280
Sectors remaining 1248
Sectors remaining 1216
Sectors remaining 1184
Sectors remaining 1152
Sectors remaining 1120
Sectors remaining 1088
Sectors remaining 105

It's been stuck at this for like 30 minutes now, I've closed it.
[Xiaomi Mi A1 Guides, News, & Discussion] rubenswing:
Could you upload the log file
[Xiaomi Mi A1 Guides, News, & Discussion] SmallTarzan:
Where should I upload it? I can't upload it here, it's over the size limit. Pastebin doesn't work either.
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
You need a better USB cable or try a different port.

It will report success if it finishes OK. But that is a communication error when it freezes.

Also reboot EDL mode. And keep the window active, don't go play a game while it's doing stuff :p
[Xiaomi Mi A1 Guides, News, & Discussion] SmallTarzan:
I am using an USB-C cable I bought from a shop the other day, and I was in the EDL mode. I wasn't playing a game during the backup either!
[Xiaomi Mi A1 Guides, News, & Discussion] rubenswing:
Then as Cosmic Dan said try a different port and check :)
[Xiaomi Mi A1 Guides, News, & Discussion] joeyhuab:
Thanks for the tool! Was able to backup everything except userdata and system since i don't have the time yet. I'll be preparing for treble. :)
[Xiaomi Mi A1 Guides, News, & Discussion] ddaggebi:
The tool hangs everytime, no matter how I do my setup.

Stock cable, port changed to COM10 according to my Device Manager(W10 64bit), no spaces or anything in the directory, even tried giving Administrator Privileges to the batch file.

Nothing works, it hangs mid of backuping modem_a or modem_b

Here are some logs.

I live in South Korea, so my laptop's Windows language is Korean. Can it be a cause of the problem?

<edit>

Okay, I think I found the answer myself.

1. You must reenter EDL mode everytime you fail to try another attempt.

2. [IMPORTANT] Please update EDL driver to the one provided in the OP. Somehow I already had a driver, but it must have been a faulty one. Updating driver solved the problem.

Thanks to the developers! Now I'm going to use Treblizer~
[Xiaomi Mi A1 Guides, News, & Discussion] Raxcoms:
Got the same twice (but in different sectors, during persist and logdump)

But it worked fine in the third one. (in a different usb port, as suggested here)

Only if you unplug your device.

You can hit ctrl +c to cancel the process and try again.
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
Yes you should reboot device on failure.

And yeah, the driver in first post is good. It's 100% stable for me with original USB-C cable. I will add this info to OP.
[Xiaomi Mi A1 Guides, News, & Discussion] thepandas:
Thanks for the tool it just creates backup in less than minute

More intuitive than I thought...
[Xiaomi Mi A1 Guides, News, & Discussion] idrees_jawad:
Question regarding restore

Currently I'm on RR official and Franco kernel. I observed that my original WiFi and Bluetooth Mac has been changed. But both are working. Before flashing RR. I took the backup of all partitions with low level backup tool. Now my question is can I restore the persist partition on RR or let it be the current one. Would it affect anything? If I can restore it on RR then how can I restore only persist. Thanks
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
As it says in the main post...

...just delete the lines matching the partitions you don't want.
[Xiaomi Mi A1 Guides, News, & Discussion] idrees_jawad:
Edit:

I used the tool on RR 6.0 Official. I successfully restored persist partition but I didn't get my original Wlan and BT Mac back. I also tried persist resurrector, it shown me correct Mac but could not change it on my phone.

Any ideas?
[Xiaomi Mi A1 Guides, News, & Discussion] jack_21:
Just a question

Does increasing the Virtual Com Port bitrate from 9600 to 128000 will increase the backup/restore process speed?

I can't get it to work, just installed your drivers and using the official USB-C cable (with different ports) but it keeps hanging on modem_a backup...
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
No idea. Off topic.

Nah, that's legacy stuff for real com ports. 9600bps is very very slow, it'd take weeks if that were true lol).

You can reduce the speed of transfer, actually. It might help (it's not possible to go faster than it is now, but slower speed may increasd reliability if you've a bad cable or OS). I'll whip up a new version that allows changing it easily.

Make sure you're using the driver I linked, too. Others were unreliable for me.
[Xiaomi Mi A1 Guides, News, & Discussion] jack_21:
Tried, no luck.

Windows 10 latest version (clean installation done 1 week ago), Mi A1 with may update but nothing to do :(
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
New version out which lets you change transfer speed in config.ini.

Read the comments, you have to reduce it to get a more reliable speed. Try with maybe 8192 first. It will take twice as long as the default 16384 but hopefully works. If not, try 4096.
[Xiaomi Mi A1 Guides, News, & Discussion] jack_21:
Thanks, will try this out
[Xiaomi Mi A1 Guides, News, & Discussion] Ahmed Al-Sayed:
For everyone that faces freezing issue,

if you tried the solutions provided in the OP and none of them worked, try selecting the desktop as the path for saveing the backup folder in (which means that when you choose the script you want to run and choose option 2, the tool will ask you to enter the folder name or the path you eant to put the folder in.... Just choose the desktop as the path and it won't freeze, hopefully )
[Xiaomi Mi A1 Guides, News, & Discussion] pooniaprashant:
worked like a charm on stock 8.0 may patch, i have a ques though, i flashed magisk before performing this backup, will it tamper any low lvl partitions of the backup? as i backed up this "partition_list.skip-systems-and-userdata.txt"
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
Yes. Magisk modifies the kernel. Your backup will contained a modified boot image. That's it, apart from system and userdata afaik.
[Xiaomi Mi A1 Guides, News, & Discussion] Venkatesh55:
wile entering fastboot its giving me error status read error (too many links) . what I am missing here
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
Ignore it. Device should recognise as EDL mode. OP already says to ignore the error.
[Xiaomi Mi A1 Guides, News, & Discussion] Venkatesh55:
tried everything u mentioned.

1)change cable

2)change port.

still freezing.
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
What about 3, 4, 5, etc.?
[Xiaomi Mi A1 Guides, News, & Discussion] oreo27:
Awesome tool, dude! I'm testing it now. I wonder how long an entire device backup will take. LOL. I didn't even need to install the drivers since I previously went to OEM EDL mode, which prompted Windows 10 to automatically install the drivers.
[Xiaomi Mi A1 Guides, News, & Discussion] joeyhuab:
Should not take too long. I skipped system and data partitions so it took a short time only. Didn't include system and data cause I backed up via TWRP.
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
Idk, I never bothered backing up system or userdata. My guess is 10 to 20mins for everything.

Automatic drivers? Ok, but don't complain when it freezes because you didn't use the recommended drivers.
[Xiaomi Mi A1 Guides, News, & Discussion] DGEEEK:
i dont know this this error or not [MENTION=1844875]CosmicDan[/MENTION] but i cant find any partition info Backedup or not

[#] Dumping "apdp" to "e:\Newmia1\apdp.img"...

[#] Dumping "msadp" to "e:\Newmia1\msadp.img"...

[#] Dumping "dpo" to "e:\Newmia1\dpo.img"...

[#] Dumping "logdump" to "e:\Newmia1\logdump.img"...

[#] Dumping partition table info...

The system cannot find the path specified.

The system cannot find the path specified.

The system cannot find the path specified.

The system cannot find the path specified.

The system cannot find the path specified.

The system cannot find the file specified.

[#] Building rawprogram0.xml...

The system cannot find the path specified.

The system cannot find the path specified.

The system cannot find the path specified.

The system cannot find the path specified.

The system cannot find the file specified.

All done!
[Xiaomi Mi A1 Guides, News, & Discussion] oreo27:
I tried it with all partitions and got tired of waiting. The userdata was about 30GB when I stopped. LOL.

I do the same for other devices where I don't require some kind of UI to configure settings (printer etc.). In my experience, Windows supplied drivers work pretty well for other devices. Just did a full backup with no freezes. If I ever encounter a freeze in the future, I'll try the driver linked in the OP. Thanks for the awesome tool once again man!
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
Might be related to you manually supplying a full path to some other folder or drive. I'll test this out and update to fix it.

EDIT: Nope, can't reproduce. Please try/share these things with me:

1) Where is the BackupRestoreTool located on your PC? (full path with drive, please)

2) What are you entering for the backup path location?

3) Have you tried running the BackupRestoreTool as Administrator?

Thanks.

Cool stuff, good to know. I just tried a lot and they were all crap until the one I linked.
[Xiaomi Mi A1 Guides, News, & Discussion] yaduvanshiii:
[MENTION=1844875]CosmicDan[/MENTION] bro facing this error pls help

- Mi A1 Low-level Backup/Restore/Flashing tool -
- -
- By CosmicDan@XDA and CosmicDan.com -
- Based on EMMCDL scripts thanks to @emuzychenko -
--------------------------------------------------------

[i] Make your choice:

1) Set partition list file [list of partitions to backup]
Current = partition_list.all.txt

2) Backup all partitions from partition list file

3) Restore a backup

4) Advanced...

5) Quit

[#] Enter number:
3

[#] Enter folder name or full/relative path of backup to restore:
vikasyadav
[!] An error occured. Not a valid backup path [missing rawprogram0.xml].

[i] Press any key to return to main menu.
Press any key to continue . . .

---------- Post added at 10:59 AM ---------- Previous post was at 10:59 AM ----------

[/COLOR [MENTION=1844875]CosmicDan[/MENTION] bro facing this error pls help

- Mi A1 Low-level Backup/Restore/Flashing tool -
- -
- By CosmicDan@XDA and CosmicDan.com -
- Based on EMMCDL scripts thanks to @emuzychenko -
--------------------------------------------------------

[i] Make your choice:

1) Set partition list file [list of partitions to backup]
Current = partition_list.all.txt

2) Backup all partitions from partition list file

3) Restore a backup

4) Advanced...

5) Quit

[#] Enter number:
3

[#] Enter folder name or full/relative path of backup to restore:
vikasyadav
[!] An error occured. Not a valid backup path [missing rawprogram0.xml].

[i] Press any key to return to main menu.
Press any key to continue . . .
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
The path is wrong/missing.
[Xiaomi Mi A1 Guides, News, & Discussion] aringcn:
test many time , backtool not appear folder oppion . why ? anything wrong ?
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
I don't understand your English sorry.
[Xiaomi Mi A1 Guides, News, & Discussion] aringcn:
thx . just now . lowbackup has done . only several minutes . sorry for my english .
[Xiaomi Mi A1 Guides, News, & Discussion] redbullman:
Wow. Just did the option without the full back up. It worked in about 10 seconds. Really impressive. The only thing I was surprised about was I didn't need the driver. Windows update pulled it through when I went into edl mode. Even when I selected update driver, stated it was the most recent.
[Xiaomi Mi A1 Guides, News, & Discussion] MrBurnGamer:
So this tool is able to backup every single partition of Mi A1 right?

I want to use it becouse I've seen some users report not working touchscreen after flashing ROMs or lost Wifi MAC Adress, which cannot be solved by just usint MiFlash Tool, I was wondering if this tool would help me in those situations as an example... I want to flash roms on my Mi A1 but I'm really afraid of getting permanent software damage.

Also I want to ask if I can unlock bootloader just to do the backup and then relock bootloader without losing any data.
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
Disregard (XDA Labs app doing it's best)
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
Yes, full backup will backup *everything* - don't share the backup with others!

Yes, you should be able to just relock afterwards.
[Xiaomi Mi A1 Guides, News, & Discussion] riccetto80:
worked like a charm!

backupped all except data and system, generated something like 470mb of files and needed just a couple of minuts!

thank you man!!!!
[Xiaomi Mi A1 Guides, News, & Discussion] prorooter007:
Anyone got stuck in edl mode?

What to do if stucked in edl mode?

Is stucking in edl mode a common issue ?

Or I am too much woried and it will work fine?

Please clear my queries

P.S I m a noob
[Xiaomi Mi A1 Guides, News, & Discussion] prorooter007:
it frezes every time i try

also my logs are empty

updated drivers from op

changed com port to 32 (as for my machine)

still no luck
[Xiaomi Mi A1 Guides, News, & Discussion] CosmicDan:
Read the FAQ. That has all the possible solutions. If none of them worked, then there's nothing else to suggest.

"COM32" is strange. Are you sure you are in QDLoader mode with flashing white LED? You might be in diagnostic mode (Brick). It will say on the driver in Device Manager.
[Xiaomi Mi A1 Guides, News, & Discussion] prorooter007:
I fixed it

The only thing I did wrong was that I didn't press 2 after selecting 1st option with 3rd sub option

Thanks for the tool

Works great
[Xiaomi Mi A1 Guides, News, & Discussion] riccetto80:
i notice this tool dont back uo the EFS partition! is this normal?
[Xiaomi Mi A1 Guides, News, & Discussion] Dusayanta:
This guide may help you

I did several experiments to connect and got the best way to connect your phone properly.

First of all download the Qualcomm Driver Setup from below link:

Official Mi Qualcomm drivers (find your device and download it).

Even download the driver files given by [MENTION=1844875]CosmicDan[/MENTION] in his thread.

Install the downloaded exe and reboot PC.

Connect your phone in fastboot mode and run the EDL command:

fastboot oem edl

You will face an error, but its normal as stated by [MENTION=1844875]CosmicDan[/MENTION]

Your phone's screen will go blank with a blinking LED, now you are in QDLoader mode.

Check for Qualcomm QDLoader in the device manager and update the driver using the driver files mentioned by [MENTION=1844875]CosmicDan[/MENTION] and note the com port and change accordingly in the config.ini file of tools's zip provided by [MENTION=1844875]CosmicDan[/MENTION]

Run the Tool-

Press 1 to selection which partitions to backup.

Choose from the sub option between 1 to 3 accordingly.

It will say 'Press any key to continue'

Press any key.

Again, press 2, which will give you an option to provide folder name where you want to backup the partitions.

It will say 'Press any key to start backup'

Press any key

On successful backup you will get a message 'All Done!'

Note:- I faced the freezing issue, the log file was not updating. I changed my usb port, mentioned the new com port in config.ini and ran the tool. And repeated the above process, it worked like a magic.
[Xiaomi Mi A1 Guides, News, & Discussion] KuGeSch:
Did everything according to OP.

When I start "fastboot oem edl" the phone switches to edl mode, but in the PC device manager "qhsusb_bulk" does not show up.

Changing the USB port then it shows sometimes up just for a second and disappears immediately.

I'm on Windows 10, latest build...
[Xiaomi Mi A1 Guides, News, & Discussion] Dusayanta:
Did you install official Qualcomm driver which i mentioned above?

If yes, then whenever the com port(usb port) appears, be very quick and right click on it and then try updating the driver first via online windows update and then later again update via the drivers provided by CosmicDan.

Note: Check whether its entering edl mode.... Blank screen with blinking LED.
[Xiaomi Mi A1 Guides, News, & Discussion] KuGeSch:
Yes, I installed the official drivers as well

it enters edl mode but it appears, if at all, for a decisecond, too fast for catching it and click on it...