Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JP4442199B2 - Asynchronous signal input device and sampling frequency converter - Google Patents
[go: Go Back, main page]

JP4442199B2 - Asynchronous signal input device and sampling frequency converter - Google Patents

Asynchronous signal input device and sampling frequency converter Download PDF

Info

Publication number
JP4442199B2
JP4442199B2 JP2003390564A JP2003390564A JP4442199B2 JP 4442199 B2 JP4442199 B2 JP 4442199B2 JP 2003390564 A JP2003390564 A JP 2003390564A JP 2003390564 A JP2003390564 A JP 2003390564A JP 4442199 B2 JP4442199 B2 JP 4442199B2
Authority
JP
Japan
Prior art keywords
read
conversion
interpolation
frequency
remaining amount
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 - Fee Related
Application number
JP2003390564A
Other languages
Japanese (ja)
Other versions
JP2005159407A (en
Inventor
保之 村木
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.)
Yamaha Corp
Original Assignee
Yamaha 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 Yamaha Corp filed Critical Yamaha Corp
Priority to JP2003390564A priority Critical patent/JP4442199B2/en
Publication of JP2005159407A publication Critical patent/JP2005159407A/en
Application granted granted Critical
Publication of JP4442199B2 publication Critical patent/JP4442199B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Stabilization Of Oscillater, Synchronisation, Frequency Synthesizers (AREA)

Description

この発明は、機器間で非同期信号を確実に受け渡すために使用される非同期信号入力装置、及び同装置を使用したサンプリング周波数変換装置に関する。   The present invention relates to an asynchronous signal input device used for reliably passing an asynchronous signal between devices, and a sampling frequency conversion device using the device.

ディジタルオーディオ機器等では、32kHz、44.1kHz、48kHz等、様々なサンプリング周波数が使用されている。サンプリング周波数が異なる機器同士をつなぐ場合に、送出側の機器から送出される元信号波形のデータ列を、そのまま受取側機器で読み出すと、出力される信号波形は時間方向に歪んだものとなり、元信号波形は正しく再現されない。そこで、受取側機器では、サンプリング周波数変換装置が使用される。このサンプリング周波数変換装置は、第1のサンプリング周波数の入力データ列を受け取り、この入力データ列に基づき、これと同一の信号波形を描く第2のサンプリング周波数の出力データ列を生成する装置である。   In digital audio equipment and the like, various sampling frequencies such as 32 kHz, 44.1 kHz, and 48 kHz are used. When devices with different sampling frequencies are connected, if the data sequence of the original signal waveform sent from the sending device is read as it is by the receiving device, the output signal waveform is distorted in the time direction. The signal waveform is not reproduced correctly. Therefore, a sampling frequency converter is used in the receiving device. The sampling frequency converter is an apparatus that receives an input data string having a first sampling frequency and generates an output data string having a second sampling frequency that draws the same signal waveform based on the input data string.

この種のサンプリング周波数変換装置としては、FIFO(First In First Out)を使用したものが本出願人によって提案されている(特許文献1参照)。尚、本明細書中では、特許文献1記載の技術を「従来のサンプリング周波数変換装置」と称することとする。   As this type of sampling frequency converter, a device using a FIFO (First In First Out) has been proposed by the present applicant (see Patent Document 1). In this specification, the technique described in Patent Document 1 is referred to as a “conventional sampling frequency converter”.

特開平11−55075号公報JP-A-11-55075

従来のサンプリング周波数変換装置において、処理対象である入力データ列は、第1のサンプリング周波数と同一周波数の入力クロックにより、順次、FIFOに書き込まれる。一方、サンプリング周波数変換装置では、第2のサンプリング周波数と同一周波数の出力クロックが生成され、この出力クロックに同期して、第2のサンプリング周波数の出力データ列が生成される。ここで、出力データ列は、入力データ列と同一の信号波形を描くものであるが、各々のサンプリング周波数が異なっているため、出力データ列および入力データ列の各々が時間軸上において占める位置(以下、サンプリング点という)は一般的に異なったものとなる。そこで、出力データ列を構成する個々の出力データを求めるために、その出力データのサンプリング点の前後にある所定個数の入力データ(以下、補間用入力データ列という)を用いた補間処理が出力クロックに同期して行われる。この補間処理では、発生すべき出力データのサンプリング点の時間軸上での位置を示す位相情報を求める処理と、この位相情報に対応付けて用意された補間用係数列を補間用入力データ列に畳み込む処理が行われる。位相情報は、出力クロックが発生する度に、ある適正な値の周波数制御情報を累算することにより生成される。この周波数制御情報の累算が繰り返されることにより、その累算結果たる位相情報は順次増加し、位相情報によって示されるサンプリング点が時間軸上を移動する。そして、位相情報によって示されるサンプリング点が、補間用入力データ列における最も新しい入力データのサンプリング点を越すと、出力クロックに同期したタイミングで読み出しクロックが発生され、これにより、FIFOに保存されていた入力データ列のうち最も古いものが読み出される。この読み出された入力データは、補間用入力データ列に追加され、補間用入力データ列中の最も古い入力データは廃棄される。このような処理により、入力データ列と同一信号波形を描く出力データ列が得られる。   In the conventional sampling frequency converter, the input data string to be processed is sequentially written into the FIFO by the input clock having the same frequency as the first sampling frequency. On the other hand, in the sampling frequency conversion device, an output clock having the same frequency as the second sampling frequency is generated, and an output data string having the second sampling frequency is generated in synchronization with the output clock. Here, the output data string is the same signal waveform as that of the input data string, but each sampling frequency is different, so that the position occupied by each of the output data string and the input data string on the time axis ( Hereinafter, sampling points) are generally different. Therefore, in order to obtain individual output data constituting the output data string, interpolation processing using a predetermined number of input data before and after the sampling point of the output data (hereinafter referred to as interpolation input data string) is performed as an output clock. Done in sync with In this interpolation process, a process for obtaining phase information indicating the position of the sampling point of output data to be generated on the time axis, and an interpolation coefficient string prepared in association with this phase information are used as an input data string for interpolation. A convolution process is performed. The phase information is generated by accumulating some appropriate value of frequency control information each time an output clock is generated. By repeating the accumulation of the frequency control information, the phase information as the accumulation result sequentially increases, and the sampling point indicated by the phase information moves on the time axis. Then, when the sampling point indicated by the phase information exceeds the sampling point of the newest input data in the input data string for interpolation, a read clock is generated at a timing synchronized with the output clock, and is stored in the FIFO. The oldest input data string is read out. The read input data is added to the interpolation input data string, and the oldest input data in the interpolation input data string is discarded. By such processing, an output data string that draws the same signal waveform as the input data string is obtained.

ここで、入力データ列のFIFOへの書き込みに用いられる入力クロックの周波数が第1のサンプリング周波数に正確に一致しており、かつ、補間処理のタイミング制御に用いられる出力クロックの周波数が第2のサンプリング周波数に正確に一致している場合には、周波数制御情報として、第1のサンプリング周波数と第2のサンプリング周波数との比に相当する固定値を用いればよい。しかし、入力クロックの周波数精度および出力クロックの周波数精度を如何に厳しくしても、各々を第1および第2のサンプリング周波数に正確に一致させるのには限界がある。このため、例えば入力クロックの周波数が第1のサンプリング周波数よりも高い、あるいは出力クロックの周波数が第2のサンプリング周波数よりも低い、といったことが起こると、FIFO内の残存データ量(読み出し未了の入力データの個数)が時間経過に伴って増大し、やがてFIFOがオーバーフローしてしまう。逆に、入力クロックの周波数が第1のサンプリング周波数よりも低い、あるいは出力クロックの周波数が第2のサンプリング周波数よりも高い、といったことが起こると、FIFO内の残存データ量が時間経過に伴って減少し、やがてFIFOがアンダーフローしてしまう。   Here, the frequency of the input clock used for writing the input data string to the FIFO exactly matches the first sampling frequency, and the frequency of the output clock used for timing control of the interpolation processing is the second. If the sampling frequency exactly matches, a fixed value corresponding to the ratio between the first sampling frequency and the second sampling frequency may be used as the frequency control information. However, no matter how strict the frequency accuracy of the input clock and the frequency accuracy of the output clock are, there is a limit to exactly matching each of them with the first and second sampling frequencies. For this reason, if, for example, the frequency of the input clock is higher than the first sampling frequency or the frequency of the output clock is lower than the second sampling frequency, the remaining data amount in the FIFO (reading has not been completed). The number of input data) increases with time, and eventually the FIFO overflows. Conversely, when the frequency of the input clock is lower than the first sampling frequency, or the frequency of the output clock is higher than the second sampling frequency, the remaining data amount in the FIFO increases with time. It will decrease and eventually the FIFO will underflow.

