New: XDA launches forum for app developers. Discuss coding, tools, marketing, and more.
XDA Developers Android and Mobile Development Forum
Forgot your password?
THREAD CLOSED
Tip us?
 
pof
Old
(Last edited by pof; 13th June 2008 at 09:54 AM.)
#1  
pof's Avatar
Retired Moderator - OP
Thanks Meter 37
Posts: 3,562
Join Date: Mar 2005
Location: Barcelona

 
DONATE TO ME
Default HERMflasher: Open source RUU for HTC Hermes devices

Are you a Linux user tired of rebooting into Window$ to flash your device? Now you can flash your Hermes under Linux using HERMflasher: the first open source Rom Upgrade Utility for HTC Hermes devices.

Features:
  • Flash NBH files
  • Flash raw (*.nb) radio rom files
  • Dump radio rom
  • Serial prompt (replaces mtty/minicom)

Usage:
Code:
 
# ./hermflasher -h
=== XDA-Developers HERMFlasher v1.0 by pof
=== Open source RUU for HTC Hermes devices

Usage: hermflasher [options]
 options:
  -F [radio|nbh] [filename]  flash radio or nbh file
  -r [filename]    dump radio rom
  -s [device]      uses another serial device (/dev/ttyUSB0)
  -i               get device info
  -v               verbose mode
  -p               enter serial prompt (minicom like)
  -d               show debug information
  -h               shows this help message

Why did you wrote this tool?
warrio sent me his bricked SPV M3100, I found it was hanging when the RUU issued a command which required checking security (info 2, info3, task 32, etc...) but radio bootloader was responsive, so to unbrick it I needed a RUU which did not authenticate to normal bootloader prior to flashing radio through 'rtask a'. When it successfully flashed a radio, I thought I could enhance it to flash nbh files also.

Is it safe?
It has been extensively tested with several NBH files and GSM.nb files, with bootloader 1.04 and Des SSPL 1.09, never bricked a device and unbricked one but... use it at your own risk

Can it be used in other devices?
NBH flashing is only valid for hermes bootloaders (uses 'wdatah' command) but should be easily ported to other devices such as Trinity or Artemis, if I have some time I will probably port it in the future, otherwise feel free to port it yourself.
Radio flashing and dumping will most probably work out of the box on other devices such as Universal and Magician, but I haven't tested it. Again if I have time I will try to make it more generic so it can be used on other devices too, but now it only supports Hermes.

Will it work on other operating systems?
I've only tested it on GNU/Linux... I'm not a good programmer nor a Unix guru, so feel free to send patches if you port it to other device or OS.


Zip file attached to this post contains source code & GPL license (must be logged in to download).

Enjoy!

[+]------------------------------------------------------------------------------------------------------[+]

THREAD CLOSED, GET THE NEW VERSION HERE:

http://forum.xda-developers.com/showthread.php?t=399762

[+]------------------------------------------------------------------------------------------------------[+]
Attached Files
File Type: zip HERMflasher.zip - [Click for QR Code] (26.1 KB, 8094 views)
Caution: reading THE WIKI may be hazardous to your health!
 
cyberdrakula
Old
#2  
cyberdrakula's Avatar
Senior Member
Thanks Meter 0
Posts: 291
Join Date: Oct 2005
Location: New York
POf, you are amazing.
Hell is what you want it 2 B,
4 me, it just might B heaven!
 
richy240
Old
#3  
richy240's Avatar
Senior Member
Thanks Meter 0
Posts: 308
Join Date: Jun 2006
Location: H-Town, sucka!
Yeah dude, I don't use Linux that often, but this is awesome!
Here I am, rock you like a hurricane.
 
joej
Old
#4  
Senior Member
Thanks Meter 1
Posts: 234
Join Date: Dec 2006
Pof you rock!
 
dutty
Old
#5  
Senior Member
Thanks Meter 20
Posts: 501
Join Date: Apr 2004
good job!

dutty's good NBH Tool - unpacks/packs any NBH file!
the rom koch v2
WM6 Premium v2 - the most definite wm6 release
 
lpsi2000
Old
#6  
lpsi2000's Avatar
Senior Member
Thanks Meter 93
Posts: 2,291
Join Date: Jan 2004
Location: TriState
Oh yeah Pof, this is a dream come true. U R the man!!! then again you were the man before this tool

