1srec_tektronix(5) File Formats Manual srec_tektronix(5)
2
3
4
6 srec_tektronix - Tektronix hexadecimal file format
7
9 The Tektronix hexadecimal file format is no longer very common. It
10 serves a similar purpose to the Motorola and Intel formats, usually
11 used to transfer data into EPROM programmers.
12
13 The Lines
14 Most Tektronix hex files contain only Tektronix hex lines (see the next
15 section), which always start with a slash (``/'') character. There are
16 only two types of lines - data lines and a termination line.
17
18 Data Lines
19 Data lines have five fields: address, length, checksum 1, data and
20 checksum 2. The lines always start with a slash (``/'') character.
21
22 ┌──┬─────────┬────────┬───────────┬──────┬───────────┐
23 │/ │ Address │ Length │ Checksum1 │ Data │ Checksum2 │
24 └──┴─────────┴────────┴───────────┴──────┴───────────┘
25 Address This is a 4 character (2 byte) address that specifies where the
26 data in the record is to be loaded into memory.
27
28 Data Length
29 The data length field is a 2 character (1 byte) field that
30 specifies the number of character pairs (bytes) in the data
31 field. This field never has a value of zero.
32
33 Checksum 1
34 The checksum 1 field is a 2 character (1 byte) field. Its
35 value is the 8-bit sum of the six 4-bit values which make up
36 the address and length fields.
37
38 Data The data field contains character pairs (bytes); the number of
39 character pairs (bytes) is indicated by the length field.
40
41 Checksum 2
42 The checksum 2 field is a 2 character (1 byte) field. Its
43 value is the least significant byte of the sum of the all the
44 4-bit values of the data field.
45
46 Termination Line
47 Termination lines have three fields: address, zero and checksum. The
48 lines always start with a slash (``/'') character.
49
50 ┌──┬─────────┬──────┬──────────┐
51 │/ │ Address │ Zero │ Checksum │
52 └──┴─────────┴──────┴──────────┘
53 Address This is a 4 character (2 byte) address that specifies where to
54 begin execution.
55
56 Zero The data length field is a 2 character (1 byte) field of value
57 zero.
58
59 Checksum
60 The checksum 1 field is a 2 character (1 byte) field. Its
61 value is the 8-bit sum of the six 4-bit values which make up
62 the address and zero fields.
63
64 Size Multiplier
65 In general, binary data will expand in sized by approximately 2.4 times
66 when represented with this format.
67
69 Here is an example Tektronix hex file. It contains the data ``Hello,
70 World'' to be loaded at address 0.
71 /00000D0D48656C6C6F2C20576F726C640A52
72 /00000000
73
75 srec_cat version 1.35
76 Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
77 2007 Peter Miller
78
79 The srec_cat program comes with ABSOLUTELY NO WARRANTY; for details use
80 the 'srec_cat -VERSion License' command. This is free software and you
81 are welcome to redistribute it under certain conditions; for details
82 use the 'srec_cat -VERSion License' command.
83
85 Peter Miller E-Mail: millerp@canb.auug.org.au
86 /\/\* WWW: http://www.canb.auug.org.au/~millerp/
87
88
89
90Reference Manual SRecord srec_tektronix(5)