JP4542658B2 - Digital sine wave data generator - Google Patents

Digital sine wave data generator Download PDF

Info

Publication number
JP4542658B2
JP4542658B2 JP2000043200A JP2000043200A JP4542658B2 JP 4542658 B2 JP4542658 B2 JP 4542658B2 JP 2000043200 A JP2000043200 A JP 2000043200A JP 2000043200 A JP2000043200 A JP 2000043200A JP 4542658 B2 JP4542658 B2 JP 4542658B2
Authority
JP
Japan
Prior art keywords
value
frequency
output
sine wave
unit
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2000043200A
Other languages
Japanese (ja)
Other versions
JP2001238235A (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.)
Toshiba Corp
Original Assignee
Toshiba 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 Toshiba Corp filed Critical Toshiba Corp
Priority to JP2000043200A priority Critical patent/JP4542658B2/en
Publication of JP2001238235A publication Critical patent/JP2001238235A/en
Application granted granted Critical
Publication of JP4542658B2 publication Critical patent/JP4542658B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Description

【0001】
【発明の属する技術分野】
本発明は、例えばボタン電話システムの主装置などに用いられ、例えば内線端末などに供するために用いられるトーン信号を生成するための正弦波データを生成するディジタル正弦波データ生成器に関する。
【0002】
【従来の技術】
ボタン電話システムにおいて交換機能を有している主装置は、近年の高機能化および小型化の要求のために、その主要部はディジタル化されている。
【0003】
ところでこの種の装置では、内線や局線へと送出するためのトーン信号を発生する機能が必要とされ、そのトーン信号の元となる正弦波信号を生成する正弦波生成器が設けられる。
【0004】
また、内線や局線を介して到来したビジートーンやDTMF信号などの各種のトーン信号を検出することが必要とされ、これらのトーン信号を検出するトーン検出回路が設けられる。
【0005】
これらの正弦波生成器やトーン検出回路は従来、アナログ回路により実現されていたため、回路規模が大きく、集積化も困難であるという不具合があった。また、他の部分はディジタル化されているために、それらの部分とのインタフェースのためにはコーデックも設けなければならず、さらなる回路規模の増大を招いていた。
【0006】
これらの正弦波生成器やトーン検出回路は、トラヒックの理論によると収容回線100回線当り8つが必要となるが、このような複数のトーン検出回路を全てアナログ回路により構成していることは、回路規模の縮小の大きな妨げとなってしまっていた。
【0007】
なお、DSP(Digital Signal Processor)を用いてディジタル処理により正弦波生成やトーン検出を行うことも可能ではあるが、プログラム作成の手間が多大である上に、依然として回路規模が大きく、コストや消費電力も大きいという不具合がある。
【0008】
【発明が解決しようとする課題】
以上のように従来は、正弦波信号の生成やトーン信号の検出はアナログ回路によって実現されていたため、回路規模の増大による大型化やコスト上昇、ならびに消費電力の増大などの不具合があった。
【0009】
本発明はこのような事情を考慮してなされたものであり、その目的とするところは、簡易なディジタル回路により、集積化による小型化、低コスト化および低消費電力化を実現可能なディジタル正弦波データ生成器を提供することにある。
【0010】
【発明が解決しようとする課題】
以上の目的を達成するために第1の発明は、所定の周波数の正弦波信号のレベルを示すディジタル値を所定の周期毎に出力ディジタル値として出力することで正弦波データを生成するディジタル正弦波データ生成器において、1周期前における出力ディジタル値に前記正弦波信号の周波数に応じて定まる定数を乗算した第1参照値を生成する、例えばラッチ回路と乗算器とからなる乗算手段と、2周期前における出力ディジタル値を反転させた第2参照値を生成する、例えば2つのラッチ回路と乗算器とからなる反転手段と、前記乗算手段により生成された前記第1参照値と前記反転手段により生成された前記第2参照値とを加算して現時点における出力ディジタル値を生成する例えば加算器などの加算手段と、前記第1参照値を「0」に、また前記第2参照値を前記正弦波信号の周波数に応じて定まる初期値にそれぞれリセットする例えば初期化部などのリセット手段と、このリセット手段によるリセットが行われてからの経過時間を計時する例えばタイマなどの計時手段と、前記加算手段で生成された前記出力ディジタル値の極性が正から負に変化したことを検出する、例えばラッチ回路および比較部よりなる極性変化検出手段と、前記出力ディジタル値の絶対値が所定の基準値以下である低レベル状態であることを検出する、例えば基準データレジスタおよび比較部からなるレベル確認手段と、前記計時手段により計時された経過時間が所定時間を超えている状態において、前記極性変化検出手段により極性変化が検出された際に前記レベル確認手段により前記低レベル状態であることが検出されていたならば前記リセット手段にリセットを行わせる例えばANDゲートなどのリセット制御手段とを備えた。
【0011】
このような手段を講じたことにより、1周期前における出力ディジタル値に所望の正弦波信号の周波数に応じて定まる定数が乗算された第1参照値と、2周期前における出力ディジタル値が反転された第2参照値とが加算されることで、前記正弦波信号のレベルを示すディジタル値が求められる。そして前回のリセットが行われてからの経過時間が所定時間を超えている状態において、前記出力ディジタル値の極性が正から負に変化した際に、前記出力ディジタル値の絶対値が所定の基準値以下である低レベル状態である状態となったことに応じて、第1参照値および第2参照値は「0」および前記正弦波信号の周波数に応じて定まる初期値にそれぞれリセットされる。従って、このようなディジタル処理により実現可能な処理によってのみ正弦波データの生成が行え、また定期的なリセットは前回のリセットが行われてからの経過時間が所定時間を超えている状態において、前記出力ディジタル値の極性が正から負に変化した際に、前記出力ディジタル値の絶対値が所定の基準値以下である低レベル状態である状態となったときにのみ行われ、リセットによる正弦波のひずみが低減される。
【0024】
【発明の実施の形態】
以下、図面を参照して本発明のいくつかの実施形態につき説明する。
【0025】
図1は本発明の正弦波データ生成器およびトーン検出回路を備えたボタン電話システムの要部構成を示すブロック図である。
【0026】
このボタン電話システムは同図に示すように、主装置1に、複数(最大i個)の内線端末2(2-1〜2-i)を任意に接続して構成されている。
【0027】
主装置1はさらに、タイムスイッチ11、複数(j個)の局線インタフェース回路12(12-1〜12-j)、複数(i個)の内線インタフェース回路13(13-1〜13-i)、CPU14、ROM15、RAM16、データハイウェイインタフェース部17、正弦波データ生成器18およびトーン検出回路19を備えており、タイムスイッチ11、局線インタフェース回路12、内線インタフェース回路13、正弦波データ生成器18およびトーン検出回路19は、PCMハイウェイ20を介して互いに接続されている。
【0028】
またタイムスイッチ11、局線インタフェース回路12、内線インタフェース回路13およびデータハイウェイインタフェース部17は、データハイウェイ21を介して互いに接続されている。さらに、CPU14、ROM15、RAM16およびデータハイウェイインタフェース部17は、CPUローカルバス22を介して互いに接続されている。
【0029】
タイムスイッチ11は、CPU14の制御に基づいてPCMハイウェイ20上のタイムスロットの入れ替えを行なうことによって、局線インタフェース回路12および内線インタフェース回路13を任意に交換接続する。
【0030】
局線インタフェース回路12には、公衆回線や専用線などの局線L(L-1〜L-j)が必要に応じて接続される。局線インタフェース回路12は、接続された局線Lに関する局線インタフェース動作を行なう。局線インタフェース動作とは、局線Lを介して到来する音声信号(アナログ)のPCM信号への変換、タイムスイッチ11を介して与えられるPCM信号の音声信号(アナログ)への変換、局線Lの状態監視や、局線Lを介して接続された網に対する種々の信号の送出などである。また局線インタフェース回路12は、上記局線インタフェース動作に係わる種々の制御情報の授受を、データハイウェイ21、データハイウェイインタフェース部17およびCPUローカルバス22を介してCPU14との間で行なう。
【0031】
内線インタフェース回路13には、内線端末2が必要に応じて接続される。内線インタフェース回路13は、接続された内線端末に関する内線インタフェース動作を行なう。内線インタフェース動作は、内線端末2から出力されるPCM信号のPCMハイウェイ20への送出、タイムスイッチ11を介して与えられるPCM信号のPCMハイウェイ20からの抽出、内線端末2の状態監視や、内線端末2に対する種々の信号の送出などである。また内線インタフェース回路13は、上記内線インタフェース動作に係わる種々の制御情報の授受を、データハイウェイ21、データハイウェイインタフェース部17およびCPUローカルバス22を介してCPU14との間で行なう。
【0032】
CPU14は、ROM15に格納されている動作プログラムに基づいた処理を行うことで、タイムスイッチ11、局線インタフェース回路12および内線インタフェース回路13のそれぞれを総括制御し、ボタン電話装置における主装置としての動作を実現する。
【0033】
ROM15は、CPU14の動作プログラムや、その他の永続的に使用される各種のデータを記憶している。
【0034】
RAM16は、CPU14が各種の処理を行なう上で必要な各種の情報を記憶しておくためのものである。
【0035】
データハイウェイインタフェース部17は、データハイウェイ21とCPUローカルバス22との間でのデータの授受を行う。
【0036】
(第1の実施形態)
この実施形態は、図1における正弦波データ生成器18に関するものである。
【0037】
図2は本実施形態における正弦波データ生成器18の具体的な構成を示すブロック図である。
【0038】
この図に示すように本実施形態における正弦波データ生成器18は、加算器31、ラッチ回路32,33、乗算器34,35、出力処理部36、ラッチ回路37、比較部38、基準データレジスタ39、比較部40、タイマ41、ANDゲート42および初期化部43を有している。
【0039】
加算器31は、乗算器34の出力値と乗算器35の出力値とを加算し、加算値を正弦波データの現在値として出力する。なおこの加算器31の出力値は、信号レベルを示すデータ部と極性を示す符号とからなる。
【0040】
ラッチ回路32には、加算器31の出力値が入力されている。このラッチ回路32は、PCMハイウェイ20でのフレーム周期に同期し、かつ同一周波数fs(例えば8KHz)のクロック信号に応じたタイミングで加算器31の出力値を取り込んで保持する。そしてラッチ回路32は、保持している値を常時出力する。
【0041】
ラッチ回路33には、ラッチ回路32の出力値が入力されている。このラッチ回路33は、周波数fsのクロック信号に応じたタイミングでラッチ回路32の出力値を取り込んで保持する。そしてラッチ回路33は、保持している値を常時出力する。
【0042】
かくして、ラッチ回路32およびラッチ回路33は、加算器31からの出力を1フレーム周期分ずつ遅延させ、1フレーム前および2フレーム前における出力値をそれぞれ出力する。
【0043】
乗算器34は、所望の正弦波周波数およびラッチ回路32,33に与えられる信号の周波数fsに応じて決まる定数2cos(w)を、ラッチ回路32の出力値に乗算し、その結果得られる値を加算器31に与える。
【0044】
乗算器35は、ラッチ回路33の出力値に「−1」を乗じることで、データを反転させた上で、その結果得られる値を加算器31に与える。
【0045】
加算器31の出力値は、所定周波数の正弦波信号を示す正弦波データにおける現在値として、PCMハイウェイ20上で割り当てられたタイムスロットへと出力処理部36により出力される。
【0046】
ラッチ回路37には、加算器31の出力値のうちの符号が入力されている。このラッチ回路37は、周波数fsのクロック信号に応じたタイミングで加算器31の出力値の符号を取り込んで保持する。そしてラッチ回路37は、保持している符号を出力する。すなわちラッチ回路37は、加算器31からの出力のうちの符号を1フレーム周期分遅延させ、1フレーム前における加算器31からの出力値のうちの符号を出力する。
【0047】
比較部38には、ラッチ回路37が出力する符号と加算器31の出力値のうちの符号とが入力されている。比較部38は、ラッチ回路37が出力する符号が「正」で、かつ加算器31の出力値のうちの符号が「正」であるときにのみ「H」レベルを出力する。
【0048】
基準データレジスタ39は、所定の基準値ABSを示す基準値データを記憶しており、この基準値データを常時出力する。
【0049】
比較部40には、基準データレジスタ39が出力する基準値データと加算器31の出力値のうちのデータとが入力されている。比較部40は、これらの2つのデータが示す値を比較し、加算器31の出力値のうちのデータが示す値が基準値以下であるときにのみ「H」レベルを出力する。
【0050】
タイマ41は、ANDゲート42の出力が「H」レベルとなったことに応じてクリアされる。そしてタイマ41は、クリアされた時点からの経過時間をカウントして所定のリセット周期をカウントし終わったならば、次にクリアされるまでの間のみ出力を「H」とする。
【0051】
ANDゲート42には、比較部38、比較部40およびタイマ41のそれぞれの出力が与えられている。そしてANDゲート42は、比較部38、比較部40およびタイマ41のそれぞれの出力が全て「H」であるときにのみ「H」レベルを出力する。
【0052】
初期化部43には、ANDゲート42の出力が与えられている。そして初期化部43は、ANDゲート42の出力が「H」となったことに応じて、ラッチ回路32およびラッチ回路33の保持値を所定の初期値に初期化する。
【0053】
次に、以上のように構成された正弦波データ生成器18の動作につき説明する。
【0054】
最初にラッチ回路32の保持値を「0」に、かつラッチ回路33の保持値を所望の正弦波周波数と振幅とに応じて決まる定数Asin(w)に設定しておく。そうすると、加算器31の出力は−Asin(w)となる。
【0055】
以後、クロック信号のタイミングでラッチ回路32,33の保持値が更新されることにより、加算器31の出力値も変化される。
【0056】
このとき加算器31の出力値Y(h)は、クロック信号の1周期前および2周期前の加算器31の出力値をそれぞれY(h-1),Y(h-2)と示すならば、
(h)=Y(h-1)×2cos(w)−Y(h-2)
となり、所望の正弦波周波数の正弦波信号をfsなるサンプリング周波数でサンプリングした際のレベル値が出力値Yとして現れることとなる。
【0057】
すなわち、加算器31の出力は、−Asin(w)を初期値として定数2cos(w)および定数Asin(w)により定まる周波数と、定数Asin(w)により定まる振幅とを有した図3に示すような正弦波信号をfsなるサンプリング周波数でサンプリングして示した正弦波データとなる。そしてこの正弦波データは、出力処理部36によって適切なタイミングでPCMハイウェイ20へと送出される。この正弦波データは、例えばタイムスイッチ11での出力の断続制御によって任意のトーン信号を生成するために使用される。
【0058】
ところで出力値Yはディジタル値であるが、そのビット数は有限である。このため、乗算器34の出力はまるめられた結果となっており、正規の値との誤差が生じている。そしてこのような誤差は、繰り返しの演算により蓄積されて行くこととなる。
【0059】
そこで、ラッチ回路37、比較部38、基準データレジスタ39、比較部40、タイマ41、ANDゲート42および初期化部43により構成されるリセット回路によって、ラッチ回路32,33の保持値のリセットを行うこととしている。
【0060】
すなわち、まずタイマ41では、出力値Yの誤差が許容できる範囲に収まる時間を考慮して適切に設定されたリセット周期を計時しており、このリセット周期を計時し終わると、以降に出力を「H」とする。従って、ANDゲート42の出力は、タイマ41がリセット周期を計時し終わるまでは「H」となることはない。
【0061】
一方、比較部38では、現在の出力値Y(h)と、ラッチ回路37に保持された1フレーム前の出力値Y(h-1)の符号とを比較し、出力値Yの符号が正から負に変化するか否かを監視している。そして出力値Y(h-1)の符号が正で、かつ出力値Y(h)の符号が負となったならば、出力値Yの符号が正から負に変化したことになるので、比較部38は出力を「H」とする。
【0062】
また比較部40は、出力値Yの符号を除くデータ、すなわち出力値Yの絶対値と、基準データレジスタ39に保持された基準値データが示す基準値ABSとを比較している。そして出力値Yの絶対値が基準値ABS以下であるときに、比較部40は出力を「H」とする。なお基準値ABSは、リセット後の出力値Yの初期値である−Asin(w)よりも小さな適切な値に設定される。
【0063】
かくして、タイマ41がリセット周期を計時し終わった後、出力値Yの符号が正から負に変化した直後の出力値Yの絶対値が基準値ABS以下であるときにのみ、ANDゲート42の全ての入力が「H」となり、ANDゲート42の出力が「H」となる。
【0064】
そしてANDゲート42の出力が「H」となったことに応じて初期化部43は、ラッチ回路32の保持値を「0」に、かつラッチ回路33の保持値を定数Asin(w)にそれぞれ初期化する。
【0065】
また、ANDゲート42の出力が「H」となったことに応じてタイマ41もリセットされ、新たなリセット周期の計時が開始される。
【0066】
このようにして、出力値Yは定期的に−Asin(w)にリセットされることとなり、誤差は一定範囲内に抑えられる。
【0067】
そして本実施形態では、出力値Yが正から負に変化した直後にリセットすることとしているので、出力値Yが正レベルから−Asin(w)までという通常は生じ得ない急峻な変化をしてしまうことが防止される。これにより波形のひずみを低減でき、この正弦波データを用いて生成されたトーンに生じるブツ音を低減できる。
【0068】
ところで、出力値Yの符号が正から負に変化した直後の出力値Yは、必ず0〜−Asin(w)の範囲となるが、この値が−Asin(w)に近いほどリセット後の出力値Yがほぼ同レベルとなってしまい、例えば図4に示すように波形がひずんでしまう。
【0069】
しかしながら本実施形態では、リセットの実行を出力値Yの絶対値がAsin(w)よりも小さく設定された基準値ABS以下である場合に限定しているので、上述のような原因による波形のひずみを低減でき、この正弦波データを用いて生成されたトーンに生じるブツ音を低減できる。
【0070】
なお、基準値ABSを小さくするほど波形のひずみを低減することが可能であるが、リセット実行の条件が整う確率が低下してリセット周期が長くなりすぎてしまうおそれがあるので、それらのバランスを考慮して基準値ABSを適切に設定することが望ましい。
【0071】
(第2の実施形態)
この実施形態は、図1におけるトーン検出回路19に関するものである。
【0072】
図5は本実施形態におけるトーン検出回路19の具体的な構成を示すブロック図である。
【0073】
この図に示すように本実施形態におけるトーン検出回路19は、速度変換部51、圧縮/リニア変換部52、演算処理部53、絶対値変換部54、ピーク検出部55、加算部56、判定部57、レジスタ58、CPUインタフェース59、カウンタ60およびリセット信号生成部61を有している。
【0074】
速度変換部51は、PCMハイウェイ20に接続されている。速度変換部51は、PCMハイウェイ20上で1/fsのフレーム周期(例えば125μs)で多重化されている多数のチャネルのうちの所定の1チャネルを抽出し、速度を低下させて連続したデータとする。すなわち、速度変換部51は1/fsの周期で値が変化して行くPCM信号を再生する。
【0075】
圧縮/リニア変換部52には、速度変換部51から出力されるPCM信号が与えられる。このPCM信号は、所定の圧縮方式により圧縮されている。そこで圧縮/リニア変換部52は、速度変換部51から出力されるPCM信号を伸長して、リニアなPCM信号に戻す。
【0076】
演算処理部53は、圧縮/リニア変換部から与えられるPCM信号を用いて後に詳述する積和演算を複数の着目周波数のそれぞれについて行って、その積和演算の結果を絶対値変換部54へと与える。
【0077】
絶対値変換部54は、演算処理部53の出力値の絶対値を算出する。
【0078】
ピーク検出部55は、絶対値変換部54からの出力値のピーク値を着目周波数毎に検出する。
【0079】
加算部56は、ピーク検出部55で検出された着目周波数毎のピーク値の和を算出する。
【0080】
判定部57は、カウンタ60が所定の繰り返し演算回数Nをカウントし終えた際の加算部56からの出力値に基づいて、検出対象としているトーン信号の有無を判定する。判定部57は、その判定結果を示す判定データを出力する。
【0081】
レジスタ58は、判定部57が出力する判定データを記憶保持する。
【0082】
CPUインタフェース59は、レジスタ58に記憶保持されている判定データを所定のタイミングでCPUローカルバス22へと送出する。
【0083】
カウンタ60には、周波数fsのクロック信号が与えられている。カウンタ60は、この周波数fsのクロック信号を繰り返し演算回数Nまで巡回的にカウントする。カウンタ60は、所定の繰り返し演算回数Nをカウントし終えた際には、カウントアップ信号を判定部57およびリセット信号生成部61のそれぞれへと与える。
【0084】
リセット信号生成部61は、カウンタ60からカウントアップ信号が与えられたことに応じて、演算処理部53およびピーク検出部55の動作状態を所定の初期状態にリセットするためのリセット信号を出力する。
【0085】
図6は図5中の演算処理部53の具体的構成を示すブロック図である。
【0086】
この図に示すように演算処理部53は、減算器71、加算器72、直列接続されたp個のフリップフロップ(FF)73(73-1,73-2…,73-j)、直列接続されたp個のフリップフロップ(FF)74(74-1,74-2…,74-j)、係数発生器75および乗算器76を有してなる。
【0087】
減算器71には、圧縮/リニア変換部52の出力値が入力されている。また減算器71には、最終段のフリップフロップ74-jの出力値が入力されている。そして減算器71は、圧縮/リニア変換部52の出力値からフリップフロップ74-jの出力値を減算し、その減算値を出力する。
【0088】
加算器72には、減算器71の出力値が入力されている。また加算器72には、乗算器76の出力値が入力されている。そして加算器72は、これらの2つの値を加算し、その加算値を出力する。この加算器72の出力値は、積和演算の結果の値として絶対値変換部54へと出力される。
【0089】
フリップフロップ73のうちの最上段のフリップフロップ73-1には、加算器72の出力値が入力されている。また各フリップフロップ73には、フレーム周波数fsのp倍の周波数をもったクロック信号が与えられている。かくしてフリップフロップ73は、加算器72の出力値をフレーム周期の1/pの周期で順次転送していく。各フリップフロップ73の保持値は、リセット信号生成部61から出力されるリセット信号によってリセットされる。
【0090】
フリップフロップ74のうちの最上段のフリップフロップ74-1には、フリップフロップ73のうちの最終段のフリップフロップ73-jの出力値が入力されている。また各フリップフロップ74には、フレーム周波数fsのp倍の周波数をもったクロック信号が与えられている。かくしてフリップフロップ74は、フリップフロップ73-jの出力値をフレーム周期の1/pの周期で順次転送していく。各フリップフロップ74の保持値は、リセット信号生成部61から出力されるリセット信号によってリセットされる。
【0091】
係数発生器75は、p個の着目周波数のそれぞれに応じた係数を、フレーム周波数fsのp倍の周波数をもったクロック信号に同期したタイミングで変化させつつ順次出力する。すなわち係数発生器75は、1フレーム期間をp等分した各期間にそれぞれ別の着目周波数に応じた係数を出力する。
【0092】
乗算器76は、フリップフロップ73-jの出力値に係数発生器75が出力する係数を乗算する。
【0093】
図7は図5中のピーク検出部55の具体的な構成を示すブロック図である。
【0094】
この図に示すようにピーク検出部55は、比較器81、セレクタ82および直列接続されたp個のフリップフロップ(FF)83(83-1,83-2…,83-j)を有してなる。
【0095】
比較器81には、絶対値変換部54の出力値と、フリップフロップ83のうちの最終段のフリップフロップ83-jの出力値とがそれぞれ与えられる。そして比較器81は、これら2つの値を比較し、絶対値変換部54の出力値のほうがフリップフロップ83-jの出力値よりも大きい場合に「H」レベルをセレクタ82へと与える。
【0096】
セレクタ82には、絶対値変換部54の出力値とフリップフロップ83-jの出力値とがそれぞれ与えられる。そしてセレクタ82は、比較器81から「H」レベルが与えられているときには絶対値変換部54の出力値を、また比較器81から「L」レベルが与えられているときにはフリップフロップ83-jの出力値をそれぞれ選択して出力する。
【0097】
フリップフロップ83のうちの最上段のフリップフロップ83-1には、セレクタ82の出力値が入力されている。また各フリップフロップ83には、フレーム周波数fsのp倍の周波数をもったクロック信号が与えられている。かくしてフリップフロップ83は、セレクタ82の出力値をフレーム周期の1/pの周期で順次転送していく。そして各フリップフロップ83のそれぞれの出力は、各着目周波数に関するピーク値として個々に加算部56へと与えられる。なお各フリップフロップ83の保持値は、リセット信号生成部61から出力されるリセット信号によってリセットされる。
【0098】
次に以上のように構成されたトーン検出回路19の動作につき説明する。
【0099】
なおここでは、305Hz〜640Hzの周波数帯域内のいずれかの周波数を持つBT(Busy Tone)信号を検出することとして動作を説明する。
【0100】
このようなBT信号の検出を行う場合、着目周波数は305Hz〜640Hzの帯域内の4個の周波数f1,f2,f3,f4に設定される。
【0101】
従って、フリップフロップ73,74,81,83の数は、それぞれ4個である。またこれらのフリップフロップ73,74,81,83に与えられるクロック信号の周波数はfsの4倍であり、fsが8KHzであるとするならば32KHzとなる。
【0102】
PCMハイウェイ20の伝送データに多重化されている多数のチャネルのうちのBT信号の検出対象となるチャネルが速度変換部51により抽出される。PCMハイウェイ20では各チャネルのシリアルデータが時分割多重されているので、速度変換部51により抽出されるデータはバースト状に存在している。そこでこの抽出されたデータは、速度変換部51によりパラレル変換および速度低減がなされて、フレーム周期毎に1サンプリング値に相当するデータ(ただしここでは圧縮されている)が存在する連続したデータに変換される。
【0103】
このように連続データに変換されたデータは、次に圧縮/リニア変換部52により伸長されて信号レベルを直接的に示すデータに戻された後、演算処理部53に与えられる。
【0104】
かくして演算処理部53では、1フレーム期間に渡り1つのサンプリング値が減算器71へと与えられる。
【0105】
一方、演算処理部53から絶対値変換部54へと出力するべき値、すなわち演算処理部53での積和演算結果となる加算器72の出力値(以下、積和演算値と称する)は、フレーム期間の1/4の周期毎にフリップフロップ73-1〜73-kおよびフリップフロップ74-1〜74-kを順次転送されていく。
【0106】
かくして、フリップフロップ73の最終段(ここでは4段目)のフリップフロップ73-kおよびフリップフロップ74の最終段(ここでは4段目)のフリップフロップ74-kのそれぞれの出力値は、1フレーム周期前および2フレーム周期前の加算器72の出力値となる。
【0107】
かくして減算器71では、圧縮/リニア変換部52から与えられるサンプリング値から、2フレーム周期前における積和演算値が減算される。ただし、圧縮/リニア変換部52から与えられるサンプリング値は1フレーム周期の間は同一値であるのに対し、フリップフロップ74-kの出力値は後述するように1フレーム周期を4等分したそれぞれの期間で異なる値となる。従って、減算器71の出力値も1フレーム周期を4等分したそれぞれの期間で異なる値となる。
【0108】
一方、乗算器76では、1フレーム周期前における積和演算値に係数発生器75が出力する係数が乗算される。ここで係数発生器75は、フレーム周波数の4倍の周波数を持つクロック信号に同期して4つの着目周波数のそれぞれに応じた係数を順次出力する。すなわち1フレーム周期を4等分し、着目周波数f1,f2,f3,f4のそれぞれに応じた係数を順に出力する。またフリップフロップ73も4段構成であり、転送クロックとして係数発生器75に与えられるのと同一のクロック信号を用いているから、フリップフロップ73-kの出力値は、1フレーム周期を4等分したそれぞれの期間で異なる値となる。
【0109】
かくして乗算器76では、1フレーム周期を4等分したそれぞれの期間で異なる乗算が行われるのであって、その出力値も1フレーム周期を4等分したそれぞれの期間で異なる。
【0110】
加算器72には減算器71および乗算器76のそれぞれから、1フレーム周期を4等分したそれぞれの期間で異なる値が与えられるので、加算器72では各タイミングで2つの値が加算される。
【0111】
このようにして図8に示すように、1フレーム周期内において4回の積和演算処理が時分割に行われる。そして1フレーム周期を4等分したそれぞれの期間では、1番目の期間は第1の着目周波数f1に応じた係数K(f1)が関わる値を用いて、2番目の期間は第2の着目周波数f2に応じた係数K(f2)が関わる値を用いて、3番目の期間は第3の着目周波数f3に応じた係数K(f3)が関わる値を用いて、そしての期間は第4の着目周波数f4に応じた係数K(f4)が関わる値を用いて、それぞれ積和演算処理が行われるのである。すなわち、各着目周波数に関する積和演算処理が時分割に行われる。なお、図8において各値の末尾に付してある「_f1」「_f2」「_f3」「_f4」の表記は、その値が着目周波数f1、f2、f3、f4のいずれに関するものであるかを示している。
【0112】
そして各着目周波数に関する積和演算による出力値V(h)は、圧縮/リニア変換部52から与えられるサンプリング値をX(h)、フリップフロップ73-kの出力値をV(h-1)、フリップフロップ74-kの出力値をV(h-2)、そして係数発生器75が発生する係数をKとそれぞれ示すならば、
(h)=X(h)−V(h-2)+V(h-1)×K(f)
となる。
【0113】
なお、K(f)は着目周波数に応じて決まるものであって、
(f)=2cos(2×π×k(f)/N(f)
となる。
【0114】
ここで、kは着目周波数に応じて決まる定数である。またN(f)は着目周波数に応じて決まる積和演算の繰り返し回数(サンプル点数)である。これら定数kおよび繰り返し回数N(f)は、着目周波数をftone、積和演算の繰り返し周波数をfsと示すと、
ftone/fs≒k(f)/N(f)
なる関係を満たし、かつそれぞれが整数となるように設定される。
【0115】
このようにして求められる出力値Vは、積和演算を繰り返すに従って増減を繰り返すこととなるが、入力信号中に着目周波数の成分が存在する場合にのみ、出力値Vのピーク値が増大していく。
【0116】
図9は周波数fxを着目周波数としての積和演算を行い、かつ入力信号周波数をfx、fy、fzと変化させた場合の出力値Vの変化を示す図である。
【0117】
この図から明らかなように、着目周波数と同一周波数fxを入力した場合には、出力値Vのピーク値は増大していくが、他の周波数fy,fzを入力したときには出力値Vのピーク値は増大しない。
【0118】
従って、ある程度の期間に渡って積和演算を繰り返した後の出力値Vのピーク値に基づいて、着目周波数が入力信号中に存在するか否かを判定することが可能となるのである。
【0119】
しかし、出力値Vのピーク値は、図9からも分かるように正および負の双方に生じ得る。そこで出力値Vは、絶対値変換部54により絶対値に変換された上で、ピーク検出部55によりピーク値が検出される。
【0120】
ピーク検出部55では、このピーク値の検出は以下のようにして行われる。
【0121】
すなわち絶対値変換部54の出力値は、比較器81に与えられ、フリップフロップ83-kの出力値と比較される。
【0122】
ここでフリップフロップ83-1〜83-kでは、セレクタ82の出力値をフレーム期間の1/4の周期毎に順次転送しているので、最終段のフリップフロップ83-kの出力値は1フレーム周期前のセレクタ82の出力値である。
【0123】
かくして、絶対値変換部54の出力値は比較器81にて、1フレーム周期前のセレクタ82で選択された値と比較されるのである。そしてこの比較器81での比較の結果、絶対値変換部54の出力値とフリップフロップ83-kの出力値とのうちで大きい方の値がセレクタ82によって選択される。ここでセレクタ82により選択された値は、フリップフロップ83-1に入力されてフリップフロップ83-1〜83-kを順次転送されることとなる。
【0124】
このようにして、フリップフロップ83-1〜83-kには各着目周波数に関しての絶対値変換部54の出力値のピーク値がそれぞれ保持されるのである。そこで、フリップフロップ83-1〜83-kのそれぞれの出力値が各着目周波数に関しての積和演算結果のピーク値として加算部56に個々に与えられる。
【0125】
このようにしてピーク検出部55から与えられるp個のピーク値は、加算部56にて互いに加算されて、これにより求められる各ピーク値の総和値が判定部57へと与えられる。
【0126】
さて、以上のように演算処理部53による積和演算が繰り返し行われている最中において、カウンタ60ではその積和演算が実行された回数をカウントするために、周波数がフレーム周波数fsであるクロック信号のカウントを行っている。そして所定の繰り返し回数Nをカウンタ60がカウントし終えたならば、カウンタ60から判定部57およびリセット信号生成部61へとカウントアップ信号が与えられる。
【0127】
このようにしてカウントアップ信号がカウンタ60から与えられると判定部57は、その時点における加算部56の出力値が所定のしきい値を超えているか否かを確認することで、検出対象としているBT信号が入力信号中に含まれているか否かを判定する。
【0128】
すなわち、BT信号が到来しているのであれば、着目周波数の全てが含まれているのであるから、各着目周波数のそれぞれに関する積和演算値のピーク値がいずれも大きな値となる。つまり、図10に示すような周波数スペクトルが検出されてことと等価となる。
【0129】
さて、各着目周波数に関する積和演算の結果は、図10に示しているようにある程度のバンド幅を持った周波数スペクトルとなる。そしてそのバンド幅は、積和演算の繰り返し回数により決まる。
【0130】
そこで隣接する着目周波数に関して求められる周波数スペクトルどうしが図10に示すように適度に重なり合うように各着目周波数に関する積和演算の繰り返し回数を設定しておく。
【0131】
そうすることによって、各着目周波数のそれぞれに関する積和演算値のピーク値を加算部56で加算することで、図10に示すような各着目周波数のスペクトルの和が求められることとなり、図11に示すような感度分布で各周波数の信号を検出することとなる。
【0132】
すなわち、着目周波数と同一周波数の信号が到来しているときはもちろんのこと、着目周波数どうしの中間の周波数の信号が到来しているときにも加算部56の出力値が十分に大きな値となるのであり、図11に示すような周波数特性のバンドパスフィルタを通したのと同様な結果が得られる。
【0133】
従って、加算部56の出力値が一定値以上であるならば、図11に示すような帯域内の信号、すなわちBT信号が到来していると判定することができるのである。
【0134】
そして判定部57での判定結果を示す判定データは、レジスタ58に記憶保持された上で、CPUインタフェース59により所定のタイミングでCPUローカルバス22へと送出され、CPU14へと通知される。
【0135】
なお、この判定部57による判定処理と並行して、カウントアップ信号がカウンタ60から与えられことに応じてリセット信号生成部61から演算処理部53およびピーク検出部55へとリセット信号が与えられる。これにより、演算処理部53のフリップフロップ73-1〜73-k,74-1〜74-kおよびピーク検出部55のフリップフロップ83-1〜83-kがリセットされ、新たな積和演算処理および積和演算値のピーク値検出が開始される。
【0136】
ところで、積和演算を繰り返す回数は着目周波数毎で異なり、理論的には個々の着目周波数に応じた繰り返し回数の積和演算により得られた値を用いての判定を判定部57にて行うことになる。
【0137】
しかしながら、各着目周波数にそれぞれ応じた繰り返し回数N(f)をとり得る値のうちである基準回数に最も近い値に設定し、かつカウンタ60がカウントする繰り返し回数Nを上記基準回数に設定しておく。このことにより、上述のようにカウンタ60が繰り返し回数Nをカウントし終えた時点における各着目周波数に関する積和演算値のピーク値に基づいての判定を判定部57にて行うことが可能となる。
【0138】
なぜならば、図9からも分かるように繰り返し回数が多少変化しても、積和演算結果のピーク値は大きくは変化しないのであるから、繰り返し回数N(f)との差が少ない繰り返し回数Nの時点でのピーク値であっても、BT信号の有無の判定精度にはほとんど影響しないためである。
【0139】
なお繰り返し回数Nは、検出対象トーン(ここではBT信号)の継続時間中に少なくとも1回は、N回の積和演算を完了することが可能なように適切に設定される。
【0140】
このように本実施形態によれば、各フレームにおける入力信号のレベルから2フレーム周期前の積和演算値を減算して得られた値と、1フレーム周期前の積和演算値に着目周波数に応じた係数を乗算して得られた値とを加算することで行う積和演算処理を所定の繰り返し回数に渡り行い、そのピーク値を検出することで、Goertzelアルゴリズムを利用して着目周波数をそれぞれ中心周波数とする複数の周波数スペクトルを演算する。その周波数スペクトルのバンド幅は積和演算の繰り返し回数と積和演算に用いる係数とにより決まるので、隣接する周波数スペクトルどうしが重なるように設定した上で、各周波数スペクトルを合成することで1つのバンドパスフィルタを構成し、BT信号の検出を行っている。
【0141】
従って、基本的なディジタル回路によるディジタル処理により容易に行うことが可能な処理のみによりBT信号の検出を行うことが可能であり、集積化によって小型化を図ることが可能である。
【0142】
また本実施形態では、各着目周波数のピーク値を加算することで各周波数スペクトルを合成するようにしているので、着目周波数どうしの中間の周波数に関しても十分な感度を得ることが可能であるために、後述の第3実施形態の場合に比べて着目周波数の間隔を大きくすることができる。この結果、ある周波数帯域をカバーするのに必要な着目周波数の数を減らすことが可能となり、積和演算処理の多重数を低減できることから、構成の簡易化と処理速度の低減を図ることが可能となり、簡易に実現することが可能となる。
【0143】
また本実施形態によれば、1フレーム期間をp等分して、p個の着目周波数のそれぞれに関する積和演算処理を時分割で処理するようにしているので、演算処理部53における減算器71、加算器72、乗算器76を各着目周波数で共用することが可能であり、個別に設ける場合に比べてさらに回路規模を縮小することが可能である。
【0144】
また本実施形態によれば、各着目周波数に関する積和演算の繰り返し回数N(f)をある基準回数に最も近い値に設定した上で、BT信号の有無の判定に用いる積和演算値を上記基準回数の積和演算により得られた値としているので、加算部56では各着目周波数に関するピーク値の最新の値を単純に加算すれば良く、個々の繰り返し回数N(f)の管理を行う必要がないので、さらに構成を簡易とすることが可能である。
【0145】
(第3の実施形態)
この実施形態は、図1におけるトーン検出回路19に関するものである。
【0146】
図12は本実施形態におけるトーン検出回路19の具体的な構成を示すブロック図である。なお、図1および図5と同一部分には同一符号を付し、その詳細な説明は省略する。
【0147】
この図に示すように本実施形態におけるトーン検出回路19は、速度変換部51、圧縮/リニア変換部52、演算処理部53、絶対値変換部54、ピーク検出部55、レジスタ58、CPUインタフェース59、カウンタ60、リセット信号生成部61、しきい値比較部91および判定部92を有している。
【0148】
すなわち本実施形態においてトーン検出回路19は、前記第2実施形態における加算部56および判定部57に代えてしきい値比較部91および判定部92を備えたものとなっている。
【0149】
しきい値比較部91は、ピーク検出部55で検出された各着目周波数のピーク値をそれぞれ所定のしきい値と比較し、その比較結果を判定部92へと通知する。
【0150】
判定部92は、カウンタ60が所定の繰り返し演算回数Nをカウントし終えた際のしきい値比較部91からの通知内容に基づいて、検出対象としているトーン信号の有無を判定する。判定部92は、その判定結果を示す判定データを出力する。
【0151】
図13はしきい値比較部91の具体的な構成を示すブロック図である。
【0152】
この図に示すようにしきい値比較部91は、p個の比較回路101(101-1,101-2…,101-k)としきい値レジスタ102とから構成されている。
【0153】
各比較回路101には、ピーク検出部55で検出された各着目周波数のピーク値がそれぞれ入力されている。また各比較回路101には、しきい値レジスタ102に記憶保持されたしきい値が共通に与えられている。そして各比較回路101はそれぞれ、ピーク値をしきい値と比較し、ピーク値がしきい値よりも大きいか否かを判定部92へと通知する。
【0154】
しきい値レジスタ102は、予め設定された所定のしきい値を記憶保持しており、このしきい値を常時出力する。
【0155】
かくして本実施形態のトーン検出回路19は、各着目周波数に関するピーク値を加算するのではなく、それらを個々にしきい値と比較する。そして判定部92では、各着目周波数に関するピーク値のいずれか1つでもしきい値を超えているとしきい値比較部91で判定されたならば、BT信号が到来していると判定する。
【0156】
さて、前述した第2実施形態の場合、各着目周波数のスペクトルを合成しているために高調波の影響を受けやすく、検出精度が低くなるおそれがある。
【0157】
しかしながら本実施形態によれば、各着目周波数のスペクトルを合成すること無しに個々にしきい値と比較するので、高調波の影響を受けること無しに精度良くBT信号の検出を行うことが可能である。
【0158】
ただし本実施形態の場合には、着目周波数どうしの中間の周波数については感度が低くなってしまうことから、このような中間の周波数についての感度低下を小さく抑えるためには例えば図14に示すように前述した第2実施形態の場合よりも着目周波数の密度を高める必要がある。従って、ある周波数帯域をカバーするのに必要な着目周波数の数が増えることなり、積和演算処理の多重数が増加することから、処理速度の上昇が必要となる。
【0159】
(第4の実施形態)
この実施形態は、図1におけるトーン検出回路19に関するものである。
【0160】
図15は本実施形態におけるトーン検出回路19の具体的な構成を示すブロック図である。なお、図1、図5および図12と同一部分には同一符号を付し、その詳細な説明は省略する。
【0161】
この図に示すように本実施形態におけるトーン検出回路19は、速度変換部51、圧縮/リニア変換部52、演算処理部53、絶対値変換部54、ピーク検出部55、レジスタ58、カウンタ60、リセット信号生成部61、しきい値比較部91、判定部92、しきい値比較部111、マトリクス部112、レジスタ113およびCPUインタフェース114を有している。
【0162】
すなわち本実施形態においてトーン検出回路19は、前記第3実施形態におけるトーン検出回路19の構成に加えてしきい値比較部111、マトリクス部112およびレジスタ113を備えるとともに、前記第3実施形態におけるCPUインタフェース59に代えてCPUインタフェース114を備えたものとなっている。
【0163】
また本実施形態では、BT信号検出用に305Hz〜640Hzの周波数帯域内に設定された複数の着目周波数の他に、DTMF(Dual Tone Multi Frequency)信号の要素となり得る周波数(例えば697Hz、770Hz、852Hz、941Hz、1209Hz、1336Hz、1477Hz、1633Hzの8周波数)にそれぞれ設定された着目周波数が用いられる。従って、BT信号検出用の着目周波数が上述の第3実施形態に示すように8周波数であるとするならば、着目周波数の数pは「16」となる。
【0164】
従って、ピーク検出部55の出力は16本となる。そしてこの16本の出力のうちのBT信号検出用の着目周波数に関する8本がしきい値比較部91に、また残りの8本、すなわちDTMF信号検出用の着目周波数に関する8本がしきい値比較部111にそれぞれ入力される。
【0165】
しきい値比較部111は、しきい値比較部91と同様な構成を有する。そしてしきい値比較部111は、DTMF信号検出用の着目周波数に関するピーク検出部55からの各出力値を所定のしきい値と比較し、ピーク検出部55からの各出力値がしきい値より大きいか否かをマトリクス部112に対してそれぞれ通知する。
【0166】
マトリクス部112は、カウンタ60が繰り返し演算回数Nをカウントし終えた際のしきい値比較部91からの通知内容に基づいて、DTMF信号の到来の有無の判定および到来しているDTMF信号の種類の識別を行う。マトリクス部112は、その判定結果を示す判定データを出力する。
【0167】
レジスタ113は、マトリクス部112が出力する判定データを記憶保持する。
【0168】
CPUインタフェース114は、レジスタ58およびレジスタ113にそれぞれ記憶保持されている判定データを所定のタイミングでCPUローカルバス22へと送出する。
【0169】
かくしてこのトーン検出回路19では、BT信号の検出は前述の第3実施形態の場合と全く同様になされる。そしてこのBT信号の検出と並行して、図16に示すようにDTMF信号の各要素周波数に関する周波数スペクトルが求められる。なお、DTMF信号は、要素周波数のうちの2つの組み合わせによりなるものであり、中間の周波数の検出を行う必要はないので、求める周波数スペクトルのバンド幅は周波数の許容偏差をカバーできる程度であればよい。
【0170】
そしてピーク検出部55からのDTMF信号検出用の着目周波数に関する出力値のそれぞれをしきい値比較部111にてしきい値と比較し、その結果いずれか2つの出力値がしきい値以上となっていればDTMF信号が到来していることが分かり、かつそのしきい値以上となっている2つの出力値がいずれの要素周波数に対応するものであるかを判定することで到来しているDTMF信号の種類を判定することが可能であるので、そのような判定がマトリクス部112により行われる。
【0171】
このように本実施形態によれば、若干の構成を付加するだけで、トーン検出回路19にてBT信号の検出とDTMF信号の検出との双方を行うことが可能である。
【0172】
なお、本発明は前記各実施形態に限定されるものではない。例えば前記各実施形態では、本発明のディジタル正弦波データ生成器およびトーン検出回路をボタン電話システムに用いられるものとして例示して説明しているが、例えば電話端末装置などのような他の装置に適用されるものとして実現することも可能である。
【0173】
また前記第1実施形態では、1つの周波数の正弦波データのみを生成するものとなっているが、複数の周波数の正弦波データを時分割に発生するようにしても良い。すなわち、ラッチ回路32およびラッチ回路33を図6に示すフリップフロップ73およびフリップフロップ74と同様に多段構成とするとともに、乗算器34にて乗算する係数を図6に示す係数発生器75と同様なものを用いて時分割に発生するようにすればよい。そして初期化部43は、複数段のラッチ回路33のそれぞれに設定する定数Asin(w)を各正弦波周波数と振幅とに応じてそれぞれ異なる値とする。
【0174】
また前記第2乃至第4の実施形態では、積和演算の繰り返し回数N(f)が着目周波数に応じて異なるにも拘わらずに、同一回数の積和演算による積和演算値のピーク値を用いてトーン信号の検出を行うこととしているが、着目周波数毎にN(f)回の積和演算による積和演算値のピーク値を順次取得して記憶しておき、全ての着目周波数に関する積和演算値が取得できるのを待って、それらを用いてのトーン信号の検出を行うようにしても良い。このようにするならば、積和演算の繰り返し回数N(f)の設定の自由度が高くなり、それを検出精度をより向上させるように設定するなどの処置をとることが可能となる。
【0175】
また前記第2乃至第4実施形態では、演算処理部53、絶対値変換部54およびピーク検出部55では、各着目周波数に関する処理を時分割で行っているが、別々の処理系を設けておのおので並行に処理を行うことも可能である。この場合、前記第2乃至第4実施形態に比べて構成は若干複雑となるが、処理速度は低くて済む。
【0176】
また前記第2乃至第4実施形態では、1チャネルに関してのトーン検出のみを行うものを例示しているが、複数チャネルに関するトーン検出を時分割に行うようにしても良い。この場合、変数pを着目周波数の数と時分割処理するチャネル数との積とすれば良い。またこの場合には、加算部56、判定部57、しきい値比較部91、判定部92、しきい値比較部111およびマトリクス部112も時分割処理を行うこととする。収容回線が100回線であり、8チャネル分のトーン検出回路が必要とされるのであれば、この8チャネル分を時分割処理することで単一のトーン検出回路19を設けるだけで良くなり、回路規模の縮小とそれに伴うコスト低減および小型化促進ならびに消費電力の低減に大きく寄与する。
【0177】
また前記第2乃至第4の実施形態では、演算処理部53およびピーク検出部55では、各着目周波数に関する値をそれぞれ保持しておくために多段接続したフリップフロップ73,74,83を用いるようにしているが、RAMやFIFOメモリなどを用いるようにしても良い。着目周波数の数pや多重処理するチャネル数が大きく、フリップフロップの段数が非常に大きくなってしまう場合には、これらのメモリを用いた方が回路規模が縮小できる場合がある。
【0178】
また前記第2乃至第4の実施形態では、変数nを「1」として、乗算器76では1フレーム周期前の積和演算値に係数を乗算し、かつ減算器71では2フレーム周期前の積和演算値を入力値から減算することとしているが、変数nは任意であって良く、例えば「2」として乗算器76へは2フレーム周期前の積和演算値を、かつ減算器71には4フレーム周期前の積和演算値をそれぞれ与えるようにしても良い。そしてこのような場合には、例えば奇数番目のフレームと偶数番目のフレームとでそれぞれ異なる着目周波数に関する処理を行うようにするなどの処置をとることも可能である。
【0179】
また前記第4の実施形態では、BT信号の検出に関しては前記第3実施形態と同一の構成を用いたものとなっているが、前記第2実施形態と同一の構成を用いることも可能である。
【0180】
このほか、本発明の要旨を逸脱しない範囲で種々の変形実施が可能である。
【0181】
【発明の効果】
第1の発明によれば、所定の周波数の正弦波信号のレベルを示すディジタル値を所定の周期毎に出力ディジタル値として出力することで正弦波データを生成するディジタル正弦波データ生成器において、1周期前における出力ディジタル値に前記正弦波信号の周波数に応じて定まる定数を乗算した第1参照値を生成する乗算手段と、2周期前における出力ディジタル値を反転させた第2参照値を生成する反転手段と、前記乗算手段により生成された前記第1参照値と前記反転手段により生成された前記第2参照値とを加算して現時点における出力ディジタル値を生成する加算手段と、前記第1参照値を「0」に、また前記第2参照値を前記正弦波信号の周波数に応じて定まる初期値にそれぞれリセットするのリセット手段と、このリセット手段によるリセットが行われてからの経過時間を計時する計時手段と、前記加算手段で生成された前記出力ディジタル値の極性が正から負に変化したことを検出する極性変化検出手段と、前記出力ディジタル値の絶対値が所定の基準値以下である低レベル状態であることを検出するレベル確認手段と、前記計時手段により計時された経過時間が所定時間を超えている状態において、前記極性変化検出手段により極性変化が検出された際に前記レベル確認手段により前記低レベル状態であることが検出されていたならば前記リセット手段にリセットを行わせるリセット制御手段とを備えたので、このようなディジタル処理により実現可能な処理によってのみ正弦波データの生成が行え、簡易なディジタル回路により、集積化による小型化、低コスト化および低消費電力化を実現可能で、しかもひずみの少ない正弦波データを生成することが可能なディジタル正弦波データ生成器を提供できる。
【図面の簡単な説明】
【図1】本発明の正弦波データ生成器およびトーン検出回路を備えたボタン電話システムの要部構成を示すブロック図。
【図2】本発明の第1実施形態における正弦波データ生成器18の具体的な構成を示すブロック図。
【図3】図2に示す正弦波データ生成器18が生成する正弦波データが示す正弦波を示す図。
【図4】リセット時の最大のひずみの発生の様子を示す図。
【図5】本発明の第2実施形態におけるトーン検出回路19の具体的な構成を示すブロック図。
【図6】図5中の演算処理部53の具体的構成を示すブロック図。
【図7】図5中のピーク検出部55の具体的な構成を示すブロック図。
【図8】図5中の演算処理部53で行われる積和演算の様子を示す図。
【図9】周波数fxを着目周波数としての積和演算を行い、かつ入力信号周波数をfx、fy、fzと変化させた場合の出力値Vの変化を示す図。
【図10】図5に示すトーン検出回路19にて各着目周波数に関して検出される周波数スペクトルを並べて示した図。
【図11】図10に示す各周波数スペクトルを合成した様子を示す図。
【図12】本発明の第3実施形態におけるトーン検出回路19の具体的な構成を示すブロック図。
【図13】図12中のしきい値比較部91の具体的な構成を示すブロック図。
【図14】図12に示すトーン検出回路19にて検出する各着目周波数の周波数スペクトルの配置を示す図。
【図15】本発明の第4実施形態におけるトーン検出回路19の具体的な構成を示すブロック図。
【図16】図15に示すトーン検出回路19にて検出する各着目周波数の周波数スペクトルの配置を示す図。
【符号の説明】
1…主装置
2(2-1〜2-i)…内線端末
11…タイムスイッチ
12(12-1〜12-j)…局線インタフェース回路
13(13-1〜13-i)…内線インタフェース回路
14…CPU
15…ROM
16…RAM
17…データハイウェイインタフェース部
18…正弦波データ生成器
19…トーン検出回路
20…PCMハイウェイ
21…データハイウェイ
22…CPUローカルバス
31…加算器
32,33…ラッチ回路
34,35…乗算器
36…出力処理部
37…ラッチ回路
38…比較部
39…基準データレジスタ
40…比較部
41…タイマ
42…ANDゲート
43…初期化部
51…速度変換部
52…圧縮/リニア変換部
53…演算処理部
54…絶対値変換部
55…ピーク検出部
56…加算部
57…判定部
58…レジスタ
59…CPUインタフェース
60…カウンタ
61…リセット信号生成部
71…減算器
72…加算器
73(73-1〜73-p)…フリップフロップ
74(74-1〜74-p)…フリップフロップ
75…係数発生器
76…乗算器
81…比較器
82…セレクタ
83(83-1〜83-p)…フリップフロップ
91…しきい値比較部
92…判定部
101…比較回路
102…しきい値レジスタ
111…しきい値比較部
112…マトリクス部
113…レジスタ
114…CPUインタフェース
[0001]
BACKGROUND OF THE INVENTION
  The present invention is used in, for example, a main device of a key telephone system, and for example, digital sine wave data generation for generating sine wave data for generating a tone signal used for providing an extension terminal or the like.In a vesselRelated.
[0002]
[Prior art]
The main part of the key telephone system having an exchange function has been digitized because of the recent demand for higher functionality and smaller size.
[0003]
By the way, in this type of apparatus, a function for generating a tone signal to be transmitted to an extension line or a local line is required, and a sine wave generator for generating a sine wave signal that is a source of the tone signal is provided.
[0004]
Further, it is necessary to detect various tone signals such as a busy tone and a DTMF signal that have arrived via an extension line or a local line, and a tone detection circuit that detects these tone signals is provided.
[0005]
Since these sine wave generators and tone detection circuits have been conventionally realized by analog circuits, there is a problem that the circuit scale is large and the integration is difficult. Also, since the other parts are digitized, a codec must be provided for interfacing with those parts, resulting in a further increase in circuit scale.
[0006]
According to the theory of traffic, these sine wave generators and tone detection circuits require eight for every 100 accommodated lines. However, the fact that all the plurality of tone detection circuits are composed of analog circuits It was a great hindrance to scale reduction.
[0007]
Although it is possible to perform sine wave generation and tone detection by digital processing using a DSP (Digital Signal Processor), it takes much time to create a program, and the circuit scale is still large, resulting in cost and power consumption. There is a problem that is too big.
[0008]
[Problems to be solved by the invention]
As described above, conventionally, the generation of the sine wave signal and the detection of the tone signal have been realized by an analog circuit, and thus there are problems such as an increase in size due to an increase in circuit scale, an increase in cost, and an increase in power consumption.
[0009]
  The present invention has been made in consideration of such circumstances, and an object of the present invention is to provide a digital sine capable of realizing downsizing, cost reduction, and low power consumption by integration with a simple digital circuit. Wave data generationVesselIt is to provide.
[0010]
[Problems to be solved by the invention]
In order to achieve the above object, a first invention is a digital sine wave that generates sine wave data by outputting a digital value indicating a level of a sine wave signal having a predetermined frequency as an output digital value at a predetermined cycle. In the data generator, a first reference value obtained by multiplying an output digital value in the previous cycle by a constant determined in accordance with the frequency of the sine wave signal, for example, a multiplication means including a latch circuit and a multiplier, and two cycles A second reference value generated by inverting the previous output digital value is generated, for example, generated by an inverting means including two latch circuits and a multiplier, and the first reference value generated by the multiplying means and the inverting means. Adding means such as an adder for generating an output digital value at the present time by adding the second reference value, and the first reference value to “0”, For example, reset means such as an initialization unit for resetting the second reference value to an initial value determined according to the frequency of the sine wave signal, and time elapsed after the reset by the reset means is performed. Time measuring means such as a timer, polarity change detecting means comprising, for example, a latch circuit and a comparison unit for detecting that the polarity of the output digital value generated by the adding means has changed from positive to negative, and the output digital value Detecting that the absolute value of the low level state is equal to or less than a predetermined reference value, for example, a level confirmation unit comprising a reference data register and a comparison unit, and an elapsed time measured by the time measuring unit exceeds a predetermined time When the polarity change is detected by the polarity change detection means, the low level state is detected by the level confirmation means. It has a reset control means such as a reset performed to example AND gate to the reset means if has been detected in.
[0011]
By taking such means, the first reference value obtained by multiplying the output digital value in the previous cycle by a constant determined according to the frequency of the desired sine wave signal and the output digital value in the previous two cycles are inverted. By adding the second reference value, a digital value indicating the level of the sine wave signal is obtained. Then, when the polarity of the output digital value changes from positive to negative in a state where the elapsed time since the last reset has exceeded a predetermined time, the absolute value of the output digital value is a predetermined reference value The first reference value and the second reference value are reset to “0” and an initial value determined according to the frequency of the sine wave signal, respectively, in response to the low level state that is described below. Accordingly, the sine wave data can be generated only by processing that can be realized by such digital processing, and the periodic reset is performed when the elapsed time from the previous reset exceeds a predetermined time. When the polarity of the output digital value changes from positive to negative, it is performed only when the absolute value of the output digital value is in a low level state that is equal to or less than a predetermined reference value. Strain is reduced.
[0024]
DETAILED DESCRIPTION OF THE INVENTION
Hereinafter, several embodiments of the present invention will be described with reference to the drawings.
[0025]
FIG. 1 is a block diagram showing a main configuration of a button telephone system including a sine wave data generator and a tone detection circuit according to the present invention.
[0026]
As shown in the figure, this key telephone system is configured by arbitrarily connecting a plurality (maximum i) of extension terminals 2 (2-1 to 2-i) to a main apparatus 1.
[0027]
The main device 1 further includes a time switch 11, a plurality (j) of local line interface circuits 12 (12-1 to 12-j), and a plurality (i) of extension interface circuits 13 (13-1 to 13-i). , CPU 14, ROM 15, RAM 16, data highway interface unit 17, sine wave data generator 18 and tone detection circuit 19, time switch 11, office line interface circuit 12, extension interface circuit 13, sine wave data generator 18. The tone detection circuit 19 is connected to each other via the PCM highway 20.
[0028]
The time switch 11, the office line interface circuit 12, the extension interface circuit 13, and the data highway interface unit 17 are connected to each other via the data highway 21. Further, the CPU 14, the ROM 15, the RAM 16 and the data highway interface unit 17 are connected to each other via a CPU local bus 22.
[0029]
The time switch 11 exchanges and connects the local line interface circuit 12 and the extension interface circuit 13 arbitrarily by exchanging the time slots on the PCM highway 20 based on the control of the CPU 14.
[0030]
A station line L (L-1 to L-j) such as a public line or a dedicated line is connected to the station line interface circuit 12 as necessary. The office line interface circuit 12 performs an office line interface operation for the connected office line L. The office line interface operation refers to conversion of an audio signal (analog) arriving via the office line L into a PCM signal, conversion of a PCM signal given via the time switch 11 into an audio signal (analog), and the office line L State monitoring, and transmission of various signals to the network connected via the office line L. The office line interface circuit 12 exchanges various control information related to the above-mentioned office line interface operation with the CPU 14 via the data highway 21, the data highway interface unit 17, and the CPU local bus 22.
[0031]
The extension terminal 2 is connected to the extension interface circuit 13 as necessary. The extension interface circuit 13 performs an extension interface operation related to the connected extension terminal. The extension interface operation includes the transmission of the PCM signal output from the extension terminal 2 to the PCM highway 20, the extraction of the PCM signal given via the time switch 11 from the PCM highway 20, the status monitoring of the extension terminal 2, and the extension terminal. 2 to send various signals. The extension interface circuit 13 exchanges various control information related to the extension interface operation with the CPU 14 via the data highway 21, the data highway interface unit 17, and the CPU local bus 22.
[0032]
The CPU 14 performs overall control of each of the time switch 11, the office line interface circuit 12, and the extension interface circuit 13 by performing processing based on the operation program stored in the ROM 15, and operates as a main device in the button telephone device. Is realized.
[0033]
The ROM 15 stores an operation program for the CPU 14 and other various data used permanently.
[0034]
The RAM 16 stores various information necessary for the CPU 14 to perform various processes.
[0035]
The data highway interface unit 17 exchanges data between the data highway 21 and the CPU local bus 22.
[0036]
(First embodiment)
This embodiment relates to the sine wave data generator 18 in FIG.
[0037]
FIG. 2 is a block diagram showing a specific configuration of the sine wave data generator 18 in the present embodiment.
[0038]
As shown in this figure, the sine wave data generator 18 in this embodiment includes an adder 31, latch circuits 32 and 33, multipliers 34 and 35, an output processing unit 36, a latch circuit 37, a comparison unit 38, and a reference data register. 39, a comparison unit 40, a timer 41, an AND gate 42, and an initialization unit 43.
[0039]
The adder 31 adds the output value of the multiplier 34 and the output value of the multiplier 35, and outputs the added value as the current value of the sine wave data. The output value of the adder 31 is composed of a data portion indicating the signal level and a code indicating the polarity.
[0040]
The output value of the adder 31 is input to the latch circuit 32. The latch circuit 32 captures and holds the output value of the adder 31 at a timing in accordance with a clock signal having the same frequency fs (for example, 8 KHz) in synchronization with the frame period on the PCM highway 20. The latch circuit 32 always outputs the held value.
[0041]
The output value of the latch circuit 32 is input to the latch circuit 33. The latch circuit 33 captures and holds the output value of the latch circuit 32 at a timing corresponding to the clock signal having the frequency fs. The latch circuit 33 always outputs the held value.
[0042]
Thus, the latch circuit 32 and the latch circuit 33 delay the output from the adder 31 by one frame period and output the output values one frame before and two frames before, respectively.
[0043]
The multiplier 34 multiplies the output value of the latch circuit 32 by a constant 2cos (w) determined according to the desired sine wave frequency and the frequency fs of the signal applied to the latch circuits 32 and 33, and obtains a value obtained as a result. This is given to the adder 31.
[0044]
The multiplier 35 inverts the data by multiplying the output value of the latch circuit 33 by “−1”, and gives the resulting value to the adder 31.
[0045]
The output value of the adder 31 is output by the output processing unit 36 to a time slot assigned on the PCM highway 20 as a current value in sine wave data indicating a sine wave signal having a predetermined frequency.
[0046]
The sign of the output value of the adder 31 is input to the latch circuit 37. The latch circuit 37 captures and holds the sign of the output value of the adder 31 at a timing according to the clock signal having the frequency fs. The latch circuit 37 outputs the retained code. That is, the latch circuit 37 delays the sign of the output from the adder 31 by one frame period, and outputs the sign of the output value from the adder 31 one frame before.
[0047]
The comparison unit 38 receives the sign output from the latch circuit 37 and the sign of the output value of the adder 31. The comparison unit 38 outputs the “H” level only when the sign output from the latch circuit 37 is “positive” and the sign of the output value of the adder 31 is “positive”.
[0048]
The reference data register 39 stores reference value data indicating a predetermined reference value ABS, and always outputs this reference value data.
[0049]
Reference value data output from the reference data register 39 and data out of the output values of the adder 31 are input to the comparison unit 40. The comparison unit 40 compares the values indicated by these two data, and outputs the “H” level only when the value indicated by the data among the output values of the adder 31 is equal to or less than the reference value.
[0050]
The timer 41 is cleared in response to the output of the AND gate 42 becoming “H” level. Then, the timer 41 counts the elapsed time from the time when it is cleared and, after completing a predetermined reset period, sets the output to “H” only until it is cleared next.
[0051]
The AND gate 42 is supplied with outputs of the comparator 38, the comparator 40, and the timer 41. The AND gate 42 outputs the “H” level only when the outputs of the comparison unit 38, the comparison unit 40, and the timer 41 are all “H”.
[0052]
An output from the AND gate 42 is given to the initialization unit 43. Then, in response to the output of the AND gate 42 becoming “H”, the initialization unit 43 initializes the holding values of the latch circuit 32 and the latch circuit 33 to a predetermined initial value.
[0053]
Next, the operation of the sine wave data generator 18 configured as described above will be described.
[0054]
First, the holding value of the latch circuit 32 is set to “0”, and the holding value of the latch circuit 33 is set to a constant Asin (w) determined according to a desired sine wave frequency and amplitude. Then, the output of the adder 31 is −Asin (w).
[0055]
Thereafter, the value held in the latch circuits 32 and 33 is updated at the timing of the clock signal, so that the output value of the adder 31 is also changed.
[0056]
At this time, the output value Y of the adder 31(h)Represents the output value of the adder 31 one cycle before and two cycles before the clock signal, respectively.(h-1), Y(h-2)If
Y(h)= Y(h-1)× 2cos (w) -Y(h-2)
Thus, a level value when a sine wave signal having a desired sine wave frequency is sampled at a sampling frequency of fs appears as an output value Y.
[0057]
That is, the output of the adder 31 is shown in FIG. 3 having a frequency determined by the constant 2cos (w) and the constant Asin (w) with −Asin (w) as an initial value and an amplitude determined by the constant Asin (w). The sine wave data is obtained by sampling such a sine wave signal at a sampling frequency of fs. The sine wave data is sent to the PCM highway 20 by the output processing unit 36 at an appropriate timing. This sine wave data is used, for example, to generate an arbitrary tone signal by intermittent control of output by the time switch 11.
[0058]
The output value Y is a digital value, but the number of bits is finite. For this reason, the output of the multiplier 34 is a rounded result, and an error from the normal value occurs. Such errors are accumulated by repeated calculations.
[0059]
Therefore, the holding values of the latch circuits 32 and 33 are reset by a reset circuit including the latch circuit 37, the comparison unit 38, the reference data register 39, the comparison unit 40, the timer 41, the AND gate 42, and the initialization unit 43. I am going to do that.
[0060]
That is, first, the timer 41 counts a reset period appropriately set in consideration of the time during which the error of the output value Y is within an allowable range. H ”. Therefore, the output of the AND gate 42 does not become “H” until the timer 41 finishes counting the reset period.
[0061]
On the other hand, in the comparison unit 38, the current output value Y(h)And the output value Y one frame before held in the latch circuit 37(h-1)The sign of the output value Y is monitored to see if it changes from positive to negative. And the output value Y(h-1)Is positive and the output value Y(h)Since the sign of the output value Y has changed from positive to negative, the comparison unit 38 sets the output to “H”.
[0062]
Further, the comparison unit 40 compares the data excluding the sign of the output value Y, that is, the absolute value of the output value Y, with the reference value ABS indicated by the reference value data held in the reference data register 39. When the absolute value of the output value Y is equal to or less than the reference value ABS, the comparison unit 40 sets the output to “H”. The reference value ABS is set to an appropriate value smaller than -Asin (w) that is the initial value of the output value Y after reset.
[0063]
Thus, after the timer 41 finishes counting the reset period, all of the AND gates 42 only when the absolute value of the output value Y immediately after the sign of the output value Y changes from positive to negative is equal to or less than the reference value ABS. Becomes “H”, and the output of the AND gate 42 becomes “H”.
[0064]
Then, in response to the output of the AND gate 42 becoming “H”, the initialization unit 43 sets the holding value of the latch circuit 32 to “0” and the holding value of the latch circuit 33 to the constant Asin (w). initialize.
[0065]
Further, in response to the output of the AND gate 42 becoming “H”, the timer 41 is also reset, and timing of a new reset period is started.
[0066]
In this way, the output value Y is periodically reset to -Asin (w), and the error is suppressed within a certain range.
[0067]
In this embodiment, since the output value Y is reset immediately after the change from positive to negative, the output value Y changes from a positive level to -Asin (w), which is a steep change that cannot normally occur. Is prevented. As a result, the distortion of the waveform can be reduced and the noise generated in the tone generated using the sine wave data can be reduced.
[0068]
By the way, the output value Y immediately after the sign of the output value Y changes from positive to negative always falls within the range of 0 to −Asin (w). The closer this value is to −Asin (w), the more the output after resetting. The value Y becomes almost the same level, and for example, the waveform is distorted as shown in FIG.
[0069]
However, in this embodiment, reset execution is limited to the case where the absolute value of the output value Y is equal to or less than the reference value ABS set smaller than Asin (w). And the noise generated in the tone generated using this sine wave data can be reduced.
[0070]
Although it is possible to reduce the distortion of the waveform as the reference value ABS is decreased, the probability that the reset execution condition is satisfied may be reduced and the reset cycle may be too long. It is desirable to set the reference value ABS appropriately in consideration.
[0071]
(Second Embodiment)
This embodiment relates to the tone detection circuit 19 in FIG.
[0072]
FIG. 5 is a block diagram showing a specific configuration of the tone detection circuit 19 in the present embodiment.
[0073]
As shown in this figure, the tone detection circuit 19 in this embodiment includes a speed conversion unit 51, a compression / linear conversion unit 52, an arithmetic processing unit 53, an absolute value conversion unit 54, a peak detection unit 55, an addition unit 56, and a determination unit. 57, a register 58, a CPU interface 59, a counter 60, and a reset signal generator 61.
[0074]
The speed converter 51 is connected to the PCM highway 20. The speed conversion unit 51 extracts a predetermined one of a number of channels multiplexed on the PCM highway 20 with a 1 / fs frame period (for example, 125 μs), reduces the speed, To do. That is, the speed converter 51 reproduces a PCM signal whose value changes with a period of 1 / fs.
[0075]
The compression / linear conversion unit 52 is provided with the PCM signal output from the speed conversion unit 51. This PCM signal is compressed by a predetermined compression method. Therefore, the compression / linear conversion unit 52 expands the PCM signal output from the speed conversion unit 51 and returns it to a linear PCM signal.
[0076]
The arithmetic processing unit 53 performs a product-sum operation, which will be described in detail later, on each of a plurality of frequencies of interest using the PCM signal provided from the compression / linear conversion unit, and sends the result of the product-sum operation to the absolute value conversion unit 54. And give.
[0077]
The absolute value conversion unit 54 calculates the absolute value of the output value of the arithmetic processing unit 53.
[0078]
The peak detector 55 detects the peak value of the output value from the absolute value converter 54 for each frequency of interest.
[0079]
The adder 56 calculates the sum of peak values for each frequency of interest detected by the peak detector 55.
[0080]
The determination unit 57 determines the presence / absence of a tone signal to be detected based on the output value from the addition unit 56 when the counter 60 finishes counting the predetermined number of repetitions N. The determination unit 57 outputs determination data indicating the determination result.
[0081]
The register 58 stores and holds determination data output from the determination unit 57.
[0082]
The CPU interface 59 sends the determination data stored and held in the register 58 to the CPU local bus 22 at a predetermined timing.
[0083]
The counter 60 is given a clock signal having a frequency fs. The counter 60 cyclically counts the clock signal having the frequency fs repeatedly up to the number of times N. When the counter 60 finishes counting the predetermined number of repetitions N, it gives a count-up signal to each of the determination unit 57 and the reset signal generation unit 61.
[0084]
The reset signal generation unit 61 outputs a reset signal for resetting the operation states of the arithmetic processing unit 53 and the peak detection unit 55 to a predetermined initial state in response to the count up signal from the counter 60.
[0085]
FIG. 6 is a block diagram showing a specific configuration of the arithmetic processing unit 53 in FIG.
[0086]
As shown in this figure, the arithmetic processing unit 53 includes a subtracter 71, an adder 72, p flip-flops (FF) 73 (73-1, 73-2... 73-j) connected in series, and serial connection. P flip-flops (FF) 74 (74-1, 74-2... 74-j), a coefficient generator 75, and a multiplier 76.
[0087]
An output value of the compression / linear conversion unit 52 is input to the subtracter 71. Further, the output value of the flip-flop 74-j at the final stage is input to the subtracter 71. The subtractor 71 subtracts the output value of the flip-flop 74-j from the output value of the compression / linear conversion unit 52, and outputs the subtraction value.
[0088]
The output value of the subtracter 71 is input to the adder 72. Further, the output value of the multiplier 76 is input to the adder 72. The adder 72 adds these two values and outputs the added value. The output value of the adder 72 is output to the absolute value conversion unit 54 as a result of product-sum operation.
[0089]
The output value of the adder 72 is input to the uppermost flip-flop 73-1 of the flip-flops 73. Each flip-flop 73 is supplied with a clock signal having a frequency p times the frame frequency fs. Thus, the flip-flop 73 sequentially transfers the output value of the adder 72 at a period of 1 / p of the frame period. The held value of each flip-flop 73 is reset by a reset signal output from the reset signal generation unit 61.
[0090]
The output value of the last flip-flop 73-j of the flip-flops 73 is input to the uppermost flip-flop 74-1 of the flip-flops 74-1. Each flip-flop 74 is supplied with a clock signal having a frequency p times the frame frequency fs. Thus, the flip-flop 74 sequentially transfers the output value of the flip-flop 73-j at a period of 1 / p of the frame period. The held value of each flip-flop 74 is reset by a reset signal output from the reset signal generation unit 61.
[0091]
The coefficient generator 75 sequentially outputs a coefficient corresponding to each of the p target frequencies while changing the coefficient in synchronization with a clock signal having a frequency p times the frame frequency fs. That is, the coefficient generator 75 outputs a coefficient corresponding to a different frequency of interest in each period obtained by equally dividing one frame period by p.
[0092]
The multiplier 76 multiplies the output value of the flip-flop 73-j by the coefficient output from the coefficient generator 75.
[0093]
FIG. 7 is a block diagram showing a specific configuration of the peak detector 55 in FIG.
[0094]
As shown in this figure, the peak detector 55 includes a comparator 81, a selector 82, and p flip-flops (FF) 83 (83-1, 83-2,..., 83-j) connected in series. Become.
[0095]
The comparator 81 is given the output value of the absolute value converter 54 and the output value of the flip-flop 83-j at the final stage of the flip-flop 83. The comparator 81 compares these two values, and gives an “H” level to the selector 82 when the output value of the absolute value converter 54 is larger than the output value of the flip-flop 83-j.
[0096]
The selector 82 is given the output value of the absolute value converter 54 and the output value of the flip-flop 83-j. The selector 82 outputs the output value of the absolute value converter 54 when the "H" level is given from the comparator 81, and the flip-flop 83-j when the "L" level is given from the comparator 81. Select and output each output value.
[0097]
The output value of the selector 82 is input to the uppermost flip-flop 83-1 of the flip-flops 83. Each flip-flop 83 is supplied with a clock signal having a frequency p times the frame frequency fs. Thus, the flip-flop 83 sequentially transfers the output value of the selector 82 at a period of 1 / p of the frame period. Each output of each flip-flop 83 is individually supplied to the adder 56 as a peak value related to each frequency of interest. Note that the held value of each flip-flop 83 is reset by the reset signal output from the reset signal generation unit 61.
[0098]
Next, the operation of the tone detection circuit 19 configured as described above will be described.
[0099]
Here, the operation will be described as detecting a BT (Busy Tone) signal having any frequency within the frequency band of 305 Hz to 640 Hz.
[0100]
When such a BT signal is detected, the frequency of interest is set to four frequencies f1, f2, f3, and f4 within a band of 305 Hz to 640 Hz.
[0101]
Therefore, the number of flip-flops 73, 74, 81, 83 is four each. The frequency of the clock signal applied to these flip-flops 73, 74, 81, 83 is four times fs. If fs is 8 KHz, the frequency is 32 KHz.
[0102]
A speed conversion unit 51 extracts a channel as a detection target of the BT signal from a large number of channels multiplexed on transmission data of the PCM highway 20. Since the serial data of each channel is time-division multiplexed on the PCM highway 20, the data extracted by the speed conversion unit 51 exists in bursts. Therefore, the extracted data is subjected to parallel conversion and speed reduction by the speed conversion unit 51, and converted into continuous data in which data corresponding to one sampling value (but compressed here) exists for each frame period. Is done.
[0103]
The data converted into continuous data in this way is then decompressed by the compression / linear conversion unit 52 and returned to data directly indicating the signal level, and then provided to the arithmetic processing unit 53.
[0104]
Thus, in the arithmetic processing unit 53, one sampling value is given to the subtracter 71 over one frame period.
[0105]
On the other hand, a value to be output from the arithmetic processing unit 53 to the absolute value conversion unit 54, that is, an output value of the adder 72 that is a product-sum operation result in the arithmetic processing unit 53 (hereinafter referred to as a product-sum operation value) is The flip-flops 73-1 to 73-k and the flip-flops 74-1 to 74-k are sequentially transferred every quarter of the frame period.
[0106]
Thus, the output values of the flip-flop 73-k at the final stage (here, the fourth stage) of the flip-flop 73 and the flip-flop 74-k at the final stage (here, the fourth stage) of the flip-flop 74 are one frame. It becomes the output value of the adder 72 before the cycle and two frames before.
[0107]
Thus, the subtracter 71 subtracts the product-sum operation value two frames before from the sampling value given from the compression / linear conversion unit 52. However, while the sampling value given from the compression / linear converter 52 is the same value during one frame period, the output value of the flip-flop 74-k is obtained by dividing one frame period into four as will be described later. It becomes a different value in the period. Therefore, the output value of the subtracter 71 also becomes a different value in each period obtained by dividing one frame period into four equal parts.
[0108]
On the other hand, the multiplier 76 multiplies the product-sum operation value before one frame period by the coefficient output from the coefficient generator 75. Here, the coefficient generator 75 sequentially outputs coefficients corresponding to the four frequencies of interest in synchronization with a clock signal having a frequency four times the frame frequency. That is, one frame period is divided into four equal parts, and coefficients corresponding to each of the frequencies of interest f1, f2, f3, and f4 are sequentially output. Since the flip-flop 73 has a four-stage configuration and uses the same clock signal as that supplied to the coefficient generator 75 as a transfer clock, the output value of the flip-flop 73-k divides one frame period into four equal parts. It becomes a different value in each period.
[0109]
Thus, the multiplier 76 performs different multiplication in each period obtained by dividing one frame period into four, and the output value also differs in each period obtained by dividing one frame period into four equal parts.
[0110]
Since different values are given to the adder 72 from each of the subtractor 71 and the multiplier 76 in respective periods obtained by dividing one frame period into four equal parts, the adder 72 adds two values at each timing.
[0111]
In this way, as shown in FIG. 8, four product-sum operation processes are performed in a time division manner within one frame period. In each period obtained by dividing one frame period into four equal parts, the first period is a coefficient K corresponding to the first frequency of interest f1.(f1)Is used for the second period, the coefficient K corresponding to the second frequency of interest f2(f2)Is used for the third period, the coefficient K corresponding to the third frequency of interest f3(f3)And the period is a coefficient K corresponding to the fourth frequency of interest f4.(f4)The product-sum operation process is performed using the values related to. That is, the product-sum calculation process for each frequency of interest is performed in a time division manner. In FIG. 8, the notations “_f1”, “_f2”, “_f3”, and “_f4” attached to the end of each value indicate whether the value relates to the frequency of interest f1, f2, f3, or f4. Show.
[0112]
And the output value V by the product-sum operation for each frequency of interest(h)Represents the sampling value given from the compression / linear conversion unit 52 as X(h), The output value of flip-flop 73-k is V(h-1), The output value of flip-flop 74-k is V(h-2)And the coefficient generated by the coefficient generator 75 is denoted as K, respectively.
V(h)= X(h)-V(h-2)+ V(h-1)× K(f)
It becomes.
[0113]
K(f)Is determined according to the frequency of interest,
K(f)= 2cos (2 × π × k(f)/ N(f))
It becomes.
[0114]
Here, k is a constant determined according to the frequency of interest. N(f)Is the number of repetitions of product-sum operation (number of sample points) determined according to the frequency of interest. These constant k and number of repetitions N(f)Indicates the frequency of interest as ftone and the repetition frequency of the product-sum operation as fs.
ftone / fs ≒ k(f)/ N(f)
Are set so that each satisfies an integer.
[0115]
The output value V thus obtained is repeatedly increased and decreased as the product-sum operation is repeated. However, the peak value of the output value V increases only when the component of the frequency of interest exists in the input signal. Go.
[0116]
FIG. 9 is a diagram illustrating a change in the output value V when the product-sum operation is performed with the frequency fx as the frequency of interest and the input signal frequency is changed to fx, fy, and fz.
[0117]
As is clear from this figure, when the same frequency fx as the frequency of interest is input, the peak value of the output value V increases, but when other frequencies fy and fz are input, the peak value of the output value V is obtained. Does not increase.
[0118]
Therefore, it is possible to determine whether or not the frequency of interest exists in the input signal based on the peak value of the output value V after repeating the product-sum operation over a certain period.
[0119]
However, the peak value of the output value V can occur both positively and negatively as can be seen from FIG. Therefore, the output value V is converted into an absolute value by the absolute value conversion unit 54, and the peak value is detected by the peak detection unit 55.
[0120]
The peak detector 55 detects this peak value as follows.
[0121]
That is, the output value of the absolute value converter 54 is given to the comparator 81 and compared with the output value of the flip-flop 83-k.
[0122]
Here, in the flip-flops 83-1 to 83-k, the output value of the selector 82 is sequentially transferred every 1/4 period of the frame period, so that the output value of the flip-flop 83-k at the final stage is one frame. This is the output value of the selector 82 before the cycle.
[0123]
Thus, the output value of the absolute value converter 54 is compared with the value selected by the selector 82 in the previous frame period by the comparator 81. As a result of the comparison by the comparator 81, the selector 82 selects the larger value of the output value of the absolute value converter 54 and the output value of the flip-flop 83-k. Here, the value selected by the selector 82 is input to the flip-flop 83-1, and sequentially transferred through the flip-flops 83-1 to 83-k.
[0124]
In this way, the flip-flops 83-1 to 83-k hold the peak value of the output value of the absolute value converter 54 for each frequency of interest. Therefore, the output values of the flip-flops 83-1 to 83-k are individually given to the adding unit 56 as the peak value of the product-sum operation result for each frequency of interest.
[0125]
The p peak values given from the peak detection unit 55 in this way are added to each other by the addition unit 56, and the total value of the peak values obtained thereby is given to the determination unit 57.
[0126]
Now, while the product-sum operation is repeatedly performed by the arithmetic processing unit 53 as described above, the counter 60 counts the number of times the product-sum operation is executed, so that the frequency is the frame frequency fs. The signal is counted. When the counter 60 finishes counting the predetermined number of repetitions N, a count-up signal is given from the counter 60 to the determination unit 57 and the reset signal generation unit 61.
[0127]
When the count-up signal is given from the counter 60 in this way, the determination unit 57 makes a detection target by confirming whether or not the output value of the addition unit 56 at that time exceeds a predetermined threshold value. It is determined whether or not the BT signal is included in the input signal.
[0128]
That is, if the BT signal has arrived, all of the frequencies of interest are included, so the peak value of the product-sum calculation value for each of the frequencies of interest is a large value. That is, this is equivalent to the detection of the frequency spectrum as shown in FIG.
[0129]
Now, the result of the product-sum operation for each frequency of interest is a frequency spectrum having a certain bandwidth as shown in FIG. The bandwidth is determined by the number of product-sum operations repeated.
[0130]
Therefore, the number of repetitions of the product-sum operation for each frequency of interest is set so that the frequency spectra obtained for the adjacent frequencies of interest overlap appropriately as shown in FIG.
[0131]
By doing so, the sum of the product sum calculation values for each frequency of interest is added by the adder 56, whereby the sum of the spectrum of each frequency of interest as shown in FIG. 10 is obtained. The signal of each frequency is detected with the sensitivity distribution as shown.
[0132]
That is, not only when a signal having the same frequency as the target frequency has arrived, but also when a signal having an intermediate frequency between the target frequencies has arrived, the output value of the adder 56 becomes a sufficiently large value. Thus, the same result as that obtained by passing the band-pass filter having the frequency characteristics as shown in FIG. 11 can be obtained.
[0133]
Therefore, if the output value of the adder 56 is equal to or greater than a certain value, it can be determined that a signal in the band as shown in FIG. 11, that is, a BT signal has arrived.
[0134]
Then, the determination data indicating the determination result in the determination unit 57 is stored and held in the register 58, and then sent to the CPU local bus 22 at a predetermined timing by the CPU interface 59 and notified to the CPU 14.
[0135]
In parallel with the determination processing by the determination unit 57, a reset signal is supplied from the reset signal generation unit 61 to the arithmetic processing unit 53 and the peak detection unit 55 in response to the count-up signal being supplied from the counter 60. As a result, the flip-flops 73-1 to 73-k and 74-1 to 74-k of the arithmetic processing unit 53 and the flip-flops 83-1 to 83-k of the peak detecting unit 55 are reset, and a new product-sum operation process is performed. And the peak value detection of the product-sum operation value is started.
[0136]
By the way, the number of times the product-sum operation is repeated is different for each frequency of interest, and theoretically, the determination unit 57 uses the value obtained by the product-sum operation of the number of repetitions corresponding to each frequency of interest. become.
[0137]
However, the number of repetitions N corresponding to each frequency of interest(f)Is set to a value closest to the reference number, and the number of repetitions N counted by the counter 60 is set to the reference number. As a result, the determination unit 57 can make a determination based on the peak value of the product-sum operation value for each frequency of interest at the time when the counter 60 has counted the number of repetitions N as described above.
[0138]
This is because, as can be seen from FIG. 9, even if the number of iterations changes slightly, the peak value of the product-sum operation result does not change greatly.(f)This is because even the peak value at the time of the number of repetitions N with a small difference from the above has little influence on the determination accuracy of the presence or absence of the BT signal.
[0139]
The number of repetitions N is appropriately set so that N product-sum operations can be completed at least once during the duration of the detection target tone (here, the BT signal).
[0140]
As described above, according to the present embodiment, the value obtained by subtracting the product-sum operation value two frames before from the level of the input signal in each frame and the product-sum operation value one frame before are used as the frequency of interest. The sum-of-products operation process performed by adding the values obtained by multiplying the corresponding coefficients is performed over a predetermined number of iterations, and the peak value is detected, and the frequency of interest is determined using the Goertzel algorithm. A plurality of frequency spectra as the center frequency are calculated. The bandwidth of the frequency spectrum is determined by the number of repetitions of the product-sum operation and the coefficient used for the product-sum operation. Therefore, one frequency band can be synthesized by combining each frequency spectrum after setting adjacent frequency spectra. A pass filter is configured to detect the BT signal.
[0141]
Therefore, the BT signal can be detected only by processing that can be easily performed by digital processing by a basic digital circuit, and downsizing can be achieved by integration.
[0142]
Further, in this embodiment, since each frequency spectrum is synthesized by adding the peak values of the respective frequencies of interest, it is possible to obtain sufficient sensitivity with respect to intermediate frequencies between the frequencies of interest. The interval of the frequency of interest can be increased compared to the case of the third embodiment described later. As a result, the number of frequencies of interest required to cover a certain frequency band can be reduced, and the number of product-sum calculation processes can be reduced, thereby simplifying the configuration and reducing the processing speed. Thus, it can be easily realized.
[0143]
Further, according to the present embodiment, one frame period is equally divided into p, and the product-sum operation processing for each of the p number of frequencies of interest is processed in a time-sharing manner. The adder 72 and multiplier 76 can be shared by each frequency of interest, and the circuit scale can be further reduced as compared with the case where they are provided individually.
[0144]
Further, according to the present embodiment, the number of repetitions N of product-sum operations for each frequency of interest is N.(f)Is set to a value closest to a certain reference number, and the product-sum operation value used for determining the presence or absence of the BT signal is set to a value obtained by the product-sum operation of the reference number. It is sufficient to simply add the latest values of the peak values regarding the number of individual repetitions N(f)Therefore, the configuration can be further simplified.
[0145]
(Third embodiment)
This embodiment relates to the tone detection circuit 19 in FIG.
[0146]
FIG. 12 is a block diagram showing a specific configuration of the tone detection circuit 19 in the present embodiment. 1 and 5 are denoted by the same reference numerals, and detailed description thereof is omitted.
[0147]
As shown in this figure, the tone detection circuit 19 in this embodiment includes a speed conversion unit 51, a compression / linear conversion unit 52, an arithmetic processing unit 53, an absolute value conversion unit 54, a peak detection unit 55, a register 58, and a CPU interface 59. , A counter 60, a reset signal generation unit 61, a threshold value comparison unit 91, and a determination unit 92.
[0148]
That is, in the present embodiment, the tone detection circuit 19 includes a threshold value comparison unit 91 and a determination unit 92 in place of the addition unit 56 and the determination unit 57 in the second embodiment.
[0149]
The threshold comparison unit 91 compares the peak value of each frequency of interest detected by the peak detection unit 55 with a predetermined threshold value, and notifies the determination unit 92 of the comparison result.
[0150]
The determination unit 92 determines the presence / absence of a tone signal to be detected based on the notification content from the threshold value comparison unit 91 when the counter 60 finishes counting the predetermined number of repetitions N. The determination unit 92 outputs determination data indicating the determination result.
[0151]
FIG. 13 is a block diagram showing a specific configuration of the threshold comparison unit 91.
[0152]
As shown in this figure, the threshold value comparison unit 91 is composed of p number of comparison circuits 101 (101-1, 101-2... 101-k) and a threshold value register 102.
[0153]
Each comparison circuit 101 receives a peak value of each frequency of interest detected by the peak detector 55. Each comparison circuit 101 is commonly given a threshold value stored and held in the threshold value register 102. Each comparison circuit 101 compares the peak value with a threshold value and notifies the determination unit 92 whether or not the peak value is larger than the threshold value.
[0154]
The threshold register 102 stores and holds a predetermined threshold value set in advance, and always outputs this threshold value.
[0155]
Thus, the tone detection circuit 19 of this embodiment does not add the peak values for each frequency of interest, but compares them individually with the threshold value. The determination unit 92 determines that the BT signal has arrived if the threshold value comparison unit 91 determines that any one of the peak values related to each frequency of interest exceeds the threshold value.
[0156]
In the case of the second embodiment described above, since the spectrum of each frequency of interest is synthesized, it is likely to be affected by harmonics and the detection accuracy may be lowered.
[0157]
However, according to the present embodiment, since the spectrum of each frequency of interest is individually compared with the threshold without being synthesized, it is possible to accurately detect the BT signal without being affected by the harmonics. .
[0158]
However, in the case of the present embodiment, since the sensitivity is low for the intermediate frequency between the frequencies of interest, in order to suppress such a decrease in sensitivity for the intermediate frequency, for example, as shown in FIG. It is necessary to increase the density of the frequency of interest compared to the case of the second embodiment described above. Accordingly, the number of frequencies of interest necessary to cover a certain frequency band increases, and the number of multiplexed product-sum calculation processes increases, which requires an increase in processing speed.
[0159]
(Fourth embodiment)
This embodiment relates to the tone detection circuit 19 in FIG.
[0160]
FIG. 15 is a block diagram showing a specific configuration of the tone detection circuit 19 in the present embodiment. The same parts as those in FIGS. 1, 5, and 12 are denoted by the same reference numerals, and detailed description thereof is omitted.
[0161]
As shown in this figure, the tone detection circuit 19 in this embodiment includes a speed conversion unit 51, a compression / linear conversion unit 52, an arithmetic processing unit 53, an absolute value conversion unit 54, a peak detection unit 55, a register 58, a counter 60, A reset signal generation unit 61, a threshold comparison unit 91, a determination unit 92, a threshold comparison unit 111, a matrix unit 112, a register 113, and a CPU interface 114 are provided.
[0162]
That is, in the present embodiment, the tone detection circuit 19 includes a threshold value comparison unit 111, a matrix unit 112, and a register 113 in addition to the configuration of the tone detection circuit 19 in the third embodiment, and the CPU in the third embodiment. Instead of the interface 59, a CPU interface 114 is provided.
[0163]
In the present embodiment, in addition to a plurality of frequencies of interest set in the frequency band of 305 Hz to 640 Hz for BT signal detection, frequencies that can be elements of a DTMF (Dual Tone Multi Frequency) signal (for example, 697 Hz, 770 Hz, 852 Hz). , 941 Hz, 1209 Hz, 1336 Hz, 1477 Hz, and 1633 Hz). Accordingly, if the target frequency for detecting the BT signal is 8 frequencies as shown in the third embodiment, the number p of the target frequencies is “16”.
[0164]
Accordingly, the peak detector 55 has 16 outputs. Of the 16 outputs, 8 related to the target frequency for detecting the BT signal are stored in the threshold value comparison unit 91, and the remaining 8 outputs, that is, 8 related to the target frequency for detecting the DTMF signal are compared with the threshold value. Each is input to the unit 111.
[0165]
The threshold comparison unit 111 has the same configuration as the threshold comparison unit 91. Then, the threshold value comparing unit 111 compares each output value from the peak detecting unit 55 related to the target frequency for detecting the DTMF signal with a predetermined threshold value, and each output value from the peak detecting unit 55 is greater than the threshold value. The matrix unit 112 is notified of whether it is larger.
[0166]
The matrix unit 112 determines whether or not a DTMF signal has arrived and the type of the DTMF signal that has arrived, based on the notification content from the threshold value comparison unit 91 when the counter 60 has finished counting the number of times of repetition N. Identify. The matrix unit 112 outputs determination data indicating the determination result.
[0167]
The register 113 stores and holds determination data output from the matrix unit 112.
[0168]
The CPU interface 114 sends the determination data stored and held in the register 58 and the register 113 to the CPU local bus 22 at a predetermined timing.
[0169]
Thus, in the tone detection circuit 19, the BT signal is detected in exactly the same manner as in the third embodiment. In parallel with the detection of the BT signal, a frequency spectrum for each element frequency of the DTMF signal is obtained as shown in FIG. The DTMF signal is composed of a combination of two element frequencies, and there is no need to detect an intermediate frequency. Therefore, if the bandwidth of the frequency spectrum to be obtained is sufficient to cover the frequency tolerance. Good.
[0170]
Then, each of the output values related to the target frequency for detecting the DTMF signal from the peak detecting unit 55 is compared with the threshold value by the threshold value comparing unit 111, and as a result, any two output values are equal to or more than the threshold value. If this is the case, it is known that the DTMF signal has arrived, and the DTMF that has arrived is determined by determining which element frequency corresponds to the two output values that are equal to or greater than the threshold value. Since the signal type can be determined, such a determination is performed by the matrix unit 112.
[0171]
As described above, according to the present embodiment, it is possible to detect both the BT signal and the DTMF signal by the tone detection circuit 19 with only a slight configuration.
[0172]
The present invention is not limited to the above embodiments. For example, in each of the above embodiments, the digital sine wave data generator and the tone detection circuit of the present invention are illustrated and described as being used in a button telephone system. It can also be realized as applied.
[0173]
In the first embodiment, only sine wave data of one frequency is generated, but sine wave data of a plurality of frequencies may be generated in a time division manner. That is, the latch circuit 32 and the latch circuit 33 have a multi-stage configuration similar to the flip-flop 73 and the flip-flop 74 shown in FIG. What is necessary is just to make it generate | occur | produce in a time division using a thing. The initialization unit 43 sets different values for the constant Asin (w) set in each of the plurality of stages of latch circuits 33 in accordance with each sine wave frequency and amplitude.
[0174]
In the second to fourth embodiments, the number of repetitions N of product-sum operations is N.(f)The tone signal is detected by using the peak value of the product-sum operation value by the same number of product-sum operations even though the frequency varies depending on the frequency of interest.(f)The peak value of the product-sum operation value by the product-sum operation is obtained and stored in sequence, and after waiting for the product-sum operation values for all the frequencies of interest to be obtained, the tone signal is detected using them. You may make it do. If this is done, the number of repetitions of product-sum operations N(f)The degree of freedom of setting is increased, and it is possible to take measures such as setting it so as to further improve the detection accuracy.
[0175]
In the second to fourth embodiments, the arithmetic processing unit 53, the absolute value conversion unit 54, and the peak detection unit 55 perform processing on each target frequency in a time-sharing manner, but each processing system is provided with a separate processing system. It is also possible to perform processing in parallel. In this case, the configuration is slightly complicated as compared with the second to fourth embodiments, but the processing speed is low.
[0176]
In the second to fourth embodiments, only the tone detection for one channel is illustrated, but tone detection for a plurality of channels may be performed in a time-sharing manner. In this case, the variable p may be the product of the number of frequencies of interest and the number of channels to be time-division processed. In this case, the addition unit 56, the determination unit 57, the threshold value comparison unit 91, the determination unit 92, the threshold value comparison unit 111, and the matrix unit 112 also perform time division processing. If the accommodated lines are 100 lines and a tone detection circuit for 8 channels is required, it is only necessary to provide a single tone detection circuit 19 by time-sharing the 8 channels. This greatly contributes to the reduction of scale, the associated cost reduction and miniaturization promotion, and reduction of power consumption.
[0177]
In the second to fourth embodiments, the arithmetic processing unit 53 and the peak detection unit 55 use flip-flops 73, 74, and 83 connected in multiple stages in order to hold values related to the respective frequencies of interest. However, a RAM, a FIFO memory or the like may be used. If the number of frequencies of interest p and the number of channels to be multiplexed are large and the number of flip-flop stages becomes very large, the circuit scale may be reduced by using these memories.
[0178]
In the second to fourth embodiments, the variable n is set to “1”, the multiplier 76 multiplies the product-sum operation value one frame period before by the coefficient, and the subtractor 71 multiplies the product two frames period before. Although the sum operation value is subtracted from the input value, the variable n may be arbitrary. For example, “2” is set to the multiplier 76 and the product-sum operation value two frames before is supplied to the multiplier 76. You may make it give the product-sum operation value 4 periods before, respectively. In such a case, for example, it is possible to take measures such as performing processing related to different frequencies of interest in odd-numbered frames and even-numbered frames.
[0179]
In the fourth embodiment, the same configuration as that of the third embodiment is used for the detection of the BT signal. However, the same configuration as that of the second embodiment can also be used. .
[0180]
In addition, various modifications can be made without departing from the scope of the present invention.
[0181]
【The invention's effect】
According to the first invention, in the digital sine wave data generator for generating sine wave data by outputting a digital value indicating the level of a sine wave signal having a predetermined frequency as an output digital value at predetermined intervals, Multiplying means for generating a first reference value obtained by multiplying an output digital value before a cycle by a constant determined according to the frequency of the sine wave signal, and a second reference value by inverting the output digital value two cycles before. Inversion means, addition means for adding the first reference value generated by the multiplication means and the second reference value generated by the inversion means to generate an output digital value at the present time, and the first reference A reset means for resetting the value to “0” and the second reference value to an initial value determined in accordance with the frequency of the sine wave signal; Timing means for measuring the elapsed time since the reset by the resetting means, polarity change detecting means for detecting that the polarity of the output digital value generated by the adding means has changed from positive to negative, and the output digital Level confirmation means for detecting that the absolute value of the value is a low level state that is equal to or less than a predetermined reference value, and the polarity change detection means in a state in which the elapsed time counted by the time measuring means exceeds a predetermined time And a reset control means for resetting the reset means if the low-level state is detected by the level confirmation means when the polarity change is detected by the digital confirmation processing. The sine wave data can be generated only by a process that can be realized with the simple digital circuit. It can provide and power consumption is a feasible, yet the strain less sinusoidal digital sine wave data generator capable of generating data.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a main configuration of a button telephone system including a sine wave data generator and a tone detection circuit according to the present invention.
FIG. 2 is a block diagram showing a specific configuration of a sine wave data generator 18 according to the first embodiment of the present invention.
3 is a diagram showing a sine wave indicated by sine wave data generated by the sine wave data generator 18 shown in FIG. 2; FIG.
FIG. 4 is a diagram showing how a maximum strain is generated at the time of resetting.
FIG. 5 is a block diagram showing a specific configuration of a tone detection circuit 19 according to the second embodiment of the present invention.
6 is a block diagram showing a specific configuration of an arithmetic processing unit 53 in FIG.
7 is a block diagram showing a specific configuration of a peak detection unit 55 in FIG.
FIG. 8 is a diagram showing a state of product-sum operation performed by the arithmetic processing unit 53 in FIG. 5;
FIG. 9 is a diagram illustrating a change in an output value V when a product-sum operation is performed with the frequency fx as a frequency of interest and the input signal frequency is changed to fx, fy, and fz.
10 is a diagram showing frequency spectra detected for each frequency of interest by the tone detection circuit 19 shown in FIG.
FIG. 11 is a diagram showing a state in which the frequency spectra shown in FIG. 10 are synthesized.
FIG. 12 is a block diagram showing a specific configuration of a tone detection circuit 19 in the third embodiment of the present invention.
13 is a block diagram showing a specific configuration of a threshold value comparison unit 91 in FIG.
14 is a diagram showing the arrangement of frequency spectra of each frequency of interest detected by the tone detection circuit 19 shown in FIG.
FIG. 15 is a block diagram showing a specific configuration of a tone detection circuit 19 according to a fourth embodiment of the present invention.
16 is a diagram showing the arrangement of the frequency spectrum of each frequency of interest detected by the tone detection circuit 19 shown in FIG.
[Explanation of symbols]
1 ... Main unit
2 (2-1 to 2-i): Extension terminal
11 ... Time switch
12 (12-1 to 12-j): Station line interface circuit
13 (13-1 to 13-i): Extension interface circuit
14 ... CPU
15 ... ROM
16 ... RAM
17 ... Data highway interface
18 ... Sine wave data generator
19: Tone detection circuit
20 ... PCM Highway
21 ... Data Highway
22 ... CPU local bus
31 ... Adder
32, 33 ... Latch circuit
34, 35 ... Multiplier
36 ... Output processing section
37 ... Latch circuit
38 ... Comparison part
39: Reference data register
40 ... Comparison part
41 ... Timer
42 ... AND gate
43. Initialization unit
51. Speed converter
52. Compression / linear conversion unit
53. Arithmetic processing part
54. Absolute value conversion unit
55. Peak detector
56: Adder
57. Determination unit
58 ... Register
59 ... CPU interface
60 ... Counter
61 ... Reset signal generator
71: Subtractor
72. Adder
73 (73-1 to 73-p) ... Flip-flop
74 (74-1 to 74-p) ... Flip-flop
75 ... coefficient generator
76 ... Multiplier
81 ... Comparator
82 ... Selector
83 (83-1 to 83-p) ... Flip-flop
91: Threshold comparison unit
92: Determination unit
101: Comparison circuit
102: Threshold register
111... Threshold value comparison unit
112 ... Matrix part
113 ... Register
114 ... CPU interface

