JP2014154118A - Optical code and generation method for the optical code - Google Patents

Optical code and generation method for the optical code Download PDF

Info

Publication number
JP2014154118A
JP2014154118A JP2013026208A JP2013026208A JP2014154118A JP 2014154118 A JP2014154118 A JP 2014154118A JP 2013026208 A JP2013026208 A JP 2013026208A JP 2013026208 A JP2013026208 A JP 2013026208A JP 2014154118 A JP2014154118 A JP 2014154118A
Authority
JP
Japan
Prior art keywords
color
data
module
code
optical code
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2013026208A
Other languages
Japanese (ja)
Other versions
JP6099258B2 (en
Inventor
Nobuyuki Teraura
信之 寺浦
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
TERRARA CODE RESEARCH INSTITUTE Inc
TERRARA CODE RES INST Inc
Original Assignee
TERRARA CODE RESEARCH INSTITUTE Inc
TERRARA CODE RES INST Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by TERRARA CODE RESEARCH INSTITUTE Inc, TERRARA CODE RES INST Inc filed Critical TERRARA CODE RESEARCH INSTITUTE Inc
Priority to JP2013026208A priority Critical patent/JP6099258B2/en
Publication of JP2014154118A publication Critical patent/JP2014154118A/en
Application granted granted Critical
Publication of JP6099258B2 publication Critical patent/JP6099258B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

PROBLEM TO BE SOLVED: To provide an optical code that has a recording density higher than a monochrome optical code while retaining compatibility with a standard conventional monochrome optical code.SOLUTION: Colors are assigned to modules for an optical code so as to be distinguished from one of reference colors of two or more of types. The reference colors of two or more types are composed of a plurality of bright reference colors equal to or higher than a predetermined bright color threshold in reflectance or brightness, and a plurality of dark reference colors equal to or lower than a predetermined dark color threshold in reflectance or brightness. One of the bright reference colors is assigned to a module distinguished as a bright color, such that the module can be distinguished. One of the dark reference colors is assigned to a module distinguished as a dark color, such that the module can be distinguished. Thereby, two types of data are recorded, one of which is general-purpose data recorded according to information indicating which one of a bright reference color and dark reference color each module has, and the other of which is exclusive data recorded according to information indicating which type of the bright reference color or dark reference color each module has.

Description

本発明は、複数のモジュールによって構成される光学コードに関する。   The present invention relates to an optical code composed of a plurality of modules.

バーコードや二次元コード等の光学コードであって、現在普及しているものは、基本単位となるモジュールに白色又は黒色を割り当てて情報を記録している。こうした白黒の光学コードは規格が統一されており、規格化された光学コードであれば、携帯電話等の読取装置でデータを読み取って、誰でも記録された内容を知り得るように構成されている。   Optical codes such as barcodes and two-dimensional codes, which are currently popular, record information by assigning white or black to a module as a basic unit. Standards for such black and white optical codes are standardized, and any standardized optical code can be read by a reading device such as a mobile phone so that anyone can know the recorded contents. .

規格化された白黒の光学コードは汎用性に優れている一方で、情報量を増大させ難いという欠点がある。このため、記録密度を高める手段として、各モジュールを多種類の色で配色することで、1モジュールに1ビット超のデータを記録し得るようにした構成が提案されている(例えば、特許文献1)。   While the standardized black and white optical code is excellent in versatility, it has a drawback that it is difficult to increase the amount of information. For this reason, as a means for increasing the recording density, a configuration has been proposed in which data of more than 1 bit can be recorded in one module by arranging each module with various colors (for example, Patent Document 1). ).

特開2010−61217号公報JP 2010-61217 A

上記特許文献1に記載の光学コードは、既存の白黒の光学コードに比べて、モジュールの色の種類が多くなり、また、データを符号化する方式も異なるため、既存の規格化された白黒光学コードを読み取るための読取装置では読み取ることができない。このため、仮に、特許文献1に記載の光学コードを、規格化された白黒光学コードに替えて新規格として採用する場合は、当該白黒光学コードの読取装置のソフトやハードを変更する必要がある。   The optical code described in Patent Document 1 has a larger number of module colors and a different method for encoding data compared to an existing monochrome optical code. It cannot be read by a reader for reading the code. Therefore, if the optical code described in Patent Document 1 is adopted as a new standard in place of the standardized black and white optical code, it is necessary to change the software and hardware of the black and white optical code reading device. .

しかしながら、商品バーコードやQRコード(登録商標)などの規格化された白黒光学コードは、極めて広範囲に普及しており、これらの光学コードを読み取るための読取装置は膨大な数に上るため、読取装置全てを新規格の光学コードに合わせて変更するのは困難である。白黒光学コードの読取装置でも情報を読取可能とするために、現規格の白黒光学コードを新規格の光学コードと並列表示することも提案されるが、光学コードの印字スペースを広くしなくてはならず、記録密度を高めるという本来の目的を達成できなくなってしまう。   However, standardized black-and-white optical codes such as commodity barcodes and QR codes (registered trademark) are very widespread, and there are a large number of reading devices for reading these optical codes. It is difficult to change all the devices according to the new standard optical code. In order to be able to read information even with a black and white optical code reader, it is proposed to display the current standard black and white optical code in parallel with the new standard optical code, but it is necessary to widen the optical code printing space. In other words, the original purpose of increasing the recording density cannot be achieved.

本発明はかかる現状に鑑みて為されたものであり、規格化された従来の白黒光学コードと互換性を保ちつつ、記録密度を高め得る光学コードの提供を目的とする。   The present invention has been made in view of the present situation, and an object of the present invention is to provide an optical code capable of increasing the recording density while maintaining compatibility with a standardized conventional monochrome optical code.

本発明は、明色又は暗色と識別されるモジュールによって構成される光学コードであって、各モジュールは、RGB値の異なる複数種類の基準色のいずれかと識別され得るよう配色されており、前記複数種類の基準色は、反射率又は輝度が所定の明色閾値以上である複数の明色基準色と、反射率又は輝度が所定の暗色閾値以下である複数の暗色基準色とからなり、明色と識別されるモジュールは、明色基準色のいずれかと識別可能に配色され、暗色と識別されるモジュールは、暗色基準色のいずれかと識別可能に配色されており、各モジュールが、明色基準色と暗色基準色のいずれであるかの情報によって記録される汎用データと、各モジュールが、明色基準色又は暗色基準色のうち、どの種類の基準色であるかの情報によって記録される専用データとの少なくとも二種類のデータを含むことを特徴とする光学コードである。   The present invention is an optical code configured by modules identified as light or dark colors, and each module is color-coded so as to be identified as one of a plurality of types of reference colors having different RGB values. The type of reference color is composed of a plurality of light color reference colors whose reflectance or luminance is equal to or higher than a predetermined light color threshold value, and a plurality of dark color reference colors whose reflectance or luminance is equal to or lower than a predetermined dark color threshold value. The modules identified with the light color reference color are identifiable with one of the light color reference colors, the modules identified with the dark color are identifiable with one of the dark color reference colors, and each module has a light color reference color. And the general-purpose data recorded by the information on whether the reference color is the dark color reference color, and the special data recorded by the information on which type of reference color the light color reference color or the dark color reference color is used for each module. An optical code characterized in that it comprises at least two kinds of data with the data.

かかる光学コードを、既存の読取装置で読み取った場合、明色基準色で配色されたモジュール(以下、明色モジュールと言う。)は明色と識別され、暗色基準色で配色された(以下、暗色モジュールと言う。)は暗色と識別される。このため、本発明の光学コードでは、既存の白黒光学コードの規格に則って各モジュールに汎用データを記録すれば、白黒光学コードを読み取るための既存の読取装置で汎用データを読み取ることができる。一方で、既存の読取装置では、明色モジュールや暗色モジュールがどの基準色で配色されているかは識別不能であるため、光学コードに記録された専用データは読み取ることができないが、専用の読取装置を用いて、各モジュールがいずれの基準色で配色されているかを識別すれば、光学コードに記録された専用データも読み取り可能となる。このように、本発明の光学コードによれば、汎用データを、既存の読取装置で読取可能な態様で記録できるから、規格化された白黒光学コードに記録されるデータを汎用データとして記録することで、規格化された白黒光学コードとの互換性を確保することができる。また、本発明の光学コードでは、各モジュールに、汎用データと専用データの二種類のデータを記録することができるから、1モジュールに1ビットのデータしか記録できない白黒光学コードに比べて記録密度を高めることができるという利点がある。また、光学コードに記録される専用データは、既存の読取装置では読み取ることができないため、特定の者にしか読み取りできない秘匿情報を記録するのに適している。   When such an optical code is read by an existing reader, a module arranged in a light color reference color (hereinafter referred to as a light color module) is identified as a light color and is arranged in a dark color reference color (hereinafter referred to as a light color reference color). Is referred to as a dark color module). For this reason, in the optical code of the present invention, if general-purpose data is recorded in each module in accordance with the standard of the existing black-and-white optical code, the general-purpose data can be read by the existing reader for reading the black-and-white optical code. On the other hand, in the existing reading device, it is impossible to identify which reference color is used for the light color module and the dark color module, so that the dedicated data recorded in the optical code cannot be read. If it is identified by which reference color each module is colored using the dedicated data recorded in the optical code can be read. As described above, according to the optical code of the present invention, general-purpose data can be recorded in a form that can be read by an existing reader. Therefore, data recorded in a standardized monochrome optical code can be recorded as general-purpose data. Thus, compatibility with the standardized monochrome optical code can be ensured. In addition, since the optical code of the present invention can record two types of data, general-purpose data and dedicated data, in each module, the recording density is higher than that of a monochrome optical code that can record only 1-bit data in one module. There is an advantage that it can be increased. Moreover, since the dedicated data recorded on the optical code cannot be read by an existing reader, it is suitable for recording confidential information that can be read only by a specific person.

本発明の光学コードは、例えば、モジュールをマトリックス状に配置してなる二次元コードであることが提案される。   It is proposed that the optical code of the present invention is a two-dimensional code formed by arranging modules in a matrix, for example.

光学コードが二次元コードである場合、明色基準色と暗色基準色のいずれで配色されるかが予め決定され、光学的読取りを補助するパターンを構成する固定領域を備えるものであり、該固定領域には、全種類の基準色を所定位置のモジュールに夫々配色してなるサンプル領域を備えることが提案される。   When the optical code is a two-dimensional code, it is determined in advance whether the light color reference color or the dark color reference color is used, and includes a fixed region that forms a pattern that assists optical reading. It is proposed that the area includes a sample area formed by arranging all kinds of reference colors on modules at predetermined positions.

かかる構成では、サンプル領域の各モジュールの色を基準にして、データを記録するモジュールの色を識別することで、各モジュールの色の識別誤りを低減できるという利点がある。すなわち、本発明の光学コードは、インキや用紙の経時変化や、プリンタや表示装置、周囲の照明等の影響によって、各モジュールの基準色の識別誤りが増大し、光学コードの読取りに支障が生じるおそれがある。こうした問題に対して、かかる構成では、サンプル領域の各モジュールの基準色は、インキや用紙の経時変化や、プリンタや表示装置、周囲の照明等の影響を受けて、データを記録するモジュールの基準色と同様に変化するから、各モジュールの色を識別する際に、サンプル領域の各モジュールの基準色と比較することで、経時変化やその他の影響を排除して、各モジュールがどの基準色で配色されているかを正確に識別できるのである。   In such a configuration, there is an advantage that the identification error of the color of each module can be reduced by identifying the color of the module for recording data on the basis of the color of each module in the sample area. That is, in the optical code of the present invention, the identification error of the reference color of each module increases due to the influence of aging of ink and paper, the printer, the display device, the ambient illumination, etc., and the reading of the optical code is hindered. There is a fear. In such a configuration, the reference color of each module in the sample area is affected by changes in ink and paper, printers, display devices, ambient lighting, etc. Since it changes in the same way as the color, when identifying the color of each module, by comparing it with the reference color of each module in the sample area, you can eliminate the change over time and other influences, which reference color each module has It is possible to accurately identify the color scheme.

また、光学コードが二次元コードである場合、汎用データ及び専用データのデータコード語を記録するデータ部と、汎用データ及び専用データの誤り訂正コード語を記録する誤り訂正部とを含み、誤り訂正部の各モジュールは、明色基準色と暗色基準色のいずれであるかの情報によって第一種の誤り訂正コード語を記録するとともに、明色基準色又は暗色基準色のうち、どの種類の基準色であるかの情報によって第二種の誤り訂正コード語を記録しており、第一種の誤り訂正コード語は、汎用データのみを訂正対象とし、第二種の誤り訂正コード語は、汎用データ及び専用データを訂正対象としており、第二種の誤り訂正コード語は、データ部のモジュール1つに記録される複数ビットのデータを、1つの誤り訂正単位に含めることが提案される。   When the optical code is a two-dimensional code, the optical code includes a data section for recording data code words for general data and dedicated data, and an error correction section for recording error correction code words for general data and dedicated data. Each module of the unit records the first type of error correction code word according to information on whether it is a light reference color or a dark reference color, and which type of reference is selected from the light reference color or the dark reference color The second type error correction code word is recorded according to the color information. The first type error correction code word is a correction target only for general-purpose data, and the second type error correction code word is a general purpose data. Data and dedicated data are subject to correction, and the second type of error correction codeword is proposed to include multiple bits of data recorded in one module of the data section in one error correction unit. That.

かかる構成にあっては、光学コードの読取時に生じるモジュールの色の識別誤りを、効率的に訂正することが可能となる。すなわち、本発明の光学コードでは、1個のモジュールを多種類の基準色で配色するため、白黒二次元コードに比べて、各モジュールの基準色の識別誤りがモジュール1個単位で散発し易いという特徴がある。モジュールの基準色の識別誤りが生じた場合、当該モジュールに記録される複数ビットのデータに集中して誤りが生じることとなるため、本構成のように、1個のモジュールに含まれる複数ビットのデータを1つの誤り訂正単位に含めておけば、基準色の識別誤りよってデータに誤りが生じた時に、誤り訂正するべき誤り訂正単位の数を減少できるのである。   With such a configuration, it becomes possible to efficiently correct an identification error in the color of the module that occurs when the optical code is read. That is, in the optical code of the present invention, since one module is arranged with various kinds of reference colors, the identification error of the reference color of each module is more likely to occur in units of modules compared to the black and white two-dimensional code. There are features. If an identification error occurs in a reference color of a module, errors occur in a concentrated manner in a plurality of bits of data recorded in the module. Therefore, as in this configuration, a plurality of bits included in one module If data is included in one error correction unit, the number of error correction units to be error-corrected can be reduced when an error occurs in the data due to an identification error of the reference color.

