Androxyde / Flashtool

Xperia device flashing
GNU General Public License v3.0
481 stars 245 forks source link

Cannot flash orig fw to castor_windy (xperia z2 tablet) #69

Closed murdegern closed 7 years ago

murdegern commented 7 years ago

Hello,

thanks for writing flashtool. It worked fine for me earlier. Now, I hit a snag with my z2 tablet, though. I fetched the ftf with the embedded XperiFirm. When flashing, it fails like

04/041/2017 11:41:09 - ERROR - (X10flash.java:735) - null 04/041/2017 11:41:10 - ERROR - (X10flash.java:736) - Error flashing. Aborted

Help is very much appreciated. Regards, Torsten

More Logs (debug mode):

04/041/2017 11:41:06 - INFO  - (X10flash.java:979) - Phone ready for flashmode operations.
04/041/2017 11:41:06 - INFO  - (X10flash.java:424) - Opening TA partition 2
04/041/2017 11:41:06 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 9 / Flags : false,true,false / Data length : 1 / Data CRC32 : EE 0E 61 2C
04/041/2017 11:41:06 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:06 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 9 / Flags : false,false,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:06 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 12 / Flags : false,true,false / Data length : 4 / Data CRC32 : F0 01 48 CC
04/041/2017 11:41:06 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:06 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 12 / Flags : false,false,false / Data length : 29 / Data CRC32 : 28 10 5B 3F
04/041/2017 11:41:06 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 12 / Flags : false,true,false / Data length : 4 / Data CRC32 : 5D EC A5 43
04/041/2017 11:41:06 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:06 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 12 / Flags : false,false,false / Data length : 10 / Data CRC32 : 38 62 07 98
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 12 / Flags : false,true,false / Data length : 4 / Data CRC32 : 46 67 65 F1
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 12 / Flags : false,false,false / Data length : 29 / Data CRC32 : 28 10 5B 3F
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 12 / Flags : false,true,false / Data length : 4 / Data CRC32 : D8 03 F0 52
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 12 / Flags : false,false,false / Data length : 29 / Data CRC32 : 28 10 5B 3F
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 12 / Flags : false,true,false / Data length : 4 / Data CRC32 : DF 6E 34 4B
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 12 / Flags : false,false,false / Data length : 20 / Data CRC32 : A6 B3 91 2F
04/041/2017 11:41:07 - INFO  - (X10flash.java:575) - Current device : Unknown: Jul 24 2016/19:28:59 - CB5126MJL1 - Unknown: Jul 24 2016/19:28:59 - Unknown: Jul 24 2016/19:28:59 - GENERIC_23.5.A.1.291
04/041/2017 11:41:07 - INFO  - (X10flash.java:433) - Closing TA partition
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 10 / Flags : false,true,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 10 / Flags : false,false,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:07 - INFO  - (X10flash.java:707) - Start Flashing
04/041/2017 11:41:07 - INFO  - (X10flash.java:306) - Processing loader.sin
04/041/2017 11:41:07 - INFO  - (X10flash.java:288) -     Checking header
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 5 / Flags : false,true,false / Data length : 1024 / Data CRC32 : 36 03 01 69
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:07 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 5 / Flags : false,false,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:07 - INFO  - (X10flash.java:308) -     Flashing data
04/041/2017 11:41:07 - DEBUG - (X10flash.java:309) - Number of parts to send : 5 / Part size : 65536
04/041/2017 11:41:07 - DEBUG - (X10flash.java:313) - Sending part 1 of 5
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 6 / Flags : false,true,true / Data length : 65536 / Data CRC32 : D2 71 96 91
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 6 / Flags : false,false,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:08 - DEBUG - (X10flash.java:313) - Sending part 2 of 5
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 6 / Flags : false,true,true / Data length : 65536 / Data CRC32 : ED 26 11 58
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 6 / Flags : false,false,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:08 - DEBUG - (X10flash.java:313) - Sending part 3 of 5
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 6 / Flags : false,true,true / Data length : 65536 / Data CRC32 : 68 81 29 68
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 6 / Flags : false,false,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:08 - DEBUG - (X10flash.java:313) - Sending part 4 of 5
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 6 / Flags : false,true,true / Data length : 65536 / Data CRC32 : 9F CC 4E 82
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 6 / Flags : false,false,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:08 - DEBUG - (X10flash.java:313) - Sending part 5 of 5
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 6 / Flags : false,true,false / Data length : 8428 / Data CRC32 : B6 6F C4 1F
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 6 / Flags : false,false,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:08 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:09 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 1 / Flags : false,false,false / Data length : 1159 / Data CRC32 : EE D3 C9 05
04/041/2017 11:41:09 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 1 / Flags : false,true,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:09 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:09 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 1 / Flags : false,false,false / Data length : 1159 / Data CRC32 : EE D3 C9 05
04/041/2017 11:41:09 - DEBUG - (X10flash.java:942) - PROT_VER="04";VER="MSM8974AB_27";ID="1277-2052";TYPE="S1_LOADER";ACTIVE_COMP_AID="0004";MAX_PKT_SZ="00080000";IGNORE_CRC="HDR,DATA";DEF_SEC="ON";HWCONF_AID="0004";LOADER_AID="0004";BOOT_AID="0004";NO_SUB_SYSTEMS="0001";OTP_DATA_1="01000400";OTP_LOCK_STATUS_1="LOCKED";UNIQUE_DEV_ID_1="0633B315";IDCODE_1="107BB0E1";S1_ROOT="S1_Root_9c84,S1_Root_Test_b316";HW_CONFIG_VER="0006";HW_CONFIG_INFO="HWC_Shinano_Com_003";SEC_STATE="HWC_Shinano_Com_003";IMEI="11003000026550";PROD_ID="0001";GLOB_SEC="0000";PHONE_ID="0000:11003000026550";HW_CONFIG="S1_Boot:0004:0013,S1_Loader:0004:000B,S1_SW:0005:0013,S1_RPMFW:0005:0013,S1_Cust:0004:0013,S1_ELabel:0004:0013,S1_SL:0004:0043,S1_ModemOS2:0005:0023,S1_ModemSW:0005:0013,S1_FOTA:0005:0023,S1_RIC:0005:0123,S1_HexagonSW2:0005:0023,S1_GPS2:0005:0023,S1_RIVA2:0005:0023,S1_Video2:0005:0023,S1_SDI2:0005:0023,S1_ETS:0005:0013,S1_RAMETS:0005:000B,S1_TZExec2:0005:00A3,S1_RLock:0004:0223";AUTH_LEVEL="NONE";AUTH_MET="0001";MEMDEVS="03:00:0011:0100:0000:03A3E000:00000400:00000200";PLF_ROOT_1="573BA40C7848CC15D672D2ECB560B257CE58FC364B00874BF31973E733339F7C";RAM_INFO="0103005B:0103005B:0103001B:0103001B";CARD_PRESENT="NO";
04/041/2017 11:41:09 - DEBUG - (X10flash.java:949) - After loader command reply (hook) : PROT_VER="04";VER="MSM8974AB_27";ID="1277-2052";TYPE="S1_LOADER";ACTIVE_COMP_AID="0004";MAX_PKT_SZ="00080000";IGNORE_CRC="HDR,DATA";DEF_SEC="ON";HWCONF_AID="0004";LOADER_AID="0004";BOOT_AID="0004";NO_SUB_SYSTEMS="0001";OTP_DATA_1="01000400";OTP_LOCK_STATUS_1="LOCKED";UNIQUE_DEV_ID_1="0633B315";IDCODE_1="107BB0E1";S1_ROOT="S1_Root_9c84,S1_Root_Test_b316";HW_CONFIG_VER="0006";HW_CONFIG_INFO="HWC_Shinano_Com_003";SEC_STATE="HWC_Shinano_Com_003";IMEI="11003000026550";PROD_ID="0001";GLOB_SEC="0000";PHONE_ID="0000:11003000026550";HW_CONFIG="S1_Boot:0004:0013,S1_Loader:0004:000B,S1_SW:0005:0013,S1_RPMFW:0005:0013,S1_Cust:0004:0013,S1_ELabel:0004:0013,S1_SL:0004:0043,S1_ModemOS2:0005:0023,S1_ModemSW:0005:0013,S1_FOTA:0005:0023,S1_RIC:0005:0123,S1_HexagonSW2:0005:0023,S1_GPS2:0005:0023,S1_RIVA2:0005:0023,S1_Video2:0005:0023,S1_SDI2:0005:0023,S1_ETS:0005:0013,S1_RAMETS:0005:000B,S1_TZExec2:0005:00A3,S1_RLock:0004:0223";AUTH_LEVEL="NONE";AUTH_MET="0001";MEMDEVS="03:00:0011:0100:0000:03A3E000:00000400:00000200";PLF_ROOT_1="573BA40C7848CC15D672D2ECB560B257CE58FC364B00874BF31973E733339F7C";RAM_INFO="0103005B:0103005B:0103001B:0103001B";CARD_PRESENT="NO";
04/041/2017 11:41:09 - INFO  - (X10flash.java:950) - Loader : S1_Root_9c84 - Version : MSM8974AB_27 / Boot version : S1_Boot_MSM8974AB_LA2.0.1_23_generic_5 / Bootloader status : ROOTED
04/041/2017 11:41:09 - INFO  - (X10flash.java:385) - Max packet size set to 512K
04/041/2017 11:41:09 - INFO  - (X10flash.java:397) - USB buffer size set to 512K
04/041/2017 11:41:09 - INFO  - (X10flash.java:442) - Parsing boot delivery
04/041/2017 11:41:09 - INFO  - (X10flash.java:910) - Ending flash session
04/041/2017 11:41:09 - DEBUG - (USBFlashLinux.java:57) - OUT : CommandID : 4 / Flags : false,true,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:09 - DEBUG - (USBFlashLinux.java:75) - Reading packet from phone
04/041/2017 11:41:09 - DEBUG - (USBFlashLinux.java:81) - IN : CommandID : 4 / Flags : false,false,false / Data length : 0 / Data CRC32 : 00 00 00 00
04/041/2017 11:41:09 - ERROR - (X10flash.java:735) - null
04/041/2017 11:41:10 - ERROR - (X10flash.java:736) - Error flashing. Aborted
04/041/2017 11:41:10 - INFO  - (MainSWT.java:158) - Device connected in flash mode
04/041/2017 11:41:10 - INFO  - (MainSWT.java:154) - Device disconnected
murdegern commented 7 years ago

got a little further now. The problem seems to be that FlashTool cannot identify the device (I have to pick SGP5XX from the "Device Selector" on every start). Asking to "permanently" identify it is, well, not permanent (menu appears again next time, though ~/.flashTool/devices/SGP5XX/SGP5XX.properties was rewritten)

So when I enter flash mode, the device is again unknown, Devices.getDeviceFromVariant(getCurrentDevice()) will return a null pointer, and dev.isFlashScriptMandatory() will bomb with an NPE.

I'd love to kludge it (hard-code the model or something), but compiling the git version didn't work for me either: Error: Could not find or load main class gui.Main, x10flasher.jar is only 808 byte.

murdegern commented 7 years ago

Got it to compile with eclipse, kludged detection out (tablet id came as "castor_windy", not "SGP512" or alike).