JP2008182494A - Sampling rate converter - Google Patents

Sampling rate converter Download PDF

Info

Publication number
JP2008182494A
JP2008182494A JP2007014479A JP2007014479A JP2008182494A JP 2008182494 A JP2008182494 A JP 2008182494A JP 2007014479 A JP2007014479 A JP 2007014479A JP 2007014479 A JP2007014479 A JP 2007014479A JP 2008182494 A JP2008182494 A JP 2008182494A
Authority
JP
Japan
Prior art keywords
frequency
sampling
measurement
ratio
sampling rate
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2007014479A
Other languages
Japanese (ja)
Inventor
Yoriko Hirose
依子 廣瀬
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.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial Co 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 Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP2007014479A priority Critical patent/JP2008182494A/en
Publication of JP2008182494A publication Critical patent/JP2008182494A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Transmission Systems Not Characterized By The Medium Used For Transmission (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a sampling rate converter for performing sampling frequency conversion by always calculating a frequency ratio of a sampling frequency of input data and output data with high accuracy without a multiplication circuit. <P>SOLUTION: The sampling rate converter for converting a first sampling frequency into a second sampling frequency has a measurement adjusting part for generating a measurement adjustment signal on the basis of a ratio between the first sampling frequency and an input clock frequency being a frequency proportional to the first sampling frequency, a frequency ratio detecting part for counting the number of pulses of an input clock inputted during a predetermined measurement period by an increment amount per pulse determined on the basis of the measurement adjustment signal to determine a frequency ratio between the first sampling frequency and the second sampling frequency, and a sampling frequency converting part for performing sampling frequency conversion of input data on the basis of the frequency ratio. <P>COPYRIGHT: (C)2008,JPO&INPIT

Description

本発明は、サンプリング・レート・コンバータに関し、特に、非同期型サンプリング・レート・コンバータに関する。   The present invention relates to sampling rate converters, and more particularly to asynchronous sampling rate converters.

従来、入力データのサンプリング・レート(標本化周波数)を、異なるサンプリング・レートを有するデータに変換する手段としてサンプリング・レート・コンバータが用いられる。非特許文献1は、非同期型のサンプリング・レート・コンバータを開示する。非同期型サンプリング・レート・コンバータは、予め定められたサンプリング・レートを有する入力データを受けて所定のサンプリング・レートを有する出力データを出力する(例えば非特許文献1参照)。そのため、非同期型サンプリング・レート・コンバータの行うサンプリング・レート変換処理(標本化周波数変換処理)においては、実際に入力される入力データのサンプリング・レートと、出力データの所定のサンプリング・レートとの比を正確に求めることが重要である。   Conventionally, a sampling rate converter is used as means for converting the sampling rate (sampling frequency) of input data into data having different sampling rates. Non-Patent Document 1 discloses an asynchronous sampling rate converter. The asynchronous sampling rate converter receives input data having a predetermined sampling rate and outputs output data having a predetermined sampling rate (see, for example, Non-Patent Document 1). Therefore, in the sampling rate conversion process (sampling frequency conversion process) performed by the asynchronous sampling rate converter, the ratio between the sampling rate of the input data that is actually input and the predetermined sampling rate of the output data It is important to calculate accurately.

非特許文献1の開示する非同期型サンプリング・レート・コンバータは、先ず、入力データのサンプリング・レートの128倍の周波数を有する入力クロックを用い、32サンプル分のデータの出力に要した周期T1を計測する。ここで、この入力クロックは、入力データとは別にサンプリング・レート・コンバータに入力されるクロック信号である。サンプリング・レート・コンバータは、順次入力される入力データおよび入力クロックを受け、周期T1の計測を上記と同様にして総計64回繰り返し、64とおりの周期T1を計測する。ここで、これら計測された64個の周期T1を、それぞれT101〜T164とする。次に、サンプリング・レート・コンバータは、上記計測で求めたT101〜T164の合計値T2(T2=T101+T102+・・・+T163+T164)と、周期T101を64倍した値T3(T3=64×T101)とを比較する。 The asynchronous sampling rate converter disclosed in Non-Patent Document 1 first measures the period T1 required to output 32 samples of data using an input clock having a frequency 128 times the sampling rate of the input data. To do. Here, this input clock is a clock signal input to the sampling rate converter separately from the input data. The sampling rate converter receives input data and an input clock that are sequentially input, repeats the measurement of the period T1 64 times in the same manner as described above, and measures 64 periods T1. Here, these 64 measured periods T1 are defined as T1 01 to T1 64 , respectively. Next, the sampling rate converter, the total value of T1 01 to T1 64 obtained in the measurement T2 and (T2 = T1 01 + T1 02 + ··· + T1 63 + T1 64), the period T1 01 64 times the value Compare with T3 (T3 = 64 × T1 01 ).

比較結果をもとに、サンプリング・レート・コンバータは、T2とT3が実質的に等しいと判断すれば、T2の値に基づいて上記サンプリング・レートの比を決定し、T2とT3が実質的に等しくないと判断すれば、T3の値に基づいて上記サンプリング・レートの比を決定する。   Based on the comparison result, if the sampling rate converter determines that T2 and T3 are substantially equal, the sampling rate ratio is determined based on the value of T2, and T2 and T3 are substantially equal to each other. If it is determined that they are not equal, the ratio of the sampling rates is determined based on the value of T3.

このような標本化周波数変換方法を用いるサンプリング・レート・コンバータにおいては、入力データのサンプリング・レートの128倍の周波数を有する入力クロックを外部から受けることができない場合、サンプリング・レート・コンバータ自らそのような周波数を有するクロック信号を発生させる。しかしながら、このクロック信号にはジッタが含まれることがあり、ジッタが含まれたクロック信号に基づく周期T1の計測は、大きな変動を含み、精度の悪いものになる。それ故、このようなサンプリング・レート・コンバータにおいては、自ずと周期T2と周期T3との比較は、精度が低く、T2とT3とが実際には実質的に一致するような場合であっても、不一致と判断されることがあった。このことは、標本化周波数変換の質を劣化させる一因であった。   In a sampling rate converter using such a sampling frequency conversion method, if an input clock having a frequency 128 times the sampling rate of the input data cannot be received from the outside, the sampling rate converter itself does so. A clock signal having a proper frequency is generated. However, jitter may be included in this clock signal, and the measurement of the period T1 based on the clock signal including the jitter includes a large variation and becomes inaccurate. Therefore, in such a sampling rate converter, the comparison between period T2 and period T3 is naturally less accurate, even if T2 and T3 actually match substantially, Sometimes it was judged as a discrepancy. This was one factor that deteriorated the quality of the sampling frequency conversion.

特許文献1に記載のサンプリング・レート・コンバータは、上記問題を解決するものであって、サンプリング・レートfsinを有する入力データを、サンプリング・レートfsoutを有する出力データに変換するものである。   The sampling rate converter described in Patent Document 1 solves the above problem, and converts input data having a sampling rate fsin into output data having a sampling rate fsout.

このサンプリング・レート・コンバータは、入力データのサンプリング・レートfsinを逓倍(逓倍操作)した周波数fsinxを有する逓倍信号を発生させるフェーズ・ロックド・ループ回路と、逓倍信号に基づいて入力データのサンプリング・レートfsinと出力データのサンプリング・レートfsoutの比fsd(周波数比)を計測し、周波数比fsdの安定度を判断し、安定している事を示すステータスフラグstflgを発生させる周波数比検出手段と、周波数比fsdと、ステータスフラグstflgに基づいてサンプリング・レート変換を行うサンプリング・レート変換部を備える。さらに、フェーズ・ロックド・ループ回路は、逓倍操作が完了していることを示す完了フラグfinflgを発生させる手段を備え、周波数比検出手段は、周波数比fsdの値の変動幅が、finflgの状態に基づいて変化する所定の値の範囲に含まれることを検出してstflgを発生させる。このような構成により、特許文献1記載のサンプリング・レート・コンバータは、逓倍信号(入力クロック)にジッタが含まれていても、高精度かつ安定に動作可能である。
特開2002−077063号公報 ラジオ技術、アイエー出版(株)、1994年5月号、p.133−144
This sampling rate converter includes a phase locked loop circuit that generates a multiplied signal having a frequency fsinx obtained by multiplying a sampling rate fsin of input data (multiplication operation), and a sampling rate of input data based on the multiplied signal. a frequency ratio detecting means for measuring a ratio fsd (frequency ratio) between the sampling rate fsout of the output data and the output data, determining the stability of the frequency ratio fsd, and generating a status flag stflg indicating that the frequency ratio is stable; A sampling rate conversion unit that performs sampling rate conversion based on the ratio fsd and the status flag stflg is provided. Further, the phase-locked loop circuit includes means for generating a completion flag finflg indicating that the multiplication operation has been completed, and the frequency ratio detecting means has a fluctuation range of the value of the frequency ratio fsd in a state of finflg. Stflg is generated by detecting that it falls within the range of a predetermined value that changes based on this. With such a configuration, the sampling rate converter described in Patent Document 1 can operate with high accuracy and stability even when jitter is included in the multiplied signal (input clock).
JP 2002-077063 A Radio Technology, AIA Publishing Co., Ltd., May 1994, p. 133-144

以上のように、非特許文献1に記載のサンプリング・レート・コンバータは、入力データの有するサンプリング・レートの128倍の周波数を有する入力クロックが存在しない場合、標本化周波数変換が上手く行えないという課題を有する。   As described above, the sampling rate converter described in Non-Patent Document 1 cannot perform sampling frequency conversion well when there is no input clock having a frequency that is 128 times the sampling rate of input data. Have

また、特許文献1に記載のサンプリング・レート・コンバータは、逓倍回路、および、逓倍回路によるジッタの影響を軽減させるための構成を具備したことで、入力データの有するサンプリング・レートの128倍の周波数を有する入力クロックを受けることができなくとも、標本化周波数変換可能である。しかし、当該サンプリング・レート・コンバータは、逓倍回路が必要であるため、サンプリング・レート・コンバータの回路規模は、比較的大きくならざるを得ない。また、入力データのサンプリング・レートが高周波側にシフトした場合、サンプリング・レート・コンバータを、さらに高速で動作させることになるが、この場合、逓倍回路で発生される逓倍信号の周波数もさらに高くなり、不要輻射や消費電力の増大を招来するという課題を有する。   In addition, the sampling rate converter described in Patent Document 1 includes a multiplier circuit and a configuration for reducing the influence of jitter caused by the multiplier circuit, so that the frequency is 128 times the sampling rate of input data. The sampling frequency can be converted even if the input clock having the signal s is not received. However, since the sampling rate converter requires a multiplication circuit, the circuit scale of the sampling rate converter must be relatively large. Also, if the sampling rate of the input data is shifted to the high frequency side, the sampling rate converter will be operated at a higher speed, but in this case, the frequency of the multiplication signal generated by the multiplication circuit will be higher. There is a problem in that unnecessary radiation and power consumption increase.

上記課題を鑑み、本発明は、構成が簡単で、かつ、高速動作させた場合でも不要輻射や消費電力の増大を招かずに精度よくサンプリング・レートの変換が可能なサンプリング・レート・コンバータを提供することを目的とする。   In view of the above problems, the present invention provides a sampling rate converter that has a simple configuration and can accurately convert a sampling rate without causing unnecessary radiation and an increase in power consumption even when operated at high speed. The purpose is to do.

本発明は、その一態様において、第1の標本化周波数を有する入力データを、第2の標本化周波数を有する出力データに変換する非同期型サンプリング・レート・コンバータであって、第1の標本化周波数と、第1の標本化周波数に比例した周波数である入力クロック周波数との比に基づいて測定調整信号を生成する、測定調整部と、測定調整信号と、入力クロック周波数を有する入力クロックと、第2の標本化周波数を有する出力クロックと、を受け、所定の測定期間に入力される入力クロックのパルスの数を、測定調整信号に基づいて定まる1パルス当たりのインクリメント量でカウントし、第1の標本化周波数と、第2の標本化周波数の周波数比を決定する、周波数比検出部と、周波数比に基づいて、入力データの標本化周波数変換を行うサンプリング周波数変換部と、を有するサンプリング・レート・コンバータである。   In one aspect thereof, the present invention is an asynchronous sampling rate converter for converting input data having a first sampling frequency into output data having a second sampling frequency, the first sampling frequency A measurement adjustment unit that generates a measurement adjustment signal based on a ratio of the frequency and an input clock frequency that is proportional to the first sampling frequency; a measurement adjustment signal; an input clock having an input clock frequency; Receiving an output clock having a second sampling frequency, and counting the number of pulses of the input clock input during a predetermined measurement period by an increment per pulse determined based on the measurement adjustment signal; A frequency ratio detector for determining a frequency ratio between the sampling frequency of the second sampling frequency and the second sampling frequency, and sampling frequency conversion of the input data based on the frequency ratio Cormorant a sampling frequency converter, the sampling rate converter having.

本発明の一態様においては、さらに、第1の標本化周波数と、入力クロック周波数との比に基づいて検出精度調整信号を生成する、検出精度調整部を有し、周波数比検出部は、検出精度調整信号に基づいて測定期間の長さを変更することが好ましい。   In one aspect of the present invention, a detection accuracy adjustment unit that generates a detection accuracy adjustment signal based on a ratio between the first sampling frequency and the input clock frequency is further included. It is preferable to change the length of the measurement period based on the accuracy adjustment signal.

本発明の一態様においては、前記検出精度調整部は、検出精度調整信号を、測定調整信号に応じて変化させることが好ましい。   In one aspect of the present invention, it is preferable that the detection accuracy adjustment unit changes the detection accuracy adjustment signal according to the measurement adjustment signal.

本発明の一態様においては、測定期間の長さは、インクリメント量に比例することが好ましい。   In one embodiment of the present invention, the length of the measurement period is preferably proportional to the increment amount.

本発明の一態様においては、さらに、周波数比の安定性を示すステータスフラグを生成するステータスフラグ生成部を有し、ステータスフラグ生成部は、周波数比とその周波数比よりも以前に測定された周波数比とに基づいて、周波数比の安定性を判定し、ステータスフラグを生成し、サンプリング周波数変換部は、ステータスフラグの状態に基づいて、入力データの標本化周波数変換を開始することが好ましい。   In one aspect of the present invention, the information processing apparatus further includes a status flag generation unit that generates a status flag indicating the stability of the frequency ratio, and the status flag generation unit includes the frequency ratio and the frequency measured before the frequency ratio. Preferably, the stability of the frequency ratio is determined based on the ratio and a status flag is generated, and the sampling frequency converter starts sampling frequency conversion of the input data based on the status flag state.

本発明にかかるサンプリング・レート・コンバータは、従来のサンプリング・レート・コンバータのように、逓倍回路を必要としない。よって、サンプリング・レート・コンバータにかかる回路規模を従来よりも小さくすることができる。   The sampling rate converter according to the present invention does not require a multiplier circuit unlike the conventional sampling rate converter. Therefore, the circuit scale concerning a sampling rate converter can be made smaller than before.

また、本発明にかかるサンプリング・レート・コンバータは、入力データのサンプリング・レートとの比較において入力クロックの周波数が従来ほどに高くない場合であっても、入力データのサンプリング・レートと出力データの有するサンプリング・レートとの周波数比を、従来のサンプリング・レート・コンバータと同様に求めることができる。よって、本発明にかかるサンプリング・レート・コンバータは、小さな回路規模で、従来と同様の標本化周波数変換を実行することができる。   Further, the sampling rate converter according to the present invention has the sampling rate of the input data and the output data even when the frequency of the input clock is not as high as in the conventional case in comparison with the sampling rate of the input data. The frequency ratio to the sampling rate can be obtained in the same manner as in the conventional sampling rate converter. Therefore, the sampling rate converter according to the present invention can execute the sampling frequency conversion similar to the conventional one with a small circuit scale.

さらに、本発明にかかるサンプリング・レート・コンバータは、入力データのサンプリング・レートが高周波側にシフトした場合であっても、従来よりも低い動作クロックで、従来と同様の標本化周波数変換を実行することができる。よって、本発明にかかるサンプリング・レート・コンバータは、従来に較べ不要輻射や消費電力の低減が可能である。   Furthermore, the sampling rate converter according to the present invention performs the same sampling frequency conversion with the operation clock lower than the conventional one even when the sampling rate of the input data is shifted to the high frequency side. be able to. Therefore, the sampling rate converter according to the present invention can reduce unnecessary radiation and power consumption as compared with the conventional case.

以下、図面を参照し、本発明にかかる好適な実施形態によるサンプリング・レート・コンバータの例について説明する。   Hereinafter, an example of a sampling rate converter according to a preferred embodiment of the present invention will be described with reference to the drawings.

(第1の実施形態)
図1は、本発明にかかる第1の実施形態によるサンプリング・レート・コンバータ1aの構成を示すブロック図である。本実施形態のサンプリング・レート・コンバータ1aは、周波数比の測定における、入力された入力クロックのパルス数の計数において、入力データのサンプリング・レートと入力クロックの周波数の比に基づいて、1パルスの入力クロックの入力に対して計数値へ加算するインクリメント量を変化させる。
(First embodiment)
FIG. 1 is a block diagram showing a configuration of a sampling rate converter 1a according to the first embodiment of the present invention. The sampling rate converter 1a of the present embodiment is configured to count one pulse based on the ratio of the sampling rate of the input data and the frequency of the input clock in counting the number of pulses of the input clock input in the measurement of the frequency ratio. The increment to be added to the count value is changed with respect to the input clock.

サンプリング・レート・コンバータ1aは、コントローラ2aと接続される。また、コントローラ2aは、標本化データ出力器3とも接続され、サンプリング・レート・コンバータ1aおよび標本化データ出力器3を制御する。逆に、標本化データ出力器3が出力する入力クロックに関する情報をコントローラ2aに伝える手段がある場合、コントローラ2aは、必ずしも標本化データ出力器3を制御する必要はない。   Sampling rate converter 1a is connected to controller 2a. The controller 2a is also connected to the sampled data output unit 3, and controls the sampling rate converter 1a and the sampled data output unit 3. Conversely, if there is a means for transmitting information related to the input clock output by the sampled data output unit 3 to the controller 2a, the controller 2a does not necessarily need to control the sampled data output unit 3.

コントローラ2aによる標本化データ出力器3の制御には、第1制御信号が用いられ、サンプリング・レート・コンバータ1aの制御には、第2制御信号が用いられる。第1制御信号および第2制御信号に含まれる情報の詳細については後述する。ここで、標本化データ出力器3は、例えば、コンパクト・ディスク・プレーヤ(CDプレーヤ)でよい。この場合、サンプリング・レート・コンバータ1aに対する入力データは、デジタル・オーディオ・データである。標本化データ出力器3は、デジタル信号用インターフェース(図示せず。)を介して、入力データおよび入力クロックをサンプリング・レート・コンバータ1aに対して出力する。   The first control signal is used for controlling the sampling data output device 3 by the controller 2a, and the second control signal is used for controlling the sampling rate converter 1a. Details of the information included in the first control signal and the second control signal will be described later. Here, the sampled data output device 3 may be, for example, a compact disc player (CD player). In this case, the input data to the sampling rate converter 1a is digital audio data. The sampled data output unit 3 outputs input data and an input clock to the sampling rate converter 1a via a digital signal interface (not shown).

さらに、サンプリング・レート・コンバータ1aは、出力クロックを生成するクロック生成部(CLK)11と接続され、クロック生成部(CLK)11は、サンプリング・レート・コンバータ1aに、所定の第2のサンプリング・レート(第2標本化周波数)を入力する。   Further, the sampling rate converter 1a is connected to a clock generation unit (CLK) 11 that generates an output clock, and the clock generation unit (CLK) 11 sends a predetermined second sampling signal to the sampling rate converter 1a. Enter the rate (second sampling frequency).

サンプリング・レート・コンバータ1aは、第1のサンプリング・レート(第1標本化周波数)を有する入力データを入力し、標本化周波数変換(サンプリング周波数変換)し、所定の第2のサンプリング・レート(第2標本化周波数)を有する出力データを出力するサンプリング周波数変換部5と、入力データのサンプリング・レート(第1標本化周波数)と、出力データのサンプリング・レート(第2標本化周波数)との比を測定し、周波数比検出データ、および、測定された周波数比検出データに基づいて入力データの入力状態の安定・不安定を示すステータスフラグをサンプリング周波数変換部5に対して出力する周波数比検出データ出力部10aとを有する。   The sampling rate converter 1a receives input data having a first sampling rate (first sampling frequency), performs sampling frequency conversion (sampling frequency conversion), and outputs a predetermined second sampling rate (first sampling frequency). The ratio of the sampling frequency converter 5 that outputs output data having two sampling frequencies), the sampling rate of the input data (first sampling frequency), and the sampling rate of the output data (second sampling frequency) Frequency ratio detection data, and output a status flag indicating the stability / instability of the input state of the input data to the sampling frequency converter 5 based on the measured frequency ratio detection data And an output unit 10a.