また、少なくとも一部のモジュールが、該モジュールよりも微細なサブモジュールにマトリクス状に細分されており、該サブモジュールに細分されたモジュールでは、各サブモジュールが前記複数種類の基準色のいずれかと識別され得るよう配色され、かつ、明色と識別されるモジュールでは、所定割合以上のサブモジュールが明色基準色で配色され、暗色と識別されるモジュールでは、前記所定割合以上のサブモジュールが暗色基準色で配色されており、専用データは、モジュールを構成する各サブモジュールが明色基準色又は暗色基準色のうち、どの種類の基準色であるかの情報によって記録される構成が提案される。   In addition, at least some of the modules are subdivided into sub-modules smaller than the module in a matrix, and each sub-module is identified as one of the plurality of types of reference colors. In a module that is color-coded and is identified as a light color, a sub-module of a predetermined ratio or more is color-coded with a light reference color, and in a module that is identified as a dark color, the sub-module of a predetermined ratio or more is a dark color reference A configuration is proposed in which the dedicated data is recorded in accordance with information indicating which type of reference color is a bright reference color or a dark reference color among the sub-modules constituting the module.

かかる構成にあっては、規格化された従来の白黒の二次元コードと互換性を保ちつつ、記録密度を一層高めることが可能となる。   In such a configuration, it is possible to further increase the recording density while maintaining compatibility with the standardized conventional black and white two-dimensional code.

また、上記構成にあって、サブモジュールに細分されたモジュールにあって、明色と識別されるモジュールは、全てのサブモジュールが明色基準色で配色され、暗色と識別されるモジュールは、全てのサブモジュールが暗色基準色で配色されていることが提案される。   Further, in the above-described configuration, the modules that are subdivided into sub-modules that are identified as light colors are all sub-modules that are arranged in a light reference color, and all modules that are identified as dark colors are all It is proposed that the sub-modules are arranged in a dark reference color.

かかる構成にあっては、1つのモジュールを構成するサブモジュールは、全て明色基準色と暗色基準色のいずれかで統一して配色されるため、白黒光学コード用の読取装置によって、各モジュールが明色と暗色のいずれであるかを正確に識別可能となる。   In such a configuration, all the sub-modules constituting one module are uniformly arranged in either the bright color reference color or the dark color reference color, so that each module is arranged by the reader for monochrome optical code. It becomes possible to accurately identify whether the color is light or dark.

また、本発明にあって、明色と識別されるモジュールからなる平行バーと、暗色と識別されるモジュールからなる平行バーとを読取方向に配列してなるバーコードである構成が提案される。   Further, in the present invention, a configuration is proposed which is a barcode in which parallel bars made up of modules identified as light colors and parallel bars made up of modules identified as dark colors are arranged in the reading direction.

かかる構成にあっては、バーコードを構成する各平行バーが、明色モジュールと暗色モジュールの一方で統一して構成されるため、かかるバーコードを、既存のバーコード読取装置で読み取った場合、明色モジュールで構成された平行バーは明色と識別され、暗色モジュールで構成された平行バーは暗色と識別される。このため、かかるバーコードに、規格化された白黒バーコードと同様に平行バーの明暗二値によって汎用データを記録すれば、当該汎用データは、既存のバーコード読取装置で読取可能なものとなり、かかるバーコードは、既存のバーコードと互換性を有するものとなる。なお、各平行バーを構成するモジュールは、平行バーごとに同一の基準色で統一して配色してもよいが、モジュールごとに各基準色に配色する方が、専用データの記録容量を高くすることができるため、好適である。   In such a configuration, since each parallel bar constituting the barcode is configured integrally with one of the light color module and the dark color module, when such a barcode is read by an existing barcode reader, Parallel bars composed of light color modules are identified as light colors, and parallel bars composed of dark color modules are identified as dark colors. For this reason, if general-purpose data is recorded in such a bar code using binary values of parallel bars in the same manner as a standard black and white bar code, the general-purpose data can be read by an existing bar code reader. Such a barcode is compatible with an existing barcode. The modules constituting each parallel bar may be unified with the same reference color for each parallel bar. However, the arrangement of the reference colors for each module increases the dedicated data recording capacity. This is preferable.

また、上記構成にあって、各モジュールが、明色基準色又は暗色基準色のうち、どの種類の基準色であるかの情報によって、汎用データの誤り訂正コード語が記録されていることが提案される。   Further, in the above configuration, it is proposed that each module records an error correction code word of general-purpose data according to information on which kind of reference color is selected from light color reference color or dark color reference color. Is done.

既存のバーコードは、誤り訂正機能を具備していないため読取エラーが生じ易く、商品用バーコードなどでは読取りに手間取ることがあるが、かかる構成にあっては、汎用データに関する誤り訂正コード語を専用の読取装置で読み取ることによって、汎用データの読取時に誤り訂正を行うことが可能となるから、既存の白黒バーコードに比べて、汎用データを容易に読取可能となる。   Existing barcodes do not have an error correction function, so reading errors are likely to occur. For product barcodes, etc., it may take time to read, but in such a configuration, error correction code words related to general-purpose data will be used. By reading with a dedicated reading device, it becomes possible to perform error correction at the time of reading the general-purpose data, so that the general-purpose data can be read easily as compared with the existing black and white barcode.

また、上記構成にあって、少なくとも一部のモジュールが読取方向と直交する方向に複数段のサブモジュールに多段化されており、各モジュールを構成するサブモジュールは、複数種類の明色基準色又は複数種類の暗色基準色に配色されていることが提案される。   Further, in the above configuration, at least some of the modules are multi-staged into a plurality of stages of submodules in a direction orthogonal to the reading direction, and each of the submodules constituting each module has a plurality of types of bright color reference colors or It is proposed that colors are arranged in a plurality of types of dark reference colors.

かかる構成にあっては、規格化された従来の白黒バーコードと互換性を保ちつつ、記録密度を一層高めることが可能となる。   With such a configuration, it is possible to further increase the recording density while maintaining compatibility with a standardized monochrome bar code.

また、上記光学コードの生成方法として、汎用データを符号化する第一の符号化ステップと、専用データを符号化する第二の符号化ステップと、符号化した汎用データ及び専用データを、モジュールごとに記録する記録単位データに分割し、該記録単位データの内容とモジュールの配色とを対応付けした符号化テーブルに基づいて、各モジュールの配色を決定する第三の符号化ステップとを実行することを特徴とする光学コードの生成方法が提案される。   In addition, as a method for generating the optical code, a first encoding step for encoding general-purpose data, a second encoding step for encoding dedicated data, and the encoded general-purpose data and dedicated data for each module. And a third encoding step for determining the color scheme of each module based on an encoding table in which the content of the recording unit data is associated with the color scheme of the module. An optical code generation method characterized by the above is proposed.

かかる方法にあっては、各モジュールの基準色を光学的に識別可能な読取装置を用いたとしても、符号化テーブルの内容を知らなければ、各モジュールの基準色から専用データを復号することができないため、光学コードに記録する専用データの秘匿性を高めることができる。   In such a method, even if a reader capable of optically identifying the reference color of each module is used, if the contents of the encoding table are not known, the dedicated data can be decoded from the reference color of each module. Therefore, the confidentiality of the dedicated data recorded on the optical code can be improved.

また、上記生成方法にあって、符号化テーブルは、前記記録単位データの内容とモジュールの配色とを一対多に対応付けしたものであり、第三の符号化ステップでは、符号化テーブルに基づいて、前記記録単位データの内容に対応する、モジュールの配色候補を複数抽出し、複数の配色候補のいずれかの配色に決定することが提案される。   Further, in the above generation method, the encoding table is a one-to-many correspondence between the contents of the recording unit data and the color scheme of the module. In the third encoding step, based on the encoding table, It is proposed to extract a plurality of module color scheme candidates corresponding to the contents of the recording unit data and determine any one of the plurality of color scheme candidates.

かかる構成にあっては、各モジュールの配色パターンから符号化テーブルの内容を推測し難くなるため、専用データの解読可能性を低減させることが可能となる。   In such a configuration, it becomes difficult to guess the contents of the encoding table from the color arrangement pattern of each module, and therefore it is possible to reduce the possibility of decoding the dedicated data.

また、上記生成方法にあって、第一の符号化ステップと第二の符号化ステップでは、汎用データと専用データを同じ方式で符号化することが提案される。   In the above generation method, it is proposed that the first encoding step and the second encoding step encode the general-purpose data and the dedicated data in the same manner.

かかる構成にあっては、第一の符号化ステップと第二の符号化ステップで、共通するアルゴリズムを用いてデータを符号化できるから、光学コードの生成プログラムを単純化できるという利点がある。また、汎用データと専用データを復号する時も、共通のアルゴリズムを使用できるから、光学コードの読取プログラムも単純化できるという利点がある。   In such a configuration, data can be encoded using a common algorithm in the first encoding step and the second encoding step, so that there is an advantage that the optical code generation program can be simplified. In addition, since a common algorithm can be used when decoding general-purpose data and dedicated data, there is an advantage that an optical code reading program can be simplified.

また、上記生成方法にあって、第三の符号化ステップでは、前記記録単位データの内容とモジュールの配色との対応付けの異なる複数の符号化テーブルから一の符号化テーブルを選択し、選択した符号化テーブルに基づいて各モジュールの配色を決定することが提案される。   Further, in the above generation method, in the third encoding step, one encoding table is selected from a plurality of encoding tables having different correspondences between the contents of the recording unit data and the color scheme of the module. It is proposed to determine the color scheme of each module based on the coding table.

光学コードに記録された専用データを復号するためには、符号化時に用いた符号化テーブルの内容を知る必要がある。符号化時に用いる符号化テーブルが共通していると、他の光学コードで使用された符号化テーブルを利用して、当該光学コードを復号されてしまうが、本構成にあっては、符号化時に用いる符号化テーブルが一定でないため、他の光学コードで使用された符号化テーブルが知られている場合でも、当該光学コードの専用データの読取を制限できる。   In order to decode the dedicated data recorded in the optical code, it is necessary to know the contents of the encoding table used at the time of encoding. If the encoding table used at the time of encoding is common, the optical code is decoded using the encoding table used by another optical code. In this configuration, at the time of encoding, Since the encoding table to be used is not constant, reading of the dedicated data of the optical code can be restricted even when the encoding table used by another optical code is known.

また、上記生成方法にあって、第一の符号化ステップでは、汎用データを、該汎用データをコード化したるデータコード語に変換するとともに、該データコード語から誤り訂正コード語を生成し、第二の符号化ステップでは、専用データを、該専用データをコード化するデータコード語に変換するとともに、該データコード語から、第一の符号化ステップに比べて誤り訂正率の低い誤り訂正コード語を生成するか、又は、誤り訂正コード語を生成しないことが提案される。   Further, in the above generation method, in the first encoding step, the general data is converted into a data code word obtained by encoding the general data, and an error correction code word is generated from the data code word. In the second encoding step, the dedicated data is converted into a data code word for encoding the dedicated data, and an error correction code having a lower error correction rate than the first encoding step is converted from the data code word. It is proposed to generate words or not generate error correction codewords.

上述のように、光学コードの符号化に用いた符号化テーブルを秘密にすることによって専用データの秘匿性を向上させることが可能となるが、これに対して、専用データの不正解読を試みる攻撃者は、考えられ得る符号化テーブルを順に適用してくる可能性がある。この場合、誤り訂正機能の誤り訂正率の範囲内で、誤りを訂正することができるため、攻撃者は、符号化に用いた符号化テーブルを選択した場合だけでなく、正しい符号化テーブルに近似する符号化テーブルを選択した場合でも、誤り訂正機能を利用して専用データを復号することができる。こうした攻撃に対し、かかる構成では、専用データについて、誤り訂正コード語の誤り訂正率を汎用データに比べて低くするか、誤り訂正コード語を記録せず誤り訂正機能を無効にするため、正しい符号化テーブルに類似する符号化テーブルが選択された場合でも、専用データが復号され難いという利点がある。   As described above, it is possible to improve the confidentiality of the dedicated data by keeping the encoding table used for encoding the optical code secret. The person may sequentially apply possible encoding tables. In this case, since the error can be corrected within the range of the error correction rate of the error correction function, the attacker approximates the correct encoding table as well as the case where the encoding table used for encoding is selected. Even when an encoding table to be selected is selected, the dedicated data can be decoded using the error correction function. In response to such an attack, in such a configuration, the error correction rate of the error correction code word is lower than that of general-purpose data, or the error correction function is disabled without recording the error correction code word. Even when an encoding table similar to the encoding table is selected, there is an advantage that the dedicated data is difficult to decode.

以上に述べたように、本発明の光学コードによれば、汎用データの部分で、規格化された従来の白黒光学コードとの互換性を保ちつつ、専用データの部分で、規格化された従来の白黒光学コードに比べて、記録密度を高めることが可能となる。   As described above, according to the optical code of the present invention, the conventional data standardized in the dedicated data portion while maintaining compatibility with the standardized monochrome optical code in the general-purpose data portion. The recording density can be increased as compared with the monochrome optical code.

(a)は実施例1の光学コード1の概略図であり、(b)は実施例1の光学コード1の各領域を機能別に模様分けして示す説明図である。(A) is the schematic of the optical code 1 of Example 1, (b) is explanatory drawing which shows each area | region of the optical code 1 of Example 1 according to the function according to the pattern. 16種類の基準色の内容を示す図表である。It is a chart which shows the contents of 16 kinds of standard colors. (a)は実施例1の光学コード1であり、(b)は実施例1の光学コード1と互換性を有する二次元コード11である。(A) is the optical code 1 of the first embodiment, and (b) is a two-dimensional code 11 having compatibility with the optical code 1 of the first embodiment. 光学コード1の生成方法を示すフローチャートである。3 is a flowchart showing a method for generating the optical code 1; 符号化処理の処理内容を示すフローチャートである。It is a flowchart which shows the processing content of an encoding process. 実施例1に係る符号化テーブルを示す図表である。6 is a chart illustrating an encoding table according to the first embodiment. 光学コード1の復号方法を示すフローチャートである。3 is a flowchart showing a method for decoding optical code 1. (a)は実施例1の光学コード1のデータ配置を示す図表であり、(b)は実施例2の光学コードのデータ配置を示す図表である。(A) is a chart showing the data arrangement of the optical code 1 of Example 1, and (b) is a chart showing the data arrangement of the optical code of Example 2. 実施例3の光学コード1aの概略図である。6 is a schematic diagram of an optical cord 1a of Example 3. FIG. (a)は、実施例3に係るモジュール2の機能領域を表す説明図であり、(b)は、実施例3に係る明色モジュール2aの概略図であり、(c)は、実施例3に係る暗色モジュール2bの概略図である。(A) is explanatory drawing showing the functional area of the module 2 which concerns on Example 3, (b) is the schematic of the light color module 2a which concerns on Example 3, (c) is Example 3. FIG. It is the schematic of the dark color module 2b which concerns on. 実施例4の光学コード1bの概略図である。6 is a schematic diagram of an optical cord 1b of Example 4. FIG. (a)は実施例4の光学コード1bであり、(b)は実施例4の光学コード1bと互換性を有するバーコード12である。(A) is the optical code 1b of Example 4, and (b) is the barcode 12 having compatibility with the optical code 1b of Example 4. 実施例4の光学コード1bのデータ配置を示す図表である。10 is a chart showing a data arrangement of an optical code 1b of Example 4. 実施例5の光学コード1cの概略図である。10 is a schematic diagram of an optical cord 1c of Example 5. FIG.

