71M6521 Demo Board User’s Manual
Revision 2.18
© 2005-2009 TERIDIAN Semiconductor Corporation
Page: 23 of 111
Field
Name
Characters Description
1
Start code
1
An ASCII colon (":")
2
Byte count
2
The count of the character pairs in the data field.
3
Address
4
The 2-byte address at which the data field is to be loaded into
memory. This is the physical XRAM or I/O RAM address, not
the 4-byte address used by the command-line interface (CLI).
4
Type
2
00, 01, or 02.
5
Data
0-2n
From 0 to n bytes of executable code, or memory loadable
data.
n is normally 20 hex (32 decimal) or less.
6
Checksum
2
The least significant byte of the two's complement sum of the
values represented by all the pairs of characters in the record
except the start code and checksum.
Table 1-7: Fields of a Hex Record
Each record may be terminated with a CR/LF/NULL character. Accuracy of transmission is ensured by the
byte count and checksum fields. This is important when series of values such as calibration constants are
transmitted to a meter, e.g. by ATE equipment in a factory setting. When entering hex records manually, the
user may also choose “FF” (“wild card”) as the checksum. In this case, the Demo Code omits comparing the
checksum with the received record(s).
This is how the checksum is calculated manually (if necessary):
1) The hex values of all bytes (except start code and checksum itself) are added up.
2) The last two hex digits are subtracted from 0xFF.
3) The value 0x01 is added.
As opposed to the standardized Hex-records that offer three possible types (data, termination, segment
base), six different types are supported for communicating with the 71M6521BE and 71M6521DE Demo
Codes. These data types basically encode command types (read/write) along with the data source or
destination, as listed in Table 1-8.