JPH0380379B2 - - Google Patents

Info

Publication number
JPH0380379B2
JPH0380379B2 JP59218924A JP21892484A JPH0380379B2 JP H0380379 B2 JPH0380379 B2 JP H0380379B2 JP 59218924 A JP59218924 A JP 59218924A JP 21892484 A JP21892484 A JP 21892484A JP H0380379 B2 JPH0380379 B2 JP H0380379B2
Authority
JP
Japan
Prior art keywords
output
voltage
avalanche photodiode
optical
amplifier
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.)
Expired - Lifetime
Application number
JP59218924A
Other languages
Japanese (ja)
Other versions
JPS6198032A (en
Inventor
Kazuo Yamane
Masakazu Mori
Takashi Tsuda
Yoshinori Oosumi
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.)
Fujitsu Ltd
Original Assignee
Fujitsu 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 Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP59218924A priority Critical patent/JPS6198032A/en
Publication of JPS6198032A publication Critical patent/JPS6198032A/en
Publication of JPH0380379B2 publication Critical patent/JPH0380379B2/ja
Granted legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B10/00Transmission systems employing electromagnetic waves other than radio-waves, e.g. infrared, visible or ultraviolet light, or employing corpuscular radiation, e.g. quantum communication
    • H04B10/60Receivers
    • H04B10/66Non-coherent receivers, e.g. using direct detection
    • H04B10/69Electrical arrangements in the receiver
    • H04B10/691Arrangements for optimizing the photodetector in the receiver
    • H04B10/6911Photodiode bias control, e.g. for compensating temperature variations

Landscapes

  • Physics & Mathematics (AREA)
  • Electromagnetism (AREA)
  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Monitoring And Testing Of Transmission In General (AREA)
  • Optical Communication System (AREA)

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は光通信装置に係り、特に光受信レベル
モニタ回路に関するものである。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to an optical communication device, and particularly to an optical reception level monitor circuit.

光通信の受信装置に於いては送信側から送られ
て来る光信号レベルを常時監視する回路が使用さ
れている。此の様な回路は光受信レベルモニタ回
路と云われている。
A receiving device for optical communication uses a circuit that constantly monitors the level of an optical signal sent from the transmitting side. A circuit like this is called an optical reception level monitor circuit.

〔従来の技術〕[Conventional technology]

光受信レベルモニタ回路には従来から種々の方
法があり、例えばアバランシエフオトダイオード
(以下APDと云う)のバイアス電圧、電気増幅器
のAGC電圧の両者を合成して広いモニタ範囲を
実現している。
Conventionally, there are various methods for optical reception level monitoring circuits. For example, a wide monitoring range is realized by combining both the bias voltage of an avalanche photodiode (hereinafter referred to as APD) and the AGC voltage of an electric amplifier.

第3図は従来の光受信回路と光受信レベルモニ
タ回路の一例を示す図である。
FIG. 3 is a diagram showing an example of a conventional optical receiving circuit and an optical receiving level monitor circuit.

図中、1はAPD、2,4は夫々抵抗、3はコ
ンデンサ、5は前置増幅器、6はAGC増幅器、
7はP−P検出器、8は比較器、9は直流源、1
0は比較器、11,12は共にダイオード、13
加算器である。尚以下全図を通じ同一記号は同一
対象物を表す。
In the figure, 1 is an APD, 2 and 4 are resistors, 3 is a capacitor, 5 is a preamplifier, 6 is an AGC amplifier,
7 is a P-P detector, 8 is a comparator, 9 is a DC source, 1
0 is a comparator, 11 and 12 are both diodes, 13
It is an adder. The same symbols represent the same objects throughout all the figures below.

光受信はAPD1に入り、電気信号に変換され
てパルス成分が前置増幅器5で増幅される。更に
AGC増幅器6により増幅されて出力端子OUTに
出力される。
The optical reception enters the APD 1, is converted into an electrical signal, and the pulse component is amplified by the preamplifier 5. Furthermore
The signal is amplified by the AGC amplifier 6 and output to the output terminal OUT.

