User manual
V002450_25_CR1200-CR2-CR3-CR2500-CR3500_Interface_Configuration_Document_CLIENT.docx
2011-04-27 Page 55 of 65
© 2011 The Code Corporation
•
14870 S. Pony Express Rd., Suite 200, Bluffdale, UT 84065
•
(801) 495-2200
•
FAX (801) 495-0280
13 1,3,1,3,1,3,….
137 1,3,7,1,3,7,1,3,7,….
The checksum character itself always start with a weight of 1. As we move away from the checksum
towards the left, we update the weight value to the next member of the sequence. The sequences repeat
over and over until the first character in a row for a Row type checksum, and to the first character in the
template for a Block type checksum. The resulting sum is then divided by the Checksum Modulo
number of the checksum and the remainder of this division should be zero for a valid checksum.
For example, the following 2 line OCR-B template contains a mod 10 checksum with weight 1 (5) at the
end of each line along with a mod 36 block checksum with weight 13 (191) as the last character. There
are a total of 8 alphanumeric characters per line including the checksums:
1,2,7,7,7,7,7,7,7,13,5,2,7,7,7,7,7,7,13,5,13,191,0
12.4.14 Example OCR User Templates
This section gives some examples of valid OCR User Templates along with the OCR text they are
designed to read.
12.4.14.1 Multi_Row with Leading and Trailing Spaces
123456
ABCDEFG
The OCR-B text above is made up of two lines, the top being purely numeric and the bottom purely
alphabetic. Also, the second line is offset from the first by two spaces. The following template will read
this text:
1,2,5,5,5,5,5,5,2,32,32,6,6,6,6,6,6,6,0
Note the 2 following the 6 numeric wild card digits: this indicates that the template is inserting a new
line. Also of note are the leading two spaces on the second line. They must be explicitly indicated by
using the ASCII value of a space: decimal value 32. You may not use a wildcard or group to indicate
leading (or trailing) space. Finally, the trailing spaces on line 1 do not need to be explicitly entered into
the template. They are assumed to be there based on the number of character positions defined for the
row.
12.4.14.2 Row and Block Checksums
ABCD6
EFG5X
The two lines of OCR-B alphabetic text above both contain a row checksum. In addition, the last
character of row 2 is a block checksum. The 2 row checksums are mod 10 with a 13 weight (control