周波数比検出データ出力部10aは、第2制御信号と入力クロックを受けて、入力クロック1パルス当たりのインクリメント量を示す測定調整信号を出力する測定調整部13aと、入力クロック、出力クロック、および、測定調整信号を受けて周波数比検出データを出力する周波数比検出部15aと、周波数比検出データを受けてステータスフラグを生成し出力するステータスフラグ生成部30とを備える。   The frequency ratio detection data output unit 10a receives the second control signal and the input clock, outputs a measurement adjustment signal indicating an increment amount per pulse of the input clock, an input clock, an output clock, and A frequency ratio detection unit 15a that receives the measurement adjustment signal and outputs the frequency ratio detection data, and a status flag generation unit 30 that receives the frequency ratio detection data and generates and outputs a status flag.

周波数比検出部15aは、出力クロックのパルスを計数し、測定期間の始期および周期を周波数比測定部153に通知する出力クロック計数部151a、および、入力データと出力データの周波数比を測定して周波数比検出データを生成し出力する周波数比測定部153を含む。   The frequency ratio detection unit 15a counts the pulses of the output clock, measures the frequency ratio between the input data and the output data, and the output clock counting unit 151a that notifies the start and period of the measurement period to the frequency ratio measurement unit 153. A frequency ratio measurement unit 153 that generates and outputs frequency ratio detection data is included.

ステータスフラグ生成部30は、周波数比検出データをバッファリングし、所定期間の後、当該周波数比検出データを、遅延された周波数比検出データとして出力する遅延部33、および、周波数比検出データと遅延された周波数比検出データとを比較し、当該比較に基づいてステータスフラグを生成し出力するデータ比較部31を含む。   The status flag generation unit 30 buffers the frequency ratio detection data, and outputs the frequency ratio detection data as delayed frequency ratio detection data after a predetermined period, and the frequency ratio detection data and delay A data comparison unit 31 that compares the detected frequency ratio detection data and generates and outputs a status flag based on the comparison.

以下、第1の実施形態によるサンプリング・レート・コンバータ1aの動作について説明する。説明においては、第1標本化周波数(入力データのサンプリング・レート)を、fsinとする。また、入力クロックの周波数を、fxinとする。また、第2標本化周波数(出力データのサンプリング・レート)を、fsoutとし、出力クロックの周波数をfxoutとする。fsoutおよびfxoutは、予め設定された値である。   The operation of the sampling rate converter 1a according to the first embodiment will be described below. In the description, the first sampling frequency (sampling rate of input data) is assumed to be fsin. The frequency of the input clock is fxin. The second sampling frequency (sampling rate of output data) is fsout, and the frequency of the output clock is fxout. fsout and fxout are preset values.

コントローラ2aは、第1標本化周波数fsinと入力クロック周波数fxinに関する情報を含む第2制御信号を、サンプリング・レート・コンバータ1aに出力する。また、標本化データ出力器3が出力する入力クロックに関する情報をコントローラ2aに伝える手段がある場合、この情報に基づいて、第1標本化周波数fsinと入力クロック周波数fxinに関する情報を含む第2制御信号を生成し、サンプリング・レート・コンバータ1aに出力する。この情報は、入力クロック周波数fxinの第1標本化周波数fsinに対する倍率の情報でもよい。   The controller 2a outputs a second control signal including information on the first sampling frequency fsin and the input clock frequency fxin to the sampling rate converter 1a. Further, when there is means for transmitting information related to the input clock output from the sampling data output device 3 to the controller 2a, a second control signal including information related to the first sampling frequency fsin and the input clock frequency fxin is based on this information. Is output to the sampling rate converter 1a. This information may be information on the magnification of the input clock frequency fxin with respect to the first sampling frequency fsin.

