ISO/IEC 18004:2000
(Main)Information technology — Automatic identification and data capture techniques — Bar code symbology — QR Code
Information technology — Automatic identification and data capture techniques — Bar code symbology — QR Code
Technologies de l'information — Techniques d'identification automatique et de capture de données — Symboles de codes à barres — Code QR
General Information
Relations
Standards Content (Sample)
INTERNATIONAL ISO/IEC
STANDARD 18004
First edition
2000-06-15
Information technology — Automatic
identification and data capture
techniques — Bar code symbology — QR
Code
Technologies de l'information — Techniques d'identification automatique et
de capture de données — Symboles de codes à barres — Code QR
Reference number
ISO/IEC 18004:2000(E)
©
ISO/IEC 2000
---------------------- Page: 1 ----------------------
ISO/IEC 18004:2000(E)
PDF disclaimer
This PDF file may contain embedded typefaces. In accordance with Adobe's licensing policy, this file may be printed or viewed but shall not
be edited unless the typefaces which are embedded are licensed to and installed on the computer performing the editing. In downloading this
file, parties accept therein the responsibility of not infringing Adobe's licensing policy. The ISO Central Secretariat accepts no liability in this
area.
Adobe is a trademark of Adobe Systems Incorporated.
Details of the software products used to create this PDF file can be found in the General Info relative to the file; the PDF-creation parameters
were optimized for printing. Every care has been taken to ensure that the file is suitable for use by ISO member bodies. In the unlikely event
that a problem relating to it is found, please inform the Central Secretariat at the address given below.
© ISO/IEC 2000
All rights reserved. Unless otherwise specified, no part of this publication may be reproduced or utilized in any form or by any means, electronic
or mechanical, including photocopying and microfilm, without permission in writing from either ISO at the address below or ISO's member body
in the country of the requester.
ISO copyright office
Case postale 56 � CH-1211 Geneva 20
Tel. + 41 22 749 01 11
Fax + 41 22 749 09 47
E-mail copyright@iso.ch
Web www.iso.ch
Printed in Switzerland
ii © ISO/IEC 2000 – All rights reserved
---------------------- Page: 2 ----------------------
ISO/IEC 18004:2000(E)
Contents Page
Foreword.v
Introduction.vi
1 Scope .1
2 Conformance.1
3 Normative references .1
4 Terms and definitions .2
5 Symbols (and abbreviated terms).3
6 Conventions .4
6.1 Module positions .4
6.2 Byte notation.4
6.3 Version references.4
7 Symbol description .4
7.1 Basic characteristics.4
7.2 Summary of additional features.5
7.3 Symbol structure .6
7.3.1 Symbol Versions and sizes .6
7.3.2 Finder pattern.13
7.3.3 Separators .13
7.3.4 Timing Pattern.13
7.3.5 Alignment Patterns.13
7.3.6 Encoding region.13
7.3.7 Quiet zone.13
8 Requirements.14
8.1 Encode procedure overview.14
8.2 Data analysis.15
8.3 Modes.16
8.3.1 Extended Channel Interpretation (ECI) Mode .16
8.3.2 Numeric Mode .16
8.3.3 Alphanumeric Mode .16
8.3.4 8-bit Byte Mode .16
8.3.5 Kanji Mode.16
8.3.6 Mixing modes.17
8.3.7 Structured Append Mode.17
8.3.8 FNC1 Mode .17
8.4 Data encodation.17
8.4.1 Extended Channel Interpretation (ECI) Mode .18
8.4.2 Numeric Mode .19
8.4.3 Alphanumeric Mode .21
8.4.4 8-bit Byte Mode .22
8.4.5 Kanji Mode.24
8.4.6 Mixing modes.25
8.4.7 FNC1 Modes .25
8.4.8 Terminator .27
8.4.9 Bit stream to codeword conversion.27
8.5 Error correction.33
8.5.1 Error correction capacity.33
8.5.2 Generating the error correction codewords .45
8.6 Constructing the final message codeword sequence .45
© ISO/IEC 2000 – All rights reserved iii
---------------------- Page: 3 ----------------------
ISO/IEC 18004:2000(E)
8.7 Codeword placement in matrix.46
8.7.1 Symbol character representation.46
8.7.2 Function pattern placement.46
8.7.3 Symbol character placement.46
8.8 Masking.50
8.8.1 Mask Patterns.50
8.8.2 Evaluation of masking results.52
8.9 Format Information .53
8.10 Version Information .54
9 Structured Append .55
9.1 Basic principles .55
9.2 Symbol Sequence Indicator.56
9.3 Parity Data .56
10 Symbol printing and marking .57
10.1 Dimensions.57
10.2 Human-readable interpretation.57
10.3 Marking guidelines .57
11 Symbol quality .57
11.1 Obtaining the test image.57
11.2 Symbol quality parameters.57
11.2.1 Decode .57
11.2.2 Symbol Contrast .58
11.2.3 "Print" growth .58
11.2.4 Axial Nonuniformity.58
11.2.5 Unused Error Correction.58
11.3 Overall symbol grade .58
11.4 Process control measurements .59
12 Decoding procedure overview .59
13 Reference decode algorithm for QR Code .60
14 Autodiscrimination capability.65
15 Transmitted data .65
15.1 Symbology Identifier .65
15.2 Extended Channel Interpretations .65
15.3 FNC1.66
Annex A (normative) Error detection and correction generator polynomials .67
Annex B (normative) Error correction decoding steps .74
Annex C (normative) Format Information .76
Annex D (normative) Version Information .78
Annex E (normative) Position of Alignment Patterns.81
Annex F (normative) Symbology Identifier.83
Annex G (informative) Symbol encoding example.84
Annex H (informative) Optimisation of bit stream length.86
Annex I (informative) User guidelines for printing and scanning of QR Code symbols.88
Annex J (informative) Autodiscrimination .90
Annex K (informative) Matrix code print quality guideline.91
Annex L (informative) Process control techniques .95
Annex M (informative) Characteristics of Model 1 QR Code symbols.97
iv © ISO/IEC 2000 – All rights reserved
---------------------- Page: 4 ----------------------
ISO/IEC 18004:2000(E)
Foreword
ISO (the International Organization for Standardization) and IEC (the International Electrotechnical Commission)
form the specialized system for worldwide standardization. National bodies that are members of ISO or IEC
participate in the development of International Standards through technical committees established by the
respective organization to deal with particular fields of technical activity. ISO and IEC technical committees
collaborate in fields of mutual interest. Other international organizations, governmental and non-governmental, in
liaison with ISO and IEC, also take part in the work.
International Standards are drafted in accordance with the rules given in the ISO/IEC Directives, Part 3.
In the field of information technology, ISO and IEC have established a joint technical committee, ISO/IEC JTC 1.
Draft International Standards adopted by the joint technical committee are circulated to national bodies for voting.
Publication as an International Standard requires approval by at least 75 % of the national bodies casting a vote.
Attention is drawn to the possibility that some of the elements of this International Standard may be the subject of
patent rights. ISO and IEC shall not be held responsible for identifying any or all such patent rights.
International Standard ISO/IEC 18004 was prepared by Joint Technical Committee ISO/IEC JTC 1, Information
technology, Subcommittee SC 31, Automatic identification and data capture techniques, in collaboration with AIM
1)
Inc. .
Annexes A to F form a normative part of this International Standard. Annexes G to M are for information only.
1) AIM Inc., 634 Alpha Drive, Pittsburgh, PA 15238-2802, U.S.A.
© ISO/IEC 2000 – All rights reserved v
---------------------- Page: 5 ----------------------
ISO/IEC 18004:2000(E)
Introduction
QR Code is a matrix symbology consisting of an array of nominally square modules arranged in an overall square
pattern, including a unique finder pattern located at three corners of the symbol and intended to assist in easy
location of its position, size and inclination. A wide range of sizes of symbol is provided for together with four levels
of error correction. Module dimensions are user-specified to enable symbol production by a wide variety of
techniques. QR Code Model 1 is the original specification for QR Code; QR Code Model 2 is an enhanced form of
the symbology with additional features and can be auto-discriminated from Model 1. Since Model 2 is the
recommended model for new, open systems application of QR Code, this International Standard describes Model 2
fully, and specifies the features in which Model 1 QR Code differs from Model 2 in an annex.
vi © ISO/IEC 2000 – All rights reserved
---------------------- Page: 6 ----------------------
INTERNATIONAL STANDARD ISO/IEC 18004:2000(E)
Information technology — Automatic identification and data
capture techniques — Bar code symbology — QR Code
1 Scope
This International Standard specifies the requirements for the symbology known as QR Code. It specifies the QR
Code Model 2 symbology characteristics, data character encodation, symbol formats, dimensional characteristics,
error correction rules, reference decoding algorithm, production quality requirements, and user-selectable
application parameters, and defines in an annex the features of Model 1 symbols which differ from Model 2.
2 Conformance
QR Code symbols (and equipment designed to produce or read QR Code symbols) shall be considered as meeting
this specification if they meet the requirements defined for either QR Code Model 2 or Model 1. It should be noted,
however, that Model 2 is the form of the symbology recommended for new and open systems applications.
3 Normative references
The following normative documents contain provisions which, through reference in this text, constitute provisions of
this International Standard. For dated references, subsequent amendments to, or revisions of, any of these
publications do not apply. However, parties to agreements based on this International Standard are encouraged to
investigate the possibility of applying the most recent editions of the normative documents indicated below. For
undated references, the latest edition of the normative document referred to applies. Members of ISO and IEC
maintain registers of currently valid International Standards.
ISO/IEC 15424, Information technology — Automatic identification and data capture techniques — Data
carrier/symbology identifiers.
ISO/IEC 15416, Information technology — Automatic identification and data capture techniques — Bar code print
quality test specifications — Linear symbols.
EN 1556, Bar Coding — Terminology.
JIS X 0201, JIS 8-bit Character Set for Information Interchange.
JIS X 0208-1997, Japanese Graphic Character Set for Information Interchange.
ANSI X3.4, Coded Character Sets — 7-bit American National Standard Code for Information Interchange (7-bit
ASCII).
AIM International Technical Specification, Extended Channel Interpretations: Part 1: Identification scheme and
protocol (referred to as "AIM ECI specification").
© ISO/IEC 2000 – All rights reserved 1
---------------------- Page: 7 ----------------------
ISO/IEC 18004:2000(E)
4 Terms and definitions
For the purposes of this International Standard, the terms and definitions given in EN 1556 and the following apply.
4.1
Alignment Pattern
fixed reference pattern in defined positions in a matrix symbology, which enables the decode software to re-
synchronise the coordinate mapping of the image modules in the event of moderate amounts of distortion of the
image
4.2
Character Count Indicator
bit sequence which defines the data string length in a mode
4.3
ECI designator
six-digit number identifying a specific ECI assignment
4.4
encoding region
region of the symbol not occupied by function patterns and available for encodation of data and error correction
codewords
4.5
Extended Channel Interpretation (ECI)
protocol used in some symbologies that allows the output data stream to have interpretations different from that of
the default character set
4.6
Extension Pattern
in Model 1 symbols, a function pattern which does not encode data
4.7
Format Information
function pattern containing information on the error correction level applied to the symbol and on the masking
pattern used, essential to enable the remainder of the encoding region to be decoded
4.8
function pattern
overhead component of the symbol required for location of the symbol or identification of its characteristics to assist
in decoding
4.9
Mask Pattern Reference
three-bit identifier of the masking patterns applied to the symbol
4.10
masking
process of XORing the bit pattern in the encoding region with a masking pattern to provide a symbol with more
evenly balanced numbers of dark and light modules and reduced occurrence of patterns which would interfere with
fast processing of the image
4.11
mode
method of representing a defined character set as a bit string
2 © ISO/IEC 2000 – All rights reserved
---------------------- Page: 8 ----------------------
ISO/IEC 18004:2000(E)
4.12
Mode Indicator
four-bit identifier indicating in which mode the next data sequence is encoded
4.13
Padding Bit
0 bit, not representing data, used to fill empty positions of the final codeword after the Terminator in a data bit string
4.14
Position Detection Pattern
one of three identical components of the Finder Pattern
4.15
Remainder Bit
0 bit, not representing data, used to fill empty positions of the symbol encoding region after the final symbol
character, where the encoding region does not divide exactly into eight-bit symbol characters
4.16
Remainder Codeword
Pad Codeword used to fill empty codeword positions to complete the symbol if the total number of data and error
correction codewords does not exactly fill its nominal capacity
NOTE The Remainder codewords come after the error correction codewords.
4.17
segment
sequence of data encoded according to the rules of one ECI or encodation mode
4.18
Separator
function pattern of all light modules, one module wide, separating the Position Detection Patterns from the rest of
the symbol
4.19
Terminator
bit pattern 0000 used to end the bit string representing data
4.20
Timing Pattern
alternating sequence of dark and light modules enabling module coordinates in the symbol to be determined
4.21
Version
size of the symbol represented in terms of its position in the sequence of permissible sizes from 21 � 21 modules
(Version 1) to 177� 177 (Version 40) modules
NOTE May also indicate the error correction level applied to the symbol.
4.22
Version Information
in Model 2 symbols, a function pattern containing information on the symbol version together with error correction
bits for this data
5 Symbols (and abbreviated terms)
Mathematical symbols used in formulae and equations are defined after the formula or equation in which they
appear.
© ISO/IEC 2000 – All rights reserved 3
---------------------- Page: 9 ----------------------
ISO/IEC 18004:2000(E)
For the purposes of this specification, the mathematical operations which follow shall apply:
div is the integer division operator
mod is the integer remainder after division
XOR is the exclusive-or logic function whose output is one only when its two inputs are not equivalent. It is
represented by the symbol�.
6 Conventions
6.1 Module positions
For ease of reference, module positions are defined by their row and column coordinates in the symbol, in the form
(i, j) where i designates the row (counting from the top downwards) and j the column (counting from left to right) in
which the module is located, with counting commencing at 0. Module (0, 0) is therefore located at the upper left
corner of the symbol.
6.2 Byte notation
Byte contents are shown as hexadecimal values.
6.3 Version references
Symbol versions are referred to in the form Version V-E where V identifies the version number (1 - 40) and E
indicates the error correction level (L, M, Q, H).
7 Symbol description
The clauses and subclauses of this International Standard define the specifications applicable to Model 2 QR Code
symbols. Unless indicated otherwise in Annex M they also apply to Model 1 symbols.
7.1 Basic characteristics
QR Code is a matrix symbology with the following characteristics:
a) Encodable character set:
1) numeric data (digits 0- 9);
2) alphanumeric data (digits 0- 9; upper case letters A-Z; nine other characters: space, $ % * + - . / : );
3) 8-bit byte data (JIS 8-bit character set (Latin and Kana) in accordance with JIS X 0201);
4) Kanji characters (Shift JIS character set in accordance with JIS X 0208 Annex 1 Shift Coded
Representation. Note that Kanji characters in QR Code can have values 8140 -9FFC and E040 -
HEX HEX HEX
EBBF , which can be compacted into 13 bits.)
HEX
b) Representation of data:
A dark module is a binary one and a light module is a binary zero.
c) Symbol size (not including quiet zone):
21� 21 modules to 177� 177 modules (Versions 1 to 40, increasing in steps of 4 modules per side)
4 © ISO/IEC 2000 – All rights reserved
---------------------- Page: 10 ----------------------
ISO/IEC 18004:2000(E)
d) Data characters per symbol (for maximum symbol size – Version 40-L):
1) numeric data: 7 089 characters
2) alphanumeric data: 4 296 characters
3) 8-bit byte data: 2 953 characters
4) Kanji data: 1 817 characters
e) Selectable error correction:
Four levels of error correction allowing recovery of:
L7%
M 15%
Q 25%
H 30%
of the symbol codewords.
f) Code type:
Matrix
g) Orientation independence:
Yes
Figure 1 illustrates a Version 1 QR Code symbol.
Figure 1 — Example of QR Code symbol
7.2 Summary of additional features
The following additional features are either inherent or optional in QR Code:
a) Structured append (optional)
This allows files of data to be represented logically and continuously in up to 16 QR Code symbols. These
may be scanned in any sequence to enable the original data to be correctly reconstructed.
© ISO/IEC 2000 – All rights reserved 5
---------------------- Page: 11 ----------------------
ISO/IEC 18004:2000(E)
b) Masking (inherent)
This enables the ratio of dark to light modules in the symbol to be approximated to 1:1 whilst minimizing the
occurrence of arrangements of adjoining modules which would impede efficient decoding.
c) Extended Channel Interpretations (optional)
This mechanism enables data using character sets other than the default encodable set (e.g. Arabic, Cyrillic,
Greek) and other data interpretations (e.g. compacted data using defined compression schemes) or other
industry-specific requirements to be encoded.
7.3 Symbol structure
Each QR Code symbol shall be constructed of nominally square modules set out in a regular square array and
shall consist of a encoding region and function patterns, namely
...
Questions, Comments and Discussion
Ask us and Technical Secretary will try to provide an answer. You can facilitate discussion about the standard in here.