Thanks, and great job.
AT&T Samsung Galaxy Note II(i317)
Previous devices:
Samsung Galaxy S II & III
Retired devices: AT&T Samsung Galaxy Note / Moto Atrix and SGS Captivate / HTC Leo(HD2) / AT&T Tilt 2/ HTC Fuze / HTC Advantage / I-Mate JasJam / JasJar / Pocket PC / XDA
SAMSUNG CAPTIVATE AND T-MOBILE HD2 FOR SALE, PM ME IF YOUR ARE INTERESTED.

Network: AT&T
Tweaked TW JB 4.1.2
Ported ROMS
825/850/875/900/925/950/975/s100/1025/1050/1075/1100/1125/1150/1200/1250/1275 -1800Mzh
 
zegizengi
Old
(Last edited by pof; 28th March 2007 at 09:37 AM.) Reason: removed big quote text
#7  
Junior Member
Thanks Meter 0
Posts: 6
Join Date: Mar 2007
how can i use thr hermflasher in windows plz
plz help me step by step
 
MegaHz
Old
(Last edited by pof; 4th April 2007 at 09:26 AM.) Reason: added code tags
#8  
MegaHz's Avatar
Senior Member
Thanks Meter 11
Posts: 261
Join Date: Jul 2005
Location: Nicosia

 
DONATE TO ME
Exclamation hermflasher on bricked hermes

hello,
I tried to run:./flasher -v -d -F nbh HERMIMG_IPL1.01_SPL1.04_ONLY.nbh
on my bricked hermes and got:

Code:
------------------------------------------------
=== XDA-Developers HERMFlasher v1.1 by pof
=== Open source RUU for HTC Hermes devices

[] verbose mode enabled
[] debug mode enabled
Flash nbh file: HERMIMG_IPL1.01_SPL1.04_ONLY.nbh

SEND: 

GET: 0:  - d
1: 
 - a



SEND: set 5 7777
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: s - 73
5: e - 65
6: t - 74
7:   - 20
8: 5 - 35
9:   - 20
10: 7 - 37
11: 7 - 37
12: 7 - 37
13: 7 - 37
14:  - d
15: 
 - a

GET: USB>set 5 7777

SEND: set 2 1
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: s - 73
5: e - 65
6: t - 74
7:   - 20
8: 2 - 32
9:   - 20
10: 1 - 31
11:  - d
12: 
 - a

GET: USB>set 2 1

SEND: set 6 FFFF
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: s - 73
5: e - 65
6: t - 74
7:   - 20
8: 6 - 36
9:   - 20
10: F - 46
11: F - 46
12: F - 46
13: F - 46
14:  - d
15: 
 - a

GET: USB>set 6 FFFF

SEND: shmsg 4 3 "XDA-Developers"
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: s - 73
5: h - 68
6: m - 6d
7: s - 73
8: g - 67
9:   - 20
10: 4 - 34
11:   - 20
12: 3 - 33
13:   - 20
14: " - 22
15: X - 58
16: D - 44
17: A - 41
18: - - 2d
19: D - 44
20: e - 65
21: v - 76
22: e - 65
23: l - 6c
24: o - 6f
25: p - 70
26: e - 65
27: r - 72
28: s - 73
29: " - 22
30:  - d
31: 
 - a

GET: USB>shmsg 4 3 "XDA-Developers"

SEND: shmsg 5 3 "HERMFlasher 1.1"
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: s - 73
5: h - 68
6: m - 6d
7: s - 73
8: g - 67
9:   - 20
10: 5 - 35
11:   - 20
12: 3 - 33
13:   - 20
14: " - 22
15: H - 48
16: E - 45
17: R - 52
18: M - 4d
19: F - 46
20: l - 6c
21: a - 61
22: s - 73
23: h - 68
24: e - 65
25: r - 72
26:   - 20
27: 1 - 31
28: . - 2e
29: 1 - 31
30: " - 22
31:  - d
32: 
 - a

GET: USB>shmsg 5 3 "HERMFlasher 1.1"

SEND: shmsg 6 3 "by pof"
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: s - 73
5: h - 68
6: m - 6d
7: s - 73
8: g - 67
9:   - 20
10: 6 - 36
11:   - 20
12: 3 - 33
13:   - 20
14: " - 22
15: b - 62
16: y - 79
17:   - 20
18: p - 70
19: o - 6f
20: f - 66
21: " - 22
22:  - d
23: 
 - a

GET: USB>shmsg 6 3 "by pof"