本発明の実施形態を、以下の実施例に従って説明する。   Embodiments of the present invention are described according to the following examples.

本実施例の光学コード1は、二次元コードの中で最も普及しているQRコード(登録商標)と互換性を有するものである。具体的には、図1(a)に示すように、本実施例の光学コード1は、正方形のモジュール2を、縦横に21個ずつマトリクス状に配置してなるものである。この光学コード1のモジュール2は、白色と黒色のみで構成されるものではないが、その基本構造は、QRコードに準拠したものとなっている。すなわち、図1(b)に示すように、光学コード1は、QRコードと同様に、機能パターン(固定領域)3と符号化領域4とによって構成される。機能パターン3は、QRコードにあってモジュールの配色パターンが予め定められている領域であり、光学コード1の光学的読取りを補助する位置検出パターン5、分離パターン6、タイミングパターン7などによって構成される。また、符号化領域4は、各モジュール2の配色によってデータを記録する領域であり、データコード語及び誤り訂正コード語が記録されるデータコード領域8と、形式情報を示すコードが配置される形式情報コード領域9とによって構成される。こうした構成は、基本的に、QRコードのJIS規格(JIS X 0510:2004)に準拠したものであるため詳細な説明は省略する。   The optical code 1 of this embodiment is compatible with the most popular QR code (registered trademark) among two-dimensional codes. Specifically, as shown in FIG. 1 (a), the optical code 1 of this embodiment is formed by arranging 21 square modules 2 in a matrix form vertically and horizontally. The module 2 of the optical code 1 is not composed of only white and black, but its basic structure conforms to the QR code. That is, as shown in FIG. 1B, the optical code 1 is composed of a functional pattern (fixed area) 3 and an encoding area 4 in the same manner as the QR code. The function pattern 3 is an area in the QR code where the module color pattern is predetermined, and is composed of a position detection pattern 5, a separation pattern 6, a timing pattern 7 and the like that assist optical reading of the optical code 1. The The encoding area 4 is an area in which data is recorded according to the color scheme of each module 2, and a data code area 8 in which data code words and error correction code words are recorded, and a format in which codes indicating format information are arranged. And an information code area 9. Since such a configuration basically conforms to the JIS standard (JIS X 0510: 2004) of the QR code, detailed description thereof is omitted.

モノクロ画像であるため図1(a)では十分に表されていないが、光学コード1を構成する各モジュール2は、RGB値の異なる複数種類の基準色のいずれかに配色される。図2に示すように、本実施例では、基準色は16種類存在し、各基準色に対して、2進数表記で0000から1111までの基準色コードが付されている。16種類の基準色のうち8種類は明色基準色に分類され、その他の8種類は、暗色基準色に分類される。明色基準色は全て輝度が0.75以上であり、暗色基準色は、全て輝度が0.25以下である。すなわち、輝度0.75が本発明に係る明色閾値に相当し、輝度0.25が本発明に係る暗色閾値に相当する。既存一般のQRコード用の読取装置は、QRコードの読取時に、反射率や輝度の値に基づいて、各モジュールが白色(明色)と黒色(暗色)のいずれであるかを判定するだけであるから、既存一般の読取装置では、高輝度の明色基準色で配色されたモジュールは、白色(明色)と識別される明色モジュール2aとなり、低輝度の暗色基準色で配色されたモジュールは、黒色(暗色)と識別される暗色モジュール2bとなる。本実施例では、明色モジュール2aと暗色モジュール2bの輝度差を0.5以上と大きな値にすることにより、QRコード用の読取装置が、明色モジュール2aと暗色モジュール2bとを確実に識別できるようにしている。   Although it is a monochrome image, it is not sufficiently represented in FIG. 1A, but each module 2 constituting the optical code 1 is arranged in one of a plurality of types of reference colors having different RGB values. As shown in FIG. 2, in this embodiment, there are 16 types of reference colors, and reference color codes from 0000 to 1111 are assigned to each reference color in binary notation. Of the 16 types of reference colors, 8 types are classified as light color reference colors, and the other 8 types are classified as dark color reference colors. All the bright reference colors have a luminance of 0.75 or more, and all the dark reference colors have a luminance of 0.25 or less. That is, the luminance 0.75 corresponds to the light color threshold according to the present invention, and the luminance 0.25 corresponds to the dark color threshold according to the present invention. The existing general QR code reader simply determines whether each module is white (light color) or black (dark color) based on the reflectance and luminance values when reading the QR code. Therefore, in the existing general reading apparatus, the module arranged with the high-brightness light color reference color becomes the light color module 2a identified as white (light color), and the module arranged with the low-brightness dark color reference color. Is a dark color module 2b identified as black (dark color). In this embodiment, the brightness difference between the light color module 2a and the dark color module 2b is set to a large value of 0.5 or more, so that the QR code reader can reliably identify the light color module 2a and the dark color module 2b. I can do it.

上述のように、QRコード用の読取装置は、各モジュール2が明色と暗色のいずれであるかしか識別しないが、基準色の識別機能を備えた専用の読取装置(以下、専用読取装置という)を用いることで、各モジュール2の配色を識別することができる。本実施例では、図2に示すように、各基準色間のRGB値の差が大きくなるように16種類の基準色を選択し、これにより、専用読取装置が各モジュール2がいずれの基準色であるかを正確に識別し得るようにしている。   As described above, the QR code reader recognizes only whether each module 2 is light or dark, but a dedicated reader having a reference color identification function (hereinafter referred to as a dedicated reader). ) Can be used to identify the color scheme of each module 2. In this embodiment, as shown in FIG. 2, 16 types of reference colors are selected so that the difference in RGB values between the reference colors is increased, and thus the dedicated reading device allows each module 2 to select which reference color. So that it can be accurately identified.

また、本実施例にあっては、図1(b)に示すように、専用読取装置が各モジュール2がどの基準色であるかを識別し易いように、位置検出パターン5の左上に設けられるサンプル領域5aを16種類の基準色で配色している。詳述すると、サンプル領域5aは、16個のモジュール2を16種類の基準色で1個ずつ配色してなる領域であり、サンプル領域5aが、光学コード1のどこに配設されて、サンプル領域5aのどのモジュール2がどの基準色で配色されるかは予め決定されている。このように、サンプル領域5aに含まれる各モジュール2は、常に規定された基準色で配色されているため、専用読取装置は、サンプル領域5aのモジュール2の色と比較対照することで、符号化領域4のモジュール2がどの基準色であるかを正確に識別できる。すなわち、光学コード1を撮像した画像データのRGB値から個々のモジュール2の基準色を識別する場合には、インキの経時変化や撮像環境等によって、基準色の識別誤りが生じる可能性が高くなるが、かかる構成では、サンプル領域5aのモジュール2との比較対照により基準色を決定することで、インキの経時変化や撮像環境等の影響を排除して基準色を識別できるから、基準色の識別誤りを低減できるのである。なお、サンプル領域5aでは、QRコードの位置検出パターン5にあって、白色となる位置に明色モジュール2aを配置し、黒色となる位置に暗色モジュール2bを配置しているため、サンプル領域5aが位置検出パターン5の機能を阻害することはない。また、かかるサンプル領域5aは、16種類の基準色で配色された光学コード1であることを示す識別コードとしても機能できる。   Further, in this embodiment, as shown in FIG. 1B, the dedicated reading device is provided on the upper left of the position detection pattern 5 so as to easily identify which reference color each module 2 is. The sample area 5a is colored with 16 kinds of reference colors. More specifically, the sample area 5a is an area formed by arranging 16 modules 2 one by one with 16 kinds of reference colors, and the sample area 5a is disposed anywhere on the optical code 1 so that the sample area 5a is arranged. Which of the modules 2 is arranged with which reference color is determined in advance. In this way, since each module 2 included in the sample area 5a is always arranged in a standard color that is defined, the dedicated reading device performs encoding by comparing and contrasting with the color of the module 2 in the sample area 5a. It is possible to accurately identify which reference color the module 2 in the region 4 is. That is, when the reference color of each module 2 is identified from the RGB value of the image data obtained by imaging the optical code 1, there is a high possibility that the identification error of the reference color will occur due to the change of ink over time or the imaging environment. However, in such a configuration, the reference color can be identified by determining the reference color by comparing with the module 2 in the sample area 5a, thereby eliminating the influence of the change with time of the ink and the imaging environment. Errors can be reduced. In the sample area 5a, the light color module 2a is arranged at the position where the color is white and the dark module 2b is arranged at the position where the color is black in the position detection pattern 5 of the QR code. The function of the position detection pattern 5 is not hindered. The sample area 5a can also function as an identification code indicating that the optical code 1 is colored with 16 kinds of reference colors.

このように、本実施例の光学コード1にあっては、符号化領域4の各モジュール2が16種類の基準色で配色されるため、白黒光学コードでは1モジュール当たり1ビットの情報しか記録できないのに対し、本実施例の光学コード1では1モジュール当たり4ビットの情報を記録できる。ここで、本実施例にあって、各モジュール2が明色基準色と暗色基準色のいずれであるかは、QRコード用の読取装置でも識別可能であり、また、各モジュール2が明色基準色と暗色基準色のうち、どの基準色であるかは、QRコード用の読取装置では識別できない。このため、本実施例にあっては、各モジュール2が、明色基準色と暗色基準色のいずれであるかの情報によって、QRコード用の読取装置でも読取可能な汎用データを記録し、各モジュール2が、明色基準色と暗色基準色のうち、どの基準色であるかの情報によって、専用読取装置でしか読み取ることのできない専用データを記録している。   As described above, in the optical code 1 of the present embodiment, each module 2 in the encoding area 4 is arranged with 16 kinds of reference colors, so that the monochrome optical code can record only 1 bit of information per module. In contrast, the optical code 1 of this embodiment can record 4-bit information per module. Here, in this embodiment, whether each module 2 is a bright color reference color or a dark color reference color can be identified by a QR code reader, and each module 2 can be identified as a light color reference color. Which reference color is the color or dark reference color cannot be identified by a QR code reader. For this reason, in this embodiment, each module 2 records general-purpose data that can be read by a QR code reading device according to information on whether the light color reference color or the dark color reference color. The module 2 records dedicated data that can be read only by a dedicated reading device according to information on which reference color is a bright color reference color or a dark color reference color.

具体的には、汎用データは、QRコードの規格にしたがって、光学コード1の符号化領域4に、明色基準色と暗色基準色とによる明暗二値のパターンとして記録される。かかる光学コード1をQRコード用の読取装置に読み取らせた場合、当該読取装置は、各モジュール2の色を詳細に識別することなく、明色モジュール2aを白色(明色)と、暗色モジュール2bを黒色(暗色)と識別し、QRコードの復号処理にしたがって汎用データを復号する。図3(a)は、本実施例の光学コード1であり、図3(b)は、図3(a)の光学コード1にあって、明色基準色を全て白塗りとし、暗色基準色を全て黒塗りとして得られたQRコード11である。このQRコード11は、モジュールの明暗二値パターンによって光学コード1と同じ汎用データを記録したものであるから、QRコード用の読取装置で図3の光学コード1とQRコード11とを読み取った場合には、いずれも同じ汎用データが読み取られることとなる。すなわち、本実施例の光学コード1は、QRコード用の読取装置に対しては、QRコードの同等品として機能し得るものであり、QRコードと互換性を有するものとなっている。   Specifically, the general-purpose data is recorded in the encoding area 4 of the optical code 1 as a light / dark binary pattern based on the light reference color and the dark reference color in accordance with the QR code standard. When the optical code 1 is read by a QR code reading device, the reading device recognizes the light color module 2a as white (light color) and the dark color module 2b without identifying the color of each module 2 in detail. Is identified as black (dark color), and the general-purpose data is decoded according to the QR code decoding process. FIG. 3A shows the optical code 1 of the present embodiment, and FIG. 3B shows the optical code 1 of FIG. 3A, in which all the light color reference colors are white and dark color reference colors. Is the QR code 11 obtained as a black paint. Since this QR code 11 records the same general-purpose data as the optical code 1 by the light / dark binary pattern of the module, when the optical code 1 and the QR code 11 in FIG. 3 are read by a QR code reader In both cases, the same general-purpose data is read. That is, the optical code 1 of this embodiment can function as an equivalent of the QR code to the QR code reader, and is compatible with the QR code.

汎用データが各モジュール2の明暗二値のパターンとして記録されるのに対し、専用データは、符号化領域4にあって、各モジュール2が明色基準色と暗色基準色のうち、どの基準色であるかの情報によって記録される。明色基準色と暗色基準色は、夫々8種類ずつ存在するため、専用データは、モジュール2ごとに3ビット記録することができる。すなわち、本実施例の光学コード1には、汎用データの3倍の容量の専用データを記憶できる。汎用データの記憶容量は、同じモジュール数のQRコード11の記憶容量と同じであるから、本実施例の光学コード1では、QRコードの4倍の記憶密度が実現される。   The general-purpose data is recorded as a light / dark binary pattern of each module 2, whereas the dedicated data is in the encoding area 4 and each module 2 has which reference color of the light color reference color and the dark color reference color. It is recorded by the information of whether or not. Since there are eight types of light color reference colors and dark color reference colors, 3 bits of dedicated data can be recorded for each module 2. That is, the optical code 1 of this embodiment can store dedicated data having a capacity three times that of general-purpose data. Since the storage capacity of the general-purpose data is the same as the storage capacity of the QR code 11 having the same number of modules, the optical code 1 of the present embodiment realizes a storage density four times that of the QR code.

また、光学コード1の各モジュール2の基準色は、QRコード用の読取装置では識別できず、専用読取装置でないと識別できないため、光学コード1に記録される専用データは一定の秘匿性を有している。このため、本実施例の光学コード1では、公開情報を汎用データとして記録し、秘匿情報を専用データとして記録することで、公開情報と秘匿情報の二種類の情報を記録できるという利点がある。特に、本実施例では、秘匿情報(専用データ)は、汎用データを記録するモジュール2の明暗二値パターンとは独立した配色パターンで記録されるため、秘匿情報(専用データ)の情報量によって、公開情報(汎用データ)の情報量が制限されることがない。また、専用データは、汎用データよりも多量の情報を記録可能であるから、本実施例の光学コード1には、公開情報に比べて多量の秘匿情報を記録できるという利点がある。   Further, since the reference color of each module 2 of the optical code 1 cannot be identified by a QR code reader, and cannot be identified unless it is a dedicated reader, the dedicated data recorded on the optical code 1 has a certain level of confidentiality. doing. For this reason, the optical code 1 of the present embodiment has an advantage that two types of information, that is, public information and confidential information can be recorded by recording public information as general-purpose data and recording confidential information as dedicated data. In particular, in the present embodiment, the confidential information (dedicated data) is recorded in a color arrangement pattern independent of the light / dark binary pattern of the module 2 that records the general-purpose data. Therefore, depending on the information amount of the confidential information (dedicated data), The amount of information of public information (general data) is not limited. In addition, since the dedicated data can record a larger amount of information than the general-purpose data, the optical code 1 of this embodiment has an advantage that a larger amount of confidential information can be recorded than public information.

