FORUMS
Remove All Ads from XDA

[TOOL] Newflasher (xperia command line flasher for 2017 devices)

8,447 posts
Thanks Meter: 21,049
 
By munjeni, Senior Member on 9th June 2017, 05:58 PM
Post Reply Email Thread
Disclaimer:

newflasher tool was made for testing and educational purposes, ME is not responsible for what you do on/with your device using newflasher, you must agree that you using newflasher on your own risk, I am not responsible if you brick your device or anything else!


How to use:

OPTIONAL STEP 1:
- if you have missing flash driver just double click exe and confirm driver extraction, 7z archive will become available, extract it and install driver.

OPTIONAL STEP 2:
- this step is realy optional and maybe not a functional, this step dump trim area, need somebody confirmation!

STEP 1:
- Download right firmware for your device using XperiFirm tool, put newflasher.exe into firmware dir created by XperiFirm tool. Before you double click newflasher.exe do in mind something, newflasher tool is programed to flash everything found in the same dir!!! So tool flash all .ta files, all .sin files, boot delivery (whole boot folder), partition.zip, in short all files found in dir! If you no want to flash something just move file which you no want to flash OUT OF FOLDER! Partition.zip .sin files can be flashed only if you extract partition.zip into newly created folder called partition!

STEP 2:
- To start flashing phone put your phone into flash mode, double click newflasher.exe and wait wait wait until your device gets flashed, thats it. Look into log to see if something goes wrong! If all right you are done. If not post your log so I can look! Happy flashing!

Don't forget your opinions, sucess, reports, logs... etc, you are welcome with suggestions!


Platform:


- Newflasher is working on Windows, Linux and Android, just chose right newflasher binary. With Android version you can flash phone by using another phone!


Changelog:

- version 1: Sorry a lot of work is done in pre pre alpha version and I can't count every changes, just folow development process about version 1, a lot of work is done before it started working. One esential change was done to tool improvement and it is described in one of the my posts related to moving function "erase:" to the section before function "flash:", it is realy improvement and more safer than in time when it was at the start of flashing routine.

- version v2 (15.Aug.2017)
Implemented free disk space safety check, it was missing and danger in case flashing process gets interupted because of the lack of the free disk space needed for sin extractions and temporary files. I have also include GordonGate flash driver prompt so in case somebody have missing flash drivers, simple need to double click exe and folow drivers archive extraction procedure, later need to install these drivers trought Windos device mannager. Also I have implemented an realy pre pre alpha version of the maybe non working trim (why maybe? Because I don't own xzp so can't test) area dump routine, in case it is working we can dump some esentials trim area units from device (probably not a full dump as like it was on every oldest xperia models - no permissions for dumping drm key unit)

- version v3 (23.09.2017)
Some more security checks, it's now a bit safer than v2

- version v4 (21.10.2017)
Updated trim area dumper, now it stores log to the trimarea.log but dump is now in .ta format and writen to the 01.ta and 02.ta

- version v5 (22.10.2017)
Updated trim area dumper, add progress meter, fix y-n prompt (thanks @pbarrette)

- version v6 (22.10.2017)
Updated trim area dumper

- version v7 (23.10.2017)
Updated trim area dumper, newflasher redesigned a bit, fix new partitioning for Oreo

- version v8 (24.10.2017)
Fix trim area dumper

- version v9 & v10 (25.10.2017)
Workaorunds on trim area dumper

Credits:

