HOME

TheInfoList



OR:

Tektronix hex format (TEK HEX) and Extended Tektronix hex format (EXT TEK HEX or XTEK) / Extended Tektronix Object Format are
ASCII ASCII ( ), abbreviated from American Standard Code for Information Interchange, is a character encoding standard for electronic communication. ASCII codes represent text in computers, telecommunications equipment, and other devices. Because ...
-based
hexadecimal In mathematics and computing, the hexadecimal (also base-16 or simply hex) numeral system is a positional numeral system that represents numbers using a radix (base) of 16. Unlike the decimal system representing numbers using 10 symbols, h ...
file format A file format is a Computer standard, standard way that information is encoded for storage in a computer file. It specifies how bits are used to encode information in a digital storage medium. File formats may be either proprietary format, pr ...
s, created by
Tektronix Tektronix, Inc., historically widely known as Tek, is an American company best known for manufacturing test and measurement devices such as oscilloscopes, logic analyzers, and video and mobile test protocol equipment. Originally an independent ...
, for conveying binary information for applications like programming
microcontroller A microcontroller (MCU for ''microcontroller unit'', often also MC, UC, or μC) is a small computer on a single VLSI integrated circuit (IC) chip. A microcontroller contains one or more CPUs ( processor cores) along with memory and programma ...
s,
EPROM An EPROM (rarely EROM), or erasable programmable read-only memory, is a type of programmable read-only memory (PROM) chip that retains its data when its power supply is switched off. Computer memory that can retrieve stored data after a power ...
s, and other kinds of chips. Each line of a Tektronix hex file starts with a slash (/) character, whereas extended Tektronix hex files start with a percent (%) character.


Tektronix hex format

A line consists of four parts, excluding the initial '/' character: # ''Address'' — 4 character (2 byte) field containing the address where the data is to be loaded into memory. This limits the address to a maximum value of FFFF16. # ''Byte count'' — 2 character (1 byte) field containing the length of the data fields. # ''Prefix checksum'' — 2 character (1 byte) field containing the
checksum A checksum is a small-sized block of data derived from another block of digital data for the purpose of detecting errors that may have been introduced during its transmission or storage. By themselves, checksums are often used to verify dat ...
of the prefix. The prefix checksum is the 8-bit sum of the four-bit hexadecimal value of the six digits that make up the address and byte count. # ''Data'' -- contains the data to be transferred, followed by a 2 character (1 byte) checksum. The data checksum is the 8-bit sum, modulo 256, of the 4-bit hexadecimal values of the digits that make up the data bytes.


Extended Tektronix hex format

A line consists of five parts, excluding the initial '%' character: # ''Record Length'' — 2 character (1 byte) field that specifies the number of characters (not bytes) in the record, excluding the percent sign. # ''Type'' — 1 character field, specifies whether the record is data (6) or termination (8). (6 record contains data, placed at the address specified. 8 termination record: The address field may optionally contain the address of the instruction to which control is passed ; there is no data field.) # ''Checksum'' — 2 hex digits (1 byte, represents the sum of all the nibbles on the line, excluding the checksum itself. # ''Address'' — 2 to N character field. The first character is how many characters are to follow for this field. The remaining characters contains the address that specifies where the data is to be loaded into memory. For example, if the first character is 8, then the following 8 characters should specify the address for a total of 9 characters in this field. # ''Data'' — contains the executable code, memory-loadable data or descriptive information to be transferred.


See also

*
Binary-to-text encoding A binary-to-text encoding is encoding of data in plain text. More precisely, it is an encoding of binary data in a sequence of printable characters. These encodings are necessary for transmission of data when the channel does not allow binary dat ...
, a survey and comparison of encoding algorithms *
Intel hex format Intel hexadecimal object file format, Intel hex format or Intellec Hex is a file format that conveys binary information in ASCII text form. It is commonly used for programming microcontrollers, EPROMs, and other types of programmable logic devi ...
*
MOS Technology file format The MOS Technology file format is a file format that conveys binary information in ASCII text form. History The KIM-1 single-board computer specified a file format for magnetic tape and a format for paper tape. The paper tape format was ad ...
*
Motorola S-record hex format Motorola S-record is a file format, created by Motorola in the mid-1970s, that conveys binary information as hex values in ASCII text form. This file format may also be known as SRECORD, SREC, S19, S28, S37. It is commonly used for programm ...


References


Further reading

* *

* *

(56 pages) *


External links


SRecord
is a collection of tools for manipulating hex format files, including both Tektronix formats {{Tektronix Binary-to-text encoding formats Embedded systems Computer file formats