又出力の一部はP−P検出器7に入力され、P
−P検出器7は出力パルス信号のピーク〜ピーク
間の電圧を検出するもので、ピーク〜ピーク間の
電圧に比例する直流電圧V0を出力する。
Also, a part of the output is input to the P-P detector 7, and P
-P detector 7 detects the peak-to-peak voltage of the output pulse signal, and outputs a DC voltage V 0 proportional to the peak-to-peak voltage.

比較器8は直流電圧V0と基準電圧Vref2を比較
し、若し直流電圧V0の方が大きい時は比較器8
の出力は負極性の電圧となる様に設定され、従つ
てダイオード12はオフ状態となる。
Comparator 8 compares DC voltage V 0 and reference voltage Vref 2 , and if DC voltage V 0 is larger, comparator 8
The output of the diode 12 is set to be a negative voltage, and therefore the diode 12 is turned off.

此の負極性の電圧が大きい時はAGC増幅器6
の利得を下げ、小さい時には利得を上げてAGC
増幅器6の出力レベルを一定に保つ。
When this negative polarity voltage is large, AGC amplifier 6
AGC lowers the gain and increases the gain when it is small.
The output level of amplifier 6 is kept constant.

一方直流電圧源9は一種のDC/DC変換器であ
り、此の直流電圧源9から抵抗2を会してAPD
1に直流電圧が供給されている。
On the other hand, the DC voltage source 9 is a kind of DC/DC converter, and the APD is connected by connecting the resistor 2 from this DC voltage source 9.
1 is supplied with DC voltage.

点Aの電圧(供給電圧)をVAPD1とし、点Bの
電圧(バイアス電圧)をVAPD2とする。
Let the voltage at point A (supply voltage) be V APD1 , and the voltage at point B (bias voltage) be V APD2 .

直流電圧源9の入力にはダイオード11,12
がセレクタとして接続され、ダイオード11には
比較器10の出力が、ダイオード12には比較器
8の出力が夫々接続される。
Diodes 11 and 12 are connected to the input of the DC voltage source 9.
is connected as a selector, the output of the comparator 10 is connected to the diode 11, and the output of the comparator 8 is connected to the diode 12, respectively.

前述した様に、P−P検出器7出力の直流電圧
V0が基準電圧Vref2より大きい時(光入力信号が
大きい時)は比較器8の出力は負極性の電圧とな
り、従つてダイオード12はオフ状態となり、直
流電圧源9の入力側から切り離され、比較器10
出力がダイオード11を介して直流電圧源9の入
力側に接続されて一定の出力電圧を点Aに供給す
る。
As mentioned above, the DC voltage of the P-P detector 7 output
When V 0 is larger than the reference voltage Vref 2 (when the optical input signal is large), the output of the comparator 8 becomes a negative polarity voltage, so the diode 12 is turned off and disconnected from the input side of the DC voltage source 9. , comparator 10
The output is connected to the input side of a DC voltage source 9 via a diode 11 to supply a constant output voltage to point A.

光入力信号のレベルが低くなるとP−P検出器
7出力の直流電圧V0が基準電圧Vref2より小さく
なり、比較器8の出力は正極性の電圧となり、ダ
イオード12はオン状態となる。
When the level of the optical input signal becomes low, the DC voltage V0 output from the P-P detector 7 becomes smaller than the reference voltage Vref2 , the output of the comparator 8 becomes a positive voltage, and the diode 12 is turned on.

従つて直流電圧源9の入力側に接続され、逆に
ダイオード11はオフ状態となる。
Therefore, it is connected to the input side of the DC voltage source 9, and conversely, the diode 11 is turned off.

此の状態では光入力信号が小さくなるに従い、
比較器8の出力の正極性の電圧は大きくなり、直
流電圧源9の供給電圧は大きくなり、APD1の
増倍率を大きくする。
In this state, as the optical input signal becomes smaller,
The positive polarity voltage output from the comparator 8 increases, the supply voltage of the DC voltage source 9 increases, and the multiplication factor of the APD 1 increases.

