校验域(Checksum Field) 校验域在记录中占用 2 个字符位置,其值为字节数域开始到数据域结束所有十六进制数对的校验值。 校验值的计算方法为从字节数域开始到数据域结束所有十六进制数对之和的最低有效字节的取反(the least significant byte of the ones complement of the sum of the byte values represented by the pairs of characters making up the count, the address, and the data fields)。 例如一个 S3 记录如下 S309610088046C880061B4 则 S3 记录的 checksum 的计算方法如下 checksum = FF - (09 + 61 + 00 + 88 + 04 + 6C + 88 + 00 + 61) && 0xFF = B4