同時に、コントローラ2aは、第1制御信号を用いて、標本化データ出力器3に対し、第1標本化周波数fsinで入力データを、周波数fxinで入力クロックを出力するように指示する。コントローラ2aから指示を受けた標本化データ出力器3は、サンプリング・レートfsinを有する入力データと、例えばfsinの32倍の周波数fxin(fxin=32×fsin)を有する入力クロックとをサンプリング・レート・コンバータ1aに対して出力する。   At the same time, the controller 2a instructs the sampling data output device 3 to output the input data at the first sampling frequency fsin and the input clock at the frequency fxin using the first control signal. Upon receiving an instruction from the controller 2a, the sampling data output unit 3 receives input data having a sampling rate fsin and an input clock having a frequency fxin (fxin = 32 × fsin) that is 32 times fsin, for example. Output to the converter 1a.

逆に、標本化データ出力器3が出力する入力クロックに関する情報をコントローラ2aに伝える手段がある場合、標本化データ出力器3は、サンプリング・レートfsinを有する入力データと、例えばfsinの32倍の周波数fxin(fxin=32×fsin)を有する入力クロックとをサンプリング・レート・コンバータ1aに対して出力し、周波数fxinで入力クロックを出力した事をコントローラ2aに指示する。   On the contrary, when there is a means for transmitting information related to the input clock output by the sampled data output unit 3 to the controller 2a, the sampled data output unit 3 is provided with input data having a sampling rate fsin and, for example, 32 times fsin. An input clock having the frequency fxin (fxin = 32 × fsin) is output to the sampling rate converter 1a, and the controller 2a is instructed that the input clock is output at the frequency fxin.

測定調整部13aは、デコード回路で構成することができる。測定調整部13aは、受け取った第1標本化周波数fsinと入力クロック周波数fxinに関する情報に基づき、測定調整信号を生成して周波数比検出部15aに対して出力する。測定調整信号は、周波数比測定部153における入力クロックのパルスの計数において、1パルスあたりカウントアップするインクリメント量を示す信号である。周波数比測定部153は、測定調整信号に示されるインクリメント量で、入力クロックの計数を行う。例えば、周波数比測定部153に入力される測定調整信号が、インクリメント量「2」を示す場合、周波数比測定部153は、入力されたパルス1つについて、計数値を2つ増加させる。この測定調整信号は、第1標本化周波数fsinと入力クロック周波数fxinとの比に応じて異なる値をとるように生成されればよい。入力クロック周波数fxinが、第1標本化周波数fsinに対して32倍の周波数を有する場合、測定調整部13aは、その「32」の、予め定めた基準値(例えば64)に対する比を求め、測定調整信号として「2」を周波数比検出部15aの周波数比測定部153に出力する。このように、測定調整信号は、入力クロック周波数fxinの第1標本化周波数fsinに対する比(倍率)と、基準値(ここでは、64)との比に基づいて決定されればよい。すなわち、測定調整部13aは、コントローラ2aの出力する第2制御信号から、入力クロック周波数fxinの第1標本化周波数fsinに対する比の情報を取得し、それに基づいて測定調整信号を出力する。なお、この基準値は、任意の値でよい。基準値は、例えば、入力クロック周波数fxinの第1標本化周波数fsinに対する倍率として一般的に望ましい値でよい。このとき、測定調整信号は、一般的に望ましいと考えられる、入力クロックの周波数の入力データの標本化周波数に対する倍率と、実際に用いられる入力クロック周波数fxinの第1標本化周波数fsinに対する倍率との比を示す値となる。   The measurement adjustment unit 13a can be configured by a decode circuit. The measurement adjustment unit 13a generates a measurement adjustment signal based on the received information regarding the first sampling frequency fsin and the input clock frequency fxin, and outputs the measurement adjustment signal to the frequency ratio detection unit 15a. The measurement adjustment signal is a signal indicating an increment amount to be counted up per pulse in counting the pulses of the input clock in the frequency ratio measuring unit 153. The frequency ratio measurement unit 153 counts the input clock with the increment amount indicated by the measurement adjustment signal. For example, when the measurement adjustment signal input to the frequency ratio measurement unit 153 indicates the increment amount “2”, the frequency ratio measurement unit 153 increases the count value by two for one input pulse. The measurement adjustment signal may be generated so as to have a different value depending on the ratio between the first sampling frequency fsin and the input clock frequency fxin. When the input clock frequency fxin has a frequency 32 times the first sampling frequency fsin, the measurement adjustment unit 13a calculates the ratio of “32” with respect to a predetermined reference value (for example, 64) and performs measurement. “2” is output as the adjustment signal to the frequency ratio measuring unit 153 of the frequency ratio detecting unit 15a. As described above, the measurement adjustment signal may be determined based on the ratio of the ratio (magnification) of the input clock frequency fxin to the first sampling frequency fsin and the reference value (here, 64). That is, the measurement adjustment unit 13a acquires information on the ratio of the input clock frequency fxin to the first sampling frequency fsin from the second control signal output from the controller 2a, and outputs a measurement adjustment signal based on the acquired information. The reference value may be an arbitrary value. For example, the reference value may be a generally desirable value as a magnification of the input clock frequency fxin with respect to the first sampling frequency fsin. At this time, the measurement adjustment signal is obtained by multiplying the frequency of the input clock with respect to the sampling frequency of the input data and the magnification of the actually used input clock frequency fxin with respect to the first sampling frequency fsin. A value indicating the ratio.

周波数比検出部15aは、入力クロック、出力クロック、および、測定調整信号を用いて、サンプリング・レート・コンバータ1aに入力される入力データのサンプリング・レート(第1標本化周波数)と、出力データのサンプリング・レート(所定の第2標本化周波数)との周波数比を求める。   The frequency ratio detection unit 15a uses the input clock, the output clock, and the measurement adjustment signal to input the sampling rate (first sampling frequency) of the input data input to the sampling rate converter 1a and the output data. A frequency ratio with the sampling rate (predetermined second sampling frequency) is obtained.

具体的には、周波数比検出部15aは、出力クロックのパルスが所定数入力される間(測定期間)に入力される入力クロックのパルス数を計数し、計数値を周波数比(測定値)とする。例えば、出力クロックの周期(fxoutの逆数)の所定倍(例えば、2048倍)に等しい測定期間に入力された入力クロックのパルス数を測定(計数)する。   Specifically, the frequency ratio detection unit 15a counts the number of pulses of the input clock that are input while a predetermined number of pulses of the output clock are input (measurement period), and uses the count value as the frequency ratio (measurement value). To do. For example, the number of pulses of the input clock input during a measurement period equal to a predetermined multiple (for example, 2048 times) of the output clock period (the reciprocal of fxout) is measured (counted).

出力クロック計数部151aは、出力クロックのパルスを2048個カウントする毎に、周波数比測定部153に、測定期間の終了を示す出力を行い、周波数比測定部153は、当該出力の間に含まれる入力クロックのパルス数を、測定調整信号を参照しながら、計数(カウントアップ)する。つまり、このとき、測定調整信号は、カウントアップにおける入力パルス1パルス当たりのインクリメント量を定める情報として用いられる。例えば、測定調整信号が「2」であれば、周波数比測定部153は、実際に受けた入力クロックのパルス数の2倍に等しい値を、計数値とする。   Each time the output clock counting unit 151a counts 2048 pulses of the output clock, the output clock counting unit 151a outputs to the frequency ratio measuring unit 153 the end of the measurement period, and the frequency ratio measuring unit 153 is included between the outputs. The number of pulses of the input clock is counted (counted up) while referring to the measurement adjustment signal. That is, at this time, the measurement adjustment signal is used as information for determining the increment amount per one input pulse in the count-up. For example, if the measurement adjustment signal is “2”, the frequency ratio measurement unit 153 sets a value equal to twice the number of pulses of the input clock actually received as the count value.

周波数比測定部153は、計数値と、測定した期間に受けた出力クロックのパルス数(この場合、2048)との比を求めることによって周波数比を求める。   The frequency ratio measuring unit 153 obtains the frequency ratio by obtaining the ratio between the count value and the number of pulses of the output clock received in the measured period (in this case, 2048).

このようにして得られた周波数比は、周波数比検出データNとしてサンプリング周波数変換部5およびステータスフラグ生成部30に送られる。ステータスフラグ生成部30の遅延部33は、直前の測定期間の測定値(直前に測定された周波数比検出データ)を保持している。遅延部33は、保持するデータを、適切なタイミングで、データ比較部31に対し遅延された周波数比検出データNzとして出力することができる。   The frequency ratio thus obtained is sent to the sampling frequency conversion unit 5 and the status flag generation unit 30 as frequency ratio detection data N. The delay unit 33 of the status flag generation unit 30 holds a measurement value (frequency ratio detection data measured immediately before) in the immediately previous measurement period. The delay unit 33 can output the held data as frequency ratio detection data Nz delayed to the data comparison unit 31 at an appropriate timing.

ステータスフラグ生成部30は、そのデータ比較部31において、1つ前の測定期間に受けて遅延部33によって遅延された周波数比検出データNzと、周波数比検出データNとを比較する。ただし、遅延された周波数比検出データNzの測定されたタイミングは、直前の測定期間に限らない。2測定期間以上前に測定された周波数比検出データを遅延された周波数比検出データとして用いてもよい。データ比較部31は、両データの差が、所定の値域に含まれる場合、入力されている入力データのサンプリング・レート(第1標本化周波数)が安定していると判断し、安定を示すステータス・フラグ(たとえば、「1」)をサンプリング周波数変換部5に出力する。   In the data comparison unit 31, the status flag generation unit 30 compares the frequency ratio detection data Nz received by the delay unit 33 in the previous measurement period with the frequency ratio detection data N. However, the measured timing of the delayed frequency ratio detection data Nz is not limited to the immediately preceding measurement period. You may use the frequency ratio detection data measured before 2 measurement periods or more as delayed frequency ratio detection data. When the difference between the two data is included in the predetermined range, the data comparison unit 31 determines that the sampling rate (first sampling frequency) of the input data being input is stable, and indicates a status indicating stability. The flag (for example, “1”) is output to the sampling frequency converter 5.

サンプリング周波数変換部5は、入力されるステータスフラグを監視し、ステータスフラグが「1」(安定)になると、別途入力される周波数比検出データNに基づく標本化周波数変換を開始する。そして、入力データは、周波数比検出データNに基づいて、第2標本化周波数を有する出力データに変換され、出力される。   The sampling frequency conversion unit 5 monitors the input status flag. When the status flag becomes “1” (stable), the sampling frequency conversion unit 5 starts sampling frequency conversion based on the separately input frequency ratio detection data N. Then, the input data is converted to output data having the second sampling frequency based on the frequency ratio detection data N, and is output.

図2は、測定調整部13の詳細を示すブロック図である。測定調整部13は、第2制御信号に含まれる第1標本化周波数fsinおよび入力クロック周波数fxinに関する情報と入力クロックとを受けるセレクタ部131と、同じく第1標本化周波数fsinおよび入力クロック周波数fxinに関する情報と入力クロックとを受ける測定微調整部133と、セレクタ部131および測定微調整部133の出力を加算する加算器135とを含む。セレクタ部131は、第2制御信号に基づいて測定制御主信号を生成し加算器135に出力する。測定微調整部133は、セレクタ部131の出力する測定制御主信号だけでは、測定制御信号を上手く生成できない場合に、測定制御主信号に加算して望ましい測定制御信号を生成するように測定制御副信号を、加算器135に対し、入力クロックに同期して出力する。セレクタ部131および測定微調整部133は、それぞれ測定制御主信号および測定制御副信号を生成するために、入力に対して出力を決定する参照テーブルを有する。   FIG. 2 is a block diagram showing details of the measurement adjustment unit 13. The measurement adjustment unit 13 receives a selector 131 that receives information about the first sampling frequency fsin and the input clock frequency fxin included in the second control signal and the input clock, and also relates to the first sampling frequency fsin and the input clock frequency fxin. A measurement fine adjustment unit 133 that receives information and an input clock, and an adder 135 that adds the outputs of the selector unit 131 and the measurement fine adjustment unit 133 are included. The selector unit 131 generates a measurement control main signal based on the second control signal and outputs it to the adder 135. The measurement fine adjustment unit 133 adds the measurement control main signal to the measurement control main signal when the measurement control main signal output from the selector unit 131 alone is not sufficient to generate the desired measurement control signal. The signal is output to the adder 135 in synchronization with the input clock. The selector unit 131 and the measurement fine adjustment unit 133 have a reference table for determining an output with respect to an input in order to generate a measurement control main signal and a measurement control sub signal, respectively.