このような問題を解決するため、従来のサンプリング周波数変換装置には、FIFO内の残存データ量に応じて周波数制御情報を増減することにより、FIFOのオーバーフローおよびアンダーフローを防止する非同期信号入力装置が設けられている。
さらに詳述すると、この非同期信号入力装置では、FIFOの残存データ量、すなわち、FIFOに最後に書き込まれた入力データとFIFOから最後に読み出された入力データとの位相差を目標位相差と比較し、両者間の位相誤差に応じた修正量を求め、この修正量を時間軸上において均して周波数制御情報を生成している。この構成によれば、FIFOの残存データ量が増え、正の位相誤差が発生すると、周波数制御情報が増加する。この結果、位相情報の時間勾配が増加し、FIFOから入力データを読み出す頻度が増加し、FIFOの残存データ量が低下する。一方、FIFOの残存データ量が減少し、負の位相誤差が発生すると、周波数制御情報が減少する。この結果、位相情報の時間勾配が低下し、FIFOから入力データを読み出す頻度が減少し、FIFOの残存データ量が増加する。このように、非同期信号入力装置では、FIFOに書き込まれる入力データとFIFOから読み出される入力データとの位相差の時間平均値を適正な値に収束させる、いわばPLL(Phase Locked Loop)としての動作が行われ、FIFOのオーバーフローおよびアンダーフローが防止される。
In order to solve such a problem, the conventional sampling frequency converter has an asynchronous signal input device that prevents the overflow and underflow of the FIFO by increasing or decreasing the frequency control information according to the amount of remaining data in the FIFO. Is provided.
More specifically, in this asynchronous signal input device, the remaining data amount of the FIFO, that is, the phase difference between the last written data in the FIFO and the last read data from the FIFO is compared with the target phase difference. Then, a correction amount corresponding to the phase error between them is obtained, and this correction amount is averaged on the time axis to generate frequency control information. According to this configuration, when the amount of remaining data in the FIFO increases and a positive phase error occurs, the frequency control information increases. As a result, the time gradient of the phase information increases, the frequency of reading input data from the FIFO increases, and the remaining data amount of the FIFO decreases. On the other hand, if the amount of data remaining in the FIFO decreases and a negative phase error occurs, the frequency control information decreases. As a result, the time gradient of the phase information decreases, the frequency of reading input data from the FIFO decreases, and the amount of remaining data in the FIFO increases. As described above, in the asynchronous signal input device, an operation as a PLL (Phase Locked Loop) is performed so that the time average value of the phase difference between the input data written to the FIFO and the input data read from the FIFO is converged to an appropriate value. And FIFO overflow and underflow are prevented.

ところで、上述した従来の非同期信号入力装置は、予め用意された変換テーブルに従い、FIFOの残存データ量と目標値との差に応じた修正量を求めていた。ここで、FIFOの残存データ量と目標値との差に対して、修正量が小さく設定されていれば、PLLのフェーズロックが外れた場合に再びフェーズロック状態となるまでの時間が長くなる。その一方、FIFOの残存データ量と目標値との差に対して修正量が大きく設定されていると、フェーズロック状態への移行は迅速に行われるが、フェーズロック状態における読み出しクロックの周波数の変動も大きくなって、逆に動作が不安定になる。このように従来の非同期信号入力装置は、フェーズロック状態への移行を迅速に行わせることと、フェーズロック状態における動作の安定化を図ることを両立させることが難しいという問題を有していた。
本発明は上述した事情に鑑みてなされたものであり、FIFOから読み出されたデータと、FIFOに書き込まれたデータとの位相差を速やかに目標位相差に収束させると共に、この収束した状態を安定に維持し得る非同期信号入力装置、及び同装置を使用したサンプリング周波数変換装置を提供することを目的としている。
By the way, the above-described conventional asynchronous signal input device calculates a correction amount according to the difference between the remaining data amount of the FIFO and the target value in accordance with a conversion table prepared in advance. Here, if the correction amount is set small with respect to the difference between the remaining data amount of the FIFO and the target value, the time until the phase lock state is resumed when the phase lock of the PLL is released becomes longer. On the other hand, if the correction amount is set large with respect to the difference between the remaining data amount of the FIFO and the target value, the shift to the phase lock state is performed quickly, but the frequency of the read clock in the phase lock state varies. Becomes larger and the operation becomes unstable. As described above, the conventional asynchronous signal input device has a problem that it is difficult to achieve both the rapid transition to the phase locked state and the stabilization of the operation in the phase locked state.
The present invention has been made in view of the above-described circumstances. The phase difference between the data read from the FIFO and the data written to the FIFO is quickly converged to the target phase difference, and this converged state is An object of the present invention is to provide an asynchronous signal input device that can be stably maintained, and a sampling frequency conversion device using the same.

上述した課題を解決するため、本発明に係る非同期信号入力装置は、記憶手段と、第1の周波数の入力クロックに従い、入力データを前記記憶手段に書き込む書き込み制御手段と、前記記憶手段に格納された読み出し未了の入力データの残存量を計測するデータ量計測手段と、変換特性の異なった第1および第2の変換手段を有し、これらの変換手段のいずれかを使用することにより、前記残存量と目標値との間の誤差を修正量に変換し、該修正量に基づいて周波数制御情報を生成するループフィルタ部と、前記残存量が前記目標値に収束したか否かを判定し、該判定結果に基づいて、前記第1または第2の変換手段の一方の使用を前記ループフィルタ部に指示する判定手段と、第2の周波数の出力クロックに同期した読み出し信号を、前記周波数制御情報に応じた時間密度で生成する読み出し信号生成手段と、前記読み出し信号生成手段によって生成された読み出し信号により前記記憶手段から入力データを読み出す読み出し制御手段とを具備を具備し、前記第1の変換手段は、前記第2の変換手段よりも前記修正量が小さい変換手段であり、前記判定手段は、前記残存量が前記目標値に収束したと判定した場合には前記第1の変換手段の使用を前記ループフィルタ部に指示し、前記残存量が前記目標値に収束していないと判定した場合には前記第2の変換手段の使用を前記ループフィルタ部に指示することを特徴としている。かかる非同期信号入力装置によれば、前記判定手段による判定結果に基づいて、複数の変換特性のうち、前記記憶手段の現在のデータ量に適した変換特性が、変換特性選択手段によって与えられる。従って、記憶手段のデータ量が目標値から大きく外れている場合には、速やかにこのデータ量を目標値又は目標値を含む所定の範囲に収束させるとともに、データ量が一旦収束した場合には、その収束状態を維持させることが可能となって、極めて安定したデータの受渡しが提供される。 In order to solve the above-described problem, an asynchronous signal input device according to the present invention is stored in a storage unit, a write control unit that writes input data to the storage unit in accordance with an input clock of a first frequency, and the storage unit. The data amount measuring means for measuring the remaining amount of the input data that has not been read, and the first and second conversion means having different conversion characteristics, and by using any of these conversion means, A loop filter unit that converts an error between the remaining amount and the target value into a correction amount and generates frequency control information based on the correction amount, and determines whether or not the remaining amount has converged to the target value A determination means for instructing the loop filter unit to use one of the first or second conversion means based on the determination result, and a read signal synchronized with an output clock of a second frequency, Comprising a read signal generating means for generating a time density corresponding to the wave number control information, the and a read control means for reading out input data from said memory means by the read signal generated by the reading signal generating means, said first The conversion means is a conversion means whose correction amount is smaller than that of the second conversion means, and when the determination means determines that the remaining amount has converged to the target value, the first conversion means The loop filter unit is instructed to use, and when it is determined that the remaining amount has not converged to the target value, the loop filter unit is instructed to use the second conversion means . . According to such an asynchronous signal input device, a conversion characteristic suitable for the current amount of data in the storage unit is provided by the conversion characteristic selection unit among a plurality of conversion characteristics based on the determination result by the determination unit. Therefore, when the data amount of the storage means is greatly deviated from the target value, this data amount is quickly converged to the target value or a predetermined range including the target value, and when the data amount has once converged, The convergence state can be maintained, and extremely stable data delivery is provided.

また、好ましい態様において、前記判定手段は、前記残存量が前記目標値を含む予め設定された範囲にない状態である場合、および前記残存量が前記範囲にない状態から前記範囲にある状態に変化した後の一定時間は、前記残存量が前記目標値に収束していないと判定し、前記残存量が前記範囲にある状態に変化した後、当該状態を前記一定時間維持した場合には、前記残存量が前記目標値に収束したと判定する。
また、好ましい態様において、前記第1および第2の変換手段は、前記誤差と前記修正量との関係が非線形となるような変換特性を有する。
Further, in a preferred embodiment, the determination means changes from a state where the remaining amount is not within a preset range including the target value and a state where the remaining amount is not within the range to a state within the range. If the remaining amount is determined not to have converged to the target value for a certain period of time and the remaining amount is changed to a state in the range, and the state is maintained for the certain period of time, It is determined that the remaining amount has converged to the target value.
In a preferred aspect, the first and second conversion means have conversion characteristics such that the relationship between the error and the correction amount is non-linear.