Claims (1)

所定の周波数の正弦波信号のレベルを示すディジタル値を所定の周期毎に出力ディジタル値として出力することで正弦波データを生成するディジタル正弦波データ生成器において、
1周期前における出力ディジタル値に前記正弦波信号の周波数に応じて定まる定数を乗算した第1参照値を生成する乗算手段と、
2周期前における出力ディジタル値を反転させた第2参照値を生成する反転手段と、
前記乗算手段により生成された前記第1参照値と前記反転手段により生成された前記第2参照値とを加算して現時点における出力ディジタル値を生成する加算手段と、
前記第1参照値を「0」に、また前記第2参照値を前記正弦波信号の周波数に応じて定まる初期値にそれぞれリセットするリセット手段と、
このリセット手段によるリセットが行われてからの経過時間を計時する計時手段と、
前記加算手段で生成された前記出力ディジタル値の極性が正から負に変化したことを検出する極性変化検出手段と、
前記出力ディジタル値の絶対値が所定の基準値以下である低レベル状態であることを検出するレベル確認手段と、
前記計時手段により計時された経過時間が所定時間を超えている状態において、前記極性変化検出手段により極性変化が検出された際に前記レベル確認手段により前記低レベル状態であることが検出されていたならば前記リセット手段にリセットを行わせるリセット制御手段とを具備したことを特徴とするディジタル正弦波データ生成器。
In a digital sine wave data generator that generates sine wave data by outputting a digital value indicating a level of a sine wave signal of a predetermined frequency as an output digital value at a predetermined cycle,
Multiplying means for generating a first reference value obtained by multiplying an output digital value one cycle before by a constant determined according to the frequency of the sine wave signal;
Inverting means for generating a second reference value obtained by inverting the output digital value two cycles before;
Adding means for adding the first reference value generated by the multiplying means and the second reference value generated by the inverting means to generate a current output digital value;
Resetting means for resetting the first reference value to “0” and the second reference value to an initial value determined according to the frequency of the sine wave signal;
A time measuring means for measuring the elapsed time since the reset by the reset means,
Polarity change detecting means for detecting that the polarity of the output digital value generated by the adding means has changed from positive to negative;
Level confirmation means for detecting a low level state in which the absolute value of the output digital value is equal to or less than a predetermined reference value;
In a state in which the elapsed time measured by the time measuring means exceeds a predetermined time, the low level state is detected by the level confirmation means when the polarity change is detected by the polarity change detecting means. If so, a digital sine wave data generator comprising reset control means for causing the reset means to reset.
JP2000043200A 2000-02-21 2000-02-21 Digital sine wave data generator Expired - Fee Related JP4542658B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2000043200A JP4542658B2 (en) 2000-02-21 2000-02-21 Digital sine wave data generator

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2000043200A JP4542658B2 (en) 2000-02-21 2000-02-21 Digital sine wave data generator

