-
Notifications
You must be signed in to change notification settings - Fork 36
/
ihex2bin.1
78 lines (78 loc) · 1.78 KB
/
ihex2bin.1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
.Dd February 1, 2014
.Dt ihex2bin 1
.Os kk_ihex
.Sh NAME
.Nm ihex2bin
.Nd Convert Intel HEX encoded data to binary
.Sh SYNOPSIS
.Nm
.Op Fl a Ar address_offset | Fl A
.Op Fl i Ar input_file.hex
.Op Fl o Ar output_file.bin
.Op Fl v
.Sh DESCRIPTION
.Nm
reads Intel HEX encoded data from standard input and writes the
decoded binary data to standard output.
.Sh OPTIONS
.Bl -tag -width -indent
.It Fl a Ar address_offset
Set the address of the first byte output to
.Ar address_offset
- by default the beginning of the output is considered to be at address
0, which may cause large amounts of padding to be written if the input
data begins at an offset (e.g., a ROM address for flashing program images)
.It Fl A
Autodetect the address offset (see
.Ar -a
above), i.e., the first output byte written will have the address of the
first byte of input - this option should almost always be used!
.It Fl i Ar file
Read the Intel HEX input from
.Ar file
instead of standard input
.It Fl o Ar file
Write the binary output to
.Ar file
instead of standard output
.It Fl v
Print extra status messages to standard error
.El
.Sh EXAMPLES
Read Intel HEX from
.Ar input.hex
and write the binary output to
.Ar output.bin
such that the first byte of input is written as the first byte
of output (even if the input specifies an address offset):
.Pp
.Bd -ragged -offset indent
.Nm
.Fl A
.Fl i
.Ar input.hex
.Fl o
.Ar output.bin
.Ed
.Pp
Read Intel HEX from
.Ar input.hex
and write the binary output to
.Ar output.bin
such that the first byte of the output has address
.Ar 0x8000000
(the beginning of the output is padded if the input data begins
at a greater address):
.Bd -ragged -offset indent
.Nm
.Fl a
.Ar 0x8000000
.Fl i
.Ar input.hex
.Fl o
.Ar output.bin
.Ed
.Sh SEE ALSO
.Xr bin2ihex 1
.Sh AUTHOR
.An "Kimmo Kulovesi" Aq https://arkku.com