JPS61163393A - Miscomputation preventing circuit for electronic cirucuit for electronic musical instrument - Google Patents
Miscomputation preventing circuit for electronic cirucuit for electronic musical instrumentInfo
- Publication number
- JPS61163393A JPS61163393A JP60004580A JP458085A JPS61163393A JP S61163393 A JPS61163393 A JP S61163393A JP 60004580 A JP60004580 A JP 60004580A JP 458085 A JP458085 A JP 458085A JP S61163393 A JPS61163393 A JP S61163393A
- Authority
- JP
- Japan
- Prior art keywords
- circuit
- digital filter
- digital
- output
- electronic
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 230000002265 prevention Effects 0.000 claims 2
- 230000000295 complement effect Effects 0.000 claims 1
- 238000010586 diagram Methods 0.000 description 6
- 102100031584 Cell division cycle-associated 7-like protein Human genes 0.000 description 2
- 101000777638 Homo sapiens Cell division cycle-associated 7-like protein Proteins 0.000 description 2
- 230000005540 biological transmission Effects 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 230000010355 oscillation Effects 0.000 description 1
- 102220076776 rs144141585 Human genes 0.000 description 1
Landscapes
- Electrophonic Musical Instruments (AREA)
Abstract
(57)【要約】本公報は電子出願前の出願データであるた
め要約のデータは記録されません。(57) [Summary] This bulletin contains application data before electronic filing, so abstract data is not recorded.
Description
【発明の詳細な説明】
〔産業上の利用分野〕
本発明は、デジタル信号処理される楽音データのデジタ
ル的なビット数制限に関し、デジタル演算される楽音デ
ータのオーバーフローを防止することをU的としている
。DETAILED DESCRIPTION OF THE INVENTION [Industrial Application Field] The present invention relates to digital bit number limitation of musical tone data subjected to digital signal processing, and aims to prevent overflow of musical tone data subjected to digital calculations. There is.
本発明は、デジタル信号処理される楽音データのデジタ
ル的なビット数制限に関し、デジタル演算される楽音デ
ータのオーバーフローを防止することを目的としている
。The present invention relates to a digital bit limit for musical tone data subjected to digital signal processing, and an object of the present invention is to prevent overflow of musical tone data subjected to digital calculations.
そのためにデジタルフィルタ21の出力にクリップ回路
を設け、デジタルフィルタ内で発生するデータのオーバ
ーフローを救済しようとするものである。さらに具体的
には加算回路21dの出力にクリップ回路を設けたもの
である。For this purpose, a clip circuit is provided at the output of the digital filter 21 to relieve data overflow occurring within the digital filter. More specifically, a clip circuit is provided at the output of the adder circuit 21d.
従来、第2図に示すような楽音信号発生装置が考案され
ている。この楽音信号発生装置の動作原理は、RAM2
1とデジタルフィルタ21(ここではローパスフィルタ
とする)から成り、この2つを直列に接続して楽音信号
を循環させて所定の波形を得るというものである。これ
はRAM20にあらかじめ高調波の多く含んだ楽音デー
タをゼットしておき、デジタルフィルタ21によってそ
の高調波成分を除々に削減していくという考え方であり
、弦楽器等の楽音を発生させるのに好適だといわれてい
る。Conventionally, a musical tone signal generating device as shown in FIG. 2 has been devised. The operating principle of this musical tone signal generator is that RAM2
1 and a digital filter 21 (herein referred to as a low-pass filter), these two are connected in series to circulate musical tone signals and obtain a predetermined waveform. This idea is to first store musical sound data containing many harmonics in the RAM 20, and then gradually reduce the harmonic components using the digital filter 21, which is suitable for generating musical sounds from stringed instruments, etc. It is said that.
ここで、デジタルフィルタ21で扱うデジタル信号は1
6ビット程度の精度を有しなければ雑音の多い楽音とな
り、その楽音の音質はデジタルデータのビット数に大き
く依存する。仮にこれを16ビットであるとすると、デ
ジタルフィルタ内でこの16ビットデータは乗算、及び
加算される必要がある。乗算回路21eLと21hは1
6ビット×16ビットの乗算を行い、その結果を16ビ
ットデータとして取り出す。これは、乗算回路21αと
21bの乗数を小数点以下の数字として扱ったと考え、
16ビット×16ビットの結果32ビットのうち、上位
16ビットを取り出すことにする。つまり、16ビット
×16ビットの演算の結果32ビットが得られるが、こ
の32ビットのうち上位16ビットだけを有効ビットと
して扱うということは、乗算回路の乗数を小数点以下の
数字として考えれば矛盾がない。Here, the digital signal handled by the digital filter 21 is 1
If it does not have an accuracy of about 6 bits, the musical tone will be noisy, and the quality of the musical tone will depend largely on the number of bits of the digital data. If this is 16 bits, this 16 bit data needs to be multiplied and added within the digital filter. The multiplier circuits 21eL and 21h are 1
A 6-bit x 16-bit multiplication is performed and the result is extracted as 16-bit data. This is because the multipliers of the multiplier circuits 21α and 21b are treated as numbers below the decimal point,
Of the 32 bits of the result of 16 bits x 16 bits, the upper 16 bits are extracted. In other words, 32 bits are obtained as a result of a 16-bit x 16-bit operation, but treating only the upper 16 bits of these 32 bits as valid bits is inconsistent if we consider the multiplier of the multiplication circuit as a number below the decimal point. do not have.
次に、乗算回路21αと21hの各々の出力(16ビッ
ト)を加算回路21Liで加算するが、16ビット+1
6ピツトの加算は結果として17ビットのデジタルデー
タとなる。この17ビットのデジタルデータをRAM2
0へ書き込む訳であるが、RAM20のビット数は並列
的に16ビットしか有していないため、ビットの重みづ
けの矛盾が発生する。つまり、RAM20から読み出さ
れた16ビットのデジタルデータは、デジタルフィルタ
21で演算されることにより17ビット構成となり、再
びRAM20に書き込む時には17ビットデータのうち
最下位ビットを1ビット分切シ捨てて書き込まなければ
ならない。これは、データを2で割った値となり、デジ
タルフィルタの動作が保証されなくなる。Next, the outputs (16 bits) of each of the multiplier circuits 21α and 21h are added by the adder circuit 21Li, but 16 bits + 1
The addition of 6 pits results in 17 bits of digital data. This 17-bit digital data is stored in RAM2.
However, since the RAM 20 has only 16 bits in parallel, a contradiction in bit weighting occurs. In other words, the 16-bit digital data read from the RAM 20 becomes a 17-bit configuration by being operated on by the digital filter 21, and when it is written to the RAM 20 again, the least significant bit of the 17-bit data is cut off by 1 bit and discarded. must be written. This becomes a value obtained by dividing the data by 2, and the operation of the digital filter is no longer guaranteed.
上記問題点を解決するために本発明は、第1図に示すよ
うにデジタルフィルタ21の出力にクリップ回路を設け
、デジタルフィルタ内で発生するデータのオーバーフロ
ーを救済しようとするものである。さらに具体的には加
算回路21dの出力にクリップ回路を設けたものである
。In order to solve the above problems, the present invention provides a clip circuit at the output of the digital filter 21 as shown in FIG. 1, and attempts to relieve data overflow occurring within the digital filter. More specifically, a clip circuit is provided at the output of the adder circuit 21d.
以下にこの発明の実施例を図面に基づいて説明する。第
1図は本発明のブロックであり、デジタルフィルタ21
の出力側にクリップ回路22を接続したものである。Embodiments of the present invention will be described below based on the drawings. FIG. 1 shows a block diagram of the present invention, in which a digital filter 21
A clip circuit 22 is connected to the output side of the circuit.
次に、クリップ回路周辺の詳細な図を第3図に示す。Next, a detailed diagram of the vicinity of the clip circuit is shown in FIG.
21dは加算回路でありフルアダーで構成され、22は
クリップ回路の詳細図である。22αと22dはノア回
路であり、22bはナンド回路であり、22Cはアンド
回路である。22e′から 422jはオア回路であり
22kから22pはイクスクルシプオアである。xOか
らXi5は加算回路21dの一方の入力系であり、YO
からY15 −は他の一方の入力系である。Reference numeral 21d denotes an adder circuit, which is composed of a full adder, and 22 is a detailed diagram of a clip circuit. 22α and 22d are NOR circuits, 22b is a NAND circuit, and 22C is an AND circuit. 22e' to 422j are OR circuits, and 22k to 22p are exclusive OR circuits. xO to Xi5 are one input system of the adder circuit 21d, and YO
to Y15 - is the other input system.
そして、このxO〜X15とYO〜Y15信号は2の捕
数表現をしたデジタルデータであり、x15とY15は
共に符号ビットである。つまりレベル1なら負の値であ
り、レベル0なら正の値である加算回路21dでのオー
バーフローは2種類ある。つまり、負同士の加算と正同
士の加算の場合である。Xδ値とYの値が共に正か負の
最大値に近い状態でそのオーバーフローが発生する。The xO to X15 and YO to Y15 signals are digital data expressed as a catch of 2, and both x15 and Y15 are sign bits. In other words, there are two types of overflow in the adder circuit 21d: a negative value if level 1, and a positive value if level 0. In other words, this is the case of addition between negatives and addition between positives. The overflow occurs when both the Xδ value and the Y value are close to their maximum positive or negative values.
第1表は正のオーバーフローした時の各ビットの状態で
ある。Table 1 shows the state of each bit when a positive overflow occurs.
第 1 表
Xの値とYの値に正の大きい値を入力した時、SO〜3
15の加算結果は符号ビットが負(S15=レベル1)
となり正確な演算結果が出ない。この時、ノア回路22
αの出力と加算回路21dの315出力が共にレベル1
となり、アン・ド回路22Cの出力には正のオーバーフ
ロー検出が表われ、オア回路22g〜22jとイクスク
ルシプオア22に〜22pの各ゲートを制御して結果的
に第1表に示すzO〜Z15の値となる。つまり、正の
最大値となる。When inputting large positive values for the values of X and Y in Table 1, SO~3
The sign bit of the addition result of 15 is negative (S15 = level 1)
Therefore, accurate calculation results cannot be obtained. At this time, the Noah circuit 22
Both the output of α and the 315 output of the adder circuit 21d are level 1.
Therefore, positive overflow detection appears in the output of the AND circuit 22C, and each gate of the OR circuits 22g to 22j and exclusive OR 22 to 22p is controlled, resulting in zO to shown in Table 1. It becomes the value of Z15. In other words, it is the maximum positive value.
次に第2表に負のオーバーフローの例を示す。Next, Table 2 shows an example of negative overflow.
負の値同士の加算では、結果が正の符号(S15=0)
となり不都合であるため、負の最大値に強制的にセット
する。これは、負同士の演算なのでナンド回路22bと
ノア回路22dが動作し、正のオーバー70一時と同様
にオア回路22g〜22jとイクスクルシプオア22に
〜22pを制御する。負同士の場合はイクスクルシプオ
ア22に〜22pが反転素子として動作する。When adding negative values, the result has a positive sign (S15=0)
Since this is inconvenient, it is forcibly set to the maximum negative value. Since this is an operation between negatives, the NAND circuit 22b and the NOR circuit 22d operate, and similarly to the positive over 70 time, the OR circuits 22g to 22j and the exclusive OR 22 to 22p are controlled. In the case of negative values, the exclusive OR 22 ~22p operates as an inverting element.
以上の動作を楽音波形として説明したものが第4図であ
る。FIG. 4 illustrates the above operation as a musical sound waveform.
第4図のXはピークを1.0とするサイン波であり、Y
はピークを0.75とするサイン波である。In Figure 4, X is a sine wave with a peak of 1.0, and Y
is a sine wave with a peak of 0.75.
2の波形はXの波形とYの波形を加算した時のもので、
斜線で示した部分がオーバーフローした部分である。こ
のオーバーフロー領域では、演算結果の符号と絶対値は
全く保証されず、デジタル信号処理が行えない。The waveform 2 is the one obtained by adding the X waveform and Y waveform,
The shaded area is the overflowed area. In this overflow region, the sign and absolute value of the calculation result are not guaranteed at all, and digital signal processing cannot be performed.
2の波形が本発明のクリップ回路を備えたものである。The waveform No. 2 is the one provided with the clip circuit of the present invention.
この発明は以上説明したように、デジタル信号処理技術
等によりて楽音を得るシステムにおいて動作の保証を行
える。つまり、楽音データを循環させるようなシステム
においては、その伝送径路内で演算のオーバーフローが
発生すると演算値そのものの保証ができない場合だけで
なく、最悪時にはデジタルフィルタそのものが発振して
しまう恐れがある。特に、オールパスフィルター等ノシ
ステムにおいては、フィルター内でデータを2回も循環
させている場合が多く、非常に発振しやすいものである
。本発明を用いれば少なくともフィルターの発振を防ぐ
ことができ、かつオーバーフローした場合には楽音デー
タがクリップしているため、デジタル処理にも関わらず
アナログ波形のクリップと等価に扱え、後の対処がやり
やすい。As described above, the present invention can guarantee the operation of a system that obtains musical tones using digital signal processing technology or the like. In other words, in a system that circulates musical tone data, if an overflow occurs in the transmission path, not only will the calculated value itself not be guaranteed, but in the worst case scenario, the digital filter itself may oscillate. In particular, in systems such as all-pass filters, data is often circulated twice within the filter, making it very easy to oscillate. By using the present invention, it is possible to at least prevent filter oscillation, and in the event of an overflow, the musical sound data is clipped, so it can be handled equivalently to clipping of an analog waveform even though it is digitally processed, making subsequent countermeasures easier. Cheap.
第1図は本発明にかかるブロック図であり、第2図は従
来のブロック図であり、第6図は本発明にかかるクリッ
プ回路であり、第4図は本発明のクリップ回路を動作さ
せた時の楽音波形図である2 0 ・・・ ・・・ ・
・・ RAM21・・・・・・・・・デジタルフィルタ
22・・・・・・・・・クリップ回路
21α、21h・・・・・・乗算回路
21C・・・・・・遅延回路
21d・・・・・・加算回路
以 上FIG. 1 is a block diagram according to the present invention, FIG. 2 is a conventional block diagram, FIG. 6 is a clip circuit according to the present invention, and FIG. 4 is a diagram showing the operation of the clip circuit according to the present invention. 20 ・・・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・
...RAM21...Digital filter 22...Clip circuit 21α, 21h...Multiplication circuit 21C...Delay circuit 21d... ... Adder circuit or more
Claims (2)
波形のデジタル信号処理を行うデジタルフィルタから成
り、前記メモリの出力が前記デジタルフィルタの入力端
へ接続され、該デジタルフィルタの出力が前記メモリの
入力端へ接続されるような循環接続をとり、該循環接続
の所定の位置より楽音信号を得るように構成した電子楽
器用電子回路において、前記デジタルフィルタはデジタ
ル乗算回路とデジタル加算回路より成り、前記デジタル
フィルタに加えられるデジタル信号のビット数が演算前
と演算後同一であるように構成し、かつ、前記デジタル
フィルタの出力値が該デジタルフィルタの入力ビット数
で表現できる値を超えた時に、前記デジタルフィルタの
出力側に設置されるデータクリップ回路を動作させ、楽
音データの誤演算(オーバーフロー)を防止することを
特徴とする電子楽器用電子回路の誤演算防止回路。(1) Consisting of a memory that stores at least musical tone data and a digital filter that performs digital signal processing of musical sound waveforms, the output of the memory is connected to the input terminal of the digital filter, and the output of the digital filter is connected to the input of the memory. In the electronic circuit for an electronic musical instrument, the digital filter is composed of a digital multiplier circuit and a digital adder circuit, and the digital filter is configured to have a circular connection such that it is connected to the end of the circuit, and to obtain a musical tone signal from a predetermined position of the circular connection. The number of bits of the digital signal applied to the digital filter is the same before and after the calculation, and when the output value of the digital filter exceeds the value that can be expressed by the number of input bits of the digital filter, A miscalculation prevention circuit for an electronic circuit for an electronic musical instrument, characterized in that it operates a data clip circuit installed on the output side of a digital filter to prevent miscalculations (overflow) of musical tone data.
タル信号であり、前記データクリップ回路の出力ビット
は前記デジタルフィルタの入力ビット数内で表現される
最大値を超えないように構成し、かつ正のオーバーフロ
ー時には正の最大値を、負のオーバーフロー時には負の
最大値を出力するように構成したことを特徴とする特許
請求の範囲第1項記載の電子楽器用電子回路の誤演算防
止回路。(2) the musical tone data is a digital signal expressed in two's complement representation, and the output bits of the data clipping circuit are configured so as not to exceed the maximum value expressed within the number of input bits of the digital filter; The miscalculation prevention circuit for an electronic circuit for an electronic musical instrument according to claim 1, wherein the circuit is configured to output a maximum positive value when there is a positive overflow, and to output a maximum negative value when there is a negative overflow. .
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP60004580A JPS61163393A (en) | 1985-01-14 | 1985-01-14 | Miscomputation preventing circuit for electronic cirucuit for electronic musical instrument |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP60004580A JPS61163393A (en) | 1985-01-14 | 1985-01-14 | Miscomputation preventing circuit for electronic cirucuit for electronic musical instrument |
Publications (1)
Publication Number | Publication Date |
---|---|
JPS61163393A true JPS61163393A (en) | 1986-07-24 |
Family
ID=11587972
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP60004580A Pending JPS61163393A (en) | 1985-01-14 | 1985-01-14 | Miscomputation preventing circuit for electronic cirucuit for electronic musical instrument |
Country Status (1)
Country | Link |
---|---|
JP (1) | JPS61163393A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH02126295A (en) * | 1988-11-07 | 1990-05-15 | Kawai Musical Instr Mfg Co Ltd | Musical sound data processing system |
-
1985
- 1985-01-14 JP JP60004580A patent/JPS61163393A/en active Pending
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH02126295A (en) * | 1988-11-07 | 1990-05-15 | Kawai Musical Instr Mfg Co Ltd | Musical sound data processing system |
JP2565555B2 (en) * | 1988-11-07 | 1996-12-18 | 株式会社河合楽器製作所 | Sequence accumulator for electronic musical instruments |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CA1078521A (en) | Digital signal processing device | |
US3609568A (en) | Stable digital filter apparatus | |
KR900008410B1 (en) | Method and apparatus for compensating for cutting error of sample signal | |
US4062060A (en) | Digital filter | |
US5629881A (en) | Method for filtering a digital value train with improved noise behavior, and circuit configuration for performing the method | |
JPS60254097A (en) | Distorted waveform generator | |
US5243658A (en) | Modulation effect adding apparatus | |
JPS61163393A (en) | Miscomputation preventing circuit for electronic cirucuit for electronic musical instrument | |
US4485717A (en) | Electronic musical instrument | |
JP2968847B2 (en) | Noise generator | |
JP3136735B2 (en) | Effect adding device | |
JPH04167170A (en) | Multiplication/addition arithmetic circuit | |
Deo et al. | Improved numerically-controlled digital sinusoidal oscillator | |
JPH03124110A (en) | Digital controlled filter | |
JP3044890B2 (en) | Envelope generator | |
JPH0563509A (en) | Digital filter | |
JPH0311565B2 (en) | ||
JPH04147197A (en) | Musical sound synthesizer | |
JPS6337974B2 (en) | ||
JPS6138998A (en) | Waveform generation system | |
KR970019249A (en) | Linearizer with signal processor for narrowband mobile radio | |
JPH04368999A (en) | signal processing device | |
KR970024536A (en) | Multi-channel, multi-stage oversampling half-band filter with data bus structure | |
JPS6337976B2 (en) | ||
SID-AHMED | A hardware structure for the realization of recursive digital filters |