また、本発明に係るサンプリング周波数変換装置は、上述の非同期信号入力装置と、前記出力クロックが発生する毎に補間情報を生成する手段であり、該補間情報を、前記ループフィルタ部から生成される周波数制御情報に基づいて制御する補間情報生成手段と、前記出力クロックの発生タイミングに対応したデータを、前記読み出し制御手段によって読み出されたデータと前記補間情報生成手段によって生成された補間情報を用いた補間演算により求める補間手段とを具備することを特徴としている。   The sampling frequency converter according to the present invention is a means for generating interpolation information every time the output clock is generated and the asynchronous signal input device described above, and the interpolation information is generated from the loop filter unit. Interpolation information generation means for controlling based on frequency control information, data corresponding to the generation timing of the output clock, data read by the read control means and interpolation information generated by the interpolation information generation means are used. Interpolating means obtained by the interpolation calculation.

以下、図面を参照して、本発明の最良な実施の形態であるサンプリング周波数変換装置について説明する。   Hereinafter, a sampling frequency converter according to the best mode of the present invention will be described with reference to the drawings.

<本実施形態の構成>
図1は、本実施形態に係るサンプリング周波数変換装置の構成を示すブロック図である。
このサンプリング周波数変換装置は、第1のサンプリング周波数f(ここでは44.1kHz)の入力データDinの列を受け取り、この入力データDinの列に基づき、これと同一の信号波形を描く第2のサンプリング周波数f(ここでは48kHz)の出力データDoutの列を生成する装置である。このサンプリング周波数変換装置では、出力データ列を生成し、出力するための処理のタイミング制御を行うため、第2のサンプリング周波数fと同一周波数の出力クロックCKoutが、図示しないクロック発生回路により生成される。
<Configuration of this embodiment>
FIG. 1 is a block diagram showing the configuration of the sampling frequency converter according to this embodiment.
The sampling frequency converter receives a sequence of input data Din having a first sampling frequency f 1 (44.1 kHz in this case), and generates a second signal waveform that draws the same signal waveform based on the sequence of input data Din. It is a device that generates a sequence of output data Dout having a sampling frequency f 2 (here, 48 kHz). In this sampling frequency converter, an output clock CKout having the same frequency as the second sampling frequency f2 is generated by a clock generation circuit (not shown) in order to control the timing of processing for generating and outputting an output data string. The

サンプリング周波数変換装置は、大別すると、非同期信号入力装置100と、補間部20とにより構成されている。ここで、非同期信号入力装置100は、3つの機能を有している。第1の機能は、第1のサンプリング周波数fの入力データ列を受け取って保存し、補間部20が新たな入力データを必要とするとき、これを出力クロックCKoutに同期したタイミングで補間部20に供給する機能である。第2の機能は、出力クロックCKoutが発生する毎に、補間部20において生成すべき出力データのサンプリング点の位相を表す補間比Δtを更新し、この補間部20に供給する機能である。第3の機能は、補間比Δtの増分である周波数制御情報を制御する機能である。補間部20は、非同期信号入力装置100を介して供給される入力データを、過去一定個数だけ、補間用入力データ列として記憶し、出力クロックCKoutの発生タイミングにおいて、その時点における補間比Δtによって定まる補間用計数列を補間用入力データ列に畳み込み、出力データを生成する手段である。 The sampling frequency converter is roughly composed of an asynchronous signal input device 100 and an interpolation unit 20. Here, the asynchronous signal input device 100 has three functions. The first function is to receive the first input data sequence of the sampling frequency f 1 and stored, when the interpolation unit 20 requires a new input data, the interpolation section 20 at the timing synchronized with the output clock CKout this It is a function to supply to. The second function is a function for updating the interpolation ratio Δt representing the phase of the sampling point of the output data to be generated in the interpolation unit 20 every time the output clock CKout is generated, and supplying this to the interpolation unit 20. The third function is a function of controlling frequency control information that is an increment of the interpolation ratio Δt. The interpolation unit 20 stores the input data supplied via the asynchronous signal input device 100 as a past fixed number as an input data string for interpolation, and is determined by the interpolation ratio Δt at that time at the generation timing of the output clock CKout. It is a means for generating output data by convolving the interpolation count sequence with the interpolation input data sequence.

次に、非同期信号入力装置100の構成について説明する。
FIFO10は、RAM(Random Access Memory)などにより構成される先入れ先出し形式のバッファであり、最大4個のデータを記憶することができる。FIFO10は、外部の送出側機器から供給される入力データDinを、一時的に保存し、古いものから順に補間部20に引き渡す。
書き込み制御部30は、入力データDinのサンプリング周波数fと同一周波数の入力クロックCkinに従って、書き込みアドレス及び書き込みイネーブル信号WEを生成し、FIFO10に供給する。FIFO10に供給される入力データDinは、書き込みイネーブル信号WEにより、FIFO10内の書き込みアドレスによって指定されるエリアに書き込まれる。
読み出し制御部40は、出力補間部20への入力データの供給を指令する読み出しクロックCKRがクロックCKoutに同期して発生されると、読み出しアドレス及び読み出しイネーブル信号REを生成し、FIFO10へ供給する。ここで、読み出しアドレスは、FIFO10内に残存している読み出し未了の入力データのうち最も古いものを指定するように制御される。この読み出しアドレスにより指定された入力データは、読み出しイネーブル信号REによりFIFO10から読み出され、補間部20に供給される。なお、読み出しクロックCKRを生成する回路については後述する。
Next, the configuration of the asynchronous signal input device 100 will be described.
The FIFO 10 is a first-in first-out buffer configured by a RAM (Random Access Memory) or the like, and can store a maximum of four pieces of data. The FIFO 10 temporarily stores the input data Din supplied from the external transmission side device, and delivers it to the interpolation unit 20 in order from the oldest one.
The write control unit 30 generates a write address and a write enable signal WE according to the input clock Ckin having the same frequency as the sampling frequency f 1 of the input data Din, and supplies it to the FIFO 10. Input data Din supplied to the FIFO 10 is written in an area designated by a write address in the FIFO 10 by a write enable signal WE.
When the read clock CKR that commands the supply of input data to the output interpolation unit 20 is generated in synchronization with the clock CKout, the read control unit 40 generates a read address and a read enable signal RE and supplies the read address and the read enable signal RE to the FIFO 10. Here, the read address is controlled so as to designate the oldest input data remaining in the FIFO 10 and not yet read. The input data designated by the read address is read from the FIFO 10 by the read enable signal RE and supplied to the interpolation unit 20. A circuit that generates the read clock CKR will be described later.

アップダウンカウンタ50は、入力クロックCkinが発生する毎に「1」だけアップカウントを行い、上記読み出しクロックCKRが発生する度に「1」だけダウンカウントを行う。このアップダウンカウンタ50のカウント値ΔSは、現時点においてFIFO10に残存する読み出し未了の入力データの個数、すなわち、残存データ量を表す。上述した様に、本実施形態において、FIFO10は最大4個のデータを記憶することができるから、ΔSの値は「0」〜「4」までのいずれかの値をとる。   The up / down counter 50 counts up by “1” every time the input clock Ckin is generated, and counts down by “1” every time the read clock CKR is generated. The count value ΔS of the up / down counter 50 represents the number of unread read input data remaining in the FIFO 10 at the present time, that is, the remaining data amount. As described above, in this embodiment, since the FIFO 10 can store a maximum of four pieces of data, the value of ΔS takes any value from “0” to “4”.

アップダウンカウンタ50のカウント値であるΔSは、FIFO10の残存データ量を示すと同時に、入力クロックCkinによって最後に書き込まれたデータDinと、読み出しクロックによって最後に読み出されたデータDinとの位相差を示すと言える。アップダウンカウンタ50と、ループフィルタ部60と、可変周波数発振部70は、この位相差を所定の目標位相差に収束させるPLL80を構成している。以下、このPLL80の構成を説明する。   ΔS which is the count value of the up / down counter 50 indicates the remaining data amount of the FIFO 10, and at the same time, the phase difference between the data Din written last by the input clock Ckin and the data Din read last by the read clock. It can be said that it shows. The up / down counter 50, the loop filter unit 60, and the variable frequency oscillating unit 70 constitute a PLL 80 that converges this phase difference to a predetermined target phase difference. Hereinafter, the configuration of the PLL 80 will be described.

ループフィルタ部60は、変換部61、第1全加算器62、第1ラッチ回路63、及びセレクタ64から構成されている。
変換部61は、アップダウンカウンタ50のカウント値ΔSに対し、後述するフェーズロック判定回路51によって指示された変換テーブルを使用して非線形変換を行い、修正量Gain・ΔSを出力する回路である。変換テーブルでは、ΔSの値に応じて、予め修正量Gain・ΔSが定められており、変換部61からは、ΔSの値に応じた修正量Gain・ΔSが第1全加算器62に供給される。
The loop filter unit 60 includes a conversion unit 61, a first full adder 62, a first latch circuit 63, and a selector 64.
The conversion unit 61 is a circuit that performs non-linear conversion on the count value ΔS of the up / down counter 50 using a conversion table instructed by a phase lock determination circuit 51 described later, and outputs a correction amount Gain · ΔS. In the conversion table, the correction amount Gain · ΔS is determined in advance according to the value of ΔS, and the correction amount Gain · ΔS corresponding to the value of ΔS is supplied from the conversion unit 61 to the first full adder 62. The

図2は、本実施形態における変換テーブルである。同図に示すように、変換テーブルには第1変換テーブル、及び第2変換テーブルがあり、各々において、アップダウンカウンタ50のカウント値ΔSに応じて異なる修正量Gain・ΔSが定められている。第1変換テーブルは、第2変換テーブルよりも修正量が小さくなっているが、何れの変換テーブルにおいても、ΔSの値が「0」又は「1」である場合には負の修正量が、「2」である場合にはゼロが、「3」又は「4」の場合には正の修正量が与えられるようになっている。   FIG. 2 is a conversion table in this embodiment. As shown in the figure, the conversion table includes a first conversion table and a second conversion table, and a different correction amount Gain · ΔS is determined in accordance with the count value ΔS of the up / down counter 50. The first conversion table has a smaller correction amount than the second conversion table, but in any conversion table, if the value of ΔS is “0” or “1”, the negative correction amount is Zero is given when it is “2”, and a positive correction amount is given when it is “3” or “4”.

第1全加算器62は15ビット構成の全加算器である。第1全加算器62は、修正量Gain・ΔSとセレクタ64から供給される値y(n)とを加算し、下記(1)式に示す演算を行う。第1全加算器62の出力である下記y(n+1)は、第1ラッチ回路63によって、出力クロックCKoutに同期したタイミングでラッチされ、ループフィルタ部60の出力である周波数制御情報として、可変周波数発振部70に供給される。
y(n+1)=y(n)+Gain・ΔS ・・・・・(1)
The first full adder 62 is a 15-bit full adder. The first full adder 62 adds the correction amount Gain · ΔS and the value y (n) supplied from the selector 64, and performs the calculation shown in the following equation (1). The following y (n + 1), which is the output of the first full adder 62, is latched by the first latch circuit 63 at a timing synchronized with the output clock CKout, and the frequency control information that is the output of the loop filter unit 60 is variable frequency. It is supplied to the oscillation unit 70.
y (n + 1) = y (n) + Gain · ΔS (1)

ここで、周波数制御情報である上記y(n+1)は、上記(1)式におけるy(n)として、セレクタ64へ再びフィードバックされる。従って、ループフィルタ部60では、出力クロックCKout毎に、FIFO10の残存データ量に基づいて周波数制御情報が更新される。
尚、セレクタ64には初期値y(0)として「4096×44.1/48」なる値が格納されており、装置の動作開始時にはこのy(0)が第1全加算器62に与えられ、以降(1)式に示す演算が行われるようになっている。
Here, y (n + 1), which is frequency control information, is fed back to the selector 64 as y (n) in the equation (1). Accordingly, in the loop filter unit 60, the frequency control information is updated based on the remaining data amount of the FIFO 10 for each output clock CKout.
The selector 64 stores a value “4096 × 44.1 / 48” as an initial value y (0), and this y (0) is given to the first full adder 62 when the operation of the apparatus is started. Thereafter, the calculation shown in the equation (1) is performed.

可変周波数発振部70は、12ビット構成の第2全加算器71及び第2ラッチ回路72で構成されている。第2ラッチ回路72は、出力クロックCKoutに同期して第2全加算器71の出力データをラッチし、再び第2全加算器71にフィードバックする。即ち、第2全加算器71は、ループフィルタ部60の出力データとして供給される周波数制御情報y(n)を出力クロックCKout毎に累算する。第2ラッチ回路72の出力は、第2全加算器71にフィードバックされる一方、補間比Δtとして補間部20に供給される。   The variable frequency oscillating unit 70 includes a 12-bit second full adder 71 and a second latch circuit 72. The second latch circuit 72 latches the output data of the second full adder 71 in synchronization with the output clock CKout, and feeds it back to the second full adder 71 again. That is, the second full adder 71 accumulates the frequency control information y (n) supplied as output data of the loop filter unit 60 for each output clock CKout. The output of the second latch circuit 72 is fed back to the second full adder 71 while being supplied to the interpolation unit 20 as an interpolation ratio Δt.

第2全加算器71は12ビット構成であるから、累算値が212、即ち「4096」となる毎に、この第2全加算器71からはキャリーアウトが発生する。このキャリーアウトの発生する時間密度は、ループフィルタ部60から出力される周波数制御情報y(n)の値に依存する。このキャリーアウトは、可変周波数発振部70の出力である読み出しクロックCKRとして、読み出し制御部40、及びアップダウンカウンタ50に供給される。 Since the second full adder 71 has a 12-bit configuration, a carry-out occurs from the second full adder 71 every time the accumulated value becomes 2 12 , that is, “4096”. The time density at which this carry-out occurs depends on the value of the frequency control information y (n) output from the loop filter unit 60. This carry-out is supplied to the read control unit 40 and the up / down counter 50 as a read clock CKR which is an output of the variable frequency oscillating unit 70.

フェーズロック判定回路51は、アップダウンカウンタ50、及び変換部61に接続されており、アップダウンカウンタ50から位相差信号であるΔSを受け取って、ΔSが収束しているか否かを判定し、変換部61に対して変換テーブル選択信号を供給する回路である。本実施形態において、変換テーブルは、既に図2に示した様に2種類用意されており、変換部61は、供給された変換テーブル選択信号に基づいて、何れかの変換テーブルを選択し、選択された変換テーブルに従って、上述した非線形変換を行い、現時点での位相差に基づく修正量Gain・ΔSをPLL80のループフィルタ部60に供給する。第1変換テーブルは、第1変換テーブル選択信号に、また、第2変換テーブルは、第2変換テーブル選択信号にそれぞれ従って、変換部61によって選択される。   The phase lock determination circuit 51 is connected to the up / down counter 50 and the conversion unit 61. The phase lock determination circuit 51 receives ΔS as a phase difference signal from the up / down counter 50, determines whether ΔS has converged, and performs conversion. This is a circuit for supplying a conversion table selection signal to the unit 61. In the present embodiment, two types of conversion tables have already been prepared as shown in FIG. 2, and the conversion unit 61 selects and selects one of the conversion tables based on the supplied conversion table selection signal. The nonlinear conversion described above is performed in accordance with the converted table, and the correction amount Gain · ΔS based on the current phase difference is supplied to the loop filter unit 60 of the PLL 80. The first conversion table is selected by the conversion unit 61 according to the first conversion table selection signal, and the second conversion table is selected according to the second conversion table selection signal.

フェーズロック判定回路51は、制御部とクロックカウンタ(いずれも図示略)を有している。制御部は、アップダウンカウンタ50から入力されるΔSを、クロックCKoutと同期したタイミングで内部メモリに取り込み、その値を記憶する。記憶した値が「0」又は「4」である場合、制御部は、PLL80のフェーズロックが外れた状態であると判定し、第2変換テーブル選択信号を変換部61に出力する。
ΔSの値が、一定時間(1msec)以上「1」〜「2」又は「2」〜「3」の範囲にある場合、フェーズロック判定回路51はPLL80がフェーズロック状態にあると判断し、第1変換テーブル選択信号を変換部61に供給する。この経過時間は、クロックカウンタがクロックCKoutの発生回数をカウントすることによって得られる。また、これ以外の場合、例えば、ΔSの値が、「1」〜「3」の間で切り替っている場合は、現在選択されている変換テーブルが維持される。
尚、上記一定時間は、ここでは1msecに設定されているが、これに限定されるものではなく、状況に応じて自由に設定可能である。例えば、本実施形態においては、数msec〜数secの範囲で設定されているのが好適である。
The phase lock determination circuit 51 has a control unit and a clock counter (both not shown). The control unit takes ΔS input from the up / down counter 50 into the internal memory at a timing synchronized with the clock CKout, and stores the value. When the stored value is “0” or “4”, the control unit determines that the phase lock of the PLL 80 is released, and outputs the second conversion table selection signal to the conversion unit 61.
When the value of ΔS is in the range of “1” to “2” or “2” to “3” for a certain time (1 msec) or more, the phase lock determination circuit 51 determines that the PLL 80 is in the phase lock state, and One conversion table selection signal is supplied to the converter 61. This elapsed time is obtained by the clock counter counting the number of occurrences of the clock CKout. In other cases, for example, when the value of ΔS is switched between “1” and “3”, the currently selected conversion table is maintained.
In addition, although the said fixed time is set to 1 msec here, it is not limited to this, It can set freely according to a condition. For example, in the present embodiment, it is preferable to set within a range of several milliseconds to several seconds.

<本実施形態の動作>
図3は、本実施形態に係る非同期信号入力装置の動作を示すタイミングチャートである。信号波形のサンプルである入力データDinは、既に述べたように、サンプリング周波数f(44.1kHz)と同一周波数の入力クロックCkinに同期し、FIFO10に供給される。ここで、FIFO10は、4個のアドレス「A1」〜「A4」に対応した各エリアを持っている。書き込み制御部30は、入力クロックCkinが発生する毎に、書き込みイネーブル信号WEをFIFO10に供給するとともに、その際にFIFO10に与える書き込みアドレスを順次「A1」、「A2」、「A3」、「A4」、「A1」、〜という具合に巡回的に変化させる。このようにして、FIFO10内のアドレス「A1」〜「A4」に対応した各エリアが巡回的に書き込み先として指定され、入力データDinが順次書き込まれる。以下、FIFO10におけるアドレス「Ax」(x=1〜4)に書き込まれた入力データDinをDin(Ax)と表記し、入力データ全体を指す場合には単に「Din」、特定のDinを指定する場合には「Din(Ax)」と表記する。
<Operation of this embodiment>
FIG. 3 is a timing chart showing the operation of the asynchronous signal input device according to this embodiment. As described above, the input data Din which is a sample of the signal waveform is supplied to the FIFO 10 in synchronization with the input clock Ckin having the same frequency as the sampling frequency f 1 (44.1 kHz). Here, the FIFO 10 has areas corresponding to four addresses “A1” to “A4”. The write controller 30 supplies the write enable signal WE to the FIFO 10 every time the input clock Ckin is generated, and sequentially writes write addresses to be given to the FIFO 10 at that time, “A1”, “A2”, “A3”, “A4”. ”,“ A1 ”, and so on. In this way, each area corresponding to the addresses “A1” to “A4” in the FIFO 10 is cyclically designated as the write destination, and the input data Din is sequentially written. Hereinafter, the input data Din written to the address “Ax” (x = 1 to 4) in the FIFO 10 is expressed as Din (Ax), and when referring to the entire input data, simply “Din”, a specific Din is designated. In this case, it is expressed as “Din (Ax)”.

読み出し制御部40は、読み出しクロックCKRが与えられる毎に、読み出しイネーブル信号REおよび読み出しアドレスをFIFO10に供給する。その際、読み出し制御部40は、読み出しイネーブル信号とともに供給する読み出しアドレスを「A1」、「A2」、「A3」、「A4」、「A1」、〜という具合に巡回的に変化させる。
アップダウンカウンタ50は、入力クロックCKinが与えられる度にアップカウントを行い、読み出しクロックCKRが与えられる度にダウンカウントを行う。このアップダウンカウンタ50のカウント値ΔSは、FIFO10内の残存データ量を表すとともに、FIFO10に書き込まれるデータDinとFIFO10から読み出されるデータDinとの位相差を表している。
The read control unit 40 supplies the read enable signal RE and the read address to the FIFO 10 every time the read clock CKR is given. At this time, the read control unit 40 cyclically changes the read address supplied together with the read enable signal to “A1”, “A2”, “A3”, “A4”, “A1”, and so on.
The up / down counter 50 counts up every time the input clock CKin is given, and counts down every time the read clock CKR is given. The count value ΔS of the up / down counter 50 represents the amount of remaining data in the FIFO 10 and also represents the phase difference between the data Din written to the FIFO 10 and the data Din read from the FIFO 10.

ここで、FIFO10内の残存データ量が大きく、カウント値ΔSが示す位相差が目標位相差(図2に示す例では「2」に相当する位相差)よりも大きい時、変換部61は、正の修正量Gain・ΔSを出力する。一方、FIFO10内の残存データ量が小さく、カウント値ΔSが示す位相差が目標位相差よりも小さい時、変換部61は、負の修正量Gain・ΔSを出力する。第1全加算器62、第1ラッチ回路63およびセレクタ64からなるループは、このようにして変換部61から順次出力される修正量Gain・ΔSを時間軸上において均し、周波数制御情報y(n)として出力する。可変周波数発振部70は、出力クロックCKoutが与えられる毎に、この周波数制御情報y(n)の累算を行う。そして、この累算の過程において全加算器71がオーバーフローする毎に、そのとき発生するキャリーアウトCOを読み出しクロックCKRとして出力する。この読み出しクロックCKRが発生する時間密度は、周波数制御情報y(n)に依存し、周波数制御情報y(n)が大きければ読み出しクロックCKRの時間密度は大きくなり、逆に周波数制御情報y(n)が小さければ読み出しクロックCKRの時間密度は小さくなる。そして、読み出しクロックCKRの時間密度が、第1のサンプリング周波数fに相当するものよりも大きくなると、アップダウンカウンタ50のカウント値ΔSが減少して負の修正量Gain・ΔSが発生する頻度が増し、周波数制御情報y(n)が減少する。この結果、読み出しクロックCKRの時間密度が低下する。逆に、読み出しクロックCKRの時間密度が、第1のサンプリング周波数fに相当するものよりも小さくなると、アップダウンカウンタ50のカウント値ΔSが増加して正の修正量Gain・ΔSが発生する頻度が増し、周波数制御情報y(n)が増加する。この結果、読み出しクロックCKRの時間密度が上昇する。このようなPLLとしての動作が行われる結果、読み出しクロックCKRは、第2のサンプリング周波数fと同一周波数の出力クロックCKoutに同期して発生されるものの、その時間密度は、第1のサンプリング周波数f相当のものに収束する。 Here, when the amount of remaining data in the FIFO 10 is large and the phase difference indicated by the count value ΔS is larger than the target phase difference (a phase difference corresponding to “2” in the example shown in FIG. 2), The correction amount Gain · ΔS is output. On the other hand, when the remaining data amount in the FIFO 10 is small and the phase difference indicated by the count value ΔS is smaller than the target phase difference, the conversion unit 61 outputs a negative correction amount Gain · ΔS. The loop composed of the first full adder 62, the first latch circuit 63, and the selector 64 averages the correction amount Gain · ΔS sequentially output from the conversion unit 61 in this way on the time axis, and the frequency control information y ( n). The variable frequency oscillating unit 70 accumulates the frequency control information y (n) every time the output clock CKout is given. Then, every time the full adder 71 overflows during the accumulation process, the carry-out CO generated at that time is output as the read clock CKR. The time density at which the read clock CKR is generated depends on the frequency control information y (n). If the frequency control information y (n) is large, the time density of the read clock CKR is large, and conversely, the frequency control information y (n ) Is small, the time density of the read clock CKR is small. When the time density of the read clock CKR becomes larger than that corresponding to the first sampling frequency f1, the count value ΔS of the up / down counter 50 decreases and the negative correction amount Gain · ΔS is generated. Increasing the frequency control information y (n) decreases. As a result, the time density of the read clock CKR decreases. Conversely, when the time density of the read clock CKR becomes smaller than that corresponding to the first sampling frequency f1, the frequency at which the count value ΔS of the up / down counter 50 increases and the positive correction amount Gain · ΔS is generated. And frequency control information y (n) increases. As a result, the time density of the read clock CKR increases. As a result of such an operation as a PLL, the read clock CKR is generated in synchronization with the output clock CKout having the same frequency as the second sampling frequency f2, but the time density thereof is the first sampling frequency. It converges to f 1 equivalent of thing.

図3に示す例においては、時刻t、t、t、t、tにおいて出力クロックCKoutが発生している。そして、時刻t、t、t、tでは、出力クロックCKoutに同期して読み出しクロックCKRが発生するが、時刻tでは読み出しクロックCKRが発生しない。このように、本実施形態では、個々の出力クロックCKoutを所々間引いた態様で、第1のサンプリング周波数f相当の時間密度の読み出しクロックCKRが発生されるのである。このようにして発生される読み出しクロックCKRにより、FIFO10内の入力データDinが古いものから順に読み出され、補間部20に供給される。補間部20では、このようにして供給される入力データDinを用いた補間演算が、出力クロックCKoutが与えられる毎に実行され、第2のサンプリング周波数fのサンプリングデータである出力データDoutが生成される。 In the example shown in FIG. 3, the output clock CKout is generated at times t 1 , t 2 , t 3 , t 4 , and t 5 . At time t 1 , t 2 , t 3 , t 5 , the read clock CKR is generated in synchronization with the output clock CKout, but at time t 4 , the read clock CKR is not generated. Thus, in the present embodiment, the read clock CKR having a time density corresponding to the first sampling frequency f1 is generated in a manner in which the individual output clocks CKout are thinned out in some places. In accordance with the read clock CKR generated in this way, the input data Din in the FIFO 10 is read in order from the oldest and supplied to the interpolation unit 20. In the interpolation unit 20, an interpolation operation using the input data Din supplied in this way is executed every time the output clock CKout is given, and output data Dout which is sampling data of the second sampling frequency f2 is generated. Is done.

図4は、本実施形態に係るサンプリング周波数変換装置の動作を示すタイミングチャートである。同図は、図3に対し、補間部20の動作を追記したものである。以下、図4を参照して、補間部20の動作について説明する。
既に述べた様に、可変周波数発振部70からは、出力クロックCKoutに同期して補間比Δtが生成され、補間部20に供給される。図4には、クロックCKoutが発生する度に補間比Δtが更新される様子が示されている。
FIG. 4 is a timing chart showing the operation of the sampling frequency converter according to the present embodiment. This figure shows the operation of the interpolation unit 20 added to FIG. Hereinafter, the operation of the interpolation unit 20 will be described with reference to FIG.
As already described, the interpolation frequency Δt is generated from the variable frequency oscillating unit 70 in synchronization with the output clock CKout and supplied to the interpolation unit 20. FIG. 4 shows how the interpolation ratio Δt is updated every time the clock CKout is generated.

図5は、補間部20によって行われる補間処理を示す図である。本実施形態において、補間部20は、FIFO10から読み出される入力データのうち最新の2個を格納するシフトレジスタを有している。補間部20は、出力クロックCKoutの発生タイミングにおいて、このシフトレジスタに格納された2個の入力データDin(t)およびDin(t+1)と、そのとき可変周波数発振部70から供給される補間比Δtと、入力データDinのサンプリング周期Tとを用いて、出力クロックCKoutの発生タイミングにおける第2のサンプリング周波数fの出力データDoutを求める補間演算を行う。ここで、補間比Δtは、出力クロックCKoutの発生タイミング、すなわち、補間によって求めようとする出力データのサンプリング点(図5におけX印)と、その直前の入力データDin(t)のサンプリング点との間の時間を示している。補間部20は、これらに基づいて、下記(2)式に示す補間演算を実行する。
Dout=Din(t)+(Din(t+1)−Din(t))×Δt/T・・・(2)
FIG. 5 is a diagram illustrating an interpolation process performed by the interpolation unit 20. In the present embodiment, the interpolation unit 20 has a shift register that stores the latest two pieces of input data read from the FIFO 10. The interpolation unit 20 generates two pieces of input data Din (t) and Din (t + 1) stored in the shift register at the generation timing of the output clock CKout, and the interpolation ratio Δt supplied from the variable frequency oscillation unit 70 at that time. When, by using the sampling period T of the input data Din, performs interpolation calculation for obtaining a second output data Dout of the sampling frequency f 2 in the generation timing of the output clock CKout. Here, the interpolation ratio Δt is the generation timing of the output clock CKout, that is, the sampling point of the output data to be obtained by interpolation (marked with X in FIG. 5) and the sampling point of the input data Din (t) immediately before it. Shows the time between. Based on these, the interpolation unit 20 executes the interpolation calculation shown in the following equation (2).
Dout = Din (t) + (Din (t + 1) −Din (t)) × Δt / T (2)

図4には、このような補間処理が逐次実行される様子が示されている。なお、以降の説明において、時刻tにおいて出力された補間比をΔtと表現することとする。
時刻tにおいて、補間部20には、第2ラッチ回路72から補間比Δtが供給される。一方、補間部20のシフトレジスタには、読み出しクロックCKRに基づいて新たにDin(A3)が読み出されるため、時刻tにおいては、Din(A2)、及びDin(A3)が格納されている。補間部20は、このDin(A2)、Din(A3)、及びΔtによって、上記(2)式に示す補間演算を行い、時刻tにおける出力データDout(t)を算出する。時刻tにおいても、時刻tと同様に、補間部20のシフトレジスタにDin(A3)、及びDin(A4)が格納され、Dout(t)が算出される。
次に、時刻tにおいては、読み出しクロックCKRが発生しないため、シフトレジスタの格納内容は変化しない。従って、補間部20は、Din(A3)、Din(A4)、及び補間比Δtを使用して補間演算を行い、時刻tにおける出力データDout(t)を算出する。本実施形態に係るサンプリング周波数変換装置では、このようにして出力データDoutが算出される。
FIG. 4 shows how such an interpolation process is sequentially executed. In the following description, the output interpolation ratio at time t x and be expressed as Delta] t x.
At time t 2 , the interpolation unit 20 is supplied with the interpolation ratio Δt 2 from the second latch circuit 72. On the other hand, the shift register of the interpolation section 20, since the Din (A3) is read anew on the basis of the read clock CKR, at time t 2, Din (A2), and Din (A3) are stored. Interpolation unit 20, the Din (A2), Din (A3), and the Delta] t 2, performs interpolation calculation shown in the above (2) to calculate the output data Dout (t 2) at time t 2. At time t 3 , similarly to time t 2 , Din (A3) and Din (A4) are stored in the shift register of the interpolation unit 20, and Dout (t 3 ) is calculated.
Then, at time t 4, since the read clock CKR is not generated, the storage contents of the shift register is not changed. Therefore, the interpolation section 20, Din (A3), Din ( A4), and performs interpolation calculation using interpolation ratio Delta] t 4, calculates the output data Dout (t 4) at time t 4. In the sampling frequency converter according to the present embodiment, the output data Dout is calculated in this way.

さて、以上説明した動作において、PLL80がフェーズロック状態にあるときは、変換部61から出力される修正量Gain・ΔSの値は小さい方が望ましい。何故ならば、大きな値の修正量Gain・ΔSが出力されると、周波数制御情報y(n)の時間変動が大きくなり、可変周波数発振部70の周波数変動が大きくなって、フェーズロックが外れる恐れがあるからである。また、修正量Gain・ΔSの値が大きいと、フェーズロック状態における周波数制御情報の定常的な揺らぎの振幅が大きく、そして周期が短くなり、サンプリング周波数変換後のデータの歪みが大きくなるからである。以下、この後者の理由についてやや詳しく述べる。既に述べたように、周波数制御情報は、「4096×44.1/48」に相当する値を初期値として、ΔSが「2」(すなわち、修正量=0となるΔS)になるように補正が繰り返される。このため、周波数制御情報は、フェーズロック状態においても、ある周期と振幅を持った正弦波に近い曲線を描く。図7は、この周波数制御情報の定常的な揺らぎを例示するものであり、細線は修正量Gain・ΔSの値が小さい場合を、太線は修正量Gain・ΔSの値が大きい場合を各々例示している。また、図8はサンプリング周波数変換後のデータによって表される波形を例示するものであり、細線は修正量Gain・ΔSの値が小さい場合を、太線は修正量Gain・ΔSの値が大きい場合を各々例示している。なお、これらの図は、あくまでも例を示すものであり、図示が煩雑になるのを防ぐため、修正量Gain・ΔSの小さい場合における周波数制御情報等の曲線と修正量Gain・ΔSの大きい場合における周波数制御情報等の曲線との差を際立たせて図示している。図7に示すように、修正量Gain・ΔSが大きいほど、周波数制御情報の揺らぐ周期は短くなり、振幅は大きくなる。そして、このように周波数制御情報の揺らぐ周期は短くなり、振幅は大きくなると、図8に示すように、サンプリング周波数変換後のデータの位相誤差が大きくなり、歪みがより大きくなる。このような事態が生じるのを防ぐためにも、修正量Gain・ΔSの値は小さい方が望ましいのである。一方で、外乱の発生や、装置の立ち上がり応答に際しては、変換部61から出力される修正量Gain・ΔSの値を大きくすることによりPLL80のループゲインを大きくし、速やかにPLL80をフェーズロックさせることが好ましい。このため、本実施形態においては、変換テーブルを2種類用意し、適切なタイミングでそれらを切り替えることによって、可変周波数発振部70の周波数変動を制御している。この切り替え制御を行うのがフェーズロック判定回路51である。   In the operation described above, when the PLL 80 is in the phase lock state, it is desirable that the value of the correction amount Gain · ΔS output from the conversion unit 61 is small. This is because if a large correction amount Gain · ΔS is output, the time variation of the frequency control information y (n) increases, the frequency variation of the variable frequency oscillator 70 increases, and the phase lock may be released. Because there is. Also, if the value of the correction amount Gain · ΔS is large, the amplitude of the steady fluctuation of the frequency control information in the phase lock state is large, the period is shortened, and the distortion of the data after the sampling frequency conversion is large. . The reason for the latter will be described in some detail below. As described above, the frequency control information is corrected so that ΔS becomes “2” (that is, ΔS at which the correction amount = 0), with a value corresponding to “4096 × 44.1 / 48” as an initial value. Is repeated. For this reason, the frequency control information draws a curve close to a sine wave having a certain period and amplitude even in the phase lock state. FIG. 7 illustrates the steady fluctuation of the frequency control information. A thin line illustrates a case where the value of the correction amount Gain · ΔS is small, and a bold line illustrates a case where the value of the correction amount Gain · ΔS is large. ing. FIG. 8 illustrates a waveform represented by data after sampling frequency conversion. A thin line indicates a case where the value of the correction amount Gain · ΔS is small, and a thick line indicates a case where the value of the correction amount Gain · ΔS is large. Each is illustrated. These drawings are merely examples, and in order to prevent the illustration from becoming complicated, curves such as frequency control information when the correction amount Gain · ΔS is small and a case where the correction amount Gain · ΔS is large are shown. A difference from a curve such as frequency control information is shown in a prominent manner. As shown in FIG. 7, the greater the correction amount Gain · ΔS, the shorter the frequency control information fluctuation period and the larger the amplitude. When the frequency control information fluctuation period becomes shorter and the amplitude becomes larger, the phase error of the data after sampling frequency conversion becomes larger and the distortion becomes larger, as shown in FIG. In order to prevent such a situation from occurring, it is desirable that the value of the correction amount Gain · ΔS is small. On the other hand, when a disturbance occurs or when the device starts up, the loop gain of the PLL 80 is increased by increasing the value of the correction amount Gain · ΔS output from the conversion unit 61, and the PLL 80 is quickly phase-locked. Is preferred. For this reason, in this embodiment, two types of conversion tables are prepared, and the frequency variation of the variable frequency oscillating unit 70 is controlled by switching them at an appropriate timing. The phase lock determination circuit 51 performs this switching control.

図6は、本実施形態において2つの変換テーブルが切り替えられる様子が示されている。なお、図6において、縦軸はアップダウンカウンタ50の出力であるΔS、横軸は時間t(任意単位)である。
時刻tにおいて、ΔSの値は「4」であり、変換部61には第2変換テーブルが選択されている。この第2変換テーブルが選択されている期間は、修正量Gain・ΔSの変動幅が大きく、PLL80のループゲインは大きい。従って、PLL80は速やかにフェーズロック状態へと進む。図6においては、時刻tにおいてΔSは「3」、時刻tにおいてΔSの値は目標値である「2」、すなわち、目標位相差に相当する値に到達する。
FIG. 6 shows how two conversion tables are switched in this embodiment. In FIG. 6, the vertical axis represents ΔS which is the output of the up / down counter 50, and the horizontal axis represents time t (arbitrary unit).
At time t A , the value of ΔS is “4”, and the second conversion table is selected for the conversion unit 61. During the period in which the second conversion table is selected, the fluctuation range of the correction amount Gain · ΔS is large, and the loop gain of the PLL 80 is large. Therefore, the PLL 80 quickly proceeds to the phase lock state. In FIG. 6, [Delta] S is "3" at time t B, the value of [Delta] S at time t C is the target value "2", i.e., reaches a value corresponding to the target phase difference.

ΔSの値が「2」となると、変換部61の出力である修正量Gain・ΔSはゼロとなるから、可変周波数発振部70を制御する周波数制御情報は徐々に一定値に収束する。PLL80が定常状態に入ると、可変周波数発振部70が発生させる読み出しクロックCKRの周波数は実質的に入力クロックCkinと同じ44.1kHzとなり、FIFO10の残存データ量ΔSは、「1」と「2」の間を往復する。この状態では、FIFO10に最後に書き込まれたデータDinと、FIFO10から最後に読み出されたデータDinとの位相差の長期的な時間平均が、一定値に収束する。従って、フェーズロック判定回路51は、PLL80がフェーズロック状態にあると判定し、第1変換テーブル選択信号を変換部61に供給する。図6では時刻tにおいて、同信号が供給されている。 When the value of ΔS becomes “2”, the correction amount Gain · ΔS that is the output of the conversion unit 61 becomes zero, so that the frequency control information for controlling the variable frequency oscillation unit 70 gradually converges to a constant value. When the PLL 80 enters a steady state, the frequency of the read clock CKR generated by the variable frequency oscillating unit 70 is substantially the same as the input clock Ckin of 44.1 kHz, and the remaining data amount ΔS of the FIFO 10 is “1” and “2”. To and from between. In this state, the long-term time average of the phase difference between the data Din written last in the FIFO 10 and the data Din read last from the FIFO 10 converges to a constant value. Therefore, the phase lock determination circuit 51 determines that the PLL 80 is in the phase lock state, and supplies the first conversion table selection signal to the conversion unit 61. At time t D in FIG. 6, the signal is supplied.

変換部61は、この第1変換テーブル選択信号に基づいて変換テーブルを第1変換テーブルに変更し、当該変換テーブルに基づく修正量Gain・ΔSを出力する。第1変換テーブルにおける修正量Gain・ΔSは、第2変換テーブルにおける修正量Gain・ΔSと比べて変動幅が小さいから、PLL80におけるループフィルタ部60の周波数制御情報の変動も比較的に小さくなる。従って、可変周波数発振部70の読み出しクロックCKRも周波数の変動は小さくなり、PLL80は安定してフェーズロック状態を維持することができる。   The conversion unit 61 changes the conversion table to the first conversion table based on the first conversion table selection signal, and outputs the correction amount Gain · ΔS based on the conversion table. Since the correction amount Gain · ΔS in the first conversion table has a smaller fluctuation range than the correction amount Gain · ΔS in the second conversion table, the fluctuation of the frequency control information of the loop filter unit 60 in the PLL 80 is also relatively small. Therefore, the frequency fluctuation of the read clock CKR of the variable frequency oscillating unit 70 is also small, and the PLL 80 can stably maintain the phase lock state.

一方、突発的な要因(外乱)によって、FIFO10の残存データ量が大きく変化する場合がある。時刻tにおいては、この様な外乱によって、ΔSが再び「4」となった状態が示されている。この場合、フェーズロック判定回路51は、上述した過程と同様にPLL80によるフェーズロックが外れたと判定し、第2変換テーブル選択信号を変換部61に供給する。再び時刻tでΔSが目標値(目標位相差)に達し、時刻tにおいて、フェーズロック判定回路51によりPLL80がフェーズロックしたと判定されると、第1変換テーブル選択信号が変換部61に供給される。このように、本実施形態における非同期信号入力装置100は、フェーズロック判定回路51によって、修正量Gain・ΔSを与える変換テーブルが適切に選択されるようになっている。従って、PLL80を速やかにフェーズロックさせることができる上、そのフェーズロック状態を維持することが可能となるのである。 On the other hand, due to sudden factors (disturbances), the amount of data remaining in the FIFO 10 may change greatly. At time t E, by such a disturbance, ΔS has been shown condition that again "4". In this case, the phase lock determination circuit 51 determines that the phase lock by the PLL 80 has been released in the same manner as described above, and supplies the second conversion table selection signal to the conversion unit 61. When ΔS reaches the target value (target phase difference) again at time t F and the phase lock determination circuit 51 determines that the PLL 80 is phase locked at time t G , the first conversion table selection signal is sent to the conversion unit 61. Supplied. Thus, in the asynchronous signal input device 100 according to the present embodiment, the conversion table that gives the correction amount Gain · ΔS is appropriately selected by the phase lock determination circuit 51. Therefore, the PLL 80 can be quickly phase-locked and the phase-locked state can be maintained.

尚、変換テーブルの個数は本実施形態の態様に限定されない。変換テーブルを3種類以上用意することによって、本実施形態よりも更に詳細にFIFOのデータ量を制御しても良い。また、変換テーブルの内容も、線形、非線形を問わず、ループフィルタ部60のゲインを調整できれば如何なる態様であっても良い。   The number of conversion tables is not limited to the aspect of this embodiment. By preparing three or more types of conversion tables, the amount of FIFO data may be controlled in more detail than in the present embodiment. Moreover, the content of the conversion table may be in any form as long as the gain of the loop filter unit 60 can be adjusted regardless of whether it is linear or non-linear.

また、本実施形態において、補間部20は、2点間の直線補間によって補間処理を行っているが、高次補間、スプライン補間等、補間の態様は限定されない。これらの補間であっても良い。   In the present embodiment, the interpolation unit 20 performs interpolation processing by linear interpolation between two points, but the mode of interpolation such as high-order interpolation and spline interpolation is not limited. These interpolations may be used.

本発明の実施形態に係るサンプリング周波数変換装置のブロック図である。It is a block diagram of the sampling frequency converter which concerns on embodiment of this invention. 同装置における変換テーブルを示す図である。It is a figure which shows the conversion table in the same apparatus. 同装置における非同期信号入力装置の動作を示すタイミングチャートである。It is a timing chart which shows operation | movement of the asynchronous signal input device in the apparatus. 本発明の実施形態に係るサンプリング周波数変換装置の動作を示すタイミングチャートである。It is a timing chart which shows operation | movement of the sampling frequency converter which concerns on embodiment of this invention. 同装置における補間部20の補間処理を示す図である。It is a figure which shows the interpolation process of the interpolation part 20 in the same apparatus. 同装置におけるフェーズロック判定回路51の動作を説明する図である。It is a figure explaining operation | movement of the phase lock determination circuit 51 in the same apparatus. 同装置における周波数制御情報の定常的な揺らぎを例示する図である。It is a figure which illustrates the steady fluctuation of the frequency control information in the same device. 同装置におけるサンプリング周波数変換後のデータによって表される波形を例示する図である。It is a figure which illustrates the waveform represented by the data after sampling frequency conversion in the same apparatus.

