JP2010182057A - Optical information reading device - Google Patents
Optical information reading device Download PDFInfo
- Publication number
- JP2010182057A JP2010182057A JP2009024491A JP2009024491A JP2010182057A JP 2010182057 A JP2010182057 A JP 2010182057A JP 2009024491 A JP2009024491 A JP 2009024491A JP 2009024491 A JP2009024491 A JP 2009024491A JP 2010182057 A JP2010182057 A JP 2010182057A
- Authority
- JP
- Japan
- Prior art keywords
- focal length
- light
- specific pattern
- blur
- optical information
- 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.)
- Pending
Links
Images
Abstract
Description
本発明は、光学的情報読取装置に関するものである。 The present invention relates to an optical information reader.
従来、光学的情報読取装置に関する技術として、下記特許文献1に示す撮像装置が知られている。この撮像装置は、QRコードの読み取り時に特徴点が抽出されると、特徴点マーク部分についてバンドパスフィルタを掛けて高周波成分を抽出し、その積分をとって積分値をピントの合い具合の評価値として求めていく。そして、使用するデジタルフィルタを順次変更しながら連続して求めていく評価値が最大値を検出した場合に、ボケ復元画像を読み出して、この画像の焦点のボケを補正して復元し、復元した画像信号に対して所定の画像処理を行うことで、認識率を向上させている。
2. Description of the Related Art Conventionally, an imaging apparatus shown in
ところで、上述したデジタルフィルタをかける為に必要な周波数成分の抽出は、原理的に画素割り当て(1セルの画素割当量)により大きな影響を受ける。そのため、使用する撮像素子の画素数が例えば、35万、100万、300万と増加していくと、理論上有り得る画素割当量の組み合わせは膨大になり(例えば、あるQRコードを画面一杯に撮像した近点画像〜読み取り可能な最遠点画像との比較した場合の画素割り当て(周波数成分))、結果として周波数成分の抽出後に使用するデジタルフィルタ種が増加し、処理時間が増大するという問題がある。 By the way, the extraction of the frequency components necessary for applying the digital filter described above is greatly influenced by the pixel allocation (pixel allocation amount of one cell) in principle. Therefore, when the number of pixels of the image sensor used increases to 350,000, 1 million, 3 million, for example, the theoretically possible combinations of pixel allocation amounts become enormous (for example, a certain QR code is imaged to the full screen). Pixel allocation (frequency component) when compared with the near-point image to the farthest-point image that can be read), resulting in an increase in processing time due to an increase in the number of digital filter types used after extraction of the frequency component. is there.
本発明は、上述した課題を解決するためになされたものであり、その目的とするところは、読取速度を低下させることなくぼけに起因する認識不良を抑制し得る光学的情報読取装置を提供することにある。 The present invention has been made to solve the above-described problems, and an object of the present invention is to provide an optical information reading apparatus capable of suppressing recognition failure due to blur without reducing the reading speed. There is.
上記目的を達成するため、特許請求の範囲に記載の請求項1の光学的情報読取装置では、複数の明色セルおよび複数の暗色セルから構成される二次元コードであって前記明色セルおよび前記暗色セルが所定の順序で配列される特定パターンを含む二次元コードを読み取り可能な光学的情報読取装置において、前記二次元コードからの反射光を集光しその焦点距離が変更可能な焦点距離変更手段と、前記焦点距離変更手段により集光された前記反射光を受光する受光手段と、前記受光手段による受光結果に基づいてデコード処理を行うデコード手段と、前記受光手段による受光結果に基づいて前記特定パターンを検出する特定パターン検出手段と、前記特定パターン検出手段により検出される前記特定パターンの輝度値からぼけ具合を算出するぼけ具合算出手段と、前記ぼけ具合算出手段により算出される前記ぼけ具合に基づいて目標焦点距離を決定する焦点距離決定手段と、を備え、前記焦点距離変更手段は、前記焦点距離決定手段により決定される前記目標焦点距離に基づいて前記焦点距離を変更することを特徴とする。
In order to achieve the above object, in the optical information reading device according to
請求項2の発明は、請求項1に記載の光学的情報読取装置において、前記特定パターンは、前記二次元コードの位置を検出するための位置検出パターンであることを特徴とする。 According to a second aspect of the present invention, in the optical information reading apparatus according to the first aspect, the specific pattern is a position detection pattern for detecting a position of the two-dimensional code.
請求項3の発明は、請求項1に記載の光学的情報読取装置において、前記特定パターンは、前記明色セルおよび前記暗色セルが交互に配列されるタイミングパターンと、前記二次元コードの外縁部であって前記明色セルのみから構成されるクワイエットゾーンとから構成されることを特徴とする。 According to a third aspect of the present invention, in the optical information reading apparatus according to the first aspect, the specific pattern includes a timing pattern in which the light color cells and the dark color cells are alternately arranged, and an outer edge portion of the two-dimensional code. And a quiet zone composed only of the light-colored cells.
請求項4の発明は、請求項1〜3のいずれか一項に記載の光学的情報読取装置において、前記ぼけ具合算出手段は、前記特定パターンにおける輝度勾配から前記ぼけ具合を算出することを特徴とする。 According to a fourth aspect of the present invention, in the optical information reading device according to any one of the first to third aspects, the blur condition calculating unit calculates the blur condition from a luminance gradient in the specific pattern. And
請求項5の発明は、請求項1〜4のいずれか一項に記載の光学的情報読取装置において、前記焦点距離変更手段は、印加される電圧に応じて前記焦点距離が変更可能な液体レンズであることを特徴とする。 According to a fifth aspect of the present invention, in the optical information reading device according to any one of the first to fourth aspects, the focal length changing means is a liquid lens whose focal length can be changed according to an applied voltage. It is characterized by being.
請求項1の発明では、二次元コードからの反射光が焦点距離変更手段によりその焦点距離を変更させて受光手段に集光される。そして、ぼけ具合算出手段により特定パターンの輝度値からぼけ具合が算出されると、このぼけ具合に基づいて焦点距離決定手段により目標焦点距離が決定される。そして、このように決定される目標焦点距離に基づいて焦点距離変更手段により焦点距離が変更される。 In the first aspect of the invention, the reflected light from the two-dimensional code is condensed on the light receiving means by changing the focal distance by the focal length changing means. When the blur condition is calculated from the brightness value of the specific pattern by the blur condition calculator, the target focal distance is determined by the focal distance determiner based on the blur condition. Then, the focal length is changed by the focal length changing means based on the target focal length thus determined.
このように、ぼけ具合に応じて決定される目標焦点距離に基づいて焦点距離変更手段により焦点距離が変更されるので、ぼけを抑制するように焦点距離を変更することができる。このため、ぼけに起因する認識不良を抑制することができる。特に、特定パターンの輝度値からぼけ具合が算出されるので、全領域の輝度値からぼけ具合を算出する場合と比較して、目標焦点距離を決定する処理の高速化を図ることができる。
したがって、読取速度を低下させることなくぼけに起因する認識不良を抑制することができる。
Thus, since the focal length is changed by the focal length changing means based on the target focal length determined according to the degree of blur, the focal length can be changed so as to suppress blur. For this reason, the recognition failure resulting from blurring can be suppressed. In particular, since the degree of blur is calculated from the luminance value of the specific pattern, it is possible to speed up the process of determining the target focal length as compared to the case where the degree of blur is calculated from the luminance value of the entire region.
Accordingly, it is possible to suppress recognition failure due to blur without reducing the reading speed.
請求項2の発明では、特定パターンは、二次元コードの位置を検出するための位置検出パターンであるため、特定パターンの認識が容易になるので、ぼけ具合を確実に算出することができる。 According to the second aspect of the present invention, since the specific pattern is a position detection pattern for detecting the position of the two-dimensional code, it is easy to recognize the specific pattern, so that the degree of blur can be reliably calculated.
請求項3の発明では、特定パターンは、明色セルおよび暗色セルが交互に配列されるタイミングパターンと、二次元コードの外縁部であって明色セルのみから構成されるクワイエットゾーンとから構成されるため、上記請求項2の発明と同様に特定パターンの認識が容易になるので、ぼけ具合を確実に算出することができる。
In the invention of
請求項4の発明のように、ぼけ具合算出手段は、特定パターンにおける輝度勾配からぼけ具合を算出してもよい。
As in the invention of
請求項5の発明では、焦点距離変更手段は、印加される電圧に応じて焦点距離が変更可能な液体レンズであるため、印加する電圧を変更するだけで焦点距離が変更されるので、焦点距離の調整を容易にすることができる。また、モータ等の駆動部分が少ないため、耐久性を向上させることができる。 In the invention of claim 5, since the focal length changing means is a liquid lens whose focal length can be changed according to the applied voltage, the focal length is changed only by changing the applied voltage. Can be easily adjusted. Moreover, since there are few drive parts, such as a motor, durability can be improved.
以下、本発明の光学的情報読取装置を情報コードリーダに適用した一実施形態について図を参照して説明する。図1は、本実施形態に係る情報コードリーダ20の電気的構成を示すブロック図である。図2は、液体レンズ27に印加される印加電圧値と焦点距離との関係を示す図表である。
Hereinafter, an embodiment in which an optical information reader of the present invention is applied to an information code reader will be described with reference to the drawings. FIG. 1 is a block diagram showing an electrical configuration of the
図1に示すように、情報コードリーダ20は、主に、照明光源21、受光センサ23、液体レンズ27等の光学系と、メモリ35、制御回路40、操作スイッチ42、液晶表示器46等のマイクロコンピュータ(以下「マイコン」という)系と、電源スイッチ41、電池49等の電源系と、から構成されている。なお、これらは、図略のプリント配線板に実装あるいは図略のハウジング内に内装されている。
As shown in FIG. 1, the
光学系の照明光源21は、照明光Lfを発光可能な照明光源として機能するもので、例えば、赤色のLEDとこのLEDの出射側に設けられる拡散レンズ、集光レンズ等とから構成されている。本実施形態では、受光センサ23を挟んだ両側に照明光源21が設けられており、図略のハウジングの読取口を介して読取対象物Rに向けて照明光Lfを照射可能に構成されている。この読取対象物Rは、例えば、包装容器や包装用紙あるいはラベルといった表示媒体に相当するもので、その表面には二次元コードとして例えばQRコードQが印刷されている。
The optical
受光センサ23は、読取対象物RやQRコードQに照射されて反射した反射光Lrを受光可能に構成されるもので、例えば、C−MOSやCCD等の固体撮像素子である受光素子を二次元に配列したエリアセンサが、これに相当する。この受光センサ23は、液体レンズ27を介して入射する入射光をこの受光面23aで受光可能に図略のプリント配線板に実装されている。なお、受光センサ23は、特許請求の範囲に記載の「受光手段」の一例に相当する。
The
液体レンズ27は、外部から読取口を介して入射する入射光を集光して受光センサ23の受光面23aに像を結像可能な結像光学系として機能する。本実施形態では、照明光源21から照射された照明光LfがQRコードQに反射して読取口に入射する反射光Lrを集光することにより、受光センサ23の受光面23aにQRコードQのコード画像を結像可能にしている。特に、液体レンズ27は、図2に示すように、制御回路40の駆動回路(図略)から印加される印加電圧に応じてその焦点距離が変更可能に構成されている。なお、液体レンズ27は、特許請求の範囲に記載の「焦点距離変更手段」の一例に相当する。
The
次に、マイコン系の構成概要を説明する。マイコン系は、増幅回路31、A/D変換回路33、メモリ35、アドレス発生回路36、同期信号発生回路38、制御回路40、操作スイッチ42、LED43、ブザー44、液晶表示器46、通信インタフェース48等から構成されている。このマイコン系は、その名の通り、マイコン(情報処理装置)として機能し得る制御回路40およびメモリ35と中心に構成されるもので、上述した光学系によって撮像されたQRコードQの画像信号をハードウェア的およびソフトウェア的に信号処理し得るものである。また制御回路40は、当該情報コードリーダ20の全体システムに関する制御も行っている。
Next, a configuration outline of the microcomputer system will be described. The microcomputer system includes an
光学系の受光センサ23から出力される画像信号(アナログ信号)は、増幅回路31に入力されることで所定ゲインで増幅された後、A/D変換回路33に入力されると、アナログ信号からディジタル信号に変換される。そして、ディジタル化された画像信号、つまり画像データ(画像情報)は、メモリ35に入力されると、画像データ蓄積領域に蓄積される。なお、同期信号発生回路38は、受光センサ23およびアドレス発生回路36に対する同期信号を発生可能に構成されており、またアドレス発生回路36は、この同期信号発生回路38から供給される同期信号に基づいて、メモリ35に格納される画像データの格納アドレスを発生可能に構成されている。
An image signal (analog signal) output from the
メモリ35は、半導体メモリ装置で、例えばRAM(DRAM、SRAM等)やROM(EPROM、EEPROM等)がこれに相当する。このメモリ35のうちのRAMには、上述した画像データ蓄積領域のほかに、制御回路40が算術演算や論理演算等の各処理時に利用する作業領域や読取条件テーブルも確保可能に構成されている。またROMには、後述する読取処理、評価処理等を実行可能な所定プログラムやその他、照明光源21、受光センサ23等の各ハードウェアを制御可能なシステムプログラム等が予め格納されている。
The
制御回路40は、情報コードリーダ20全体を制御可能なマイコンで、CPU、システムバス、入出力インタフェース等からなるもので、メモリ35とともに情報処理装置を構成し得るもので情報処理機能を有する。この制御回路40には、内蔵された入出力インタフェースを介して種々の入出力装置(周辺装置)と接続可能に構成されており、本実施形態の場合、電源スイッチ41、操作スイッチ42、LED43、ブザー44、液晶表示器46、通信インタフェース48等が接続されている。また、制御回路40は、上述した駆動回路を介して液体レンズ27に接続されている。
The
これにより、例えば、電源スイッチ41や操作スイッチ42の監視や管理、またインジケータとして機能するLED43の点灯・消灯、ビープ音やアラーム音を発生可能なブザー44の鳴動のオンオフ、さらには読み取ったQRコードQによるコード内容を画面表示可能な液晶表示器46の画面制御や外部装置とのシリアル通信を可能にする通信インタフェース48の通信制御等を可能にしている。また、上記駆動回路を駆動することで液体レンズ27の焦点距離を調整可能にしている。なお、通信インタフェース48に接続される外部装置には、当該情報コードリーダ20の上位システムに相当するホストコンピュータHST等が含まれる。
Thereby, for example, monitoring and management of the
電源系は、電源スイッチ41、電池49等により構成されており、制御回路40により管理される電源スイッチ41のオンオフによって、上述した各装置や各回路に、電池49から供給される駆動電圧の導通や遮断が制御されている。なお、電池49は、所定の直流電圧を発生可能な2次電池で、例えば、リチウムイオン電池等がこれに相当する。また、電池49によることなく、例えば、通信インタフェース48を介して接続されるホストコンピュータHST等の外部装置から電力供給を受ける構成を採る場合もあり、この場合には当該電池49は不要となる。
The power supply system includes a
このように情報コードリーダ20を構成することによって、例えば、電源スイッチ41がオンされて所定の自己診断処理等が正常終了し、QRコードQの読み取りが可能な状態になると、照明光Lfの発光を指示する操作スイッチ42(例えばトリガースイッチ)の入力を受け付ける。これにより、作業者がトリガースイッチを押圧しオンにすることで、制御回路40が同期信号を基準に照明光源21に発光信号を出力するので、当該発光信号を受けた照明光源21は、LEDを発光させて照明光Lfを照射する。
By configuring the
すると、QRコードQに照射された照明光Lfが反射しその反射光Lrが読取口を介して液体レンズ27に入射するため、受光センサ23の受光面23aには、後述するように焦点距離が調整された液体レンズ27によりQRコードQの像、つまりコード画像が結像される。これにより、受光面23aを構成する各受光素子が露光され、各受光素子から受光量に応じた信号がそれぞれ出力される。各受光素子から出力される信号は、QRコードQの画像データを構成するものであり、この画像データを2値化した後、所定のデコード処理を施すことによって、QRコードQとして符号化された文字データ等が解読されることとなる。解読された内容は液晶表示器46に表示したり、通信インタフェース48を介してホストコンピュータHSTに出力したりすることができる。なお、制御回路40は、特許請求の範囲に記載の「デコード手段」の一例に相当する。
Then, the illumination light Lf irradiated to the QR code Q is reflected, and the reflected light Lr enters the
次に、情報コードリーダ20を用いた焦点距離調整処理について図3〜図5を用いて説明する。図3は、焦点距離調整処理の流れを例示するフローチャートである。なお、この焦点距離調整処理はメモリ35に記憶されるプログラムに従って制御回路40によって実行されるものである。
Next, focal length adjustment processing using the
また、図4(A)は、ぼけていない状態のQRコードQを示す図であり、図4(B)は、図4(A)の測定線L1上におけるファインダパターンFPの各輝度値を示すグラフである。図5(A)は、ぼけている状態のQRコードQを示す図であり、図5(B)は、図5(A)の測定線L1上におけるファインダパターンFPの各輝度値を示すグラフである。なお、図4(B)および図5(B)において、縦軸は輝度値を示し、明色では数値が高くなり暗色では数値が低くなる。 Further, FIG. 4 (A) is a diagram showing a QR code Q in the state not blurred, FIG. 4 (B), each luminance value of the finder pattern FP on the measurement line L 1 shown in FIG. 4 (A) It is a graph to show. 5 (A) is a diagram showing the QR code Q of blurred and state, and FIG. 5 (B) is a graph showing the respective luminance values of the finder pattern FP on the measurement line L 1 shown in FIG. 5 (A) It is. In FIGS. 4B and 5B, the vertical axis indicates the luminance value, and the numerical value is high for light colors and low for dark colors.
当該焦点距離調整処理が開始されると、まず、図3のステップS101において、画像取得処理が行われる。この画像取得処理は、当該処理実施時において受光センサ23による受光結果に基づいてQRコードQの画像データを生成し、メモリ35に記憶する処理である。なお、QRコードQの画像データを生成し、メモリ35に記憶する流れは上述した通りである。
When the focal length adjustment process is started, first, an image acquisition process is performed in step S101 of FIG. This image acquisition process is a process of generating image data of QR code Q based on the light reception result by the
次に、ステップS103において、デコード処理がなされる。この処理では、ステップS101にて取得された画像データに対して上述したデコード処理が実施される。そして、上記デコード処理が正常になされQRコードQのデコードが成功していると判定されると(S105でYes)、液体レンズ27の焦点距離を調整することなく当該焦点距離調整処理を終了する。
Next, decoding processing is performed in step S103. In this process, the decoding process described above is performed on the image data acquired in step S101. When it is determined that the decoding process has been performed normally and the QR code Q has been successfully decoded (Yes in S105), the focal length adjustment process is terminated without adjusting the focal length of the
一方、S101にて取得した画像データにぼけ等が生じており、ステップS105にて上記デコード処理が失敗したと判定されると、ステップS107において、計時処理がなされる。この処理では、制御回路40が有するクロック装置等の計時装置(図略)によりデコード処理が失敗したと判定されてからの経過時間tが計時される。
On the other hand, if the image data acquired in S101 is blurred or the like, and it is determined in step S105 that the decoding process has failed, a timing process is performed in step S107. In this process, an elapsed time t from when it is determined that the decoding process has failed by a timing device (not shown) such as a clock device included in the
次に、ステップS109において、特定パターン検出処理がなされる。この処理では、ステップS101にて取得した画像データから、特定パターンとしてQRコードの位置を検出するためのパターンであるファインダパターンFPを検出する処理がなされる。QRコードの位置検出パターンの検出処理は公知であるので詳細は省略するが、概要としては明色セル、暗色セルの並びが特定の比率(1:1:3:1:1)となる部位を検出するように処理が行われる。なお、ファインダパターンFPは、特許請求の範囲に記載の「特定パターン」の一例に相当し、制御回路40は、特許請求の範囲に記載の「特定パターン検出手段」の一例に相当する。
Next, in step S109, a specific pattern detection process is performed. In this process, a process for detecting a finder pattern FP, which is a pattern for detecting the position of the QR code as the specific pattern, is performed from the image data acquired in step S101. The detection process of the QR code position detection pattern is well known and will not be described in detail. However, as a summary, a part where the arrangement of light cells and dark cells is a specific ratio (1: 1: 3: 1: 1) is used. Processing is performed to detect. The finder pattern FP corresponds to an example of “specific pattern” recited in the claims, and the
そして、ステップS111において、ファインダパターンFPが検出されたか否かが判定され、S101にて取得した画像データにぼけ等が生じており、ファインダパターンFPが正常に検出されない場合(S111でNo)、ステップS113において、経過時間tが許容最大処理時間ta以上であるか否かが判定される。 In step S111, it is determined whether or not the finder pattern FP is detected. If the image data acquired in S101 is blurred and the finder pattern FP is not normally detected (No in S111), step S111 is performed. In S113, it is determined whether or not the elapsed time t is greater than or equal to the allowable maximum processing time ta.
ステップS113にて経過時間tが許容最大処理時間ta未満であると判定されると(S113でNo)、ステップS115において、焦点距離変更処理がなされる。この処理では、制御回路40の駆動回路により印加される電圧に応じて、液体レンズ27がその焦点距離を変更するように調整される。具体的には、液体レンズ27には初期電圧として例えば1Vが印加されており、この焦点距離変更処理により、例えば2Vに変更した電圧が液体レンズ27に印加される。すなわち、電圧を2Vに決定することにより、この印加電圧に応じた焦点距離が決定されることとなる。
If it is determined in step S113 that the elapsed time t is less than the allowable maximum processing time ta (No in S113), a focal length changing process is performed in step S115. In this process, the
そして、ステップS101にて、S115にて変更された焦点距離の液体レンズ27を介した反射光Lrが受光センサ23に受光されることにより、この受光結果に基づく画像データが取得され、この画像データに対して上述したステップS103以降の処理がなされる。なお、ステップS115における焦点距離変更処理では、S105、S111、S113のいずれかのステップにてYesと判定されるまで、液体レンズ27に対して、変更した電圧が印加されることとなる。このように変更した印加電圧は、ステップS117における印加電圧記憶処理によりメモリ35に記憶される。
In step S101, the reflected light Lr through the
そして、上述したステップS111にてファインダパターンFPが正常に検出されると(S111でYes)、ステップS119において、ぼけ量算出処理がなされる。この処理では、測定線L1上にてファインダパターンFPを構成する各輝度値において所定の位置の振幅Xと振幅Yとの差からぼけ量F=Y−Xとして算出する。なお、ファインダパターンFPを構成する一の明色セルの輝度値とこの一の明色セルと異なる他の明色セルの輝度値との差からぼけ量を算出してもよいし、ファインダパターンFPを構成する一の暗色セルの輝度値とこの一の暗色セルと異なる他の暗色セルの輝度値との差からぼけ量を算出してもよい。 When the finder pattern FP is normally detected in step S111 described above (Yes in S111), blur amount calculation processing is performed in step S119. In this process, calculated as the blur amount F = Y-X from the difference between the amplitudes X and amplitude Y of the predetermined position in each of luminance values constituting a finder pattern FP at the upper measuring line L 1. The blur amount may be calculated from the difference between the luminance value of one light cell constituting the finder pattern FP and the luminance value of another light cell different from the one light cell, or the finder pattern FP. The amount of blur may be calculated from the difference between the luminance value of one dark cell constituting the dark cell and the luminance value of another dark cell different from this one dark cell.
具体的には、図4(A)に示すように、ファインダパターンFPがぼけていない場合には、図4(B)に示すように、振幅Xと振幅Yとの差が小さくなることからぼけ量Fが小さくなる。一方、図5(A)に示すように、ファインダパターンFPがぼけている場合には、図5(B)に示すように、振幅Xと振幅Yとの差が大きくなることからぼけ量Fが大きくなる。なお、現段階では、ステップS105にてNoと判定された後、ステップS111にてYesと判定されているので、図5(A)に示すように、ファインダパターンFPがぼけており、ぼけ量Fは大きくなっている。現段階では、液体レンズ27には2Vの電圧が印加されており、ステップS119によりぼけ量Fが、例えば、10として算出される。なお、制御回路40は、特許請求の範囲に記載の「ぼけ具合算出手段」の一例に相当する。
Specifically, as shown in FIG. 4A, when the finder pattern FP is not blurred, the difference between the amplitude X and the amplitude Y becomes small as shown in FIG. The amount F becomes smaller. On the other hand, as shown in FIG. 5A, when the finder pattern FP is blurred, the difference between the amplitude X and the amplitude Y becomes large as shown in FIG. growing. At this stage, since it is determined No in Step S105 and then Yes in Step S111, the finder pattern FP is blurred as shown in FIG. Is getting bigger. At this stage, a voltage of 2 V is applied to the
次に、ステップS121において、印加電圧およびぼけ量記憶処理がなされ、印加電圧とこの印加電圧に応じたぼけ量Fがメモリ35に記憶される。そして、ステップS123にて経過時間tが許容最大処理時間ta未満であると判定されると(S123でNo)、ステップS125において、焦点距離変更処理がなされる。この処理では、ぼけ量Fが増加するまで液体レンズ27に対して1V刻みで変更した電圧が印加される。そして、ぼけ量Fが増加すると、0.1V刻みで変更した電圧が印加される。すなわち、電圧を所定値に決定することにより、この印加電圧に応じた焦点距離が決定されることとなる。なお、制御回路40は、特許請求の範囲に記載の「焦点距離決定手段」の一例に相当する。
Next, in step S <b> 121, an applied voltage and blur amount storing process is performed, and the applied voltage and the blur amount F corresponding to the applied voltage are stored in the
図6(A)は、液体レンズに1V刻みで印加される印加電圧値と焦点距離との関係を示す図表であり、図6(B)は、液体レンズに0.1V刻みで印加される印加電圧値と焦点距離との関係を示す図表である。
具体的には、ステップS125にて2Vから3Vに変更された電圧が液体レンズ27に印加される。これにより焦点距離が変更された液体レンズ27により、ステップS101にて画像データが取得され、再び、ステップS119にてぼけ量Fが例えば6として算出される(図6(A)参照)。
FIG. 6A is a chart showing the relationship between the applied voltage value applied to the liquid lens in increments of 1V and the focal length, and FIG. 6B is an application applied to the liquid lens in increments of 0.1V. It is a graph which shows the relationship between a voltage value and a focal distance.
Specifically, the voltage changed from 2V to 3V in step S125 is applied to the
そして、ぼけ量Fが減少していることから、ステップS125にて3Vから4Vに変更された電圧が液体レンズ27に印加される。これにより焦点距離が変更された液体レンズ27により、ステップS101にて画像データが取得され、再び、ステップS119にてぼけ量Fが例えば10として算出される。
Since the blur amount F is reduced, the voltage changed from 3 V to 4 V in step S125 is applied to the
そして、ぼけ量Fが増加していることから、ステップS125にて2Vと3Vとの間にて0.1V刻みで変更された電圧が液体レンズ27に印加される。このように0.1V刻みで電圧が液体レンズ27に印加される場合、図6(B)からわかるように、液体レンズ27に2.7Vの電圧を印加する場合が0.1V刻みでは最もぼけ量Fが小さくなることがわかる。
Since the blur amount F is increased, a voltage changed in steps of 0.1V between 2V and 3V is applied to the
このように、ぼけ量Fを小さくするように液体レンズ27に印加される印加電圧を変更することで、画像データが鮮明になることからステップS105によりQRコードQのデコードが成功していると判定されると、当該焦点距離調整処理を終了する。一方、経過時間tが許容最大処理時間ta以上になると、ステップS113またはS123にてYesと判定されて、焦点距離調整処理を終了する。
In this way, since the image data becomes clear by changing the applied voltage applied to the
以上説明したように、本実施形態に係る情報コードリーダ20では、QRコードQからの反射光Lrが焦点距離変更手段として機能する液体レンズ27によりその焦点距離を変更させて受光センサ23の受光面23aに集光される。そして、QRコードQのファインダパターンFPの輝度値からぼけ量F(ぼけ具合)が算出されると、このぼけ量Fを減少させるように液体レンズ27に印加される電圧が決定される。そして、このように決定される印加電圧に応じて液体レンズ27により焦点距離が変更される。
As described above, in the
このように、ぼけ量Fに応じて決定される印加電圧に応じて液体レンズ27により焦点距離が変更されるので、ぼけを抑制するように焦点距離を変更することができる。このため、ぼけに起因する認識不良を抑制することができる。特に、特定パターンであるファインダパターンFPの輝度値からぼけ量Fが算出されるので、全領域の輝度値からぼけ量Fを算出する場合と比較して、印加電圧を決定する処理の高速化を図ることができる。
したがって、読取速度を低下させることなくぼけに起因する認識不良を抑制することができる。
Thus, since the focal length is changed by the
Accordingly, it is possible to suppress recognition failure due to blur without reducing the reading speed.
また、本実施形態に係る情報コードリーダ20では、特定パターンであるファインダパターンFPは、二次元コードの位置を検出するための位置検出パターンであるため、特定パターンの認識が容易になるので、ぼけ量F(ぼけ具合)を確実に算出することができる。
In the
さらに、本実施形態に係る情報コードリーダ20では、焦点距離変更手段として液体レンズ27が採用されており、当該液体レンズ27に印加する電圧を変更するだけで焦点距離が変更されるので、焦点距離の調整を容易にすることができる。また、モータ等の駆動部分が少ないため、耐久性を向上させることができる。
Furthermore, in the
なお、本発明は上記実施形態に限定されるものではなく、以下のように具体化してもよく、その場合でも、上記実施形態と同等の作用・効果が得られる。
(1)図7(A)は、ぼけている状態のQRコードQを示す図であり、図7(B)は、図7(A)の測定線L2上におけるタイミングパターンTPおよびクワイエットゾーンQZの各輝度値を示すグラフである。
上述したステップS119におけるぼけ量算出処理では、測定線L1上でのファインダパターンFPの各輝度値からぼけ量Fを算出することに限らず、測定線L2上での明色セルおよび暗色セルが交互に配列されるタイミングパターンTPにおける明色セルの輝度値と、QRコードQの外縁部であって明色セルのみから構成されるクワイエットゾーンQZの輝度値との差からぼけ量Fを算出してもよい。
In addition, this invention is not limited to the said embodiment, You may actualize as follows, and even in that case, an effect | action and effect equivalent to the said embodiment are acquired.
(1) FIG. 7 (A) is a diagram showing the QR code Q of blurred and state, FIG. 7 (B), the timing pattern TP and quiet zone QZ on the measurement line L 2 shown in FIG. 7 (A) It is a graph which shows each luminance value.
In out-of-focus-amount calculating process in step S119 described above is not limited to calculating blur amount F from the luminance values of the finder pattern FP of on measurement line L 1, bright cells and dark cells in the above measurement line L 2 The blur amount F is calculated from the difference between the brightness value of the light cell in the timing pattern TP in which are alternately arranged and the brightness value of the quiet zone QZ that is the outer edge of the QR code Q and is composed only of the light cell. May be.
具体的には、図7(A)に示すように、QRコードQがぼけている場合には、図7(B)に示すように、タイミングパターンTPにおける明色セルの輝度値と、クワイエットゾーンQZの輝度値との差が大きくなることからぼけ量Fが大きくなる。このようにしても、ぼけ量Fを確実に算出することができる。 Specifically, as shown in FIG. 7A, when the QR code Q is blurred, as shown in FIG. 7B, the brightness value of the light cell in the timing pattern TP and the quiet zone Since the difference from the luminance value of QZ is increased, the blur amount F is increased. Even in this way, the blur amount F can be reliably calculated.
(2)本実施形態に係る情報コードリーダ20は、QRコードQに対して焦点距離調整処理を実施することによりぼけに起因する認識不良を抑制することに限らず、タイミングパターンTPおよびクワイエットゾーンQZ等が既定される二次元コード、例えば、Data Matrixコードに対して焦点距離調整処理を実施することによりぼけに起因する認識不良を抑制してもよい。
(2) The
(3)ぼけ量Fは、ファインダパターンFPを構成する各輝度値において所定の位置の振幅Xと振幅Yとの差からぼけ量F=Y−Xとして算出することに限らず、所定の位置の輝度勾配から算出してもよい。 (3) The blur amount F is not limited to being calculated as the blur amount F = Y−X from the difference between the amplitude X and the amplitude Y at a predetermined position in each luminance value constituting the finder pattern FP. You may calculate from a brightness | luminance gradient.
(4)ステップS115,S125では、1V刻みで印加電圧を変更することに限らず、0.1V刻みで印加電圧を変更してもよいし、ぼけ量F等に応じて刻み幅を調整してもよい。 (4) In steps S115 and S125, the applied voltage is not limited to changing in increments of 1V, the applied voltage may be changed in increments of 0.1V, and the increment width is adjusted according to the blur amount F or the like. Also good.
(5)液体レンズ27により、QRコードQからの反射光Lrをその焦点距離を変更させて受光センサ23の受光面23aに対して集光させることに限らず、この液体レンズ27に代えて、例えば、モータ等で焦点距離を変更可能な焦点距離変更手段を採用してもよい。
(5) The
(6)ステップS113,123では、経過時間tが許容最大処理時間ta以上であると判定される場合にYesと判定されて焦点距離調整処理が終了することに限らず、全パターン、例えば、予め設定された刻み幅の全てのパターンの印加電圧を液体レンズ27に印加してもデコード成功と判定されない場合にYesと判定されて焦点距離調整処理が終了してもよい。
(6) In steps S113 and 123, when the elapsed time t is determined to be equal to or greater than the allowable maximum processing time ta, it is determined that the determination is Yes and the focal length adjustment processing is not terminated. If it is not determined that the decoding is successful even if the application voltages of all the patterns having the set step width are applied to the
20…情報コードリーダ(光学的情報読取装置)
23…受光センサ(受光手段)
27…液体レンズ(焦点距離変更手段)
40…制御回路(デコード手段,特定パターン検出手段,ぼけ具合算出手段,焦点距離決定手段)
F…ぼけ量(ぼけ具合)
FP…ファインダパターン(特定パターン)
TP…タイミングパターン(特定パターン)
Q…QRコード(二次元コード)
QZ…クワイエットゾーン(特定パターン)
X,Y…振幅
20. Information code reader (optical information reader)
23. Light receiving sensor (light receiving means)
27 ... Liquid lens (focal length changing means)
40... Control circuit (decoding means, specific pattern detection means, blur condition calculation means, focal length determination means)
F ... Bokeh amount (blur condition)
FP ... Finder pattern (specific pattern)
TP ... Timing pattern (specific pattern)
Q ... QR code (two-dimensional code)
QZ ... Quiet Zone (specific pattern)
X, Y ... amplitude
Claims (5)
前記二次元コードからの反射光を集光しその焦点距離が変更可能な焦点距離変更手段と、
前記焦点距離変更手段により集光された前記反射光を受光する受光手段と、
前記受光手段による受光結果に基づいてデコード処理を行うデコード手段と、
前記受光手段による受光結果に基づいて前記特定パターンを検出する特定パターン検出手段と、
前記特定パターン検出手段により検出される前記特定パターンの輝度値からぼけ具合を算出するぼけ具合算出手段と、
前記ぼけ具合算出手段により算出される前記ぼけ具合に基づいて目標焦点距離を決定する焦点距離決定手段と、
を備え、
前記焦点距離変更手段は、前記焦点距離決定手段により決定される前記目標焦点距離に基づいて前記焦点距離を変更することを特徴とする光学的情報読取装置。 Optical information capable of reading a two-dimensional code composed of a plurality of light-colored cells and a plurality of dark-colored cells and including a specific pattern in which the light-colored cells and the dark-colored cells are arranged in a predetermined order In the reading device,
A focal length changing means capable of collecting the reflected light from the two-dimensional code and changing the focal length;
A light receiving means for receiving the reflected light collected by the focal length changing means;
Decoding means for performing decoding processing based on a light reception result by the light receiving means;
Specific pattern detecting means for detecting the specific pattern based on a light reception result by the light receiving means;
A blur condition calculating means for calculating a blur condition from a luminance value of the specific pattern detected by the specific pattern detecting means;
A focal length determination means for determining a target focal distance based on the blur condition calculated by the blur condition calculation means;
With
The optical distance reading unit changes the focal length based on the target focal length determined by the focal length determination unit.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2009024491A JP2010182057A (en) | 2009-02-05 | 2009-02-05 | Optical information reading device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2009024491A JP2010182057A (en) | 2009-02-05 | 2009-02-05 | Optical information reading device |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2010182057A true JP2010182057A (en) | 2010-08-19 |
Family
ID=42763612
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2009024491A Pending JP2010182057A (en) | 2009-02-05 | 2009-02-05 | Optical information reading device |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2010182057A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2012208797A (en) * | 2011-03-30 | 2012-10-25 | Casio Comput Co Ltd | Code reading device and program |
JP2013118006A (en) * | 2013-03-18 | 2013-06-13 | Casio Comput Co Ltd | Code reading device and program |
JP2013206129A (en) * | 2012-03-28 | 2013-10-07 | Denso Wave Inc | Information code reader |
JP2016089292A (en) * | 2014-10-31 | 2016-05-23 | 株式会社デンソーウェーブ | Information code medium manufacturing method and information code medium |
-
2009
- 2009-02-05 JP JP2009024491A patent/JP2010182057A/en active Pending
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2012208797A (en) * | 2011-03-30 | 2012-10-25 | Casio Comput Co Ltd | Code reading device and program |
US8651384B2 (en) | 2011-03-30 | 2014-02-18 | Casio Computer Co., Ltd. | Code reading apparatus and computer program product |
JP2013206129A (en) * | 2012-03-28 | 2013-10-07 | Denso Wave Inc | Information code reader |
JP2013118006A (en) * | 2013-03-18 | 2013-06-13 | Casio Comput Co Ltd | Code reading device and program |
JP2016089292A (en) * | 2014-10-31 | 2016-05-23 | 株式会社デンソーウェーブ | Information code medium manufacturing method and information code medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4403975B2 (en) | Optical information reader | |
JP2005202930A (en) | Optical information reading device | |
JP2010182057A (en) | Optical information reading device | |
US10325377B2 (en) | Image depth sensing method and image depth sensing apparatus | |
JP4470860B2 (en) | Information code reader | |
JP5786784B2 (en) | Information code reader | |
JP4175358B2 (en) | Optical information reader | |
JP4466522B2 (en) | Optical information reader | |
JP5888199B2 (en) | Bar code reader | |
JP2010134595A (en) | Information code reading device | |
JP2014126943A (en) | Image processing apparatus and method for performing image processing in order to detect object in image | |
JP2012181757A (en) | Optical information reader | |
JP6338836B2 (en) | Information code reader | |
JP5780192B2 (en) | Information code reader | |
JP5381928B2 (en) | Optical information reader | |
JP5282559B2 (en) | Information code reader | |
JP2011008574A (en) | Optical information reader | |
JP2011197856A (en) | Optical information reading device | |
JP2009294769A (en) | Optical information reader | |
US9767560B2 (en) | Work mode control method and optical encoder using the same | |
JP5786783B2 (en) | Information code reader | |
JP2013196470A (en) | Two-dimensional code reader | |
JP2012208824A (en) | Optical information reading apparatus | |
JP5505332B2 (en) | Imaging device | |
JP2007124002A (en) | Camera system |