セレクタ部131および測定微調整部133にそれぞれ含まれる参照テーブルの構成について説明する。基準値と入力クロック周波数fxinの第1標本化周波数fsinに対する比との比(この比を「対基準値比」と称する。)は、必ずしも整数値とは限らない。これに対し、インクリメント量は、整数値であることが望ましい。そこで、測定調整部13は、対基準値比の整数部を測定制御主信号で構成し、対基準値比の小数部を測定制御副信号で構成することによって、測定制御信号を生成する。セレクタ部131の参照テーブルは、対基準値比の整数部の値を、測定制御主信号の値に対応付け、セレクタ部131は、整数部の値に等しい値を測定制御主信号として、加算器135に出力する。測定微調整部133は、周期的に値が変化する測定制御副信号を入力クロックと同期して出力することができる。測定微調整部133の参照テーブルは、対基準値比の小数部の値を、測定制御副信号の周期および各周期における出力パターンに対応付ける。出力パターンは、測定制御副信号の値の一周期分の合計値と、その一周期に入力される入力クロックのパルス数との比が、対基準値比の小数部の値に等しくなるように決定される。そして、測定微調整部133は、得られた周期および出力パターンを有する測定制御副信号を出力する。   The configuration of the reference table included in each of the selector unit 131 and the measurement fine adjustment unit 133 will be described. The ratio between the reference value and the ratio of the input clock frequency fxin to the first sampling frequency fsin (this ratio is referred to as “reference value ratio”) is not necessarily an integer value. On the other hand, the increment amount is desirably an integer value. Therefore, the measurement adjustment unit 13 generates the measurement control signal by configuring the integer part of the reference value ratio with the measurement control main signal and configuring the fractional part of the reference value ratio with the measurement control subsignal. The reference table of the selector unit 131 associates the value of the integer part of the reference value ratio with the value of the measurement control main signal, and the selector unit 131 uses the value equal to the value of the integer part as the measurement control main signal. It outputs to 135. The measurement fine adjustment unit 133 can output a measurement control sub-signal whose value periodically changes in synchronization with the input clock. The reference table of the measurement fine adjustment unit 133 associates the value of the decimal part of the reference value ratio with the period of the measurement control sub-signal and the output pattern in each period. The output pattern is such that the ratio between the total value for one period of the measurement control sub-signal value and the number of pulses of the input clock input in that period is equal to the value of the fractional part of the reference value ratio. It is determined. And the measurement fine adjustment part 133 outputs the measurement control subsignal which has the obtained period and output pattern.

具体例を挙げ、測定調整部13の動作を説明する。セレクタ部131および測定微調整部133はそれぞれ、第2制御信号に含まれる第1標本化周波数fsinおよび入力クロック周波数fxinに関する情報を参照する。なお、セレクタ部131および測定微調整部133に入力される情報は、入力クロック周波数fxinと第1標本化周波数fsinとの比の情報を含めば足りる。この情報を参照することにより、例えば、入力クロック周波数fxinが、第1標本化周波数fsinの8倍であると判明したとする。このとき、対基準値比は、「8.0」である。セレクタ部131は、参照テーブルを参照し、この「8.0」の整数部「8」に対応する測定制御主信号を決定する。また、測定微調整部133も、別の参照テーブルを参照し、「8.0」の小数部「0」に対応する測定制御副信号を決定する。このとき測定制御副信号は、常に0となる。この場合、入力クロック周波数が第1標本化周波数の64倍である場合と比較すれば、同一期間に含まれる入力クロックのパルス数は、8分の1である。そこで、セレクタ部131および測定微調整部133は参照テーブルを参照し、周波数比測定部153に入力クロックのパルスが1つ入力される度に、常に、8ずつ計数値が増加するように、インクリメント量「8」を示す測定調整信号を構成する測定調整主信号および測定調整副信号をそれぞれ出力する。   A specific example is given and operation | movement of the measurement adjustment part 13 is demonstrated. The selector unit 131 and the measurement fine adjustment unit 133 refer to information on the first sampling frequency fsin and the input clock frequency fxin included in the second control signal, respectively. Note that the information input to the selector unit 131 and the measurement fine adjustment unit 133 may include information on the ratio between the input clock frequency fxin and the first sampling frequency fsin. By referring to this information, for example, it is assumed that the input clock frequency fxin is 8 times the first sampling frequency fsin. At this time, the ratio to the reference value is “8.0”. The selector 131 refers to the reference table and determines the measurement control main signal corresponding to the integer part “8” of “8.0”. The measurement fine adjustment unit 133 also refers to another reference table and determines a measurement control sub-signal corresponding to the decimal part “0” of “8.0”. At this time, the measurement control sub-signal is always 0. In this case, compared with the case where the input clock frequency is 64 times the first sampling frequency, the number of pulses of the input clock included in the same period is 1/8. Therefore, the selector 131 and the measurement fine adjustment unit 133 refer to the reference table and increment the count value so that the count value always increases by 8 each time one input clock pulse is input to the frequency ratio measurement unit 153. A measurement adjustment main signal and a measurement adjustment sub-signal constituting the measurement adjustment signal indicating the quantity “8” are respectively output.

セレクタ部131は、値8を測定調整主信号として加算器135に出力し、測定微調整部133は常に値0を測定制御副信号として加算器135に出力する。よって、加算器135は、測定調整信号として、常に値8を出力する。周波数比検出部15aは、値8の測定調整信号を受けて入力クロックのパルス1つにつき、8ずつカウントアップする。   The selector 131 outputs the value 8 to the adder 135 as a measurement adjustment main signal, and the measurement fine adjustment unit 133 always outputs the value 0 to the adder 135 as a measurement control sub-signal. Therefore, the adder 135 always outputs the value 8 as the measurement adjustment signal. The frequency ratio detection unit 15a receives the measurement adjustment signal of value 8 and counts up by 8 for each pulse of the input clock.

また、上記参照により、例えば、入力クロックの周波数fxinが、第1標本化周波数fsinの48倍であると判明したとする。このとき、対基準値比は、「1.33(4/3)」である。セレクタ部131は、参照テーブルを参照し、この「1.33(4/3)」の整数部「1」に対応する測定制御主信号を決定する。また、測定微調整部133も、別の参照テーブルを参照し、「1.33(4/3)」の小数部「0.33(1/3)」に対応する測定制御副信号を決定する。このとき、測定制御副信号は、入力クロックの周期に同期して0と1とを(0、1、0、0、1、0、・・・)となるように繰り返すような出力パターンで出力される。この場合、入力クロック周波数が第1標本化周波数の64倍である場合と比較すれば、同一期間に含まれる入力クロックのパルス数は、4分の3である。この場合、セレクタ部131および測定微調整部133は参照テーブルを参照し、周波数比測定部153に入力クロックの1パルスが入力される度に、1.33(4/3)だけ計数値が増加するように、測定調整信号を構成する測定調整主信号および測定調整副信号をそれぞれ出力することが望まれる。しかしながら、インクリメント量は、整数値が好ましい。そこで、セレクタ部131および測定微調整部133は、ある入力クロックの周期において入力されたパルスは、インクリメント量「1」で計数され、その次の入力クロックの周期において入力されたパルスは、インクリメント量「2」で計数されるように、さらにその次の入力クロックの周期において入力されたパルスは、インクリメント量「2」で計数されるように、入力クロックの周期と同期してインクリメント量「1」と「2」が(1、2、1、1、2、1、・・・)となるように、測定調整主信号および測定調整副信号をそれぞれ出力する。こうすることで、例えば、入力クロックのパルスが、48個入力された場合、その計数値を「64」とすることができる。   Further, for example, it is assumed that the frequency fxin of the input clock is found to be 48 times the first sampling frequency fsin by the above reference. At this time, the ratio to the reference value is “1.33 (4/3)”. The selector 131 refers to the reference table, and determines the measurement control main signal corresponding to the integer part “1” of “1.33 (4/3)”. The measurement fine adjustment unit 133 also refers to another reference table and determines a measurement control sub-signal corresponding to the decimal part “0.33 (1/3)” of “1.33 (4/3)”. . At this time, the measurement control sub-signal is output in an output pattern that repeats 0 and 1 (0, 1, 0, 0, 1, 0,...) In synchronization with the cycle of the input clock. Is done. In this case, compared with the case where the input clock frequency is 64 times the first sampling frequency, the number of pulses of the input clock included in the same period is 3/4. In this case, the selector 131 and the measurement fine adjustment unit 133 refer to the reference table, and the count value increases by 1.33 (4/3) every time one pulse of the input clock is input to the frequency ratio measurement unit 153. As described above, it is desirable to output the measurement adjustment main signal and the measurement adjustment sub-signal that constitute the measurement adjustment signal. However, the increment amount is preferably an integer value. Therefore, the selector 131 and the measurement fine adjustment unit 133 count the pulses input in a certain input clock cycle by the increment amount “1”, and the pulses input in the next input clock cycle The pulses input in the next input clock cycle as counted by “2” are incremented by “1” in synchronization with the cycle of the input clock so as to be counted by increment amount “2”. And “2” are (1, 2, 1, 1, 2, 1,...), The measurement adjustment main signal and the measurement adjustment sub-signal are respectively output. In this way, for example, when 48 input clock pulses are input, the count value can be set to “64”.

周波数比検出部15aは、値1の測定調整信号を受けて、入力クロックのパルス1つにつき、1ずつカウントアップし、次の入力クロックのパルスを受けるときは、値2を示す測定調整信号を受けて、入力クロックのパルス1つにつき、2ずつカウントアップする。   The frequency ratio detector 15a receives the measurement adjustment signal of value 1, counts up by one for each pulse of the input clock, and receives the measurement adjustment signal indicating value 2 when receiving the next input clock pulse. In response, each input clock pulse counts up by two.

このように、周波数比検出部15aは、測定調整信号に基づいて、入力クロックのパルス1つに対してカウントアップする量(インクリメント量)を変化させて周波数比を測定する。そのため、入力クロックの周波数fxinの第1標本化周波数fsinに対する倍率が、一般的な倍率(例えば64倍)と異なる場合であっても、ある一定期間において測定される(カウントアップされた)値は、上記一般的な倍率を用いてカウントアップされる値(測定値)と、実質的に同じ値になる。   In this way, the frequency ratio detection unit 15a measures the frequency ratio by changing the count-up amount (increment amount) for one pulse of the input clock based on the measurement adjustment signal. Therefore, even when the magnification of the input clock frequency fxin with respect to the first sampling frequency fsin is different from a general magnification (for example, 64 times), the value measured (counted up) in a certain period is The value (measured value) counted up using the general magnification is substantially the same.

サンプリング周波数変換部5は、周波数比検出部15aが検出した周波数比検出データNに基づいて標本化周波数変換を行う。周波数比検出にかかる測定期間(上記例における、出力クロックの周期(周波数fxoutの逆数)の2048倍の期間)が一定の場合、入力クロックの周波数fxinの第1標本化周波数fsinに対する倍率が変化すると、周波数比検出データNの値が大きく変化し、実際に入力されている入力データのサンプリング・レートと、出力データのサンプリング・レートとの周波数比と異なる周波数比に基づいて標本化周波数変換を行うことになり、正しく標本化周波数変換が行うことができない。そのため、周波数比検出部15aは、測定調整部13aの出力する第2制御信号に基づいて、入力クロック1パルス当たりのカウントアップの量を変え、測定期間を変化させることなく、迅速に、周波数比を測定し、正確な標本化周波数変換を実現する。   The sampling frequency converter 5 performs sampling frequency conversion based on the frequency ratio detection data N detected by the frequency ratio detector 15a. When the measurement period (a period of 2048 times the period of the output clock (reciprocal of the frequency fxout) in the above example) is constant, the magnification of the input clock frequency fxin with respect to the first sampling frequency fsin changes. The value of the frequency ratio detection data N changes greatly, and sampling frequency conversion is performed based on a frequency ratio different from the frequency ratio between the sampling rate of the input data actually input and the sampling rate of the output data. As a result, sampling frequency conversion cannot be performed correctly. Therefore, the frequency ratio detector 15a changes the amount of count-up per pulse of the input clock based on the second control signal output from the measurement adjuster 13a, and quickly changes the frequency ratio without changing the measurement period. To achieve accurate sampling frequency conversion.