此の様に光受信レベルモニタ回路に於ける
AGC回路部は一般的に光入力レベルが小さい領
域ではAPDの増倍率を上げ、光入力レベルが大
きい領域ではAPDの増倍率を下げると波形の劣
化を生ずるためAPDの増倍率を或る一定レベル
で固定し、電気増幅部の増幅度を制御することに
より達成している。
In this way, in the optical reception level monitor circuit
Generally, the AGC circuit section increases the APD multiplication factor in areas where the optical input level is low, and reduces the APD multiplication factor in areas where the optical input level is high, causing waveform deterioration, so the APD multiplication factor is set to a certain level. This is achieved by controlling the amplification degree of the electrical amplification section.

第4図は光入力によりAPDのバイアス電圧と
直流電流が如何に変化するかを示す図である。
FIG. 4 is a diagram showing how the bias voltage and DC current of the APD change depending on the optical input.

横軸は光入力で、縦軸はAPD1のバイアス電
圧VAPD2と直流電流IAPDである。図示する様に光入
力が小さい時は直流電流IAPDは一定値をとるが、
大きくなると直線的に増加する。一方バイアス電
圧VAPD2は光入力が大きい時は一定であるが、小
さくなると増加する。
The horizontal axis is the optical input, and the vertical axis is the bias voltage V APD2 and DC current I APD of the APD1. As shown in the figure, when the optical input is small, the DC current I APD takes a constant value, but
As it gets bigger, it increases linearly. On the other hand, the bias voltage V APD2 is constant when the optical input is large, but increases as the optical input becomes small.

従つて図示する様に加算器13を接続して
APDのバイアス電圧VAPD2と電気的AGD電圧の和
を取る時、加算器13の出力電圧Vmは光入力に
対し第5図に示す様に変化する。此の出力電圧
Vmを監視することにより光受信レベルをモニタ
することが出来る。
Therefore, connect the adder 13 as shown in the figure.
When the APD bias voltage V APD2 and the electrical AGD voltage are summed, the output voltage Vm of the adder 13 changes as shown in FIG. 5 with respect to the optical input. This output voltage
The optical reception level can be monitored by monitoring Vm.

此の様に従来方式はAPDのバイアス電圧と電
気的AGC電圧の両者を合成して広いモニタ範囲
を実現していたが、制御ルーブが複雑で配線が長
くなり発振防止、漏話防止上好ましくないと云う
欠点があつた。
In this way, the conventional method achieved a wide monitoring range by combining both the APD bias voltage and the electrical AGC voltage, but the control loop was complicated and the wiring was long, which was undesirable in terms of preventing oscillation and crosstalk. There was a drawback.

〔発明が解決しようとする問題点〕[Problem that the invention seeks to solve]

本発明は此の様な欠点のないLSI化に好適な光
受信レベルモニタ回路を提供することである。
The object of the present invention is to provide an optical reception level monitor circuit suitable for LSI implementation without such drawbacks.

〔問題点を解決するための手段〕[Means for solving problems]

問題点を解決するための手段は、入力光信号を
電気信号に変換するアバランシエフオトダイオー
ド1と、アバランシエフオトダイオード1の出力
信号を増幅する可変利得増幅器6と、可変利得増
幅器6の出力信号を検出するピーク検出器7とを
有し、アバランシエフオトダイオード1の一端の
バイアス電圧とピーク検出器7の出力により、ア
バランシエフオトダイオード1の増倍率と可変利
得増幅器6の増幅度を制御して、可変利得増幅器
6の出力振幅を一定にする光受信回路において、
アバランシエフオトダイオード1の一端のバイア
ス電圧を入力して符号を反転して出力する反転増
幅器21と、アバランシエフオトダイオード1の
一端に接続した抵抗器2の両端の電圧を入力し
て、アバランシエフオトダイオード1に流れる電
流に比例する電圧を出力する差動増幅器20と、
反転増幅器21の出力と差動増幅器20の出力と
を入力して両者の加算を行う加算器22とを設
け、加算器22の出力によりアバランシエフオト
ダイオード1に入力する光信号レベルを監視する
ようにした構成により達成される。
Means for solving the problem includes an avalanche photodiode 1 that converts an input optical signal into an electrical signal, a variable gain amplifier 6 that amplifies the output signal of the avalanche photodiode 1, and an output signal of the variable gain amplifier 6. The avalanche photodiode 1 has a bias voltage at one end and the output of the peak detector 7 to control the multiplication factor of the avalanche photodiode 1 and the amplification degree of the variable gain amplifier 6. In the optical receiving circuit that keeps the output amplitude of the variable gain amplifier 6 constant,
An inverting amplifier 21 inputs the bias voltage at one end of the avalanche photodiode 1, inverts the sign, and outputs it, and inputs the voltage across the resistor 2 connected to one end of the avalanche photodiode 1 to generate an avalanche photodiode. a differential amplifier 20 that outputs a voltage proportional to the current flowing through the photodiode 1;
An adder 22 is provided which inputs the output of the inverting amplifier 21 and the output of the differential amplifier 20 and adds the two, and the level of the optical signal input to the avalanche photodiode 1 is monitored by the output of the adder 22. This is achieved by the following configuration.