また、本実施例では、光学コード1に3セットの専用データを記録し得るよう構成されている。3セットの専用データは、符号化領域4の異なるモジュール2に記録されるのではなく、符号化領域4の各モジュール2に重複するように記録される。具体的には、符号化領域4の各モジュール2に専用データを3ビット記録し得るところ、各モジュール2に各セットの専用データが1ビットずつ記録される。すなわち、光学コード1に専用データを1セット記録する場合は、符号化された専用データが各モジュール2に1ビットずつ記録される。また、3セットの専用データを光学コード1に記録する場合は、各モジュール2に、1ビットの専用データが3セット分(3ビット)記録されることとなる。かかる専用データの記録態様は、光学コード1の生成方法によって詳述する。   In this embodiment, three sets of dedicated data can be recorded on the optical code 1. The three sets of dedicated data are not recorded in different modules 2 in the encoding area 4 but are recorded so as to overlap each module 2 in the encoding area 4. Specifically, 3 bits of dedicated data can be recorded in each module 2 in the encoding area 4, but 1 bit of each set of dedicated data is recorded in each module 2. That is, when one set of dedicated data is recorded on the optical code 1, the encoded dedicated data is recorded on each module 2 by one bit. When three sets of dedicated data are recorded on the optical code 1, 1 set of dedicated data is recorded in each module 2 for three sets (3 bits). The recording mode of the dedicated data will be described in detail by a method for generating the optical code 1.

以下に、上記光学コード1の生成方法について説明する。
図4は、上記光学コード1を生成するフローチャートである。まず、ステップS100では、光学コード1に記録すべきデータセットの準備を行う。データセットとは、1セットの汎用データDS0と、1〜3セットの専用データDS1、DS2,DS3である。
Hereinafter, a method for generating the optical code 1 will be described.
FIG. 4 is a flowchart for generating the optical code 1. First, in step S100, a data set to be recorded on the optical code 1 is prepared. The data set is one set of general-purpose data DS0 and one to three sets of dedicated data DS1, DS2, DS3.

次のステップS110では、汎用データDS0について、通常のQRコードの生成手続に則って二次元コード化し、QRコードの配色パターンに相当するコードA0を生成する。すなわち、このコードA0は、汎用データDS0を記録するQRコード11(図3(b参照))のコードそのものであり、このコードA0には、機能パターン3及び符号化領域4を構成する各モジュール2の明暗二値パターンが含まれる。この手続は、QRコードの手続であるため、詳細な説明は省略する。   In the next step S110, the general-purpose data DS0 is two-dimensionally encoded in accordance with a normal QR code generation procedure, and a code A0 corresponding to the color arrangement pattern of the QR code is generated. That is, the code A0 is the code itself of the QR code 11 (see FIG. 3B) for recording the general-purpose data DS0. The code A0 includes the function pattern 3 and the modules 2 constituting the encoding area 4. The light / dark binary pattern is included. Since this procedure is a QR code procedure, a detailed description thereof will be omitted.

次のステップS120,S130では、専用データDS1,DS2,DS3について、通常のQRコードの生成手続に則って二次元コード化し、QRコードの配色パターンに相当するコードA1,A2,A3を夫々生成する。すなわち、このコードA1,A2,A3は、専用データDS1,DS2,DS3を記録するQRコードのデータそのものである。なお、コードA1,A2,A3の生成時には、上記コードA0と合成し得るように、コードA0と同じバージョンのQRコードとなるようにする。また、コードA1〜A3には、QRコードの規格に則った誤り訂正コード語が付加されることとなるが、本実施例にあっては、専用データの不正解読を困難にするために、夫々の誤り訂正レベルをコードA0よりも低くして、QRコードの最低レベルとなるようにする。専用データDS1,DS2,DS3のコード化は、QRコードの手続と同じであるため、詳細な説明は省略する。   In the next steps S120 and S130, the dedicated data DS1, DS2, and DS3 are two-dimensionally encoded in accordance with a normal QR code generation procedure, and codes A1, A2, and A3 corresponding to the QR code color pattern are generated. . That is, the codes A1, A2, and A3 are QR code data themselves that record the dedicated data DS1, DS2, and DS3. When the codes A1, A2 and A3 are generated, the QR code has the same version as the code A0 so that it can be combined with the code A0. In addition, an error correction code word conforming to the QR code standard is added to the codes A1 to A3. In this embodiment, in order to make it difficult to illegally decode the dedicated data, respectively. Is made lower than the code A0 so as to be the lowest level of the QR code. Since the encoding of the dedicated data DS1, DS2, DS3 is the same as the procedure of the QR code, detailed description is omitted.

ステップS130までの手続によって、1セットの汎用データDS0と、1〜3セットの専用データDS1,DS2,DS3とを夫々記録する、データ上のQRコードA0,A1,A2,A3が得られる。上述のように、これらのQRコードA0〜A3は、夫々の機能パターンと符号化領域が重なり合うように同一バージョンで生成される。これらのQRコードA0〜A3について、重なり合うモジュールごとに夫々の色を合成し、上記光学コード1のモジュール2の配色パターンに変換するのがステップS200の符号化処理である。なお、図4のフローチャートに示す光学コード1の生成方法にあって、本発明に係る第一の符号化ステップは、ステップS110によって主に実現される。また、本発明に係る第二の符号化ステップは、ステップS120によって主に実現される。また、本発明に係る第三の符号化ステップは、ステップS200によって主に実現される。   By the procedure up to step S130, QR codes A0, A1, A2, and A3 on the data that record one set of general-purpose data DS0 and one to three sets of dedicated data DS1, DS2, and DS3, respectively, are obtained. As described above, these QR codes A0 to A3 are generated in the same version so that the respective function patterns overlap with the coding areas. The coding process of step S200 is to synthesize the respective colors of these QR codes A0 to A3 for each overlapping module and convert them into the color arrangement pattern of the module 2 of the optical code 1. In the method of generating the optical code 1 shown in the flowchart of FIG. 4, the first encoding step according to the present invention is mainly realized by step S110. The second encoding step according to the present invention is mainly realized by step S120. The third encoding step according to the present invention is mainly realized by step S200.

符号化処理S200では、QRコードA0,A1,A2,A3を合成することにより、光学コード1の各モジュール2の配色を決定する。具体的には、生成する光学コード1の一辺のモジュール数をNとすると、光学コード1全体では、N個のモジュール2が存在し、QRコードA0,A1,A2,A3にも、N個のモジュールの配色パターンが存在する。このN個のモジュール2全てについての配色を1つずつ決定する。より具体的には、QRコードの、縦のモジュールのインデックスをI,横のモジュールのインデックスをJとすると、I=1からN、J=1からNまでの組合せで全てのモジュールを表現できる。I,Jで示されるモジュールの色をC(I,J)で表現する。また、コードをA0,A1,A2,A3をKで示すとすると、C(I,J,K)で示すことが可能となる。ここで、Kは0から3である。 In the encoding process S200, the color code of each module 2 of the optical code 1 is determined by combining the QR codes A0, A1, A2, and A3. Specifically, when the number of modules one side of the optical code 1 for generating a N, the whole optical code 1, there are N 2 pieces of module 2, also QR code A0, A1, A2, A3, N 2 There is a color scheme pattern of modules. The color scheme for all the N 2 modules 2 is determined one by one. More specifically, assuming that the vertical module index of the QR code is I and the horizontal module index is J, all modules can be expressed by combinations of I = 1 to N and J = 1 to N. The color of the module indicated by I and J is expressed by C (I, J). If the codes A0, A1, A2, and A3 are represented by K, they can be represented by C (I, J, K). Here, K is 0 to 3.

図5は、符号化処理の処理内容を示したフローチャートである。ステップS210では、IとJで指定されるモジュール2について、それが機能パターン3を構成するモジュール2であるか否かを判定する。そして、機能パターン3を構成するモジュール2であると判定した場合は、ステップS220で、当該モジュール2の位置に基づいて配色を決定する。一方、符号化領域4を構成するモジュール2であると判定した場合は、次のステップS230でQRコードA0〜A3の配色パターンを読み込む。具体的には、C(I,J,K)(Kは0から3)の配色データを読み込み、各モジュールが0か1(白か黒)かを識別する。次に、ステップS240では、QRコードA0,A1,A2,A3の当該モジュールの配色パターンを結合する。具体的には、4セットのQRコードA0,A1,A2,A3を記録する場合は、例えば白白黒白(0010)のように、各セットの当該モジュールの色の組合せを作る。この4つの色の組合せが、1個のモジュール2に記録する汎用データ及び専用データの記録単位となる。次に、ステップS250では、モジュール2の配色を決定するための符号化テーブルの選択を行う。符号化テーブルは、図6に示すように、モジュール2に記録するデータと当該モジュール2の基準色コードとを1対1に対応付けしたものである。この符号化テーブルは、常に同じものを使用することもできるが、対応付けの異なる複数種類の符号化テーブルを選択的に用いて、使用した符号化テーブルの内容を知る者を制限することで、専用データの秘匿性を高めることができる。そして、ステップS260では、選択した符号化テーブルを用いて、記録単位となる4つの色の組合せからモジュール2の配色を決定する。ステップS270では、すべてのモジュール2について、上記の処理が完了したかを判定し、すべてのモジュール2の処理が完了した場合は符号化処理を終了する。   FIG. 5 is a flowchart showing the contents of the encoding process. In step S210, it is determined whether or not the module 2 designated by I and J is the module 2 constituting the function pattern 3. If it is determined that the module 2 constitutes the function pattern 3, the color arrangement is determined based on the position of the module 2 in step S220. On the other hand, if it is determined that the module 2 is included in the coding area 4, the color arrangement pattern of the QR codes A0 to A3 is read in the next step S230. Specifically, the color arrangement data of C (I, J, K) (K is 0 to 3) is read to identify whether each module is 0 or 1 (white or black). Next, in step S240, the color scheme patterns of the modules of the QR codes A0, A1, A2, and A3 are combined. Specifically, when four sets of QR codes A0, A1, A2, and A3 are recorded, a color combination of the module of each set is created, for example, white, white, white, and white (0010). The combination of these four colors becomes a recording unit for general-purpose data and dedicated data to be recorded in one module 2. Next, in step S250, a coding table for determining the color scheme of module 2 is selected. As shown in FIG. 6, the encoding table is a one-to-one correspondence between the data recorded in the module 2 and the reference color code of the module 2. The same encoding table can always be used, but by selectively using a plurality of types of encoding tables with different correspondences, by limiting the number of people who know the contents of the used encoding table, The confidentiality of the dedicated data can be improved. In step S260, using the selected encoding table, the color scheme of module 2 is determined from the combination of four colors serving as recording units. In step S270, it is determined whether or not the above processing has been completed for all modules 2. If the processing of all modules 2 has been completed, the encoding processing is terminated.

このように、本実施例の光学コード1の生成方法では、汎用データDS0及び専用データDS1,DS2,DS3を夫々QRコード化し、データ上のQRコードA0,A1,A2,A3を合成することによって、光学コード1の配色を決定する。かかる生成方法では、汎用データと専用データの双方を、QRコードの符号化方式に則って符号化するため、汎用データと専用データの符号化に共通のアルゴリズムを用いることにより、光学コード1の生成プログラムを簡素化できるという利点がある。また、かかる生成方法によって生成された光学コード1は、汎用データと専用データの復号時にも共通のアルゴリズムを用いることができるから、光学コード1の読取プログラムも簡素化できる。   As described above, in the method for generating the optical code 1 of the present embodiment, the general-purpose data DS0 and the dedicated data DS1, DS2, DS3 are respectively QR-coded, and the QR codes A0, A1, A2, A3 on the data are synthesized. The color arrangement of the optical code 1 is determined. In such a generation method, since both the general-purpose data and the dedicated data are encoded in accordance with the QR code encoding method, the optical code 1 is generated by using a common algorithm for encoding the general-purpose data and the dedicated data. There is an advantage that the program can be simplified. Further, since the optical code 1 generated by such a generation method can use a common algorithm when decoding general-purpose data and dedicated data, the reading program for the optical code 1 can be simplified.

また、かかる生成方法では、符号化テーブルを用いて各モジュール2に記録するデータを16種類の基準色のいずれかに変換して記録している。符号化テーブルの内容は予め任意に定められるものであり、適用するシステム毎に内容が異なるため、この符号化テーブルを秘匿することにより、専用データを第三者から保護することができる。なお、汎用データに関してはQRコードと互換性をもたせる必要があるため、各モジュール2を明色基準色と暗色基準色のいずれで配色するかに関しては、符号化テーブルの内容に関わらず、QRコードの生成手順に則って一義的に決定されるよう構成されている。   In such a generation method, data to be recorded in each module 2 is converted into one of 16 types of reference colors and recorded using an encoding table. The content of the encoding table is arbitrarily determined in advance, and the content differs depending on the system to be applied. Therefore, by concealing this encoding table, the dedicated data can be protected from a third party. Since general-purpose data must be compatible with the QR code, the QR code is used regardless of the content of the encoding table as to whether each module 2 is color-coded in the light color reference color or the dark color reference color. It is comprised so that it may be determined uniquely according to the production | generation procedure.

なお、図6に示した符号化テーブルでは、1つのモジュール2に記録する4ビットのデータと、16種類の基準色コードとが1対1に対応付けされているため、上述のように、1セットの汎用データDS0と3セットの専用データDS1〜DS3を光学コード1に記録する場合には、モジュール2に記録するデータから、当該モジュール2の配色を一義的に決定することが可能である。一方で、光学コード1に、汎用データと専用データを1セットずつ(例えばDS0とDS1)しか記録しない場合には、符号化テーブルにおいて、1つのモジュール2に記録するデータ(2ビット)と、16種類の基準色コードとが1対4に対応付けされることとなり、モジュール2に記録するデータから当該モジュール2の配色を一義的に決定できなくなる。このため、かかる場合は、記録するデータの組合せに対応する4種類の基準色を当該モジュール2の配色候補として抽出し、抽出した配色候補の中から抽選等によって当該モジュール2の基準色を選択すればよい。このように、符号化テーブルにあって、1つのモジュール2に記録するデータと、当該モジュール2の配色とが1対多で対応する場合には、光学コード1から符号化テーブルの内容を推測され難くなるため、専用データの秘匿性を高めることができるという利点がある。   In the encoding table shown in FIG. 6, 4-bit data to be recorded in one module 2 and 16 types of reference color codes are associated with each other on a one-to-one basis. When the set of general-purpose data DS0 and the three sets of dedicated data DS1 to DS3 are recorded in the optical code 1, the color scheme of the module 2 can be uniquely determined from the data recorded in the module 2. On the other hand, when only one set of general-purpose data and dedicated data (for example, DS0 and DS1) is recorded in the optical code 1, data (2 bits) to be recorded in one module 2 in the encoding table, 16 The types of reference color codes are associated with each other on a one-to-four basis, and the color scheme of the module 2 cannot be uniquely determined from the data recorded in the module 2. Therefore, in such a case, four types of reference colors corresponding to the combination of data to be recorded are extracted as color scheme candidates for the module 2, and the reference color of the module 2 is selected from the extracted color scheme candidates by lottery or the like. That's fine. Thus, in the encoding table, when the data to be recorded in one module 2 and the color scheme of the module 2 correspond one-to-many, the contents of the encoding table are estimated from the optical code 1. Since it becomes difficult, there is an advantage that the confidentiality of the dedicated data can be improved.