従って、本発明にかかる第1の実施形態によるサンプリング・レート・コンバータ1aは、入力クロックの周波数fxinの第1標本化周波数fsinに対する倍率が、一般的に用いられてきた望ましい倍率(例えば64倍)よりも低い場合であっても、逓倍回路を用いることなく正しく周波数比を測定し、正確に標本化周波数変換を行うことができる。   Accordingly, in the sampling rate converter 1a according to the first embodiment of the present invention, the magnification of the input clock frequency fxin with respect to the first sampling frequency fsin is a desirable magnification that has been generally used (for example, 64 times). Even if it is lower than that, it is possible to accurately measure the frequency ratio without using the multiplier circuit and to accurately perform the sampling frequency conversion.

サンプリング・レート・コンバータ1aは、入力クロック周波数の第1標本化周波数に対する倍率が多様な値を取りうる場合であっても、逓倍回路を持たずに、周波数比検出を正確かつ迅速に行い、質の高い標本化周波数変換を実現する。   The sampling rate converter 1a performs frequency ratio detection accurately and quickly without having a multiplier circuit even when the magnification of the input clock frequency with respect to the first sampling frequency can take various values. High sampling frequency conversion is realized.

従来のサンプリング・レート・コンバータにおいては、サンプリング・レート44.1kHzの入力データを、サンプリング・レート48kHzの出力データに変換するときは、例えば、(44.1×64)kHzの周波数を有する入力クロックを用いて標本化周波数変換を行い、上記入力データを倍速で標本化周波数変換するときは、(44.1×64×2)kHzの周波数を有する入力クロックを用いて標本化周波数変換する必要があった。そのため、従来においては、不要輻射や消費電力の増大等の問題を抱えていた。しかし、サンプリング・レート・コンバータ1aでは、上記のような倍速での標本化周波数変換を行う場合であっても、入力クロックの周波数を高周波側にシフトさせる必要がないため、不要輻射や消費電力の低減が可能である。   In a conventional sampling rate converter, when converting input data having a sampling rate of 44.1 kHz to output data having a sampling rate of 48 kHz, for example, an input clock having a frequency of (44.1 × 64) kHz. When sampling frequency conversion is performed using the above and the input data is converted at sampling speed, it is necessary to perform sampling frequency conversion using an input clock having a frequency of (44.1 × 64 × 2) kHz. there were. For this reason, conventionally, there have been problems such as unnecessary radiation and increased power consumption. However, the sampling rate converter 1a does not need to shift the frequency of the input clock to the high frequency side even when performing the sampling frequency conversion at the double speed as described above. Reduction is possible.

また、サンプリング・レート・コンバータ1aは、逓倍回路を必要としないため、逓倍回路を要する従来のサンプリング・レート・コンバータよりも、回路面積を小さくすることができる。   Further, since the sampling rate converter 1a does not require a multiplication circuit, the circuit area can be made smaller than that of a conventional sampling rate converter that requires a multiplication circuit.

(第2の実施形態)
図3は、本発明にかかる第2の実施形態によるサンプリング・レート・コンバータ1bの構成を示すブロック図である。本実施形態のサンプリング・レート・コンバータ1bは、周波数比の検出にかかる測定期間を、外部からの入力信号に基づいて変更することが可能である。例えば、入力データのサンプリング・レートと入力クロックの周波数の比に関する情報を有する入力信号に基づいて、測定期間を標準の測定期間と異なる測定期間に変更して周波数比を測定することができる。図1に示すサンプリング・レート・コンバータ1aと同様の構成要素については、同様の参照数字を付している。また、そのような構成要素については、以下の記述において、詳細な説明を省略する。
(Second Embodiment)
FIG. 3 is a block diagram showing the configuration of the sampling rate converter 1b according to the second embodiment of the present invention. The sampling rate converter 1b of the present embodiment can change the measurement period for detecting the frequency ratio based on an input signal from the outside. For example, the frequency ratio can be measured by changing the measurement period to a measurement period different from the standard measurement period based on an input signal having information regarding the ratio between the sampling rate of the input data and the frequency of the input clock. Constituent elements similar to those of the sampling rate converter 1a shown in FIG. In addition, detailed description of such components will be omitted in the following description.

サンプリング・レート・コンバータ1bは、コントローラ2bと接続される。コントローラ2bは、新たに、第2の実施形態で追加された検出精度調整部17aに対し、精度調整信号を出力する。精度調整信号は、測定期間を変更するための情報を含めばよい。検出精度調整部17aは、受けた精度調整信号に基づいて検出精度調整信号を生成し、出力クロック計数部151bに対し出力する。出力クロック計数部151bは、出力クロックのパルスを計数する際、受けた検出精度調整信号に基づいて、測定期間の終了を示す出力の間隔(測定期間)を調整する。   Sampling rate converter 1b is connected to controller 2b. The controller 2b outputs an accuracy adjustment signal to the detection accuracy adjustment unit 17a newly added in the second embodiment. The accuracy adjustment signal may include information for changing the measurement period. The detection accuracy adjustment unit 17a generates a detection accuracy adjustment signal based on the received accuracy adjustment signal, and outputs the detection accuracy adjustment signal to the output clock counting unit 151b. When counting the pulses of the output clock, the output clock counter 151b adjusts the output interval (measurement period) indicating the end of the measurement period based on the received detection accuracy adjustment signal.

以下、第2の実施形態によるサンプリング・レート・コンバータ1bの動作について説明する。   The operation of the sampling rate converter 1b according to the second embodiment will be described below.

コントローラ2bから、第1標本化周波数fsinと入力クロック周波数fxinに関する情報を含む第2制御信号を、サンプリング・レート・コンバータ1aに出力する。   The controller 2b outputs a second control signal including information on the first sampling frequency fsin and the input clock frequency fxin to the sampling rate converter 1a.

同時に、コントローラ2aは第1制御信号を用いて、標本化データ出力器3に対し、第1標本化周波数fsinで入力データを、周波数fxinで入力クロックを出力するように指示する。逆に、標本化データ出力器3が出力する入力クロックに関する情報をコントローラ2aに伝える手段がある場合、コントローラ2bは、必ずしも標本化データ出力器3を制御する必要はなく、標本化データ出力器3は、サンプリング・レートfsinを有する入力データと、例えばfsinの32倍の周波数fxin(fxin=32×fsin)を有する入力クロックとをサンプリング・レート・コンバータ1bに対して出力し、周波数fxinで入力クロックを出力した事をコントローラ2aに指示する。   At the same time, the controller 2a uses the first control signal to instruct the sampling data output device 3 to output the input data at the first sampling frequency fsin and the input clock at the frequency fxin. On the contrary, when there is means for transmitting information related to the input clock output from the sampled data output unit 3 to the controller 2a, the controller 2b does not necessarily need to control the sampled data output unit 3, and the sampled data output unit 3 Outputs to the sampling rate converter 1b input data having a sampling rate fsin and an input clock having a frequency fxin (fxin = 32 × fsin) 32 times fsin, for example, and the input clock at the frequency fxin. Is output to the controller 2a.

例として、入力クロック周波数fxinは、第1標本化周波数fsinに対して32倍(fxin=32×fsin)であるとする。このとき、測定調整部13aは、参照テーブルを参照することにより、測定調整信号として値2を周波数比検出部15bに出力する。   As an example, it is assumed that the input clock frequency fxin is 32 times (fxin = 32 × fsin) with respect to the first sampling frequency fsin. At this time, the measurement adjustment unit 13a outputs the value 2 as a measurement adjustment signal to the frequency ratio detection unit 15b by referring to the reference table.

検出精度調整部17aは、デコード回路で構成することができる。検出精度調整部17aは、入力に対する出力を決定する参照テーブルを有し、受け取った精度調整信号に基づき、検出精度調整信号を出力クロック計数部151aに出力する。検出精度調整部17aに入力される精度調整信号は、1回の周波数比測定の測定期間の長さを調整するための信号である。例えば、標準の測定期間が、第1の実施形態と同じく出力クロックの周期の2048倍である場合、測定期間を3倍、つまり、出力クロックの周期の6144倍に相当する期間にしようとするならば、コントローラ2bは、値3を、精度調整信号として検出精度調整部17aに対して出力すればよい。   The detection accuracy adjustment unit 17a can be configured by a decode circuit. The detection accuracy adjustment unit 17a has a reference table for determining an output with respect to an input, and outputs a detection accuracy adjustment signal to the output clock counting unit 151a based on the received accuracy adjustment signal. The accuracy adjustment signal input to the detection accuracy adjustment unit 17a is a signal for adjusting the length of the measurement period of one frequency ratio measurement. For example, if the standard measurement period is 2048 times the output clock period as in the first embodiment, the measurement period should be three times, that is, a period corresponding to 6144 times the output clock period. For example, the controller 2b may output the value 3 to the detection accuracy adjustment unit 17a as an accuracy adjustment signal.

そして検出精度調整部17aは、精度調整信号に基づいて、測定期間を変更させるための検出精度調整信号を出力クロック計数部151aに対し出力する。検出精度調整信号は、例えば、ハイ(H)とロー(L)を有する二値信号でよい。例えば、値3を精度調整信号として受けた検出精度調整部17aは、参照テーブルを参照し、検出精度調整信号として、出力クロックに同期して、出力クロック3周期に一度、当該二値の一方の値(たとえば、ハイ)を出力する。検出精度調整信号は、出力クロック計数部151aを介して周波数比検出部153にも入力されてよい。出力クロック計数部151aが、検出精度調整信号のハイを2048個計数する毎に、周波数比測定部153に対し、測定期間の終了を示す出力を行うことで、測定期間は標準の測定期間の3倍の期間に延長される。   Then, the detection accuracy adjustment unit 17a outputs a detection accuracy adjustment signal for changing the measurement period to the output clock counting unit 151a based on the accuracy adjustment signal. The detection accuracy adjustment signal may be, for example, a binary signal having high (H) and low (L). For example, the detection accuracy adjustment unit 17a that receives the value 3 as the accuracy adjustment signal refers to the reference table, and synchronizes with the output clock as the detection accuracy adjustment signal once in one cycle of the output clock. Outputs a value (for example, high). The detection accuracy adjustment signal may also be input to the frequency ratio detection unit 153 via the output clock counting unit 151a. Each time the output clock counting unit 151a counts 2048 detection accuracy adjustment signals, the frequency ratio measuring unit 153 outputs to the frequency ratio measuring unit 153 the end of the measurement period, so that the measurement period is 3 times the standard measurement period. Doubled to a period.

周波数比検出部15bは、入力クロック、出力クロック、および、測定調整信号、ならびに、検出精度調整信号を用いて、サンプリング・レート・コンバータ1aに実際に入力されている入力データのサンプリング・レート(第1標本化周波数)と、出力データの所定のサンプリング・レート(第2標本化周波数)との比を求める。   The frequency ratio detector 15b uses the input clock, the output clock, the measurement adjustment signal, and the detection accuracy adjustment signal to sample the input data that is actually input to the sampling rate converter 1a (the first sampling rate). The ratio of one sampling frequency) to a predetermined sampling rate (second sampling frequency) of the output data is obtained.

具体的には、周波数比検出部15bは、(標準の測定期間)×(検出精度調整信号の示す値)に等しい期間に、(例えば、出力クロックの周期の2048倍の3倍の期間)に存在する入力クロックのパルス数を測定することになる。そして、出力クロック計数部151aは、検出精度調整信号を2048個カウントすると、周波数比測定部153に、測定期間の終了を示す出力を行う。周波数比測定部153は、当該期間に入力される入力クロックについて、測定調整信号を参照してインクリメント量を必要に応じて変更しながら、パルス数の計数(カウントアップ)を行う。   Specifically, the frequency ratio detection unit 15b has a period equal to (standard measurement period) × (value indicated by the detection accuracy adjustment signal), (for example, a period three times 2048 times the period of the output clock). The number of pulses of the existing input clock will be measured. When the output clock counting unit 151a counts 2048 detection accuracy adjustment signals, the output clock counting unit 151a outputs to the frequency ratio measurement unit 153 an output indicating the end of the measurement period. The frequency ratio measuring unit 153 counts (counts up) the number of pulses for the input clock input during the period while referring to the measurement adjustment signal and changing the increment amount as necessary.