〔作用〕[Effect]

本発明に依る光受信レベルモニタ回路はアバラ
ンシエフオトダイオードのバイアス電圧と該アバ
ランシエフオトダイオードに流れる直流電流に比
例する電圧を監視する直流回路であり、配線長も
従来に比し短く、発振防止、漏話防止上簡便であ
ると云う効果が生ずる。
The optical reception level monitor circuit according to the present invention is a DC circuit that monitors the bias voltage of an avalanche photodiode and the voltage proportional to the DC current flowing through the avalanche photodiode, and the wiring length is shorter than conventional ones, preventing oscillation. This has the effect of being simple in preventing crosstalk.

〔実施例〕〔Example〕

第1図は本発明に依る光受信レベルモニタ回路
の一実施例を示す図である。
FIG. 1 is a diagram showing an embodiment of an optical reception level monitor circuit according to the present invention.

第2図は第1図の光受信レベルモニタ回路の動
作の説明図である。
FIG. 2 is an explanatory diagram of the operation of the optical reception level monitor circuit of FIG. 1.

図中、20は差動増幅器、21は反転増幅器、
22は加算器である。
In the figure, 20 is a differential amplifier, 21 is an inverting amplifier,
22 is an adder.

以下図に従つて本発明の詳細を説明する。 The details of the present invention will be explained below with reference to the drawings.

本発明では点Aに作動増幅器20の+入力端子
を接続し、点Bに差動増幅器20の−入力端子及
び反転増幅器21を接続し、差動増幅器20と反
転増幅器21の出力の和を加算器22で取り、此
の出力電圧をVm′とする。
In the present invention, the + input terminal of the operational amplifier 20 is connected to point A, the - input terminal of the differential amplifier 20 and the inverting amplifier 21 are connected to the point B, and the sum of the outputs of the differential amplifier 20 and the inverting amplifier 21 is added. This output voltage is taken as Vm'.

第4図で説明した様に光入力が小さい時は直流
電流IAPDは一定値をとるが、或る値αを越して大
きくなると増加する。
As explained in FIG. 4, when the optical input is small, the DC current I APD takes a constant value, but when it increases beyond a certain value α, it increases.

一方バイアス電圧VAPD2は光入力が大きい時は
一定であるが、或る値αを越して小さくなると増
加する。
On the other hand, the bias voltage V APD2 is constant when the optical input is large, but increases when it decreases beyond a certain value α.

従つてバイアス電圧VAPD2を反転増幅器21に
入力して極性を反転増幅し、差動増幅器20で供
給電圧VAPD1とバイアス電圧VAPD2の差を取り、加
算器22で両増幅器の出力電圧の和Vm′をとる時
は、第2図に示す様に光入力に対し電圧Vm′が直
線的に変化する。
Therefore, the bias voltage V APD2 is input to the inverting amplifier 21 to invert and amplify the polarity, the differential amplifier 20 calculates the difference between the supply voltage V APD1 and the bias voltage V APD2 , and the adder 22 sums the output voltages of both amplifiers. When taking Vm', the voltage Vm' changes linearly with respect to the optical input as shown in FIG.

