JP2014228345A - Distance detection device, reading device including distance detection device, distance detection method, and distance detection program - Google Patents

Distance detection device, reading device including distance detection device, distance detection method, and distance detection program Download PDF

Info

Publication number
JP2014228345A
JP2014228345A JP2013107163A JP2013107163A JP2014228345A JP 2014228345 A JP2014228345 A JP 2014228345A JP 2013107163 A JP2013107163 A JP 2013107163A JP 2013107163 A JP2013107163 A JP 2013107163A JP 2014228345 A JP2014228345 A JP 2014228345A
Authority
JP
Japan
Prior art keywords
reading
distance
barcode
result
frequency analysis
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
JP2013107163A
Other languages
Japanese (ja)
Other versions
JP5559393B1 (en
Inventor
芦浦 敦
Atsushi Ashiura
敦 芦浦
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.)
NEC Platforms Ltd
Original Assignee
NEC Platforms Ltd
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 NEC Platforms Ltd filed Critical NEC Platforms Ltd
Priority to JP2013107163A priority Critical patent/JP5559393B1/en
Application granted granted Critical
Publication of JP5559393B1 publication Critical patent/JP5559393B1/en
Publication of JP2014228345A publication Critical patent/JP2014228345A/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Length Measuring Devices By Optical Means (AREA)

Abstract

PROBLEM TO BE SOLVED: To eliminate the need to incorporate a module dedicated to distance measurement and prevent reading of a barcode located at an unexpected distance.SOLUTION: A distance detection device performs predetermined processing on the basis of a result of first frequency analysis to image data obtained by reading a reading object image with a reading device, and a result of second frequency analysis to image data obtained by reading the reading object image with the reading device distant by a predetermined distance, so as to detect the distance between a reading object and the reading device.

Description

本発明は、距離を検出するための、距離検出装置、距離検出装置を備えた読取装置、距離検出方法及び距離検出プログラムに関する。   The present invention relates to a distance detection device, a reading device including a distance detection device, a distance detection method, and a distance detection program for detecting a distance.

物品の管理等の目的でバーコード(barcode)が広く普及している。バーコードの利用方法としては、物品に添付或いは印刷されたバーコードを、ユーザが手に持ったバーコード読取装置(以下適宜「バーコードスキャナ」と呼ぶ。)を利用して読み取るという方法が一般的である。   Barcodes are widely used for the purpose of managing articles. As a method of using a bar code, a method of reading a bar code attached to or printed on an article by using a bar code reader (hereinafter referred to as “bar code scanner” as appropriate) held by a user is generally used. Is.

もっとも、バーコード読取装置を利用するにあたり、手元の読み取りたいバーコードラベルではなく、手元から外れた遠くのラベルを予期せずに読み取ってしまう、という問題が生じることがある。   However, when using the barcode reader, there may be a problem that a label far away from the hand is unexpectedly read instead of the barcode label desired to be read.

この問題について具体的に説明する。「バーコードラベルの読み取りが可能な距離」は、バーコードスキャナの設計仕様として定義される。もっとも、現実的にはバーコードスキャナとバーコードラベルとの間の距離を正確に測定してデコードの可否を判断したうえで定義しているものではない。現実的なバーコードラベルの読み取りが可能な距離は、有効な強度で照明が届く距離、バーコードスキャナのセンサ上で映像を適切に結像するための光学的(焦点距離や絞り、センサの許容錯乱円径)に有効な焦点の幅(被写界深度)等に依存する。また、さらにバーコードラベルの大きさやバーコードを構成する縞模様一つ一つの幅(最小モジュール幅)によっても、大きく左右されてしまう。   This problem will be specifically described. “Distance at which barcode label can be read” is defined as a design specification of the barcode scanner. However, in reality, it is not defined after the distance between the barcode scanner and the barcode label is accurately measured to determine whether decoding is possible. Realistic barcode label reading distance is the distance that the illumination reaches with effective intensity, and the optical to properly image the barcode scanner sensor (focal length, aperture, sensor tolerance) This depends on the effective focal width (depth of field) and the like. Furthermore, the size of the bar code label and the width of each stripe pattern constituting the bar code (minimum module width) are greatly affected.

つまり、バーコードスキャナはバーコードラベルまでの距離に関係なく、センサに映った映像がデコードできるか否かによって、結果的に「読み取り可能な距離」が決まる。そして、読み取り可能となるバーコードスキャナとラベルの距離の範囲外は、いわゆるピンボケ状態となるため、「事実上デコードができない距離」となる。   In other words, regardless of the distance to the barcode label, the barcode scanner determines the “readable distance” as a result depending on whether or not the video imaged on the sensor can be decoded. The area outside the distance between the barcode scanner and the label that can be read is in a so-called out-of-focus state, and thus is a “distance that cannot be practically decoded”.

ところで、バーコードスキャナでバーコードラベルを読み取らせる際に、条件によっては、バーコードスキャナ使用者の手元のラベルではなく、テーブルの上のラベルや足元にあるラベルなど、使用者が予期しない離れたラベルを読み取ってしまう可能性があるという問題があった。例えば、バーコードラベルが予想の範囲を外れるほど大きく印刷されている場合であって、想定される読み取り距離から離れていたような場合においては、想定の範囲を超えて読み取りが可能となってしまうというような問題である。   By the way, when reading a bar code label with a bar code scanner, depending on the conditions, the label may not be at the user's hand, but a label on the table or a label on the foot, etc. There was a problem that the label could be read. For example, if the barcode label is printed so large that it is out of the expected range, and it is far from the expected reading distance, reading beyond the expected range becomes possible. It is such a problem.

この問題を技術的に解決するために、バーコードスキャナに距離測定用のモジュールを組み込むという方法が考えられる。この距離測定用のモジュールとは、例えば、光学式や超音波式のモジュールである。   In order to technically solve this problem, a method of incorporating a distance measurement module into the barcode scanner can be considered. This distance measurement module is, for example, an optical or ultrasonic module.

このような技術の一例が特許文献1の明細書段落[0018]及び明細書段落[0034]等に記載されている。   An example of such a technique is described in the specification paragraph [0018] and the specification paragraph [0034] of Patent Document 1.

具体的には、特許文献1に記載のバーコードリーダは、バーコードラベルに記載されたバーコードデータを光学的に読み取る読み取り部と、読み取り部にて光学的に読み取られたバーコードデータを電気信号へ変換する光電変換部と、光電変換部にて変換された電気信号からデータキャラクタ解読を行うデコード部という一般的なバーコードリーダとしての部分を含んでいる。そして、引用文献1のバーコードリーダは、更にバーコードリーダからバーコードラベルまでの距離を測定する距離測定手段である距離センサを含んでいる。そして、距離センサによって測定された距離と、メモリに格納された測定許容距離範囲とを比較することにより、読み取り部にて現在読み取られたバーコードデータが有効なものかどうかを判断する。なお、特許文献1では、距離センサについて、赤外線LEDとフォトトランジスタとで構成されるものでも良いし、超音波やレーザ光によって測定されるものであっても良い、とも記載されている。   Specifically, the barcode reader described in Patent Document 1 optically reads the barcode data described on the barcode label, and electrically converts the barcode data optically read by the reading unit. It includes a portion as a general bar code reader, which is a photoelectric conversion unit for converting into a signal and a decoding unit for decoding a data character from an electric signal converted by the photoelectric conversion unit. The barcode reader of the cited document 1 further includes a distance sensor that is a distance measuring means for measuring the distance from the barcode reader to the barcode label. Then, by comparing the distance measured by the distance sensor with the measurement allowable distance range stored in the memory, it is determined whether or not the barcode data currently read by the reading unit is valid. Note that Patent Document 1 describes that the distance sensor may be constituted by an infrared LED and a phototransistor, or may be measured by ultrasonic waves or laser light.

特開2006−201921号公報JP 2006-201921 A

上述した特許文献1等に記載されているようにバーコードスキャナに距離測定用のモジュールを組み込むという方法を取ることにより、想定外の距離に存在するバーコードを誤って読み取ってしまうという問題の解決につながる。しかし、特許文献1等に記載されているような距離測定用のモジュールを組み込むという方法では、厳密には実際に測定すべき対象物と若干異なる位置の距離を測定しているという点が課題となっていた。また、更に部品数の増加によってバーコードスキャナが大きくなってしまう点やコストが上昇してしまうという点が課題となっていた。   Solution of the problem of erroneously reading a barcode existing at an unexpected distance by adopting a method of incorporating a distance measurement module into the barcode scanner as described in Patent Document 1 and the like described above Leads to. However, in the method of incorporating a module for distance measurement as described in Patent Document 1 or the like, strictly speaking, a distance at a position slightly different from the object to be actually measured is measured. It was. Further, there are problems that the barcode scanner becomes larger and the cost increases due to the increase in the number of parts.

他方、他の距離の測定方法として、バーコードスキャナの照明用光源に距離測定用パルスを混ぜ、映像取得用センサでそのパルス応答の時間差を測定するという方法も考えられる。もっとも、観測しなくてはならない時間が10−11秒程度と極めて短い一方で、センサからデータを取得できる時間が10−3秒程度であるため、データの取得と距離の測定の双方を確実に実現することが困難であった。 On the other hand, as another distance measurement method, a method of mixing a distance measurement pulse with an illumination light source of a barcode scanner and measuring a time difference of the pulse response with an image acquisition sensor is also conceivable. However, while the time that must be observed is as short as 10 -11 seconds, the time that data can be acquired from the sensor is about 10 -3 seconds, so both data acquisition and distance measurement can be ensured. It was difficult to realize.

このように、バーコードリーダでは、遠くにあるバーコードラベルを誤って読み取ってしまわないようにするために何らかの手段で距離を測定する必要があるにも関わらず、一般的技術ではその合理的解決手段が無かった。   In this way, with bar code readers, it is necessary to measure the distance by some means so as not to misread bar code labels in the distance. There was no means.

そこで、本発明は、距離測定用の専用モジュールを組み込む必要が無く、且つ、想定外の距離にあるバーコードの読み取りを防止することが可能な、距離検出装置、距離検出装置を備えた読取装置、距離検出方法及び距離検出プログラムを提供することを目的とする。   Therefore, the present invention eliminates the need for incorporating a dedicated module for distance measurement, and can prevent reading of a barcode at an unexpected distance, and a distance detection device and a reader equipped with the distance detection device An object of the present invention is to provide a distance detection method and a distance detection program.

本発明の第1の観点によれば、読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出装置が提供される。   According to the first aspect of the present invention, the result of the first frequency analysis on the image data obtained by reading the reading target image with the reading device and the reading target image separated by a predetermined distance by the reading device. The distance between the reading object and the reading device is detected by performing a predetermined process based on the result of the second frequency analysis on the image data obtained by reading. A detection device is provided.

本発明の第2の観点によれば、読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出方法が提供される。   According to the second aspect of the present invention, the result of the first frequency analysis on the image data obtained by reading the reading target image with the reading device and the reading target image separated by a predetermined distance by the reading device. The distance between the reading object and the reading device is detected by performing a predetermined process based on the result of the second frequency analysis on the image data obtained by reading. A detection method is provided.

本発明の第3の観点によれば、読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出装置としてコンピュータを機能させることを特徴とする距離検出プログラムが提供される。   According to the third aspect of the present invention, the result of the first frequency analysis on the image data obtained by reading the reading target image with the reading device and the reading target image separated by a predetermined distance by the reading device. The distance between the reading object and the reading device is detected by performing a predetermined process based on the result of the second frequency analysis on the image data obtained by reading. A distance detection program is provided that causes a computer to function as the detection device.

本発明によれば、距離測定用の専用モジュールを組み込む必要が無く、且つ、想定外の距離にあるバーコードの読み取りを防止することが可能となる。   According to the present invention, it is not necessary to incorporate a dedicated module for distance measurement, and bar code reading at an unexpected distance can be prevented.

本発明の実施形態の基本的構成を表す図である。It is a figure showing the basic composition of the embodiment of the present invention. 本発明の実施形態の読み取り時の光の流れを表す図である。It is a figure showing the flow of the light at the time of reading of embodiment of this invention. 本発明の実施形態におけるプロセッサに含まれる機能ブロックの一例を表す図である。It is a figure showing an example of the functional block contained in the processor in embodiment of this invention. バーコードの読み取りと焦点位置との関係を表す図である。It is a figure showing the relationship between barcode reading and a focus position. 本発明の実施形態における周波数解析について説明する図(1/6)である。It is a figure (1/6) explaining the frequency analysis in embodiment of this invention. 本発明の実施形態における周波数解析について説明する図(2/6)である。It is a figure (2/6) explaining the frequency analysis in embodiment of this invention. 本発明の実施形態における周波数解析について説明する図(3/6)である。It is a figure (3/6) explaining the frequency analysis in embodiment of this invention. 本発明の実施形態における周波数解析について説明する図(4/6)である。It is a figure (4/6) explaining the frequency analysis in embodiment of this invention. 本発明の実施形態における周波数解析について説明する図(5/6)である。It is a figure (5/6) explaining the frequency analysis in embodiment of this invention. 本発明の実施形態における周波数解析について説明する図(6/6)である。It is a figure (6/6) explaining the frequency analysis in embodiment of this invention. 一般的なバーコードラベルの一例を表す図である。It is a figure showing an example of a general barcode label. 説明のためにバーコードラベルを模式化したラベルを表す図である。It is a figure showing the label which modeled the barcode label for explanation. 図6に表されるラベルを適切な距離にて読み取りを行った場合の受光強度について表す図である。It is a figure showing about the received light intensity at the time of reading the label shown in FIG. 6 in appropriate distance. 図6に表されるラベルを適切な距離にて読み取りを行った場合の受光強度と不適切な距離にて読み取りを行った場合の受光強度を重ね合わせた図である。FIG. 7 is a diagram in which the received light intensity when the label shown in FIG. 6 is read at an appropriate distance and the received light intensity when read at an inappropriate distance are superimposed. 図6に表されるラベルを適切な距離にて読み取りを行った場合の受光強度と不適切な距離にて読み取りを行った場合の受光強度の周波数解析結果を重ね合わせた図である。FIG. 7 is a diagram in which the received light intensity when the label shown in FIG. 6 is read at an appropriate distance and the frequency analysis result of the received light intensity when read at an inappropriate distance are superimposed. 図9の一部を拡大した図である。It is the figure which expanded a part of FIG. 説明のためにバーコードラベルを模式化したラベルを表す図である。It is a figure showing the label which modeled the barcode label for explanation. 本発明の実施形態の基本的動作を表すフローチャートである。It is a flowchart showing the basic operation | movement of embodiment of this invention. 図11に表されるラベルを不適切な距離にて読み取りを行った場合の受光強度について表す図である。FIG. 12 is a diagram illustrating received light intensity when the label illustrated in FIG. 11 is read at an inappropriate distance. 図11に表されるラベルを適切な距離にて読み取りを行った場合の受光強度について表す図である。It is a figure showing about the light reception intensity | strength at the time of reading the label shown in FIG. 11 in appropriate distance. 図11に表されるラベルを適切な距離にて読み取りを行った場合の受光強度と不適切な距離にて読み取りを行った場合の受光強度を重ね合わせた図である。FIG. 12 is a diagram in which the received light intensity when the label shown in FIG. 11 is read at an appropriate distance and the received light intensity when read at an inappropriate distance are superimposed. 図11に表されるラベルを適切な距離にて読み取りを行った場合の受光強度と不適切な距離にて読み取りを行った場合の受光強度の周波数解析結果を重ね合わせた図である。FIG. 12 is a diagram in which the received light intensity when the label shown in FIG. 11 is read at an appropriate distance and the frequency analysis result of the received light intensity when read at an inappropriate distance are superimposed.

まず、本発明の実施形態の概略を説明する。本発明の実施形態は、概略、バーコードスキャナ(バーコード読み取り機)とバーコードラベルとの距離を、バーコードスキャナのセンサに映るバーコードの映像解析によって測定することを特徴とするというものである。更に本実施形態は、これを実現するために、バーコードスキャナとして機能するためのセンサ以外の、他の特別なセンサを必要としないことを特徴とするというものである。   First, an outline of an embodiment of the present invention will be described. The embodiment of the present invention is characterized in that the distance between a barcode scanner (barcode reader) and a barcode label is roughly measured by analyzing the image of the barcode reflected on the sensor of the barcode scanner. is there. Furthermore, this embodiment is characterized in that no special sensor other than the sensor for functioning as a barcode scanner is required to realize this.

次に、本発明の実施形態について図面を用いて詳細に説明する。   Next, embodiments of the present invention will be described in detail with reference to the drawings.

図1−1及び図1−2には本実施形態であるバーコードスキャナ100及びバーコードラベル106が表される。ここで、図1−1は、もっぱらバーコードスキャナ100の構成要素の一例を表す図である。図1−2は、更にバーコードスキャナ100が読み取りを行う際の光路を表す図である。   1-1 and FIG. 1-2 show a barcode scanner 100 and a barcode label 106 according to the present embodiment. Here, FIG. 1-1 is a diagram exclusively showing an example of the components of the barcode scanner 100. FIG. 1-2 is a diagram illustrating an optical path when the barcode scanner 100 further performs reading.

図1−1及び図1−2を参照すると、本実施形態のバーコードスキャナ100は、プロセッサ101、イメージセンサ102、集光レンズ/フィルタ103、反射ミラー104及び照明光源105を含む。加えて、図1−1及び図1−2には、バーコードスキャナ100の読み取り対象となるバーコードラベル106が表されている。   Referring to FIGS. 1-1 and 1-2, the barcode scanner 100 of this embodiment includes a processor 101, an image sensor 102, a condenser lens / filter 103, a reflection mirror 104, and an illumination light source 105. In addition, FIGS. 1-1 and 1-2 show a barcode label 106 to be read by the barcode scanner 100. FIG.

バーコードスキャナ100の基本的な構成は、一般的なバーコードスキャナの基本構成と同じであり、バーコードスキャナとしての機能を実現するために、イメージを取得するイメージセンサ102が含まれてはいるがこれ以外の特別なセンサや物理的な機構等は含まれていない。すなわち、バーコードスキャナ100には距離取得のためだけの特別な物理的なモジュールは設けられていない。   The basic configuration of the barcode scanner 100 is the same as the basic configuration of a general barcode scanner, and an image sensor 102 for acquiring an image is included in order to realize a function as a barcode scanner. However, other special sensors and physical mechanisms are not included. In other words, the barcode scanner 100 is not provided with a special physical module only for distance acquisition.

バーコードスキャナ100は、プロセッサ101の制御によりバーコードラベル106を読み取る。具体的には、照明光源105がバーコードラベル106を照射する。そして、照明光源105の照射に基づくバーコードラベル106の反射光を反射ミラー104が反射させる。そして、反射ミラー104による反射光は集光レンズと照射光を適切に通す集光レンズ/フィルタ103を通してイメージセンサ102により取得される。取得された反射光はプロセッサ100によりデコードされ、デコード結果は上位装置と通信をするためのラインを介して上位装置に伝達される。   The barcode scanner 100 reads the barcode label 106 under the control of the processor 101. Specifically, the illumination light source 105 irradiates the barcode label 106. Then, the reflection mirror 104 reflects the reflected light of the barcode label 106 based on the irradiation of the illumination light source 105. Then, the reflected light from the reflecting mirror 104 is acquired by the image sensor 102 through the condenser lens / filter 103 that appropriately passes the condenser lens and the irradiation light. The acquired reflected light is decoded by the processor 100, and the decoding result is transmitted to the host device via a line for communicating with the host device.

なお、バーコードスキャナ100の形状によっては反射ミラー104を省略することが可能である。また、集光レンズ/フィルタ103についても、フィルタが不要であれば、集光レンズだけで実現するようにしても良い。   Note that the reflection mirror 104 can be omitted depending on the shape of the barcode scanner 100. Further, the condensing lens / filter 103 may be realized only by the condensing lens if no filter is required.

なお、プロセッサ101は、本願発明の「距離検出装置」に相当する。また、バーコードスキャナ100は、本願発明の「距離検出装置を備えた読取装置」に相当する。   The processor 101 corresponds to the “distance detection device” of the present invention. The barcode scanner 100 corresponds to the “reading device including the distance detection device” of the present invention.

続いて、図2を参照してプロセッサ101に含まれる機能ブロックについて説明をする。   Next, functional blocks included in the processor 101 will be described with reference to FIG.

図2を参照すると、プロセッサ101は、センサ制御部101−1、処理部101−2、記憶部101−3及びデータ送受信部101−4を含む。   Referring to FIG. 2, the processor 101 includes a sensor control unit 101-1, a processing unit 101-2, a storage unit 101-3, and a data transmission / reception unit 101-4.

センサ制御部101−1は、イメージセンサ102の制御を行う機能と、イメージセンサ102によりデータの取得を行う機能を含む。取得されたデータは記憶部101−3に格納される。なお、今回の説明において、イメージセンサ102は256ドットの幅を持つイメージセンサであることを想定して説明をするが、これは説明のための一例に過ぎず、イメージセンサ102のドット幅に特に制限はない。   The sensor control unit 101-1 includes a function for controlling the image sensor 102 and a function for acquiring data by the image sensor 102. The acquired data is stored in the storage unit 101-3. In this description, it is assumed that the image sensor 102 is an image sensor having a width of 256 dots. However, this is only an example for explanation, and the dot width of the image sensor 102 is particularly limited. There is no limit.

処理部101−2は、バーコードスキャナ100全体を制御する機能を有する。また、処理部101−2は、イメージセンサ102により取得したデータをセンサ制御部101−1から受け取り、記憶部101−3に格納に格納する。そして、処理部101−2は、記憶部101−3に格納したデータと記憶部101−3に格納されている「距離・正規化対応表」とに基づいて画像解析等の処理を行い、バーコードスキャナ100とバーコードラベル106との距離を検出する機能も有する。ここで、距離・正規化対応表が具体的にどのようなデータであるのかについては後述する。   The processing unit 101-2 has a function of controlling the entire barcode scanner 100. The processing unit 101-2 receives the data acquired by the image sensor 102 from the sensor control unit 101-1, and stores the data in the storage unit 101-3. Then, the processing unit 101-2 performs processing such as image analysis based on the data stored in the storage unit 101-3 and the “distance / normalization correspondence table” stored in the storage unit 101-3. It also has a function of detecting the distance between the code scanner 100 and the barcode label 106. Here, the specific data of the distance / normalization correspondence table will be described later.

記憶部101−3は、イメージセンサ102より取得したデータを格納する記憶部である。また、記憶部101−3は、事前に測定されたデータである距離・正規化対応表も格納する。   The storage unit 101-3 is a storage unit that stores data acquired from the image sensor 102. The storage unit 101-3 also stores a distance / normalization correspondence table that is data measured in advance.

そして、バーコードスキャナ100とバーコードラベル106との距離が適切な範囲である場合に、イメージセンサ102により取得した画像データを二値化し、更にこの二値化したデータをバーコードの種別に対応してデコードしたデータをデータ送受信部101−4に出力する。   When the distance between the barcode scanner 100 and the barcode label 106 is within an appropriate range, the image data acquired by the image sensor 102 is binarized, and the binarized data corresponds to the barcode type. The decoded data is output to the data transmitting / receiving unit 101-4.

データ送受信部101−4は、バーコードスキャナ100と上位装置とがデータを送受信するための機能を有する。データ送受信部101−4は、処理部101−2から入力したデータを上位装置に送信する。   The data transmission / reception unit 101-4 has a function for transmitting / receiving data between the barcode scanner 100 and the host device. The data transmitting / receiving unit 101-4 transmits the data input from the processing unit 101-2 to the higher-level device.

なお、プロセッサ101に含まれる各機能ブロックは、プロセッサ101に含まれる図示を省略した演算処理装置が、記憶部101−3又は図示を省略した他の記憶部に格納されている本実施形態特有のプログラムに基づいて演算処理を行い、演算処理の結果に基づいて各種のハードウェアを制御することにより実現される。また、プロセッサ101に含まれる機能の一部を例えば上位装置等の他の装置により実現するようにしても良い。プロセッサ101を用いて構成されている距離検出装置のうちの一部又は全部を、プログラムを用いずに動作するハードウェアによって構成してもよい。   It should be noted that each functional block included in the processor 101 is unique to the present embodiment in which an arithmetic processing device (not shown) included in the processor 101 is stored in the storage unit 101-3 or another storage unit (not shown). This is realized by performing arithmetic processing based on a program and controlling various hardware based on the result of the arithmetic processing. Further, a part of the functions included in the processor 101 may be realized by another device such as a host device. A part or all of the distance detection apparatus configured using the processor 101 may be configured by hardware that operates without using a program.

続いて、本実施形態の処理部101−2における、バーコードスキャナ100とバーコードラベル106との距離の検出方法について詳細に説明する。   Next, a method for detecting the distance between the barcode scanner 100 and the barcode label 106 in the processing unit 101-2 of this embodiment will be described in detail.

本実施形態では、バーコードスキャナ100のイメージセンサ102が読み込んだ映像から、その映像に基づいた光の受光強度分布を分析し、周波数解析(例えば、フーリエ変換)することによって、バーコードスキャナ100とバーコードラベル106との距離を取得する処理も行う。   In the present embodiment, from the video read by the image sensor 102 of the barcode scanner 100, the received light intensity distribution of light based on the video is analyzed, and frequency analysis (for example, Fourier transform) is performed. Processing for obtaining the distance from the barcode label 106 is also performed.

より詳細には、本実施形態では、イメージセンサ102に映し出されて、イメージセンサ102が読み込んだ映像を周波数解析したものと、イメージセンサに映し出されて、イメージセンサ102が読み込んだ映像をデコードのために二値化したものを周波数解析したものとを比較することによって、バーコードスキャナ100とバーコードラベル106との距離を取得する処理を行う。   More specifically, in the present embodiment, the video image projected on the image sensor 102 and read by the image sensor 102 is subjected to frequency analysis, and the video image projected on the image sensor and read by the image sensor 102 is decoded. A process for obtaining the distance between the barcode scanner 100 and the barcode label 106 is performed by comparing the binarized signal with a frequency analysis result.

この点、[課題を解決するための手段]の欄で述べたように一般的な技術では、厳密には実際に測定すべき対象物であるバーコードラベルと若干異なる位置とバーコードスキャナとの間の距離を測定している点に加え、部品数増加によってバーコードスキャナが大きくなってしまう点やコストが上昇してしまう点が課題となっていた。   In this regard, as described in the section [Means for Solving the Problems], in the general technique, strictly speaking, a position slightly different from the barcode label which is an object to be actually measured and the barcode scanner are different. In addition to measuring the distance between them, the problem is that the barcode scanner becomes larger and the cost increases due to an increase in the number of parts.

しかし、本実施形態のこの手段を用いれば、距離測定対象をバーコードラベルそのものとすることができる。更に本実施形態であれば、一般的なバーコードスキャナの構成品のままで、距離の測定を実現できる。すなわち、本実施形態では一般的な技術が抱えていた課題を解決することが可能となる。   However, if this means of the present embodiment is used, the distance measurement object can be the barcode label itself. Furthermore, according to the present embodiment, distance measurement can be realized with a general barcode scanner component. That is, in the present embodiment, it is possible to solve the problems that the general technology has.

なお、周波数解析にかける周波数領域のデータを読み取り画像データから得るためにはフーリエ変換を用いても良い。特に、高速化のためには、高速フーリエ変換(FFT:Fast Fourier Transform)を用いても良い。   Note that Fourier transform may be used to read frequency domain data to be subjected to frequency analysis from image data. In particular, in order to increase the speed, a fast Fourier transform (FFT) may be used.

ここで、本実施形態の基本原理について図3を参照して説明する。   Here, the basic principle of the present embodiment will be described with reference to FIG.

まず前提として、バーコードスキャナ100の光学的焦点位置にあるバーコードラベル106と比較して、バーコードラベル106が焦点位置から離れると、バーコードスキャナ100のイメージセンサに映る映像がぼける。これを表すのが図3上段に表される301〜303である。   First, as a premise, when the barcode label 106 moves away from the focal position as compared with the barcode label 106 at the optical focal position of the barcode scanner 100, an image reflected on the image sensor of the barcode scanner 100 is blurred. This is represented by 301 to 303 shown in the upper part of FIG.

バーコードラベル106は中間色の無い二色の部分(例えば、白部と黒部)によって実現される。そして、バーコードラベル106が適切な焦点位置にある場合には301のように白部と黒部の境界は明確である。しかし、バーコードラベル106が適切な焦点位置からやや離れると302のようにバーコードスキャナ100のイメージセンサに結像した映像がぼけた状態となる。また、302より更に離れた場合には303に表されるように、映像が302よりも更にぼけた状態となる。   The bar code label 106 is realized by a two-color portion (for example, a white portion and a black portion) having no intermediate color. When the barcode label 106 is at an appropriate focal position, the boundary between the white part and the black part is clear as in 301. However, when the barcode label 106 is slightly separated from the appropriate focal position, the image formed on the image sensor of the barcode scanner 100 becomes blurred as indicated by 302. When the image is further away from 302, the image is more blurred than 302, as indicated by 303.

そして、バーコードスキャナ100のイメージセンサに結像した映像がぼけていない状態である場合には、バーコードスキャナ100のイメージセンサでの受光強度は、バーコードの白・黒の境界部で急峻に又はステップ状に変化するようになる。これに対して、バーコードスキャナ100のイメージセンサに結像した映像がぼけた状態となった場合には、バーコードスキャナ100のイメージセンサでの受光強度は、バーコードの白・黒の境界部でなだらかに変化するようになる。これを表すのが図3の304〜306である。バーコードラベル106が適切な焦点位置にあり、読み取り画像301を得られる場合には、反射率の変化する箇所、すなわちバーコードの白・黒の境界部が明確である(すなわち、境界部での変化が急峻又はステップ状である)波形データ304が得られる。これに対して、バーコードラベル106が適切な焦点位置から離れて、読み取り画像302を得る場合には、反射率の変化する箇所、すなわちバーコードの白・黒の境界部が不明確である(すなわち、境界部での変化がなだらかである)波形データ305が得られる。バーコードラベル106が適切な焦点位置から更に離れて、読み取り画像303を得る場合には、反射率の変化する箇所、すなわちバーコードの白・黒の境界部が更に不明確である(すなわち、境界部での変化が更になだらかである)波形データ306が得られる。このように映像がぼけて白・黒の境界部がなだらかになったものは、バーコードラベル106が適切な焦点位置にあるものと比較して、周波数解析すると低周波となる傾向がある。一方で、適切な焦点位置にあるものは、白・黒の境界部が急峻に変化するため、高周波となる傾向がある。すなわち、バーコードラベル106が、バーコードリーダからの焦点位置にある場合には、読み取られる波形データは白黒変化部が急峻な矩形データであるので、周波数分析をすると、かなり高次までの高調波を多く含むが、バーコードラベル106が、バーコードリーダからの焦点位置からずれた位置にある場合には、読み取られる波形データは、白黒変化部がなだらかな矩形データであるので、周波数分析をすると、低い次数の高調波までしか含まないこととなる。   When the image formed on the image sensor of the barcode scanner 100 is not blurred, the received light intensity at the image sensor of the barcode scanner 100 is steep at the white / black boundary portion of the barcode. Or it changes in a step shape. On the other hand, when the image formed on the image sensor of the barcode scanner 100 is blurred, the received light intensity at the image sensor of the barcode scanner 100 is the boundary between the white and black boundaries of the barcode. It will change gently. This is indicated by 304 to 306 in FIG. When the barcode label 106 is in an appropriate focal position and the read image 301 can be obtained, the portion where the reflectance changes, that is, the white / black boundary portion of the barcode is clear (that is, at the boundary portion). Waveform data 304 (having a steep or step change) is obtained. On the other hand, when the barcode label 106 is separated from the appropriate focal position and the read image 302 is obtained, the portion where the reflectance changes, that is, the white / black boundary portion of the barcode is unclear ( That is, waveform data 305 is obtained in which the change at the boundary portion is gentle. When the barcode label 106 is further away from the appropriate focal position to obtain the read image 303, the portion where the reflectance changes, that is, the white / black boundary portion of the barcode is further unclear (ie, the boundary). Waveform data 306 is obtained. As described above, when the video is blurred and the boundary between white and black is gentle, the frequency tends to be low when the frequency analysis is performed, compared to the case where the barcode label 106 is at an appropriate focal position. On the other hand, an object at an appropriate focal position tends to have a high frequency because the boundary between white and black changes sharply. That is, when the barcode label 106 is at the focal position from the barcode reader, the waveform data to be read is rectangular data with a steep black and white changing portion. However, when the barcode label 106 is at a position deviated from the focal position from the barcode reader, the waveform data to be read is rectangular data with a gentle black and white changing portion. Therefore, only low-order harmonics are included.

本実施形態では、これらの、画像の周波数解析による周波数の偏りとバーコードラベルのバーコードリーダからの距離との関係を、その距離毎に、予め調べておき、距離・正規化対応表として記憶部101−3に格納しておく。そして、センサイメージセンサ102の読み取り画像データから得られた波形データをフーリエ変換することにより得られた周波数データにおける交流周波数成分の振幅和を、距離・正規化対応表に含まれる、距離毎の交流周波数成分の振幅和と比較し、最も振幅和が近い周波数データに対応する距離を、実際の距離の推測値として得る。   In the present embodiment, the relationship between the frequency deviation by the frequency analysis of the image and the distance from the barcode reader of the barcode label is examined in advance for each distance and stored as a distance / normalization correspondence table. Stored in the unit 101-3. The amplitude sum of the AC frequency components in the frequency data obtained by performing Fourier transform on the waveform data obtained from the image data read by the sensor image sensor 102 is included in the distance / normalization correspondence table. Compared with the amplitude sum of the frequency components, the distance corresponding to the frequency data with the closest amplitude sum is obtained as an estimated value of the actual distance.

ここで、比較の前処理となる周波数解析について図4−1〜図4−6を参照して詳細に説明する。   Here, frequency analysis that is preprocessing for comparison will be described in detail with reference to FIGS.

この周波数解析の説明におけるイメージセンサは、横方向に受光素子が1つずつ、計256ピクセル並んでいるラインイメージセンサであるものと想定する。そして、各受光素子には、左側から0番、1番・・・255番と番号が振られるものと想定する。また、受光強度最大値を1とし、最小値を0とする。   The image sensor in the description of the frequency analysis is assumed to be a line image sensor in which a total of 256 pixels are arranged one by one in the horizontal direction. Each light receiving element is assumed to be numbered 0, 1,..., 255 from the left. The maximum value of received light intensity is set to 1, and the minimum value is set to 0.

このとき、横軸を受光素子の番号、縦軸を各受光素子の受光強度としたときに、図4−1の様な波形になるものとする。ここで、図4−1の波形は正弦波形である。   At this time, when the horizontal axis is the number of the light receiving element and the vertical axis is the light receiving intensity of each light receiving element, the waveform is as shown in FIG. Here, the waveform of FIG. 4A is a sine waveform.

また、図4−1の例では、受光素子256個に対して1周期分の正弦波形であり、これを波長1と定める。   In the example of FIG. 4A, a sinusoidal waveform for one cycle is set for 256 light receiving elements, and this is defined as a wavelength 1.

図4−1の256個の受光強度データを周波数解析(FFTで解析した結果出てくる複素数の値の絶対値を利用)すると、図4−2の様になる。図4−2の周波数解析結果の横軸は   When the 256 received light intensity data in FIG. 4A are subjected to frequency analysis (using the absolute value of the complex number obtained as a result of analysis by FFT), the result is as shown in FIG. The horizontal axis of the frequency analysis result in Fig. 4-2 is

を示していて、即ち周波数そのものである。図4−2では、横軸0のときに縦軸128、横軸1のときに縦軸64となっている。 That is, the frequency itself. In FIG. 4B, the vertical axis is 128 when the horizontal axis is 0, and the vertical axis is 64 when the horizontal axis is 1.

なお、一般的には、音波や電波の場合、波長×周波数=速度という式が成り立つが、本実施形態では、具体的な速度成分や時間成分が存在しないため、上記の式においては、波長×周波数=定数、とみなし、さらに簡単のために定数=1としている。   In general, in the case of sound waves and radio waves, the equation of wavelength × frequency = velocity is established, but in the present embodiment, there is no specific velocity component or time component. It is assumed that the frequency = constant, and constant = 1 for further simplicity.

図4−2に現れている、横軸の0とは、直流成分であって、周波数や波長として示されない成分を示している。これは図4−1の波形が正弦波形に対して、+0.5底上げされた状態のデータが256個分の合計値、即ち0.5×256=128の成分が表現されていることになる。   In FIG. 4B, 0 on the horizontal axis indicates a direct current component that is not indicated as a frequency or wavelength. This means that the data in the state where the waveform in FIG. 4A is raised by +0.5 with respect to the sine waveform is the total value of 256, that is, 0.5 × 256 = 128 components are expressed. .

図4−2に現れている、横軸1は、上記したように   The horizontal axis 1 appearing in FIG. 4-2 is as described above.

であることを示しているので、即ち波長1、周波数1であるということになる。 That is, it means that the wavelength is 1 and the frequency is 1.

上述した説明は、波長1/4の場合と波長1/16の場合も同様に適用できる。   The above description can be similarly applied to the case of the wavelength 1/4 and the case of the wavelength 1/16.

図4−3は、波長1/4(イメージセンサ素子の全体幅に対して波形が4周期分あるという意味)の場合の受光強度分布を表す図である。図4−4は図4−3を周波数解析した結果を表す図である。図4−4を参照すると、図4−1と同様に横軸0のときに縦軸128、また、横軸4のところで縦軸64となる。この横軸の”4”が即ち周波数を示している。   FIG. 4C is a diagram illustrating a received light intensity distribution in the case of the wavelength ¼ (meaning that the waveform has four periods with respect to the entire width of the image sensor element). FIG. 4-4 is a diagram illustrating a result of frequency analysis of FIG. 4-3. Referring to FIG. 4-4, similarly to FIG. 4-1, the vertical axis 128 is obtained when the horizontal axis is 0, and the vertical axis 64 is obtained at the horizontal axis 4. “4” on the horizontal axis indicates the frequency.

図4−5は波長1/16の場合の受光強度分布(の一部)を表す図である。図4−6は図4−5を周波数解析した結果を表す図である。図4−6を参照すると、図4−1と同様に横軸0のときに縦軸128、また、横軸16のところで縦軸64となる。この横軸の”16”が即ち周波数を示している。   FIG. 4-5 is a diagram illustrating (a part of) the received light intensity distribution when the wavelength is 1/16. 4-6 is a diagram illustrating a result of frequency analysis of FIG. 4-5. Referring to FIG. 4-6, as in FIG. 4A, the vertical axis 128 when the horizontal axis is 0, and the vertical axis 64 at the horizontal axis 16. The horizontal axis “16” indicates the frequency.

このように、イメージセンサ全体幅で1周期となる周期波形を波長1とし、このときの周波数を1とすると、イメージセンサ受光強度を示す波形データを周波数解析した結果の横軸が周波数であり、縦軸はその周波数成分の強度を示すということである。なお、周波数成分の強度としては、上述したように、FFTで解析した結果出てくる複素数の値の絶対値である振幅を利用してもよいが、その自乗であるパワーを用いてもよい。   Thus, if the periodic waveform having one period in the entire width of the image sensor is wavelength 1, and the frequency at this time is 1, the horizontal axis of the result of frequency analysis of the waveform data indicating the image sensor received light intensity is the frequency, The vertical axis indicates the intensity of the frequency component. As the intensity of the frequency component, as described above, an amplitude that is an absolute value of a complex value obtained as a result of analysis by FFT may be used, but a power that is the square thereof may be used.

そして、横軸の値が小さいと周波数が「低い」、大きいと周波数が「高い」ということになる。   When the value on the horizontal axis is small, the frequency is “low”, and when the value is large, the frequency is “high”.

以下、上述の説明で示した図のデータを表として示す。ここで、表1−1及び表1−2は各波形のセンサ受光強度を表し、表2は各波形のセンサ受光強度を周波数解析した結果を表す。   Hereinafter, the data of the figure shown by the above-mentioned description is shown as a table | surface. Here, Table 1-1 and Table 1-2 show the sensor light reception intensity of each waveform, and Table 2 shows the result of frequency analysis of the sensor light reception intensity of each waveform.

なお、上述の説明では、周波数解析のために高速フーリエ変換(FFT)を利用している。このため、解析結果の有効データ数は解析元のデータ数の半分となる。つまり、本例では解析元の波形データの数が0〜255の256個であるから、解析結果の周波数データの有効データ数は0〜127までの128個となる。   In the above description, Fast Fourier Transform (FFT) is used for frequency analysis. For this reason, the number of valid data of the analysis result is half of the number of data of the analysis source. That is, in this example, the number of waveform data of the analysis source is 256 from 0 to 255, so the number of effective data of the frequency data of the analysis result is 128 from 0 to 127.

以上が本実施形態における周波数解析の概念である。続いて、具体例を用いた周波数解析及び解析結果に基づいた比較について詳細に説明する。   The above is the concept of frequency analysis in the present embodiment. Next, frequency analysis using a specific example and comparison based on the analysis result will be described in detail.

図5にはバーコードラベル106の具体例として、一般的なバーコードラベル501を表す。バーコードスキャナ100を通常使用する際に実際に読み取るのは、バーコードラベル501のような一般的なバーコードラベルである。もっとも以下の説明においては、説明を簡単にするために、図6に表されるバーコードラベルを模した等間隔に縦筋が描かれたラベル601を用いて説明する。   FIG. 5 shows a general barcode label 501 as a specific example of the barcode label 106. What is actually read when the barcode scanner 100 is normally used is a general barcode label such as the barcode label 501. However, in the following description, in order to simplify the description, a description will be given using a label 601 in which vertical stripes are drawn at equal intervals simulating the barcode label shown in FIG.

図6のラベル601を、バーコードスキャナの光学的な焦点となる位置に配置した場合、イメージセンサ部102に適切に結像し、ラベル601の白部分は受光強度が高く、黒部分は受光強度が低い状態としてイメージセンサ出力を得ることができる。   When the label 601 in FIG. 6 is arranged at a position that becomes the optical focus of the barcode scanner, an image is appropriately formed on the image sensor unit 102. The white portion of the label 601 has a high light reception intensity, and the black portion has a light reception intensity. The image sensor output can be obtained in a low state.

説明を簡単にするため、適切な距離にて読み取りを行った場合にイメージセンサ102で取得される白部分の受光強度の値をイメージセンサ出力の最大値とする。また、適切な距離にて読み取りを行った場合にイメージセンサ102で取得される黒部の受光強度の値を0とする。更に、イメージセンサの受光素子が256ピクセルあるものとする。このときにイメージセンサから得られる受光強度の値は、その最大値を1として規格化した場合、横軸をイメージセンサ102のピクセルの位置、縦軸を受光強度値として表すと、図7に表される様になる。   In order to simplify the description, the value of the received light intensity of the white portion acquired by the image sensor 102 when reading is performed at an appropriate distance is set as the maximum value of the image sensor output. In addition, the value of the received light intensity of the black portion acquired by the image sensor 102 when reading is performed at an appropriate distance is set to zero. Further, it is assumed that the light receiving element of the image sensor has 256 pixels. In this case, when the received light intensity value obtained from the image sensor is normalized with the maximum value being 1, the horizontal axis represents the pixel position of the image sensor 102 and the vertical axis represents the received light intensity value. It will be done.

次に、図8は図7の一部(40ピクセル分)を拡大すると共に、バーコードラベルがバーコードスキャナの光学的な焦点となる位置から所定距離だけ離れた位置にある場合の受光強度を重ね合わせた図である。   Next, FIG. 8 enlarges a part of FIG. 7 (for 40 pixels), and shows the received light intensity when the barcode label is at a predetermined distance from the position where it becomes the optical focus of the barcode scanner. FIG.

図8の破線801は、バーコードラベルがバーコードスキャナの光学的な焦点となる位置にある場合のイメージセンサ受光強度波形を示す。すなわち、801は図7に表された波形を拡大したものである。801を参照すると明らかなように受光強度が1の或るピクセルがあり、この或るピクセルに隣接するピクセルでは受光強度が0となっている。このようにバーコードラベルがバーコードスキャナの光学的な焦点となる位置にある場合には、受光強度が1であるか0であるかを正確に測定できることから波形が急峻なものとなっている。   A broken line 801 in FIG. 8 shows a received light intensity waveform of the image sensor when the barcode label is at a position where it becomes the optical focus of the barcode scanner. That is, reference numeral 801 is an enlarged version of the waveform shown in FIG. As apparent from reference numeral 801, there is a certain pixel having a light reception intensity of 1, and the light reception intensity is 0 in a pixel adjacent to the certain pixel. In this way, when the barcode label is at a position where it becomes the optical focus of the barcode scanner, it is possible to accurately measure whether the received light intensity is 1 or 0, so that the waveform is steep. .

一方で、バーコードラベルがバーコードスキャナの光学的な焦点となる位置に無い場合には図8の実線802の様に、白部と黒部の境界がなだらかな曲線となる。これは境界付近の受光強度が1又は0以外の値を取り、なだらかに変化していくからである。この例では、値が0であるピクセルと値が1であるピクセルとの間には、値が0よりも大きくて、1よりも小さいピクセルが6個程度ある。   On the other hand, when the bar code label is not at the position where it becomes the optical focus of the bar code scanner, the boundary between the white part and the black part becomes a gentle curve as shown by the solid line 802 in FIG. This is because the received light intensity in the vicinity of the boundary takes a value other than 1 or 0 and changes gently. In this example, there are about six pixels having a value greater than 0 and less than 1 between a pixel having a value of 0 and a pixel having a value of 1.

次に、図9は前述のバーコードラベルがバーコードスキャナの光学的な焦点となる位置にある場合と、バーコードラベルがバーコードスキャナの光学的な焦点となる位置から所定距離だけ離れた位置にある場合について、受光強度波形(図8の破線801の波形及び実線802の波形に相当)について、それぞれ高速フーリエ変換による周波数解析を行った結果を重ねたものである。破線901がイメージセンサ強度波形を二値化した波形(図8の破線801の波形に相当)を周波数解析したもの、実線902がイメージセンサ強度(図8の実線802の波形に相当)を周波数解析したものである。   Next, FIG. 9 shows a case where the barcode label is at a position where it becomes the optical focus of the barcode scanner, and a position where the barcode label is separated from the position where it becomes the optical focus of the barcode scanner by a predetermined distance. , The results of frequency analysis by fast Fourier transform are superimposed on the received light intensity waveform (corresponding to the waveform of the broken line 801 and the waveform of the solid line 802 in FIG. 8). A broken line 901 is a frequency analysis of a binarized waveform of the image sensor intensity waveform (corresponding to the waveform of the broken line 801 in FIG. 8), and a solid line 902 is a frequency analysis of the image sensor intensity (corresponding to the waveform of the solid line 802 in FIG. 8). It is a thing.

図10は図9の枠903を拡大して得られた、部分拡大グラフである。拡大図においても、破線901は、イメージセンサ強度波形を二値化した波形(図8の破線801の波形に相当)を周波数解析したもの、実線902がイメージセンサ強度(図8の実線802の波形に相当)を周波数解析したものである。   FIG. 10 is a partially enlarged graph obtained by enlarging the frame 903 in FIG. Also in the enlarged view, a broken line 901 is a frequency analysis of a binarized waveform of the image sensor intensity waveform (corresponding to the waveform of the broken line 801 in FIG. 8), and a solid line 902 is the image sensor intensity (the waveform of the solid line 802 in FIG. 8). Is equivalent to frequency analysis.

図10を参照すると、バーコードラベル501がバーコードスキャナ100の光学的な焦点から所定距離だけ離れた位置にある場合の周波数解析の結果である周波数・振幅特性(実線902を参照)は、バーコードラベル501がバーコードスキャナ100の光学的な焦点となる位置にある場合の周波数解析の結果である周波数・振幅特性(破線901を参照)と比較して、全体的に高周波成分の値の振幅が小さくなっていることがわかる。   Referring to FIG. 10, the frequency / amplitude characteristics (see solid line 902) as a result of frequency analysis when the barcode label 501 is located at a predetermined distance from the optical focus of the barcode scanner 100 are shown in FIG. Compared with the frequency / amplitude characteristics (see the broken line 901), which is the result of frequency analysis when the code label 501 is located at the optical focal point of the barcode scanner 100, the overall amplitude of the value of the high frequency component It can be seen that is smaller.

図7〜図10に図示された内容に関する表を以下に表す。ここで、表3−1及び表3−2は各波形のセンサ受光強度を表し、表4は各波形のセンサ受光強度を周波数解析した結果を表す。   Tables relating to the contents shown in FIGS. 7 to 10 are shown below. Here, Table 3-1 and Table 3-2 represent the sensor light reception intensity of each waveform, and Table 4 represents the result of frequency analysis of the sensor light reception intensity of each waveform.

表3−1及び表3−2は、イメージセンサ102におけるピクセル番号と、各ピクセル番号に対応する受光強度との対応関係を、バーコードラベル501がバーコードスキャナ100の光学的な焦点位置にある場合と、バーコードラベル501がバーコードスキャナ100の光学的な焦点距離にない場合とについて、比較できるように、並べて示した表である。   Tables 3-1 and 3-2 show the correspondence between the pixel number in the image sensor 102 and the received light intensity corresponding to each pixel number, and the barcode label 501 is at the optical focal position of the barcode scanner 100. The table shows the case where the barcode label 501 is not at the optical focal length of the barcode scanner 100 for comparison.

表4は、周波数領域における周波数番号と、各周波数番号に対応する振幅との対応関係を、バーコードラベル501がバーコードスキャナ100の光学的な焦点位置にある場合と、バーコードラベル501がバーコードスキャナ100の光学的な焦点距離にない場合とについて、比較できるように、並べて示した表である。   Table 4 shows the correspondence between the frequency number in the frequency domain and the amplitude corresponding to each frequency number, when the barcode label 501 is at the optical focus position of the barcode scanner 100, and when the barcode label 501 is a bar code. It is the table | surface shown side by side so that it can compare with the case where it is not in the optical focal distance of the code scanner 100. FIG.

上記の表4に表されるように周波数解析結果の違いを定量的に示すために、それぞれの周波数解析結果を表に並べた後、周波数解析結果の値の合計値を比較する。すなわち、上述の例で言うと、周波数番号1に対応する振幅から周波数番号127に対応する振幅までの合計値を、それぞれの場合について求め、これにより得た2つの合計値を比較する。比較としては、例えば、焦点位置にあるかどうかがわからない場合に対応する合計値の、焦点位置にある場合に対応する合計値に対する割合を求めることを行う。   In order to quantitatively show the difference in the frequency analysis results as shown in Table 4, the frequency analysis results are arranged in a table, and then the total values of the frequency analysis results are compared. That is, in the above example, the total value from the amplitude corresponding to frequency number 1 to the amplitude corresponding to frequency number 127 is obtained for each case, and the two total values obtained thereby are compared. As a comparison, for example, the ratio of the total value corresponding to the case where it is not known whether or not it is in the focal position to the total value corresponding to the case where it is in the focal position is obtained.

すると、バーコードラベルが焦点位置にある場合に対応するセンサ合計値(「合計値1」とする)と、バーコードラベルが焦点位置から所定距離だけ離れた位置にある場合に対応する合計値(「合計値2」とする)とを比較すると、合計値2は、合計値1に対して、約21.9%小さいことがわかる。   Then, the sensor total value corresponding to the case where the barcode label is at the focal position (referred to as “total value 1”) and the total value corresponding to the case where the barcode label is located at a predetermined distance from the focal position ( And “total value 2”), it can be seen that the total value 2 is about 21.9% smaller than the total value 1.

もっとも、この周波数解析結果の合計値そのものや、合計値の比較結果そのものを用いて、バーコードラベルがバーコードスキャナ100の焦点距離から離れた位置にあるか否かを判断することや、離れている場合にはどれだけ離れた位置にあるかということを判断することを簡単に行うことはできない。   However, it is possible to determine whether or not the barcode label is at a position away from the focal length of the barcode scanner 100 by using the total value itself of the frequency analysis results or the comparison result of the total values. It is not easy to determine how far away they are.

そのため本実施形態では、事前に、バーコードラベルとバーコードスキャナ100との間の距離を複数設定し、設定した各距離毎に、その距離だけバーコードラベルとバーコードスキャナ100とが離れている場合に得られる周波数解析値の合計値(つまり、周波数毎の振幅を直流以外の周波数について合計した値)を求める。そして、距離と合計値との対応関係を保持しておく。距離には、焦点距離(つまり、適正距離)も含まれる。それから、各距離に対応する合計値と焦点距離に対応する合計値との比率を求める。そして、各距離に対応するこの比率と、焦点距離に対応する合計値と、を事前に記憶部101−3に格納しておく。   Therefore, in the present embodiment, a plurality of distances between the barcode label and the barcode scanner 100 are set in advance, and the barcode label and the barcode scanner 100 are separated by the distance for each set distance. The total value of the frequency analysis values obtained in this case (that is, the value obtained by summing the amplitude for each frequency for frequencies other than DC) is obtained. The correspondence between the distance and the total value is held. The distance includes a focal length (that is, an appropriate distance). Then, a ratio between the total value corresponding to each distance and the total value corresponding to the focal length is obtained. Then, the ratio corresponding to each distance and the total value corresponding to the focal length are stored in the storage unit 101-3 in advance.

バーコードスキャナ100がバーコードを読み取った場合には、その読み取りにより得られた合計値と記憶部101−3に記憶されている焦点距離との比率を算出し、算出された比率に最も近い比率を記憶部101−3から探し、その最も近い比率に対応する距離を、バーコードを読み取った時の、バーコードスキャナ100とバーコードとの間の実際の距離として推測する。   When the barcode scanner 100 reads a barcode, the ratio between the total value obtained by the reading and the focal length stored in the storage unit 101-3 is calculated, and the ratio closest to the calculated ratio Is stored in the storage unit 101-3, and the distance corresponding to the closest ratio is estimated as the actual distance between the barcode scanner 100 and the barcode when the barcode is read.

上記の例では、比率を用いたが、そうではなく、各距離とその距離に対応する合計値との対応関係を複数の距離について、事前に記憶部101−3に格納しておいて、バーコードスキャナ100がバーコードを読み取った場合には、その読み取りにより得られた合計値に最も近い合計値を記憶部101−3から探し、その最も近い合計値に対応する距離を、バーコードを読み取った時の、バーコードスキャナ100とバーコードとの間の実際の距離として推測するようにしてもよい。   In the above example, the ratio is used, but instead, the correspondence relationship between each distance and the total value corresponding to the distance is stored in advance in the storage unit 101-3 for a plurality of distances. When the code scanner 100 reads the barcode, the total value closest to the total value obtained by the reading is searched from the storage unit 101-3, and the distance corresponding to the closest total value is read from the barcode. The actual distance between the barcode scanner 100 and the barcode may be estimated.

更に、上記の何れの場合であっても、直流の振幅で各周波数の振幅を正規化してから上記の処理を行うようにするのが好ましい。   Furthermore, in any of the above cases, it is preferable to perform the above processing after normalizing the amplitude of each frequency with the amplitude of the direct current.

なお、距離・正規化対応表を格納するメモリとしては記憶部101−3を利用することが考えられるがこれ以外のメモリを利用するようにしても良い。   Note that the memory 101-3 may be used as a memory for storing the distance / normalization correspondence table, but other memory may be used.

上記の方法では、予め記憶部101−3に、各距離に対応する上述の比率と、焦点距離に対応する合計値と、を格納しておくことや、予め記憶部101−3に、各距離とその距離に対応する合計値との対応関係を複数の距離について格納しておくことが必要である。すなわち、事前に測定と計算をして、その計算結果を記憶部101−3に格納しておく必要がある。また、上記の方法では、同一のバーコードを読み取る場合には、距離推定の精度を維持できるが、異なったバーコードを読み取る場合には、距離測定の精度を維持できるとは限らない。   In the above method, the above-described ratio corresponding to each distance and the total value corresponding to the focal length are stored in the storage unit 101-3 in advance, or each distance is stored in the storage unit 101-3 in advance. It is necessary to store the correspondence between the distance and the total value corresponding to the distance for a plurality of distances. That is, it is necessary to perform measurement and calculation in advance and store the calculation result in the storage unit 101-3. In the above method, the accuracy of distance estimation can be maintained when reading the same barcode, but the accuracy of distance measurement cannot always be maintained when reading different barcodes.

これに対して、次に説明する方法を用いると、記憶部101−3に何かしらのデータを記憶しておく必要がなくなり、1回のバーコードの読み取り操作により得られたバーコード画像自体から、バーコードがバーコードスキャナ100の焦点位置にあるか否かを判断することができる。つまり、バーコードを読み取る度に、その読み取りの時に得られたバーコード画像から、バーコードがバーコードスキャナ100の焦点位置にあるか否かを判断することができる。   On the other hand, when the method described below is used, it is not necessary to store any data in the storage unit 101-3, and the barcode image itself obtained by one barcode reading operation can be used. It can be determined whether or not the barcode is at the focal position of the barcode scanner 100. That is, each time a barcode is read, it can be determined from the barcode image obtained at the time of reading whether the barcode is at the focal position of the barcode scanner 100.

すなわち、その方法では、バーコードスキャナでバーコードラベルをデコードする際に、必ず存在する、「受光強度波形を二値化する工程」により得られた二値化データを利用する。   That is, in this method, binarized data obtained by the “step of binarizing the received light intensity waveform”, which always exists when the bar code label is decoded by the bar code scanner, is used.

そして、この二値化工程で得られた二値化データを仮想の理想的な波形データ(バーコードラベルが焦点位置にある場合の波形データ)であるとみなす。そして、この二値化データを周波数解析する。他方では、二値化する前の元のバーコード画像も周波数解析する。そして、これらの2つの周波数解析の結果を利用して、バーコードがバーコードスキャナ100の焦点位置にあるか否かを判断する。   Then, the binarized data obtained in this binarization step is regarded as virtual ideal waveform data (waveform data when the barcode label is at the focal position). Then, the binarized data is subjected to frequency analysis. On the other hand, the original barcode image before binarization is also subjected to frequency analysis. Then, using the results of these two frequency analyses, it is determined whether or not the barcode is at the focal position of the barcode scanner 100.

これにより、バーコードラベルがバーコードスキャナ100の焦点位置にあると想定される場合の周波数解析結果と、バーコードラベルがバーコードスキャナ100の焦点位置にあるか否かが不明である場合の周波数解析結果とを用いて、バーコードラベルが実際にバーコードスキャナ100の焦点位置にあるか否かを判断し、また、焦点位置になければ、どれだけ焦点距離から離れた位置にあるかを求めることができる。   Thus, the frequency analysis result when the barcode label is assumed to be at the focal position of the barcode scanner 100 and the frequency when it is unknown whether the barcode label is at the focal position of the barcode scanner 100 or not. Using the analysis result, it is determined whether or not the barcode label is actually at the focal position of the barcode scanner 100, and if it is not at the focal position, the distance from the focal distance is obtained. be able to.

より詳細に説明をすると、一方では、読み取ったバーコード画像を二値化する前のデータを周波数解析することにより得られた全ての交流周波数の振幅の和(「二値化前振幅和」という。)を求め、他方では、読み取ったバーコード画像を二値化した後のデータを周波数解析することにより、全ての交流周波数の振幅の和(「二値後前振幅和」という。)を求める。そして、二値化前振幅和の二値化後振幅和に対する比率を算出する。算出された比率が100%から所定の範囲にあれば、バーコードは、バーコードスキャナ100の焦点位置にあると判断する。また、バーコードの位置とバーコードスキャナ100の焦点位置との間の距離と、二値化前振幅和の二値化後振幅和に対する比率との関係に関する既存のデータがあるならば、このデータを参照することにより、現在読み取ったバーコードから得た比率を基に、現在読み取ったバーコードがバーコードスキャナ100の焦点位置からどれだけ離れた位置にあるかを推定することができる。   In more detail, on the other hand, the sum of the amplitudes of all the AC frequencies obtained by frequency analysis of the data before binarizing the read barcode image (referred to as “amplitude sum before binarization”). On the other hand, the data after binarizing the read barcode image is subjected to frequency analysis to obtain the sum of amplitudes of all AC frequencies (referred to as “pre-binary amplitude sum”). . Then, a ratio of the amplitude sum before binarization to the amplitude sum after binarization is calculated. If the calculated ratio is within a predetermined range from 100%, it is determined that the barcode is at the focal position of the barcode scanner 100. In addition, if there is existing data regarding the relationship between the distance between the barcode position and the focal position of the barcode scanner 100 and the ratio of the amplitude sum before binarization to the amplitude sum after binarization, this data is present. By referring to, it is possible to estimate how far the currently read barcode is from the focal position of the barcode scanner 100 based on the ratio obtained from the currently read barcode.

尚、参考までに、周波数解析結果の合計値そのもの、あるいは理想波形との差から算術的に距離を決定するような通常の方法では、バーコードのバーコードスキャナ100に対する距離を精度良く求めることが難しい理由について次に説明をする。すなわち、バーコードスキャナのレンズの焦点距離、レンズの性能、光学的なF値、イメージセンサの許容錯乱円径(画素の大きさ)、バーコードラベルの焦点が合う距離、バーコードスキャナから照射する照明の強度など、バーコードスキャナそのものの設計仕様に、通常の方法により求めたバーコードのバーコードスキャナ100に対する距離が、依存するため、通常の方法により、そのような距離を算出してもその距離精度を高めることができないのである。つまり、周波数解析結果の合計値そのものや理想波形との差は、バーコードスキャナの種別に左右されるため、複数の種類のバーコードスキャナに一律に適用できる所定の基準を設けた上で、通常の方法で距離を求めることが難しい。   For reference, a normal method of arithmetically determining the distance from the total frequency analysis result itself or the difference from the ideal waveform can accurately determine the distance of the barcode to the barcode scanner 100. The following explains why it is difficult. That is, the focal length of the lens of the barcode scanner, the performance of the lens, the optical F value, the permissible circle of confusion (pixel size) of the image sensor, the distance at which the barcode label is focused, and the irradiation from the barcode scanner Since the distance from the barcode to the barcode scanner 100 determined by a normal method depends on the design specifications of the barcode scanner itself, such as the intensity of illumination, even if such a distance is calculated by a normal method The distance accuracy cannot be increased. In other words, since the difference between the total frequency analysis result itself and the ideal waveform depends on the type of barcode scanner, it is usually necessary to set a predetermined standard that can be applied uniformly to multiple types of barcode scanners. It is difficult to find the distance by this method.

続いて、図12を参照して本実施形態の動作について説明する。図12は、本実施形態の基本的動作を表すフローチャート且つイメージ図である。なお、今回の動作は、図5のラベル501のような一般的なバーコードラベルを読み取る場合を想定した動作の例である。もっとも説明を単純化するために、実際のラベルを模した図11のラベル1001を用いる。   Next, the operation of this embodiment will be described with reference to FIG. FIG. 12 is a flowchart and an image diagram showing the basic operation of the present embodiment. This operation is an example of an operation assuming a case where a general bar code label such as the label 501 in FIG. 5 is read. In order to simplify the explanation, the label 1001 in FIG. 11 simulating an actual label is used.

まず、バーコードスキャナ100の読み取り処理が開始される(ステップS11)。読み取り対象となるバーコードのイメージ図をフローチャート中のステップS11と併記する。   First, the reading process of the barcode scanner 100 is started (step S11). An image diagram of the barcode to be read is shown together with step S11 in the flowchart.

次に、バーコードスキャナ100内の各部が協働することによりバーコードラベルがイメージセンサ102に結像する(ステップS12)。なお、バーコードラベルを模式化したラベルのイメージ図をフローチャート中のステップS12と併記する。   Next, each part in the bar code scanner 100 cooperates to form an image on the bar code label on the image sensor 102 (step S12). Note that an image of a label schematically representing a bar code label is shown together with step S12 in the flowchart.

そして、イメージセンサ制御部101−1はイメージセンサ102から受光強度を示す波形を有するバーコード画像データを取得する。取得したバーコード画像データは処理部101−2が記憶部101−3に格納する(ステップS13)。なお、センサ受光強度を示す波形を有するバーコード画像データの模式的な波形図をフローチャート中のステップS13と併記する。   Then, the image sensor control unit 101-1 acquires barcode image data having a waveform indicating the received light intensity from the image sensor 102. The acquired barcode image data is stored in the storage unit 101-3 by the processing unit 101-2 (step S13). A schematic waveform diagram of the barcode image data having a waveform indicating the sensor light reception intensity is also shown together with step S13 in the flowchart.

次に、ステップS13にて取得した二値化前バーコード画像データを二値化することにより二値化後バーコード画像データを取得する(ステップS14)。二値化後バーコード画像データの波形の模式的な波形図をフローチャート中のステップS14と併記する。   Next, the binarized barcode image data is obtained by binarizing the pre-binarized barcode image data obtained in step S13 (step S14). A schematic waveform diagram of the waveform of the barcode image data after binarization is shown together with step S14 in the flowchart.

このとき、バーコード106がバーコードスキャナ100の光学的な焦点位置からずれているのであれば、焦点があわずにイメージセンサ−102にはバーコードラベル106が不鮮明に映り、これにより二値化前バーコード画像データの白黒境界部がなだらかになる。例えば、図11のラベルに対して、イメージセンサ102には図13のような受光強度波形が得られたものと想定する。なお、図13における数値は規格化(最大値を1とする。)したものとする。   At this time, if the bar code 106 is deviated from the optical focus position of the bar code scanner 100, the bar code label 106 appears unclearly on the image sensor 102 without being in focus, thereby binarizing. The black and white border portion of the previous barcode image data becomes gentle. For example, it is assumed that the received light intensity waveform as shown in FIG. 13 is obtained in the image sensor 102 with respect to the label of FIG. Note that the numerical values in FIG. 13 are normalized (the maximum value is 1).

図13の二値化前バーコード画像データの波形は若干白・黒の境界部がなだらかになっている。この図13にその波形が示されている二値化前バーコード画像データを二値化することにより得られた二値化後バーコード画像データの波形を表すのが図14である。   The waveform of the pre-binarized barcode image data in FIG. 13 has a slightly smooth white / black boundary. FIG. 14 shows the waveform of the binarized barcode image data obtained by binarizing the pre-binarized barcode image data whose waveform is shown in FIG.

また、図13と図14にそれぞれ表されていた二値化前バーコード画像データと二値化後バーコード画像データの波形を重ねて、更に、その一部を拡大することにより得た部分拡大図が図15である。図15中、破線1501が二値化後バーコード画像データの波形(図14に表される波形に相当)であり、実線1502が受光強度そのままの二値化前バーコード画像データの波形(図13に表される波形に相当)である。   Further, the partial enlargement obtained by superimposing the waveform of the pre-binarized barcode image data and the post-binarized barcode image data shown in FIGS. 13 and 14 and further magnifying a part thereof. The figure is FIG. In FIG. 15, the broken line 1501 is the waveform of the barcode image data after binarization (corresponding to the waveform shown in FIG. 14), and the solid line 1502 is the waveform of the barcode image data before binarization with the received light intensity as it is (see FIG. 15). 13).

次に、二値化前バーコード画像データを周波数解析する(ステップS16)。これと並行して、二値化後バーコード画像データを周波数解析する(ステップS15)。これらの周波数解析には、例えば、高速フーリエ変換を使用する。なお、それぞれの周波数解析結果のイメージ図をフローチャート中のステップS15及びステップS16と併記する。   Next, frequency analysis is performed on the pre-binarized barcode image data (step S16). In parallel with this, the binarized barcode image data is subjected to frequency analysis (step S15). For these frequency analysis, for example, a fast Fourier transform is used. In addition, the image figure of each frequency analysis result is written together with step S15 and step S16 in a flowchart.

図16は、ステップS15での周波数解析の結果と、ステップS16での周波数解析の結果とを重ねて示す。破線1601は、ステップS15での周波数解析の結果を示し、実線1602は、ステップS16での周波数解析の結果を示す。すなわち、破線1601は、二値化後バーコード画像データの周波数解析の結果である、周波数・振幅特性を示し、実線1602は、二値化前バーコード画像データの周波数解析の結果である、周波数・振幅特性を示す。   FIG. 16 shows the result of the frequency analysis in step S15 and the result of the frequency analysis in step S16 in an overlapping manner. A broken line 1601 indicates the result of the frequency analysis in step S15, and a solid line 1602 indicates the result of the frequency analysis in step S16. That is, the broken line 1601 indicates the frequency / amplitude characteristic that is the result of the frequency analysis of the binarized barcode image data, and the solid line 1602 indicates the frequency that is the result of the frequency analysis of the pre-binarized barcode image data.・ Shows amplitude characteristics.