- without @tanipat and his pc companion debug logs this tool will never be possible! Thank you a lot for your time providing me logs! (by the influence of others, He was disappointed me with last post, but I still appreciate his help and can't forget it)
- without @thrash001 who helped testing our tool I never be continue building our tool since I don't have device for testing, thanks mate!
- didn't forgot @beenoliu, thanks mate for testing!
- thanks to @porphyry for testing linux version!

Source code:

https://github.com/munjeni/newflasher
Attached Files
File Type: rar newflasher_v10.rar - [Click for QR Code] (4.70 MB, 16046 views)
The Following 210 Users Say Thank You to munjeni For This Useful Post: [ View ] Gift munjeni Ad-Free
 
 
9th June 2017, 06:01 PM |#2  
Senior Member
Thanks Meter: 72
 
More
let me start for you and report
The Following 2 Users Say Thank You to tanipat For This Useful Post: [ View ] Gift tanipat Ad-Free
9th June 2017, 06:25 PM |#3  
Member
Thanks Meter: 42
 
More
here my log..

Code:
--------------------------------------------------------
              newflasher.exe by Munjeni @ 2017
--------------------------------------------------------
Device path: \\?\usb#vid_0fce&pid_b00b#5&15c311e1&0&2#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
Class Description: USB-Controller
Device Instance Id: USB\VID_0FCE&PID_B00B\5&15C311E1&0&2

ERROR: TIMEOUT: failed with error code 997 as follows:
▄berlappender E/A-Vorgang wird verarbeitet.
 - Error writing command!
Drücken Sie eine beliebige Taste . . .
The Following 2 Users Say Thank You to thrash001 For This Useful Post: [ View ] Gift thrash001 Ad-Free
9th June 2017, 06:39 PM |#4  
munjeni's Avatar
OP Senior Member
Thanks Meter: 21,049
 
Donate to Me
More
Quote:
Originally Posted by thrash001

here my log..

Code:
--------------------------------------------------------
              newflasher.exe by Munjeni @ 2017
--------------------------------------------------------
Device path: \\?\usb#vid_0fce&pid_b00b#5&15c311e1&0&2#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
Class Description: USB-Controller
Device Instance Id: USB\VID_0FCE&PID_B00B\5&15C311E1&0&2

ERROR: TIMEOUT: failed with error code 997 as follows:
▄berlappender E/A-Vorgang wird verarbeitet.
 - Error writing command!
Drücken Sie eine beliebige Taste . . .

Hi thanks! You have driver installed? "Class Description: USB-Controller" looks like without drivers. Can you look into device manager when you connect phone in flash mode to usb?
The Following 2 Users Say Thank You to munjeni For This Useful Post: [ View ] Gift munjeni Ad-Free
9th June 2017, 06:40 PM |#5  
Senior Member
Thanks Meter: 72
 
More
what I got

--------------------------------------------------------
newflasher.exe by Munjeni @ 2017
--------------------------------------------------------
Device path: \\?\usb#vid_0fce&pid_b00b#6&3a757eec&0&1#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
Class Description: Universal Serial Bus controllers
Device Instance Id: USB\VID_0FCE&PID_B00B\6&3A757EEC&0&1

ERROR: GetOverlapped_in_Result: failed with error code 31 as follows:
A device attached to the system is not functioning.

- Error reaply! Device didn't replied with OKAY or DATA
Press any key to continue . . .

wait for others to report
The Following User Says Thank You to tanipat For This Useful Post: [ View ] Gift tanipat Ad-Free
9th June 2017, 06:49 PM |#6  
munjeni's Avatar
OP Senior Member
Thanks Meter: 21,049
 
Donate to Me
More
Hm, you successfully wrote command but error on reaply Lets see new version is out
The Following User Says Thank You to munjeni For This Useful Post: [ View ] Gift munjeni Ad-Free
9th June 2017, 07:39 PM |#7  
munjeni's Avatar
OP Senior Member
Thanks Meter: 21,049
 
Donate to Me
More
Today I have free time for development, I don't know when I will get free time again, so guys if you hurry to have flasher I am here and waiting. I do not have 2017 device model so I can't test, so can't continue development without your tests
The Following User Says Thank You to munjeni For This Useful Post: [ View ] Gift munjeni Ad-Free
9th June 2017, 07:44 PM |#8  
Member
Thanks Meter: 42
 
More
Driver is the right.

here the next:
Code:
--------------------------------------------------------
              newflasher.exe by Munjeni @ 2017
--------------------------------------------------------
Device path: \\?\usb#vid_0fce&pid_b00b#5&15c311e1&0&2#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
Class Description: USB-Controller
Device Instance Id: USB\VID_0FCE&PID_B00B\5&15C311E1&0&2

ERROR: TIMEOUT: failed with error code 997 as follows:
▄berlappender E/A-Vorgang wird verarbeitet.
 - Successfully write 0x0 bytes to handle.
 - Error writing command!
Drücken Sie eine beliebige Taste . . .
The Following User Says Thank You to thrash001 For This Useful Post: [ View ] Gift thrash001 Ad-Free
9th June 2017, 07:57 PM |#9  
munjeni's Avatar
OP Senior Member
Thanks Meter: 21,049
 
Donate to Me
More
Strange! Maybe run as admin is need?
The Following User Says Thank You to munjeni For This Useful Post: [ View ] Gift munjeni Ad-Free
9th June 2017, 07:58 PM |#10  
munjeni's Avatar
OP Senior Member
Thanks Meter: 21,049
 
Donate to Me
More
It would be great if tanipat debug newflasher with monitoring studio so I can compare whats going on? New version is out again.

Edit:
Curent version is safe so you no need to care for brick! Tool currently nothing write to internal mem! I will tell when it is ready for flashing! Now its just pre pre alpha version, only read from phone
The Following User Says Thank You to munjeni For This Useful Post: [ View ] Gift munjeni Ad-Free
9th June 2017, 08:14 PM |#11  
Member
Thanks Meter: 42
 
More
in the windows devicemanager is it correct as "SOMC Flash Device"
the next one:
Code:
--------------------------------------------------------
              newflasher.exe by Munjeni @ 2017
--------------------------------------------------------
Device path: \\?\usb#vid_0fce&pid_b00b#5&15c311e1&0&2#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
Class Description: USB-Controller
Device Instance Id: USB\VID_0FCE&PID_B00B\5&15C311E1&0&2

ERROR: TIMEOUT: failed with error code 997 as follows:
▄berlappender E/A-Vorgang wird verarbeitet.
 - Error write! Need nBytes: 0x18 but done: 0x0
 - Error writing command!
Drücken Sie eine beliebige Taste . . .
The Following 2 Users Say Thank You to thrash001 For This Useful Post: [ View ] Gift thrash001 Ad-Free
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes