-
Notifications
You must be signed in to change notification settings - Fork 36
/
split32bit.1
69 lines (69 loc) · 1.31 KB
/
split32bit.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
.Dd December 13, 2019
.Dt split32bit 1
.Os kk_ihex
.Sh NAME
.Nm split32bit
.Nd Splits a 32-bit ROM image into four 8-bit files.
.Sh SYNOPSIS
.Nm
.Op Fl i Ar input32bit.bin
.Op Fl 0 Ar out0.bin
.Op Fl 1 Ar out1.bin
.Op Fl 2 Ar out2.bin
.Op Fl 3 Ar out3.bin
.Sh DESCRIPTION
.Nm
reads a raw 32-bit binary file from standard input and writes four
separate output files, each containing separate 8-bit bytes that make
up each 32-bit input dword. The bytes are numbered from 0 to 3 by
address, i.e., the first byte of input is byte 0 (little endian).
.Sh OPTIONS
.Bl -tag -width -indent
.It Fl 0 Ar byte0file
Output to
.Ar byte0file
the first byte of every input word
.It Fl 1 Ar byte1file
Output to
.Ar byte1file
the second byte of every input word
.It Fl 2 Ar byte2file
Output to
.Ar byte2file
the third byte of every input word
.It Fl 3 Ar byte3file
Output to
.Ar byte3file
the fourth byte of every input word
.It Fl i Ar file
Read the binary input from
.Ar file
instead of standard input
.El
.Sh EXAMPLES
Read binary data from
.Ar be32.bin
and write the bytes to output files from
.Ar U1.bin
to
.Ar U4.bin
in big endian order:
.Pp
.Bd -ragged -offset indent
.Nm
.Fl i
.Ar be32.bin
.Fl 0
.Ar U4.bin
.Fl 1
.Ar U3.bin
.Fl 2
.Ar U2.bin
.Fl 3
.Ar U1.bin
.Ed
.Pp
.Sh SEE ALSO
.Xr merge32bit 1
.Sh AUTHOR
.An "Kimmo Kulovesi" Aq https://arkku.com