カウントアップした入力クロックのパルス数の計数値と、測定期間に受けた出力クロックのパルス数(この場合、6144)との比を求めることによって周波数比が求められる。測定期間に含まれる出力クロックのパルス数は、検出精度調整信号に基づいて定めることができる。   The frequency ratio is obtained by obtaining the ratio between the counted value of the counted number of pulses of the input clock and the number of pulses of the output clock received during the measurement period (in this case, 6144). The number of pulses of the output clock included in the measurement period can be determined based on the detection accuracy adjustment signal.

このように、周波数比検出部15bは、検出精度調整部17aから出力される検出精度調整信号に基づいて、1回の測定に要する期間を変更することができる。測定期間を長くすることで、測定の精度を向上させることができる。特に、測定調整信号の値が大きい場合、測定期間を長くすることで、周波数比検出の精度の低下を防止することができる。   Thus, the frequency ratio detection unit 15b can change the period required for one measurement based on the detection accuracy adjustment signal output from the detection accuracy adjustment unit 17a. By increasing the measurement period, the measurement accuracy can be improved. In particular, when the value of the measurement adjustment signal is large, it is possible to prevent a decrease in the accuracy of frequency ratio detection by lengthening the measurement period.

このようにして得られた、周波数比は、周波数比検出データNとして、ステータスフラグ生成部30およびサンプリング周波数変換部5に送られる。以降の動作は、第1の実施形態と同様でよいため、ここでは説明を省略する。   The frequency ratio obtained in this way is sent to the status flag generation unit 30 and the sampling frequency conversion unit 5 as frequency ratio detection data N. Subsequent operations may be the same as those in the first embodiment, and thus description thereof is omitted here.

図4は、検出精度調整部17の詳細を示すブロック図である。検出精度調整部17は、精度調整信号および出力クロックを受ける検出精度調整信号生成部171と、同じく精度調整信号および出力クロックを受ける検出精度調整信号微調整部173と、検出精度調整信号生成部171および検出精度調整信号微調整部173の出力を加算する加算器175とを含む。検出精度調整信号生成部171は、入力に対する出力を決定するための参照テーブルを備え、精度調整信号に基づいて検出精度調整主信号を生成し、出力クロックに同期して加算器175に出力する。検出精度調整信号微調整部173もまた、入力に対する出力を決定するための参照テーブルを備え、検出精度調整信号生成部171の出力する検出精度調整主信号だけでは、検出精度調整信号を上手く生成できない場合に、検出精度調整主信号に加算して望ましい検出精度調整信号を生成するように検出精度調整副信号を、出力クロックに同期して加算器175に対し出力する。   FIG. 4 is a block diagram showing details of the detection accuracy adjustment unit 17. The detection accuracy adjustment unit 17 includes a detection accuracy adjustment signal generation unit 171 that receives the accuracy adjustment signal and the output clock, a detection accuracy adjustment signal fine adjustment unit 173 that similarly receives the accuracy adjustment signal and the output clock, and a detection accuracy adjustment signal generation unit 171. And an adder 175 that adds the outputs of the detection accuracy adjustment signal fine adjustment unit 173. The detection accuracy adjustment signal generation unit 171 includes a reference table for determining an output for the input, generates a detection accuracy adjustment main signal based on the accuracy adjustment signal, and outputs the detection accuracy adjustment main signal to the adder 175 in synchronization with the output clock. The detection accuracy adjustment signal fine adjustment unit 173 also includes a reference table for determining an output with respect to the input, and the detection accuracy adjustment signal cannot be generated satisfactorily only with the detection accuracy adjustment main signal output from the detection accuracy adjustment signal generation unit 171. In this case, the detection accuracy adjustment sub-signal is output to the adder 175 in synchronization with the output clock so as to be added to the detection accuracy adjustment main signal to generate a desired detection accuracy adjustment signal.

検出精度調整信号生成部171および検出精度調整信号微調整部173にそれぞれ含まれる参照テーブルの構成について説明する。検出精度調整部17の受け取った精度調整信号の示す、標準の測定期間に対する変更された測定期間の倍率(この倍率を「対標準測定期間倍率」と称する。)は、必ずしも整数値でなくともよい。また検出精度調整信号は、ハイとローの二値信号である。そこで、検出精度調整部17は、対標準測定期間倍率に対応する出力パターンを、検出精度調整信号生成部171および検出精度調整信号微調整部173において検出精度調整主信号および検出精度調整副信号として構成し、両方の信号を加算し、測定制御信号を生成する。参照テーブルは、対標準測定期間倍率を、検出精度調整信号の出力パターンに対応付ける。この出力パターンは、出力クロックのパルス数と、検出精度調整信号のハイの数との比が対標準測定期間倍率の値と等しくなるように決定される。決定された出力パターンに基づき、検出精度調整主信号および検出精度調整副信号が精製され、出力クロックに同期して加算器135に出力される。その結果、ある期間内の出力クロックのパルス数に対する検出精度調整信号のハイの数の比は、対標準測定期間倍率の値に等しくなる。   The configuration of the reference table included in each of the detection accuracy adjustment signal generation unit 171 and the detection accuracy adjustment signal fine adjustment unit 173 will be described. The magnification of the measurement period changed with respect to the standard measurement period indicated by the accuracy adjustment signal received by the detection accuracy adjustment unit 17 (this magnification is referred to as “versus standard measurement period magnification”) is not necessarily an integer value. . The detection accuracy adjustment signal is a binary signal of high and low. Therefore, the detection accuracy adjustment unit 17 uses the detection accuracy adjustment signal generation unit 171 and the detection accuracy adjustment signal fine adjustment unit 173 as the detection accuracy adjustment main signal and the detection accuracy adjustment sub-signal in the output pattern corresponding to the standard measurement period magnification. Configure and add both signals to generate a measurement control signal. The reference table associates the magnification with respect to the standard measurement period with the output pattern of the detection accuracy adjustment signal. This output pattern is determined so that the ratio between the number of pulses of the output clock and the number of highs of the detection accuracy adjustment signal is equal to the value of the standard measurement period magnification. Based on the determined output pattern, the detection accuracy adjustment main signal and the detection accuracy adjustment subsignal are refined and output to the adder 135 in synchronization with the output clock. As a result, the ratio of the high number of detection accuracy adjustment signals to the number of pulses of the output clock within a certain period is equal to the value of the standard measurement period magnification.

具体例を挙げ、検出精度調整部17の動作を説明する。検出精度調整信号生成部171および検出精度調整信号微調整部173はそれぞれ、精度調整信号を参照する。参照により、例えば、精度調整信号は、測定期間を、標準の測定期間の3倍とすることを示していることが判明したとする。検出精度調整信号生成部171および検出精度調整信号微調整部173は、参照テーブルを参照し、この「3.0倍」に対応した出力パターンを求める。この場合、検出精度調整信号生成部171は、出力クロックに同期して、出力クロック3周期に一度、ハイを検出精度調整主信号として加算器175に出力する。検出精度調整信号微調整部173は、この場合、常にローを検出精度調整副信号として加算器135に出力する。よって、検出精度調整信号は、出力クロック3周期に一度、ハイになる信号として出力される。出力クロック計数部151aは、検出精度調整信号に含まれるハイを計数し、計数値が所定値(例えば、2048)になると、測定期間の終了を示す出力を周波数比測定部153に対し行う。そのため、測定期間は、標準の測定期間の3倍になる。   The operation of the detection accuracy adjustment unit 17 will be described with a specific example. Each of the detection accuracy adjustment signal generation unit 171 and the detection accuracy adjustment signal fine adjustment unit 173 refers to the accuracy adjustment signal. By reference, for example, it is assumed that the accuracy adjustment signal is found to indicate that the measurement period is three times the standard measurement period. The detection accuracy adjustment signal generation unit 171 and the detection accuracy adjustment signal fine adjustment unit 173 refer to the reference table to obtain an output pattern corresponding to “3.0 times”. In this case, the detection accuracy adjustment signal generation unit 171 outputs high to the adder 175 as a detection accuracy adjustment main signal once every three cycles of the output clock in synchronization with the output clock. In this case, the detection accuracy adjustment signal fine adjustment unit 173 always outputs low to the adder 135 as a detection accuracy adjustment sub-signal. Therefore, the detection accuracy adjustment signal is output as a signal that goes high once every three output clock cycles. The output clock counting unit 151a counts high included in the detection accuracy adjustment signal, and when the count value reaches a predetermined value (for example, 2048), outputs to the frequency ratio measuring unit 153 that indicates the end of the measurement period. Therefore, the measurement period is three times as long as the standard measurement period.

また、例えば、精度調整信号が、測定期間を標準の測定期間の1.5倍とすることを示している場合について説明する。検出精度調整信号生成部171および検出精度調整信号微調整部173はそれぞれ、精度調整信号を参照する。参照により、精度調整信号は、測定期間を標準の測定期間の1.5倍とすることを示していることが判明したとする。検出精度調整信号生成部171および検出精度調整信号微調整部173は、参照テーブルを参照し、この「1.5倍」に対応した信号パターンを求める。この場合、検出精度調整信号生成部171は、出力クロックに同期して、出力クロック3周期に一度、ハイを検出精度調整主信号として加算器175に出力する。検出精度調整信号微調整部173は、この場合、検出精度調整信号生成部171とは異なるタイミングで、出力クロック3周期に一度、ハイを検出精度調整副信号として加算器175に出力する。よって、検出精度調整信号は、出力クロック3周期に二度、ハイになる信号として出力される。よって、出力クロック計数部151aは、出力クロック3周期に2度、計数する。そのため、測定期間が、標準の測定期間の1.5倍に延長される。   Further, for example, a case will be described in which the accuracy adjustment signal indicates that the measurement period is 1.5 times the standard measurement period. Each of the detection accuracy adjustment signal generation unit 171 and the detection accuracy adjustment signal fine adjustment unit 173 refers to the accuracy adjustment signal. By reference, it is assumed that the accuracy adjustment signal is found to indicate that the measurement period is 1.5 times the standard measurement period. The detection accuracy adjustment signal generation unit 171 and the detection accuracy adjustment signal fine adjustment unit 173 refer to the reference table and obtain a signal pattern corresponding to “1.5 times”. In this case, the detection accuracy adjustment signal generation unit 171 outputs high to the adder 175 as a detection accuracy adjustment main signal once every three cycles of the output clock in synchronization with the output clock. In this case, the detection accuracy adjustment signal fine adjustment unit 173 outputs “high” as a detection accuracy adjustment sub-signal to the adder 175 once every three cycles of the output clock at a timing different from that of the detection accuracy adjustment signal generation unit 171. Therefore, the detection accuracy adjustment signal is output as a signal that goes high twice every three output clock cycles. Therefore, the output clock counter 151a counts twice every three cycles of the output clock. Therefore, the measurement period is extended to 1.5 times the standard measurement period.

ここで、周波数比検出部15bの出力するデータについて考察する。ある一測定期間において、測定調整信号は、常に2であったとする。その場合、周波数比検出部15bは、入力クロックのパルスを受ける度に、2つずつカウントアップし、カウントアップした値(測定値)を周波数比検出データNとして出力する。そうすると、周波数比検出データNと、遅延された周波数比検出データNzとの差の刻み幅は、測定調整信号が、常に1である場合と比較して、2倍になってしまう。そこで、検出精度調整部17aは、測定期間を標準の測定期間よりも長くし、長くする倍率に基づいてカウントアップされた入力パルス数を割って周波数比検出データNを求めることにより、遅延された周波数比検出データNzとの差の刻み幅を小さくする。このことは、周波数比および周波数比の安定・不安定の判定をより正確にする効果がある。   Here, data output from the frequency ratio detector 15b will be considered. It is assumed that the measurement adjustment signal is always 2 in one measurement period. In this case, the frequency ratio detection unit 15b counts up two by two each time an input clock pulse is received, and outputs the counted up value (measured value) as frequency ratio detection data N. Then, the step size of the difference between the frequency ratio detection data N and the delayed frequency ratio detection data Nz is doubled as compared with the case where the measurement adjustment signal is always 1. Therefore, the detection accuracy adjustment unit 17a is delayed by making the measurement period longer than the standard measurement period and dividing the number of input pulses counted up based on the magnification to be increased to obtain the frequency ratio detection data N. The step size of the difference from the frequency ratio detection data Nz is reduced. This has the effect of making the determination of the frequency ratio and the stability / instability of the frequency ratio more accurate.