SEND: shmsg 10 2 "FLASH NBH"
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: s - 73
5: h - 68
6: m - 6d
7: s - 73
8: g - 67
9:   - 20
10: 1 - 31
11: 0 - 30
12:   - 20
13: 2 - 32
14:   - 20
15: " - 22
16: F - 46
17: L - 4c
18: A - 41
19: S - 53
20: H - 48
21:   - 20
22: N - 4e
23: B - 42
24: H - 48
25: " - 22
26:  - d
27: 
 - a

GET: USB>shmsg 10 2 "FLASH NBH"

SEND: info 3
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: i - 69
5: n - 6e
6: f - 66
7: o - 6f
8:   - 20
9: 3 - 33
10:  - d
11: 
 - a
12: H - 48
13: T - 54
14: C - 43
15: S - 53
16: H - 48
17:   - 0
....
....
....
2138:   - 0
2139:   - 0
2140:   - 0
2141:   - 0
2142:   - 0
2143:   - 0
2144: ž - ffffff9e
2145: — - ffffff97
2146: ν - ffffffed
2147: Ψ - ffffffd8
2148: H - 48
2149: T - 54
2150: C - 43
2151: E - 45

GET: USB>info 3
HTCSH E R M 2 0 0                                                                                                                                                                                    Œ                                                           ?³Ϊ6ιiPΤNΌ―³σ€_Ϋ²…xMρV˜š®Χ .                                                                                                                                                                                      A       P  P      A                                     H                               1.09                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            ž—νΨHTCbuffer[0]=?
buffer[1]=³
buffer[2]=
buffer[3]=Ϊ
buffer[4]=6
buffer[5]=ι
buffer[6]=i
buffer[7]=P
buffer[8]=Τ
buffer[9]=N
buffer[10]=Ό
buffer[11]=
buffer[12]=―
buffer[13]=³
buffer[14]=σ
buffer[15]=€
buffer[16]=_
buffer[17]=Ϋ
buffer[18]=
buffer[19]=²
buffer[20]=…
buffer[21]=x
buffer[22]=M
buffer[23]=ρ
buffer[24]=
buffer[25]=V
buffer[26]=˜
buffer[27]=š
buffer[28]=®
buffer[29]=Χ
buffer[30]= 
buffer[31]=.

SEND: password ~e~I00|~~~00~000
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: p - 70
5: a - 61
6: s - 73
7: s - 73
8: w - 77
9: o - 6f
10: r - 72
11: d - 64
12:   - 20
13: ~ - 7e
14: e - 65
15: ~ - 7e
16: I - 49
17: 0 - 30
18: 0 - 30
19: | - 7c
20: ~ - 7e
21: ~ - 7e
22: ~ - 7e
23: 0 - 30
24: 0 - 30
25: ~ - 7e
26: 0 - 30
27: 0 - 30
28: 0 - 30
29:  - d
30: 
 - a

GET: USB>password ~e~I00|~~~00~000
0: H - 48
1: T - 54
2: C - 43
3: S - 53
4: P - 50
5: a - 61
6: s - 73
7: s - 73
8: 1 - 31
9: . - 2e
10: 
 - a
11: C - 43
12: M - 4d
13: ˆ - ffffff88
14: Λ - ffffffcb
15: H - 48
16: T - 54
17: C - 43
18: E - 45

GET: HTCSPass1.
CMˆΛHTCAuthenticated OK

SEND: set 1 0
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: s - 73
5: e - 65
6: t - 74
7:   - 20
8: 1 - 31
9:   - 20
10: 0 - 30
11:  - d
12: 
 - a