Publications (2)

Publication Number Publication Date
JP2001238235A JP2001238235A (en) 2001-08-31
JP4542658B2 true JP4542658B2 (en) 2010-09-15

Family

ID=18566153

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2000043200A Expired - Fee Related JP4542658B2 (en) 2000-02-21 2000-02-21 Digital sine wave data generator

Country Status (1)

Country Link
JP (1) JP4542658B2 (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS62195903A (en) * 1986-02-24 1987-08-29 Hitachi Ltd Periodic function signal generating circuit
JPH01278104A (en) * 1988-04-30 1989-11-08 Oki Electric Ind Co Ltd Digital oscillator
JPH10313217A (en) * 1997-05-13 1998-11-24 Asahi Chem Ind Co Ltd Periodic waveform output circuit

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS62195903A (en) * 1986-02-24 1987-08-29 Hitachi Ltd Periodic function signal generating circuit
JPH01278104A (en) * 1988-04-30 1989-11-08 Oki Electric Ind Co Ltd Digital oscillator
JPH10313217A (en) * 1997-05-13 1998-11-24 Asahi Chem Ind Co Ltd Periodic waveform output circuit

Also Published As

Publication number Publication date
JP2001238235A (en) 2001-08-31

Similar Documents

Publication Publication Date Title
KR100295257B1 (en) Digital filter
EP0523307A1 (en) Decimation filter for a sigma-delta converter and data circuit terminating equipment including the same
JP4542658B2 (en) Digital sine wave data generator
RU2363963C1 (en) Multi-channel seismic jerks and tsunami warning system
JP4377544B2 (en) Tone generation circuit
US4009353A (en) Analog signal detection
US6668057B1 (en) Apparatus for receiving tone signal, apparatus for transmitting tone signal, and apparatus for transmitting or receiving tone signal
JP3479617B2 (en) Moving average filter
JPS5897968A (en) Sampling frequency converter for video signal
JPH06303101A (en) Digital filter
RU1809447C (en) Walsh spectrum analyzer
SU1730723A2 (en) Digital filter with linear delta modulation
RU1824597C (en) Pulse duration meter
JP2571268B2 (en) Correlator
SU1250980A1 (en) Multichannel device for determining sign of phase difference
JPS60119162A (en) Counting method of dial pulse
SU1264306A1 (en) Device for digital filtering
SU1179331A1 (en) Random pulse flow generator
RU1788592C (en) Device for search of pseudorandom sequence
SU1045233A1 (en) Digital correlator
SU1506525A1 (en) Random process generator
SU1096658A1 (en) Digital instrument system
SU450220A1 (en) Device for compressing multi-channel telemetry information
SU1042014A1 (en) Random number markovian sequence generator
JP2008158312A (en) Pitch estimator, pitch estimation method, self-correlation computing device, and self-correlation computation method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20061006

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20091202

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20091215

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20100205

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

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

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

Free format text: PAYMENT UNTIL: 20130702

Year of fee payment: 3

LAPS Cancellation because of no payment of annual fees