従つて出力電圧Vm′を監視することにより広い
ダイナミツクレンジを持つ光受信レベルモニタが
得られる。
Therefore, by monitoring the output voltage Vm', an optical reception level monitor with a wide dynamic range can be obtained.

〔発明の効果〕〔Effect of the invention〕

以上詳細に説明した様に本発明によれば、入力
側から直流電圧を取るので配線が簡略化され、配
線長も大幅に縮小され、発振防止、漏話防止上好
ましく、LSI化に好適な光受信レベルモニタ回路
が実現出来ると云う大きい効果がある。
As explained in detail above, according to the present invention, since the DC voltage is taken from the input side, the wiring is simplified and the wiring length is significantly reduced, which is advantageous for preventing oscillation and crosstalk, and is suitable for optical reception for LSI. This has the great effect of realizing a level monitor circuit.

【図面の簡単な説明】[Brief explanation of drawings]

第1図は本発明に依る光受信レベルモニタ回路
の一実施例を示す図である。第2図は第1図の光
受信レベルモニタ回路の動作の説明図である。第
3図は従来の光受信回路と光受信レベルモニタ回
路の一例を示す図である。第4図は光入力により
APDのバイアス電圧と直流電流が如何に変化す
るかを示す図である。第5図は従来の光入力に対
するモニタ出力電圧Vmとの関係図である。 図中、1はAPD、2,4は夫々抵抗、3はコ
ンデンサ、5は前置増幅器、6はAGC増幅器、
7はP−P検出器、8は比較器、9は直流源、1
0は比較器、11,12は共にダイオード、13
加算器、20は作動増幅器、21は反転増幅器、
22は加算器である。
FIG. 1 is a diagram showing an embodiment of an optical reception level monitor circuit according to the present invention. FIG. 2 is an explanatory diagram of the operation of the optical reception level monitor circuit of FIG. 1. FIG. 3 is a diagram showing an example of a conventional optical receiving circuit and an optical receiving level monitor circuit. Figure 4 shows the optical input.
FIG. 3 is a diagram showing how the bias voltage and direct current of the APD change. FIG. 5 is a diagram showing the relationship between the monitor output voltage Vm and the conventional optical input. In the figure, 1 is an APD, 2 and 4 are resistors, 3 is a capacitor, 5 is a preamplifier, 6 is an AGC amplifier,
7 is a P-P detector, 8 is a comparator, 9 is a DC source, 1
0 is a comparator, 11 and 12 are both diodes, 13
an adder, 20 a differential amplifier, 21 an inverting amplifier,
22 is an adder.

Claims (1)

【特許請求の範囲】 1 入力光信号を電気信号に変換するアバランシ
エフオトダイオード1と、該アバランシエフオト
ダイオード1の出力信号を増幅する可変利得増幅
器6と、該可変利得増幅器6の出力信号を検出す
るピーク検出器7とを有し、該アバランシエフオ
トダイオード1の一端のバイアス電圧と該ピーク
検出器7の出力により、該アバランシエフオトダ
イオード1の増倍率と該可変利得増幅器6の増幅
度を制御して、該可変利得増幅器6の出力振幅を
一定にする光受信回路において、 該アバランシエフオトダイオード1の一端のバ
イアス電圧を入力して符号を反転して出力する反
転増幅器21と、 該アバランシエフオトダイオード1の一端に接
続した抵抗器2の両端の電圧を入力して、該アバ
ランシエフオトダイオード1に流れる電流に比例
する電圧を出力する作動増幅器20と、 該反転増幅器21の出力と該差動増幅器20の
出力とを入力して両者の加算を行う加算器22と
を設け、 該加算器22の出力により該アバランシエフオ
トダイオード1に入力する光信号レベルを監視す
るようにしたことを特徴とする光受信レベルモニ
タ方式。
[Claims] 1. An avalanche photodiode 1 that converts an input optical signal into an electrical signal, a variable gain amplifier 6 that amplifies the output signal of the avalanche photodiode 1, and an output signal of the variable gain amplifier 6. The avalanche photodiode 1 has a peak detector 7 for detection, and the multiplication factor of the avalanche photodiode 1 and the amplification degree of the variable gain amplifier 6 are determined by the bias voltage at one end of the avalanche photodiode 1 and the output of the peak detector 7. in an optical receiving circuit that controls the output amplitude of the variable gain amplifier 6 to be constant, the inverting amplifier 21 inputting the bias voltage of one end of the avalanche photodiode 1, inverting the sign and outputting the inverted signal; a differential amplifier 20 that inputs the voltage across a resistor 2 connected to one end of the avalanche photodiode 1 and outputs a voltage proportional to the current flowing through the avalanche photodiode 1; and an output of the inverting amplifier 21. An adder 22 is provided which inputs the output of the differential amplifier 20 and adds the two, and the level of the optical signal input to the avalanche photodiode 1 is monitored by the output of the adder 22. Optical reception level monitoring method featuring:
JP59218924A 1984-10-18 1984-10-18 Optical reception level monitoring circuit Granted JPS6198032A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP59218924A JPS6198032A (en) 1984-10-18 1984-10-18 Optical reception level monitoring circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP59218924A JPS6198032A (en) 1984-10-18 1984-10-18 Optical reception level monitoring circuit

