JP3722104B2 - Sound generator - Google Patents

Sound generator Download PDF

Info

Publication number
JP3722104B2
JP3722104B2 JP2002273966A JP2002273966A JP3722104B2 JP 3722104 B2 JP3722104 B2 JP 3722104B2 JP 2002273966 A JP2002273966 A JP 2002273966A JP 2002273966 A JP2002273966 A JP 2002273966A JP 3722104 B2 JP3722104 B2 JP 3722104B2
Authority
JP
Japan
Prior art keywords
sound source
access
unit
access request
request
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
JP2002273966A
Other languages
Japanese (ja)
Other versions
JP2004109686A (en
Inventor
和久 岡村
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Yamaha Corp
Original Assignee
Yamaha Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Yamaha Corp filed Critical Yamaha Corp
Priority to JP2002273966A priority Critical patent/JP3722104B2/en
Publication of JP2004109686A publication Critical patent/JP2004109686A/en
Application granted granted Critical
Publication of JP3722104B2 publication Critical patent/JP3722104B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Electrophonic Musical Instruments (AREA)

Description

【0001】
【発明の属する技術分野】
この発明は、音声データに基づいてチャンネル毎に音声信号を生成する音源部と、装置の動作を制御する制御部と、音源部と制御部の双方から同じ記憶手段にアクセスする手段とを有する音源装置に関し、特に、記憶手段に対するアクセス調停の効率化に関する。
【0002】
【従来の技術】
従来から、音声データに基づいてチャンネル毎に音声信号を生成する音源部と装置の動作を制御する制御部とを有する音源装置において、音声信号生成用の音声データ等と動作制御用のプログラムデータ等を共通のメモリに記憶し、音源部と制御部とによって共通バスを介してそのメモリにアクセスし、アクセス要求が競合した場合にはその調停を行うことが行われている。
【0003】
そして、このような装置として、特許2546098号公報には、音源部から記憶手段へのアクセス要求と制御部から記憶手段へのアクセス要求とが競合した場合に、基本的には制御部からのアクセス要求を優先させるが、音源部が楽音形成用のデータを使用するタイミングまでに必要な回数のアクセスを行うぎりぎりのタイミングになった場合だけは音源部からのアクセス要求を優先させる調停を行う電子楽器が開示されている。
このような電子楽器によれば、音源部と制御部に固定的にアクセスタイミングを割り振るのではなく、各部がフレキシブルにメモリアクセスを行うことができると共に、音源部に対して最低限必要なアクセスタイミングを確保しつつ制御部からのアクセス要求を優先しているので、音源部が発音を行わない場合のように音源部からのアクセス要求がない場合には制御部がメモリアクセスを独占できる等、記憶手段へのアクセス効率を改善することができる。
【0004】
また、特開平7−271376号公報には、基本的には音源部からのアクセス要求を優先するが、音声信号のレベルが所定値以下となった場合には音源部から記憶手段へのアクセスを禁止し、音源部からのアクセス要求を優先していた期間にCPUからのアクセスを許可するようにした音源装置が開示されている。
このような音源装置によれば、音源部からのアクセスが実質的に不要となる期間に音源部から記憶手段へのアクセスを行わないようにするので、その分のアクセスタイミングにCPU等の他のユニットからのアクセスを行うことができ、記憶手段へのアクセス効率を改善することができる。
【0005】
【発明が解決しようとする課題】
しかしながら、これらの装置においては、音源部が1チャンネル分の音声信号生成に用いる音声データの読み出しを行うべき期間をチャンネルスロットとして設定し、各チャンネルスロットを記憶手段への1回のアクセスに必要な期間毎に処理スロットに固定的に区分し、各処理スロット毎にどこからのアクセス要求を許可するかを決定するようにしていた。従って、アクセス速度の異なる複数のメモリを使用した場合でも、最もアクセス速度の遅いメモリのアクセスタイミングに合わせて処理スロットを設ける必要があり、アクセス速度の速いメモリと遅いメモリとを同じ速さでしか利用できないという問題があった。
【0006】
また、アクセス速度の異なる複数のメモリを使用した場合には、チャンネルスロット内に音源部が必要とするアクセスタイミングを確保するために必要な優先度はメモリによって異なる。すなわち、アクセス速度が遅く、チャンネルスロット内に音源部が必要とするぎりぎりの数のアクセスタイミングしか取れない場合には再優先で確保しなければならないが、アクセス速度が速く、タイミングに余裕がある場合には音源部の優先度はある程度低くてもよい。しかし、上述の装置においては、アクセス要求の優先度は、アクセス元がどこであるかに応じて決定しており、全てのメモリについて共通の基準を設けていたため、タイミングに余裕がないメモリに合わせた基準を使用しなければならないという問題があった。また、発音のためには、音源部が必要とするアクセスタイミングはチャンネルスロット内に必ず確保しなければならないが、必ず音源部のアクセスを優先させるとすると制御部のCPUがアクセスを待たされすぎて処理負荷が大きくなることがある。しかし、制御部のアクセス要求をある程度優先させるために特許2546098号公報に記載されているような調停を行うと、複雑な制御が必要になる。
【0007】
この発明は、これらの問題を解決し、音声データに基づいて音声信号を生成する音源部と、装置の動作を制御する制御部と、前記音源部と前記制御部の双方から同じ記憶手段にアクセスする手段とを有する音源装置において、記憶手段へのアクセス要求を簡単な処理で適切に調停して記憶手段へのアクセス効率を改善することを目的とする。さらに、アクセス速度の異なる複数のメモリを使用した場合にも簡単な処理で適切な調停を行うことができるようにすることも目的とする。
【0008】
【課題を解決するための手段】
上記の目的を達成するため、この発明の音源装置は、音声データに基づいて音声信号を生成する音源部と、装置の動作を制御する制御部と、上記音源部と上記制御部の双方から同じ記憶手段にアクセスする手段とを有する音源装置において、上記記憶手段に対する上記音源部からのアクセス要求が発生したとき、上記記憶手段に対する上記制御部からのアクセス要求が発生していなければ、上記音源部に対して連続したアクセス要求を許可し、上記記憶手段に対する上記制御部からのアクセス要求が発生していれば、上記音源部からのアクセス要求と上記制御部からのアクセス要求とをそれぞれ独立に定めた所定回数ずつ交互に許可するアクセス調停手段を設けたものである。
【0009】
また、音声データに基づいて音声信号を生成する音源部と、装置の動作を制御する制御部と、上記音源部と上記制御部の双方から同じ記憶手段にアクセスする手段とを有する音源装置において、上記記憶手段に、第1のメモリとその第1のメモリよりアクセス速度の速い第2のメモリとを設け、上記音源部から上記第1のメモリへのアクセス要求と上記制御部から上記第1のメモリへのアクセス要求とが競合した場合に、上記音源部からのアクセス要求を優先させて上記音源部からのアクセス要求と上記制御部からのアクセス要求を調停する第1の調停手段と、上記音源部から上記第2のメモリへのアクセス要求と上記制御部から上記第2のメモリへのアクセス要求とが競合した場合に、上記音源部からのアクセス要求と上記制御部からのアクセス要求とをそれぞれ独立に定めた所定回数ずつ交互に許可するように上記音源部からのアクセス要求と上記制御部からのアクセス要求を調停する第2の調停手段を設けたものである。
【0010】
あるいは、音声データに基づいてチャンネル毎に音声信号を生成する音源部と、装置の動作を制御する制御部と、上記音源部と上記制御部の双方から同じ記憶手段にアクセスする手段とを有する音源装置において、上記音源部が1チャンネル分の音声信号生成に用いる音声データの読み出しを行うべき期間を、動作クロックの所定クロック数単位でチャンネルスロットとして設定する手段を設け、上記記憶手段に1回のアクセスに動作クロックの複数クロック分の期間を要するメモリを設け、上記音源部に、各チャンネルスロットにおいてあらかじめ生成しておいた読み出しアドレスからの読み出し要求を上記メモリに対して行う読出要求手段を設け、上記動作クロックの各クロックタイミング毎に上記メモリへのアクセスの許可/不許可を決定し、各チャンネルスロットの開始時に、直前のチャンネルスロットから続いている上記制御部による上記メモリへのアクセスがない場合には直ちに上記読出要求手段による読み出し要求を許可し、直前のチャンネルスロットから続いている上記制御部による上記メモリへのアクセスがある場合にはそのアクセスの終了後に上記読出要求手段による読み出し要求を許可するアクセス調停手段をさらに設けたものである。
【0011】
【発明の実施の形態】
以下、この発明の好ましい実施の形態を図面を参照して説明する。
まず、この発明の音源装置の実施形態である音源LSIについて図1乃至図4を用いて説明する。図1はその音源LSIの構成を示すブロック図、図2はその音源LSIに接続する周辺ユニットを示すブロック図、図3はその音源LSIに備える音源コアの構成をより詳しく示すブロック図、図4は図3に示した音源部の構成をより詳しく示すブロック図である。
【0012】
この音源LSI10は、図2に示すように、操作子1,表示器2,サウンドシステム3,外部メモリ4に接続して電子楽器等の音源として用いられ、操作子1からの指示に従って音声信号を生成してサウンドシステム3に送出して発音を行わせたり、表示信号を生成して表示器2に送出して表示を行わせたりする装置である。そして、この音源LSI10は、図1に示すように内部にも記憶手段を有するが、外部記憶手段である外部メモリ4とも接続し、必要に応じてここに対してデータを読み書きして必要な動作を行う。なお、操作子1としてはダイアル、ボタン、鍵盤等を用いることができ、表示器2としては発光ダイオードや液晶ディスプレイを用いることができる。
【0013】
そして、音源LSI10は、図1に示すように、CPU11,入出力ポート12,タイマ13,割込コントローラ14,外部バス調停部15,内蔵ROM調停部16,内蔵SRAM(Static RAM)調停部17,音源コア30を備え、これらがCPUバス21によって接続されている。また、記憶手段として、内蔵ROM調停部16と接続する内蔵ROM18及び内蔵SRAM調停部17と接続する内蔵SRAM19とを備えると共に、外部バス調停部15、内蔵ROM調停部16,内蔵SRAM調停部17は、CPUバス21とは別の音源バス22によって音源コア30の音源部32と接続されている。さらに、内蔵SRAM調停部17はDSPバス23によって音源コア30のDSP部(波形処理部)33と接続されている。
【0014】
CPU11は、内蔵ROM18,内蔵SRAM19や外部メモリ4に記憶されているプログラムを読み出し、適当な記憶手段をワークメモリとして使用してそのプログラムを実行することにより、この音源LSI10の動作を制御する制御部である。そして、操作子1からの操作信号に従って制御動作を行い、また表示信号を表示器2に送出して表示を行わせる。
入出力ポート12は、操作子1や表示器2と音源LSI10とを接続するためのインタフェースとなるパラレルポートあるいはシリアルポートである。また、この入出力ポート12を介して他の装置とMIDI(Musical Instruments Digital Interface)規格による通信を行うこともできる。
タイマ13は、音源LSI10内の各回路に必要な動作クロックやタイミング信号を供給する動作クロック発生手段である。
割込コントローラ14は、CPU11における割込み処理の発生を制御するユニットである。
【0015】
外部バス調停部15は、外部メモリバス24を介して、外部メモリ4を構成する外部ROM25,外部SRAM26,外部DRAM(Dynamic RAM)27と接続し、CPU11及び音源コア30からこれらのメモリへのアクセスを仲介すると共に、アクセス要求が競合した場合にその調停を行う調停手段である。この外部バス調停部15の動作及び機能については後に詳述する。
内蔵ROM調停部16は、内蔵ROM18と接続し、CPU11及び音源部32から内蔵ROM18へのアクセスを仲介すると共に、アクセス要求が競合した場合にその調停を行う調停手段である。内蔵SRAM調停部17は、内蔵SRAM19と接続し、CPU11,音源部32及びDSP部33から内蔵SRAM19へのアクセスを仲介すると共に、アクセス要求が競合した場合にその調停を行う調停手段である。これらの調停部の動作及び機能についても後述する。
【0016】
内蔵ROM18,内蔵SRAM19は、外部の外部ROM25,外部SRAM26,外部DRAM27と共に記憶手段を構成し、音源コア30での音声信号生成処理に使用する波形データや、CPU11による制御処理に使用するプログラムやパラメータ等を記憶したり、CPU11のワークメモリとして機能したりする。CPU11及び音源部32はこれらの記憶手段を任意に選択してアクセス可能であり、DSP部33は内蔵SRAM調停部19のみにアクセス可能である。
【0017】
音源コア30は、音源制御部31,音源部32,DSP部33を備え、内蔵ROM18,内蔵SRAM19を初めとするメモリに記憶している波形データを読み出して音声信号を生成し、所要の加工を施してサウンドシステム3に対して出力する音源部である。この音源コア30は、後述するようにチャンネル毎に音声信号を生成し、32チャンネルの音声信号を生成することができる。
この音源コア30の構成をより詳しく示した図が図3である。
この音源コア30においては、音源制御部31がその全体の動作を制御する。すなわち、音源部32における音声信号の生成、DSP部33におけるエフェクト処理の内容、各チャンネルの発音の有無の制御等を行う。
【0018】
音源部32は、音源バスを介してメモリに記憶している音声データである波形データを読み出し、補間処理を行って各サンプリング周期における音声信号をチャンネル毎に生成する。そして、その音声信号を順次ミキサ部34に転送し、ミキサ部34においてミキシング処理を行う。なお、音声信号の生成は最大32チャンネル分並行して可能であり、1/44100秒のサンプリング周期毎に最大32チャンネル分の音声信号の生成を時分割で行う(図8参照)。そして、1チャンネル分の音声信号を生成する期間をチャンネルスロットとし、1チャンネルスロットは周期29.5ナノ秒の動作クロックであるマスタークロックの24クロック分の期間としている。
【0019】
また、ミキシング処理の際、エフェクトをかける必要があるチャンネルの音声信号については、DSP部33に転送してエフェクト処理を行う。そして、エフェクト処理後の音声信号をミキサ部34に戻し、エフェクト処理不要であったチャンネルの音声信号と加算してミキシング処理を行う。ここで、DSP部33はDSPバス23と内蔵SRAM調停部17とを介して内蔵SRAM19にアクセスし、ここを遅延メモリとして使用することができる。
ミキサ部34においてミキシングされた音声信号は、D/A変換部35でアナログ信号に変換し、サウンドシステム3に送信してその音声信号に基づいた発音を行わせる。
【0020】
次に、音源コア30の音源部32における波形データの読み出しと補間処理についてさらに詳しく説明する。その音源部32の構成をより詳しく示したものが図4である。
音源部32による波形データの読み出しは、アドレスレジスタ37に記憶している読み出しアドレスに対する読み出し要求を発することによって行うが、この読み出しアドレスは、音源制御部31のアドレス生成部36が生成する。このアドレス生成部36がアドレス生成手段である。
【0021】
ここで、内蔵ROM18,内蔵SRAM19あるいは外部メモリ4には、整数で表現されるアドレスに所定のサンプリング周期毎の波形データを記憶している。しかし、同じ波形の音をサンプリング時とは異なる音高で出力するためには、例えば1.5倍の周波数にするためには各サンプリング周期毎にサンプリング周期の1.5倍進んだ位置の波形データに基づいて発音する必要がある等、サンプリング周期の間の時点での波形データも必要になる。そこで、音源コア30においては、必要な波形データのアドレス情報を整数部と小数部で指定し、整数部をもとに読み出しアドレスを指定して必要な波形データを読み出し、小数部をもとに読み出したデータを補間することにより、サンプリング周期の間の時点での波形データを得ることができるようにしている。
【0022】
このとき、補間は整数部の値と整数部の値+1のアドレスから読み出した波形データを用いて行う。従って、補間バッファを設け、以前のサンプリング期間に読み出した波形データを記憶しておくようにすれば、アドレス情報の整数部が変化しない場合には記憶しておいた波形データを用いて補間を行い、整数部が変化した場合にのみ新たに波形データを読み出すようにすることができる。また、新たに読み出す場合でも、整数部の値が前のサンプリング期間と比較して1だけ増加した場合には新たに整数部の値+1のアドレスから1つの波形データを読み出すのみでよく、2以上増加した場合にのみ整数部の値と整数部の値+1のアドレスから2つの波形データを読み出せばよい。すなわち、読み出すべき波形データの数は0から2であり、読み出しアドレスもその数だけ生成することになる。
【0023】
アドレス生成部36では、サンプリング周期毎に、発音を指定された音高と波形データの音高との比に対応した数値であるFナンバを累算することにより上記のアドレス情報を生成し、その整数部に従って上記のように必要な数だけ読み出しアドレスを生成してアドレスレジスタ37に記憶させる。そして、読出要求手段として機能する音源部32が、アドレスレジスタ37に記憶されているアドレスに対して読み出し要求を発する。なお、各メモリはメモリマップ上の所定のアドレス領域にマッピングされており、アドレスを指定した読み出し要求は、そのアドレスに対応したメモリへのアクセス要求となる。
【0024】
この要求が後に詳述するようにそのメモリに対応する調停部に許可されると、読み出しアドレスに記憶された波形データが読み出され、音源部32に返されるので、読出データレジスタ38にこれを記憶する。そして、これを補間部39に転送し、アドレス情報の小数部をもとに読み出した(あるいはバッファに蓄積している)波形データに対して補間処理を行うことにより、アドレス情報に対応した波形データを生成することができる。なお、補間バッファは補間部39に設け、新たに読み出した波形データをここに記憶させる場合には、既に記憶してあるデータは古い順に消去するものとする。
そして、補間によって生成した波形データに対して、さらに図示しないエンベロープ制御回路において、音の立ち上がりから立ち下がりまでの音量の時間変化を示す音量エンベロープ波形を乗算することにより、1チャンネル分の音声信号の生成が完了し、その音声信号はミキサ部34に転送してミキシング処理に供することになる。
音源コア30では、以上のような処理により、メモリから波形データを読み出してそれに基づいてチャンネル毎に音声信号を生成することができる。
【0025】
次に、図5乃至図8を用いてこの音源LSIに備える各調停部の構成と動作について説明する。図5乃至図7はそれぞれ図1に示した外部バス調停部15,内蔵ROM調停部16,内蔵SRAM調停部17の構成をより詳しく示すブロック図、図8は各調停部によるアクセス調停の動作について説明するための図である。
まず、外部バス調停部15について説明する。
外部バス調停部15は、図5に示すように、選択回路41,調停回路42,デコード部43,44,エリア判定回路45,タイミング発生回路46,アクセス回路47を備えている。
【0026】
選択回路41は、CPUバス21及び音源バス22と接続し、CPU11及び音源部32からのアクセス要求を受け付け、調停回路42からの指示に従って、調停回路42が許可したアクセス要求をアクセス回路47に通す回路である。なお、音源部32は書き込みを行わないので、音源部32からのアクセス要求は常に読み出し要求である。
【0027】
調停回路42は、CPUバス21と音源バス22によって送られてくるアクセス要求に係るアドレスをそれぞれデコード部43,44によってデコードした結果が入力し、その結果に基づいて許可するアクセス要求を決定して選択回路41に指示する回路である。どのように許可するアクセス要求を決定するかについては、後述する。なお、デコード部43,44によるデコードは、それぞれCPUバス21,音源バス22から送られてくるアクセス要求に係るアドレスをメモリマップと対照し、それがどのメモリに対するアクセス要求であるかを判定するものである。あるいは、外部メモリバス24に接続されたいずれかのメモリに対するアクセス要求であるか否かを判定するものであってもよい。
ここでは、簡単化のため、CPU11及び音源部32が同じ広さのメモリ空間をアクセス可能であって、外部メモリ4,内蔵ROM18,内蔵SRAM19がそれぞれ各メモリ空間の同じ領域に配置されているものとする。
また、調停回路42は、制御信号として、CPU11に対してアクセス要求に対する読み出し動作が終了するまで待機させるためのCPU_WAIT信号を送信したり、音源部32に対して読み出し動作の完了を伝えるためのTG_ACK信号を送信したりもする。
【0028】
エリア判定回路45は、選択回路41が通したアクセス要求が外部メモリバス24に接続されたメモリのうちいずれに対するものであるかを判定する回路であり、M_AREA信号がその判定基準として各メモリとアドレスとの対応関係の情報を入力する。
タイミング発生回路46は、外部メモリ4にアクセスする際のアドレス,データ,制御信号等のタイミングを制御するためのタイミング信号を発生してアクセス回路47に供給する回路である。ここで、制御信号とは、例えば、アクセス対象のメモリがSRAMであれば、出力を許可するOE信号、書き込みを指示するWE信号等であり、SDRAM(Synchronous Dynamic RAM)等であれば、同期動作のためのクロック信号,CS信号,RAS信号、CAS信号,WE信号等である。
この音源LSI10においては、図1に示したように、外部メモリバス24に接続された各メモリは動作速度が異なるため、アクセス対象となるメモリによって異なるタイミングでこの信号を発生させることができるようにしたものである。なお、M_SPD信号は各メモリの種類とアクセス期間を示す情報であり、この信号に応じて異なるタイミング信号を発生する。
【0029】
アクセス回路47は、選択回路41から供給されるアクセス要求に基づき、タイミング信号により制御されたタイミングでアドレスや各種制御信号等を発生し、外部メモリバス24を介して外部メモリ4をアクセスする回路である。そして、読み出しの場合には、タイミング発生回路46からのタイミング信号に応じて読み出したデータを記憶し、選択回路41を介して読み出し要求を行ったCPU11又は音源部32にそのデータを返す。また、タイミング発生回路46からのタイミング信号に基づいて、次のタイミングで新たなアクセスが可能な場合にはハイレベル、そうでない場合にはローレベルとするSIG1信号を生成して調停回路42に送信し、次のアクセスを許可可能なタイミングを伝達する。
【0030】
ここで、調停回路42における許可するアクセス要求の決定方式について説明する。
まず、調停回路42は、アクセス要求を許可するかしないかの判断を、図8に示すマスタークロックの1クロックタイミング毎に行う。そして、アクセス要求が外部メモリバス24に接続されたいずれかのメモリに対するものでなければ、その要求は許可しない。また、SIG1信号が前のタイミングでハイレベルでなければ、すなわち外部メモリバス24が使用中であれば、いかなるアクセス要求も許可しない。
【0031】
一方、外部メモリバス24が使用中でなく、外部メモリバス24に接続されたいずれかのメモリに対するアクセス要求が1つ(CPU11と音源部32のいずれかから)だけであれば、その要求を許可し、2つ(CPU11と音源部32の両方から)あれば、音源部32からの要求を優先的に許可する。これは、外部メモリバス24に接続されたメモリは動作速度が遅いので、チャンネルスロット内に音源部32が必要とする波形データを確実に全て読み出すことができるようにするためには音源部32からのアクセスの優先度を高くする必要があるためである。
また、チャンネルスロット毎に見ると、CPU11はチャンネルスロットとは関係なくアクセス要求を行うが、音源部32は(データの読み込みが必要な場合には)チャンネルスロットの開始時にアクセス要求を行う。従って、これらのアクセス要求を調停回路42が調停した場合、結果は図8の(A)に示すようになる。
【0032】
すなわち、各チャンネルスロットの開始時に、直前のチャンネルスロットから続いているCPU11によるメモリへのアクセスがない場合には、音源部32からのアクセス要求と同時にCPU11からのアクセス要求があったとしても、音源部32を優先して直ちにそのアクセス要求を許可する。一方、直前のチャンネルスロットから続いているCPU11によるメモリへのアクセスがある場合には、新たなアクセスは許可できないので、そのアクセスの終了後に音源部32からのアクセス要求を許可する。この場合も、CPU11によるアクセスの終了後直ちにCPU11から次のアクセス要求があったとしても、音源部32からのアクセス要求を優先して許可する。
音源部32からのアクセス要求は1チャンネルスロットに0〜2回であることは上述したが、2回目のアクセス要求があった場合も、やはり音源部32からのアクセス要求を優先して許可する。音源部32のアクセス要求より前からCPU11がアクセス要求を行っていた場合でも同様である。
このような調停を行う外部バス調停部15は、第1の調停手段となる。
【0033】
このような調停動作を行った場合、1回のメモリアクセスに必要な期間を6クロック分の期間とすると、最も早い場合でチャンネルスロットの12クロック目、最も遅い場合でも17クロック目までに音源部32が必要とする波形データを読み出すことができるので、音源部32における音声信号の生成が滞ることがない。
一方で、1チャンネルスロットを、最も速いメモリのアクセス期間以下のベースクロックに分割し、1回のアクセスに複数クロック分の期間を要する遅いメモリであっても、そのベースクロックのクロックタイミング毎にアクセス可否の判断を行うようになってきているので、CPU11と音源部32から各メモリへのアクセス期間を密に詰めることができ、動作を高速に行うことができる。
【0034】
また、チャンネルスロットをまたいだアクセスも可能となり、音源部32を常にCPU11に優先させるようにする場合でも、チャンネルスロット終了間際にCPU11からのアクセスを許可して音源部32からのアクセス要求をそのアクセスを終了するまで待たせるような制御が、特に複雑な条件設定をすることなく可能となる。従って、簡単な制御回路でCPU11の待機時間を低減して処理負荷を低減することができる。
なお、図8に示した例の場合、カッコをつけて示したように音源部32の2回目のアクセスの前にCPU11からのアクセス要求を1回許可しても、2回目のアクセスは23クロック目までに終了するので、このような制御を行うようにしてもよい。ただし、これはアクセスが6クロックかかるメモリの例であり、アクセスに7クロック以上かかるメモリが接続されることが想定される場合には、本実施の形態のように音源部32を常にCPU11に優先させねばならない。
【0035】
次に、内蔵ROM調停部16について説明する。
内蔵ROM調停部16は、図6に示すように、選択回路51,調停回路52,デコード部53,54,タイミング発生回路56,アクセス回路57を備えている。これらの要素は、概ね外部バス調停部15の対応する要素と同様な機能を有するので、同様な部分についての説明は省略するか簡単にする。
選択回路51は、選択回路41と同様、調停回路52が許可したアクセス要求をアクセス回路57に通す回路である。
【0036】
調停回路52は、調停回路42と同様、デコード部53,54によってデコードした結果が入力し、その結果に基づいて許可するアクセス要求を決定して選択回路51に指示したり、種々の制御信号を送信したりする回路である。どのように許可するアクセス要求を決定するかについては、後述する。なお、デコード部53,54によるデコードは、それぞれCPUバス21,音源バス22から送られてくるアクセス要求に係るアドレスをメモリマップと対照し、それが内蔵ROM18に対するアクセス要求であるか否かを判定するものである。
【0037】
タイミング発生回路56は、タイミング発生回路46と同様、内蔵ROM18にアクセスする際のアドレス,データ,制御信号等のタイミングを制御するためのタイミング信号を発生する回路であるが、ここではアクセス対象は内蔵ROM18だけであり、内蔵ROM18をアクセスするためのタイミング信号のみを発することができる。
アクセス回路57は、アクセス回路47と同様、選択回路51から供給されるアクセス要求に基づき、タイミング信号により制御されたタイミングで内蔵ROM18をアクセスし、読み出しの場合には読み出したデータを記憶し、選択回路51を介して読み出し要求元にそのデータを返す回路である。また、SIG1信号と同様な意味のSIG2信号を生成して調停回路52に送信する。
【0038】
ここで、調停回路52における許可するアクセス要求の決定方式について説明する。
まず、調停回路52も、アクセス要求を許可するかしないかの判断を、図8に示すマスタークロックの1クロックタイミング毎に行う。そして、アクセス要求が内蔵ROM18に対するものでなければ、その要求は許可しない。また、SIG2信号が前のタイミングでハイレベルでなければ、すなわち内蔵ROM18が使用中であれば、いかなるアクセス要求も許可しない。
一方、内蔵ROM18が使用中でなく、内蔵ROM18に対するアクセス要求が1つだけであれば、その要求を許可し、アクセス要求が継続的に2つあれば、内蔵ROM18が使用中でなくなるクロックタイミング毎にこれらの要求を交互に許可する。すなわち、例えばチャンネルスロット内で最初に許可を行う場合には音源部32を許可し、次に許可を行う場合にはCPU11を許可し、という具合である。ただし、途中で一方のアクセス要求がなくなった場合には、順番に関係なくもう一方のアクセス要求を許可するものとする。
【0039】
内蔵ROM18に対するアクセス要求を調停回路52が調停した場合、結果は図8の(B)に示すようになる。
すなわち、各チャンネルスロット内で最初にアクセス要求を許可する時点では、音源部32からのアクセス要求と同時にCPU11からのアクセス要求があったとしても、音源部32を優先して直ちにそのアクセス要求を許可する。もちろん、直前のチャンネルスロットから続いているCPU11によるメモリへのアクセスがある場合には、新たなアクセスは行えないので、そのアクセスが終了するまでどちらのアクセス要求も許可しない。
最初に許可したアクセスが終了すると、次はCPU11からのアクセス要求を優先して許可する。そして、その次は音源部32からのアクセス要求を優先して許可する。ここでは音源部32からのアクセス要求はチャンネルスロット当たり最大2回であるので、それ以後はCPU11からのアクセス要求があった場合にそれを許可することになる。
【0040】
内蔵ROM18は比較的動作速度が速いので、さほど音源部32からのアクセスの優先度を高くしなくても、チャンネルスロット内に音源部32が必要とする波形データを確実に全て読み出すことができる。そこで、CPU11からのアクセス要求を待たせてCPU11を待機させる頻度を減らすよう、ある程度CPU11からのアクセス要求も優先させるようにしている。そして、このような制御は極めて簡単に行うことができ、CPU11と音源部32との間で優先度を調整する場合でも、調停回路52を簡単なロジック回路で構成することができる。
なお、上述した調停において、最初にCPU11からのアクセス要求を許可するようにしてもよいし、1回ずつに限らず、CPU11を3回につき音源部32を1回等、独立に定めた所定回数ずつ交互に許可するようにしてもよい。この場合において、CPU11からのアクセスを音源部32からのアクセス以上の回数許可するようにすると、CPU11を待機させる頻度の低減に効果的である。このような調停を行う内蔵ROM調停部16は、第2の調停手段となる。
【0041】
次に、内蔵SRAM調停部17について説明する。
内蔵SRAM調停部17は、図7に示すように、選択回路61,調停回路62,デコード部63,64,タイミング発生回路66,アクセス回路67を備えている。これらの要素は、概ね内蔵ROM調停部16の対応する要素と同様な機能を有するので、同様な部分についての説明は省略するか簡単にする。
選択回路61は、選択回路51と同様、調停回路62が許可したアクセス要求をアクセス回路67に通す回路である。ただし、選択回路61はDSPバス23とも接続し、DSP部33からのアクセス要求も受け付けるので、このアクセス要求も調停回路62による調停の対象となる。
【0042】
調停回路62は、調停回路52と同様、許可するアクセス要求を指示したり、種々の制御信号を送信したりする回路である。ただし、調停回路62にはデコード部63,64によるデコード結果の他に、DSPバス23経由のアクセス要求も入力し、許可するアクセス要求を決定する際にDSPバス23経由の要求も参照する。どのように許可するアクセス要求を決定するかについては、後述する。なお、デコード部63,64によるデコードは、それぞれCPUバス21,音源バス22から送られてくるアクセス要求に係るアドレスをメモリマップと対照し、それが内蔵SRAM19に対するアクセス要求であるか否かを判定するものである。DSPバス23経由のアクセス要求については、常に内蔵SRAM19へのアクセス要求であるので、このような判定を行うデコーダは不要であり、設けていない。
タイミング発生回路66は、1クロックでアクセス可能な内蔵SRAM19にアクセスするためのタイミング信号を発生する以外は、タイミング発生回路56と同様である。アクセス回路67は、選択回路61からのアクセス要求に基づき、タイミング信号のタイミングで内蔵SRAM19をアクセスし、SIG2信号に代えてSIG3信号を生成する点以外は、アクセス回路57と同様である。
【0043】
ここで、調停回路62における許可するアクセス要求の決定方式について説明する。
まず、調停回路62も、アクセス要求を許可するかしないかの判断を1クロックタイミング毎に行う。そして、アクセス要求が内蔵SRAM19に対するものでなければ、そのアクセス要求は許可しない。なお、ここでは内蔵SRAM19へのアクセスは1クロック分の期間で完了するので、SIG3信号は常にハイレベルであり、内蔵SRAM19が使用中でアクセス要求が許可できない状況にはならない。
一方、内蔵SRAM19に対するアクセス要求が1つだけであれば、その要求を許可し、アクセス要求が継続的に2つあれば、それらの要求を各クロックタイミング毎に交互に許可する。ただし、DSP部33については、アクセスを決まったタイミングで実行できないとエフェクト処理に支障を来すので、DSP部33からのアクセス要求があった場合には最優先で許可する。
【0044】
内蔵SRAM19に対するアクセス要求を調停回路62が調停した場合、結果は図8の(C)に示すようになる。
概ね内蔵ROM18の場合と同様であるが、アクセスは1クロック分の期間で完了するので、直前のチャンネルスロットからアクセスが続いていることはない。なお、DSP部33からのアクセス要求はDSP部33が必要としない場合にはないが、あるとすれば各チャンネルスロットの12クロック目と24クロック目であり、この要求は最優先で許可する。
内蔵SRAM19も動作速度が速いので、ある程度CPU11からのアクセス要求も優先させるようにしている。そして、このような制御は極めて簡単に行うことができ、CPU11と音源部32との間で優先度を調整する場合でも、調停回路52を簡単な回路で構成することができる。このような調停を行う内蔵SRAM調停部17も、第2の調停手段となる。
【0045】
次に、図9乃至図11に示す具体例を用いてこの音源LSIにおける記憶手段へのアクセス調停についてさらに説明する。図9乃至図11は、それぞれそのアクセス調停の別々の具体例を示す図である。
まず、図9に示す例においては、CPU11は、矢印で示したチャンネルスロットの開始前において、外部ROM25へのアクセス要求を行っている。この時点では外部メモリバス24は使用されておらず、音源部32から外部メモリ4へのアクセス要求もないので、外部バス調停部15はそのアクセス要求を許可する。そして、読み出しが終了するまでCPU11を待機させるべく、CPU_WAIT信号をローレベルにする。
このとき、外部バス調停部15のエリア判定回路45はアクセス要求先が外部ROM25と判定し、タイミング発生回路46で外部ROM25にアクセスするための6クロック時間分のタイミング信号を発生させる。また、アクセス回路47は、新たなアクセスは許可できない旨を示すため、SIG1信号をローレベルにする。
【0046】
一方、チャンネルスロットの開始時に音源部(TG)32が外部DRAM27へのアクセス要求を行うが、直前のチャンネルスロットから続いているCPU11のアクセスがあり、外部メモリバス24は使用中であるので、このアクセス要求はCPU11のアクセスが終了するまで許可されない。その後、CPU11のアクセスが終了するタイミングになると、SIG1信号がHIGHにされ、次のクロックのタイミングでアクセスが許可可能である旨が調停回路42に伝達される。
【0047】
この例の場合、次のタイミングではCPU11から外部ROM25への次のアクセス要求がなされる。この要求は、音源部32からのアクセス要求と対象のメモリは異なるものの、同じ外部メモリバス24を使用する要求であるので、音源部32からのアクセス要求と競合することになる。しかし、外部バス調停部15においては音源部32からの要求を優先させるので、次も音源部からの要求が許可される。
そして、音源部32による2回目のアクセスの終了後には、もはやCPU11からのアクセス要求は他と競合していないので、CPU11からの要求が許可される。その後、CPU11は内蔵ROM18に対してアクセス要求を行うが、これも他と競合していないので、内蔵ROM調停部16によって許可される。
【0048】
次の図10に示す例においては、矢印で示すチャンネルスロットの開始時に、CPU11と音源部32が同時に内蔵SRAM19へのアクセス要求を行っている(「S」で示した)。これらの要求は競合するため、内蔵SRAM調停部17が調停を行う。そして、CPU11からの要求と音源部32からの要求を交互に許可するが、ここでは、図8に示した例の場合と異なり、CPU11からの要求を先に許可するものとする。従って、まずCPU11からの要求を許可し(「C」で示した)、次のタイミングでもCPU11からの新たな要求と音源部32からの要求が競合しているが、ここでは音源部32からの要求を許可する(「T」で示した)。以後、4クロック目まではCPU11からの要求と音源部32からの要求が競合しているのでこれらを交互に許可し、5クロック目では音源部32からの要求がなくなるのでCPU11からの要求を許可する。
7から10クロック目ではどこからもアクセス要求がないので調停は不要である。
【0049】
そして、11クロック目からCPU11が内蔵SRAM19へのアクセス要求を4回行う。この間に音源部32からのアクセス要求はないが、12クロック目にはDSP部33から内蔵SRAM19へのアクセス要求があり(図示は省略した)、上述したようにこの要求は最優先で許可するので(「D」で示した)、CPU11のアクセス要求は12クロック目には許可されず、1クロック分の期間待たされる。
その後、CPU11は外部SRAM26に対して2回のアクセス要求を行うが、この要求は音源部32と競合しないため、そのまま許可される。1回のアクセスに必要なクロックは5クロックであり、2回目のアクセスは次のチャンネルスロットにまたがることになるが、制御上全く問題ない。また、矢印で示したチャンネルスロットの24クロック目にDSP部33が、次のチャンネルスロットの1クロック目に音源部32が内蔵SRAM19に対してアクセス要求を行っているが、内蔵SRAM19に対するアクセスには外部メモリバス24を使用しないため、これらのアクセス要求は、CPU11の行っているアクセス要求とは競合せず、別途許可可能である。
【0050】
次の図11に示す例においては、CPU11は矢印で示したチャンネルスロットの開始前から連続して内蔵SRAM19に対するアクセス要求を行っており、音源部32はそのチャンネルスロットの開始時に外部SRAM26に対するアクセス要求を行っている。しかし、上述の場合と同様、これらのアクセス要求は競合しないので、内蔵SRAM調停部17と外部バス調停部15によってそれぞれ独立に許可される。
その後、5クロック目にCPU11が外部SRAM26に対するアクセス要求を行うが、この時点では外部メモリバス24は使用中であるので、音源部32のアクセスが終了する次のクロックまでは外部バス調停部15はこの要求を許可しない。
【0051】
しかし、6クロック目には、音源部32から外部SRAM26に対する2回目のアクセス要求があり、これが5クロック目からのCPU11の要求と競合する。そして、外部バス調停部15は音源部32からの要求を優先させるので、次もこちらを許可し、CPU11からの要求はさらに待たされる。そして、音源部32からの2回目のアクセスの終了後には競合が解消されるので、許可される。そして、その後のCPU11からのアクセス要求は他からの要求とは競合しないのでそのまま許可される。
【0052】
この音源LSI10においては、各調停部15,16,17において各メモリへのアクセス要求を検出し、競合が起こった場合に上述したような調停を行うことにより、音源部32が各チャンネルスロットにおいて必要な波形データを読み出すことができるようにする一方、CPU11からのアクセスを待たせる期間を低減することができ、メモリへのアクセス効率を改善してCPU11の負荷を低減することができる。また、メモリの動作速度に応じて異なる調停を行うようにすれば、1つ1つの調停は簡単な回路で行うことができる簡易な調停としながら、動作速度に応じて音源部32の優先度を調整してCPU11の負荷をより低減することができる。動作速度に2倍以上の差がある複数のメモリを用いた場合には、このような調停が特に効果的である。
【0053】
さらに、少なくとも動作の遅いメモリについては、1つのチャンネルスロット内にいくつか固定のアクセス期間を設けるのではなく、メモリへの1回のアクセスに動作クロックの複数クロック分の期間を要するように動作クロックを設定し、その動作クロックのどのクロックタイミングからでもメモリへのアクセスを開始できるようにすれば、アクセスタイミングを柔軟に設定してメモリへのアクセス効率を改善することができる。また、動作速度の異なる複数のメモリを用いる場合にも、特に複雑な制御を行うことなく、それぞれのメモリの動作速度に合ったアクセス制御と調停処理を行うことができる。
【0054】
なお、上述した実施形態では、1チャンネルスロットが24クロックであったが、1チャンネルスロットのクロック数はそれより多くても少なくてもよい。また、CPU11と音源部32のメモリマップが同じものとしたが、CPU11と音源部32で、外部メモリ4,内蔵ROM18,内蔵SRAM19を各メモリ空間の異なる位置に配置するようにしてもよい。
【0055】
【発明の効果】
以上説明してきたように、この発明によれば、音声データに基づいて音声信号を生成する音源部と、装置の動作を制御する制御部と、前記音源部と前記制御部の双方から同じ記憶手段にアクセスする手段とを有する音源装置において、音源部と制御部からの記憶手段へのアクセス要求を簡単な処理で適切に調停して記憶手段へのアクセス効率を改善し、制御部の負荷を低減することができる。また、アクセス速度の異なる複数のメモリを使用した場合にも簡単な処理で適切な調停を行うことができる。
【図面の簡単な説明】
【図1】この発明の音源装置の実施形態である音源LSIの構成を示すブロック図である。
【図2】その音源LSIに接続する周辺ユニットを示すブロック図である。
【図3】その音源LSIに備える音源コアの構成をより詳しく示すブロック図である。
【図4】図3に示した音源部の構成をより詳しく示すブロック図である。
【図5】図1に示した外部バス調停部の構成をより詳しく示すブロック図である。
【図6】図1に示した内蔵ROM調停部の構成をより詳しく示すブロック図である。
【図7】図1に示した内蔵SRAM調停部の構成をより詳しく示すブロック図である。
【図8】図5乃至図7に示した各調停部によるアクセス調停の動作について説明するための図である。
【図9】図5乃至図7に示した各調停部によるアクセス調停の具体例を示す図である。
【図10】その別の例を示す図である。
【図11】そのさらに別の例を示す図である。
【符号の説明】
1…操作子、2…表示器、3…サウンドシステム、4…外部メモリ、10…音源LSI、11…CPU、12…入出力ポート、13…タイマ、14…割込コントローラ、15…外部バス調停部、16…内蔵ROM調停部、17…内蔵SRAM調停部、18…内蔵ROM、19…内蔵SRAM、21…CPUバス、22…音源バス、23…DSPバス、24…外部メモリバス、25…外部ROM、26…外部SRAM、27…外部DRAM、30…音源コア、31…音源制御部、32…音源部、33…DSP部、34…ミキサ部、35…D/A変換部、36…アドレス生成部、37…アドレスレジスタ、38…読出データレジスタ、39…補間部、41,51,61…選択回路、42,52,62…調停回路、43,44,53,54,63,64…デコード部、45…エリア判定回路、46,56,66…タイミング発生回路、47,57,67…アクセス回路
[0001]
BACKGROUND OF THE INVENTION
A sound source having a sound source unit that generates an audio signal for each channel based on audio data, a control unit that controls operation of the apparatus, and a unit that accesses the same storage unit from both the sound source unit and the control unit The present invention relates to an apparatus, and more particularly, to efficient access arbitration for storage means.
[0002]
[Prior art]
Conventionally, in a sound source device having a sound source unit that generates a sound signal for each channel based on sound data and a control unit that controls the operation of the device, sound data for sound signal generation, program data for operation control, etc. Is stored in a common memory, the sound source unit and the control unit access the memory via a common bus, and arbitration is performed when access requests conflict.
[0003]
As such an apparatus, Japanese Patent No. 2546098 discloses that when an access request from the sound source unit to the storage unit and an access request from the control unit to the storage unit conflict, the access from the control unit is basically performed. An electronic musical instrument that performs arbitration that gives priority to access requests from the sound source unit only when the request is prioritized, but only when the sound source unit accesses the required number of times until the timing to use the data for music generation Is disclosed.
According to such an electronic musical instrument, instead of assigning fixed access timings to the sound source unit and the control unit, each unit can flexibly perform memory access, and the minimum access timing required for the sound source unit. Priority is given to the access request from the control unit while securing the memory, so that the control unit can monopolize the memory access when there is no access request from the sound source unit, such as when the sound source unit does not sound. The access efficiency to the means can be improved.
[0004]
Japanese Patent Application Laid-Open No. 7-271376 basically gives priority to access requests from the sound source unit. However, when the level of the audio signal falls below a predetermined value, the sound source unit accesses the storage means. A sound source device is disclosed in which access from a CPU is permitted during a period in which the access request from the sound source unit is prioritized.
According to such a sound source device, the access from the sound source unit to the storage means is not performed during a period in which access from the sound source unit is substantially unnecessary. Access from the unit can be performed, and the access efficiency to the storage means can be improved.
[0005]
[Problems to be solved by the invention]
However, in these apparatuses, a period in which the sound source unit should read audio data used to generate an audio signal for one channel is set as a channel slot, and each channel slot is necessary for one access to the storage means. Each processing slot is fixedly divided into processing slots, and from each processing slot, it is determined where an access request is permitted. Therefore, even when multiple memories with different access speeds are used, it is necessary to provide a processing slot according to the access timing of the memory with the slowest access speed. There was a problem that it could not be used.
[0006]
In addition, when a plurality of memories having different access speeds are used, the priority required to secure the access timing required by the sound source unit in the channel slot differs depending on the memory. In other words, if the access speed is slow and there is only the access timing required by the sound source unit in the channel slot, it must be secured by reprioritization, but the access speed is fast and there is a margin in timing. The priority of the sound source unit may be low to some extent. However, in the above-mentioned apparatus, the priority of the access request is determined according to where the access source is, and since a common reference is provided for all the memories, it is adjusted to a memory with no timing margin. There was a problem that the standard had to be used. In addition, for sound generation, the access timing required by the sound source unit must be ensured in the channel slot. However, if priority is given to the access of the sound source unit, the CPU of the control unit will be waiting for access too much. Processing load may increase. However, when arbitration is performed as described in Japanese Patent No. 2546098 in order to give priority to access requests from the control unit to some extent, complicated control is required.
[0007]
The present invention solves these problems, and a sound source unit that generates an audio signal based on audio data, a control unit that controls the operation of the apparatus, and the same storage means are accessed from both the sound source unit and the control unit. It is an object of the present invention to improve access efficiency to a storage unit by appropriately arbitrating an access request to the storage unit with a simple process. It is another object of the present invention to allow appropriate arbitration by simple processing even when a plurality of memories having different access speeds are used.
[0008]
[Means for Solving the Problems]
In order to achieve the above object, the sound source device of the present invention includes a sound source unit that generates an audio signal based on audio data, a control unit that controls the operation of the device, and both the sound source unit and the control unit. A sound source device having means for accessing storage means; When an access request from the sound source unit to the storage unit is generated, if an access request from the control unit to the storage unit is not generated, a continuous access request is permitted to the sound source unit, and the storage If an access request from the control unit to the means has occurred, Access arbitration means for alternately permitting the access request from the sound source unit and the access request from the control unit by a predetermined number of times determined independently of each other is provided.
[0009]
Further, in a sound source device having a sound source unit that generates an audio signal based on audio data, a control unit that controls the operation of the device, and a unit that accesses the same storage unit from both the sound source unit and the control unit, The storage means is provided with a first memory and a second memory having a higher access speed than the first memory, and an access request from the sound source unit to the first memory and the control unit from the first memory. A first arbitration unit that arbitrates an access request from the sound source unit and an access request from the control unit by giving priority to an access request from the sound source unit when there is a conflict with an access request to the memory; When an access request from the control unit to the second memory conflicts with an access request from the control unit to the second memory, The access request from the sound source unit and the access request from the control unit are alternately permitted by a predetermined number of times determined independently. As described above, the second arbitration means for arbitrating the access request from the sound source unit and the access request from the control unit is provided.
[0010]
Alternatively, a sound source including a sound source unit that generates an audio signal for each channel based on audio data, a control unit that controls the operation of the apparatus, and a unit that accesses the same storage unit from both the sound source unit and the control unit In the apparatus, there is provided means for setting, as a channel slot, a predetermined clock number unit of the operation clock for a period in which the sound source unit is to read audio data used for generating an audio signal for one channel. A memory that requires a period corresponding to a plurality of operating clocks for access is provided, and a read request means for making a read request from the read address generated in advance in each channel slot is provided in the sound source unit, Permit / deny access to the memory at each clock timing of the operation clock At the start of each channel slot, if there is no access to the memory by the control unit continuing from the previous channel slot, the read request by the read request means is immediately permitted and the channel slot continues from the previous channel slot. In the case where there is an access to the memory by the control unit, an access arbitration unit is further provided that permits a read request by the read request unit after the access is completed.
[0011]
DETAILED DESCRIPTION OF THE INVENTION
Preferred embodiments of the present invention will be described below with reference to the drawings.
First, a sound source LSI which is an embodiment of a sound source device of the present invention will be described with reference to FIGS. 1 is a block diagram showing the configuration of the tone generator LSI, FIG. 2 is a block diagram showing peripheral units connected to the tone generator LSI, and FIG. 3 is a block diagram showing in more detail the configuration of the tone generator core provided in the tone generator LSI. FIG. 4 is a block diagram showing in more detail the configuration of a sound source unit shown in FIG. 3.
[0012]
As shown in FIG. 2, the tone generator LSI 10 is used as a tone generator for an electronic musical instrument or the like by being connected to an operator 1, a display 2, a sound system 3, and an external memory 4, and an audio signal is transmitted according to an instruction from the operator 1. It is a device that generates and sends sound to the sound system 3 to generate sound, or generates a display signal and sends it to the display device 2 for display. The tone generator LSI 10 also has storage means inside as shown in FIG. 1. However, the tone generator LSI 10 is also connected to an external memory 4 as external storage means, and reads / writes data from / to the data as necessary. I do. Note that a dial, a button, a keyboard or the like can be used as the operation element 1, and a light emitting diode or a liquid crystal display can be used as the display 2.
[0013]
1, the tone generator LSI 10 includes a CPU 11, an input / output port 12, a timer 13, an interrupt controller 14, an external bus arbitration unit 15, a built-in ROM arbitration unit 16, a built-in SRAM (Static RAM) arbitration unit 17, A sound source core 30 is provided, and these are connected by a CPU bus 21. Further, as a storage means, an internal ROM 18 connected to the internal ROM arbitration unit 16 and an internal SRAM 19 connected to the internal SRAM arbitration unit 17 are provided, and an external bus arbitration unit 15, an internal ROM arbitration unit 16, and an internal SRAM arbitration unit 17 are provided. The sound source unit 22 is connected to the sound source unit 32 of the sound source core 30 by a sound source bus 22 different from the CPU bus 21. Further, the built-in SRAM arbitration unit 17 is connected to the DSP unit (waveform processing unit) 33 of the sound source core 30 by the DSP bus 23.
[0014]
The CPU 11 reads a program stored in the built-in ROM 18, built-in SRAM 19 and external memory 4, and executes the program using an appropriate storage means as a work memory, thereby controlling the operation of the tone generator LSI 10. It is. Then, a control operation is performed in accordance with an operation signal from the operation element 1, and a display signal is sent to the display device 2 for display.
The input / output port 12 is a parallel port or a serial port serving as an interface for connecting the operation element 1 or the display device 2 to the sound source LSI 10. In addition, communication with other devices via the input / output port 12 according to the MIDI (Musical Instruments Digital Interface) standard can be performed.
The timer 13 is an operation clock generating means for supplying an operation clock and timing signal necessary for each circuit in the tone generator LSI 10.
The interrupt controller 14 is a unit that controls the generation of interrupt processing in the CPU 11.
[0015]
The external bus arbitration unit 15 is connected to an external ROM 25, an external SRAM 26, and an external DRAM (Dynamic RAM) 27 constituting the external memory 4 via the external memory bus 24, and the CPU 11 and the sound source core 30 access these memories. And arbitration means for arbitrating when access requests conflict. The operation and function of the external bus arbitration unit 15 will be described in detail later.
The built-in ROM arbitration unit 16 is an arbitration unit that is connected to the built-in ROM 18, mediates access from the CPU 11 and the sound source unit 32 to the built-in ROM 18, and performs arbitration when access requests conflict. The built-in SRAM arbitration unit 17 is an arbitration unit that connects to the built-in SRAM 19 and mediates access to the built-in SRAM 19 from the CPU 11, the sound source unit 32, and the DSP unit 33, and arbitrates when access requests conflict. The operation and function of these arbitration units will also be described later.
[0016]
The internal ROM 18 and the internal SRAM 19 constitute storage means together with the external external ROM 25, the external SRAM 26, and the external DRAM 27, and waveform data used for sound signal generation processing in the sound source core 30, programs and parameters used for control processing by the CPU 11. Etc. or function as a work memory for the CPU 11. The CPU 11 and the sound source unit 32 can access these storage units by arbitrarily selecting them, and the DSP unit 33 can access only the built-in SRAM arbitration unit 19.
[0017]
The tone generator core 30 includes a tone generator control unit 31, a tone generator unit 32, and a DSP unit 33, reads waveform data stored in a memory such as the built-in ROM 18 and the built-in SRAM 19, and generates an audio signal, and performs necessary processing. This is a sound source unit that performs and outputs to the sound system 3. As will be described later, the sound source core 30 can generate an audio signal for each channel and generate an audio signal of 32 channels.
FIG. 3 shows the configuration of the sound source core 30 in more detail.
In the sound source core 30, the sound source control unit 31 controls the entire operation. That is, sound signal generation in the sound source unit 32, effect processing content in the DSP unit 33, control of presence / absence of sound generation of each channel, and the like are performed.
[0018]
The sound source unit 32 reads waveform data, which is sound data stored in the memory via the sound source bus, performs interpolation processing, and generates sound signals in each sampling period for each channel. Then, the audio signals are sequentially transferred to the mixer unit 34, and mixing processing is performed in the mixer unit 34. Note that audio signals can be generated in parallel for a maximum of 32 channels, and audio signals for a maximum of 32 channels are generated in a time division manner for each sampling period of 1/444100 seconds (see FIG. 8). A period for generating an audio signal for one channel is a channel slot, and one channel slot is a period for 24 clocks of a master clock which is an operation clock with a period of 29.5 nanoseconds.
[0019]
Further, in the mixing process, the audio signal of the channel to which the effect needs to be applied is transferred to the DSP unit 33 and the effect process is performed. Then, the audio signal after the effect processing is returned to the mixer unit 34 and added to the audio signal of the channel that did not require the effect processing to perform the mixing processing. Here, the DSP unit 33 can access the built-in SRAM 19 via the DSP bus 23 and the built-in SRAM arbitration unit 17 and use it as a delay memory.
The audio signal mixed in the mixer unit 34 is converted into an analog signal by the D / A conversion unit 35 and transmitted to the sound system 3 to generate sound based on the audio signal.
[0020]
Next, waveform data reading and interpolation processing in the sound source unit 32 of the sound source core 30 will be described in more detail. FIG. 4 shows the configuration of the sound source unit 32 in more detail.
Reading of waveform data by the sound source unit 32 is performed by issuing a read request for the read address stored in the address register 37, and this read address is generated by the address generation unit 36 of the sound source control unit 31. This address generator 36 is an address generator.
[0021]
Here, the built-in ROM 18, built-in SRAM 19 or external memory 4 stores waveform data for each predetermined sampling period at an address represented by an integer. However, in order to output a sound having the same waveform at a pitch different from that at the time of sampling, for example, in order to obtain a frequency that is 1.5 times, the waveform at a position advanced by 1.5 times the sampling period for each sampling period Waveform data at a point in time during the sampling period is also required, such as the need to sound based on the data. Therefore, in the tone generator core 30, address information of necessary waveform data is designated by an integer part and a decimal part, a readout address is designated based on the integer part, and necessary waveform data is read, and on the basis of the decimal part. By interpolating the read data, waveform data at a time point during the sampling period can be obtained.
[0022]
At this time, the interpolation is performed using the waveform data read from the address of the integer part value and the integer part value + 1. Therefore, if an interpolation buffer is provided and the waveform data read in the previous sampling period is stored, if the integer part of the address information does not change, interpolation is performed using the stored waveform data. The waveform data can be newly read out only when the integer part changes. Even when a new reading is performed, if the value of the integer part is increased by 1 compared to the previous sampling period, it is only necessary to newly read one waveform data from the address of the integer part value + 1. Only in the case of increase, it is only necessary to read two waveform data from the address of the integer part value and the integer part value + 1. That is, the number of waveform data to be read is from 0 to 2, and the same number of read addresses are generated.
[0023]
The address generation unit 36 generates the above address information by accumulating F number, which is a numerical value corresponding to the ratio between the pitch designated for sound generation and the pitch of the waveform data, for each sampling period. A necessary number of read addresses are generated according to the integer part as described above and stored in the address register 37. Then, the sound source unit 32 functioning as a read request unit issues a read request to the address stored in the address register 37. Each memory is mapped to a predetermined address area on the memory map, and a read request designating an address becomes an access request to the memory corresponding to the address.
[0024]
When this request is granted to the arbitration unit corresponding to the memory as will be described in detail later, the waveform data stored in the read address is read and returned to the sound source unit 32, and this is stored in the read data register 38. Remember. Then, the waveform data corresponding to the address information is transferred to the interpolation unit 39, and interpolation processing is performed on the waveform data read (or accumulated in the buffer) based on the decimal part of the address information. Can be generated. The interpolation buffer is provided in the interpolation unit 39, and when newly read waveform data is stored therein, the already stored data is erased from the oldest data.
Then, the waveform data generated by the interpolation is further multiplied by a volume envelope waveform indicating a temporal change in volume from the rise to the fall of the sound in an envelope control circuit (not shown). The generation is completed, and the audio signal is transferred to the mixer unit 34 and used for mixing processing.
The sound source core 30 can read the waveform data from the memory and generate an audio signal for each channel based on the waveform data by the processing as described above.
[0025]
Next, the configuration and operation of each arbitration unit provided in the tone generator LSI will be described with reference to FIGS. 5 to 7 are block diagrams showing in more detail the configurations of the external bus arbitration unit 15, the built-in ROM arbitration unit 16, and the built-in SRAM arbitration unit 17 shown in FIG. 1, respectively, and FIG. 8 shows the operation of access arbitration by each arbitration unit. It is a figure for demonstrating.
First, the external bus arbitration unit 15 will be described.
As shown in FIG. 5, the external bus arbitration unit 15 includes a selection circuit 41, an arbitration circuit 42, decode units 43 and 44, an area determination circuit 45, a timing generation circuit 46, and an access circuit 47.
[0026]
The selection circuit 41 is connected to the CPU bus 21 and the sound source bus 22, receives an access request from the CPU 11 and the sound source unit 32, and passes the access request permitted by the arbitration circuit 42 to the access circuit 47 in accordance with an instruction from the arbitration circuit 42. Circuit. Since the sound source unit 32 does not perform writing, the access request from the sound source unit 32 is always a read request.
[0027]
The arbitration circuit 42 receives the results of decoding by the decoding units 43 and 44, respectively, of the addresses related to the access requests sent by the CPU bus 21 and the sound source bus 22, and determines the access request to be permitted based on the results. This is a circuit for instructing the selection circuit 41. How to determine an access request to be permitted will be described later. In the decoding by the decoding units 43 and 44, addresses relating to access requests sent from the CPU bus 21 and the sound source bus 22, respectively, are compared with the memory map to determine which memory the access request is for. It is. Alternatively, it may be determined whether the access request is for any memory connected to the external memory bus 24.
Here, for simplification, the CPU 11 and the sound source unit 32 can access a memory space of the same size, and the external memory 4, the internal ROM 18, and the internal SRAM 19 are arranged in the same area of each memory space. And
Further, the arbitration circuit 42 transmits, as a control signal, a CPU_WAIT signal for causing the CPU 11 to wait until the read operation for the access request is completed, or TG_ACK for transmitting the completion of the read operation to the sound source unit 32. Also send a signal.
[0028]
The area determination circuit 45 is a circuit for determining which of the memories connected to the external memory bus 24 the access request passed through the selection circuit 41 is. The M_AREA signal is used as a determination criterion for each memory and address. Enter the information about the correspondence with.
The timing generation circuit 46 is a circuit that generates a timing signal for controlling the timing of an address, data, a control signal, and the like when accessing the external memory 4 and supplies the timing signal to the access circuit 47. Here, the control signal is, for example, an OE signal that permits output or a WE signal that instructs writing if the memory to be accessed is an SRAM, and a synchronous operation if it is an SDRAM (Synchronous Dynamic RAM) or the like. Clock signal, CS signal, RAS signal, CAS signal, WE signal, and the like.
In the tone generator LSI 10, as shown in FIG. 1, each memory connected to the external memory bus 24 has different operation speeds, so that this signal can be generated at different timings depending on the memory to be accessed. It is a thing. The M_SPD signal is information indicating the type and access period of each memory, and a different timing signal is generated according to this signal.
[0029]
The access circuit 47 is a circuit that generates an address, various control signals, and the like at a timing controlled by the timing signal based on the access request supplied from the selection circuit 41 and accesses the external memory 4 via the external memory bus 24. is there. In the case of reading, the data read according to the timing signal from the timing generation circuit 46 is stored, and the data is returned to the CPU 11 or the sound source unit 32 that has made a read request via the selection circuit 41. Further, based on the timing signal from the timing generation circuit 46, the SIG1 signal is generated and transmitted to the arbitration circuit 42 at a high level when a new access is possible at the next timing and at a low level otherwise. Then, the timing when the next access can be permitted is transmitted.
[0030]
Here, the determination method of the access request permitted in the arbitration circuit 42 will be described.
First, the arbitration circuit 42 determines whether to permit an access request at every clock timing of the master clock shown in FIG. If the access request is not for any memory connected to the external memory bus 24, the request is not permitted. If the SIG1 signal is not at the high level at the previous timing, that is, if the external memory bus 24 is in use, any access request is not permitted.
[0031]
On the other hand, if the external memory bus 24 is not in use and there is only one access request (from either the CPU 11 or the sound source unit 32) to any memory connected to the external memory bus 24, the request is permitted. If there are two (from both the CPU 11 and the sound source unit 32), the request from the sound source unit 32 is preferentially permitted. This is because the memory connected to the external memory bus 24 has a low operating speed, so that the waveform data required by the sound source unit 32 can be reliably read into the channel slot from the sound source unit 32. This is because it is necessary to increase the priority of access.
Further, when viewed for each channel slot, the CPU 11 makes an access request regardless of the channel slot, but the sound source unit 32 makes an access request at the start of the channel slot (if data reading is necessary). Therefore, when the arbitration circuit 42 arbitrates these access requests, the result is as shown in FIG.
[0032]
That is, at the start of each channel slot, if there is no access to the memory by the CPU 11 continuing from the previous channel slot, even if there is an access request from the CPU 11 simultaneously with the access request from the sound source unit 32, the sound source The access request is granted immediately with priority given to the unit 32. On the other hand, when there is an access to the memory by the CPU 11 continuing from the immediately preceding channel slot, a new access cannot be permitted, so an access request from the sound source unit 32 is permitted after the access is completed. Also in this case, even if there is a next access request from the CPU 11 immediately after the access by the CPU 11, the access request from the sound source unit 32 is preferentially permitted.
As described above, the access request from the sound source unit 32 is 0 to 2 times per channel slot. However, even when there is a second access request, the access request from the sound source unit 32 is also preferentially permitted. The same applies to the case where the CPU 11 has made an access request before the access request of the sound source unit 32.
The external bus arbitration unit 15 that performs such arbitration serves as a first arbitration unit.
[0033]
When such an arbitration operation is performed, if the period required for one memory access is a period of 6 clocks, the sound source section is the 12th clock of the channel slot at the earliest case and the 17th clock at the latest. Since the waveform data required by 32 can be read, the generation of the audio signal in the sound source unit 32 is not delayed.
On the other hand, one channel slot is divided into base clocks shorter than the access period of the fastest memory, and even a slow memory that requires a period of multiple clocks per access is accessed at each base clock timing. Since it is determined whether or not it is possible, the access period from the CPU 11 and the sound source unit 32 to each memory can be closely packed, and the operation can be performed at high speed.
[0034]
Also, access across channel slots is possible, and even when the sound source unit 32 is always prioritized over the CPU 11, access from the CPU 11 is permitted just before the end of the channel slot and an access request from the sound source unit 32 is accessed. Control that allows the user to wait until the process is completed can be performed without setting complicated conditions. Therefore, the processing load can be reduced by reducing the waiting time of the CPU 11 with a simple control circuit.
In the case of the example shown in FIG. 8, even if the access request from the CPU 11 is permitted once before the second access of the sound source unit 32 as shown in parentheses, the second access is 23 clocks. Since the process is completed by eye, such control may be performed. However, this is an example of a memory that takes 6 clocks to access, and when a memory that takes 7 clocks or more to access is assumed to be connected, the tone generator 32 is always prioritized over the CPU 11 as in this embodiment. I have to let it.
[0035]
Next, the built-in ROM arbitration unit 16 will be described.
The built-in ROM arbitration unit 16 includes a selection circuit 51, an arbitration circuit 52, decode units 53 and 54, a timing generation circuit 56, and an access circuit 57, as shown in FIG. Since these elements generally have the same functions as the corresponding elements of the external bus arbitration unit 15, the description of the same parts will be omitted or simplified.
Similar to the selection circuit 41, the selection circuit 51 is a circuit that passes the access request permitted by the arbitration circuit 52 to the access circuit 57.
[0036]
As in the arbitration circuit 42, the arbitration circuit 52 receives the results decoded by the decoding units 53 and 54, determines an access request to be permitted based on the results, and instructs the selection circuit 51, or sends various control signals. It is a circuit that transmits. How to determine an access request to be permitted will be described later. In the decoding by the decoding units 53 and 54, addresses relating to access requests sent from the CPU bus 21 and the sound source bus 22, respectively, are compared with the memory map, and it is determined whether or not this is an access request for the built-in ROM 18. To do.
[0037]
Similar to the timing generation circuit 46, the timing generation circuit 56 is a circuit that generates a timing signal for controlling the timing of the address, data, control signal, and the like when accessing the built-in ROM 18. Only the ROM 18 can issue only timing signals for accessing the built-in ROM 18.
Similar to the access circuit 47, the access circuit 57 accesses the built-in ROM 18 at the timing controlled by the timing signal based on the access request supplied from the selection circuit 51, stores the read data in the case of reading, and selects it. This circuit returns the data to the read request source via the circuit 51. Further, the SIG2 signal having the same meaning as the SIG1 signal is generated and transmitted to the arbitration circuit 52.
[0038]
Here, a method for determining an access request to be permitted in the arbitration circuit 52 will be described.
First, the arbitration circuit 52 also determines whether to permit an access request at every clock timing of the master clock shown in FIG. If the access request is not for the internal ROM 18, the request is not permitted. If the SIG2 signal is not at the high level at the previous timing, that is, if the built-in ROM 18 is in use, any access request is not permitted.
On the other hand, if the built-in ROM 18 is not in use and there is only one access request to the built-in ROM 18, the request is permitted. If there are two continuous access requests, the internal ROM 18 is not used at every clock timing. These requests are allowed alternately. That is, for example, the sound source unit 32 is permitted when permission is first given in the channel slot, and the CPU 11 is permitted when permission is allowed next. However, when one access request disappears in the middle, the other access request is permitted regardless of the order.
[0039]
When the arbitration circuit 52 arbitrates an access request for the built-in ROM 18, the result is as shown in FIG.
That is, when an access request is first permitted in each channel slot, even if there is an access request from the CPU 11 at the same time as an access request from the sound source unit 32, the access request is immediately granted with priority given to the sound source unit 32. To do. Of course, if the CPU 11 continues to access the memory from the immediately preceding channel slot, a new access cannot be made, and neither access request is permitted until the access is completed.
When the access permitted first is completed, the access request from the CPU 11 is preferentially permitted. Then, the access request from the sound source unit 32 is preferentially permitted. Here, since the access request from the sound source unit 32 is a maximum of two times per channel slot, the access request from the CPU 11 is permitted thereafter.
[0040]
Since the built-in ROM 18 has a relatively high operating speed, all waveform data required by the sound source unit 32 can be reliably read into the channel slot without increasing the priority of access from the sound source unit 32. Therefore, priority is given to the access request from the CPU 11 to some extent so as to reduce the frequency of waiting the access request from the CPU 11 and waiting the CPU 11. Such control can be performed very easily, and even when the priority is adjusted between the CPU 11 and the sound source unit 32, the arbitration circuit 52 can be configured with a simple logic circuit.
In the above-described arbitration, an access request from the CPU 11 may be permitted first, not limited to once, but a predetermined number of times determined independently, such as three times for the CPU 11 and once for the sound source unit 32. You may make it permit alternately. In this case, if the access from the CPU 11 is permitted more times than the access from the sound source unit 32, it is effective to reduce the frequency of waiting the CPU 11. The built-in ROM arbitration unit 16 that performs such arbitration serves as a second arbitration unit.
[0041]
Next, the built-in SRAM arbitration unit 17 will be described.
As shown in FIG. 7, the built-in SRAM arbitration unit 17 includes a selection circuit 61, an arbitration circuit 62, decode units 63 and 64, a timing generation circuit 66, and an access circuit 67. Since these elements generally have the same functions as the corresponding elements of the built-in ROM arbitration unit 16, the description of the same parts will be omitted or simplified.
Similar to the selection circuit 51, the selection circuit 61 is a circuit that passes the access request permitted by the arbitration circuit 62 to the access circuit 67. However, since the selection circuit 61 is also connected to the DSP bus 23 and accepts an access request from the DSP unit 33, this access request is also subject to arbitration by the arbitration circuit 62.
[0042]
Similar to the arbitration circuit 52, the arbitration circuit 62 is a circuit that instructs an access request to be permitted and transmits various control signals. However, in addition to the decoding results by the decoding units 63 and 64, the arbitration circuit 62 also receives an access request via the DSP bus 23, and refers to the request via the DSP bus 23 when determining an access request to be permitted. How to determine an access request to be permitted will be described later. In the decoding by the decoding units 63 and 64, the addresses related to the access requests sent from the CPU bus 21 and the sound source bus 22 are compared with the memory map, and it is determined whether or not this is an access request for the built-in SRAM 19. To do. Since the access request via the DSP bus 23 is always an access request to the built-in SRAM 19, a decoder for making such a determination is unnecessary and is not provided.
The timing generation circuit 66 is the same as the timing generation circuit 56 except that it generates a timing signal for accessing the internal SRAM 19 that can be accessed in one clock. The access circuit 67 is the same as the access circuit 57 except that it accesses the built-in SRAM 19 at the timing of the timing signal based on the access request from the selection circuit 61 and generates the SIG3 signal instead of the SIG2 signal.
[0043]
Here, a method for determining an access request to be permitted in the arbitration circuit 62 will be described.
First, the arbitration circuit 62 also determines whether to permit an access request at every clock timing. If the access request is not for the built-in SRAM 19, the access request is not permitted. Here, since the access to the built-in SRAM 19 is completed in a period of one clock, the SIG3 signal is always at the high level, and the built-in SRAM 19 is in use and the access request cannot be permitted.
On the other hand, if there is only one access request to the built-in SRAM 19, that request is permitted, and if there are two access requests continuously, these requests are permitted alternately at each clock timing. However, for the DSP unit 33, if the access cannot be executed at a fixed timing, the effect processing is hindered. Therefore, when there is an access request from the DSP unit 33, the DSP unit 33 is granted with the highest priority.
[0044]
When the arbitration circuit 62 arbitrates an access request to the built-in SRAM 19, the result is as shown in FIG.
Although it is almost the same as in the case of the built-in ROM 18, access is completed in a period of one clock, so that access is not continued from the immediately preceding channel slot. Note that the access request from the DSP unit 33 is not required when the DSP unit 33 does not need it, but if there is, it is the 12th clock and the 24th clock of each channel slot, and this request is granted with the highest priority.
Since the built-in SRAM 19 also has a high operating speed, priority is given to access requests from the CPU 11 to some extent. Such control can be performed very easily, and even when the priority is adjusted between the CPU 11 and the sound source unit 32, the arbitration circuit 52 can be configured with a simple circuit. The built-in SRAM arbitration unit 17 that performs such arbitration also serves as a second arbitration unit.
[0045]
Next, access arbitration to the storage means in the tone generator LSI will be further described with reference to specific examples shown in FIGS. 9 to 11 are diagrams showing different specific examples of the access arbitration.
First, in the example shown in FIG. 9, the CPU 11 makes an access request to the external ROM 25 before the start of the channel slot indicated by the arrow. At this time, the external memory bus 24 is not used and there is no access request from the sound source unit 32 to the external memory 4, so the external bus arbitration unit 15 permits the access request. Then, the CPU_WAIT signal is set to the low level so that the CPU 11 waits until the reading is completed.
At this time, the area determination circuit 45 of the external bus arbitration unit 15 determines that the access request destination is the external ROM 25, and the timing generation circuit 46 generates a timing signal for 6 clock hours for accessing the external ROM 25. Further, the access circuit 47 sets the SIG1 signal to a low level to indicate that a new access cannot be permitted.
[0046]
On the other hand, the sound source unit (TG) 32 makes an access request to the external DRAM 27 at the start of the channel slot, but the CPU 11 continues to access from the previous channel slot, and the external memory bus 24 is in use. The access request is not permitted until the access of the CPU 11 is completed. Thereafter, when it is time to end the access of the CPU 11, the SIG1 signal is set to HIGH, and the arbitration circuit 42 is notified that the access can be permitted at the next clock timing.
[0047]
In this example, the next access request from the CPU 11 to the external ROM 25 is made at the next timing. This request is a request to use the same external memory bus 24, although the access request from the sound source unit 32 is different from the target memory, and thus conflicts with the access request from the sound source unit 32. However, since the external bus arbitration unit 15 gives priority to the request from the sound source unit 32, the request from the sound source unit is permitted next time.
After the second access by the sound source unit 32, the access request from the CPU 11 is no longer competing with the other, so that the request from the CPU 11 is permitted. Thereafter, the CPU 11 issues an access request to the built-in ROM 18, but this is also not in conflict with others, so that it is permitted by the built-in ROM arbitration unit 16.
[0048]
In the example shown in FIG. 10, the CPU 11 and the sound source unit 32 simultaneously request access to the built-in SRAM 19 at the start of the channel slot indicated by the arrow (indicated by “S”). Since these requests conflict, the built-in SRAM arbitration unit 17 performs arbitration. Then, the request from the CPU 11 and the request from the sound source unit 32 are alternately permitted, but here, unlike the example shown in FIG. 8, the request from the CPU 11 is permitted first. Therefore, first, a request from the CPU 11 is permitted (indicated by “C”), and a new request from the CPU 11 and a request from the sound source unit 32 compete with each other at the next timing. Allow the request (indicated by “T”). Thereafter, the request from the CPU 11 and the request from the sound source unit 32 compete with each other until the fourth clock, so these are alternately permitted, and the request from the sound source unit 32 is eliminated at the fifth clock, so the request from the CPU 11 is permitted. To do.
Since there is no access request from anywhere in the seventh to tenth clocks, no arbitration is required.
[0049]
Then, from the 11th clock, the CPU 11 makes an access request to the built-in SRAM 19 four times. During this time, there is no access request from the sound source unit 32, but there is an access request from the DSP unit 33 to the built-in SRAM 19 at the 12th clock (not shown), and this request is granted with the highest priority as described above. (Indicated by “D”), the access request from the CPU 11 is not permitted at the 12th clock and is waited for a period of one clock.
Thereafter, the CPU 11 makes two access requests to the external SRAM 26, but since this request does not compete with the sound source unit 32, it is permitted as it is. The clock required for one access is 5 clocks, and the second access extends over the next channel slot, but there is no problem in terms of control. The DSP unit 33 makes an access request to the built-in SRAM 19 at the 24th clock of the channel slot indicated by the arrow, and the sound source unit 32 makes an access request to the built-in SRAM 19 at the first clock of the next channel slot. Since the external memory bus 24 is not used, these access requests do not conflict with the access requests made by the CPU 11 and can be separately granted.
[0050]
In the example shown in FIG. 11, the CPU 11 makes an access request to the built-in SRAM 19 continuously before the start of the channel slot indicated by the arrow, and the sound source unit 32 requests access to the external SRAM 26 at the start of the channel slot. It is carried out. However, as in the case described above, these access requests do not compete with each other, and are thus independently permitted by the built-in SRAM arbitration unit 17 and the external bus arbitration unit 15.
Thereafter, the CPU 11 makes an access request to the external SRAM 26 at the fifth clock, but since the external memory bus 24 is in use at this point, the external bus arbitration unit 15 does not wait until the next clock when the sound source unit 32 is accessed. Do not allow this request.
[0051]
However, at the sixth clock, there is a second access request from the tone generator 32 to the external SRAM 26, and this conflicts with a request from the CPU 11 from the fifth clock. Since the external bus arbitration unit 15 gives priority to the request from the sound source unit 32, this is also permitted next time, and the request from the CPU 11 is further waited. Since the conflict is resolved after the second access from the sound source unit 32 is completed, it is permitted. Subsequent access requests from the CPU 11 do not conflict with other requests, and are allowed as they are.
[0052]
In this tone generator LSI 10, the arbitration units 15, 16, and 17 detect access requests to the respective memories, and perform the arbitration as described above when a conflict occurs, whereby the tone generator unit 32 is required in each channel slot. As a result, it is possible to reduce the period of waiting for access from the CPU 11, improve the access efficiency to the memory, and reduce the load on the CPU 11. If different arbitrations are performed according to the operation speed of the memory, each arbitration can be performed with a simple circuit, and the priority of the sound source unit 32 is set according to the operation speed. The load on the CPU 11 can be further reduced by adjustment. Such arbitration is particularly effective when a plurality of memories having a difference of two times or more in operating speed is used.
[0053]
Furthermore, at least for a slow-operating memory, an operation clock is set such that several access clock periods are required for one access to the memory, rather than providing several fixed access periods in one channel slot. Is set so that the access to the memory can be started from any clock timing of the operation clock, the access timing can be set flexibly to improve the access efficiency to the memory. Even when a plurality of memories having different operation speeds are used, access control and arbitration processing matching the operation speeds of the respective memories can be performed without performing particularly complicated control.
[0054]
In the embodiment described above, one channel slot has 24 clocks, but the number of clocks in one channel slot may be more or less. Further, although the CPU 11 and the sound source unit 32 have the same memory map, the CPU 11 and the sound source unit 32 may arrange the external memory 4, the built-in ROM 18, and the built-in SRAM 19 at different positions in each memory space.
[0055]
【The invention's effect】
As described above, according to the present invention, the sound source unit that generates the audio signal based on the audio data, the control unit that controls the operation of the apparatus, and the same storage means from both the sound source unit and the control unit In a sound source device having means for accessing the storage means, the access request to the storage means from the sound source section and the control section is appropriately arbitrated by simple processing to improve the access efficiency to the storage means and reduce the load on the control section can do. Further, even when a plurality of memories having different access speeds are used, appropriate arbitration can be performed with simple processing.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a configuration of a tone generator LSI that is an embodiment of a tone generator of the present invention;
FIG. 2 is a block diagram showing peripheral units connected to the sound source LSI.
FIG. 3 is a block diagram showing in more detail the configuration of a sound source core provided in the sound source LSI.
4 is a block diagram showing in more detail the configuration of a sound source unit shown in FIG. 3. FIG.
5 is a block diagram showing in more detail the configuration of an external bus arbitration unit shown in FIG. 1. FIG.
6 is a block diagram showing in more detail the configuration of a built-in ROM arbitration unit shown in FIG. 1. FIG.
7 is a block diagram showing in more detail the configuration of a built-in SRAM arbitration unit shown in FIG. 1; FIG.
8 is a diagram for explaining an operation of access arbitration by each arbitration unit illustrated in FIGS. 5 to 7; FIG.
FIG. 9 is a diagram illustrating a specific example of access arbitration by each arbitration unit illustrated in FIGS. 5 to 7;
FIG. 10 is a diagram showing another example thereof.
FIG. 11 is a diagram showing still another example thereof.
[Explanation of symbols]
DESCRIPTION OF SYMBOLS 1 ... Control, 2 ... Display, 3 ... Sound system, 4 ... External memory, 10 ... Sound source LSI, 11 ... CPU, 12 ... I / O port, 13 ... Timer, 14 ... Interrupt controller, 15 ... External bus arbitration , 16 ... Built-in ROM arbitration unit, 17 ... Built-in SRAM arbitration unit, 18 ... Built-in ROM, 19 ... Built-in SRAM, 21 ... CPU bus, 22 ... Sound source bus, 23 ... DSP bus, 24 ... External memory bus, 25 ... External ROM, 26 ... external SRAM, 27 ... external DRAM, 30 ... sound source core, 31 ... sound source control unit, 32 ... sound source unit, 33 ... DSP unit, 34 ... mixer unit, 35 ... D / A conversion unit, 36 ... address generation , 37 ... Address register, 38 ... Read data register, 39 ... Interpolator, 41, 51, 61 ... Selection circuit, 42, 52, 62 ... Arbitration circuit, 43, 44, 53, 54, 63, 4 ... decoding unit, 45 ... area determining circuit, 46, 56, 66 ... timing generator, 47,57,67 ... access circuit

Claims (3)

音声データに基づいて音声信号を生成する音源部と、装置の動作を制御する制御部と、前記音源部と前記制御部の双方から同じ記憶手段にアクセスする手段とを有する音源装置であって、
前記記憶手段に対する前記音源部からのアクセス要求が発生したとき、前記記憶手段に対する前記制御部からのアクセス要求が発生していなければ、前記音源部に対して連続したアクセス要求を許可し、前記記憶手段に対する前記制御部からのアクセス要求が発生していれば、前記音源部からのアクセス要求と前記制御部からのアクセス要求とをそれぞれ独立に定めた所定回数ずつ交互に許可するアクセス調停手段を設けたことを特徴とする音源装置。
A sound source device including a sound source unit that generates an audio signal based on audio data, a control unit that controls operation of the device, and a unit that accesses the same storage unit from both the sound source unit and the control unit,
When an access request from the sound source unit to the storage unit is generated, if an access request from the control unit to the storage unit is not generated, a continuous access request is permitted to the sound source unit, and the storage If there is an access request from the control unit to the access means, an access arbitration unit is provided that alternately allows the access request from the sound source unit and the access request from the control unit to be alternately determined a predetermined number of times. A sound source device characterized by that.
音声データに基づいて音声信号を生成する音源部と、装置の動作を制御する制御部と、前記音源部と前記制御部の双方から同じ記憶手段にアクセスする手段とを有する音源装置であって、
前記記憶手段は、第1のメモリと該第1のメモリよりアクセス速度の速い第2のメモリとを備え、
前記音源部から前記第1のメモリへのアクセス要求と前記制御部から前記第1のメモリへのアクセス要求とが競合した場合に、前記音源部からのアクセス要求を優先させて前記音源部からのアクセス要求と前記制御部からのアクセス要求を調停する第1の調停手段と、
前記音源部から前記第2のメモリへのアクセス要求と前記制御部から前記第2のメモリへのアクセス要求とが競合した場合に、前記音源部からのアクセス要求と前記制御部からのアクセス要求とをそれぞれ独立に定めた所定回数ずつ交互に許可するように前記音源部からのアクセス要求と前記制御部からのアクセス要求を調停する第2の調停手段を設けたことを特徴とする音源装置。
A sound source device including a sound source unit that generates an audio signal based on audio data, a control unit that controls operation of the device, and a unit that accesses the same storage unit from both the sound source unit and the control unit,
The storage means includes a first memory and a second memory having a higher access speed than the first memory,
When a request for access to the first memory from the sound source unit and a request for access to the first memory from the control unit compete, the access request from the sound source unit is given priority and is sent from the sound source unit. First arbitration means for arbitrating an access request and an access request from the control unit;
When an access request from the sound source unit to the second memory conflicts with an access request from the control unit to the second memory, an access request from the sound source unit and an access request from the control unit And a second arbitration unit that arbitrates the access request from the sound source unit and the access request from the control unit so as to alternately permit the predetermined number of times determined independently of each other .
音声データに基づいてチャンネル毎に音声信号を生成する音源部と、装置の動作を制御する制御部と、前記音源部と前記制御部の双方から同じ記憶手段にアクセスする手段とを有する音源装置であって、
前記音源部が1チャンネル分の音声信号生成に用いる音声データの読み出しを行うべき期間を、動作クロックの所定クロック数単位でチャンネルスロットとして設定する手段を設け、
前記記憶手段は1回のアクセスに動作クロックの複数クロック分の期間を要するメモリを有し、
前記音源部に、各チャンネルスロットにおいて、あらかじめ生成しておいた読み出しアドレスからの読み出し要求を前記メモリに対して行う読出要求手段を設け、
前記動作クロックの各クロックタイミング毎に前記メモリへのアクセスの許可/不許可を決定し、各チャンネルスロットの開始時に、直前のチャンネルスロットから続いている前記制御部による前記メモリへのアクセスがない場合には直ちに前記読出要求手段による読み出し要求を許可し、直前のチャンネルスロットから続いている前記制御部による前記メモリへのアクセスがある場合にはそのアクセスの終了後に前記読出要求手段による読み出し要求を許可するアクセス調停手段をさらに設けたことを特徴とする音源装置。
A sound source device having a sound source unit that generates an audio signal for each channel based on audio data, a control unit that controls operation of the device, and a unit that accesses the same storage unit from both the sound source unit and the control unit There,
Means for setting a period in which the sound source section should read audio data used to generate an audio signal for one channel as a channel slot in units of a predetermined number of clocks of an operation clock;
The storage means has a memory that requires a period of a plurality of operating clocks for one access,
The sound source unit is provided with a read request means for making a read request from a read address generated in advance in each channel slot to the memory,
When permission / non-permission of access to the memory is determined at each clock timing of the operation clock, and there is no access to the memory by the control unit continuing from the previous channel slot at the start of each channel slot Immediately permits a read request by the read request means, and if there is an access to the memory by the control unit continuing from the immediately preceding channel slot, permits the read request by the read request means after the access ends. A sound source device further comprising access arbitration means for performing
JP2002273966A 2002-09-19 2002-09-19 Sound generator Expired - Fee Related JP3722104B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2002273966A JP3722104B2 (en) 2002-09-19 2002-09-19 Sound generator

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2002273966A JP3722104B2 (en) 2002-09-19 2002-09-19 Sound generator

Publications (2)

Publication Number Publication Date
JP2004109686A JP2004109686A (en) 2004-04-08
JP3722104B2 true JP3722104B2 (en) 2005-11-30

Family

ID=32270584

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2002273966A Expired - Fee Related JP3722104B2 (en) 2002-09-19 2002-09-19 Sound generator

Country Status (1)

Country Link
JP (1) JP3722104B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011257456A (en) * 2010-06-04 2011-12-22 Panasonic Corp Musical sound reproduction device and musical sound reproduction method

Also Published As

Publication number Publication date
JP2004109686A (en) 2004-04-08

Similar Documents

Publication Publication Date Title
US7032046B2 (en) Resource management device for managing access from bus masters to shared resources
JP2005258867A (en) Resource managing apparatus
KR100395383B1 (en) Data transfer apparatus
JP3163984B2 (en) Music generator
JP3722104B2 (en) Sound generator
JP4902640B2 (en) Integrated circuit and integrated circuit system
US20110153892A1 (en) Access arbitration apparatus, integrated circuit device, electronic apparatus, access arbitration method, and program
JP3541112B2 (en) Bus arbitration system
US7734860B2 (en) Signal processor
US10061737B2 (en) Signal processing device, method of signal processing, storage medium, and electronic musical instrument
US20030204651A1 (en) Circuit for controlling sequential access to SDRAM
JP5229990B2 (en) 1-chip electronic musical tone generator
JP3791162B2 (en) Signal processing device
JPH10149311A (en) Memory controller
JP2775744B2 (en) Digital audible sound generator
JPH10177388A (en) Sound memory access control device
JP2004110852A (en) Bus arbitration system
WO2020066934A1 (en) Command control system, vehicle, command control method and program
JP3303420B2 (en) Memory access control device
JP2000172553A (en) Data processor
JP2002269028A (en) Adm controlled device
JP3910165B2 (en) High speed processor
JP2003241754A (en) Waveform processing device
JPH05128850A (en) Memory refresh controller
JP2003228546A (en) Control device for direct memory access

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20050526

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20050607

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20050727

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20050905

R150 Certificate of patent or registration of utility model

Ref document number: 3722104

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

S531 Written request for registration of change of domicile

Free format text: JAPANESE INTERMEDIATE CODE: R313532

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

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

Free format text: PAYMENT UNTIL: 20090922

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20100922

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20100922

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20110922

Year of fee payment: 6

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

Free format text: PAYMENT UNTIL: 20120922

Year of fee payment: 7

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

Free format text: PAYMENT UNTIL: 20130922

Year of fee payment: 8

LAPS Cancellation because of no payment of annual fees