EAN and UPC-A codes may include 2 digit or 5 digit supplementary codes (Add-on codes) that may be encoded using character sets A and B. However, these are normally reproduced with their number values above the bars - rather than underneath the bars as in the case of the main code. In order to accommodate this feature, character sets A and B are also provided in the dLSoft barcode font as character sets ExtA and ExtB as shown in the Character sets Table below.
2-digit supplementaries do not use a check digit for the supplementary, but the encoding of the 2 digits does depend on the value of the add-on. The character sets for the two digits depends on the remainder of dividing the value of the add-on by 4:
|
Remainder |
lefthand digit |
righthand digit |
|
0 |
A |
A |
|
1 |
A |
B |
|
2 |
B |
A |
|
3 |
B |
B |
5-digit supplementaries do use a check digit calculated by taking three times the sum of digits 1, 3 and 5, plus nine times the sum of digits 2 and 4, and using the units value of the result. Encoding of the 5 digits is then determined by the value of the check digit as follows:
|
Check digit |
n1 |
n2 |
n3 |
n4 |
n5 |
|
0 |
B |
B |
A |
A |
A |
|
1 |
B |
A |
B |
A |
A |
|
2 |
B |
A |
A |
B |
A |
|
3 |
B |
A |
A |
A |
B |
|
4 |
A |
B |
B |
A |
A |
|
5 |
A |
A |
B |
B |
A |
|
6 |
A |
A |
A |
B |
B |
|
7 |
A |
B |
A |
B |
A |
|
8 |
A |
B |
A |
A |
B |
|
9 |
A |
A |
A |
A |
A |
This table (and the check value calculation) differs from that used for the main EAN/UPC barcode symbol.
More: