JP2005140596A - Detection device - Google Patents

Detection device Download PDF

Info

Publication number
JP2005140596A
JP2005140596A JP2003376176A JP2003376176A JP2005140596A JP 2005140596 A JP2005140596 A JP 2005140596A JP 2003376176 A JP2003376176 A JP 2003376176A JP 2003376176 A JP2003376176 A JP 2003376176A JP 2005140596 A JP2005140596 A JP 2005140596A
Authority
JP
Japan
Prior art keywords
value
detection
maximum value
threshold
unit
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
JP2003376176A
Other languages
Japanese (ja)
Other versions
JP4175240B2 (en
Inventor
Takashi Kobashi
隆 小橋
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.)
Azbil Corp
Original Assignee
Azbil Corp
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 Azbil Corp filed Critical Azbil Corp
Priority to JP2003376176A priority Critical patent/JP4175240B2/en
Publication of JP2005140596A publication Critical patent/JP2005140596A/en
Application granted granted Critical
Publication of JP4175240B2 publication Critical patent/JP4175240B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To provide a detection device, capable of easily setting a threshold value to be a specific detection condition of detection level on a reference value of detection level of detection signal output by a detector under a specific measuring condition, of easily confirming minimum value of peak value in the increasing side of the detection signal or the maximum value of bottom value in reducing side of the detection signal, regardless of the characteristics of the object to be detected, and setting a proper threshold, even when each state level is unstable. <P>SOLUTION: An extreme value detector detects a local maximum value of a detection level exceeding a specific threshold and a local minimum value of a detection level undergoing the threshold. The local maximum value and the local minimum value detected by the extreme value detector are held in a memory. When the update local maximum value detected by the extremum value detector is smaller than the local maximum value, or when the update local minimum value detected by the extremum value detector is smaller than the local minimum value stored in the memory, the information stored in the memory is renewed. <P>COPYRIGHT: (C)2005,JPO&NCIPI

Description

本発明は、検出装置に係り、特に光電センサ、高周波形近接センサ、或いは静電容量形近接センサ等、物体の近接を検出するに好適な検出装置に関する。   The present invention relates to a detection apparatus, and more particularly to a detection apparatus suitable for detecting the proximity of an object, such as a photoelectric sensor, a high-frequency proximity sensor, or a capacitive proximity sensor.

近時、種々の検出装置が適用されている。この検出装置としては、例えば物体の近接を検出する光電センサ、高周波形近接センサや静電容量形近接センサ等、或いは溶液の濁度を検出する濁度センサ等の他、温度、湿度、磁気等の種々の物理量を検出するものがある。例えば光電センサは、投光器と受光器とを備えた検出装置であって、透過形と反射形とに大別することができる。透過形の光電センサは、基本的には投光器(投光部)と受光器(受光部)とを所定の距離を隔てて対峙させた構成をとっている。そして、投光器と受光器との間に形成された光路内に物体が侵入したとき、この物体によって遮られた受光量(検出量)の変化を検出して物体の近接を検出するものである。   Recently, various detection devices have been applied. As this detection device, for example, a photoelectric sensor that detects the proximity of an object, a high-frequency proximity sensor, a capacitive proximity sensor, or a turbidity sensor that detects the turbidity of a solution, temperature, humidity, magnetism, etc. There are those that detect various physical quantities. For example, the photoelectric sensor is a detection device including a projector and a light receiver, and can be roughly classified into a transmission type and a reflection type. The transmission type photoelectric sensor basically has a configuration in which a light projector (light projecting unit) and a light receiver (light receiving unit) are opposed to each other with a predetermined distance. Then, when an object enters the optical path formed between the projector and the light receiver, the proximity of the object is detected by detecting a change in the amount of light received (detected amount) blocked by the object.

一方、反射形の光電センサは、投光器(投光部)と受光器(受光部)とを、その光軸方向を揃えて並べて設けた構成をとり、投光器から発した光が物体によって反射した反射光を受光器にて検出することで物体の検出を行うように構成されている。即ち、反射形の光電センサは、光軸上に物体が存在しないときには物体による反射光がなくなり、また光軸上に物体が存在する場合には、物体までの距離に応じた強度の反射光が受光されることを利用して物体検出を行うものである。   On the other hand, a reflective photoelectric sensor has a configuration in which a light projector (light projecting unit) and a light receiver (light receiving unit) are arranged with their optical axes aligned, and the light emitted from the light projector is reflected by an object. An object is detected by detecting light with a light receiver. In other words, the reflection type photoelectric sensor has no reflected light from the object when there is no object on the optical axis, and when there is an object on the optical axis, the reflected light with the intensity corresponding to the distance to the object is not emitted. Object detection is performed by using the received light.

光電センサは、このように投光器と受光器との間に形成される光路内の光学的状態を、上記受光器による受光量(検出量)の変化として検出する検出装置であって、物体の近接検出や物体判定等の各種の用途に利用されている。具体的に光電センサは、予め定められた設定値(閾値)と受光量とを比較し、設定値と受光量とのレベル差によって投光器と受光器との間の物体の有無を判定して二値出力する光電スイッチとして用いられる。この種の光電スイッチにおいては、物体の有無を判別する閾値の設定が重要である。   The photoelectric sensor is a detection device that detects the optical state in the optical path formed between the light projector and the light receiver in this manner as a change in the amount of light received (detected amount) by the light receiver. It is used for various purposes such as detection and object determination. Specifically, the photoelectric sensor compares a predetermined set value (threshold value) with the amount of received light, and determines the presence or absence of an object between the projector and the light receiver based on a level difference between the set value and the received light amount. It is used as a photoelectric switch that outputs a value. In this type of photoelectric switch, it is important to set a threshold value for determining the presence or absence of an object.

一般には、受光レベルのピーク値とボトム値とをそれぞれ保持し、この保持したピーク値とボトム値との平均値を閾値として設定することがなされている(例えば、特許文献1を参照)。
特開平9−167951号公報
In general, a peak value and a bottom value of the received light level are held, and an average value of the held peak value and bottom value is set as a threshold value (see, for example, Patent Document 1).
JP-A-9-167951

しかしながら上述した検出装置、例えば物体の有無を検出する光電スイッチにあっては、物体の有無を判別する受光レベルの閾値の設定を誤ると物体の検出に誤りを生ずるという問題があった。具体的には図9に示すように光電センサの検出部が出力した検出信号の検出レベルの最大値(ピーク値)と最小値(ボトム値)との平均値を閾値として設定した場合、検出信号のレベルによっては、物体存在しないのに物体があるものとして誤検出したり、逆に物体がないにも係わらず物体があるものとして誤検出されるという懸念があった。   However, in the above-described detection device, for example, a photoelectric switch for detecting the presence or absence of an object, there is a problem that an error occurs in the detection of the object if the threshold value of the light reception level for determining the presence or absence of the object is mistaken. Specifically, as shown in FIG. 9, when the average value of the maximum value (peak value) and the minimum value (bottom value) of the detection level of the detection signal output from the detection unit of the photoelectric sensor is set as the threshold value, the detection signal Depending on the level, there is a concern that the object is erroneously detected as having an object even when the object is not present, or the object is erroneously detected as having an object even though there is no object.

また上述した従来の検出装置において、検出対象物体がコンベア上を移動するように検出対象物を光電スイッチの検出対象領域内に停止させることができないような場合、光電スイッチの表示部からピーク値とボトム値とをそれぞれ得ることはできるものの、そのピーク値を下回るピーク値、或いはボトム値を上回るボトム値に関しては、その値を得ることができず適切な閾値であるかどうかの判定ができないという問題があった。   Further, in the conventional detection device described above, when the detection target cannot be stopped in the detection target area of the photoelectric switch so that the detection target object moves on the conveyor, the peak value is displayed from the display unit of the photoelectric switch. The bottom value can be obtained, but the peak value below the peak value or the bottom value above the bottom value cannot be obtained and it cannot be determined whether the threshold value is appropriate. was there.

そこで一般には、予め複数の何点かの検査対象物による光電スイッチの検出状態の確認を行い、誤検出しないかどうかを検証する必要があり、閾値設定が煩雑になるという問題があった。また検査対象物の形状、表面加工等が変更された場合、その都度光電スイッチの検出状態を確認する必要があり、効率的なセンシングができないという問題もある。
本発明は、このような従来の事情に対処してなされたものであり、その目的は検出装置において適切な閾値を設定することが容易に行うことができ、検出対象物の素性によって変化する検出信号増加側のピーク値の最小値、或いは検出信号減少側のボトム値の最大値を容易に確認することができると共に、ピーク値またはボトム値のそれぞれの検出レベルが不安定な場合であっても適切な閾値設定が可能な検出装置を提供することにある。
In general, therefore, it is necessary to confirm the detection state of the photoelectric switch by using a plurality of inspection objects in advance and verify whether or not it is erroneously detected, and there is a problem that threshold setting becomes complicated. In addition, when the shape of the inspection object, surface processing, or the like is changed, it is necessary to check the detection state of the photoelectric switch each time, and there is a problem that efficient sensing cannot be performed.
The present invention has been made in response to such a conventional situation, and the object thereof is to easily set an appropriate threshold value in a detection apparatus, and to detect changes that vary depending on the characteristics of a detection object. The minimum value of the peak value on the signal increase side or the maximum value of the bottom value on the detection signal decrease side can be easily confirmed, and even if the detection level of each peak value or bottom value is unstable An object of the present invention is to provide a detection device capable of setting an appropriate threshold value.

上述した目的を達成するため、本発明に係る検出装置は、所定の計測条件下における検出器が出力した検出信号の検出レベルを基準値として該検出レベルの所定の検出条件となる閾値を設定する閾値設定手段と、前記検出器による検出レベルを前記閾値と比較して検知信号を出力する比較器とを具備した検出装置であって、
前記閾値を超えた上記検出レベルの極大値および前記閾値を下回る上記検出レベルの極小値をそれぞれ逐次検出する極値検出部と、
この極値検出部が検出した上記極大値および極小値をそれぞれ保持する記憶部と、
この記憶部に保持された極大値より前記極値検出部が検出した極大値が小さいとき、または上記記憶部に保持された極小値より前記極値検出部が検出した極小値が大きいとき、前記記憶部に保持された極大値または極小値をそれぞれ上記極値検出部が検出した極大値または極小値に更新する更新手段と、
前記記憶部に保持された極大値または極小値をそれぞれ表示する表示部と
を備えることを特徴としている。
In order to achieve the above-described object, the detection apparatus according to the present invention sets a threshold value that is a predetermined detection condition for the detection level, using the detection level of the detection signal output by the detector under a predetermined measurement condition as a reference value. A detection apparatus comprising threshold setting means and a comparator that outputs a detection signal by comparing a detection level of the detector with the threshold,
An extreme value detection unit for sequentially detecting the maximum value of the detection level exceeding the threshold and the minimum value of the detection level below the threshold;
A storage unit that holds the maximum value and the minimum value detected by the extreme value detection unit, and
When the maximum value detected by the extreme value detection unit is smaller than the maximum value held in the storage unit, or when the minimum value detected by the extreme value detection unit is larger than the minimum value held in the storage unit, Updating means for updating the maximum value or the minimum value held in the storage unit to the maximum value or the minimum value detected by the extreme value detection unit, respectively;
And a display unit for displaying the maximum value or the minimum value held in the storage unit.

このため閾値を上回った極大値のうち最小の値をとる極大値をピーク値とし、閾値を下回った極小値のうち最大の値をボトム値として表示させることができ、これらの値を用いることにより、検出レベルの基準値となる閾値の設定を適切に設定することが可能となる。つまり、前記表示部が出力する極大値および極小値は、前記検出器の検出信号の検出レベルの基準となる閾値を設定する参考値とすることができる。   For this reason, the maximum value taking the minimum value among the maximum values exceeding the threshold value can be displayed as the peak value, and the maximum value among the minimum values falling below the threshold value can be displayed as the bottom value. By using these values, Thus, it is possible to appropriately set the threshold value serving as the reference value for the detection level. That is, the maximum value and the minimum value output from the display unit can be used as reference values for setting a threshold value that serves as a reference for the detection level of the detection signal of the detector.

好ましくは、前記記憶部は、前記検出レベルの前記極大値および前記極小値の履歴をそれぞれ保持するものとして構成することが望ましい。
このため、記憶部に保持された極大値および極小値の履歴情報から検出レベルの極大値および極小値の傾向や、ばらつきの状態、平均値等の各種統計情報を得ることができる。
具体的に本発明に係る検出装置における前記検出器は、請求項4に記載するように所定の光路を形成する投光器および受光器を備え、上記投光器から発した光またはその反射光を前記受光器にて受光してその検出レベルから上記光路内の光学的条件を検出する光電センサとして構成される。
Preferably, the storage unit is configured to hold a history of the maximum value and the minimum value of the detection level.
For this reason, it is possible to obtain various statistical information such as the tendency of the maximum value and the minimum value of the detection level, the variation state, and the average value from the history information of the maximum value and the minimum value held in the storage unit.
Specifically, the detector in the detection apparatus according to the present invention includes a light projector and a light receiver that form a predetermined optical path as described in claim 4, and the light emitted from the light projector or the reflected light thereof is the light receiver. And a photoelectric sensor for detecting the optical condition in the optical path from the detection level.

このように、本発明に係る検出装置においては、検出器が出力する検出信号のうち所定の閾値を上回る検出信号の検出レベルの極大値および該閾値を下回る上記検出レベルの極小値とをそれぞれ検出して記憶部に保持するとともに、この極大値のうち最小レベルの検出信号および極小値のうち最大レベルの検出信号を履歴として残しつつ、表示することができるので極大値と極小値とのレベル差が少なく、それぞれの状態レベルが不安定な場合であっても極大値および極小値を用いることによって適切な閾値設定を行うことができる。また、上述した極大値および極小値の履歴情報を用いることにより、検出信号の増加側あるいは減少側のいずれの検出信号に、ばらつきが多いかということも判断することができ、閾値として設定すべき検出レベルを適切に判断することが可能となる。また、この閾値と極大値および極小値を履歴情報として保持しているので、例えば製造品の検査工程に本発明に係る検出装置を適用した場合、これら履歴情報を検査情報として活用することが可能となる等実用上多大なる効果を奏する。   As described above, in the detection apparatus according to the present invention, the detection signal maximum value of the detection signal that exceeds the predetermined threshold and the minimum value of the detection level that falls below the threshold value are detected from the detection signals output by the detector. The difference between the maximum value and the minimum value can be displayed while keeping the detection signal of the minimum level of the maximum value and the detection signal of the maximum level of the minimum value as a history. Even when the state levels are unstable, it is possible to set an appropriate threshold by using the maximum value and the minimum value. Further, by using the history information of the maximum value and the minimum value described above, it can be determined whether the detection signal on the increase side or the decrease side of the detection signal has a large variation, and should be set as a threshold value. It is possible to appropriately determine the detection level. In addition, since the threshold value, the maximum value, and the minimum value are held as history information, for example, when the detection apparatus according to the present invention is applied to an inspection process of a manufactured product, the history information can be used as inspection information. It has a great effect on practical use.

以下、本発明に係る検出装置の一実施形態に関し、物体の有無(近接)を検出する光電センサを例示して図面を参照しながら説明する。
図1は本発明の一実施形態に係る検出装置であって、光電センサの概略構成を示すものである。この図において1は、例えば波長660nmのレーザ光を発光する発光ダイオード(LED)からなる投光器、2は上記レーザ光を、直接或いはその反射光を受光するフォトダイオード(PD)からなる受光器である。これらの投光器1および受光器2は、透過形の光電センサを構成するものであってもよく、或いは反射形の光電センサを構成するものであってもよい。尚、ここでは投光器1から所定の物体検出対象領域に対して光を直接投射すると共に、受光器2は、上記物体検出対象領域に存在する検出対象物によって投光器1が発する光の反射光を受光して検出対象物の有無を判定する反射形の光電センサについて説明する。
Hereinafter, an embodiment of a detection device according to the present invention will be described with reference to the drawings, illustrating a photoelectric sensor that detects the presence or absence (proximity) of an object.
FIG. 1 is a detection apparatus according to an embodiment of the present invention, and shows a schematic configuration of a photoelectric sensor. In this figure, 1 is a projector made up of a light emitting diode (LED) that emits laser light with a wavelength of 660 nm, for example, and 2 is a light receiver made up of a photodiode (PD) that receives the laser light directly or its reflected light. . These projector 1 and light receiver 2 may constitute a transmissive photoelectric sensor, or may constitute a reflective photoelectric sensor. Here, light is directly projected from the projector 1 onto a predetermined object detection target area, and the light receiver 2 receives reflected light of the light emitted from the projector 1 by the detection target existing in the object detection target area. A reflective photoelectric sensor that determines the presence or absence of a detection target will be described.

この光電センサに用いられる受光器2は、受光した光の強度(受光量)に応じたレベルの信号を出力するものである。この受光器2を備えた光電センサは、例えば検出対象領域に図示しない搬送機構を用いて検出対象物を横切らせることによって、受光器2の検出レベルRの変化を捉えて検出対象物の有無を判定するようになっている。つまり、図9に示すように検出対象物が検出対象領域に到達すると、該検出対象物によって投光器1から発したレーザ光が反射されて受光器2に到達する光が徐々に増加する。すると受光器2の検出レベルRも徐々に増加する。そして検出対象物が検出対象領域の略中央部に到達すると、その反射光量は最大となり、受光器2の検出レベルRも最大になる。その後、出力レベルRは、検出対象物の移動に伴って、該検出対象物が検出対象領域から離れていくと、この検出対象物による反射光量が減少するので徐々に減少する。このように検出対象物が検出対象領域にある場合は、検出レベルRの変化は最大の値、すなわち極大値をもつことになる。逆に検出対象物が検出対象領域にない場合は、検出レベルRの変化は最小の値、すなわち極小値をもつことになる。   The light receiver 2 used in this photoelectric sensor outputs a signal having a level corresponding to the intensity of received light (amount of received light). The photoelectric sensor provided with the light receiver 2 captures a change in the detection level R of the light receiver 2 by crossing the detection object using a transport mechanism (not shown) in the detection target region, for example, and detects the presence or absence of the detection target. It comes to judge. That is, as shown in FIG. 9, when the detection target reaches the detection target region, the laser light emitted from the projector 1 is reflected by the detection target and the light reaching the light receiver 2 gradually increases. Then, the detection level R of the light receiver 2 gradually increases. When the detection target reaches the substantially central portion of the detection target region, the amount of reflected light is maximized, and the detection level R of the light receiver 2 is also maximized. Thereafter, as the detection target moves away from the detection target region as the detection target moves, the output level R gradually decreases because the amount of light reflected by the detection target decreases. Thus, when the detection target is in the detection target region, the change in the detection level R has the maximum value, that is, the maximum value. Conversely, when the detection target is not in the detection target region, the change in the detection level R has a minimum value, that is, a minimum value.

ところで受光器2から出力された出力信号(検出レベル)は、図示しない周波数選別フィルタ等を含む前置増幅器(ヘッドアンプ)を介して増幅された後、A/D変換器3を介してディジタル変換されてマイクロコンピュータ等の制御部4を含む信号処理回路5に、例えば200μs毎に取り込まれる。この信号処理回路5は、閾値設定部6に設定された閾値SHと、前記A/D変換器3から与えられる前記受光器2による検出レベルRとを比較して、前記検出対象領域における物体の有無を示す判定信号を出力するレベル判定器(比較器)7を備えて構成される。そして、このレベル判定器(比較器)7による判定信号が光電センサの検出信号として外部出力されるようになっている。   By the way, the output signal (detection level) output from the light receiver 2 is amplified through a preamplifier (head amplifier) including a frequency selection filter (not shown) and then converted into a digital signal through an A / D converter 3. Then, it is taken into the signal processing circuit 5 including the control unit 4 such as a microcomputer every 200 μs, for example. The signal processing circuit 5 compares the threshold value SH set in the threshold value setting unit 6 with the detection level R detected by the light receiver 2 provided from the A / D converter 3, and detects the object in the detection target region. A level determination unit (comparator) 7 that outputs a determination signal indicating the presence or absence is provided. A determination signal from the level determination unit (comparator) 7 is externally output as a detection signal of the photoelectric sensor.

ちなみに閾値設定部6に設定される閾値SHには、詳細は後述するが反射形の光電センサの場合、検出対象物が検出対象領域を通過したときに該検出対象物によって反射される光量(反射光量)が所定量(閾値)を上回ったかどうかで物体を検出する検出判定レベルの基準値が設定される。
信号処理回路5には、A/D変換器3が出力する検出レベルRが閾値設定部6に設定された閾値SHを上回ったレベルにあるとき、且つA/D変換器3から出力された検出信号に極大値が含まれているとき、この極大値を保持するピーク値ホールド部8aが設けられている。また信号処理回路5には、A/D変換器3が出力する検出レベルRが閾値設定部6に設定された閾値SHを下回ったレベルにあるとき、且つA/D変換器3から出力された検出信号に極小値が含まれているとき、この極小値を保持するボトム値ホールド部8bが設けられている。これらのホールド部8a,8bは、検出レベルR中の極大値および極小値をそれぞれ検出する極値検出部の役割を担っている。
Incidentally, the threshold value SH set in the threshold value setting unit 6 will be described in detail later, but in the case of a reflective photoelectric sensor, the amount of light reflected by the detection object (reflection) when the detection object passes through the detection object region. A reference value of a detection determination level for detecting an object is set based on whether or not (light quantity) exceeds a predetermined amount (threshold value).
The signal processing circuit 5 detects that the detection level R output from the A / D converter 3 is higher than the threshold value SH set in the threshold setting unit 6 and is output from the A / D converter 3. When the signal includes a maximum value, a peak value holding unit 8a is provided for holding the maximum value. The signal processing circuit 5 outputs the detection level R output from the A / D converter 3 when the detection level R is lower than the threshold value SH set in the threshold value setting unit 6 and from the A / D converter 3. When the minimum value is included in the detection signal, a bottom value holding unit 8b for holding the minimum value is provided. These hold units 8a and 8b serve as extreme value detection units for detecting a maximum value and a minimum value in the detection level R, respectively.

信号処理回路5には、ピーク値ホールド部8aおよびボトム値ホールド部8bがそれぞれ保持した値を保持するピーク値記憶部9aおよびボトム値記憶部9bからなる記憶部9がそれぞれ設けられている。この記憶部9は、詳細は後述するがピーク値ホールド部8aおよびボトム値ホールド部8bがそれぞれ保持した値(極大値および極小値)を保持するようになっている。   The signal processing circuit 5 is provided with a storage unit 9 including a peak value storage unit 9a and a bottom value storage unit 9b that hold the values held by the peak value hold unit 8a and the bottom value hold unit 8b, respectively. Although details will be described later, the storage unit 9 holds values (maximum value and minimum value) held by the peak value holding unit 8a and the bottom value holding unit 8b, respectively.

信号処理回路5には、ピーク値ホールド部8aが保持した極大値とピーク値記憶部9aに保持された極大値のそれぞれの値を比較するピーク値比較部10aおよびボトム値ホールド部8bが保持した極小値とボトム値記憶部9bに保持された極小値のそれぞれの値を比較するボトム値比較部10bとが設けられている。また信号処理回路5には、ピーク値記憶部9aおよびボトム値記憶部9bにそれぞれ保持された極大値および極小値をそれぞれ表示するピーク値表示部11aおよびボトム値表示部11bが設けられている。   The signal processing circuit 5 holds a peak value comparison unit 10a and a bottom value hold unit 8b that compare the maximum value held by the peak value hold unit 8a and the maximum value held by the peak value storage unit 9a. There is provided a bottom value comparison unit 10b for comparing each value of the minimum value and the minimum value held in the bottom value storage unit 9b. Further, the signal processing circuit 5 is provided with a peak value display unit 11a and a bottom value display unit 11b for displaying the maximum value and the minimum value respectively held in the peak value storage unit 9a and the bottom value storage unit 9b.

このように構成された本発明に係る検出装置が特徴とするところは、閾値設定部6に設定した閾値を超えた検出信号に含まれる極大値のうち、最小の検出レベルの極大値を記憶部9に保持する点、閾値設定部に設定した閾値を下回る検出信号に含まれる極小値のうち、最大の検出レベルの極小値を記憶部9に保持する点にある。
つまり、ピーク値ホールド部8aは、検出信号の検出レベルRが閾値設定部6に設定した閾値を上回っているとき、この閾値より高いレベルの検出信号に含まれる極大値を検出する。そして、この極大値をピーク値記憶部9aに保持させる。次いで、ピーク値ホールド部8aは、再び検出信号の検出レベルRが閾値設定部6に設定した閾値を上回った検出信号に含まれる極大値を検出する。このときピーク値比較部10aは、ピーク値ホールド部8aが保持した最新の極大値と、ピーク値記憶部9aに保持されている前回の極大値とをそれぞれ比較する。そして制御部4は、最新の極大値が前回の極大値より下回っているとき、ピーク値記憶部9aに保持されている極大値を最新の極大値に更新する(更新手段)。そして、この更新された極大値(ピーク値)は、ピーク値表示部11aにより表示されるようになっている。
The detection apparatus according to the present invention configured as described above is characterized in that the maximum value of the minimum detection level among the maximum values included in the detection signal exceeding the threshold set in the threshold setting unit 6 is stored in the storage unit. The minimum value of the maximum detection level among the minimum values included in the detection signal below the threshold set in the threshold setting unit is stored in the storage unit 9.
That is, when the detection level R of the detection signal exceeds the threshold set in the threshold setting unit 6, the peak value holding unit 8a detects the maximum value included in the detection signal having a level higher than this threshold. Then, this maximum value is held in the peak value storage unit 9a. Next, the peak value holding unit 8a detects the maximum value included in the detection signal in which the detection level R of the detection signal again exceeds the threshold set in the threshold setting unit 6. At this time, the peak value comparison unit 10a compares the latest maximum value held by the peak value hold unit 8a with the previous maximum value held in the peak value storage unit 9a. Then, when the latest maximum value is lower than the previous maximum value, the control unit 4 updates the maximum value held in the peak value storage unit 9a to the latest maximum value (update means). The updated maximum value (peak value) is displayed by the peak value display unit 11a.

一方、ボトム値ホールド部8bは、検出信号の検出レベルRが閾値設定部6に設定した閾値を下回っているとき、この閾値より低いレベルの検出信号に含まれる極小値を検出する。そして、この極小値をボトム値記憶部9bに保持させる。次いで、ボトム値ホールド部8bは、再び検出信号の検出レベルRが閾値設定部6に設定した閾値を下回った検出信号に含まれる極大値を検出する。このときボトム値比較部10bは、ボトム値ホールド部8bが保持した最新の極小値と、ボトム値記憶部9bに保持されている前回の極小値とをそれぞれ比較する。そして制御部4は、最新の極小値が前回の極小値より上回っているとき、ボトム値記憶部9bに保持されている極小値を最新の極小値に更新する(更新手段)。そして、この更新された極小値(ボトム値)は、ボトム値表示部11bにより表示されるようになっている。   On the other hand, when the detection level R of the detection signal is lower than the threshold set in the threshold setting unit 6, the bottom value holding unit 8b detects a minimum value included in the detection signal having a level lower than the threshold. Then, the minimum value is held in the bottom value storage unit 9b. Next, the bottom value holding unit 8b detects the maximum value included in the detection signal in which the detection level R of the detection signal again falls below the threshold set in the threshold setting unit 6. At this time, the bottom value comparison unit 10b compares the latest minimum value held by the bottom value holding unit 8b with the previous minimum value held by the bottom value storage unit 9b. When the latest minimum value is higher than the previous minimum value, the control unit 4 updates the minimum value held in the bottom value storage unit 9b to the latest minimum value (update means). The updated minimum value (bottom value) is displayed by the bottom value display unit 11b.

このような特徴ある本発明に係る検出装置の一実施形態に関し、物体の有無(近接)を検出する光電センサの作動を示す図2のフローチャートを参照しながら説明する。ちなみに閾値設定部6には、被検出物を有無を検出する検出信号の検出レベルRの閾値として仮の閾値(ピーク値)SHを予め設定してあるものとする。
まず信号処理回路5の制御部4は、カウンタ変数XおよびYをそれぞれ1に、ピーク値記憶部9aに保持するピーク値の変数P(1)に検出信号の検出レベルRの最大値、ボトム値記憶部9bに保持するボトム値の変数B(1)に検出信号の検出レベルRの最小値を設定して変数の初期化を行う[ステップS1]。ちなみにピーク値記憶部9aおよびボトム値記憶部9bは、例えば後述するような配列変数等の構成をとっている。
An embodiment of the detection apparatus according to the present invention having such characteristics will be described with reference to the flowchart of FIG. 2 showing the operation of the photoelectric sensor for detecting the presence (proximity) of an object. Incidentally, it is assumed that a temporary threshold value (peak value) SH is previously set in the threshold value setting unit 6 as a threshold value of the detection level R of the detection signal for detecting the presence or absence of the detection object.
First, the control unit 4 of the signal processing circuit 5 sets the counter variables X and Y to 1, and the peak value variable P (1) held in the peak value storage unit 9a to the maximum value and bottom value of the detection level R of the detection signal. The minimum value of the detection level R of the detection signal is set in the bottom value variable B (1) held in the storage unit 9b to initialize the variable [step S1]. Incidentally, the peak value storage unit 9a and the bottom value storage unit 9b have, for example, configurations such as array variables as described later.

そしてピーク値ホールド部8aおよびボトム値ホールド部8bは、それぞれ検出信号の検出レベルRと閾値設定部6に設定された仮閾値SHとを比較する[ステップS2]。ステップS2で検出信号の検出レベルRが閾値設定部6に設定された仮閾値SHより大きいとき、ピーク値ホールド部8aは、この検出信号に含まれる極大値を検出して変数Pに取り込む[ステップS3]。次いでピーク値比較部10aは、ピーク値ホールド部が取り込んだ極大値Pとピーク値記憶部9aの配列変数P(X)とを比較する[ステップS4]。ピーク値比較部10aは、ステップS4でピーク値ホールド部8aが取り込んだ極大値Pがピーク値記憶部9aの配列変数P(X)より小さいと判定したときは、この取り込んだ極大値Pをピーク値記憶部9aの配列変数P(X)に保持する[ステップS5]。そしてこの記憶された極大値は、ピーク値表示部11aにより表示される[ステップS6]。次いで制御部4は、次の極大値を取り込むべく配列変数のカウンタ変数Xをインクリメントして[ステップS7]、ステップS2に戻る。また、ステップS4でピーク値比較部10aは、ピーク値ホールド部8aが取り込んだ極大値Pがピーク値記憶部9aの配列変数P(X)以上の値であると判定したとき、次の極大値を取り込むべくステップS2に戻る。   Then, the peak value holding unit 8a and the bottom value holding unit 8b respectively compare the detection level R of the detection signal with the temporary threshold value SH set in the threshold value setting unit 6 [Step S2]. When the detection level R of the detection signal is larger than the temporary threshold value SH set in the threshold setting unit 6 in step S2, the peak value holding unit 8a detects the local maximum value included in the detection signal and takes it into the variable P [step S3]. Next, the peak value comparison unit 10a compares the maximum value P captured by the peak value holding unit with the array variable P (X) of the peak value storage unit 9a [step S4]. When the peak value comparison unit 10a determines that the maximum value P captured by the peak value hold unit 8a in step S4 is smaller than the array variable P (X) of the peak value storage unit 9a, the peak value comparison unit 10a peaks the captured maximum value P. The value is stored in the array variable P (X) of the value storage unit 9a [Step S5]. The stored maximum value is displayed by the peak value display unit 11a [step S6]. Next, the control unit 4 increments the counter variable X of the array variable to capture the next maximum value [Step S7], and returns to Step S2. When the peak value comparison unit 10a determines in step S4 that the maximum value P captured by the peak value holding unit 8a is equal to or greater than the array variable P (X) of the peak value storage unit 9a, the next maximum value is obtained. To return to step S2.

一方、ボトム値ホールド部8bは、ステップS2で検出信号の検出レベルRの値が閾値設定部6に設定された仮閾値SHより小さいとき、この検出信号に含まれる極小値を検出して変数Bに取り込む[ステップS8]。次いでボトム値比較部10bは、ボトム値ホールド部8bが取り込んだ極小値Bとボトム値記憶部9bの配列変数B(X)とを比較する[ステップS9]。ボトム値比較部10bは、ステップS9でボトム値ホールド部8bが取り込んだ極小値Bがボトム値記憶部9bの配列変数B(X)より小さいと判定したときは、この取り込んだ極小値Bをボトム値記憶部9bの配列変数B(X)に保持する[ステップS10]。そして、この記憶された極小値は、ボトム値表示部11bにより表示される[ステップS11]。次いで制御部4は、次の極小値を取り込むべく配列変数のカウンタ変数Yをインクリメントして[ステップS12]、ステップS2に戻る。また、ステップS9でボトム値比較部10bは、ボトム値ホールド部8bが取り込んだ極小値Bがボトム値記憶部9bの配列変数B(X)以下の値であると判定したとき、次の極小値を取り込むべくステップS2に戻る。   On the other hand, when the value of the detection level R of the detection signal is smaller than the temporary threshold value SH set in the threshold value setting unit 6 in step S2, the bottom value holding unit 8b detects the minimum value included in the detection signal and sets the variable B [Step S8]. Next, the bottom value comparison unit 10b compares the minimum value B captured by the bottom value holding unit 8b with the array variable B (X) of the bottom value storage unit 9b [Step S9]. When the bottom value comparison unit 10b determines that the minimum value B captured by the bottom value holding unit 8b in step S9 is smaller than the array variable B (X) of the bottom value storage unit 9b, the bottom value comparison unit 10b uses the captured minimum value B as the bottom value. It is stored in the array variable B (X) of the value storage unit 9b [Step S10]. The stored minimum value is displayed by the bottom value display unit 11b [step S11]. Next, the control unit 4 increments the counter variable Y of the array variable to capture the next minimum value [step S12], and returns to step S2. When the bottom value comparison unit 10b determines in step S9 that the minimum value B captured by the bottom value holding unit 8b is equal to or less than the array variable B (X) of the bottom value storage unit 9b, the next minimum value is determined. To return to step S2.

尚、ステップS2で検出信号の検出レベルRと仮閾値SHの値が等しい場合、受光器2によって取り込まれる検出レベルRの変化を待つ[ステップS2]。
このような手順に従って作動する本発明に係る検出装置について、具体例を挙げて説明する。ここでは、理解を容易にするために極大値を検出するアルゴリズムと極小値の検出するアルゴリズムとに分けて説明する。尚、A/D変換器3が出力する検出信号の検出レベルRは、[0〜100]の範囲の値をとるものとして、閾値設定部6には仮閾値SHとして[50]を設定したものとする。したがって、上述したフローチャートのステップS1において配列変数P(1)には検出レベルRが取り得る最大値として[100]が、配列変数B(1)には、検出レベルRが取り得る最小値として[0]がそれぞれ代入されて変数の初期化がなされる。
When the detection level R of the detection signal is equal to the provisional threshold value SH in step S2, a change in the detection level R taken in by the light receiver 2 is waited [step S2].
The detection device according to the present invention that operates according to such a procedure will be described with a specific example. Here, in order to facilitate understanding, the algorithm for detecting the maximum value and the algorithm for detecting the minimum value will be described separately. The detection level R of the detection signal output from the A / D converter 3 assumes a value in the range of [0 to 100], and the threshold setting unit 6 has [50] set as the temporary threshold SH. And Therefore, in step S1 of the flowchart described above, the array variable P (1) has [100] as the maximum value that the detection level R can take, and the array variable B (1) has the minimum value that the detection level R can take [ 0] is assigned to initialize variables.

さて、検出レベルRが、図3に示すように仮閾値SH=[50]を超えて最初の検出レベルRの極大値が[92]になったとする。このときピーク値ホールド部8aは、上述したようにステップS3で変数Pに極大値[92]を取り込む。この極大値P=[92]は、配列変数で初期化されたP(1)=[100]より小さいので、ピーク値ホールド部8aが保持した極大値Pは、ステップS5でピーク値記憶部9aに記憶され、この値がピーク値表示部11aにより表示される。そして制御部4は、ステップS7でカウンタ変数XをインクリメントしてX=[2]にする。   Now, it is assumed that the detection level R exceeds the temporary threshold SH = [50] and the maximum value of the first detection level R becomes [92] as shown in FIG. At this time, the peak value holding unit 8a takes the maximum value [92] into the variable P in step S3 as described above. Since the maximum value P = [92] is smaller than P (1) = [100] initialized by the array variable, the maximum value P held by the peak value holding unit 8a is the peak value storage unit 9a in step S5. And this value is displayed by the peak value display section 11a. In step S7, the control unit 4 increments the counter variable X so that X = [2].

次にピーク値ホールド部8aは、検出信号に含まれる次の極大値を検出する。ちなみに検出信号が、図3に示すような検出レベルRの変化をとった場合、次の極大値Pは、[87]となる。この値は、ピーク値記憶部9aの配列変数P(1)より小さな値である。したがって、この極大値PはステップS5において、ピーク値記憶部9aの配列変数P(2)に保持されると共に、ピーク値表示部11aによって表示される。そして制御部4は、ステップS7でカウンタ変数をインクリメントしてX=[3]にする。   Next, the peak value holding unit 8a detects the next maximum value included in the detection signal. Incidentally, when the detection signal changes in the detection level R as shown in FIG. 3, the next maximum value P is [87]. This value is smaller than the array variable P (1) in the peak value storage unit 9a. Accordingly, the local maximum value P is held in the array variable P (2) of the peak value storage unit 9a and displayed by the peak value display unit 11a in step S5. In step S7, the control unit 4 increments the counter variable to set X = [3].

その後、同様にピーク値ホールド部8aは、検出信号に含まれる次の極大値を検出する。このとき図3に示すように極大値Pが[96]であった場合、前回検出した極大値[87]より大きな値である。このため制御部4は、ステップS4で極大値Pが、ピーク値記憶部9aに保持された前回の極大値より大きいと判断して、次の極大値の検出に備える。そうして、ピーク値ホールド部8aは、検出信号に含まれる次の極大値を検出する。このとき図3に示すように極大値Pが[82]であった場合、前回検出した極大値[87]より小さな値である。したがって、この極大値PはステップS5において、ピーク値記憶部9aの配列変数P(3)に保持されると共に、ピーク値表示部11aによって表示される。そして制御部4は、ステップS7でカウンタ変数Xをインクリメントして、次の極大値の検出を行う。   Thereafter, similarly, the peak value hold unit 8a detects the next maximum value included in the detection signal. At this time, when the maximum value P is [96] as shown in FIG. 3, it is larger than the previously detected maximum value [87]. Therefore, the control unit 4 determines in step S4 that the maximum value P is larger than the previous maximum value held in the peak value storage unit 9a, and prepares for the detection of the next maximum value. Then, the peak value hold unit 8a detects the next maximum value included in the detection signal. At this time, when the maximum value P is [82] as shown in FIG. 3, it is smaller than the previously detected maximum value [87]. Accordingly, the local maximum value P is held in the array variable P (3) of the peak value storage unit 9a in step S5 and displayed by the peak value display unit 11a. In step S7, the control unit 4 increments the counter variable X to detect the next maximum value.

ちなみにこのようにしてピーク値記憶部9aに保持された極大値は、例えば図4に示すようなテーブル形式の配列変数として保持される。
次に本発明に係る検出装置について極小値の検出を行うアルゴリズムについて説明する。
まずA/D変換器3が出力する検出信号の検出レベルRが、図5に示すように仮閾値SH=[50]を下回り最初の極小値が[25]になったとする。このときボトム値ホールド部8bは、上述したようにステップS8で変数Pに極小値[25]を取り込む。この極小値B=[25]は、配列変数で初期化されたB(1)=[0]より大きいので、ステップS10でボトム値記憶部9bに記憶されてボトム値表示部11bにより表示される。そして制御部4は、ステップS12でカウンタ変数YをインクリメントしてY=[2]にする。
Incidentally, the maximum value held in the peak value storage unit 9a in this way is held as an array variable in a table format as shown in FIG. 4, for example.
Next, an algorithm for detecting a minimum value in the detection apparatus according to the present invention will be described.
First, it is assumed that the detection level R of the detection signal output from the A / D converter 3 falls below the temporary threshold SH = [50] as shown in FIG. 5, and the first minimum value becomes [25]. At this time, the bottom value holding unit 8b takes the minimum value [25] into the variable P in step S8 as described above. Since this minimum value B = [25] is larger than B (1) = [0] initialized by the array variable, it is stored in the bottom value storage unit 9b and displayed by the bottom value display unit 11b in step S10. . In step S12, the control unit 4 increments the counter variable Y to Y = [2].

次にボトム値ホールド部8bは、検出信号に含まれる次の極小値を検出する。ちなみに図5に示すような検出レベルRの変化をとった場合、次の極小値Bは、[40]となる。この値は、ボトム値記憶部9bの配列変数B(1)より小さな値である。したがって、この極小値BはステップS10において、ボトム値記憶部9bの配列変数B(2)に保持されると共に、ボトム値表示部11bによって表示される。そして制御部4は、ステップS12でカウンタ変数をインクリメントしてY=[3]にする。   Next, the bottom value holding unit 8b detects the next minimum value included in the detection signal. Incidentally, when the change of the detection level R as shown in FIG. 5 is taken, the next minimum value B is [40]. This value is smaller than the array variable B (1) in the bottom value storage unit 9b. Accordingly, the minimum value B is held in the array variable B (2) of the bottom value storage unit 9b and displayed by the bottom value display unit 11b in step S10. In step S12, the control unit 4 increments the counter variable to Y = [3].

その後、同様にボトム値ホールド部8bは、検出信号に含まれる次の極小値を検出する。このとき図5に示すように極小値Bが[20]であった場合、前回検出した極小値[40]より小さな値である。このため制御部4はステップS9でボトム値ホールド部8bに保持された極小値Bが、ボトム値記憶部9bに保持された前回の極小値より大きいと判断して、次の極小値の検出に備える。そうしてボトム値ホールド部8bは、検出信号に含まれる次の極小値を検出する。このとき図5に示すように極小値Bが[48]であった場合、前回検出した極小値[40]より大きな値である。したがって、この極小値BはステップS10において、ボトム値記憶部9bの配列変数B(3)に保持されると共に、ボトム値表示部11bによって表示される。そして制御部4は、ステップS12でカウンタ変数Yをインクリメントして、次の極小値の検出を行う。   Thereafter, similarly, the bottom value hold unit 8b detects the next minimum value included in the detection signal. At this time, as shown in FIG. 5, when the minimum value B is [20], the value is smaller than the previously detected minimum value [40]. Therefore, the control unit 4 determines that the minimum value B held in the bottom value holding unit 8b in step S9 is larger than the previous minimum value held in the bottom value storage unit 9b, and detects the next minimum value. Prepare. Then, the bottom value holding unit 8b detects the next minimum value included in the detection signal. At this time, when the minimum value B is [48] as shown in FIG. 5, it is a value larger than the previously detected minimum value [40]. Accordingly, the minimum value B is held in the array variable B (3) in the bottom value storage unit 9b and displayed by the bottom value display unit 11b in step S10. In step S12, the control unit 4 increments the counter variable Y to detect the next minimum value.

ちなみにこのようにしてボトム値記憶部9bに保持された極小値は、例えば図6に示すようなテーブル形式の配列変数として保持される。
かくしてこのように構成された本発明に係る検出装置は、ホールド部(極値検出部)8によって閾値設定部6に設定された閾値を超えた検出レベルの極大値および前記閾値を下回る上記検出レベルの極小値とをそれぞれ検出して保持すると共に、これらの極値(極大値および極小値)を記憶部9に保持するようになっている。そして、この記憶部9に保持された極大値より前記極値検出部が検出した極大値が小さいとき、または記憶部9に保持された極小値より前記極値検出部が検出した極小値が大きいとき、制御部4は、前記記憶部に保持された極大値または極小値をそれぞれ上記極値検出部が検出した極大値または極小値に更新する。そしてこの更新された極大値および極小値は、表示部11により表示される。つまり、閾値を上回った極大値のうち最小の値をとる極大値をピーク値とし、閾値を下回った極小値のうち最大の値をボトム値として表示部11に表示させることができ、これらの値を参照して、検出レベルの基準値となる閾値を閾値設定部6に適切に設定することが可能となる。
Incidentally, the minimum value held in the bottom value storage unit 9b in this way is held as an array variable in a table format as shown in FIG. 6, for example.
Thus, the detection apparatus according to the present invention configured as described above includes the maximum value of the detection level that exceeds the threshold value set in the threshold value setting unit 6 by the hold unit (extreme value detection unit) 8 and the detection level that is below the threshold value. Are detected and held, and these extreme values (maximum value and minimum value) are held in the storage unit 9. Then, when the maximum value detected by the extreme value detection unit is smaller than the maximum value held in the storage unit 9, or the minimum value detected by the extreme value detection unit is larger than the minimum value held in the storage unit 9. At this time, the control unit 4 updates the maximum value or the minimum value held in the storage unit to the maximum value or the minimum value detected by the extreme value detection unit, respectively. The updated local maximum value and local minimum value are displayed on the display unit 11. That is, the maximum value taking the minimum value among the maximum values exceeding the threshold value can be displayed on the display unit 11 as the peak value, and the maximum value among the minimum values falling below the threshold value can be displayed as the bottom value on the display unit 11. , It is possible to appropriately set a threshold value serving as a reference value for the detection level in the threshold value setting unit 6.

また記憶部9には、検出信号の検出レベルRの極大値および極小値の情報が履歴として保持されるので、記憶部9に保持されたこれら極大値および極小値の履歴情報から検出レベルRの極大値および極小値の傾向や、ばらつきの状態、平均値等の各種統計情報を算出することができる。
ちなみに上述した表示部11のほか、特に図示しないが検出装置に端末装置(例えばパソコンや可搬形のハンディターミナル)を近接させ、または通信線を接続することによって閾値設定部6の閾値設定を行ったり、記憶部9に保持された極大値および極小値の表示させたりするようにしてもよい。このようにすることにより、記憶部9に保持された極大値および極小値の履歴情報を例えばパソコンに搭載したアプリケーションソフトにより解析し、適切な閾値情報の算出を行わせることで、該検出装置の閾値設定部6に適切な閾値を設定することが容易に行うことができるようになる。
Further, since the maximum value and minimum value information of the detection level R of the detection signal is stored as a history in the storage unit 9, the detection level R of the detection level R is determined from the history information of the maximum value and the minimum value stored in the storage unit 9. Various statistical information such as the tendency of the maximum value and the minimum value, the state of variation, and the average value can be calculated.
Incidentally, in addition to the display unit 11 described above, the threshold setting unit 6 performs threshold setting by bringing a terminal device (for example, a personal computer or a portable handy terminal) close to the detection device or connecting a communication line, although not particularly shown. The maximum value and the minimum value held in the storage unit 9 may be displayed. By doing in this way, the history information of the maximum value and the minimum value held in the storage unit 9 is analyzed by, for example, application software installed in a personal computer, and calculation of appropriate threshold information is performed. It becomes possible to easily set an appropriate threshold value in the threshold setting unit 6.

尚、本発明は上述した実施形態に限定されるものではない。例えば、図7に示すように被検出物の近接にともなう電磁誘導作用によって発振回路に流れる電流が変化することを利用した高周波形(誘導形)近接センサについても適用することが可能である。この高周波形(誘導形)近接センサは、高周波発振回路の一部を構成する検出用コイルLを備えて構成されたものであり、検出用コイルLの近傍に導電性の検出対象物S(例えば金属)が存在または接近すると、電磁誘導作用により該検出用コイルLの内部抵抗成分や自己インダクタンス成分が変化することを利用した検出装置である。この高周波形近接センサの発振回路は、検出用コイルLと並列に接続されたコンデンサCとの間でLC並列共振回路を形成し、発振器12により発振駆動されるようになっている。   The present invention is not limited to the embodiment described above. For example, as shown in FIG. 7, the present invention can also be applied to a high-frequency (inductive) proximity sensor that utilizes the fact that the current flowing in the oscillation circuit changes due to the electromagnetic induction effect accompanying the proximity of the object to be detected. This high frequency (inductive) proximity sensor is configured to include a detection coil L that constitutes a part of a high frequency oscillation circuit, and a conductive detection object S (for example, in the vicinity of the detection coil L). This is a detection device that utilizes the fact that the internal resistance component and the self-inductance component of the detection coil L change due to the electromagnetic induction action when (metal) is present or approaches. The oscillation circuit of the high-frequency proximity sensor forms an LC parallel resonance circuit between the detection coil L and a capacitor C connected in parallel, and is oscillated and driven by an oscillator 12.

また発振器12の出力は、次段の検波回路13の入力信号として相応しいレベルになるよう増幅されて出力される。この検波回路13から出力されたアナログ信号は、A/D変換器3により高周波信号のレベルに相当するディジタル信号(受信レベル)に変換されて信号処理回路5に与えられている。
このように構成された高周波形(誘導形)近接センサは、原理的には検出用コイルLに近接した検出対象物Sの有無を、検出用コイルLの内部抵抗成分の変化、即ち、検出用コイルLのQの変化として捉えている。そして、このQの変化は、発振器12の振幅の変化として検出されるようになっている。
The output of the oscillator 12 is amplified and output to a level suitable as an input signal for the detection circuit 13 at the next stage. The analog signal output from the detection circuit 13 is converted into a digital signal (reception level) corresponding to the level of the high frequency signal by the A / D converter 3 and applied to the signal processing circuit 5.
In principle, the high-frequency (inductive) proximity sensor configured as described above detects the presence or absence of the detection object S close to the detection coil L, changes the internal resistance component of the detection coil L, that is, for detection. This is considered as a change in Q of the coil L. This change in Q is detected as a change in the amplitude of the oscillator 12.

このように構成された高周波形近接センサについても、前述した光電センサと同様に、検出対象物Sが検出用コイルLに近接したとき、高周波発振回路の振幅が変化するので、この振幅値を上述した実施形態の検出レベルRとすれば、検出対象物Sを検出する閾値として適切な閾値を設定することが可能となる。
或いは、本発明に係る検査装置は、図8に示すように被検出物の近接に伴う静電誘導によって静電容量が変化することを利用した静電容量形近接センサに適用することが可能である。この静電容量形近接センサには、物体の近接を検出する検出用コンデンサCと、この検出用コンデンサと共振回路を構成するコイルLとが設けられている。そして、この検出用コンデンサCとコイルLとからなる共振回路を発振駆動する発振器12が設けられている。この発振器12の発振出力は、周波数を電圧に変換するf/V変換器14により周波数に比例した電圧信号が出力されるようになっている。そうしてf/V変換器14によって変換された電圧信号は、A/D変換器3に与えられて、ディジタル信号に変換された後、上述した信号処理回路5に与えられる。
Also in the high-frequency proximity sensor configured as described above, the amplitude of the high-frequency oscillation circuit changes when the detection object S comes close to the detection coil L, similarly to the above-described photoelectric sensor. With the detection level R of the embodiment described above, it is possible to set an appropriate threshold as a threshold for detecting the detection target S.
Alternatively, the inspection apparatus according to the present invention can be applied to a capacitance-type proximity sensor that utilizes the fact that the capacitance changes due to the electrostatic induction accompanying the proximity of an object to be detected as shown in FIG. is there. This capacitive proximity sensor is provided with a detection capacitor C that detects the proximity of an object, and a coil L that constitutes a resonance circuit with the detection capacitor. An oscillator 12 is provided that oscillates and drives a resonance circuit including the detection capacitor C and the coil L. As the oscillation output of the oscillator 12, a voltage signal proportional to the frequency is output by the f / V converter 14 for converting the frequency into a voltage. The voltage signal converted by the f / V converter 14 is applied to the A / D converter 3 and converted to a digital signal, and then applied to the signal processing circuit 5 described above.

このように構成された静電誘導形近接センサは、原理的には検出用コンデンサCの近傍に検出対象物(誘電体)Sを近接させたとき、該検出用コンデンサCの静電容量の変化を、コイルLとコンデンサCとからなるLC共振回路の発振周波数の変化として捉えて、物体の存在を検出するものである。この発振周波数の変化は、f/V変換器14およびA/D変換器3によりディジタル信号(受信レベル)に変換される。そして、このディジタル信号の値、即ちLC発振回路の発振周波数が所定の周波数(閾値)になったときに、検出対象物Sがあるものとして検出することができる。このため閾値の設定に誤り等があった場合であっても、検出信号のレベルの極大値および極小値の履歴情報を参照することで、検出誤差を生じない適切な閾値を設定することが可能となる。   In principle, the electrostatic induction type proximity sensor configured as described above changes the capacitance of the detection capacitor C when the detection object (dielectric) S is brought close to the detection capacitor C. Is detected as a change in the oscillation frequency of the LC resonance circuit composed of the coil L and the capacitor C, and the presence of an object is detected. This change in oscillation frequency is converted into a digital signal (reception level) by the f / V converter 14 and the A / D converter 3. Then, when the value of this digital signal, that is, the oscillation frequency of the LC oscillation circuit reaches a predetermined frequency (threshold), it can be detected that the detection object S is present. For this reason, even if there is an error in setting the threshold value, it is possible to set an appropriate threshold value that does not cause a detection error by referring to the history information of the maximum value and the minimum value of the level of the detection signal. It becomes.

その他、本発明に係る検出装置はその要旨を逸脱しない範囲において各種センサに適用することができる。   In addition, the detection apparatus according to the present invention can be applied to various sensors without departing from the gist thereof.

本発明の一実施形態に係る光電センサの構成を示すブロック図。The block diagram which shows the structure of the photoelectric sensor which concerns on one Embodiment of this invention. 本発明の一実施形態に係る検出装置の極値(極大値および極小値)を検出するアルゴリズムを示すフローチャート。The flowchart which shows the algorithm which detects the extreme value (local maximum value and local minimum value) of the detection apparatus which concerns on one Embodiment of this invention. 図1に示す光電センサの検出器が出力する検出信号の検出レベルの一例を示すグラフ。The graph which shows an example of the detection level of the detection signal which the detector of the photoelectric sensor shown in FIG. 1 outputs. 図2に示す検出信号の検出レベルの極大値を保持する記憶部の変数構造(配列変数)の一例を示す図。The figure which shows an example of the variable structure (array variable) of the memory | storage part which hold | maintains the maximum value of the detection level of the detection signal shown in FIG. 図1に示す光電センサの検出器が出力する検出信号の検出レベルの一例を示す図。The figure which shows an example of the detection level of the detection signal which the detector of the photoelectric sensor shown in FIG. 1 outputs. 図2に示す検出信号の検出レベルの極小値を保持する記憶部の変数構造(配列変数)の一例を示す図。The figure which shows an example of the variable structure (array variable) of the memory | storage part which hold | maintains the minimum value of the detection level of the detection signal shown in FIG. 高周波信号を用いた高周波形近接センサの概略構成を示すブロック図。The block diagram which shows schematic structure of the high frequency type proximity sensor using a high frequency signal. 静電誘導現象を利用した静電容量形近接センサの概略構成を示すブロック図。The block diagram which shows schematic structure of the electrostatic capacitance type proximity sensor using an electrostatic induction phenomenon. 一般的な検出器の検出信号の検出レベルの変化を示すグラフ。The graph which shows the change of the detection level of the detection signal of a general detector.

符号の説明Explanation of symbols

1 投光器
2 受光器
3 A/D変換器
4 制御部
5 信号処理回路
6 閾値設定部
7 比較部
8 ホールド部
8a ピーク値ホールド部
8b ボトム値ホールド部
9 記憶部
9a ピーク値記憶部
9b ボトム値記憶部
10 比較部
10a ピーク値比較部
10b ボトム値比較部
11 表示部
11a ピーク値表示部
11b ボトム値表示部
DESCRIPTION OF SYMBOLS 1 Light projector 2 Light receiver 3 A / D converter 4 Control part 5 Signal processing circuit 6 Threshold setting part 7 Comparison part 8 Hold part 8a Peak value hold part 8b Bottom value hold part 9 Storage part 9a Peak value storage part 9b Bottom value storage Part 10 Comparison part 10a Peak value comparison part 10b Bottom value comparison part 11 Display part 11a Peak value display part 11b Bottom value display part

Claims (4)

所定の計測条件下における検出器が出力した検出信号の検出レベルを基準値として該検出レベルの所定の検出条件となる閾値を設定する閾値設定手段と、前記検出器による検出レベルを前記閾値と比較して検知信号を出力する比較器とを具備した検出装置であって、
前記閾値を超えた上記検出レベルの極大値および前記閾値を下回る上記検出レベルの極小値をそれぞれ逐次検出する極値検出部と、
この極値検出部が検出した上記極大値および極小値をそれぞれ保持する記憶部と、
この記憶部に保持された極大値より前記極値検出部が検出した極大値が小さいとき、または上記記憶部に保持された極小値より前記極値検出部が検出した極小値が大きいとき、前記記憶部に保持された極大値または極小値をそれぞれ上記極値検出部が検出した極大値または極小値に更新する更新手段と、
前記記憶部に保持された極大値または極小値をそれぞれ表示する表示部と
を備えることを特徴とする検出装置。
Threshold value setting means for setting a threshold value that is a predetermined detection condition of the detection level using the detection level of the detection signal output by the detector under a predetermined measurement condition as a reference value, and comparing the detection level by the detector with the threshold value And a detection device comprising a comparator that outputs a detection signal,
An extreme value detection unit for sequentially detecting the maximum value of the detection level exceeding the threshold and the minimum value of the detection level below the threshold;
A storage unit that holds the maximum value and the minimum value detected by the extreme value detection unit, and
When the maximum value detected by the extreme value detection unit is smaller than the maximum value held in the storage unit, or when the minimum value detected by the extreme value detection unit is larger than the minimum value held in the storage unit, Updating means for updating the maximum value or the minimum value held in the storage unit to the maximum value or the minimum value detected by the extreme value detection unit, respectively;
A detection apparatus comprising: a display unit that displays a maximum value or a minimum value held in the storage unit.
前記表示部が出力する極大値および極小値は、前記検出器の検出信号の検出レベルの基準となる閾値を設定する参考値となるものである請求項1に記載の検出装置。   The detection apparatus according to claim 1, wherein the maximum value and the minimum value output by the display unit serve as reference values for setting a threshold value serving as a reference for a detection level of a detection signal of the detector. 前記記憶部は、前記検出レベルの前記極大値および前記極小値の履歴をそれぞれ保持するものである請求項1に記載の検出装置。   The detection device according to claim 1, wherein the storage unit holds a history of the maximum value and the minimum value of the detection level. 前記検出器は、所定の光路を形成する投光器および受光器を備え、上記投光器から発した光またはその反射光を前記受光器にて受光してその検出レベルから上記光路内の光学的条件を検出する光電センサである請求項1に記載の検出装置。   The detector includes a light projector and a light receiver that form a predetermined optical path. The light emitted from the light projector or reflected light thereof is received by the light receiver and the optical condition in the optical path is detected from the detection level. The detection device according to claim 1, wherein the detection device is a photoelectric sensor.
JP2003376176A 2003-11-05 2003-11-05 Detection device Expired - Fee Related JP4175240B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2003376176A JP4175240B2 (en) 2003-11-05 2003-11-05 Detection device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2003376176A JP4175240B2 (en) 2003-11-05 2003-11-05 Detection device

Publications (2)

Publication Number Publication Date
JP2005140596A true JP2005140596A (en) 2005-06-02
JP4175240B2 JP4175240B2 (en) 2008-11-05

Family

ID=34687326

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2003376176A Expired - Fee Related JP4175240B2 (en) 2003-11-05 2003-11-05 Detection device

Country Status (1)

Country Link
JP (1) JP4175240B2 (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2013080577A1 (en) * 2011-11-30 2013-06-06 オムロン株式会社 Photoelectric sensor and method for assisting task of checking state of light reception by photoelectric sensor
JP2014086837A (en) * 2012-10-23 2014-05-12 Omron Corp Photoelectric sensor
DE102014113918A1 (en) * 2013-10-08 2015-04-09 Htc Corporation Electronic device with proximity sensor and automatic calibration method for it
TWI563427B (en) * 2013-10-08 2016-12-21 Htc Corp Automatic calibration method and electronic apparatus
JP2017073723A (en) * 2015-10-09 2017-04-13 株式会社キーエンス Photoelectric switch
CN107636885A (en) * 2015-06-16 2018-01-26 株式会社理光 Storage device, control device and movable body
JP7406246B2 (en) 2020-04-10 2023-12-27 東京パーツ工業株式会社 capacitive proximity sensor

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013113795A (en) * 2011-11-30 2013-06-10 Omron Corp Photoelectronic sensor and method for supporting work for confirming light receiving state of photoelectric sensor
WO2013080577A1 (en) * 2011-11-30 2013-06-06 オムロン株式会社 Photoelectric sensor and method for assisting task of checking state of light reception by photoelectric sensor
JP2014086837A (en) * 2012-10-23 2014-05-12 Omron Corp Photoelectric sensor
US9689810B2 (en) 2013-10-08 2017-06-27 Htc Corporation Electronic apparatus with proximity sensor and automatic calibration method thereof
DE102014113918A1 (en) * 2013-10-08 2015-04-09 Htc Corporation Electronic device with proximity sensor and automatic calibration method for it
DE102014113918B4 (en) * 2013-10-08 2015-08-20 Htc Corporation Electronic device with proximity sensor and automatic calibration method for it
TWI563427B (en) * 2013-10-08 2016-12-21 Htc Corp Automatic calibration method and electronic apparatus
EP3311444A4 (en) * 2015-06-16 2018-06-06 Ricoh Company, Ltd. Storage apparatus, control apparatus, and moving body
CN107636885A (en) * 2015-06-16 2018-01-26 株式会社理光 Storage device, control device and movable body
CN107636885B (en) * 2015-06-16 2020-05-19 株式会社理光 Storage device, control device, and moving body
US11007896B2 (en) 2015-06-16 2021-05-18 Ricoh Company, Ltd. Storage apparatus, control apparatus, and moving body
JP2017073723A (en) * 2015-10-09 2017-04-13 株式会社キーエンス Photoelectric switch
JP7406246B2 (en) 2020-04-10 2023-12-27 東京パーツ工業株式会社 capacitive proximity sensor

Also Published As

Publication number Publication date
JP4175240B2 (en) 2008-11-05

Similar Documents

Publication Publication Date Title
US10018502B2 (en) Laser scanner
JP4129768B2 (en) Detection device
US7902818B2 (en) Inductive proximity detector with switched windings
US5187361A (en) Object detection apparatus of the photoelectric reflection type with sampled data
JP4909036B2 (en) Optical displacement sensor
US20110181892A1 (en) Automatic calibration technique for time of flight (tof) transceivers
US20120119091A1 (en) Infrared sensor module
EP1096238B1 (en) Capacitance type detector
CN100381967C (en) Circuitry for signal measurement
US20240039341A1 (en) Wireless power systems with foreign object detection
JP4175240B2 (en) Detection device
CN109725323B (en) Displacement sensor
JP2020511637A (en) How to determine the operating conditions of a laser-based particle detector
US20100019768A1 (en) Apparatus and method for metal detecting
JP6990356B2 (en) Sensor device and detection method
JP5046296B2 (en) Displacement sensor
JPH07306080A (en) Electric capacity type detector
US11592555B2 (en) Setting value adjustment device for displacement meter
JPH11112319A (en) Detection device and its threshold setting method
JPH0571957A (en) Active range finder
US9274214B2 (en) Apparatus for controlling driving of lighting-emitting diode and method of providing control signal thereof
Balaban et al. OPTOELECTRONIC SYSTEM FOR RELIABLE DETECTION OF DOCUMENT PRESENCE
JP2007139495A (en) Photoelectric sensor
KR101031994B1 (en) Apparatus and method for sensing touch from multiple key
JPH1117513A (en) Sensor switch

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20051226

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20070426

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20080618

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080711

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: 20080806

RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7426

Effective date: 20080811

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20080811

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110829

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Ref document number: 4175240

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120829

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130829

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130829

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140829

Year of fee payment: 6

LAPS Cancellation because of no payment of annual fees