従って、本発明にかかる第2の実施形態によるサンプリング・レート・コンバータ1bは、固定的に定められた測定期間で周波数比を検出する場合よりも、周波数比測定の精度を向上させる。   Therefore, the sampling rate converter 1b according to the second embodiment of the present invention improves the accuracy of the frequency ratio measurement as compared with the case where the frequency ratio is detected in a fixedly determined measurement period.

(第3の実施形態)
図5は、本発明にかかる第3の実施形態によるサンプリング・レート・コンバータ1cの構成を示すブロック図である。本実施形態のサンプリング・レート・コンバータ1cは、入力クロック周波数fxinの第1標本化周波数fsinに対する比に基づいて、測定期間を変更することができる。サンプリング・レート・コンバータ1cは、測定期間の延長の程度を、入力クロックのパルス1つに対するインクリメント量に応じて決定することができる。図1に示すサンプリング・レート・コンバータ1a、または、図3に示すサンプリング・レート・コンバータ1bと同様の構成要素については、同様の参照数字を付している。また、そのような構成要素については、以下の記述において、詳細な説明を省略する。
(Third embodiment)
FIG. 5 is a block diagram showing a configuration of a sampling rate converter 1c according to the third embodiment of the present invention. The sampling rate converter 1c of this embodiment can change the measurement period based on the ratio of the input clock frequency fxin to the first sampling frequency fsin. The sampling rate converter 1c can determine the extent of extension of the measurement period according to the increment amount with respect to one pulse of the input clock. Constituent elements similar to those of the sampling rate converter 1a shown in FIG. 1 or the sampling rate converter 1b shown in FIG. 3 are denoted by the same reference numerals. In addition, detailed description of such components will be omitted in the following description.

サンプリング・レート・コンバータ1bは、コントローラ2aと接続される。コントローラ2aは、検出精度調整部17bに対しても、第2制御信号を出力する。検出精度調整部17aは、受けた第2制御信号に基づいて検出精度調整信号を生成し、出力クロック計数部151bに対し出力する。出力クロック計数部151bは、第2の実施形態と同様に、出力クロックのパルスを計数する際、受けた検出精度調整信号に基づいて、測定期間の終了を示す出力の間隔(測定期間)を調整する。   Sampling rate converter 1b is connected to controller 2a. The controller 2a also outputs the second control signal to the detection accuracy adjustment unit 17b. The detection accuracy adjustment unit 17a generates a detection accuracy adjustment signal based on the received second control signal, and outputs the detection accuracy adjustment signal to the output clock counting unit 151b. As in the second embodiment, the output clock counter 151b adjusts the output interval (measurement period) indicating the end of the measurement period based on the received detection accuracy adjustment signal when counting the pulses of the output clock. To do.

以下、第3の実施形態によるサンプリング・レート・コンバータ1cの動作について説明する。   The operation of the sampling rate converter 1c according to the third embodiment will be described below.

コントローラ2aから、第1標本化周波数fsinと入力クロック周波数fxinに関する情報を含む第2制御信号を、サンプリング・レート・コンバータ1cに出力する。   The controller 2a outputs a second control signal including information on the first sampling frequency fsin and the input clock frequency fxin to the sampling rate converter 1c.

同時に、コントローラ2aは第1制御信号を用いて、標本化データ出力器3に対し、第1標本化周波数fsinで入力データを、周波数fxinで入力クロックを出力するように指示する。逆に、標本化データ出力器3が出力する入力クロックに関する情報をコントローラ2aに伝える手段がある場合、コントローラ2bは、必ずしも標本化データ出力器3を制御する必要はなく、標本化データ出力器3は、サンプリング・レートfsinを有する入力データと、例えばfsinの32倍の周波数fxin(fxin=32×fsin)を有する入力クロックとをサンプリング・レート・コンバータ1bに対して出力し、周波数fxinで入力クロックを出力した事をコントローラ2aに指示する。   At the same time, the controller 2a uses the first control signal to instruct the sampling data output device 3 to output the input data at the first sampling frequency fsin and the input clock at the frequency fxin. On the contrary, when there is means for transmitting information related to the input clock output from the sampled data output unit 3 to the controller 2a, the controller 2b does not necessarily need to control the sampled data output unit 3, and the sampled data output unit 3 Outputs to the sampling rate converter 1b input data having a sampling rate fsin and an input clock having a frequency fxin (fxin = 32 × fsin) that is 32 times fsin, for example, and the input clock at the frequency fxin. Is output to the controller 2a.

第3の実施形態の説明においても、第1および第2の実施形態の説明と同様、例として、入力クロックの周波数fxinは、第1標本化周波数fsinに対して32倍(fxin=32×fsin)であるとする。このとき、測定調整部13aは、第1および第2の実施形態と同様、測定調整信号として値2を周波数比検出部15bに出力する。   Also in the description of the third embodiment, as in the description of the first and second embodiments, as an example, the frequency fxin of the input clock is 32 times the first sampling frequency fsin (fxin = 32 × fsin). ). At this time, like the first and second embodiments, the measurement adjustment unit 13a outputs the value 2 as a measurement adjustment signal to the frequency ratio detection unit 15b.

検出精度調整部17bに入力される第2制御信号は、測定調整部13aに入力される信号と同一の信号でよい。検出精度調整部17bは、第1標本化周波数fsinと入力クロック周波数fxinの情報に基づいて、入力クロックのパルス数を計数する測定期間の長さを調整することができる。この情報は、少なくとも、入力クロック周波数fxinの第1標本化周波数fsinに対する比を含んでいればよい。このとき、検出精度調整部17bは、測定期間を標準の測定期間の2倍となるように、出力クロックの2周期に1回、ハイを含む検出精度調整信号を生成して出力する。   The second control signal input to the detection accuracy adjustment unit 17b may be the same signal as the signal input to the measurement adjustment unit 13a. The detection accuracy adjustment unit 17b can adjust the length of the measurement period in which the number of pulses of the input clock is counted based on the information of the first sampling frequency fsin and the input clock frequency fxin. This information only needs to include at least the ratio of the input clock frequency fxin to the first sampling frequency fsin. At this time, the detection accuracy adjustment unit 17b generates and outputs a detection accuracy adjustment signal including high once every two cycles of the output clock so that the measurement period is twice the standard measurement period.

周波数比検出部15bは、入力クロックのパルス1つにつき、インクリメント量2でカウントアップしながら、標準の測定期間の2倍の期間(出力クロックの周期の2048×2倍に相当する期間)、カウントアップを続け、当該カウントアップに基づいて周波数比検出データNを決定する。   The frequency ratio detection unit 15b counts for each pulse of the input clock while counting up with an increment amount of 2 while doubling the standard measurement period (a period corresponding to 2048 × 2 times the cycle of the output clock). The frequency ratio detection data N is determined based on the count-up.

このように、検出精度調整部17bは、測定調整部13aと同様に、第2制御信号に含まれる入力クロック周波数fxinおよび第1標本化周波数fsinに関する情報に基づいて、測定調整信号の示す入力パルス1つ当たりのインクリメント量に比例するように測定期間を延長する検出精度調整信号を生成して出力する。たとえば、入力パルス32個を64とカウントするように測定調整信号「2」が出力されている場合、検出精度調整信号は、標準の測定期間の2倍の期間を測定期間とするように出力される。このように、測定期間を、インクリメント量に応じて変化させることができる。インクリメント量と測定期間との関係は、線形的なもの(比例関係)であってもよいし、二次以上の関係であってもよい。或いは、テーブルを参照して決定される、階段状のものでもよい。検出精度調整部17bの動作は、測定調整部13aの動作と連係して変化可能となり、入力パルスのカウントアップの1パルス当たりのインクリメント量に応じて最適な測定期間を設定することができる。   As described above, the detection accuracy adjustment unit 17b, like the measurement adjustment unit 13a, inputs the input pulse indicated by the measurement adjustment signal based on the information regarding the input clock frequency fxin and the first sampling frequency fsin included in the second control signal. A detection accuracy adjustment signal for extending the measurement period so as to be proportional to the increment amount per one is generated and output. For example, when the measurement adjustment signal “2” is output so that 32 input pulses are counted as 64, the detection accuracy adjustment signal is output so that the measurement period is twice as long as the standard measurement period. The Thus, the measurement period can be changed according to the increment amount. The relationship between the increment amount and the measurement period may be linear (proportional relationship) or may be a secondary or higher relationship. Alternatively, it may be a stepped shape determined with reference to a table. The operation of the detection accuracy adjustment unit 17b can be changed in conjunction with the operation of the measurement adjustment unit 13a, and an optimal measurement period can be set according to the increment amount per pulse of the input pulse count-up.

入力クロック1パルス当たりのカウントアップのインクリメント量が2である場合、測定期間は、標準の測定期間の2倍に設定されてよい。そうすることで、周波数比検出データNと、遅延された周波数比検出データNzとの差の刻み幅は、入力クロックのパルスを受ける度に、1ずつカウントアップする場合と比較して、同程度にすることができる。   When the increment amount of the count-up per input clock pulse is 2, the measurement period may be set to twice the standard measurement period. By doing so, the step size of the difference between the frequency ratio detection data N and the delayed frequency ratio detection data Nz is approximately the same as when incrementing by one each time a pulse of the input clock is received. Can be.

あるいは、入力クロックのパルスが入力される毎に、インクリメント量が、1、と、2、とで交互に交替する場合は、測定期間は、標準の測定期間の1.5倍に設定されればよい。この場合も同様に、周波数比検出データNと、遅延された周波数比検出データNzとの差の刻み幅は、入力クロックのパルスを受ける度に、1ずつカウントアップする場合と比較して、同程度にすることができる。   Alternatively, if the increment amount alternates between 1 and 2 each time an input clock pulse is input, the measurement period can be set to 1.5 times the standard measurement period. Good. Similarly, in this case, the step size of the difference between the frequency ratio detection data N and the delayed frequency ratio detection data Nz is the same as that when the input clock pulse is incremented by one. Can be about.

第3の実施形態によるサンプリング・レート・コンバータ1cは、1つの周波数比検出データNの決定にかかる測定期間を、入力クロックの周波数fxinに応じて自動的に適正化することができ、いかなる入力クロック周波数の場合にも、十分な精度の周波数比測定が可能である。なお、第3の実施形態においても、測定期間を、インクリメント量と、直接的な相関性を備えずに設定することは可能である。   The sampling rate converter 1c according to the third embodiment can automatically optimize the measurement period for determining one frequency ratio detection data N according to the frequency fxin of the input clock. Even in the case of frequency, the frequency ratio can be measured with sufficient accuracy. Also in the third embodiment, it is possible to set the measurement period without providing a direct correlation with the increment amount.

(第3の実施形態の変形例)
図6は、第3の実施形態の変形例によるサンプリング・レート・コンバータ1dの構成を示すブロック図である。サンプリング・レート・コンバータ1dにおいては、測定調整部13aが精度調整信号を生成し検出精度調整部17cへ出力する。図1に示すサンプリング・レート・コンバータ1a、図3に示すサンプリング・レート・コンバータ1b、または、図5に示すサンプリング・レート・コンバータ1cと同様の構成要素については、同様の参照数字を付している。また、そのような構成要素については、以下の記述において、詳細な説明を省略する。
(Modification of the third embodiment)
FIG. 6 is a block diagram showing a configuration of a sampling rate converter 1d according to a modification of the third embodiment. In the sampling rate converter 1d, the measurement adjustment unit 13a generates an accuracy adjustment signal and outputs it to the detection accuracy adjustment unit 17c. Components similar to those of the sampling rate converter 1a shown in FIG. 1, the sampling rate converter 1b shown in FIG. 3, or the sampling rate converter 1c shown in FIG. Yes. In addition, detailed description of such components will be omitted in the following description.

コントローラ2aは、第2制御信号を、測定調整部13aに対し出力する。サンプリング・レート・コンバータ1dは、図5に示すサンプリング・レート・コンバータ1cのように、検出精度調整部17bに対して第2制御信号を出力しない。その代わり、第2制御信号を受けた測定調整部13aは、図3に示すサンプリング・レート・コンバータ1bにおいてコントローラ2bの出力する精度調整信号と同等の信号を生成して検出精度調整部17cに対して出力する。または、測定調整部13aは、受けた第2制御信号を、そのままスルーして、検出精度調整部17cに出力してもよい。   The controller 2a outputs a second control signal to the measurement adjustment unit 13a. The sampling rate converter 1d does not output the second control signal to the detection accuracy adjustment unit 17b, unlike the sampling rate converter 1c shown in FIG. Instead, the measurement adjustment unit 13a that has received the second control signal generates a signal equivalent to the accuracy adjustment signal output from the controller 2b in the sampling rate converter 1b shown in FIG. 3 to the detection accuracy adjustment unit 17c. Output. Alternatively, the measurement adjustment unit 13a may directly pass the received second control signal and output it to the detection accuracy adjustment unit 17c.