次に、ステップS15で二値化後バーコード画像データを周波数解析することにより得られた全ての交流周波数の振幅の和である、上述した二値化後振幅和と、ステップS16で二値化前バーコード画像データを周波数解析することにより得られた全ての交流周波数の振幅の和である、上述した二値化前振幅和と、を求め、その上で、下記の計算式に従って、両者の差の二値化後振幅和に対する比率(すなわち、正規化差)を求める(ステップS17)。   Next, the binarized amplitude sum described above, which is the sum of the amplitudes of all AC frequencies obtained by frequency analysis of the binarized barcode image data in step S15, and binarization in step S16 The above-mentioned pre-binarization amplitude sum, which is the sum of the amplitudes of all AC frequencies obtained by frequency analysis of the previous barcode image data, is obtained, and then, according to the following calculation formula, A ratio of the difference to the sum of amplitude after binarization (that is, a normalized difference) is obtained (step S17).

正規化差=差/二値化後振幅和
=(二値化前振幅和―二値化後振幅和)/二値化後振幅和
一方、ステップS15〜17の処理と前後して、又は、ステップS15〜17の処理と平行してステップS18が実施される。
Normalized difference = difference / amplitude sum after binarization
= (Pre-binarization amplitude sum-binarization amplitude sum) / binarization amplitude sum On the other hand, before or after the processing of steps S15 to S17, or in parallel with the processing of steps S15 to S17, step S18 Is implemented.

ステップS18では、ステップS14にて得た二値化後バーコード画像データに対して、バーコードの規格に対応した方法にて、デコードを試みる(ステップS18)。次に、デコードに成功したか否かを確認する(ステップS19)。   In step S18, the post-binarized barcode image data obtained in step S14 is decoded by a method corresponding to the barcode standard (step S18). Next, it is confirmed whether or not the decoding is successful (step S19).

ここで、デコードに成功すれば(ステップS19においてYes)、距離を決定する工程であるステップS20にすすむ。   Here, if the decoding is successful (Yes in step S19), the process proceeds to step S20 which is a step of determining the distance.

ここで、記憶部101−3には、バーコードのバーコードスキャナ100に対する距離と、正規化差との対応関係を、想定した複数の距離範囲についてまとめた距離・正規化差対応表が格納されている。ステップS20では、ステップS17で算出した正規化差が、正規化差対応表のどの範囲の正規化差に属しているかを見て、正規化差対応表においてその正規化差範囲に対応する距離範囲を、バーコードのバーコードスキャナ100に対する実際の距離範囲として推測する(ステップS20)。なお、距離・正規化対応表から得た距離・正規化差対応表のイメージ図をフローチャート中のステップS20と併記する。   Here, the storage unit 101-3 stores a distance / normalized difference correspondence table in which correspondence between the distance of the barcode to the barcode scanner 100 and the normalized difference is summarized for a plurality of assumed distance ranges. ing. In step S20, the range of the normalized difference calculated in step S17 belongs to which range of the normalized difference correspondence table, and the distance range corresponding to the normalized difference range in the normalized difference correspondence table. Is estimated as the actual distance range of the barcode to the barcode scanner 100 (step S20). An image diagram of the distance / normalization difference correspondence table obtained from the distance / normalization correspondence table is shown together with step S20 in the flowchart.

距離・正規化対応表の一例を表5として下記に示す。なお、これは一例に過ぎず、例えば何cm単位で項目を分けるか、及び、項目を何段階にするか、等は任意に設定することが可能である。   An example of the distance / normalization correspondence table is shown in Table 5 below. Note that this is only an example, and for example, how many centimeters the items are divided and how many levels of the items can be arbitrarily set.

本例では、次の様な結果となる。合計の範囲は0〜127番目のデータとする。
・二値化されたデータを周波数解析した結果の合計値(二値化後振幅和):6.560
・受光強度波形そのものを周波数解析した結果の合計値(二値化前振幅和):4.929
・上記の差の比率(正規化差):1.631/6.560=0.2486
・前記正規化差と表3を比較することで、バーコードラベル106のバーコードスキャナ100に対する距離範囲は6〜10cmと分かる。
In this example, the following results are obtained. The total range is the 0th to 127th data.
-Total value of the result of frequency analysis of binarized data (binarized amplitude sum): 6.560
Total value of results of frequency analysis of received light intensity waveform itself (sum of amplitude before binarization): 4.929
The ratio of the above difference (normalized difference): 1.631 / 6.560 = 0.2486
-By comparing the normalized difference with Table 3, the distance range of the barcode label 106 with respect to the barcode scanner 100 is found to be 6 to 10 cm.

なお、ステップS20にて利用する距離・正規化対応表として、バーコードの種類別にそれぞれ事前測定を行っておき、バーコードの種類別にそれぞれ対応した距離・正規化差対応表を用意するようにしても良い。この場合は、ステップS18でデコードした結果から得られたバーコードの種類の情報を用いて、バーコードの種類に応じた距離・正規化差対応表を参照する。このようにすることによって、バーコードの種別に対応できることから、より高い精度で距離の決定が可能となる。   As the distance / normalization correspondence table used in step S20, advance measurement is performed for each barcode type, and a distance / normalization difference correspondence table corresponding to each barcode type is prepared. Also good. In this case, the distance / normalized difference correspondence table corresponding to the barcode type is referred to using the barcode type information obtained from the result of decoding in step S18. By doing so, the distance can be determined with higher accuracy since the type of the barcode can be handled.