GET: USB>set 1 0
[K   0% [----------------------------------------------------------------------]
SEND: shmsg 11 4 "000% [----------------]"
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: s - 73
5: h - 68
6: m - 6d
7: s - 73
8: g - 67
9:   - 20
10: 1 - 31
11: 1 - 31
12:   - 20
13: 4 - 34
14:   - 20
15: " - 22
16: 0 - 30
17: 0 - 30
18: 0 - 30
19: % - 25
20:   - 20
21: [ - 5b
22: - - 2d
23: - - 2d
24: - - 2d
25: - - 2d
26: - - 2d
27: - - 2d
28: - - 2d
29: - - 2d
30: - - 2d
31: - - 2d
32: - - 2d
33: - - 2d
34: - - 2d
35: - - 2d
36: - - 2d
37: - - 2d
38: ] - 5d
39: " - 22
40:  - d
41: 
 - a

GET: USB>shmsg 11 4 "000% [----------------]"

SEND: set 1e 1
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: s - 73
5: e - 65
6: t - 74
7:   - 20
8: 1 - 31
9: e - 65
10:   - 20
11: 1 - 31
12:  - d
13: 
 - a

GET: USB>set 1e 1

SEND: wdatah 6065f 8ae5ffd7
0: U - 55
1: S - 53
2: B - 42
3: > - 3e
4: w - 77
5: d - 64
6: a - 61
7: t - 74
8: a - 61
9: h - 68
10:   - 20
11: 6 - 36
12: 0 - 30
13: 6 - 36
14: 5 - 35
15: f - 66
16:   - 20
17: 8 - 38
18: a - 61
19: e - 65
20: 5 - 35
21: f - 66
22: f - 66
23: d - 64
24: 7 - 37
25:  - d
26: 
 - a

GET: USB>wdatah 6065f 8ae5ffd7

GET: 0: : - 3a
:1: w - 77
w2: d - 64
d3: a - 61
a4: t - 74
t5: a - 61
a6: h - 68
h7: = - 3d
=8:  - d
9:   - 20
 10:  - 8
11: : - 3a
:12: L - 4c
L13: = - 3d
=14: 0 - 30
015: 0 - 30
016: 0 - 30
017: 6 - 36
618: 0 - 30
019: 6 - 36
620: 5 - 35
521: F - 46
F22:  - d
23:   - 20
 24:  - 8


SEND: HTCS

SEND: HTCE
0: I - 49
1: m - 6d
2: a - 61
3: g - 67
4: e - 65
5:   - 20
6: C - 43
7: e - 65
8: r - 72
9: t - 74
10:   - 20
11: i - 69
12: s - 73
13:   - 20
14: e - 65
15: r - 72
16: r - 72
17: o - 6f
18: r - 72
19:  - d
20:  - d
21: 
 - a
22: C - 43
23: l - 6c
24: e - 65
25: a - 61
26: r - 72
27:   - 20
28: N - 4e
29: B - 42
30: H - 48
31:   - 20
32: t - 74
33: a - 61
34: g - 67
35:  - d
36:  - d
37: 
 - a
38: W - 57
39: r - 72
40: i - 69
41: t - 74
42: e - 65
43:   - 20
44: N - 4e
45: a - 61
46: n - 6e
47: d - 64
48:   - 20
49: S - 53
50: u - 75
51: c - 63
52: c - 63
53: e - 65
54: s - 73
55: s - 73
56:  - d
57:  - d
58: 
 - a
59: H - 48
60: T - 54
61: C - 43
62: S - 53
63:  - 2
64: € - ffffff80
65:  - 6
66:   - 0
67:  - ffffff8d
68: t - 74
69: f - 66
70:  - 1d
71: H - 48
72: T - 54
73: C - 43
74: E - 45

GET: Image Cert is error
Clear NBH tag
Write Nand Success
HTCS€ tfHTCImage Cert is error
Clear NBH tag
Write Nand Success
HTCS€
------------------------------------------------
what does this mean?
please help

thanks

-- Andreas
 
pof
Old
#9  
pof's Avatar
Retired Moderator - OP
Thanks Meter 37
Posts: 3,562
Join Date: Mar 2005
Location: Barcelona

 
DONATE TO ME
Quote:
Originally Posted by MegaHz View Post
what does this mean?
You're using a file signed with a non-htc certificate on a htc bootloader which only accepts htc signed files.
Caution: reading THE WIKI may be hazardous to your health!
 
MegaHz
Old
#10  
MegaHz's Avatar
Senior Member
Thanks Meter 11
Posts: 261
Join Date: Jul 2005
Location: Nicosia

 
DONATE TO ME
can you please point me to an htc signed file?
THREAD CLOSED
Subscribe

XDA PORTAL POSTS

What’s Possible with CASUAL & How to Make Your Own CASUAL – XDA Developer TV

XDA Elite Recognized Developer AdamOutler is known … more

Pearl Chen to Talk NFC Development at XDA:DevCon 2013

From HTML to LEDs or Android to Arduino, Hardware Hacking is a pastime of many people … more

Avoid Framework Bootloops on Xperias Running Jelly Bean

If you’re a Sony device owner running a stock Android Jelly Bean firmware and … more

Forum Added for the Samsung Galaxy Mega

What do you do when the Galaxy Note line is simply not big enough? You get theSamsung Galaxy Mega. … more