Zint: Manual
6. Types of symbology
6.6 Matrix Symbols
6.6.1 Data Matrix (ISO 16022)
Also known as Semacode this symbology was developed in 1989 by Acuity CiMatrix in partnership with the US DoD and NASA. The symbol can encode a large amount of data in a small area. Data Matrix encodes characters in the Latin-1 set by default but also supports encoding in other character sets using the ECI mechanism. It can also encode GS1 data. The size of the generated symbol can be adjusted using the --vers option (API option_2) as shown in the table below. A separate symbology ID (BARCODE_HIBC_DM) can be used to encode Health Industry Barcode (HIBC) data. Note that only ECC200 encoding is supported, the older standards have now been removed from Zint.
Input | Symbol Size | Input | Symbol Size | Input | Symbol Size | ||
---|---|---|---|---|---|---|---|
1 | 10 x 10 | 11 | 36 x 36 | 21 | 104 x 104 | ||
2 | 12 x 12 | 12 | 40 x 40 | 22 | 120 x 120 | ||
3 | 14 x 14 | 13 | 44 x 44 | 23 | 132 x 132 | ||
4 | 16 x 16 | 14 | 48 x 48 | 24 | 144 x 144 | ||
5 | 18 x 18 | 15 | 52 x 52 | 25 | 8 x 18 | ||
6 | 20 x 20 | 16 | 64 x 64 | 26 | 8 x 32 | ||
7 | 22 x 22 | 17 | 72 x 72 | 28 | 12 x 26 | ||
8 | 24 x 24 | 18 | 80 x 80 | 28 | 12 x 36 | ||
9 | 26 x 26 | 19 | 88 x 88 | 29 | 16 x 36 | ||
10 | 32 x 32 | 20 | 96 x 96 | 30 | 16 x 48 |
When using automatic symbol sizes you can force Zint to use square symbols (versions 1-24) at the command line by using the option --square (API option_3 = DM_SQUARE).
Data Matrix Rectangular Extension (ISO/IEC 21471) codes may be generated with the following values as before:
Input | Symbol Size | Input | Symbol Size | |
---|---|---|---|---|
31 | 8 x 48 | 40 | 20 x 36 | |
32 | 8 x 64 | 41 | 20 x 44 | |
33 | 8 x 80 | 42 | 20 x 64 | |
34 | 8 x 96 | 43 | 22 x 48 | |
35 | 8 x 120 | 44 | 24 x 48 | |
36 | 8 x 144 | 45 | 24 x 64 | |
37 | 12 x 64 | 46 | 26 x 40 | |
38 | 12 x 88 | 47 | 26 x 48 | |
39 | 16 x 64 | 48 | 26 x 64 |
DMRE symbol sizes may be activated in automatic size mode using the option --dmre (API option_3 = DM_DMRE).
GS1 data may be encoded using FNC1 (default) or GS as separator. Use the option --gssep to change to GS (API output_options |= GS1_GS_SEPARATOR).
For a faster but less optimal encoding, the --fast option (API input_mode |= FAST_MODE) may be used.
Data Matrix supports Structured Append of up to 16 symbols and a numeric ID (file identifications), which can be set by using the --structapp option (see 4.16 Structured Append) (API structapp). The ID consists of 2 numbers ID1 and ID2, each of which can range from 1 to 254, and is specified as the single number ID1 * 1000 + ID2, so for instance ID1 "123" and ID2 "234" would be given as "123234". Note that both ID1 and ID2 must be non-zero, so e.g. "123000" or "000123" would be invalid IDs. If an ID is not given it defaults to "001001".
6.6.2 QR Code (ISO 18004)
Also known as Quick Response Code this symbology was developed by Denso. Four levels of error correction are available using the --secure option (API option_1) as shown in the following table.
Input | ECC Level | Error Correction Capacity | Recovery Capacity |
---|---|---|---|
1 | L | Approx 20% of symbol | Approx 7% |
2 | M | Approx 37% of symbol | Approx 15% |
3 | Q | Approx 55% of symbol | Approx 25% |
4 | H | Approx 65% of symbol | Approx 30% |
The size of the symbol can be specified by setting the --vers option (API option_2) to the QR Code version required (1-40). The size of symbol generated is shown in the table below.
Input | Symbol Size | Input | Symbol Size | Input | Symbol Size | ||
---|---|---|---|---|---|---|---|
1 | 21 x 21 | 15 | 77 x 77 | 29 | 133 x 133 | ||
2 | 25 x 25 | 16 | 81 x 81 | 30 | 137 x 137 | ||
3 | 29 x 29 | 17 | 85 x 85 | 31 | 141 x 141 | ||
4 | 33 x 33 | 18 | 89 x 89 | 32 | 145 x 145 | ||
5 | 37 x 37 | 19 | 93 x 93 | 33 | 149 x 149 | ||
6 | 41 x 41 | 20 | 97 x 97 | 34 | 153 x 153 | ||
7 | 45 x 45 | 21 | 101 x 101 | 35 | 157 x 157 | ||
8 | 49 x 49 | 22 | 105 x 105 | 36 | 161 x 161 | ||
9 | 53 x 53 | 23 | 109 x 109 | 37 | 165 x 165 | ||
10 | 57 x 57 | 24 | 113 x 113 | 38 | 169 x 169 | ||
11 | 61 x 61 | 25 | 117 x 117 | 39 | 173 x 173 | ||
12 | 65 x 65 | 26 | 121 x 121 | 40 | 177 x 177 | ||
13 | 69 x 69 | 27 | 125 x 125 | ||||
14 | 73 x 73 | 28 | 129 x 129 |
The maximum capacity of a QR Code symbol (version 40) is 7089 numeric digits, 4296 alphanumeric characters or 2953 bytes of data. QR Code symbols can also be used to encode GS1 data. QR Code symbols can by default encode either characters in the Latin-1 set or Kanji, Katakana and ASCII characters which are members of the Shift JIS encoding scheme. In addition QR Code supports other character sets using the ECI mechanism. Input should usually be entered as UTF-8 with conversion to Latin-1 or Shift JIS being carried out by Zint. A separate symbology ID (BARCODE_HIBC_QR) can be used to encode Health Industry Barcode (HIBC) data.
Non-ASCII data density may be maximized by using the --fullmultibyte switch (API option_3 = ZINT_FULL_MULTIBYTE), but check that your barcode reader supports this before using.
QR Code has eight different masks designed to minimize unwanted patterns. The best mask to use is selected automatically by Zint but may be manually specified by using the --mask switch with values 0-7, or in the API by setting option_3 = (N + 1) << 8 where N is 0-7. To use with ZINT_FULL_MULTIBYTE set
option_3 = ZINT_FULL_MULTIBYTE | (N + 1) << 8
QR Code supports Structured Append of up to 16 symbols and a numeric ID (parity), which can be set by using the --structapp option (see 4.16 Structured Append) (API structapp). The parity ID ranges from 0 (default) to 255, and for full compliance should be set to the value obtained by XOR-ing together each byte of the complete data forming the sequence. Currently this calculation must be done outside of Zint.
6.6.3 Micro QR Code (ISO 18004)
A miniature version of the QR Code symbol for short messages, Micro QR Code symbols can encode either Latin-1 characters or Shift JIS characters. Input should be entered as a UTF-8 stream with conversion to Latin-1 or Shift JIS being carried out automatically by Zint. A preferred symbol size can be selected by using the --vers option (API option_2), as shown in the table below. Note that versions M1 and M2 have restrictions on what characters can be encoded.
Input | Version | Symbol Size | Allowed Characters |
---|---|---|---|
1 | M1 | 11 x 11 | Numeric only |
2 | M2 | 13 x 13 | Numeric, uppercase letters, space, and the characters "$%*+-./:" |
3 | M3 | 15 x 15 | Latin-1 and Shift JIS |
4 | M4 | 17 x 17 | Latin-1 and Shift JIS |
Except for version M1, which is always ECC level L, the amount of ECC codewords can be adjusted using the --secure option (API option_1); however ECC level H is not available for any version, and ECC level Q is only available for version M4:
Input | ECC Level | Error Correction Capacity | Recovery Capacity | Available for Versions |
---|---|---|---|---|
1 | L | Approx 20% of symbol | Approx 7% | M1, M2, M3, M4 |
2 | M | Approx 37% of symbol | Approx 15% | M2, M3, M4 |
3 | Q | Approx 55% of symbol | Approx 25% | M4 |
The defaults for symbol size and ECC level depend on the input and whether either of them is specified.
For barcode readers that support it, non-ASCII data density may be maximized by using the --fullmultibyte switch (API option_3 = ZINT_FULL_MULTIBYTE).
Micro QR Code has four different masks designed to minimize unwanted patterns. The best mask to use is selected automatically by Zint but may be manually specified by using the --mask switch with values 0-3, or in the API by setting option_3 = (N + 1) << 8 where N is 0-3. To use with ZINT_FULL_MULTIBYTE set
option_3 = ZINT_FULL_MULTIBYTE | (N + 1) << 8
6.6.4 Rectangular Micro QR Code (rMQR) (ISO 23941)
A rectangular version of QR Code, rMQR supports encoding of GS1 data, and either Latin-1 characters or Shift JIS characters, and other encodings using the ECI mechanism. As with other symbologies data should be entered as UTF-8 with conversion being handled by Zint. The amount of ECC codewords can be adjusted using the --secure option (API option_1), however only ECC levels M and H are valid for this type of symbol.
Input | ECC Level | Error Correction Capacity | Recovery Capacity |
---|---|---|---|
2 | M | Approx 37% of symbol | Approx 15% |
4 | H | Approx 65% of symbol | Approx 30% |
The preferred symbol sizes can be selected using the --vers option (API option_2) as shown in the table below. Input values between 33 and 38 fix the height of the symbol while allowing Zint to determine the minimum symbol width.
Input | Version | Symbol Size (HxW) | Input | Version | Symbol Size (HxW) | |
---|---|---|---|---|---|---|
1 | R7x43 | 7 x 73 | 20 | R13x77 | 13 x 77 | |
2 | R7x59 | 7 x 59 | 21 | R13x99 | 13 x 99 | |
3 | R7x77 | 7 x 77 | 22 | R13x139 | 13 x 139 | |
4 | R7x99 | 7 x 99 | 23 | R15x43 | 15 x 43 | |
5 | R7x139 | 7 x 139 | 24 | R15x59 | 15 x 59 | |
6 | R9x43 | 9 x 43 | 25 | R15x77 | 15 x 77 | |
7 | R9x59 | 9 x 59 | 26 | R15x99 | 15 x 99 | |
8 | R9x77 | 9 x 77 | 27 | R15x139 | 15 x 139 | |
9 | R9x99 | 9 x 99 | 28 | R17x43 | 17 x 43 | |
10 | R9x139 | 9 x 139 | 29 | R17x59 | 17 x 59 | |
11 | R11x27 | 11 x 27 | 30 | R17x77 | 17 x 77 | |
12 | R11x43 | 11 x 43 | 31 | R17x99 | 17 x 99 | |
13 | R11x59 | 11 x 59 | 32 | R17x139 | 17 x 139 | |
14 | R11x77 | 11 x 77 | 33 | R7xW | 7 x automatic width | |
15 | R11x99 | 11 x 99 | 34 | R9xW | 9 x automatic width | |
16 | R11x139 | 11 x 139 | 35 | R11xW | 11 x automatic width | |
17 | R13x27 | 13 x 27 | 36 | R13xW | 13 x automatic width | |
18 | R13x43 | 13 x 43 | 37 | R15xW | 15 x automatic width | |
19 | R13x59 | 13 x 59 | 38 | R17xW | 17 x automatic width |
For barcode readers that support it, non-ASCII data density may be maximized by using the --fullmultibyte switch or in the API by setting option_3 = ZINT_FULL_MULTIBYTE.
6.6.5 UPNQR (Univerzalnega Plačilnega Naloga QR)
A variation of QR Code used by Združenje Bank Slovenije (Bank Association of Slovenia). The size, error correction level and ECI are set by Zint and do not need to be specified. UPNQR is unusual in that it uses Latin-2 (ISO/IEC 8859-2 plus ASCII) formatted data. Zint will accept UTF-8 data and convert it to Latin-2, or if your data is already Latin-2 formatted use the --binary switch (API input_mode = DATA MODE).
The following example creates a symbol from data saved as a Latin-2 file:
zint -o upnqr.png -b 143 --scale=3 --binary -i upn.txt
6.6.6 MaxiCode (ISO 16023)
Developed by UPS the MaxiCode symbology employs a grid of hexagons surrounding a bulls-eye finder pattern. This symbology is designed for the identification of parcels. MaxiCode symbols can be encoded in one of five modes. In modes 2 and 3 MaxiCode symbols are composed of two parts named the primary and secondary messages. The primary message consists of a Structured Carrier Message which includes various data about the package being sent and the secondary message usually consists of address data in a data structure. The format of the primary message required by Zint is given in the following table:
Characters | Meaning |
---|---|
1 - 9 | Postcode data which can consist of up to 9 digits (for mode 2) |
or up to 6 alphanumeric characters (for mode 3). Remaining | |
unused characters can be filled with the SPACE character | |
(ASCII 32) or omitted (if omitted adjust the following | |
character positions). | |
10 - 12 | Three-digit country code according to ISO 3166-1. |
13 - 15 | Three-digit service code. This depends on your parcel courier. |
The primary message can be set at the command prompt using the --primary switch (API primary). The secondary message uses the normal data entry method. For example:
zint -o test.eps -b 57 --primary="999999999840012" \
-d "Secondary Message Here"
When using the API the primary message must be placed in the primary string. The secondary is entered in the same way as described in 5.2 Encoding and Saving to File. When either of these modes is selected Zint will analyse the primary message and select either mode 2 or mode 3 as appropriate.
As a convenience the secondary message for modes 2 and 3 can be set to be prefixed by the ISO/IEC 15434 Format "01" (transportation) sequence "[)>\R01\Gvv", where vv is a 2-digit version, by using the --scmvv switch (API option_2 = vv + 1). For example to use the common version "96" (ASC MH10/SC 8):
zint -b 57 --primary="152382802840001" --scmvv=96 --esc -d \
"1Z00004951\GUPSN\G06X610\G159\G1234567\G1/1\G\GY\G1 MAIN ST\GNY\GNY\R\E"
will prefix "[)>\R01\G96" to the secondary message. (\R, \G and \E are the escape sequences for Record Separator, Group Separator and End of Transmission respectively - see Table .)
Modes 4 to 6 can be accessed using the --mode switch (API option_1). Modes 4 to 6 do not have a primary message. For example:
zint -o test.eps -b 57 --mode=4 -d "A MaxiCode Message in Mode 4"
Mode 6 is reserved for the maintenance of scanner hardware and should not be used to encode user data.
This symbology uses Latin-1 character encoding by default but also supports the ECI encoding mechanism. The maximum length of text which can be placed in a MaxiCode symbol depends on the type of characters used in the text.
Example maximum data lengths are given in the table below:
Mode | Maximum Data Length for Capital Letters | Maximum Data Length for Numeric Digits | Number of Error Correction Codewords |
---|---|---|---|
2* | 84 | 126 | 50 |
3* | 84 | 126 | 50 |
4 | 93 | 138 | 50 |
5 | 77 | 113 | 66 |
6 | 93 | 138 | 50 |
* - secondary only
MaxiCode supports Structured Append of up to 8 symbols, which can be set by using the --structapp option (see 4.16 Structured Append) (API structapp). It does not support specifying an ID.
MaxiCode uses a different scaling than other symbols for raster output, see 4.9.2 MaxiCode Raster Scaling, and also for EMF vector output, when the scale is multiplied by 20 instead of 2.
6.6.7 Aztec Code (ISO 24778)
Invented by Andrew Longacre at Welch Allyn Inc in 1995 the Aztec Code symbol is a matrix symbol with a distinctive bulls-eye finder pattern. Zint can generate Compact Aztec Code (sometimes called Small Aztec Code) as well as ‘full-range’ Aztec Code symbols and by default will automatically select symbol type and size dependent on the length of the data to be encoded. Error correction codewords will normally be generated to fill at least 23% of the symbol. Two options are available to change this behaviour:
The size of the symbol can be specified using the --vers option (API option_2) to a value between 1 and 36 according to the following table. The symbols marked with an asterisk (*) in the table below are ‘compact’ symbols, meaning they have a smaller bulls-eye pattern at the centre of the symbol.
Input | Symbol Size | Input | Symbol Size | Input | Symbol Size | ||
---|---|---|---|---|---|---|---|
1 | 15 x 15* | 13 | 53 x 53 | 25 | 105 x 105 | ||
2 | 19 x 19* | 14 | 57 x 57 | 26 | 109 x 109 | ||
3 | 23 x 23* | 15 | 61 x 61 | 27 | 113 x 113 | ||
4 | 27 x 27* | 16 | 67 x 67 | 28 | 117 x 117 | ||
5 | 19 x 19 | 17 | 71 x 71 | 29 | 121 x 121 | ||
6 | 23 x 23 | 18 | 75 x 75 | 30 | 125 x 125 | ||
7 | 27 x 27 | 19 | 79 x 79 | 31 | 131 x 131 | ||
8 | 31 x 31 | 20 | 83 x 83 | 32 | 135 x 135 | ||
9 | 37 x 37 | 21 | 87 x 87 | 33 | 139 x 139 | ||
10 | 41 x 41 | 22 | 91 x 91 | 34 | 143 x 143 | ||
11 | 45 x 45 | 23 | 95 x 95 | 35 | 147 x 147 | ||
12 | 49 x 49 | 24 | 101 x 101 | 36 | 151 x 151 |
Note that in symbols which have a specified size the amount of error correction is dependent on the length of the data input and Zint will allow error correction capacities as low as 3 codewords.
Alternatively the amount of error correction data can be specified by setting the --secure option (API option_1) to a value from the following table:
Mode | Error Correction Capacity |
---|---|
1 | >10% + 3 codewords |
2 | >23% + 3 codewords |
3 | >36% + 3 codewords |
4 | >50% + 3 codewords |
It is not possible to select both symbol size and error correction capacity for the same symbol. If both options are selected then the error correction capacity selection will be ignored.
Aztec Code supports ECI encoding and can encode up to a maximum length of approximately 3823 numeric or 3067 alphabetic characters or 1914 bytes of data. A separate symbology ID (BARCODE_HIBC_AZTEC) can be used to encode Health Industry Barcode (HIBC) data.
Aztec Code supports Structured Append of up to 26 symbols and an optional alphanumeric ID of up to 32 characters, which can be set by using the --structapp option (see 4.16 Structured Append) (API structapp). The ID cannot contain spaces. If an ID is not given, no ID is encoded.
6.6.8 Aztec Runes (ISO 24778)
A truncated version of compact Aztec Code for encoding whole integers between 0 and 255, as defined in ISO/IEC 24778 Annex A. Includes Reed-Solomon error correction. It does not support Structured Append.
6.6.9 Code One
A matrix symbology developed by Ted Williams in 1992 which encodes data in a way similar to Data Matrix, Code One is able to encode the Latin-1 character set or GS1 data, and also supports the ECI mechanism. There are two types of Code One symbol - fixed-ratio symbols which are roughly square (versions A through to H) and variable-width versions (versions S and T). These can be selected by using --vers (API option_2) as shown in the table below:
Input | Version | Size (W x H) | Numeric Data Capacity | Alphanumeric Data Capacity |
---|---|---|---|---|
1 | A | 16 x 18 | 22 | 13 |
2 | B | 22 x 22 | 44 | 27 |
3 | C | 28 x 28 | 104 | 64 |
4 | D | 40 x 42 | 217 | 135 |
5 | E | 52 x 54 | 435 | 271 |
6 | F | 70 x 76 | 886 | 553 |
7 | G | 104 x 98 | 1755 | 1096 |
8 | H | 148 x 134 | 3550 | 2218 |
9 | S | width x 8 | 18 | N/A |
10 | T | width x 16 | 90 | 55 |
Version S symbols can only encode numeric data. The width of version S and version T symbols is determined by the length of the input data.
Code One supports Structured Append of up to 128 symbols, which can be set by using the --structapp option (see 4.16 Structured Append) (API structapp). It does not support specifying an ID. Structured Append is not supported with GS1 data nor for Version S symbols.
6.6.10 Grid Matrix
Grid Matrix groups modules in a chequerboard pattern, and by default supports the GB 2312 standard set, which includes Hanzi, ASCII and a small number of ISO/IEC 8859-1 characters. Input should be entered as UTF-8 with conversion to GB 2312 being carried out automatically by Zint. The symbology also supports the ECI mechanism. Support for GS1 data has not yet been implemented.
The size of the symbol and the error correction capacity can be specified. If you specify both of these values then Zint will make a ‘best-fit’ attempt to satisfy both conditions. The symbol size can be specified using the --vers option (API option_2), and the error correction capacity can be specified by using the --secure option (API option_1), according to the following tables:
Input | Symbol Size | Input | Symbol Size | |
---|---|---|---|---|
1 | 18 x 18 | 8 | 102 x 102 | |
2 | 30 x 30 | 9 | 114 x 114 | |
3 | 42 x 42 | 10 | 126 x 126 | |
4 | 54 x 54 | 11 | 138 x 138 | |
5 | 66 x 66 | 12 | 150 x 150 | |
6 | 78 x 78 | 13 | 162 x 162 | |
7 | 90 x 90 |
Mode | Error Correction Capacity |
---|---|
1 | Approximately 10% |
2 | Approximately 20% |
3 | Approximately 30% |
4 | Approximately 40% |
5 | Approximately 50% |
Non-ASCII data density may be maximized by using the --fullmultibyte switch (API option_3 = ZINT_FULL_MULTIBYTE), but check that your barcode reader supports this before using.
Grid Matrix supports Structured Append of up to 16 symbols and a numeric ID (file signature), which can be set by using the --structapp option (see 4.16 Structured Append) (API structapp). The ID ranges from 0 (default) to 255.
6.6.11 DotCode
DotCode uses a grid of dots in a rectangular formation to encode characters up to a maximum of approximately 450 characters (or 900 numeric digits). The symbology supports ECI encoding and GS1 data encoding. By default Zint will produce a symbol which is approximately square, however the width of the symbol can be adjusted by using the --cols option (API option_2) (maximum 200). Outputting DotCode to raster images (BMP, GIF, PCX, PNG, TIF) will require setting the scale of the image to a larger value than the default (e.g. approximately 10) for the dots to be plotted correctly. Approximately 33% of the resulting symbol is comprised of error correction codewords.
DotCode has two sets of 4 masks, designated 0-3 and 0’-3’, the second "prime" set being the same as the first with corners lit. The best mask to use is selected automatically by Zint but may be manually specified by using the --mask switch with values 0-7, where 4-7 denote 0’-3’, or in the API by setting option_3 = (N + 1) << 8 where N is 0-7.
DotCode supports Structured Append of up to 35 symbols, which can be set by using the --structapp option (see 4.16 Structured Append) (API structapp). It does not support specifying an ID.
6.6.12 Han Xin Code (ISO 20830)
Also known as Chinese Sensible Code, Han Xin is capable of encoding characters in either the Latin-1 character set or the GB 18030 character set (which is a UTF, i.e. includes all Unicode characters, optimized for Chinese characters) and is also able to support the ECI mechanism. Support for the encoding of GS1 data has not yet been implemented.
The size of the symbol can be specified using the --vers option (API option_2) to a value between 1 and 84 according to the following table.
Input | Symbol Size | Input | Symbol Size | Input | Symbol Size | ||
---|---|---|---|---|---|---|---|
1 | 23 x 23 | 29 | 79 x 79 | 57 | 135 x 135 | ||
2 | 25 x 25 | 30 | 81 x 81 | 58 | 137 x 137 | ||
3 | 27 x 27 | 31 | 83 x 83 | 59 | 139 x 139 | ||
4 | 29 x 29 | 32 | 85 x 85 | 60 | 141 x 141 | ||
5 | 31 x 31 | 33 | 87 x 87 | 61 | 143 x 143 | ||
6 | 33 x 33 | 34 | 89 x 89 | 62 | 145 x 145 | ||
7 | 35 x 35 | 35 | 91 x 91 | 63 | 147 x 147 | ||
8 | 37 x 37 | 36 | 93 x 93 | 64 | 149 x 149 | ||
9 | 39 x 39 | 37 | 95 x 95 | 65 | 151 x 151 | ||
10 | 41 x 41 | 38 | 97 x 97 | 66 | 153 x 153 | ||
11 | 43 x 43 | 39 | 99 x 99 | 67 | 155 x 155 | ||
12 | 45 x 45 | 40 | 101 x 101 | 68 | 157 x 157 | ||
13 | 47 x 47 | 41 | 103 x 103 | 69 | 159 x 159 | ||
14 | 49 x 49 | 42 | 105 x 105 | 70 | 161 x 161 | ||
15 | 51 x 51 | 43 | 107 x 107 | 71 | 163 x 163 | ||
16 | 53 x 53 | 44 | 109 x 109 | 72 | 165 x 165 | ||
17 | 55 x 55 | 45 | 111 x 111 | 73 | 167 x 167 | ||
18 | 57 x 57 | 46 | 113 x 113 | 74 | 169 x 169 | ||
19 | 59 x 59 | 47 | 115 x 115 | 75 | 171 x 171 | ||
20 | 61 x 61 | 48 | 117 x 117 | 76 | 173 x 173 | ||
21 | 63 x 63 | 49 | 119 x 119 | 77 | 175 x 175 | ||
22 | 65 x 65 | 50 | 121 x 121 | 78 | 177 x 177 | ||
23 | 67 x 67 | 51 | 123 x 123 | 79 | 179 x 179 | ||
24 | 69 x 69 | 52 | 125 x 125 | 80 | 181 x 181 | ||
25 | 71 x 71 | 53 | 127 x 127 | 81 | 183 x 183 | ||
26 | 73 x 73 | 54 | 129 x 129 | 82 | 185 x 185 | ||
27 | 75 x 75 | 55 | 131 x 131 | 83 | 187 x 187 | ||
28 | 77 x 77 | 56 | 133 x 133 | 84 | 189 x 189 |
There are four levels of error correction capacity available for Han Xin Code which can be set by using the --secure option (API option_1) to a value from the following table:
Mode | Recovery Capacity |
---|---|
1 | Approx 8% |
2 | Approx 15% |
3 | Approx 23% |
4 | Approx 30% |
Non-ASCII data density may be maximized by using the --fullmultibyte switch (API option_3 = ZINT_FULL_MULTIBYTE), but check that your barcode reader supports this before using.
Han Xin has four different masks designed to minimize unwanted patterns. The best mask to use is selected automatically by Zint but may be manually specified by using the --mask switch with values 0-3, or in the API by setting option_3 = (N + 1) << 8 where N is 0-3. To use with ZINT_FULL_MULTIBYTE set
option_3 = ZINT_FULL_MULTIBYTE | (N + 1) << 8
6.6.13 Ultracode
This symbology uses a grid of coloured elements to encode data. ECI and GS1 modes are supported. The amount of error correction can be set using the --secure option (API option_1) to a value as shown in the following table:
Value | EC Level | Amount of symbol holding error correction data |
---|---|---|
1 | EC0 | 0% - Error detection only |
2 | EC1 | Approx 5% |
3 | EC2 | Approx 9% - Default value |
4 | EC3 | Approx 17% |
5 | EC4 | Approx 25% |
6 | EC5 | Approx 33% |
Zint does not currently implement data compression by default, but this can be initiated through the API by setting
symbol->option_3 = ULTRA_COMPRESSION;
WARNING: Ultracode data compression is experimental and should not be used in a production environment.
Revision 2 of Ultracode (2021) which swops and inverts the DCCU and DCCL tiles may be specified using --vers=2 (API option_2 = 2).
Ultracode supports Structured Append of up to 8 symbols and an optional numeric ID (File Number), which can be set by using the --structapp option (see 4.16 Structured Append) (API structapp). The ID ranges from 1 to 80088. If an ID is not given, no ID is encoded.