次に、ステップS20における工程で得られた「距離範囲」に対応した距離(例えば、その距離範囲の最大値、その距離範囲の平均値など)が、読み取りを許可すべき「距離」の許容範囲内にあるか否かを判断する(ステップS21)。ここで、ステップS20における工程で得られた「距離範囲」に対応した距離が、読み取りを許可すべき「距離」の許容範囲内であれば(ステップS21においてYes)、ステップS18の工程におけるデコード結果を上位装置に対して出力する(ステップS22)。なお、読み取りを許可すべき「距離」の許容範囲はバーコードスキャナ100の機能や用途に応じて予め定めておく。   Next, the distance corresponding to the “distance range” obtained in the step S20 (for example, the maximum value of the distance range, the average value of the distance range, etc.) is an allowable range of “distance” that should be permitted to be read. It is judged whether it is in (step S21). If the distance corresponding to the “distance range” obtained in the process in step S20 is within the allowable range of “distance” that should be permitted to be read (Yes in step S21), the decoding result in the process in step S18. Is output to the host device (step S22). An allowable range of “distance” that should be permitted to be read is determined in advance according to the function and application of the barcode scanner 100.

他方で、ステップS18でのデコードが成功しなかった場合(ステップS19においてNo)、又は、ステップS21における比較を行い、ステップS20における工程で得られた「距離範囲」に対応した距離が許容範囲外の場合(ステップS21においてNo)は、処理を終了し、結果は出力しない。これにより、許容範囲外に位置するバーコードスキャナ106を誤って読み取ってしまったような場合であっても、この読み取り結果は上位装置に出力されることは無い。そのため、本実施形態では、距離測定用の専用モジュールを組み込む必要が無く、且つ、想定外の距離にあるバーコードの読み取りを防止することが可能となる、という効果を奏する。   On the other hand, if the decoding in step S18 is not successful (No in step S19), or the comparison in step S21 is performed and the distance corresponding to the “distance range” obtained in the process in step S20 is outside the allowable range. In the case of (No in step S21), the process is terminated and the result is not output. As a result, even if the barcode scanner 106 positioned outside the allowable range is erroneously read, the reading result is not output to the host device. Therefore, in this embodiment, there is an effect that it is not necessary to incorporate a dedicated module for distance measurement, and it is possible to prevent reading of a barcode at an unexpected distance.

また、上述した実施形態は、本発明の好適な実施形態ではあるが、上記実施形態のみに本発明の範囲を限定するものではなく、本発明の要旨を逸脱しない範囲において種々の変更を施した形態での実施が可能である。   Moreover, although the above-described embodiment is a preferred embodiment of the present invention, the scope of the present invention is not limited only to the above-described embodiment, and various modifications are made without departing from the gist of the present invention. Implementation in the form is possible.

例えば、本実施形態の処理内容を、バーコードスキャナのデコードプログラムの一部の処理として利用するようにしても良い。   For example, the processing content of the present embodiment may be used as part of the decoding process of the barcode scanner.

他にも、上述した説明ではバーコードスキャナの読み取り対象として1次元のバーコードを例にしていた。もっとも、上述した説明と同様の考え方で、2次元コードを対象として距離を測定するようにしても良い。   In addition, in the above description, a one-dimensional barcode is taken as an example as a reading target of the barcode scanner. However, the distance may be measured for a two-dimensional code based on the same idea as described above.

他にも、上述した本実施形態のプロセッサを、ピントを合わせる機構を更に含むバーコードスキャナと組み合わせ、周波数解析結果の二値化前振幅和が最大となるようにピントを合わせる機構を制御することによって、バーコードスキャナのオートフォーカスを実現するようにしても良い。また、正規化差が許容範囲外の距離に対応する値であれば、正規化差が許容範囲外の距離に対応する値になるまで、オートフォーカスの機構を動作させるようにしてもよい。   In addition, the above-described processor of the present embodiment is combined with a barcode scanner further including a focusing mechanism, and the focusing mechanism is controlled so that the sum of amplitudes before binarization of the frequency analysis result is maximized. Thus, the auto focus of the barcode scanner may be realized. If the normalized difference is a value corresponding to a distance outside the allowable range, the autofocus mechanism may be operated until the normalized difference reaches a value corresponding to the distance outside the allowable range.

他にも、上述した説明においてはイメージセンサで取得した全てのピクセルのセンサ受光強度を利用して周波数解析を行っていたが、一部のピクセルのセンサ受光強度を利用して周波数解析を行うようにしても良い。また、上述した説明においては周波数解析結果の全ての交流周波数の振幅和を比較していたが一部のみの交流周波数の振幅和を比較するようにしても良い。例えば差異の出やすいと考えられる高周波部分のみを比較するようにしても良い。このようにすることにより演算処理の量を減らすことも可能である。なお、このような比較方法を採用するのであれば、同じ方法にて距離・正規化対応表を作成しておけば良い。   In addition, in the above description, the frequency analysis is performed using the sensor light reception intensity of all the pixels acquired by the image sensor. However, the frequency analysis is performed using the sensor light reception intensity of some pixels. Anyway. In the above description, the amplitude sums of all the AC frequencies of the frequency analysis results are compared. However, the amplitude sums of only some AC frequencies may be compared. For example, only high-frequency portions that are considered to be easily different may be compared. By doing so, it is also possible to reduce the amount of arithmetic processing. If such a comparison method is adopted, a distance / normalization correspondence table may be created by the same method.

なお、上記のプロセッサ及びこれを含んだバーコードスキャナは、ハードウェア、ソフトウェア又はこれらの組み合わせにより実現することができる。また、上記のプロセッサ及びこれを含んだバーコードスキャナにより行なわれる距離測定方法も、ハードウェア、ソフトウェア又はこれらの組み合わせにより実現することができる。ここで、ソフトウェアによって実現されるとは、コンピュータがプログラムを読み込んで実行することにより実現されることを意味する。   The above processor and the barcode scanner including the processor can be realized by hardware, software, or a combination thereof. The distance measurement method performed by the above processor and the barcode scanner including the processor can also be realized by hardware, software, or a combination thereof. Here, “realized by software” means realized by a computer reading and executing a program.

プログラムは、様々なタイプの非一時的なコンピュータ可読媒体(non-transitory computer readable medium)を用いて格納され、コンピュータに供給することができる。非一時的なコンピュータ可読媒体は、様々なタイプの実体のある記録媒体(tangible storage medium)を含む。非一時的なコンピュータ可読媒体の例は、磁気記録媒体(例えば、フレキシブルディスク、磁気テープ、ハードディスクドライブ)、光磁気記録媒体(例えば、光磁気ディスク)、CD−ROM(Read Only Memory)、CD−R、CD−R/W、半導体メモリ(例えば、マスクROM、PROM(Programmable ROM)、EPROM(Erasable PROM)、フラッシュROM、RAM(random access memory))を含む。また、プログラムは、様々なタイプの一時的なコンピュータ可読媒体(transitory computer readable medium)によってコンピュータに供給されてもよい。一時的なコンピュータ可読媒体の例は、電気信号、光信号、及び電磁波を含む。一時的なコンピュータ可読媒体は、電線及び光ファイバ等の有線通信路、又は無線通信路を介して、プログラムをコンピュータに供給できる。   The program may be stored using various types of non-transitory computer readable media and supplied to the computer. Non-transitory computer readable media include various types of tangible storage media. Examples of non-transitory computer readable media include magnetic recording media (for example, flexible disks, magnetic tapes, hard disk drives), magneto-optical recording media (for example, magneto-optical disks), CD-ROMs (Read Only Memory), CD- R, CD-R / W, and semiconductor memory (for example, mask ROM, PROM (Programmable ROM), EPROM (Erasable PROM), flash ROM, RAM (random access memory)). The program may also be supplied to the computer by various types of transitory computer readable media. Examples of transitory computer readable media include electrical signals, optical signals, and electromagnetic waves. The temporary computer-readable medium can supply the program to the computer via a wired communication path such as an electric wire and an optical fiber, or a wireless communication path.

上記の実施形態の一部又は全部は、以下の付記のようにも記載されうるが、以下には限られない。   A part or all of the above-described embodiment can be described as in the following supplementary notes, but is not limited thereto.

(付記1) 読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出装置。   (Additional remark 1) The result of the 1st frequency analysis with respect to the image data obtained by reading a reading object image with a reading device, and the image data obtained by reading a reading object image at a predetermined distance apart with the reading device A distance detection device that detects a distance between the reading target and the reading device by performing a predetermined process based on the result of the second frequency analysis for the.

(付記2) 付記1に記載の距離検出装置であって、
読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データは、読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データから得られたものであることを特徴とする距離検出装置。
(Supplementary note 2) The distance detection device according to supplementary note 1, wherein
Image data obtained by reading a reading target image at a predetermined distance by the reading device is obtained from image data obtained by reading the reading target image by the reading device. Distance detection device.

(付記3) 付記2に記載の距離検出装置であって、
読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データは、読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データを二値化することにより得られたものであることを特徴とする距離検出装置。
(Supplementary note 3) The distance detection device according to supplementary note 2,
The image data obtained by reading the reading target image at a predetermined distance by the reading device is obtained by binarizing the image data obtained by reading the reading target image by the reading device. A distance detecting device characterized by being.

(付記4) 付記1乃至3の何れか1に記載の距離検出装置であって、
前記所定の処理とは、前記第1の周波数解析の結果から求まる交流周波数成分の振幅と、前記第2の周波数解析の結果から求まる交流周波数成分の振幅と、に基づく処理であることを特徴とする距離検出装置。
(Supplementary note 4) The distance detection device according to any one of supplementary notes 1 to 3,
The predetermined processing is processing based on the amplitude of the AC frequency component obtained from the result of the first frequency analysis and the amplitude of the AC frequency component obtained from the result of the second frequency analysis. A distance detection device.

(付記5) 付記4に記載の距離検出装置であって、
前記第1の周波数解析の結果から求まる交流周波数成分の振幅と、前記第2の周波数解析の結果から求まる交流周波数成分の振幅と、に基づく処理とは、前記第1の周波数解析の結果から求まる1以上の交流周波数成分の振幅の和と、前記第2の周波数解析の結果から求まる1以上の交流周波数成分の振幅の和との間の差を、前記第2の周波数解析の結果から求まる1以上の交流周波数成分の振幅の前記和で除することにより得られる正規化差と、読み取り対象画像と前記読み取り装置との間の距離との対応関係を用いた処理であることを特徴とする距離検出装置。
(Supplementary note 5) The distance detection device according to supplementary note 4, wherein
The processing based on the amplitude of the AC frequency component obtained from the result of the first frequency analysis and the amplitude of the AC frequency component obtained from the result of the second frequency analysis is obtained from the result of the first frequency analysis. The difference between the sum of the amplitudes of one or more AC frequency components and the sum of the amplitudes of the one or more AC frequency components obtained from the result of the second frequency analysis is obtained from the result of the second frequency analysis. The distance is a process using the correspondence between the normalized difference obtained by dividing by the sum of the amplitudes of the above AC frequency components and the distance between the image to be read and the reading device. Detection device.

(付記6) 前記読み取り対象の種別を判定し、判定結果に応じて異なる内容の前記対応関係を用いることを特徴とする付記5に記載の距離検出装置。   (Additional remark 6) The distance detection apparatus of Additional remark 5 characterized by determining the classification of the said reading object, and using the said corresponding relationship of a different content according to a determination result.

(付記7) 前記画像データを二値化したデータを前記読み取り対象に対応した規則に従いデコードし、前記検出した距離が所定の長さの範囲内である場合に前記デコードの結果を出力するデコード手段を更に備えることを特徴とする付記1乃至6の何れか1に記載の距離検出装置。   (Supplementary Note 7) Decoding means for decoding data obtained by binarizing the image data in accordance with a rule corresponding to the object to be read, and outputting the decoding result when the detected distance is within a predetermined length range The distance detection device according to any one of appendices 1 to 6, further comprising:

(付記8) 付記1乃至7の何れか1に記載の距離検出装置を備える読み取り装置であって、
前記読み取り対象を読み取ることにより前記画像データを取得する手段と、
前記取得した画像データを前記距離検出装置に供給する手段と、
を備えることを特徴とする読み取り装置。
(Supplementary note 8) A reading device including the distance detection device according to any one of supplementary notes 1 to 7,
Means for acquiring the image data by reading the reading object;
Means for supplying the acquired image data to the distance detection device;
A reading apparatus comprising:

(付記9) 読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出方法。   (Additional remark 9) The result of the 1st frequency analysis with respect to the image data obtained by reading a reading object image with a reading apparatus, and the image data obtained by reading a reading object image at a predetermined distance away with the reading apparatus A distance detection method comprising: detecting a distance between the reading target and the reading device by performing a predetermined process based on the result of the second frequency analysis for the above.