このように構成することで、サンプリング・レート・コンバータ1dにおいても、測定調整部13aと、検出精度調整部17cが連係して動作することが可能である。よって、入力クロックの周波数fxinと第1標本化周波数fsinとの比に基づいて、測定期間を延長したり、短縮したりすることができる。なお、測定期間は、入力クロックの周波数fxinと第1標本化周波数fsinとの倍率とは無関係に、決定されるようにすることも可能である。   With this configuration, in the sampling rate converter 1d, the measurement adjustment unit 13a and the detection accuracy adjustment unit 17c can operate in cooperation. Therefore, the measurement period can be extended or shortened based on the ratio between the frequency fxin of the input clock and the first sampling frequency fsin. Note that the measurement period can be determined regardless of the magnification of the frequency fxin of the input clock and the first sampling frequency fsin.

なお、本発明を説明するにあたり、入力クロックの周波数fxinを、第1標本化周波数fsinの32倍や48倍とした例を用いている。また、測定期間を出力クロックの周波数fxoutの2048倍、2048×2倍、2048×1.5倍にしているが、本発明は、これらの例値によって限定されない。入力クロックの周波数fxinに基づいて決定される測定調整信号、測定調整信号に基づいて決定される入力クロックの1パルス当たりのインクリメント量、測定調整信号の値、精度調整信号の具体的態様、検出精度調整信号、測定期間の終了を周波数比測定部153に出力する具体的態様、および、周波数比Nの導出にかかる具体的態様等は、本例に示した態様以外にも、様々に可能である。   In describing the present invention, an example in which the frequency fxin of the input clock is 32 times or 48 times the first sampling frequency fsin is used. Further, although the measurement period is set to 2048 times, 2048 × 2 times, and 2048 × 1.5 times the frequency fxout of the output clock, the present invention is not limited to these example values. Measurement adjustment signal determined based on frequency fxin of input clock, increment amount per pulse of input clock determined based on measurement adjustment signal, value of measurement adjustment signal, specific mode of accuracy adjustment signal, detection accuracy The specific mode for outputting the adjustment signal, the end of the measurement period to the frequency ratio measuring unit 153, the specific mode for deriving the frequency ratio N, and the like are variously possible in addition to the mode shown in this example. .

本発明のサンプリング・レート・コンバータは、デジタル信号処理の分野において有用である。   The sampling rate converter of the present invention is useful in the field of digital signal processing.

第1の実施形態によるサンプリング・レート・コンバータの構成を示すブロック図The block diagram which shows the structure of the sampling rate converter by 1st Embodiment 測定調整部の詳細を示すブロック図Block diagram showing details of measurement adjustment unit 第2の実施形態によるサンプリング・レート・コンバータの構成を示すブロック図The block diagram which shows the structure of the sampling rate converter by 2nd Embodiment 検出精度調整部の詳細を示すブロック図Block diagram showing details of detection accuracy adjuster 第3の実施形態によるサンプリング・レート・コンバータの構成を示すブロック図The block diagram which shows the structure of the sampling rate converter by 3rd Embodiment 第3の実施形態によるサンプリング・レート・コンバータの変形例の構成を示すブロック図The block diagram which shows the structure of the modification of the sampling rate converter by 3rd Embodiment.

符号の説明Explanation of symbols

1a・・・ サンプリング・レート・コンバータ
1b・・・ サンプリング・レート・コンバータ
1c・・・ サンプリング・レート・コンバータ
2a・・・ コントローラ
2b・・・ コントローラ
3 ・・・ 標本化データ出力器
5 ・・・ サンプリング周波数変換部
10a・・・ 周波数比検出データ出力部
10b・・・ 周波数比検出データ出力部
10c・・・ 周波数比検出データ出力部
11 ・・・ クロック生成部
13a・・・ 測定調整部
15a・・・ 周波数比検出部
15b・・・ 周波数比検出部
17a・・・ 検出精度調整部
17b・・・ 検出精度調整部
17c・・・ 検出精度調整部
30 ・・・ ステータスフラグ生成部
31 ・・・ データ比較部
33 ・・・ 遅延部
131 ・・・ セレクタ部
133 ・・・ 測定微調整部
135 ・・・ 加算器
151a・・・ 出力クロック計数部
151b・・・ 出力クロック計数部
153 ・・・ 周波数比測定部
171 ・・・ 検出精度調整信号生成部
173 ・・・ 検出精度調整信号微調整部
175 ・・・ 加算器
DESCRIPTION OF SYMBOLS 1a ... Sampling rate converter 1b ... Sampling rate converter 1c ... Sampling rate converter 2a ... Controller 2b ... Controller 3 ... Sampling data output device 5 ... Sampling frequency conversion unit 10a ... Frequency ratio detection data output unit 10b ... Frequency ratio detection data output unit 10c ... Frequency ratio detection data output unit 11 ... Clock generation unit 13a ... Measurement adjustment unit 15a .. Frequency ratio detection unit 15b ... Frequency ratio detection unit 17a ... Detection accuracy adjustment unit 17b ... Detection accuracy adjustment unit 17c ... Detection accuracy adjustment unit 30 ... Status flag generation unit 31 ... Data comparison unit 33 ... delay unit 131 ... selector unit 133 ... measurement fine adjustment unit 135・ ・ ・ Adder 151a ・ ・ ・ Output clock counting unit 151b ・ ・ ・ Output clock counting unit 153 ・ ・ ・ Frequency ratio measurement unit 171 ・ ・ ・ Detection accuracy adjustment signal generation unit 173 ・ ・ ・ Detection accuracy adjustment signal fine adjustment unit 175 ... Adder

Claims (5)

第1の標本化周波数を有する入力データを、第2の標本化周波数を有する出力データに変換する非同期型サンプリング・レート・コンバータであって、
前記第1の標本化周波数と、前記第1の標本化周波数に比例した周波数である入力クロック周波数との比に基づいて測定調整信号を生成する、測定調整部と、
前記測定調整信号と、前記入力クロック周波数を有する入力クロックと、前記第2の標本化周波数を有する出力クロックと、を受け、所定の測定期間に入力される前記入力クロックのパルスの数を、前記測定調整信号に基づいて定まる1パルス当たりのインクリメント量でカウントし、前記第1の標本化周波数と、前記第2の標本化周波数の周波数比を決定する、周波数比検出部と、
前記周波数比に基づいて、前記入力データの標本化周波数変換を行うサンプリング周波数変換部と、を有するサンプリング・レート・コンバータ。
An asynchronous sampling rate converter for converting input data having a first sampling frequency into output data having a second sampling frequency,
A measurement adjustment unit that generates a measurement adjustment signal based on a ratio between the first sampling frequency and an input clock frequency that is a frequency proportional to the first sampling frequency;
The measurement adjustment signal, an input clock having the input clock frequency, and an output clock having the second sampling frequency are received, and the number of pulses of the input clock input during a predetermined measurement period is A frequency ratio detector that counts in increments per pulse determined based on a measurement adjustment signal, and determines a frequency ratio between the first sampling frequency and the second sampling frequency;
A sampling rate converter comprising: a sampling frequency conversion unit that performs sampling frequency conversion of the input data based on the frequency ratio.
さらに、前記第1の標本化周波数と、前記入力クロック周波数との比に基づいて検出精度調整信号を生成する、検出精度調整部を有し、
前記周波数比検出部は、前記検出精度調整信号に基づいて前記測定期間の長さを変更する請求項1に記載のサンプリング・レート・コンバータ。
A detection accuracy adjustment unit configured to generate a detection accuracy adjustment signal based on a ratio between the first sampling frequency and the input clock frequency;
The sampling rate converter according to claim 1, wherein the frequency ratio detection unit changes the length of the measurement period based on the detection accuracy adjustment signal.
前記検出精度調整部は、前記検出精度調整信号を、前記測定調整信号に応じて変化させる請求項2に記載のサンプリング・レート・コンバータ。   The sampling rate converter according to claim 2, wherein the detection accuracy adjustment unit changes the detection accuracy adjustment signal according to the measurement adjustment signal. 前記測定期間の長さは、前記インクリメント量に比例する請求項2に記載のサンプリング・レート・コンバータ。   The sampling rate converter according to claim 2, wherein the length of the measurement period is proportional to the increment amount. さらに、前記周波数比の安定性を示すステータスフラグを生成するステータスフラグ生成部を有し、
前記ステータスフラグ生成部は、前記周波数比と前記周波数比よりも以前に測定された周波数比とに基づいて、前記周波数比の安定性を判定し、前記ステータスフラグを生成し、
前記サンプリング周波数変換部は、前記ステータスフラグの状態に基づいて、前記入力データの標本化周波数変換を開始する請求項1に記載のサンプリング・レート・コンバータ。
And a status flag generator for generating a status flag indicating the stability of the frequency ratio,
The status flag generation unit determines stability of the frequency ratio based on the frequency ratio and a frequency ratio measured before the frequency ratio, generates the status flag,
The sampling rate converter according to claim 1, wherein the sampling frequency converter starts sampling frequency conversion of the input data based on the status flag.
JP2007014479A 2007-01-25 2007-01-25 Sampling rate converter Pending JP2008182494A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007014479A JP2008182494A (en) 2007-01-25 2007-01-25 Sampling rate converter

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007014479A JP2008182494A (en) 2007-01-25 2007-01-25 Sampling rate converter

Publications (1)

Publication Number Publication Date
JP2008182494A true JP2008182494A (en) 2008-08-07

Family

ID=39726056

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007014479A Pending JP2008182494A (en) 2007-01-25 2007-01-25 Sampling rate converter

Country Status (1)

Country Link
JP (1) JP2008182494A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112532985A (en) * 2020-12-01 2021-03-19 北方工业大学 Self-adaptive adjustment method for video stream code rate of mobile terminal based on variable period sampling
WO2022266550A1 (en) * 2021-06-18 2022-12-22 Tektronix, Inc. Multiple sample-rate data converter

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112532985A (en) * 2020-12-01 2021-03-19 北方工业大学 Self-adaptive adjustment method for video stream code rate of mobile terminal based on variable period sampling
CN112532985B (en) * 2020-12-01 2023-05-26 北方工业大学 Self-adaptive adjustment method for mobile terminal video stream code rate based on variable period sampling
WO2022266550A1 (en) * 2021-06-18 2022-12-22 Tektronix, Inc. Multiple sample-rate data converter

Similar Documents

Publication Publication Date Title
US7999707B2 (en) Apparatus for compensating for error of time-to-digital converter
JP4893052B2 (en) Receiver circuit and receiver circuit test method
US7733151B1 (en) Operating clock generation system and method for audio applications
KR100865662B1 (en) Noise-shaped digital frequency synthesis
US7330138B2 (en) Asynchronous sample rate correction by time domain interpolation
JP2012052877A (en) Frequency measuring device and electronics
JP2004236019A (en) Method and apparatus for adjusting skew and data transmission system provided with skew adjustment function
JP5748132B2 (en) PLL circuit
JP2007024657A (en) Sampling device and sampling method
US10249279B1 (en) D/A converter, electronic musical instrument, information processing device and D/A conversion method
JP2008182494A (en) Sampling rate converter
JP4955196B2 (en) AC signal measuring device
JP2007113954A (en) Trigger signal generator
JP2009216617A (en) Sampling clock generation circuit and alternating current signal measuring device
US7236556B2 (en) Synchronising circuit
JP2008085424A (en) Interleave a/d conversion apparatus
JP2010021665A (en) Data receiver
KR101579678B1 (en) Time-digital converter and method for controlling the time-digital converter thereof
CN214315114U (en) Micro-step motor counting sequence circuit
JP4787470B2 (en) Method of operating image display apparatus and image display apparatus
CN112910338A (en) Micro-step motor counting sequence circuit
JP7263859B2 (en) D/A converter, audio equipment, electronic musical instrument and D/A conversion method
JP2010041388A (en) Asynchronous serial data receiver
JP2009303034A (en) Frequency converter
JP4355935B2 (en) Clock generator and IC tester using the same