次に、実施例1の光学コード1を専用読取装置で読み取る際の読取方法を説明する。
図7は、専用読取装置による光学コードの読取処理を示すフローチャートである。最初のステップS300では、読取装置に設けられた撮像装置によって光学コード1を撮像する。次に、ステップS310では、撮像した画像からQRコードの画像識別手順にしたがって光学コード1を識別し、モジュール2の切り出しを行う。具体的には、各モジュール2について、画像から該当するピクセルデータを抽出する。次に、ステップS320では、光学コード1の機能パターン3に上記サンプル領域5aが存在するか否かを判定する。そして、判定の結果、サンプル領域5aが存在しない、すなわち通常のQRコードであると判断した時には、ステップS330に進み、通常のQRコードの読取処理を行い、QRコードに記録されたデータを読み取って読取処理を終了する。このQRコードの読取処理は公知であるため、詳細な説明は省略する。一方、ステップS320において、サンプル領域5aが存在すると判断した場合には、ステップS340に進み、サンプル領域5aに含まれる16種類の基準色を比較対照として抽出し、RGB値を測定する。
Next, a reading method when reading the optical code 1 of the first embodiment with a dedicated reading device will be described.
FIG. 7 is a flowchart showing an optical code reading process by the dedicated reading device. In the first step S300, the optical code 1 is imaged by an imaging device provided in the reading device. Next, in step S310, the optical code 1 is identified from the captured image according to the QR code image identification procedure, and the module 2 is cut out. Specifically, for each module 2, the corresponding pixel data is extracted from the image. Next, in step S320, it is determined whether or not the sample area 5a exists in the function pattern 3 of the optical code 1. As a result of the determination, when it is determined that the sample area 5a does not exist, that is, it is a normal QR code, the process proceeds to step S330, where a normal QR code reading process is performed, and the data recorded in the QR code is read. The reading process ends. Since this QR code reading process is known, a detailed description thereof will be omitted. On the other hand, if it is determined in step S320 that the sample area 5a exists, the process proceeds to step S340, where 16 types of reference colors included in the sample area 5a are extracted as comparison references, and RGB values are measured.

次に、ステップS350では、抽出した各モジュール2の画像データから当該モジュール2がどの基準色であるかを識別する。具体的には、当該モジュール2の色をRGB値などに数値化し、当該数値をサンプル領域5aから抽出した各基準色の数値と比較して、最も数値の近似する基準色が当該モジュール2の色であると特定する。そして、ステップS360では、S350で特定した当該モジュール2の基準色を、予め記憶された復号テーブルに基づいて、当該モジュール2に記録された4ビットのデータに復号する。復号テーブルは、光学コードの生成時に使用した符号化テーブル(図6参照)と略同内容のものであり、かかる復号テーブルによって、当該モジュール2の基準色コードは、黒黒白黒などの、モジュール単位で記録された4つの色の組合せに変換される。ステップS350,360は、符号化領域4の各モジュール2について一個ずつ繰り返される。そして、ステップS370で、すべてのモジュール2について、上記の処理が完了したかを判定し、すべてのモジュール2の処理が完了した場合は、ステップS380に進む。ステップS380では、モジュール2ごとに復号した4ビットのデータをデータセットごとに結合して、各データセットのデータDS0〜DS3をコード化したQRコードA0〜A3を得る。そして、ステップS390では、専用データを記録するQRコードA1,A2,A3を、通常のQRコードの復号手順にしたがって、専用データDS1、DS2,DS3に復号する。そして、次のステップS400では、汎用データを記録するQRコードA0を、通常のQRコードの復号手順にしたがって汎用データDS0に復号し、光学コード1の読取処理を終了する。   In step S350, the reference color of the module 2 is identified from the extracted image data of each module 2. Specifically, the color of the module 2 is converted into an RGB value or the like, and the numerical value is compared with the numerical value of each reference color extracted from the sample area 5a. To be identified. In step S360, the reference color of the module 2 identified in S350 is decoded into 4-bit data recorded in the module 2 based on a previously stored decoding table. The decoding table has substantially the same contents as the encoding table (see FIG. 6) used when generating the optical code. With this decoding table, the reference color code of the module 2 is a module unit such as black, black and white. Is converted into a combination of the four colors recorded. Steps S350 and 360 are repeated one by one for each module 2 in the coding area 4. In step S370, it is determined whether the above processing is completed for all modules 2. If the processing for all modules 2 is completed, the process proceeds to step S380. In step S380, the 4-bit data decoded for each module 2 is combined for each data set to obtain QR codes A0 to A3 obtained by coding the data DS0 to DS3 of each data set. In step S390, the QR codes A1, A2, and A3 for recording the dedicated data are decoded into dedicated data DS1, DS2, and DS3 in accordance with a normal QR code decoding procedure. In the next step S400, the QR code A0 for recording the general-purpose data is decoded into the general-purpose data DS0 according to a normal QR code decoding procedure, and the optical code 1 reading process is terminated.

以上の光学コード1の読取方法からもわかるように、本実施例の光学コード1では、汎用データがQRコードの規格に準じて二次元コード化され、各モジュール2が明色と暗色のいずれであるかの情報によって記録されているため、QRコード用の読取装置で汎用データを読み取ることができる。一方、専用データは、各モジュール2がどの基準色であるかの情報によって記録され、また、符号化テーブルによって暗号化されているため、16種類の基準色を光学的に識別でき、なおかつ、符号化テーブルに対応する復号テーブルを記憶した専用読取装置でなければ読み取ることができないようになっている。   As can be seen from the optical code 1 reading method described above, in the optical code 1 of this embodiment, general-purpose data is two-dimensionally encoded according to the QR code standard, and each module 2 can be either light or dark. Since it is recorded according to certain information, general-purpose data can be read by a QR code reader. On the other hand, the dedicated data is recorded by information on which reference color each module 2 is, and since it is encrypted by the encoding table, 16 kinds of reference colors can be optically identified, and the code Only the dedicated reader that stores the decoding table corresponding to the conversion table can be read.

次に、本実施例の光学コード1の誤り訂正方法について説明する。
本実施例の光学コード1の誤り訂正方法は、QRコードの誤り訂正方法に基づくものであるため、まず、QRコードの誤り訂正方法について説明すると、QRコードでは、符号化領域にデータコード語を記録するデータ部と、誤り訂正コード語を記録する誤り訂正部が設けられる。誤り訂正コード語は、リードソロモン符号の方法によってデータコード後から生成される。リードソロモン符号は、複数ビットを誤り訂正単位(シンボル)として訂正を行うものであり、QRコードでは、8ビットのデータコード語を1シンボルとして、誤り訂正コード語を生成している。
Next, an error correction method for the optical code 1 of this embodiment will be described.
Since the error correction method of the optical code 1 of the present embodiment is based on the error correction method of the QR code, first, the error correction method of the QR code will be described. In the QR code, the data code word is stored in the encoding area. A data portion to be recorded and an error correction portion to record the error correction code word are provided. The error correction code word is generated after the data code by the Reed-Solomon code method. The Reed-Solomon code corrects a plurality of bits as error correction units (symbols), and the QR code generates an error correction code word using an 8-bit data code word as one symbol.

そして、実施例1では、上述のように、汎用データ及び専用データの各データセットDS0〜DS3を、QRコードの配色パターンに相当するコードA0〜A3に変換して記録する。この時、各データセットDS0〜DS3は、QRコードの生成方法に則って、夫々データコード語に変換されるとともに、データコード語を訂正するための誤り訂正コード語が付加される。具体的には、汎用データのデータセットDS0は、データコード語Ad0に変換されるとともに、8ビットのデータコード語Ad0を1シンボルとして誤り訂正コード語Ac0が生成される。同様に、専用データのデータセットDS1〜DS3も、夫々データコード語Ad1,Ad2,Ad3に変換され、各データコード語Ad1,Ad2,Ad3の8ビットを1シンボルとして、誤り訂正コード語Ac1,Ac2,Ac3が生成される。   In the first embodiment, as described above, the data sets DS0 to DS3 of general-purpose data and dedicated data are converted into codes A0 to A3 corresponding to the color arrangement pattern of the QR code and recorded. At this time, each of the data sets DS0 to DS3 is converted into a data code word according to a QR code generation method, and an error correction code word for correcting the data code word is added. Specifically, the general-purpose data set DS0 is converted into the data code word Ad0, and the error correction code word Ac0 is generated with the 8-bit data code word Ad0 as one symbol. Similarly, the data sets DS1 to DS3 of dedicated data are also converted into data code words Ad1, Ad2, Ad3, respectively, and the error correction code words Ac1, Ac2 are set with 8 bits of each data code word Ad1, Ad2, Ad3 as one symbol. , Ac3 is generated.

図8(a)は、実施例1の光学コード1のデータ配置を示したものである。ここで、「表層」とは、モジュール2の明暗二値パターンによって1モジュールに1ビット記録される、QRコード用の読取装置で読取可能なデータ領域であり、「内層」とは、さらに詳細な基準色の種類によって1モジュールに3ビット記録される、QRコード用の読取装置で読取不能なデータ領域である。符号化領域4にあって、汎用データのデータコード語Ad0は表層のデータ部に記録され、汎用データの誤り訂正コード語Ac0は、表層の誤り訂正部に記録される。また、符号化領域4にあって、専用データのデータコード語Ad1,Ad2,Ad3は内層のデータ部に記録され、誤り訂正コード語Ac1,Ac2,Ac3は内層の誤り訂正部に記録される。   FIG. 8A shows the data arrangement of the optical code 1 of the first embodiment. Here, the “surface layer” is a data area readable by a QR code reader, in which one bit is recorded in one module by the light / dark binary pattern of the module 2, and the “inner layer” is more detailed. This is a data area in which 3 bits are recorded in one module depending on the type of the reference color and cannot be read by a QR code reader. In the encoding area 4, the data code word Ad0 of general-purpose data is recorded in the data portion of the surface layer, and the error correction code word Ac0 of general-purpose data is recorded in the error correction portion of the surface layer. In the encoding area 4, the data code words Ad1, Ad2, Ad3 of the dedicated data are recorded in the inner layer data portion, and the error correction code words Ac1, Ac2, Ac3 are recorded in the inner layer error correction portion.

このように、本実施例では、光学コード1に記録するデータセットDS0〜DS3ごとに、QRコードの生成手順に則って誤り訂正コード語Ac0〜Ac3を生成し、データコード語Ad0〜Ad3とともに符号化領域4に記録している。なお、このように記録された誤り訂正コード語Ac0〜Ac3は、光学コード1の読取処理において、各データセットのコードA0〜A3を復号する際に用いられる。各データセットの誤り訂正は、QRコードの誤り訂正手順に則って行われるため、詳細な説明は省略する。   As described above, in this embodiment, for each of the data sets DS0 to DS3 recorded in the optical code 1, the error correction code words Ac0 to Ac3 are generated according to the QR code generation procedure, and the data code words Ad0 to Ad3 are encoded. Is recorded in the recording area 4. The error correction code words Ac0 to Ac3 recorded in this way are used when decoding the codes A0 to A3 of each data set in the reading process of the optical code 1. Since error correction of each data set is performed in accordance with the error correction procedure of QR code, detailed description is omitted.

本実施例は、上記実施例1から誤り訂正方法を変更したものである。誤り訂正方法以外の構成は、実施例1と同じであるため、構成の共通する部分は図中及び文中で符号を共通させて説明を省略する。   In the present embodiment, the error correction method is changed from the first embodiment. Since the configuration other than the error correction method is the same as that of the first embodiment, the common parts of the configuration are denoted by the same reference numerals in the drawings and text, and the description thereof is omitted.

本実施例は、データコード語Ad0〜Ad3を記録する2個のモジュール2に記録される8ビットのデータを、誤り訂正単位(シンボル)とした誤り訂正コード語を記録することを特徴とする。詳述すると、上記実施例1では、8ビットのデータコード語Ad0を1シンボルとして誤り訂正コード語Ac0が生成され、8ビットのデータコード語Ad1を1シンボルとして誤り訂正コード語Ac1が生成されるといった具合に、データセットごとに誤り訂正コード語Ac0〜Ac3を生成している。これに対して、本実施例では、2モジュールに記録される8ビットのデータを1シンボルとする誤り訂正コード語Ac4を生成し、専用データに関する誤り訂正コード語Ac1〜Ac3に代えて光学コードに記録する。なお、QRコードとの互換性を保つ目的で、汎用データに関する誤りコード語Ac0に関しては、実施例1と同様に、データコード語Ad0から生成して光学コードに記録する。   The present embodiment is characterized in that an error correction code word is recorded with 8-bit data recorded in two modules 2 for recording data code words Ad0 to Ad3 as an error correction unit (symbol). More specifically, in the first embodiment, the error correction code word Ac0 is generated using the 8-bit data code word Ad0 as one symbol, and the error correction code word Ac1 is generated using the 8-bit data code word Ad1 as one symbol. In other words, error correction code words Ac0 to Ac3 are generated for each data set. On the other hand, in the present embodiment, an error correction code word Ac4 is generated with 8 bits of data recorded in two modules as one symbol, and an optical code is used instead of the error correction code words Ac1 to Ac3 related to dedicated data. Record. For the purpose of maintaining compatibility with the QR code, the error code word Ac0 related to general-purpose data is generated from the data code word Ad0 and recorded in the optical code as in the first embodiment.

より具体的には、本実施例の光学コードの生成時には、実施例1と同様に、汎用データ及び専用データの各データセットDS0〜DS3を、QRコードの配色パターンに相当するコードA0〜A3に変換して記録する。この時、各データセットDS0〜DS3は、QRコードの生成方法に則って、夫々データコード語Ad0〜Ad3に変換されるとともに、各データコード語から誤り訂正データ語Ac0〜Ac3が生成される。この時、専用データに関しては、生成された誤り訂正コード語Ac1,Ac2,Ac3を記録せず、別途、データ部の2個のモジュール2に記録する8ビットデータを1シンボルとする誤り訂正コード語Ac4を生成する。なお、本実施例では、誤り訂正率を高めるために、データコード語Ad0〜Ad3の2倍量の誤り訂正コード語Ac4を生成する。   More specifically, when the optical code of the present embodiment is generated, the data sets DS0 to DS3 of general-purpose data and dedicated data are converted into codes A0 to A3 corresponding to the color arrangement pattern of the QR code as in the first embodiment. Convert and record. At this time, each of the data sets DS0 to DS3 is converted into data code words Ad0 to Ad3 according to a QR code generation method, and error correction data words Ac0 to Ac3 are generated from the data code words. At this time, with respect to the dedicated data, the generated error correction code words Ac1, Ac2 and Ac3 are not recorded, but separately, error correction code words having 8-bit data recorded in the two modules 2 of the data portion as one symbol. Ac4 is generated. In the present embodiment, in order to increase the error correction rate, the error correction code word Ac4 that is twice the amount of the data code words Ad0 to Ad3 is generated.