(付記10) 読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出装置としてコンピュータを機能させることを特徴とする距離検出プログラム。   (Additional remark 10) The result of the 1st frequency analysis with respect to the image data obtained by reading a reading object image with a reading apparatus, and the image data obtained by reading a reading object image at a predetermined distance with the reading apparatus The computer is caused to function as a distance detecting device that detects a distance between the reading target and the reading device by performing predetermined processing based on the result of the second frequency analysis for A distance detection program characterized by that.

(付記11) 前記読み取り対象を読み取ることにより前記画像データを取得するステップと、
前記取得した画像データを前記距離検出装置に供給するステップと、
読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出するステップと、を有することを特徴とする読み取り方法。
(Appendix 11) Acquiring the image data by reading the reading target;
Supplying the acquired image data to the distance detection device;
The result of the first frequency analysis for the image data obtained by reading the read target image with the reading device and the second for the image data obtained by reading the read target image with a predetermined distance away by the reading device. And a step of detecting a distance between the reading object and the reading device by performing a predetermined process based on the result of the frequency analysis.

本発明は、バーコードスキャナに好適であるが、それ以外にも測定対象から反射する光の受光強度を測定する用途であれば任意の機器に適用することが可能である。   The present invention is suitable for a barcode scanner, but can be applied to any device as long as it is used for measuring the received light intensity of light reflected from a measurement object.

100 バーコードスキャナ
101 プロセッサ
101−1 センサ制御部
101−2 処理部
101−3 記憶部
101−4 データ送受信部
102 イメージセンサ
103 集光レンズ/フィルタ
104 反射ミラー
105 照明光源
106 バーコードラベル
DESCRIPTION OF SYMBOLS 100 Barcode scanner 101 Processor 101-1 Sensor control part 101-2 Processing part 101-3 Storage part 101-4 Data transmission / reception part 102 Image sensor 103 Condensing lens / filter 104 Reflection mirror 105 Illumination light source 106 Barcode label

本発明の第1の観点によれば、読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果から求まる交流周波数成分の振幅と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果から求まる交流周波数成分の振幅と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出装置が提供される。 According to the first aspect of the present invention, the amplitude of the AC frequency component obtained from the result of the first frequency analysis on the image data obtained by reading the reading target image with the reading device, and the reading target image are read. By performing a predetermined process based on the amplitude of the AC frequency component obtained from the result of the second frequency analysis on the image data obtained by reading at a predetermined distance by the apparatus, the reading object and the reading apparatus are A distance detecting device is provided that detects a distance between the two.

本発明の第2の観点によれば、読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果から求まる交流周波数成分の振幅と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果から求まる交流周波数成分の振幅と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出方法が提供される。 According to the second aspect of the present invention, the amplitude of the AC frequency component obtained from the result of the first frequency analysis on the image data obtained by reading the reading target image with the reading device, and the reading target image are read. By performing a predetermined process based on the amplitude of the AC frequency component obtained from the result of the second frequency analysis on the image data obtained by reading at a predetermined distance by the apparatus, the reading object and the reading apparatus are A distance detection method is provided that detects the distance between the two.

本発明の第3の観点によれば、読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果から求まる交流周波数成分の振幅と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果から求まる交流周波数成分の振幅と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出装置としてコンピュータを機能させることを特徴とする距離検出プログラムが提供される。 According to the third aspect of the present invention, the amplitude of the AC frequency component obtained from the result of the first frequency analysis on the image data obtained by reading the read target image with the reading device, and the read target image are read. By performing a predetermined process based on the amplitude of the AC frequency component obtained from the result of the second frequency analysis on the image data obtained by reading at a predetermined distance by the apparatus, the reading object and the reading apparatus are There is provided a distance detection program characterized by causing a computer to function as a distance detection device characterized by detecting a distance between the two.

Claims (10)

読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出装置。   The result of the first frequency analysis for the image data obtained by reading the read target image with the reading device and the second for the image data obtained by reading the read target image with a predetermined distance away by the reading device. A distance detection apparatus that detects a distance between the reading object and the reading apparatus by performing predetermined processing based on a result of frequency analysis. 請求項1に記載の距離検出装置であって、
読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データは、読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データから得られたものであることを特徴とする距離検出装置。
The distance detection device according to claim 1,
Image data obtained by reading a reading target image at a predetermined distance by the reading device is obtained from image data obtained by reading the reading target image by the reading device. Distance detection device.
請求項2に記載の距離検出装置であって、
読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データは、読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データを二値化することにより得られたものであることを特徴とする距離検出装置。
The distance detection device according to claim 2,
The image data obtained by reading the reading target image at a predetermined distance by the reading device is obtained by binarizing the image data obtained by reading the reading target image by the reading device. A distance detecting device characterized by being.
請求項1乃至3の何れか1項に記載の距離検出装置であって、
前記所定の処理とは、前記第1の周波数解析の結果から求まる交流周波数成分の振幅と、前記第2の周波数解析の結果から求まる交流周波数成分の振幅と、に基づく処理であることを特徴とする距離検出装置。
The distance detection device according to any one of claims 1 to 3,
The predetermined processing is processing based on the amplitude of the AC frequency component obtained from the result of the first frequency analysis and the amplitude of the AC frequency component obtained from the result of the second frequency analysis. A distance detection device.
請求項4に記載の距離検出装置であって、
前記第1の周波数解析の結果から求まる交流周波数成分の振幅と、前記第2の周波数解析の結果から求まる交流周波数成分の振幅と、に基づく処理とは、前記第1の周波数解析の結果から求まる1以上の交流周波数成分の振幅の和と、前記第2の周波数解析の結果から求まる1以上の交流周波数成分の振幅の和との間の差を、前記第2の周波数解析の結果から求まる1以上の交流周波数成分の振幅の前記和で除することにより得られる正規化差と、読み取り対象画像と前記読み取り装置との間の距離との対応関係を用いた処理であることを特徴とする距離検出装置。
The distance detection device according to claim 4,
The processing based on the amplitude of the AC frequency component obtained from the result of the first frequency analysis and the amplitude of the AC frequency component obtained from the result of the second frequency analysis is obtained from the result of the first frequency analysis. The difference between the sum of the amplitudes of one or more AC frequency components and the sum of the amplitudes of the one or more AC frequency components obtained from the result of the second frequency analysis is obtained from the result of the second frequency analysis. The distance is a process using the correspondence between the normalized difference obtained by dividing by the sum of the amplitudes of the above AC frequency components and the distance between the image to be read and the reading device. Detection device.
前記読み取り対象の種別を判定し、判定結果に応じて異なる内容の前記対応関係を用いることを特徴とする請求項5に記載の距離検出装置。   The distance detection apparatus according to claim 5, wherein the type of the reading target is determined, and the correspondence relationship having different contents is used according to the determination result. 前記画像データを二値化したデータを前記読み取り対象に対応した規則に従いデコードし、前記検出した距離が所定距離の長さの範囲内である場合に前記デコードの結果を出力するデコード手段を更に備えることを特徴とする請求項1乃至6の何れか1項に記載の距離検出装置。   Decoding means for decoding the binarized data of the image data according to a rule corresponding to the object to be read, and outputting the decoding result when the detected distance is within a predetermined distance length The distance detection apparatus according to claim 1, wherein 請求項1乃至7の何れか1項に記載の距離検出装置を備える読み取り装置であって、
前記読み取り対象を読み取ることにより前記画像データを取得する手段と、
前記取得した画像データを前記距離検出装置に供給する手段と、
を備えることを特徴とする読み取り装置。
A reading device comprising the distance detection device according to any one of claims 1 to 7,
Means for acquiring the image data by reading the reading object;
Means for supplying the acquired image data to the distance detection device;
A reading apparatus comprising:
読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出方法。   The result of the first frequency analysis for the image data obtained by reading the read target image with the reading device and the second for the image data obtained by reading the read target image with a predetermined distance away by the reading device. A distance detection method comprising: detecting a distance between the reading object and a reading device by performing predetermined processing based on a result of frequency analysis. 読み取り対象画像を読み取り装置にて読み取ることにより得られた画像データに対する第1の周波数解析の結果と、読み取り対象画像を前記読み取り装置にて所定距離離れて読み取ることにより得られる画像データに対する第2の周波数解析の結果と、に基づいて、所定の処理を行うことにより、前記読み取り対象と読み取り装置間との間の距離を検出することを特徴とする距離検出装置としてコンピュータを機能させることを特徴とする距離検出プログラム。   The result of the first frequency analysis for the image data obtained by reading the read target image with the reading device and the second for the image data obtained by reading the read target image with a predetermined distance away by the reading device. The computer is caused to function as a distance detecting device that detects a distance between the reading target and the reading device by performing predetermined processing based on a result of the frequency analysis. Distance detection program to do.
JP2013107163A 2013-05-21 2013-05-21 Distance detection device, reader provided with distance detection device, distance detection method, and distance detection program Expired - Fee Related JP5559393B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2013107163A JP5559393B1 (en) 2013-05-21 2013-05-21 Distance detection device, reader provided with distance detection device, distance detection method, and distance detection program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2013107163A JP5559393B1 (en) 2013-05-21 2013-05-21 Distance detection device, reader provided with distance detection device, distance detection method, and distance detection program

Related Child Applications (1)

Application Number Title Priority Date Filing Date
JP2014078572A Division JP5818281B2 (en) 2014-04-07 2014-04-07 Distance detection device, reader provided with distance detection device, distance detection method, and distance detection program

Publications (2)

Publication Number Publication Date
JP5559393B1 JP5559393B1 (en) 2014-07-23
JP2014228345A true JP2014228345A (en) 2014-12-08

Family

ID=51416961

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2013107163A Expired - Fee Related JP5559393B1 (en) 2013-05-21 2013-05-21 Distance detection device, reader provided with distance detection device, distance detection method, and distance detection program

Country Status (1)

Country Link
JP (1) JP5559393B1 (en)

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4578588B2 (en) * 1998-11-09 2010-11-10 ソニー株式会社 Imaging device
US6918538B2 (en) * 2002-12-18 2005-07-19 Symbol Technologies, Inc. Image scanning device having a system for determining distance to a target
JP4829504B2 (en) * 2005-01-19 2011-12-07 Necインフロンティア株式会社 Bar code reader
JP2006220521A (en) * 2005-02-10 2006-08-24 Hitachi Ltd Self-position measuring device and program for performing self-position measurement method
JP2009222449A (en) * 2008-03-14 2009-10-01 Maxis-Shinto Inc Distance measuring device using lens system
JP5430292B2 (en) * 2009-03-26 2014-02-26 京セラ株式会社 Subject distance measuring device

Also Published As

Publication number Publication date
JP5559393B1 (en) 2014-07-23

Similar Documents

Publication Publication Date Title
JP6951056B2 (en) Acceleration-based motion tolerance and predictive coding
US9464885B2 (en) System and method for package dimensioning
US20150144692A1 (en) System and method for indicia reading and verification
JP2020074057A (en) System and method for auto-focusing vision system camera on barcodes
EP2507741B1 (en) Imaging-based scanner including border searching for image acquisition
KR101272448B1 (en) Apparatus and method for detecting region of interest, and the recording media storing the program performing the said method
JPH1063772A (en) Method and device for detecting and decoding symbol having data matrix symbol and readable with machine
JP7177295B1 (en) How to Distinguish Between Focus Drift and Distance-to-Object Change for Variable Focus Lenses
JP2018534664A (en) Compact imaging module with range finder
US20230400295A1 (en) Methods and apparatus for using range data to predict object features
JP5818281B2 (en) Distance detection device, reader provided with distance detection device, distance detection method, and distance detection program
KR102618336B1 (en) Method of detecting and correcting focus drift of variable focus lens for fixed focus applications
JP5559393B1 (en) Distance detection device, reader provided with distance detection device, distance detection method, and distance detection program
KR101488629B1 (en) Method and apparatus for capturing form document with imaging scanner
JP2010231443A (en) Code symbol reader
JP2016126515A (en) Object recognition scanner system
BE1025916B1 (en) METHODS AND DEVICES FOR QUICK DIMENSIONING AN OBJECT
US10303913B2 (en) Virtual wave decoder for blurred images and subpixel performance
JP2019091431A (en) Information reader
JP5896488B2 (en) Bar code reading apparatus, bar code reading method and bar code reading program
US11328139B1 (en) Method for scanning multiple items in a single swipe
US20240054306A1 (en) Apparatuses and computer-implemented methods for geometric image cropping for improved image processing
JP5349504B2 (en) Optical information reading apparatus and optical information reading method

Legal Events

Date Code Title Description
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: 20140512

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20140605

R150 Certificate of patent or registration of utility model

Ref document number: 5559393

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

S533 Written request for registration of change of name

Free format text: JAPANESE INTERMEDIATE CODE: R313533

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

LAPS Cancellation because of no payment of annual fees