Publications (2)

Publication Number Publication Date
JPS6198032A JPS6198032A (en) 1986-05-16
JPH0380379B2 true JPH0380379B2 (en) 1991-12-24

Family

ID=16727452

Family Applications (1)

Application Number Title Priority Date Filing Date
JP59218924A Granted JPS6198032A (en) 1984-10-18 1984-10-18 Optical reception level monitoring circuit

Country Status (1)

Country Link
JP (1) JPS6198032A (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5694852A (en) * 1979-12-28 1981-07-31 Fujitsu Ltd Monitor system for optical reception level
JPS57196639A (en) * 1981-05-28 1982-12-02 Mitsubishi Electric Corp Level monitoring circuit for photoreceiver
JPS59176938A (en) * 1983-03-25 1984-10-06 Nec Corp Optical receiving and amplifying device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5694852A (en) * 1979-12-28 1981-07-31 Fujitsu Ltd Monitor system for optical reception level
JPS57196639A (en) * 1981-05-28 1982-12-02 Mitsubishi Electric Corp Level monitoring circuit for photoreceiver
JPS59176938A (en) * 1983-03-25 1984-10-06 Nec Corp Optical receiving and amplifying device

Also Published As

Publication number Publication date
JPS6198032A (en) 1986-05-16

Similar Documents

Publication Publication Date Title
US5287375A (en) Apparatus for driving a laser diode array
US4241455A (en) Data receiving and processing circuit
US5307196A (en) Optical receiver
CA2106439A1 (en) Burst mode digital data receiver
US6031219A (en) Bias voltage supply circuit for photoelectric converting element and photodetection circuit
EP0563776B1 (en) Signal detecting circuit apparatus
US6952005B2 (en) Optical receiver circuit
US5224112A (en) Semiconductor laser device driving circuit
US4450564A (en) Apparatus for modulating the output signal of a converter
JPH0636539B2 (en) DC control circuit for telephone interface circuit
JPH02250564A (en) Clamp device and automatic gain controller
JPH0380379B2 (en)
US3660782A (en) Signal level-to-pulse rate converter
EP0921635A1 (en) Power amplifier device
EP0385547A1 (en) Amplifier arrangement with saturation detection
EP0377978A2 (en) A PLL control apparatus
JPH066308A (en) Light reception agc circuit
JPS62208724A (en) Optical receiver
KR100221655B1 (en) Optical signal detecting method and detector
JPS6378626A (en) Light modulation circuit
JPH0129333B2 (en)
JPH10177043A (en) Wh pulse detection circuit
JPH05315934A (en) Bipolar data signal generator
JPS6313534A (en) Bias voltage control circuit
JPS60201720A (en) Code reproducing circuit with automatic threshold value control function