図8(b)は、本実施例の光学コードのデータ配置を示したものである。実施例1のデータ配置(図8(a)参照)と比較するとわかるように、本実施例と実施例1のいずれでも、符号化領域4の誤り訂正部の表層には、データコード語Ad0から生成した誤り訂正コード語Ac0が記録される。一方、実施例1では、誤り訂正部の内層に、誤り訂正コード語Ac1,Ac2,Ac3が記録されるのに対して、本実施例では、誤り訂正部の内層に誤り訂正コード語Ac4が記録される。すなわち、かかる構成にあっては、誤り訂正コード語Ac0が本発明に係る「第一の訂正コード語」に相当し、誤り訂正コード語Ac4が本発明に係る「第二の訂正コード語」に相当する。なお、本実施例では、誤り訂正コード語Ac4が、誤り訂正部の内層の記憶容量を上回っているため、機能パターン3を構成するモジュール2の内層にも誤り訂正コード語Ac4の一部を記録している。機能パターン3を構成するモジュール2は、サンプル領域5aを除けば、内層に記録されるデータが存在しないため、誤り訂正コード語Ac4を記録しても支障はない。   FIG. 8B shows the data arrangement of the optical code of the present embodiment. As can be seen from comparison with the data arrangement of the first embodiment (see FIG. 8A), in both the present embodiment and the first embodiment, the data code word Ad0 is included in the surface layer of the error correction unit in the encoding area 4. The generated error correction code word Ac0 is recorded. On the other hand, in the first embodiment, the error correction codewords Ac1, Ac2, and Ac3 are recorded in the inner layer of the error correction unit, whereas in the present embodiment, the error correction codeword Ac4 is recorded in the inner layer of the error correction unit. Is done. That is, in such a configuration, the error correction code word Ac0 corresponds to the “first correction code word” according to the present invention, and the error correction code word Ac4 corresponds to the “second correction code word” according to the present invention. Equivalent to. In this embodiment, since the error correction code word Ac4 exceeds the storage capacity of the inner layer of the error correction unit, a part of the error correction code word Ac4 is also recorded in the inner layer of the module 2 constituting the function pattern 3. doing. The module 2 constituting the function pattern 3 does not have any problem even if the error correction code word Ac4 is recorded because there is no data recorded in the inner layer except for the sample area 5a.

上述のように、本実施例にあっては、汎用データのデータコード語Ad0から生成される誤り訂正コード語Ac0と、全てのデータコード語Ad0,Ad1,Ad2,Ad3からモジュール2個単位で生成される誤り訂正コード語Ac4の二種類が存在する。このため、本実施例の光学コードの読取処理では、個々の誤り訂正コード語Ac0,Ac4に基づいた二種類の誤り訂正を順番に行う。ここで、本実施例では、一方の誤り訂正コード語Ac0,Ac4による誤り訂正に失敗した場合は、他方の誤り訂正コード語Ac0,Ac4による誤り訂正を試みて、該誤り訂正に成功した場合には、失敗した方の誤り訂正を再度試みるようにする。二種類の誤り訂正コード語Ac0,Ac4は、誤り訂正の対象データが一部重複しているため、一方の誤り訂正に失敗した場合でも、他方の誤り訂正によって重複データの誤り率が低くなることで、失敗した方の誤り訂正も成功する可能性が生じるためである。   As described above, in this embodiment, the error correction code word Ac0 generated from the data code word Ad0 of general-purpose data and all the data code words Ad0, Ad1, Ad2, and Ad3 are generated in units of two modules. There are two types of error correction code word Ac4. For this reason, in the optical code reading process of this embodiment, two types of error correction based on the individual error correction code words Ac0 and Ac4 are performed in order. Here, in this embodiment, when error correction by one error correction code word Ac0, Ac4 fails, error correction by the other error correction code word Ac0, Ac4 is attempted and the error correction is successful. Try again to correct the error that failed. In the two types of error correction code words Ac0 and Ac4, the error correction target data partially overlaps. Therefore, even if one of the error corrections fails, the error correction of the duplicate data is reduced by the other error correction. This is because there is a possibility that the error correction of the failed one will be successful.

本実施例では、2つのモジュールに記録される8ビットデータをリードソロモン符号の1シンボルとして誤り訂正コード語Ac4を生成して記録することにより、実施例1に比べて誤り訂正機能を向上できるという利点がある。すなわち、本実施例の光学コードでは、各モジュール2が16種類の基準色で配色されるため、白黒光学コードに比べて色の識別誤りがモジュール単位で生じやすい。実施例1の誤り訂正方法では、1つのモジュール2に記録される4ビットのデータが、別々の誤り訂正単位(シンボル)に含まれているため、1モジュールの色の識別を誤ると、最大4シンボルで誤りが発生することとなる。これに対して、本実施例では、2つのモジュール2に記録される8ビットのデータが、1つの誤り訂正単位(シンボル)を構成しているため、1モジュールの色の識別を誤った場合でも、最大2シンボルで誤りが発生するだけで済む。一般的に、リードソロモン符号では、誤りの発生したシンボルの割合によって、誤りを訂正できるか否かが決まるため、誤りの発生するシンボル数の少ない本実施例の方が、実施例1に比べて誤りを訂正し易いものとなる。なお、1シンボルでなく、2シンボルで誤りが発生するのは、互換性維持のために表層に誤り訂正コード語Ac0を記録しているためである。   In the present embodiment, the error correction function can be improved as compared with the first embodiment by generating and recording the error correction code word Ac4 using the 8-bit data recorded in the two modules as one symbol of the Reed-Solomon code. There are advantages. That is, in the optical code of the present embodiment, each module 2 is arranged with 16 kinds of reference colors, so that a color identification error is more likely to occur in units of modules than the monochrome optical code. In the error correction method according to the first embodiment, 4-bit data recorded in one module 2 is included in different error correction units (symbols). An error will occur in the symbol. On the other hand, in this embodiment, 8-bit data recorded in two modules 2 constitutes one error correction unit (symbol), so even when the color identification of one module is wrong. It is only necessary to generate an error with a maximum of two symbols. In general, in the Reed-Solomon code, whether or not an error can be corrected is determined depending on the proportion of symbols in which an error has occurred. It becomes easy to correct errors. Note that the error occurs in two symbols instead of one symbol because the error correction code word Ac0 is recorded on the surface layer in order to maintain compatibility.

なお、本実施例では、2つのモジュール2に記録される8ビットのデータが1つの誤り訂正単位を構成しているが、本発明にあっては、1つのモジュール2に記録される複数ビットのデータを1つの誤り訂正単位とすることもできる。また、後述の実施例3のように、1つのモジュール2に多数(16ビット)のデータが記録される場合には、当該多数のデータを、2つ以上の誤り訂正単位(例えば、8ビット×2個)に分割することもできる。   In this embodiment, 8-bit data recorded in two modules 2 constitutes one error correction unit. However, in the present invention, a plurality of bits recorded in one module 2 is used. Data can also be used as one error correction unit. Further, when a large number (16 bits) of data is recorded in one module 2 as in Example 3 described later, the large number of data is stored in two or more error correction units (for example, 8 bits × 2).

本実施例は、上記実施例2の構成を変更し、各モジュールを、微細なサブモジュールに分割することで、各モジュールにより多くのデータを記録可能としたことを特徴とする。なお、以下に説明する本発明の特徴部分以外は、実施例1と同一構成であるため、構成の共通する部分は図中及び文中で符号を共通させて説明を省略する。   The present embodiment is characterized in that the configuration of the second embodiment is changed and each module is divided into fine sub-modules so that more data can be recorded in each module. In addition, since it is the same structure as Example 1 except the characteristic part of this invention demonstrated below, the part which has a common structure makes a code | symbol common in a figure and the text, and abbreviate | omits description.

具体的には、本実施例の光学コード1aは、図9に示すように、符号化領域4を構成するモジュール2が、モジュール2よりも小さいサブモジュール20に細分されており、モジュール2は、サブモジュール20のレベルで16種類の基準色(図2参照)で配色される。具体的には、モジュール2は、縦4列、横4列の計16個のサブモジュール20に、マトリックス状に分割される。サブモジュール20に細分されるモジュール2は、図10(a)に示すように、5つの領域a〜eに区画され、同一領域a〜eのサブモジュール20は、同一基準色で配色されるよう構成される。すなわち、各モジュール2は、最大5種類の基準色で配色される。また、個々のモジュール2を構成する16個のサブモジュール20は、明色基準色又は暗色基準色で統一して配色される。すなわち、図10(b)に示すように、領域aが明色基準色で配色されるモジュール2aでは、残る領域b〜eも全て明色基準色で配色される。かかるモジュール2aは、QRコード用の読取装置で読み取った時に、白色(明色)と識別されるものであり、明色モジュール2aを構成するものである。一方、図10(c)に示すように、領域aが暗色基準色で配色されるモジュール2bでは、残る領域b〜eも全て暗色基準色で配色される。すなわち、かかるモジュール2bは、QRコード用の読取装置で読み取った時に、黒色(暗色)と識別される暗色モジュール2bである。   Specifically, as shown in FIG. 9, in the optical code 1a of the present embodiment, the module 2 constituting the encoding region 4 is subdivided into submodules 20 smaller than the module 2, and the module 2 is At the level of the sub-module 20, colors are arranged with 16 reference colors (see FIG. 2). Specifically, the module 2 is divided into a total of 16 submodules 20 in 4 columns and 4 columns in a matrix. As shown in FIG. 10A, the module 2 subdivided into submodules 20 is divided into five regions ae, and the submodules 20 in the same regions ae are arranged in the same reference color. Composed. That is, each module 2 is arranged with a maximum of five types of reference colors. In addition, the 16 submodules 20 constituting each module 2 are arranged in a uniform color using the light color reference color or the dark color reference color. That is, as shown in FIG. 10B, in the module 2a in which the area a is colored with the light color reference color, all the remaining areas b to e are also colored with the light color reference color. The module 2a is identified as white (light color) when read by a QR code reader, and constitutes the light color module 2a. On the other hand, as shown in FIG. 10C, in the module 2b in which the area a is arranged with the dark reference color, all the remaining areas b to e are also arranged with the dark reference color. That is, the module 2b is a dark color module 2b that is identified as black (dark color) when read by a QR code reader.

このように、本実施例にあっても、符号化領域4の各モジュール2は、QRコード用の読取装置で明色と暗色のいずれかに識別されるものであり、本実施例の光学コード1aでは、各モジュール2が、明色基準色と暗色基準色のいずれであるかの情報によって汎用データを記録する。そして、本実施例では、モジュール2の各領域a〜eが、明色基準色又は暗色基準色のうち、どの種類の基準色であるかの情報によって専用データを記録する。ここで、明色モジュール2aと暗色モジュール2bの夫々は、5つの領域a〜eが個別に8種類の基準色で配色され得るため、8(15ビット)通りの配色パターンを有している。したがって、本実施例の光学コード1cは、1個のモジュール2に、1ビットの汎用データと、15ビットの専用データを記録することができる。 As described above, even in this embodiment, each module 2 in the encoding area 4 is identified as either light or dark color by the QR code reader, and the optical code of this embodiment is used. In 1a, each module 2 records general-purpose data according to information on which of the light color reference color and the dark color reference color. In this embodiment, dedicated data is recorded based on information indicating which type of reference color is selected from the bright reference color or the dark reference color for each of the areas a to e of the module 2. Here, each of the light color module 2a and the dark color module 2b has 8 5 (15 bits) color arrangement patterns because the five areas a to e can be individually arranged with 8 reference colors. . Therefore, the optical code 1c of this embodiment can record 1-bit general-purpose data and 15-bit dedicated data in one module 2.

以上のように、本実施例にあっては、各モジュール2をサブモジュール20に細分し、サブモジュール20のレベルで複数種類の基準色に色分けしているため、実施例1に比べて、1モジュール当たりの記録密度を高めることができる。また、各モジュール2を、明色基準色又は暗色基準色で統一して配色することで、QRコード用の読取装置で個々のモジュール2を明色又は暗色と識別可能としているため、各モジュール2の明暗二値パターンに汎用よってデータを記録することで、QRコードとの互換性を確保することもできる。   As described above, in this embodiment, each module 2 is subdivided into submodules 20 and is divided into a plurality of types of reference colors at the submodule 20 level. The recording density per module can be increased. In addition, each module 2 can be identified as a light color or a dark color by a QR code reader by unifying and arranging the modules 2 in a light color reference color or a dark color reference color. By recording data in the light / dark binary pattern using general-purpose data, compatibility with the QR code can be ensured.

本実施例の光学コード1bは、商品バーコードであるEAN/JANコードと互換性を有するものである。具体的には、図11に示すように、本実施例の光学コード1bは、4種類の幅を有する明色又は暗色の平行バー13を読取方向に一列に配列してなるものである。なお、図11では、EAN/JANコードの下部に記される10進数の数字を省略している。この光学コード1の平行バー13は、白色と黒色以外の色で配色される点においてEAN/JANコードと相違しているが、その基本構造は、EAN/JANコードに準拠している。すなわち、図11(b)に示すように、光学コード1bは、EAN/JANコードと同様に、左右のガードバー14,14と中央のセンターバー15とが制御用に設けられており、センターバー15と左右のガードバー14との間に、夫々6つのキャラクタが記録される。各キャラクタ16は、二本の明色の平行バー13aと二本の暗色の平行バー13bとからなる。各平行バー13は、単位幅の短冊状モジュール2を長手方向に並置してなるものである。全てのキャラクタ16は、7本のモジュール2によって構成され、各平行バー13は、1〜4本のモジュール2によって構成されて、構成するモジュール2の本数に応じて4種類の幅寸法を取り得るよう構成されている。こうした構成は、基本的にJIS規格(JIS X 0501:1985)に準拠しているため詳細な説明は省略する。   The optical code 1b of this embodiment is compatible with an EAN / JAN code that is a product barcode. Specifically, as shown in FIG. 11, the optical code 1b of the present embodiment is formed by arranging light or dark parallel bars 13 having four different widths in a line in the reading direction. In FIG. 11, decimal numbers written at the bottom of the EAN / JAN code are omitted. The parallel bar 13 of the optical code 1 is different from the EAN / JAN code in that it is colored with a color other than white and black, but its basic structure conforms to the EAN / JAN code. That is, as shown in FIG. 11 (b), the optical code 1b is provided with left and right guard bars 14, 14 and a central center bar 15 for control, like the EAN / JAN code. 6 characters are recorded between the left and right guard bars 14. Each character 16 includes two light parallel bars 13a and two dark parallel bars 13b. Each parallel bar 13 is formed by juxtaposing strip-shaped modules 2 having a unit width in the longitudinal direction. All the characters 16 are composed of seven modules 2, and each parallel bar 13 is composed of one to four modules 2, and can take four kinds of width dimensions according to the number of modules 2 to be configured. It is configured as follows. Since such a configuration basically conforms to the JIS standard (JIS X 0501: 1985), detailed description thereof is omitted.

