codabar-2

Details on the codabar-2 bar code type.

Codabar 2 can be used to encode text of variable length by using characters from this character set:

Table 1. Character set for Codabar 2
Reference Number Character
0 0
1 1
2 2
3 3
4 4
5 5
6 6
7 7
8 8
9 9
10 -
11 $
12 :
13 /
14 .
15 +
16 a
17 b
18 c
19 d

The first and the last character of any code must be either 'a', 'b', 'c' or 'd'. All other characters must have an ordinal value less than 16.

The last but one character is the checksum character that is calculated as follows:CS=16-(Sum(i=1 to n of Ref(i))) mod 16) where Ref(i) is the reference number of the character i, and n is the total number of characters. Example: codeValue="a37859b"CS=16-((16+3+7+8+5+9+17) mod 16),CS=16-(65 mod 16),CS=15 Looking up reference number 15 yields the character '+'. The full code value including checksum is therefore: codeValue="a37859+b"

When the system is supplied with a value that is one digit shorter than specified by noDigits then the check digit is calculated automatically.

The nominal height is 20mm. The nominal width of a thin bar is THINBARWIDTH=0.165mm. The width of a thick bar is THICKBARWIDTH=THINBARWIDTH/ thinToThickRelation where thinToThickRelation should take values between1/3 and1/2. Between digits a gap having the width GAPWIDTH=THINBARWIDTH/ thinToGapRelationis drawn. The padding on both sides measures 10*THINBARWIDTH.

The "American Blood Commission" defines a code type known as Codabar-ABC. There are two types of Codabar-ABC codes that can both be built using the Codabar 2 bar code type:

Single bar Codabar-ABC - this type is identical with Codabar 2, the constraint being that values have to be at least 5 digits long.

Dual bar Codabar-ABC - This type can be printed by printing two Codebar 2 horizontally adjacent to each other. The gap between the two bars should not exceed 15mm. Additionally the code of the first bar must end with a 'd' character while the second must start with the character 'd'. This code creates a valid Dual bar Codabar-ABC bar for the values "c1234d" and "d5678a".