符号の説明Explanation of symbols

10…FIFO、20…補間部、30…書き込み制御部、40…読み出し制御部、50・・・カウンタ、51…フェーズロック判定回路、60…ループフィルタ部、61…変換部、62…第1全加算器、63…第1ラッチ回路、64…セレクタ、70…可変周波数発振部(電圧制御発振器)、71…第2全加算器、72…第2ラッチ回路、80…PLL(位相同期ループ)。   DESCRIPTION OF SYMBOLS 10 ... FIFO, 20 ... Interpolation part, 30 ... Write control part, 40 ... Read control part, 50 ... Counter, 51 ... Phase lock determination circuit, 60 ... Loop filter part, 61 ... Conversion part, 62 ... 1st all Adder, 63 ... first latch circuit, 64 ... selector, 70 ... variable frequency oscillator (voltage controlled oscillator), 71 ... second full adder, 72 ... second latch circuit, 80 ... PLL (phase locked loop).

Claims (4)

記憶手段と、
第1の周波数の入力クロックに従い、入力データを前記記憶手段に書き込む書き込み制御手段と、
前記記憶手段に格納された読み出し未了の入力データの残存量を計測するデータ量計測手段と、
変換特性の異なった第1および第2の変換手段を有し、これらの変換手段のいずれかを使用することにより、前記残存量と目標値との間の誤差を修正量に変換し、該修正量に基づいて周波数制御情報を生成するループフィルタ部と、
前記残存量が前記目標値に収束したか否かを判定し、該判定結果に基づいて、前記第1または第2の変換手段の一方の使用を前記ループフィルタ部に指示する判定手段と、
第2の周波数の出力クロックに同期した読み出し信号を、前記周波数制御情報に応じた時間密度で生成する読み出し信号生成手段と、
前記読み出し信号生成手段によって生成された読み出し信号により前記記憶手段から入力データを読み出す読み出し制御手段と
を具備し、
前記第1の変換手段は、前記第2の変換手段よりも前記修正量が小さい変換手段であり、
前記判定手段は、
前記残存量が前記目標値に収束したと判定した場合には前記第1の変換手段の使用を前記ループフィルタ部に指示し、
前記残存量が前記目標値に収束していないと判定した場合には前記第2の変換手段の使用を前記ループフィルタ部に指示する
ことを特徴とする非同期信号入力装置。
Storage means;
Write control means for writing input data into the storage means in accordance with an input clock of a first frequency;
Data amount measuring means for measuring the remaining amount of unread read input data stored in the storage means;
The first and second conversion means having different conversion characteristics are provided, and by using any of these conversion means, an error between the remaining amount and the target value is converted into a correction amount, and the correction is performed. A loop filter unit that generates frequency control information based on the quantity;
Determining whether or not the remaining amount has converged to the target value, and based on the determination result, determining means for instructing the loop filter unit to use one of the first or second conversion means;
A read signal generating means for generating a read signal synchronized with the output clock of the second frequency at a time density according to the frequency control information;
Read control means for reading input data from the storage means by a read signal generated by the read signal generating means ,
The first conversion means is a conversion means having a smaller correction amount than the second conversion means,
The determination means includes
When it is determined that the remaining amount has converged to the target value, the loop filter unit is instructed to use the first conversion means,
The asynchronous signal input device, wherein when it is determined that the remaining amount has not converged to the target value, the loop filter unit is instructed to use the second conversion means .
前記判定手段は、The determination means includes
前記残存量が前記目標値を含む予め設定された範囲にない状態である場合、および前記残存量が前記範囲にない状態から前記範囲にある状態に変化した後の一定時間は、前記残存量が前記目標値に収束していないと判定し、When the remaining amount is not in a preset range including the target value, and for a certain period of time after the remaining amount is changed from a state not in the range to a state in the range, the remaining amount is It is determined that the target value has not converged,
前記残存量が前記範囲にある状態に変化した後、当該状態を前記一定時間維持した場合には、前記残存量が前記目標値に収束したと判定するAfter the remaining amount is changed to the state within the range, when the state is maintained for the predetermined time, it is determined that the remaining amount has converged to the target value.
ことを特徴とする請求項1に記載の非同期信号入力装置。The asynchronous signal input device according to claim 1.
前記第1および第2の変換手段は、
前記誤差と前記修正量との関係が非線形となるような変換特性を有する
ことを特徴とする請求項1または請求項2に記載の非同期信号入力装置。
The first and second conversion means are:
The asynchronous signal input device according to claim 1, wherein the asynchronous signal input device has a conversion characteristic such that a relationship between the error and the correction amount is nonlinear.
請求項1乃至請求項3のいずれかに記載の非同期信号入力装置と、
前記出力クロックが発生する毎に補間情報を生成する手段であり、該補間情報を、前記ループフィルタ部から生成される周波数制御情報に基づいて制御する補間情報生成手段と、
前記出力クロックの発生タイミングに対応したデータを、前記読み出し制御手段によって読み出されたデータと前記補間情報生成手段によって生成された補間情報を用いた補間演算により求める補間手段と
を具備することを特徴とするサンプリング周波数変換装置。
An asynchronous signal input device according to any one of claims 1 to 3 ,
Interpolation information generating means for generating interpolation information every time the output clock is generated, and controlling the interpolation information based on frequency control information generated from the loop filter unit;
Interpolating means for obtaining data corresponding to the generation timing of the output clock by an interpolation operation using the data read by the read control means and the interpolation information generated by the interpolation information generating means, Sampling frequency converter.
JP2003390564A 2003-11-20 2003-11-20 Asynchronous signal input device and sampling frequency converter Expired - Fee Related JP4442199B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2003390564A JP4442199B2 (en) 2003-11-20 2003-11-20 Asynchronous signal input device and sampling frequency converter

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2003390564A JP4442199B2 (en) 2003-11-20 2003-11-20 Asynchronous signal input device and sampling frequency converter

Publications (2)

Publication Number Publication Date
JP2005159407A JP2005159407A (en) 2005-06-16
JP4442199B2 true JP4442199B2 (en) 2010-03-31

Family

ID=34717898

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2003390564A Expired - Fee Related JP4442199B2 (en) 2003-11-20 2003-11-20 Asynchronous signal input device and sampling frequency converter

Country Status (1)

Country Link
JP (1) JP4442199B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108829373A (en) * 2018-05-25 2018-11-16 西安微电子技术研究所 A kind of asynchronous fifo realization circuit

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP7311287B2 (en) * 2019-03-26 2023-07-19 ミハル通信株式会社 Transmission device and transmission device control method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108829373A (en) * 2018-05-25 2018-11-16 西安微电子技术研究所 A kind of asynchronous fifo realization circuit
CN108829373B (en) * 2018-05-25 2020-08-18 西安微电子技术研究所 Asynchronous fifo realizes circuit

Also Published As

Publication number Publication date
JP2005159407A (en) 2005-06-16

Similar Documents

Publication Publication Date Title
JP4251094B2 (en) Asynchronous signal input device and sampling frequency converter
US7394884B2 (en) Synchronizing method
JP2005521322A (en) Frequency converter and usage
CN108880536A (en) Clock synthesizer with not damaged benchmark switching and frequency stability
US7471340B1 (en) Video quality adaptive variable-rate buffering method and system for stabilizing a sampled video signal
US20120054454A1 (en) Sampling frequency converter
US7414550B1 (en) Methods and systems for sample rate conversion and sample clock synchronization
JP4442199B2 (en) Asynchronous signal input device and sampling frequency converter
JPH09247156A (en) Line connection device
US6819732B1 (en) Asynchronous sample rate estimation using reciprocal frequency error minimization
US7158045B1 (en) Method and apparatus for maintaining an ideal frequency ratio between numerically-controlled frequency sources
JP4760052B2 (en) Transmission control device and sampling frequency conversion device
KR100684245B1 (en) Data transfer controller and sampling frequency converter
EP0671848B1 (en) Automatic digital frequency control circuit
EP0975094B1 (en) Synchronous control apparatus and method
JP4661284B2 (en) Transmission control device
WO2011114396A1 (en) Pll frequency synthesizer
US5339338A (en) Apparatus and method for data desynchronization
JPH0795053A (en) Frequency synchronization circuit
WO2024091966A1 (en) Asynchronous data transport
US7136004B2 (en) Image signal processing system
JP2020161986A (en) Transmission device, control method of the transmission device, clock generation device, and data interpolation device
JP2877070B2 (en) Clock generation circuit
CN102771077B (en) Digital clock regenerator
JP4735268B2 (en) Sampling frequency converter

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20060724

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090811

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20091013

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

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

R150 Certificate of patent or registration of utility model

Ref document number: 4442199

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

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20140122

Year of fee payment: 4

LAPS Cancellation because of no payment of annual fees