モノクロ画像であるため、図11では十分に表されていないが、本実施例にあっては、実施例1と同様に、光学コード1bを構成する各モジュール2が、明色基準色と暗色基準色とに分類される16種類の基準色(図2参照)のいずれかに配色される。かかる構成にあっては、輝度の高い明色基準色で配色された明色モジュール2aは、EAN/JANコード用の読取装置で白色(明色)と識別され、輝度の低い暗色基準色で配色された暗色モジュール2bは、EAN/JANコード用の読取装置で黒色(暗色)と識別される。そして、本実施例では、明色平行バー13aを明色モジュール2aによって構成し、暗色平行バー13bを暗色モジュール2bによって構成することで、明色と暗色の各平行バー13の幅寸法を、EAN/JANコード用の読取装置で識別し得るよう構成している。そして、本実施例の光学コード1bは、EAN/JANコードの規格にしたがって、明色平行バー13aと暗色平行バー13bの幅寸法によって汎用データを記録している。   Since it is a monochrome image, it is not sufficiently represented in FIG. 11, but in this embodiment, as in the first embodiment, each module 2 that constitutes the optical code 1 b has a light color reference color and a dark color reference. The color is arranged in any of 16 kinds of reference colors (see FIG. 2) classified into colors. In such a configuration, the light color module 2a arranged with a light color reference color having a high luminance is identified as white (light color) by the reading device for the EAN / JAN code, and is arranged with a dark color reference color having a low luminance. The dark module 2b thus identified is identified as black (dark) by the EAN / JAN code reader. In the present embodiment, the light color parallel bar 13a is constituted by the light color module 2a, and the dark color parallel bar 13b is constituted by the dark color module 2b, whereby the width dimension of each light color and dark color parallel bar 13 is set to EAN. It is configured so that it can be identified by a reader for / JAN code. The optical code 1b of the present embodiment records general-purpose data according to the width dimensions of the light color parallel bar 13a and the dark color parallel bar 13b in accordance with the EAN / JAN code standard.

図12(a)は、本実施例の光学コード1bであり、図12(b)は、図12(a)の光学コード1bにあって、明色基準色を全て白塗りとし、暗色基準色を全て黒塗りとして得られたバーコード(EAN/JANコード)12である。このバーコード12は、明色と暗色の平行バーの幅寸法によって光学コード1bと同じ汎用データを記録したものであるから、EAN/JANコード用の読取装置で図12の光学コード1bとバーコード12とを読み取った場合には、いずれも同じ汎用データが読み取られることとなる。すなわち、本実施例の光学コード1bは、EAN/JANコード用の読取装置に対しては、EAN/JANコードの同等品として機能し得るものであり、EAN/JANコードと互換性を有するものとなっている。   FIG. 12A shows the optical code 1b of this embodiment, and FIG. 12B shows the optical code 1b of FIG. 12A, in which all the light color reference colors are white and dark color reference colors. Is a bar code (EAN / JAN code) 12 obtained as a black coating. This bar code 12 records the same general-purpose data as the optical code 1b according to the width dimension of the light and dark parallel bars. Therefore, the bar code 12 is a EAN / JAN code reader and the optical code 1b and bar code of FIG. 12 is read, the same general-purpose data is read in all cases. That is, the optical code 1b according to the present embodiment can function as an EAN / JAN code equivalent to a reader for EAN / JAN code, and is compatible with the EAN / JAN code. It has become.

一方、本実施例の光学コード1bは、各モジュール2が、明色基準色又は暗色基準色のうち、どの種類の基準色であるかによって、専用読取装置でしか読み取ることのできない専用データを記録する。各モジュール2は、平行バー13の明暗二値を表す以外に3ビットの情報を記録可能であるため、7本のモジュール2で構成されるキャラクタ16には、21ビットの専用データを記録可能となっている。   On the other hand, the optical code 1b according to the present embodiment records dedicated data that can be read only by a dedicated reading device depending on which type of reference color the light color reference color or dark color reference color is used by each module 2. To do. Since each module 2 can record 3-bit information in addition to representing the light / dark binary value of the parallel bar 13, it is possible to record 21-bit dedicated data on the character 16 composed of the seven modules 2. It has become.

このように、本実施例の光学コード1bは、1キャラクタ当たり21ビットの専用データを記録できるため、既存のEAN/JANコードに比べて4倍以上の記録密度を実現できる。また、汎用データは、EAN/JANコード用の読取装置で読取可能であるため、本実施例の光学コード1bは、EAN/JANコードとの互換性も有している。   As described above, since the optical code 1b of this embodiment can record dedicated data of 21 bits per character, it can realize a recording density that is four times or more that of the existing EAN / JAN code. Further, since the general-purpose data can be read by the reading device for EAN / JAN code, the optical code 1b of this embodiment is also compatible with the EAN / JAN code.

既存のEAN/JANコードは、誤り検出機能を有しているが、誤り訂正機能は有していない。これに対して、本実施例の光学コード1bでは、各モジュール2が明色基準色又は暗色基準色のうち、どの種類の基準色であるかの情報によって、汎用データの誤り訂正コード語を記録できる。図13は、光学コード1bに汎用データの誤り訂正コード語を記録する場合のデータ配置の一例を示したものである。ここで、「表層」とは、モジュール2の明暗二値パターンによって表される、EAN/JANコード用の読取装置で明暗を識別可能なデータ領域であり、「内層」とは、さらに詳細な基準色の種類によって記録される、EAN/JANコード用の読取装置で読取不能なデータ領域である。かかる例では、各キャラクタ16の表層に7ビット、内層に21ビットの計28ビットのデータを記録し得るところ、表層に記録される汎用データのデータコード語(汎用データコード語)を、リードソロモン符号の1シンボルとする。なお、リードソロモン符号は、7ビットを1シンボルとできないため、便宜上、7ビットの汎用データコード語に固定データを1ビット付加して8ビットにしたものを1シンボルとして取り扱う。そして、かかる例では、汎用データコード語から生成された誤り訂正コード語を内層に記録する。ここでは、1つのキャラクタ16の内層に、誤り訂正コード語を2シンボル(16ビット)ずつ記録し、残りの5ビットに専用データのデータコード語(専用データコード語)を記録し得るよう構成されている。このように、汎用データをコード化したシンボルに対して2倍の数の誤り訂正コード語を記録した場合には、専用読取装置で読み取った時の誤りが33%までであれば、誤りを訂正して汎用データを読み取ることが可能となる。   Existing EAN / JAN codes have an error detection function, but no error correction function. On the other hand, in the optical code 1b of the present embodiment, each module 2 records an error correction code word of general-purpose data according to information on which kind of reference color is a bright color reference color or a dark color reference color. it can. FIG. 13 shows an example of the data arrangement when an error correction code word of general-purpose data is recorded in the optical code 1b. Here, the “surface layer” is a data area that can be identified by a reader for EAN / JAN code, represented by the light / dark binary pattern of module 2, and the “inner layer” is a more detailed standard. This is a data area that is recorded according to the type of color and that cannot be read by a reader for EAN / JAN codes. In this example, a total of 28 bits of data can be recorded, 7 bits on the surface layer of each character 16 and 21 bits on the inner layer. The data code word (general data code word) of the general data recorded on the surface layer is Reed-Solomon. One symbol of the code. Since the Reed-Solomon code cannot have 7 symbols as 1 symbol, for convenience, a 7-bit general-purpose data code word with 1 bit of fixed data added to 8 bits is treated as 1 symbol. In this example, an error correction code word generated from the general-purpose data code word is recorded in the inner layer. Here, the error correction code word is recorded on the inner layer of one character 16 by 2 symbols (16 bits) at a time, and the data code word (dedicated data code word) of the dedicated data can be recorded in the remaining 5 bits. ing. In this way, when twice as many error correction code words are recorded with respect to symbols encoded with general-purpose data, the error is corrected if the error is 33% when read with a dedicated reader. Thus, general-purpose data can be read.

本実施例は、上記実施例4の光学コード1bの構成を変更し、各モジュール2を複数段のサブモジュール20に細分したものである。なお、以下に説明する本発明の特徴部分以外は、実施例4と同一構成であるため、構成の共通する部分は図中及び文中で符号を共通させて説明を省略する。   In the present embodiment, the configuration of the optical cord 1b of the fourth embodiment is changed, and each module 2 is subdivided into a plurality of stages of submodules 20. In addition, since it is the same structure as Example 4 except the characteristic part of this invention demonstrated below, the part which has a common structure makes a code | symbol common in a figure and a text, and abbreviate | omits description.

本実施例の光学コード1cは、図14に示すように、各モジュール2は、読取方向と直交する方向に4段のサブモジュール20に細分されている。各モジュール2は、サブモジュール20ごとに16種類の基準色(図2参照)で配色される。そして、本実施例では、明色モジュール2aを構成する4個のサブモジュール20を全て明色基準色で配色し、暗色モジュール2bを構成する4個のサブモジュールを全て暗色基準色で配色することで、EAN/JANコード用の読取装置が、明色モジュール2aを明色と、暗色モジュール2bを暗色と識別し得るようにしている。そして、本実施例では、実施例4と同様に、EAN/JANコードの規格にしたがって、明色平行バー13aと暗色平行バー13bの幅寸法によって汎用データを記録している。   In the optical code 1c of this embodiment, as shown in FIG. 14, each module 2 is subdivided into four stages of submodules 20 in a direction orthogonal to the reading direction. Each module 2 is arranged with 16 types of reference colors (see FIG. 2) for each submodule 20. In this embodiment, all the four submodules 20 constituting the light color module 2a are arranged with the light reference color, and all the four submodules constituting the dark color module 2b are arranged with the dark color reference color. Thus, the EAN / JAN code reader can identify the light color module 2a as a light color and the dark color module 2b as a dark color. In this embodiment, as in the fourth embodiment, general-purpose data is recorded according to the width dimensions of the light parallel bars 13a and the dark parallel bars 13b in accordance with the EAN / JAN code standard.

一方、本実施例の光学コード1cは、各サブモジュール20が、明色基準色又は暗色基準色のうち、どの種類の基準色であるかによって、専用読取装置でしか読み取ることのできない専用データを記録する。各サブモジュール20は、平行バー13の明暗二値を表す以外に3ビットの情報を記録可能であるため、1モジュール当たり12ビットの情報を記録でき、7本のモジュール2で構成されるキャラクタ16には、84ビットの情報を記録可能となっている。   On the other hand, the optical code 1c according to the present embodiment has dedicated data that can be read only by a dedicated reading device depending on which type of reference color the light color reference color or the dark color reference color is used by each submodule 20. Record. Each sub-module 20 can record 3 bits of information in addition to representing the light / dark binary value of the parallel bar 13, and therefore can record 12 bits of information per module, and the character 16 composed of 7 modules 2. Can record 84-bit information.

以上のように、本実施例にあっては、各モジュール2をサブモジュール20に細分し、サブモジュール20のレベルで複数種類の基準色に色分けしているため、実施例4に比べて、1モジュール当たりの記録密度を高めることができる。また、各モジュール2を、明色基準色又は暗色基準色で統一して配色することで、EAN/JANコード用の読取装置で個々の平行バー13を明色又は暗色と識別可能としているため、EAN/JANコードとの互換性を確保することもできる。   As described above, in this embodiment, each module 2 is subdivided into submodules 20 and is divided into a plurality of types of reference colors at the submodule 20 level. The recording density per module can be increased. In addition, since each module 2 is arranged in a uniform color reference color or dark reference color, each parallel bar 13 can be distinguished from a light color or a dark color by an EAN / JAN code reader. Compatibility with EAN / JAN codes can also be ensured.

以上に、本発明の実施形態を実施例によって説明したが、本発明は、上記実施例の形態に限らず本発明の要旨を逸脱しない範囲内において種々変更を加えることができる。   As mentioned above, although embodiment of this invention was described by the Example, this invention can add a various change in the range which is not restricted to the form of the said Example and does not deviate from the summary of this invention.

例えば、上記実施例は、QRコードやEAN/JANコードと互換性を有する光学コードを例示したが、本発明は、QRコードやEAN/JANコード以外の規格の光学コードと互換性を持たせることも可能である。また、上記実施例では、モジュールを16種類の基準色で配色しているが、本発明にあっては、少なくとも2種類以上の明色基準色と2種類以上の暗色基準色でモジュールが配色されていれば足りる。また、基準色は、色彩を有するものに限らず、複数階調の灰色を採用することできる。また、本発明にあって、基準色の配色は、基準色のインキのベタ塗りによって表されたものに限らず、微細な網点の合成等によって表されたものであっても構わない。また、本発明の光学コードは、印刷物に印刷されたものに限らず、表示画面に表示されたものも含む。   For example, although the above embodiment exemplifies an optical code compatible with a QR code or an EAN / JAN code, the present invention is compatible with an optical code of a standard other than the QR code or the EAN / JAN code. Is also possible. In the above embodiment, the modules are arranged with 16 kinds of reference colors. However, in the present invention, the modules are arranged with at least two kinds of bright color reference colors and two or more kinds of dark color reference colors. If it is, it is enough. In addition, the reference color is not limited to one having a color, and gray of a plurality of gradations can be adopted. In the present invention, the color arrangement of the reference color is not limited to that expressed by solid coating of the ink of the reference color, and may be expressed by synthesis of fine halftone dots. The optical code of the present invention is not limited to the one printed on the printed material, but includes one displayed on the display screen.

1,1a,1b,1c 光学コード
2 モジュール
3 機能パターン
4 符号化領域
5 位置検出パターン
5a サンプル領域
6 分離パターン
7 タイミングパターン
8 データコード領域
9 形式情報コード領域
11 QRコード
12 バーコード
13 平行バー
14 ガードバー
15 センターバー
16 キャラクタ
20 サブモジュール
1, 1a, 1b, 1c Optical code 2 Module 3 Function pattern 4 Coding area 5 Position detection pattern 5a Sample area 6 Separation pattern 7 Timing pattern 8 Data code area 9 Format information code area 11 QR code 12 Bar code 13 Parallel bar 14 Guard bar 15 Center bar 16 Character 20 Sub module

Claims (14)

明色又は暗色と識別されるモジュールによって構成される光学コードであって、
各モジュールは、RGB値の異なる複数種類の基準色のいずれかと識別され得るよう配色されており、
前記複数種類の基準色は、反射率又は輝度が所定の明色閾値以上である複数の明色基準色と、反射率又は輝度が所定の暗色閾値以下である複数の暗色基準色とからなり、
明色と識別されるモジュールは、明色基準色のいずれかと識別可能に配色され、暗色と識別されるモジュールは、暗色基準色のいずれかと識別可能に配色されており、
各モジュールが、明色基準色と暗色基準色のいずれであるかの情報によって記録される汎用データと、各モジュールが、明色基準色又は暗色基準色のうち、どの種類の基準色であるかの情報によって記録される専用データとの少なくとも二種類のデータを含むことを特徴とする光学コード。
An optical code comprising a module identified as light or dark,
Each module is arranged so that it can be distinguished from any of a plurality of types of reference colors having different RGB values.
The plurality of types of reference colors are composed of a plurality of bright color reference colors having a reflectance or luminance equal to or higher than a predetermined light color threshold, and a plurality of dark color reference colors having a reflectance or luminance equal to or lower than a predetermined dark color threshold,
Modules identified as light colors are colorably distinguishable from any of the light reference colors, modules identified as dark colors are colorably distinguishable from any of the dark color reference colors,
General-purpose data recorded based on whether each module is a light reference color or a dark reference color, and what type of reference color is a light reference color or a dark reference color An optical code comprising at least two types of data including dedicated data recorded by the above information.
モジュールをマトリックス状に配置してなる二次元コードであることを特徴とする請求項1に記載の光学コード。   The optical code according to claim 1, wherein the optical code is a two-dimensional code in which modules are arranged in a matrix. 明色基準色と暗色基準色のいずれで配色されるかが予め決定され、光学的読取りを補助するパターンを構成する固定領域を備えるものであり、
該固定領域には、全種類の基準色を所定位置のモジュールに夫々配色してなるサンプル領域を備えることを特徴とする請求項2に記載の光学コード。
It is determined in advance whether the light color reference color or the dark color reference color is used, and includes a fixed region that forms a pattern that assists optical reading.
3. The optical code according to claim 2, wherein the fixed area includes a sample area in which all kinds of reference colors are arranged in modules at predetermined positions.
汎用データ及び専用データのデータコード語を記録するデータ部と、汎用データ及び専用データの誤り訂正コード語を記録する誤り訂正部とを含み、
誤り訂正部の各モジュールは、明色基準色と暗色基準色のいずれであるかの情報によって第一種の誤り訂正コード語を記録するとともに、明色基準色又は暗色基準色のうち、どの種類の基準色であるかの情報によって第二種の誤り訂正コード語を記録しており、
第一種の誤り訂正コード語は、汎用データのみを訂正対象とし、第二種の誤り訂正コード語は、汎用データ及び専用データを訂正対象としており、
第二種の誤り訂正コード語は、データ部のモジュール1つに記録される複数ビットのデータを、1つの誤り訂正単位に含めることを特徴とする請求項2又は請求項3に記載の光学コード。
A data part for recording data code words of general-purpose data and dedicated data; and an error correction part for recording error correction code words of general-purpose data and dedicated data;
Each module of the error correction unit records the first type of error correction code word according to information on whether it is a light color reference color or a dark color reference color, and which type of light color reference color or dark color reference color The second type error correction code word is recorded according to the information of whether it is the standard color of
The first type error correction code word is intended for correction only for general data, and the second type error correction code word is intended for correction for general data and dedicated data.
4. The optical code according to claim 2, wherein the second type of error correction code word includes a plurality of bits of data recorded in one module of the data portion in one error correction unit. .
少なくとも一部のモジュールが、該モジュールよりも微細なサブモジュールにマトリクス状に細分されており、
該サブモジュールに細分されたモジュールでは、各サブモジュールが前記複数種類の基準色のいずれかと識別され得るよう配色され、かつ、明色と識別されるモジュールでは、所定割合以上のサブモジュールが明色基準色で配色され、暗色と識別されるモジュールでは、前記所定割合以上のサブモジュールが暗色基準色で配色されており、
専用データは、モジュールを構成する各サブモジュールが明色基準色又は暗色基準色のうち、どの種類の基準色であるかの情報によって記録されることを特徴とする請求項2乃至請求項4のいずれか1項に記載の光学コード。
At least some of the modules are subdivided into a sub-module smaller than the module in a matrix,
In the module subdivided into the sub-modules, each sub-module is color-coded so that it can be distinguished from any of the plurality of types of reference colors, and in the modules identified as light colors, more than a predetermined proportion of the sub-modules are light-colored. In the module that is colored with the reference color and is identified as the dark color, the sub-modules of the predetermined ratio or more are colored with the dark color reference color,
5. The dedicated data is recorded according to information on which kind of reference color is selected from light color reference color or dark color reference color for each sub-module constituting the module. The optical code according to any one of the above.
サブモジュールに細分されたモジュールにあって、明色と識別されるモジュールは、全てのサブモジュールが明色基準色で配色され、暗色と識別されるモジュールは、全てのサブモジュールが暗色基準色で配色されていることを特徴とする請求項5に記載の光学コード。   Modules that are subdivided into sub-modules that are identified as light colors, all sub-modules are colored with a light reference color, and modules that are identified as dark are all sub-modules with a dark reference color The optical code according to claim 5, wherein the optical code is colored. 明色と識別されるモジュールからなる平行バーと、暗色と識別されるモジュールからなる平行バーとを読取方向に配列してなるバーコードであることを特徴とする請求項1に記載の光学コード。   2. The optical code according to claim 1, wherein the optical code is a bar code formed by arranging parallel bars composed of modules identified as light colors and parallel bars composed of modules identified as dark colors in the reading direction. 各モジュールが、明色基準色又は暗色基準色のうち、どの種類の基準色であるかの情報によって、汎用データの誤り訂正コード語が記録されていることを特徴とする請求項7に記載の光学コード。   8. The error correction code word of general-purpose data is recorded according to information on which type of reference color is selected from light color reference color or dark color reference color for each module. Optical code. 少なくとも一部のモジュールが読取方向と直交する方向に複数段のサブモジュールに多段化されており、各モジュールを構成するサブモジュールは、複数種類の明色基準色又は複数種類の暗色基準色に配色されていることを特徴とする請求項7又は請求項8に記載の光学コード。   At least some of the modules are multi-staged into a plurality of stages of sub-modules in a direction perpendicular to the reading direction, and the sub-modules constituting each module are arranged in a plurality of types of light color reference colors or a plurality of types of dark color reference colors. The optical code according to claim 7, wherein the optical code is provided. 請求項1乃至請求項9のいずれか1項に記載の光学コードの生成方法であって、
汎用データを符号化する第一の符号化ステップと、
専用データを符号化する第二の符号化ステップと、
符号化した汎用データ及び専用データを、モジュールごとに記録する記録単位データに分割し、該記録単位データの内容とモジュールの配色とを対応付けした符号化テーブルに基づいて、各モジュールの配色を決定する第三の符号化ステップと
を実行することを特徴とする光学コードの生成方法。
An optical code generation method according to any one of claims 1 to 9,
A first encoding step for encoding generic data;
A second encoding step for encoding dedicated data;
The encoded general-purpose data and dedicated data are divided into recording unit data to be recorded for each module, and the color scheme of each module is determined based on an encoding table that associates the contents of the recording unit data with the module color scheme. And a third encoding step. An optical code generation method comprising:
符号化テーブルは、前記記録単位データの内容とモジュールの配色とを一対多に対応付けしたものであり、第三の符号化ステップでは、符号化テーブルに基づいて、前記記録単位データの内容に対応する、モジュールの配色候補を複数抽出し、複数の配色候補のいずれかの配色に決定することを特徴とする請求項10に記載の光学コードの生成方法。   The encoding table is a one-to-many correspondence between the contents of the recording unit data and the color scheme of the modules. In the third encoding step, the contents correspond to the contents of the recording unit data based on the encoding table. The method for generating an optical code according to claim 10, wherein a plurality of module color scheme candidates are extracted and determined as any one of the plurality of color scheme candidates. 第一の符号化ステップと第二の符号化ステップでは、汎用データと専用データを同じ方式で符号化することを特徴とする請求項10又は請求項11に記載の光学コードの生成方法。   The optical code generation method according to claim 10 or 11, wherein in the first encoding step and the second encoding step, the general-purpose data and the dedicated data are encoded by the same method. 第三の符号化ステップでは、前記記録単位データの内容とモジュールの配色との対応付けの異なる複数の符号化テーブルから一の符号化テーブルを選択し、選択した符号化テーブルに基づいて各モジュールの配色を決定することを特徴とする請求項10乃至請求項12のいずれか1項に記載の光学コードの生成方法。   In the third encoding step, one encoding table is selected from a plurality of encoding tables having different correspondences between the contents of the recording unit data and the color scheme of the modules, and each module is selected based on the selected encoding table. The optical code generation method according to claim 10, wherein a color arrangement is determined. 第一の符号化ステップでは、汎用データを、該汎用データをコード化したデータコード語に変換するとともに、該データコード語から誤り訂正コード語を生成し、
第二の符号化ステップでは、専用データを、該専用データをコード化するデータコード語に変換するとともに、該データコード語から、第一の符号化ステップに比べて誤り訂正率の低い誤り訂正コード語を生成するか、又は、誤り訂正コード語を生成しないことを特徴とする請求項10乃至請求項13のいずれか1項に記載の光学コードの生成方法。
In the first encoding step, the general-purpose data is converted into a data code word obtained by encoding the general-purpose data, and an error correction code word is generated from the data code word.
In the second encoding step, the dedicated data is converted into a data code word for encoding the dedicated data, and an error correction code having a lower error correction rate than the first encoding step is converted from the data code word. 14. The optical code generation method according to claim 10, wherein a word is generated or no error correction code word is generated.
JP2013026208A 2013-02-14 2013-02-14 Optical code and method for generating the optical code Active JP6099258B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2013026208A JP6099258B2 (en) 2013-02-14 2013-02-14 Optical code and method for generating the optical code

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2013026208A JP6099258B2 (en) 2013-02-14 2013-02-14 Optical code and method for generating the optical code

Publications (2)

Publication Number Publication Date
JP2014154118A true JP2014154118A (en) 2014-08-25
JP6099258B2 JP6099258B2 (en) 2017-03-22

Family

ID=51575890

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2013026208A Active JP6099258B2 (en) 2013-02-14 2013-02-14 Optical code and method for generating the optical code

Country Status (1)

Country Link
JP (1) JP6099258B2 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016201061A (en) * 2015-04-14 2016-12-01 株式会社テララコード研究所 Two-dimensional code, and reading method for two-dimensional code
JP2017016211A (en) * 2015-06-26 2017-01-19 マイクロインテレクス株式会社 One-dimensional or two-dimensional information code
JP2021511610A (en) * 2018-01-26 2021-05-06 ウニベルシタ デ バルセローナ Color correction

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH03118683A (en) * 1989-09-30 1991-05-21 Toyo Ink Mfg Co Ltd Recording method and detecting method
JP2005165565A (en) * 2003-12-01 2005-06-23 Kenpakku:Kk Color code symbol and color code symbol generating method and storage medium for generating color code symbol
WO2009054363A1 (en) * 2007-10-25 2009-04-30 Takahiro Saito Information code
JP2010178214A (en) * 2009-01-30 2010-08-12 Sharp Corp Image generating apparatus, image processing apparatus, image reading apparatus, image forming apparatus, method of generating images, method of processing image, computer program, and recording medium
JP2012068691A (en) * 2010-09-21 2012-04-05 Denso Wave Inc Optical information reading device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH03118683A (en) * 1989-09-30 1991-05-21 Toyo Ink Mfg Co Ltd Recording method and detecting method
JP2005165565A (en) * 2003-12-01 2005-06-23 Kenpakku:Kk Color code symbol and color code symbol generating method and storage medium for generating color code symbol
WO2009054363A1 (en) * 2007-10-25 2009-04-30 Takahiro Saito Information code
JP2010178214A (en) * 2009-01-30 2010-08-12 Sharp Corp Image generating apparatus, image processing apparatus, image reading apparatus, image forming apparatus, method of generating images, method of processing image, computer program, and recording medium
JP2012068691A (en) * 2010-09-21 2012-04-05 Denso Wave Inc Optical information reading device

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016201061A (en) * 2015-04-14 2016-12-01 株式会社テララコード研究所 Two-dimensional code, and reading method for two-dimensional code
JP2017016211A (en) * 2015-06-26 2017-01-19 マイクロインテレクス株式会社 One-dimensional or two-dimensional information code
JP2021511610A (en) * 2018-01-26 2021-05-06 ウニベルシタ デ バルセローナ Color correction
JP7267629B2 (en) 2018-01-26 2023-05-02 ウニベルシタ デ バルセローナ color correction

Also Published As

Publication number Publication date
JP6099258B2 (en) 2017-03-22

Similar Documents

Publication Publication Date Title
TWI693551B (en) Two-dimensional code generation method, decoding method and device
JP5848464B2 (en) Two-dimensional code, two-dimensional code creation system and analysis program
JP6600905B2 (en) Two-dimensional code, multi-valued two-dimensional code, and two-dimensional code generation method
JP5321352B2 (en) Two-dimensional code generation apparatus, image forming system, two-dimensional code reading apparatus, computer program, and medium
US7673807B2 (en) Multiple resolution readable color array
JP6061075B2 (en) Two-dimensional code, two-dimensional code generation method, and two-dimensional code reading method
JP6590335B2 (en) Two-dimensional code and method for reading the two-dimensional code
MX2008015959A (en) Multi-dimensional symbologies and related methods.
US20150324678A1 (en) Modifying Data-Bearing Images
JP2013030184A (en) Two-dimensional code, two-dimensional code generating method, computer readable program for displaying two-dimensional code, authentication method using two-dimensional code, and information providing method using two-dimensional code
JP6099258B2 (en) Optical code and method for generating the optical code
US7770805B2 (en) Method for coding two dimensional optical identification with the same gray level and printing product thereof
US20240086670A1 (en) Methods for constructing, generating, and reading dot-matrix code, dot-matrix code generating and reading terminals, and dot-matrix code system
JP2005208843A (en) Information encoding/decoding method, device and code indicator
JP2011159229A (en) Data reader, data reading method and data recorder
US10853609B2 (en) Hybrid two-dimensional barcode reader
US9202155B2 (en) Bidirectional graphic matrix code
JP2006330930A (en) Method and device for preparing and reading color code
JP6617302B1 (en) Optical code, optical code generation method and program thereof, and optical code reading method and program thereof
JP5359858B2 (en) Information code and information code generation method
WO2021095457A1 (en) Two-dimensional code generation method, two-dimensional code evaluation method, two-dimensional code system, two-dimensional code generation device, two-dimensional code evaluation device, and two-dimensional code
CN114254719B (en) Anti-counterfeiting two-dimensional code generation method and device
US10650208B1 (en) Hybrid two-dimensional barcode and hybrid two-dimensional barcode generator
Sim et al. Development of high data capacity color code
CN108875872B (en) Two-dimensional code and two-dimensional code generation device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20160127

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20161017

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20161101

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20161226

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20170131

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20170220

R150 Certificate of patent or registration of utility model

Ref document number: 6099258

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150