JP6361109B2 - Electronic stringed instrument, musical sound control method and program - Google Patents

Electronic stringed instrument, musical sound control method and program Download PDF

Info

Publication number
JP6361109B2
JP6361109B2 JP2013221467A JP2013221467A JP6361109B2 JP 6361109 B2 JP6361109 B2 JP 6361109B2 JP 2013221467 A JP2013221467 A JP 2013221467A JP 2013221467 A JP2013221467 A JP 2013221467A JP 6361109 B2 JP6361109 B2 JP 6361109B2
Authority
JP
Japan
Prior art keywords
string
cross point
zero cross
vibration
pitch
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.)
Active
Application number
JP2013221467A
Other languages
Japanese (ja)
Other versions
JP2015082094A (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.)
Casio Computer Co Ltd
Original Assignee
Casio Computer Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Casio Computer Co Ltd filed Critical Casio Computer Co Ltd
Priority to JP2013221467A priority Critical patent/JP6361109B2/en
Publication of JP2015082094A publication Critical patent/JP2015082094A/en
Application granted granted Critical
Publication of JP6361109B2 publication Critical patent/JP6361109B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Electrophonic Musical Instruments (AREA)

Description

本発明は、電子ギター等の電子弦楽器に係り、特にその入力波形信号からピッチ抽出を行って種々の音高の楽音を発生する電子弦楽器、楽音制御方法及びプログラムに関する。   The present invention relates to an electronic stringed instrument such as an electronic guitar, and more particularly to an electronic stringed instrument, a musical tone control method, and a program for generating musical tones of various pitches by extracting pitches from input waveform signals.

従来より、自然楽器の演奏操作によって発生する波形信号からピッチ(基本周波数)を抽出し、電子回路で構成された音源装置を制御して、人工的に楽音等の音響を得るようにした楽音生成装置が開発されている。
このような楽音生成装置を備えた電子ギター等の電子弦楽器においては、弦を指で押さえるフレット操作と、弦を弾くピッキングとが演奏操作として行われ、これらの演奏操作に応じた楽音を発生させる。
ところが、ピッキングにより振動した弦のピッチを抽出する場合、ピッチの抽出に一定の時間を要することから、楽音の発生が遅れる場合がある。
これに対し、特許文献1に記載の電子弦楽器では、フレットに対する操作によって、操作された位置に対応する楽音を発生させている。このように楽音を発生させる場合、弦の振動からピッチを抽出するよりも以前に音高を決められることから、楽音の発生が遅れることを抑制できる。
このように、フレットに対する操作によって、ピッチを抽出するよりも以前に楽音を発生させる場合、音の強さ(ベロシティ)については、ピッキングによって発生した初期の弦の振動を検出し、その振幅に基づいて決定することで、固定的な音の強さとするよりも、実際の演奏を反映させることができる。
Conventionally, musical tone generation is performed by extracting the pitch (fundamental frequency) from the waveform signal generated by the performance operation of a natural musical instrument and controlling the sound source device composed of electronic circuits to artificially obtain sounds such as musical sounds. Equipment has been developed.
In an electronic stringed instrument such as an electronic guitar equipped with such a musical sound generating device, a fret operation for pressing a string with a finger and a picking for playing a string are performed as performance operations, and musical sounds corresponding to these performance operations are generated. .
However, when extracting the pitch of a string that vibrates due to picking, it takes a certain amount of time to extract the pitch, which may delay the generation of musical sounds.
On the other hand, in the electronic stringed instrument described in Patent Document 1, a musical sound corresponding to the operated position is generated by an operation on the fret. In the case where the musical sound is generated in this way, the pitch can be determined before extracting the pitch from the vibration of the string, so that the generation of the musical sound can be suppressed from being delayed.
As described above, when a musical sound is generated before the pitch is extracted by the operation on the frets, the initial vibration of the string generated by picking is detected and the sound intensity (velocity) is detected based on the amplitude. In this way, the actual performance can be reflected rather than a fixed sound intensity.

特開2003−084776号公報Japanese Patent Laid-Open No. 2003-084776

しかしながら、上述のように、ピッキングによって発生した初期の弦の振動を検出し、その振幅に基づいて音の強さを決定した場合、ピッキングによって発生した初期の弦の振動は不安定であることから、必ずしも演奏者が期待する音の強さとはならない場合がある。
このように、特許文献1に記載の技術を含め、従来の電子弦楽器においては、楽音の発生の遅れを抑制しつつ、発生される楽音の強さを適切なものとすることが困難であった。
However, as described above, when the initial string vibration generated by picking is detected and the sound intensity is determined based on the amplitude, the initial string vibration generated by picking is unstable. , It may not always be the sound intensity expected by the performer.
As described above, in the conventional electronic stringed instrument including the technique described in Patent Document 1, it is difficult to make the intensity of the generated musical sound appropriate while suppressing the delay in the generation of the musical sound. .

本発明は、このような状況に鑑みてなされたものであり、電子弦楽器による楽音の発生の遅れを抑制しつつ、発生される楽音の強さをより適切なものとすることを目的とする。   The present invention has been made in view of such a situation, and an object of the present invention is to make the intensity of the generated musical sound more appropriate while suppressing the delay of the musical sound generated by the electronic stringed instrument.

上記目的を達成するため、本発明の一態様の電子弦楽器は、
指板上における押弦操作に基づいて発生すべき楽音の音高を決定する音高決定手段と、
張設された弦の振動を検出する弦振動検出手段と、
前記弦の振動に応じた波形信号における或るゼロクロス点を示す第1ゼロクロス点から前記第1ゼロクロス点の次のゼロクロス点を示す第2ゼロクロス点までの第1の区間で、前記弦の振動のレベルが第1のしきい値を超えたか否か判別する第1の判別手段と、
前記第1のしきい値を超えたと判別された前記第1の区間における弦の振動のレベルと、前記第2ゼロクロス点から前記第2ゼロクロス点の次のゼロクロス点を示す第3ゼロクロス点までの第2の区間における弦の振動のレベルとに基づいて決定した第1の音量で、前記決定された音高の楽音を発生させる制御を行う制御手段と、
前記第3ゼロクロス点から前記第3ゼロクロス点の次のゼロクロス点を示す第4ゼロクロス点までの第3の区間以降における弦の振動のレベルに基づいて、前記第1の音量を補正する補正手段と、
を有する。
In order to achieve the above object, an electronic stringed musical instrument according to one aspect of the present invention is provided.
A pitch determining means for determining a pitch of a musical tone to be generated based on a string pressing operation on the fingerboard;
A string vibration detecting means for detecting vibration of the stretched string;
In a first section from a first zero cross point indicating a certain zero cross point to a second zero cross point next to the first zero cross point in a waveform signal corresponding to the vibration of the string, the vibration of the string First discriminating means for discriminating whether or not the level exceeds a first threshold value;
The level of vibration of the strings in the first and the determined first interval exceeds a threshold value, from the second zero-cross point to the third zero-cross point indicating the next zero cross point of the second zero-cross point Control means for performing control to generate a musical tone of the determined pitch at a first volume determined based on a level of string vibration in the second section;
Correction means for correcting the first volume based on a level of vibration of the string in a third section and thereafter from the third zero cross point to a fourth zero cross point indicating the next zero cross point of the third zero cross point ; ,
Have

本発明によれば、電子弦楽器による楽音の発生の遅れを抑制しつつ、発生される楽音の強さをより適切なものとすることができる。   ADVANTAGE OF THE INVENTION According to this invention, the intensity | strength of the generated musical sound can be made more appropriate, suppressing the generation | occurrence | production delay of the musical sound by an electronic stringed instrument.

本実施例に係る電子ギターの主要部の構成を示す模式図である。It is a schematic diagram which shows the structure of the principal part of the electronic guitar which concerns on a present Example. 全体の回路を示すブロック図である。It is a block diagram which shows the whole circuit. フレットの押弦状態を検出するためのフレット検出回路を示す図である。It is a figure which shows the fret detection circuit for detecting the stringing state of a fret. ピッチ抽出回路及びマイコンの具体的な機能構成を示すブロック図である。It is a block diagram which shows the concrete function structure of a pitch extraction circuit and a microcomputer. マイコンが楽音を発生する際の処理の概要を示す模式図である。It is a schematic diagram which shows the outline | summary of the process at the time of a microcomputer generating a musical sound. マイコンが実行するフレット検出処理ルーチンを示すフローチャートである。It is a flowchart which shows the fret detection process routine which a microcomputer performs. マイコンへインタラプトがかけられたときの処理を示すインタラプトルーチンを示すフローチャートである。It is a flowchart which shows the interrupt routine which shows a process when an interrupt is applied to the microcomputer. メインルーチンを示すフローチャートである。It is a flowchart which shows a main routine. 図8のM5として示すステップ0(STEP0)のときのフローチャートである。FIG. 9 is a flowchart at the time of step 0 (STEP 0) shown as M5 in FIG. 図8にM6として示すSTEP1のフローチャートの詳細である。It is the detail of the flowchart of STEP1 shown as M6 in FIG. 図10にS13として示すVEL1_ONのフローチャートの詳細である。It is the detail of the flowchart of VEL1_ON shown as S13 in FIG. 図11にS132として示すサブルーチンNOTE_ONのフローチャートの詳細である。FIG. 11 is a detailed flowchart of a subroutine NOTE_ON shown as S132 in FIG. 図8にM7として示すSTEP2のフローチャートの詳細である。FIG. 8 is a detailed flowchart of STEP2 shown as M7 in FIG. 図8にM8として示すSTEP3のフローチャートである。It is a flowchart of STEP3 shown as M8 in FIG. S311のサブルーチンの詳細な内容を示す図である。It is a figure which shows the detailed content of the subroutine of S311. 図8のM9として示すSTEP4のフローチャートである。It is a flowchart of STEP4 shown as M9 of FIG.

以下、本発明の実施形態について、図面を用いて説明する。   Hereinafter, embodiments of the present invention will be described with reference to the drawings.

[実施例]
以下、この発明の実施例について図面を参照して説明するが、ここではこの発明を電子ギター(ギターシンセサイザ)に適用した場合を例に挙げて説明する。なお、これに限らず他のタイプの電子楽器であっても同様に適用できる。
[Example]
Hereinafter, embodiments of the present invention will be described with reference to the drawings. Here, a case where the present invention is applied to an electronic guitar (guitar synthesizer) will be described as an example. Note that the present invention is not limited to this and can be applied to other types of electronic musical instruments.

図1は、本実施例に係る電子ギター1の主要部の構成を示す模式図である。
図1に示すように、電子ギター1は、指板FB上に張設された6つの弦STG1〜STG6を備えており、各弦に対して、フレット及びピッキングを行うことにより、アコースティックギター等の自然楽器と同様の操作でユーザの演奏を可能とするものである。図1に示すように、電子ギター1は、指板FB上に張設された6つの弦STG1〜STG6にそれぞれ設けられ、各弦にスキャンパルスを入力するスキャンパルス発生器PGを備えている。そして、電子ギター1は、各弦に対するフレットあるいはピッキングが行われた場合に、フレットスキャン部FS及びピッチ抽出回路PCによって、各操作を検出する。
図2は、全体の回路を示すブロック図である。ピッチ抽出回路PCは、各弦の振動を電気信号に変換し、振動波形のゼロクロス点及び振幅の絶対値を取得して、マイコンMCPに出力する。
FIG. 1 is a schematic diagram illustrating a configuration of a main part of an electronic guitar 1 according to the present embodiment.
As shown in FIG. 1, the electronic guitar 1 includes six strings STG1 to STG6 stretched on the fingerboard FB. By performing fret and picking on each string, the electronic guitar 1 The user can perform with the same operation as a natural musical instrument. As shown in FIG. 1, the electronic guitar 1 is provided with six strings STG1 to STG6 stretched on the fingerboard FB, and includes a scan pulse generator PG that inputs a scan pulse to each string. The electronic guitar 1 detects each operation by the fret scanning unit FS and the pitch extraction circuit PC when fret or picking is performed on each string.
FIG. 2 is a block diagram showing the entire circuit. The pitch extraction circuit PC converts the vibration of each string into an electrical signal, acquires the zero-cross point of the vibration waveform and the absolute value of the amplitude, and outputs them to the microcomputer MCP.

マイコンMCPは、後述する音程データ変換テーブル(ピッチテーブル)を含むメモリ例えばROM及びRAMを有するとともに、タイマーTMRを有し、音源発生装置SOBに与える為の信号を制御するものである。音源発生装置SOBは音源SSとデジタル−アナログ変換回路D/Aと、増幅回路AMCと、スピーカSPとからなり、マイコンMCPからのノートオン(発音)、ノートオフ(消音)、周波数を変える音高指示信号に応じた音高の楽音を放音するものである。なお、音源SSの入力側とマイコンMCPのデータバスBUSとの間に、MIDI(Musical Instrument Digital Interface)形式のインターフェースが設けられている。勿論、ギター本体に音源SSを設けるときは、別のインターフェースを介してもよい。アドレスデコーダDCDは、マイコンMCPからのアドレス読み出し信号ARが入力されたとき、弦番号の読込み信号RDI、時刻読込み信号RDj(j=1〜6)とMAX,MINのピーク値及びその時点その時点の瞬時値読込み信号RDAI(I=1〜18)をピッチ抽出回路PCに出力する。   The microcomputer MCP has a memory such as a ROM and a RAM including a pitch data conversion table (pitch table), which will be described later, and a timer TMR, and controls signals to be supplied to the sound source generator SOB. The sound generator SOB includes a sound source SS, a digital-analog converter circuit D / A, an amplifier circuit AMC, and a speaker SP. Note-on (sounding), note-off (silence) from the microcomputer MCP, and a pitch for changing the frequency. A musical tone having a pitch corresponding to the instruction signal is emitted. Note that an interface in the MIDI (Musical Instrument Digital Interface) format is provided between the input side of the sound source SS and the data bus BUS of the microcomputer MCP. Of course, when the sound source SS is provided in the guitar body, another interface may be used. When the address read signal AR from the microcomputer MCP is input, the address decoder DCD reads the string number read signal RDI, the time read signal RDj (j = 1 to 6), the peak values of MAX and MIN, and the current value at that time. Instantaneous value read signal RDAI (I = 1 to 18) is output to pitch extraction circuit PC.

マイコンMCPは、一定時間毎(例えば1ms毎)の割り込み処理として、各弦における各フレットの押弦状態を常に検出している。押弦状態の検出処理は、各弦のピッキングによるピッチ抽出とは別に並列処理として実行されている。
図3は、フレットの押弦状態を検出するためのフレット検出回路FDCを示す図である。フレット検出回路FDCは、フレットスキャン部FSに備えられている。
図3に示すように、フレット検出回路FDCは、フレットの数に対応する22の選択線KI0〜KI21と、弦の数に対応する6の信号線KC0〜KC5とがマトリクス状に配列された構成を有している。
The microcomputer MCP always detects the stringed state of each fret in each string as interrupt processing at regular intervals (for example, every 1 ms). The pressed state detection process is executed as a parallel process separately from pitch extraction by picking each string.
FIG. 3 is a diagram showing a fret detection circuit FDC for detecting a fret-pressed state. The fret detection circuit FDC is provided in the fret scan unit FS.
As shown in FIG. 3, the fret detection circuit FDC has a configuration in which 22 selection lines KI0 to KI21 corresponding to the number of frets and 6 signal lines KC0 to KC5 corresponding to the number of strings are arranged in a matrix. have.

各選択線KI0〜KI21は、所定時間(例えば1ms)毎に順次アクティブな状態にスイッチングされる。これら選択線KI0〜KI21は、ハイレベル(例えば5v)にプルアップされている。アクティブな状態とされた選択線KI0〜KI21に対し、押弦により指板FBに接触されている弦があると、その弦に対応する信号線KC0〜KC5からはハイレベルの信号が読み出される。
すなわち、フレット検出回路FDCは、所定時間毎に選択線KI0〜KI21を1つずつアクティブな状態に切り替え、信号線KC0〜KC5の状態(ハイレベルまたはローレベル)を読み出して、すべてのフレットについて、いずれの位置が押弦されているかを検出する。
The selection lines KI0 to KI21 are sequentially switched to an active state every predetermined time (for example, 1 ms). These selection lines KI0 to KI21 are pulled up to a high level (for example, 5v). If there is a string that is in contact with the fingerboard FB by pressing the selected line KI0 to KI21 in an active state, a high level signal is read from the signal lines KC0 to KC5 corresponding to the string.
That is, the fret detection circuit FDC switches the selection lines KI0 to KI21 to an active state one by one every predetermined time, reads the state (high level or low level) of the signal lines KC0 to KC5, and for all the frets, Detect which position is pressed.

図4は、ピッチ抽出回路PC及びマイコンMCPの具体的な機能構成を示すブロック図である。ピッチ抽出は、主にピッチ抽出回路PC及びマイコンMCPの以下に説明する機能によって実行される。
図4に示すように、ピッチ抽出回路PCは、ローパスフィルタLPFと、増幅回路AMCと、ゼロクロス点取込回路ZCRと、絶対値取込回路ABSとを備えている。
ローパスフィルタLPFには、ピッキングが行われることにより各弦において発生する波形の信号がヘキサピックアップから入力され、ローパスフィルタLPFは、入力された信号の高周波成分をカットし、低周波成分のみを通過させる。
増幅回路AMCは、ローパスフィルタLPFの出力信号を設定されたゲインに応じて増幅し、ゼロクロス点取込回路ZCR及び絶対値取込回路ABSに出力する。
FIG. 4 is a block diagram showing specific functional configurations of the pitch extraction circuit PC and the microcomputer MCP. The pitch extraction is executed mainly by functions described below of the pitch extraction circuit PC and the microcomputer MCP.
As shown in FIG. 4, the pitch extraction circuit PC includes a low-pass filter LPF, an amplifier circuit AMC, a zero-cross point capturing circuit ZCR, and an absolute value capturing circuit ABS.
A signal having a waveform generated in each string by picking is input to the low-pass filter LPF from the hex pickup, and the low-pass filter LPF cuts the high-frequency component of the input signal and passes only the low-frequency component. .
The amplifier circuit AMC amplifies the output signal of the low-pass filter LPF according to the set gain, and outputs the amplified signal to the zero-cross point capturing circuit ZCR and the absolute value capturing circuit ABS.

ゼロクロス点取込回路ZCRは、入力された波形の信号のゼロクロス点を検出し、ゼロクロス点より正側の場合にハイレベル信号、負側の場合にローレベル信号を出力する。なお、ゼロクロス点取込回路ZCRの出力信号は、反転したもの(反転出力)と非反転のもの(非反転出力)との両方がマイコンMCPに入力される。
絶対値取込回路ABSは、入力された波形の信号の正負両側におけるピーク値をそれぞれ検出し、ピーク値の絶対値及び符号をマイコンMCPに入力する。
The zero-cross point capturing circuit ZCR detects a zero-cross point of the input waveform signal, and outputs a high-level signal when the signal is positive from the zero-cross point and a low-level signal when the signal is negative. Note that both the inverted signal (inverted output) and the non-inverted signal (non-inverted output) are input to the microcomputer MCP as the output signals of the zero-cross point capturing circuit ZCR.
The absolute value fetch circuit ABS detects peak values on both the positive and negative sides of the input waveform signal, and inputs the absolute value and sign of the peak value to the microcomputer MCP.

マイコンMCPは、割込制御回路ICと、タイマーTMRと、アナログ−デジタル変換回路A/Dと、メモリMEMとを備えている。
割込制御回路ICは、ゼロクロス点取込回路ZCRの非反転出力及び反転出力が入力され、これらの立ち上がりエッジで割り込み信号を発生させる。すなわち、割込制御回路ICは、ピッキングによって各弦に発生した波形の信号がゼロクロスするタイミングで、割り込み信号を発生させる。割込制御回路ICは、発生した割り込み信号をタイマーTMRに出力する。
The microcomputer MCP includes an interrupt control circuit IC, a timer TMR, an analog-digital conversion circuit A / D, and a memory MEM.
The interrupt control circuit IC receives the non-inverted output and the inverted output of the zero-cross point capturing circuit ZCR, and generates an interrupt signal at these rising edges. That is, the interrupt control circuit IC generates an interrupt signal at the timing when the waveform signal generated in each string by picking crosses zero. The interrupt control circuit IC outputs the generated interrupt signal to the timer TMR.

タイマーTMRは、割込制御回路ICから割り込み信号が入力されると、入力された時間t(非反転出力による割り込み信号の場合)及び時間T(反転出力による割り込み信号の場合)をメモリMEMに出力する。
アナログ−デジタル変換回路A/Dは、絶対値取込回路ABSから入力されたピーク値の絶対値をデジタル信号に変換し、メモリMEMに出力する。なお、アナログ−デジタル変換回路A/Dは、ピーク値の絶対値とともに入力される符号をデジタル化されたピーク値と併せてメモリMEMに出力する。
When an interrupt signal is input from the interrupt control circuit IC, the timer TMR outputs the input time t (in the case of an interrupt signal by non-inverted output) and time T (in the case of an interrupt signal by inverted output) to the memory MEM. To do.
The analog-digital conversion circuit A / D converts the absolute value of the peak value input from the absolute value acquisition circuit ABS into a digital signal and outputs it to the memory MEM. The analog-to-digital conversion circuit A / D outputs the code input together with the absolute value of the peak value together with the digitized peak value to the memory MEM.

メモリMEMは、タイマーTMRから入力された時間t,Tと、ピーク値の絶対値(デジタル値)及び符号を記憶する。メモリMEMに記憶された時間t,Tは、マイコンMCPが前回記憶された時間t,Tと今回記憶された時間t,Tの差分を算出して周波数(発生させる楽音の音程であるピッチ)を求める際に用いられる。
また、メモリMEMは、各弦のフレットと周波数との関係を示すフレット−周波数データテーブル(不図示)を記憶している。
The memory MEM stores the times t and T input from the timer TMR, the absolute value (digital value) of the peak value, and the sign. The times t and T stored in the memory MEM are calculated by calculating the difference between the times t and T stored last time by the microcomputer MCP and the times t and T stored this time, and calculating the frequency (pitch which is the pitch of the musical sound to be generated). Used when seeking.
The memory MEM stores a fret-frequency data table (not shown) indicating the relationship between the frets of each string and the frequency.

フレット−周波数データテーブルでは、スケールA4を442Hzとし、各弦がいずれの周波数に対応するか、また、フレット位置による音程のコード(キーコード)が関連付けて記憶されている。
また、メモリMEMは、ピッチ抽出によって取得された周波数を音程データ(キーコード)に変換するための音程データ変換テーブル(不図示)を記憶している。
音程データ変換テーブルでは、ピッチ抽出によって得られた周波数が、cent比例した音程データ(キーコード)と対応付けて記憶されている。
In the fret-frequency data table, the scale A4 is set to 442 Hz, the frequency corresponding to each string, and the pitch code (key code) according to the fret position is stored in association with each other.
The memory MEM stores a pitch data conversion table (not shown) for converting the frequency acquired by the pitch extraction into pitch data (key code).
In the pitch data conversion table, the frequency obtained by pitch extraction is stored in association with pitch data (key code) proportional to cent.

マイコンMCPは、メモリMEMに記憶されたこれらのデータを参照ながら、ピッキングが行われた場合に、フレットスキャンの結果及びピッチ抽出の結果に応じて、音程を決定し、楽音を発生する。   When picking is performed while referring to these data stored in the memory MEM, the microcomputer MCP determines a pitch according to the result of the fret scan and the result of the pitch extraction, and generates a musical sound.

次に、マイコンMCPが楽音を発生する際の処理の概要について説明する。
図5は、マイコンMCPが楽音を発生する際の処理の概要を示す模式図である。
図5において、ピッチ抽出回路PCに図5(c)に示す波形の信号が入力されたとすると、これに対するゼロクロス点取込回路ZCRの非反転出力は、図5(a)に示す波形となり、反転出力は、図5(b)に示す波形となる。
Next, an outline of processing when the microcomputer MCP generates musical sounds will be described.
FIG. 5 is a schematic diagram showing an outline of processing when the microcomputer MCP generates a musical sound.
In FIG. 5, if the signal having the waveform shown in FIG. 5C is input to the pitch extraction circuit PC, the non-inverted output of the zero-cross point capturing circuit ZCR corresponding to this is the waveform shown in FIG. The output has the waveform shown in FIG.

マイコンMCPは、ピッチ抽出処理を実行する場合、設定された所定の波高値THLABより小さいものはノイズとみなして波形の信号を破棄する(STEP0〜2)。一方、マイコンMCPは、STEP0において、所定の波高値THLAB以上となった場合、STEP0の波高値VEL0がSTEP0における波高値のしきい値TH0以上となっている場合には、ピッチ抽出処理と並列的に実行しているフレットの押弦状態の検出処理で検出された各フレットの情報から音程(音程の初期値)を検出し、STEP0の波高値に基づいて、STEP1において発音を開始する。具体的には、マイコンMCPは、音量を定めるベロシティVELを(VEL0+VEL1)/2として、STEP1で発音を開始する。   When executing the pitch extraction process, the microcomputer MCP discards the waveform signal by regarding the pitch smaller than the predetermined peak value THLAB as noise (STEP 0 to 2). On the other hand, the microcomputer MCP is parallel to the pitch extraction process when the peak value VEL0 of STEP0 is equal to or greater than the threshold value TH0 of the peak value at STEP0 when the peak value THLAB is equal to or greater than STEPLAB at STEP0. The pitch (initial value of the pitch) is detected from the information of each fret detected by the fret string detection process executed at the beginning, and sound generation is started in STEP 1 based on the peak value of STEP 0. Specifically, the microcomputer MCP sets the velocity VEL for determining the sound volume to (VEL0 + VEL1) / 2 and starts sound generation at STEP1.

この後、マイコンMCPは、STEP0〜2において、所定の波高値THLAB以上となっている場合、その波が新たに入力された初めてのものであるときに、波形のピーク値及び符号をベロシティVEL(具体的には波高値VEL2)の値として取り込む(STEP3)。そして、マイコンMCPは、ピッチ抽出処理において検出したベロシティVELの値を基に、その音程の発音を行う(ノートオン)。発音が行われる場合、マイコンMCPは、音源SSに対して、音程及びベロシティVELの値を出力することにより、発音の指令を行う。また、STEP3において、マイコンMCPは、STEP2で取り込まれた波高値VEL2の値に対応して、ベロシティVELを補正するための情報をアフタータッチ情報として音源に送ることで、STEP1で発音した音量(音の強さ)を補正する。アフタータッチ情報は、一般に、ピッキングの後に弦に対して行われた操作を発音に反映させるための情報であり、本実施形態においては、STEP2以降で取り込まれた波高値に応じて音量を補正するために、アフタータッチ情報の形態で音源に指示を行っている。この後、VEL2≦(1/4)VEL(すなわち、今回の波高値がSTEP1の波高値の1/4以下)であれば、マイコンMCPは、ミュートを示すミュートフラグMfに1を設定する(Mf=1)。一方、VEL2>(1/4)VELであれば、ミュートフラグMfに0を設定する(Mf=0)。なお、ミュートであるか否かを判定するためにベロシティVELに乗ずる係数1/4は一例であり、任意の係数αを用いて1/α(αは正数)と表すことができる。   After that, if the microcomputer MCP is equal to or greater than the predetermined peak value THLAB in STEP0 to STEP2, the peak value and sign of the waveform are set to velocity VEL ( Specifically, it is taken in as a value of the crest value VEL2) (STEP 3). Then, the microcomputer MCP produces a sound of the pitch based on the velocity VEL value detected in the pitch extraction process (note-on). When sound generation is performed, the microcomputer MCP issues a sound generation command to the sound source SS by outputting the pitch and velocity VEL values. In STEP 3, the microcomputer MCP sends information for correcting the velocity VEL to the sound source as after-touch information corresponding to the value of the peak value VEL 2 captured in STEP 2. ). Aftertouch information is generally information for reflecting an operation performed on a string after picking in pronunciation. In the present embodiment, the volume is corrected according to the peak value captured in STEP 2 and subsequent steps. Therefore, the sound source is instructed in the form of aftertouch information. Thereafter, if VEL2 ≦ (1/4) VEL (that is, if the current peak value is equal to or lower than 1/4 of the STEP1 peak value), the microcomputer MCP sets 1 to the mute flag Mf indicating mute (Mf = 1). On the other hand, if VEL2> (1/4) VEL, the mute flag Mf is set to 0 (Mf = 0). Note that the coefficient ¼ multiplied by the velocity VEL to determine whether or not mute is an example, and can be expressed as 1 / α (α is a positive number) using an arbitrary coefficient α.

この後、STEP4において、ピッチ抽出処理は継続され、マイコンMCPは、前回記憶された時間t,Tと今回記憶された時間t,Tの差分から周波数(ピッチ)を算出し(TP(b),TP(b’))、この周波数によって、すでに発音している音程に対する補正を行う。また、STEP4において、マイコンMCPは、STEP3で設定されたミュートフラグMfが1の場合、所定の時間(すなわち、ミュートの判断のために設定された時間)、c≦(1/4)VEL(ただし、cはSTEP4の波高値)の状態が継続したときには、ミュートであると判断して、ノートオフする。一方、STEP4において、STEP3で設定されたミュートフラグMfが1の場合であって、ミュートと判断される上記条件が充足されない場合、マイコンMCPは、ミュートフラグMfを0にリセットし、ミュート状態を解除する。
さらに、上述の一連の処理において、前回のピッキング時に対して、押弦されたフレット位置が変化している場合、マイコンMCPは、前回の音程の補正をリセット(すなわち、押弦されたフレット位置に対応する音程の初期値にセット)し、押弦されたフレット位置が変化していない場合(同一のフレット位置で続けてピッキングされた場合)、前回の音程の補正をリセットすることなく、今回の発音においても同一の補正を行って音程を決定する。
Thereafter, in STEP 4, the pitch extraction process is continued, and the microcomputer MCP calculates the frequency (pitch) from the difference between the time t, T stored last time and the time t, T stored this time (TP (b), TP (b ′)), correction is made for the pitch that is already sounded by this frequency. Further, in STEP 4, when the mute flag Mf set in STEP 3 is 1, the microcomputer MCP has a predetermined time (that is, a time set for determining mute), c ≦ (1/4) VEL (however, , C is the peak value of STEP 4), the state is determined to be muted and the note is turned off. On the other hand, if the mute flag Mf set in STEP 3 is 1 in STEP 4 and the above condition for determining mute is not satisfied, the microcomputer MCP resets the mute flag Mf to 0 and cancels the mute state. To do.
Further, in the above-described series of processing, if the pressed fret position has changed from the previous picking time, the microcomputer MCP resets the previous pitch correction (ie, corresponds to the pressed fret position). If the fret position where the string was pressed has not changed (when picked continuously at the same fret position), the previous pitch correction will not be reset, Perform the same correction to determine the pitch.

以下、マイコンMCPの動作についてフローチャートや波形を示す図面を参照して説明する。
初めに、図面の符号について説明する。
AD・・・図2の瞬時値読込み信号RDA13〜18によりピッチ抽出回路PCの入力波形を直接読んだ入力波高値(瞬時値)
AMP(0,1)・・・正または負の前回(old)の波高値
AMRL1・・・振幅レジスタで記憶されているリラティブ(relative)オフ(off)のチェックのための前回の振幅値である。ここで、前記リラティブオフとは波高値が急激に減衰してきたことに基づき消音することで、フレット操作をやめて開放弦へ移ったときの消音処理に相当する。
AMRL2・・・振幅レジスタで記憶されている前記リラティブオフのための前々回の振幅値で、これにはAMRL1の値が入力される。
Hereinafter, the operation of the microcomputer MCP will be described with reference to flowcharts and drawings showing waveforms.
First, reference numerals in the drawings will be described.
AD: Input peak value (instantaneous value) obtained by directly reading the input waveform of the pitch extraction circuit PC by the instantaneous value read signals RDA13 to 18 in FIG.
AMP (0, 1)... Positive or negative previous (old) peak value AMRL1... The previous amplitude value for checking the relative off stored in the amplitude register. . Here, the relative off corresponds to the silencing process when the fret operation is stopped and the string is moved to the open string by muting based on the fact that the crest value has suddenly attenuated.
AMRL2... The previous amplitude value stored in the amplitude register for the relative off, and the value of AMRL1 is input thereto.

CHTIM・・・最高音フレット(22フレット)に対応する周期
CHTIO・・・開放弦フレットに対応する周期
CHTRR・・・時定数変換レジスタで、上述の時定数変換制御回路TCC(図2)の内部に設けられている。
DUB・・・波形が続けて同一方向に来たことを示すフラグ
FOFR・・・リラティブオフカウンタ
HNC・・・波形ナンバーカウンタ
CHTIM: Period corresponding to the highest sound fret (22 fret) CHTIO: Period corresponding to the open string fret CHTRR: Time constant conversion register, inside the time constant conversion control circuit TCC (FIG. 2) Is provided.
DUB: Flag indicating that the waveform has continued in the same direction FOFR: Relative off counter HNC: Waveform number counter

K・・・半音以上と半音未満の音高コードからなる音高データ
MT・・・これからピッチ抽出を行う側のフラグ(正=1,負=0)
MF・・・ミュートフラグ
NCHLV・・・ノーチェンジレベル(定数)
NSC・・・新しいスケールコード
OSC・・・前回のスケールコード
OFTIM・・・オフタイム(例えば当該弦の開放弦周期に相当)
OFPT・・・通常オフチェック開始フラグ
ONF・・・ノートオフフラグ
RIV・・・後述のステップ(STEP)4での処理ルートの切替を行うためのフラグ
ROFCT・・・リラティブオフのチェック回数を定める定数
K: Pitch data consisting of pitch codes of more than half tone and less than half tone MT: Flag on the side from which pitch is to be extracted (positive = 1, negative = 0)
MF ... Mute flag NCHLV ... No change level (constant)
NSC-New scale code OSC-Previous scale code OFTIM-Off time (for example, corresponding to the open string period of the string)
OFPT: Normal off check start flag ONF: Note off flag RIV: Flag for switching the processing route in step (STEP) 4 described later ROFCT: Constant for determining the number of checks for relative off

STEP・・・マイコンMCPのフロー動作を指定するレジスタ(1〜5)
T・・・周期データ
TF・・・有効となった前回のゼロクロス時刻データ
TFN(0,1)・・・正または負のピーク値直後の前回のゼロクロス時刻データ
TFR・・・時刻記憶レジスタ
THLIM・・・周波数上限(定数)
TLLIM・・・周波数下限(定数)
STEP: Register (1-5) that specifies the flow operation of the microcomputer MCP
T: Period data TF: Previous zero cross time data that became valid TFN (0, 1): Previous zero cross time data immediately after positive or negative peak value TFR: Time memory register THLIM ..Frequency upper limit (constant)
TLLIM ... Frequency lower limit (constant)

TP(0,1)・・・正または負の前回の周期データ
THLAB・・・STEP0,STEP1におけるノイズ除去用しきい値
TH0・・・STEP0における波高値判定用しきい値
TH1・・・STEP1における波高値判定用しきい値
TRLRL・・・リラティブオン(再発音開始)
TRLRS・・・共振除去しきい値
TP (0, 1)... Positive or negative previous cycle data THLAB... Noise elimination threshold value in STEP0 and STEP1 TH0... Peak value judgment threshold value in STEP0 TH1. Threshold value for peak value determination TRLRL: Relative on (re-pronounced)
TRLRS: Resonance elimination threshold

TTLIM・・・トリガー時の周波数下限
TTP・・・前回抽出された周期データ
TTR・・・周期レジスタ
TTU・・・定数(17/32と今回の周期情報ttの積)
TTW・・・定数(31/16と今回の周期情報ttの積)
VEL・・・速度(ベロシティー)を定める情報で、発音開始時の波形の最大ピーク値(波高値)にて定まる。
VEL0・・・STEP0におけるノイズ除去後の波高値(=a0)
VEL1・・・STEP1におけるノイズ除去後の波高値(=b0)
VEL2・・・STEP2における波高値(=a1)
TTLIM ... Lower frequency limit when triggering TTP ... Cycle data extracted last time TTR ... Cycle register TTU ... Constant (product of 17/32 and current cycle information tt)
TTW: Constant (product of 31/16 and current cycle information tt)
VEL is information that determines the velocity (velocity) and is determined by the maximum peak value (crest value) of the waveform at the start of sound generation.
VEL0 ... Crest value after noise removal in STEP0 (= a0)
VEL1... Peak value after noise removal in STEP1 (= b0)
VEL2 ... Peak value in STEP2 (= a1)

X・・・異常または正常状態を示すフラグ
b・・・ワーキングレジスタBに記憶されている今回正負フラグ(正ピークの次のゼロ点のとき1、負ピークの次のゼロ点のとき0)
c・・・ワーキングレジスタCに記憶されている今回波高値(ピーク値)
e・・・ワーキングレジスタEに記憶されている前々回波高値(ピーク値)
h・・・ワーキングレジスタHに記憶されている前々回抽出された周期データ
t・・・ワーキングレジスタTrに記憶されている今回のゼロクロス時刻
tt・・・ワーキングレジスタTOTOに記憶されている今回の周期情報
α・・・ミュートの判断のために用いる係数
X: Flag indicating abnormal or normal state b: Current positive / negative flag stored in the working register B (1 at the zero point next to the positive peak, 0 at the next zero point after the negative peak)
c: Current peak value (peak value) stored in working register C
e ・ ・ ・ Previous peak value (peak value) stored in working register E
h: Period data extracted last time stored in the working register H t: Current zero-cross time stored in the working register Tr tt: Current period information stored in the working register TOTO α: Coefficient used to determine mute

図6は、マイコンMCPが実行するフレット検出処理ルーチンを示すフローチャートである。
F1において、マイコンMCPは、選択線KI0〜KI21のうち1つ(例えば選択線KI0)を選択し、アクティブな状態とする。
続くF2において、マイコンMCPは、信号線KC0〜KC5の信号レベルを読み出す。このとき、押弦されている弦に対応する信号線では、信号レベルがハイレベルとなり、押弦されていない弦に対応する信号線では、信号レベルがローレベルとなる。
FIG. 6 is a flowchart showing a fret detection processing routine executed by the microcomputer MCP.
In F1, the microcomputer MCP selects one of the selection lines KI0 to KI21 (for example, the selection line KI0) to make it active.
In subsequent F2, the microcomputer MCP reads the signal levels of the signal lines KC0 to KC5. At this time, the signal level corresponding to the string being pressed has a high signal level, and the signal level corresponding to the string not being pressed has a low level.

そして、F3において、マイコンMCPは、押弦されているか否かの判定を行う。マイコンMCPは、押弦されている場合すなわちイエス(以下、Yと称する)の場合、F4の処理に移行し、押弦されていない場合すなわちノー(以下、Nと称する)の場合、F1の処理に移行する。
F4において、マイコンMCPは、音程コードを算出する。このとき、マイコンMCPは、押弦位置の音程コードを算出する。
このような処理を繰り返し、マイコンMCPは、すべてのフレットについて、各弦の押弦状態を検出する。
In F3, the microcomputer MCP determines whether or not the string is pressed. The microcomputer MCP shifts to the process of F4 when the string is pressed, that is, when yes (hereinafter referred to as Y), and shifts to the process of F1 when the string is not pressed, that is, when it is no (hereinafter referred to as N). To do.
In F4, the microcomputer MCP calculates a pitch code. At this time, the microcomputer MCP calculates a pitch code at the string-pressed position.
By repeating such processing, the microcomputer MCP detects the pressed state of each string for all the frets.

図7は、マイコンMCPへインタラプトがかけられたときの処理を示すインタラプトルーチンであり、I1において、マイコンMCPはアドレスデコーダDCDを介し、ゼロクロス時刻取込回路ZTSに対し、弦番号読み込み信号RDIを与えてインタラプトを与えた弦を指定する弦番号を読み込む。そして、その弦番号に対応する時刻情報つまりゼロクロス時刻情報をゼロクロス時刻取込回路ZTSへ時刻読込み信号RD1〜RD6のいずれかに対応するものを与えて読込む。これをtとする。しかる後、I2において、同様に波高値取込み回路PVSへピーク値読込み信号RDAI(I=1〜12のうちのいずれか)を与えて、ピーク値を読取る。これをcとする。   FIG. 7 is an interrupt routine showing processing when an interrupt is applied to the microcomputer MCP. In I1, the microcomputer MCP gives a string number read signal RDI to the zero-cross time acquisition circuit ZTS via the address decoder DCD. Read the string number that specifies the string that interrupted. Then, the time information corresponding to the string number, that is, the zero cross time information is read by giving the zero cross time fetch circuit ZTS the one corresponding to any of the time read signals RD1 to RD6. This is t. Thereafter, at I2, the peak value read signal RDAI (any one of I = 1 to 12) is similarly applied to the peak value acquisition circuit PVS to read the peak value. Let this be c.

続くI3において、当該ピーク値は正、負のいずれかのピークであるのかを示す情報bをゼロクロス時刻取込回路ZTSより得る。そして、I4にて、このようにして得たt,c,bの値をマイコンMCP内のバッファレジスタTr,C,Bにセットする。このバッファには、割込み処理がなされる都度、このような時刻情報、ピーク値情報、ピークの種類を示す情報がワンセットとして書込まれていき、メインルーチンで、各弦毎にかかる情報に対する処理がなされる。   In the subsequent I3, information b indicating whether the peak value is a positive or negative peak is obtained from the zero cross time acquisition circuit ZTS. Then, at I4, the values of t, c, b obtained in this way are set in the buffer registers Tr, C, B in the microcomputer MCP. Each time interrupt processing is performed in this buffer, such time information, peak value information, and information indicating the type of peak are written as one set, and processing for information on each string is performed in the main routine. Is made.

図8は、メインルーチンを示すフローチャートである。パワーオンすることによりM1において、各種レジスタやフラグがイニシャライズされ、レジスタSTEPが0とされる。M2で上述したバッファが空かどうかが判断され、Nの場合にはM3に進み、バッファよりレジスタB,C,Trの内容が読まれる。これにより、M4において、レジスタSTEPはいくつか判断され、M5ではSTEP0,M6ではSTEP1,M7ではSTEP2,M8ではSTEP3,M9ではSTEP4の処理が順次行われる。   FIG. 8 is a flowchart showing the main routine. By turning on the power, various registers and flags are initialized in M1, and the register STEP is set to zero. In M2, it is determined whether the above-described buffer is empty. If N, the process proceeds to M3, and the contents of the registers B, C, Tr are read from the buffer. As a result, several register STEPs are determined in M4, STEP0 in M5, STEP1 in M6, STEP2 in M7, STEP3 in M8, and STEP4 in M9.

M2でバッファが空の場合すなわちYの場合、M10〜M16へと順次に進み、ここで通常のノートオフのアルゴリズムの処理が行われる。このノートオフのアルゴリズムは、オフ(OFF)レベル以下の状態が所定のオフタイム時間続いたら、ノートオフするアルゴリズムである。M10でSTEP=0かどうかが判断され、Nの場合には、M11に進む。M11では、その時点の入力波高値ADが直接読まれる。これは、波高値取込み回路PVSへピーク値取込み信号RDA13〜RDA18のいずれかを与えることで達成できる。そして、この値ADが、入力波高値AD≦オフレベルかどうかが判断され、Yの場合にはM12に進む。M12では前回の入力波高値AD≦オフレベルかどうかが判断され、Yの場合にはM13に進み、ここでタイマーTMRの値≧オフタイムOFTIM(例えば当該弦の開放弦周期の定数)かどうかが判断される。Yの場合には、M14に進み、レジスタSTEPに0が書きこまれ、M15ではノートオンかどうかが判断され、Yの場合には、M16でノートオフ処理され、M2の入側のMに戻る。M12でNの場合にはM17に進み、マイコンMCP内部タイマーTMRをスタートし、M2の入側Mに戻る。M10でYの場合、及びM11、M13、M15でNの場合には、いずれもM12の入側のMに戻る。   If the buffer is empty at M2, that is, if Y, the process proceeds sequentially from M10 to M16, where normal note-off algorithm processing is performed. This note-off algorithm is an algorithm that performs note-off when a state below an OFF (OFF) level continues for a predetermined off-time period. In M10, it is determined whether STEP = 0. If N, the process proceeds to M11. At M11, the input peak value AD at that time is directly read. This can be achieved by supplying any of the peak value acquisition signals RDA13 to RDA18 to the peak value acquisition circuit PVS. Then, it is determined whether or not the value AD is the input peak value AD ≦ off level. If Y, the process proceeds to M12. In M12, it is determined whether or not the previous input peak value AD ≦ off level. If Y, the process proceeds to M13, where it is determined whether the value of the timer TMR ≧ off time OFTIM (for example, the constant of the open string period of the string). To be judged. In the case of Y, the process proceeds to M14, and 0 is written in the register STEP. In M15, it is determined whether or not the note is on. In the case of Y, the note-off process is performed in M16 and the process returns to M on the entry side of M2. . If M12 is N, the process proceeds to M17, the microcomputer MCP internal timer TMR is started, and the process returns to the entry side M of M2. If M10 is Y and M11, M13, and M15 are N, all return to M on the entry side of M12.

このように、波形入力のレベルが減衰してきた場合、オフレベル以下の入力波高値ADがオフタイムOFFTIMに相当する時間続くと、ノートオフの指示を音源SSに対しマイコンMCPは送出する。なお、ステップM15において、通常の状態ではYの判断がなされるが、後述するような処理によって、楽音の発生を指示していない場合でもレジスタSTEPは0以外の値をとっていることがあり、(例えばノイズの入力による。)そのようなときは、M14,M15の処理後M2へ戻ることで、初期設定がなされることになる。
なお、図8では、1つの弦についての処理しか示していないが、この図に示した如き処理を弦の数に相当する6回分、多重化してマイコンMCPは実行することになる。勿論、プロセッサを複数個設けて、別個独立して同等の処理を実行してもよい。
As described above, when the waveform input level is attenuated, the microcomputer MCP sends a note-off instruction to the sound source SS when the input peak value AD below the off level continues for a time corresponding to the off time OFFTIM. In step M15, a determination of Y is made in a normal state, but the register STEP may take a value other than 0 even when the generation of a musical tone is not instructed by the processing described later. (For example, due to noise input.) In such a case, the initial setting is performed by returning to M2 after the processing of M14 and M15.
In FIG. 8, only the processing for one string is shown, but the microcomputer MCP executes the processing as shown in FIG. 8 by multiplexing the processing for six times corresponding to the number of strings. Of course, a plurality of processors may be provided and the same processing may be executed separately and independently.

次に、M4にて分岐して対応する処理を行う各ルーチンの詳細について説明する。
図9は、図8のM5として示すステップ0(STEP0)のときのフローチャートであり、S01で絶対トリガーレベル(ノートオン、しきい値)TRLAB(b)<今回波高値cかどうかが判断され、Yの場合にはS02に進み共振除去がチェックされる。なお、このトリガーレベルは、正と負との極性のピークそれぞれについてのチェックを行うようになっている。これら正の場合のTRLAB(0)と負の場合のTRLAB(1)とは、実験等によって適切な値とすることになる。理想的なシステムではTRLAB(0)とTRLAB(1)とは同じでよい。S02では、共振除去しきい値TRLRS<[今回波高値c−前回波高値AMP(b)]かどうか、すなわち今回波高値と前回波高値の差が所定値以上か否かが判断される。
Next, details of each routine that branches at M4 and performs the corresponding processing will be described.
FIG. 9 is a flowchart at step 0 (STEP 0) shown as M5 in FIG. 8. In S01, it is determined whether or not absolute trigger level (note-on, threshold) TRLAB (b) <current peak value c. In the case of Y, the process proceeds to S02 and the resonance removal is checked. The trigger level is checked for each of positive and negative peaks. These TRLAB (0) in the positive case and TRLAB (1) in the negative case are set to appropriate values through experiments or the like. In an ideal system, TRLAB (0) and TRLAB (1) may be the same. In S02, it is determined whether or not the resonance elimination threshold value TRLRS <[current peak value c−previous peak value AMP (b)], that is, whether or not the difference between the current peak value and the previous peak value is greater than or equal to a predetermined value.

1つの弦をピッキングすることによって他の弦が共振を起こす場合、当該他の弦については、振動のレベルが徐々に大きくなり、その結果前回と今回とのピーク値の変化は微小なものとなって、その差は共振除去しきい値TRLRSを超えることはない。ところが、通常のピッキングでは、波形が急激に立上る(あるいは立ち下がる)ことになり、前記ピークの差は共振除去しきい値TRLRSを超える。   When picking one string causes other strings to resonate, the vibration level of the other strings gradually increases, and as a result, the change in peak value between the previous time and this time is very small. Thus, the difference does not exceed the resonance elimination threshold TRLRS. However, in normal picking, the waveform suddenly rises (or falls), and the peak difference exceeds the resonance elimination threshold TRLRS.

いま、このS02で、Yの場合つまり共振の場合でないとみなした場合には、S03において次の処理が行われる。すなわち、今回正負フラグbがフラグMTに書込まれ、レジスタSTEPに1が書込まれ、さらに今回のゼロクロス時刻tが前回のゼロクロス時刻データでTFN(b)として設定される。そして、S04では、その他フラグ類がイニシャライズされ、S05に進む。S05では、今回波高値cがSTEP0における波高値VEL0として設定されるとともに、今回波高値cが前回の波高値AMP(b)としてセットされ、しかる後図8のメインルーチンへリターンする。すなわち、ステップS05では、STEP0において得られた波高値がベロシティとしては使用されないように設定される。ただし、STEP0におけるゼロクロス点は、ピッチ抽出のために保持される。STEP0において取得される半波長の波は、一般に波高値が低く、ベロシティとして用いることが適当ではないことが実験により判明している。   If it is determined in S02 that the case is Y, that is, the case of resonance, the following processing is performed in S03. That is, the current positive / negative flag b is written in the flag MT, 1 is written in the register STEP, and the current zero cross time t is set as TFN (b) in the previous zero cross time data. In S04, other flags are initialized, and the process proceeds to S05. In S05, the current peak value c is set as the peak value VEL0 in STEP0, the current peak value c is set as the previous peak value AMP (b), and then the process returns to the main routine of FIG. That is, in step S05, the peak value obtained in STEP 0 is set not to be used as velocity. However, the zero cross point in STEP 0 is retained for pitch extraction. Experiments have shown that half-wave waves acquired in STEP 0 generally have a low peak value and are not suitable for use as velocity.

図9において、Aはリラティブオン(再発音開始)のエントリであり、後述するSTEP4のフローからこのS06へジャンプしてくる。そして、S06では今まで出力している楽音を一度消音し、再発音開始のためにS03へ進行する。この再発音開始のための処理は、通常の発音開始のときと同様であり、以下に詳述するとおりとなる。   In FIG. 9, A is an entry for Relative On (re-sounding start), and jumps to S06 from the flow of STEP 4 described later. In step S06, the musical tone output so far is muted once, and the process proceeds to step S03 to start re-sounding. The process for starting the re-sounding is the same as that for starting the normal sounding, and will be described in detail below.

そして、またS01でNの場合と、S02でNの場合(今回波高値c−前回波高値AMP(b)が所定値以上ない場合)には、S05に進む。従って、発音開始のための処理は進まないことになる。
以上述べたSTEP0では、フラグMTにBレジスタの内容(b=1)が書込まれ、レジスタTrの内容(t)が前回ゼロクロス時刻データTFN(1)に書込まれ、レジスタCの波高値(c)が前回の波高値AMP(1)に書込まれる。
If the answer is N in S01 and N in S02 (when the current peak value c−the previous peak value AMP (b) is not greater than or equal to a predetermined value), the process proceeds to S05. Therefore, the process for starting sound generation does not proceed.
In STEP0 described above, the contents of the B register (b = 1) are written to the flag MT, the contents (t) of the register Tr are written to the previous zero cross time data TFN (1), and the peak value ( c) is written in the previous peak value AMP (1).

図10は図8にM6として示すSTEP1のフローチャートの詳細を示すものであり、S11では、レジスタBの内容(b)と、フラグMTが不一致かどうかが判断され、Yの場合にはS12に進む。S12では、絶対トリガーレベル(ノートオンしきい値)TRLAB(b)<今回波高値cかどうかが判断され、Yの場合にはS13に進む。S12でYの場合にはS13でサブルーチンVEL1_ONが実行される。サブルーチンVEL1_ONは、波高値がしきい値を超えることにより暫定発音を開始するための処理である。続いて、S14でレジスタSTEPに2がセットされ、S15でレジスタTrの内容(1)を前回のゼロクロス時刻データでTFN(b)としてセットし、さらにS16で今回波高値cを、前回の波高値AMP(b)へセットする。S11において、Nの場合すなわち入力波形信号が同一方向にきた場合S17に進み、今回波高値c>前回波高値AMP(b)かどうかが判断され、Yの場合すなわち今回の波高値cが前回の波高値AMP(b)より大の場合には、S15に進む。一方、S12においてNの場合には、S16に進み、これにより波高値のみが更新される。また、S17において、Nの場合及び、S16の処理の終了時にはメインルーチン(図8)ヘリターンする。   FIG. 10 shows the details of the flowchart of STEP1 shown as M6 in FIG. 8. In S11, it is determined whether or not the contents (b) of the register B and the flag MT are inconsistent. If Y, the process proceeds to S12. . In S12, it is determined whether or not the absolute trigger level (note-on threshold) TRLAB (b) <current peak value c. If YES, the process proceeds to S13. If the answer is Y in S12, the subroutine VEL1_ON is executed in S13. Subroutine VEL1_ON is a process for starting provisional sound generation when the peak value exceeds a threshold value. Subsequently, 2 is set in the register STEP in S14, the content (1) of the register Tr is set as TFN (b) in the previous zero cross time data in S15, and the current peak value c is changed to the previous peak value in S16. Set to AMP (b). In S11, if the input waveform signal comes in the same direction in the case of N, the process proceeds to S17, and it is determined whether or not the current peak value c> the previous peak value AMP (b). If it is larger than the peak value AMP (b), the process proceeds to S15. On the other hand, in the case of N in S12, the process proceeds to S16, whereby only the peak value is updated. In S17, the process returns to the main routine (FIG. 8) in the case of N and at the end of the process of S16.

以上述べたSTEP1では、今回正負フラグb(=0)とフラグMT=1が不一致ということで、今回のゼロクロス時刻tを前回のゼロクロス時刻データTFN(0)としてセットし、さらに今回波高値cを前回の波高値AMP(0)として書込む。   In STEP 1 described above, since the current positive / negative flag b (= 0) and the flag MT = 1 do not match, the current zero cross time t is set as the previous zero cross time data TFN (0), and the current peak value c is further set. Write as the previous peak value AMP (0).

図11は、図10にS13として示すVEL1_ONのフローチャートの詳細を示すもので、S131において、STEP1の波高値VEL1に今回波高値cをセットする。
S132でサブルーチンNOTE_ONが実行され、所定の音程及びベロシティで発音が開始される。
以上述べたVEL1_ONでは、STEP1からSTEP2またはSTEP3に移行する場合に、サブルーチンNOTE_ONが実行される。
FIG. 11 shows the details of the VEL1_ON flowchart shown as S13 in FIG. 10. In S131, the current peak value c is set to the peak value VEL1 of STEP1.
In S132, the subroutine NOTE_ON is executed, and sound generation is started with a predetermined pitch and velocity.
In VEL1_ON described above, the subroutine NOTE_ON is executed when shifting from STEP1 to STEP2 or STEP3.

図12は、図11にS132として示すサブルーチンNOTE_ONのフローチャートの詳細を示すもので、S1001において、ベロシティVELにSTEP0の波高値とSTEP1の波高値の平均値(VEL0+VEL1)/2が設定される。   FIG. 12 shows the details of the flowchart of the subroutine NOTE_ON shown as S132 in FIG. 11. In S1001, the average value (VEL0 + VEL1) / 2 of the STEP0 peak value and the STEP1 peak value is set in the velocity VEL.

ステップS1002において、振動が検出されている弦のフレット状態を検出し、ステップS1003において、フレット検出処理で検出された弦の押弦位置を基に、スケールコード(音程)を取得する。
ステップS1004において、取得されたスケールコード(音程)が新しいスケールコードを示すNSCに設定される。
S1005において、新しいスケールコードNSCが前回のスケールコードを示すOSCと一致しているかが判断され、Nの場合にはS1006に進み、音源SSに対して、音程を補正するための情報(ピッチベンド情報)として、押弦位置に応じて設定されているスケールコード(以下、適宜「中央位置情報」という。)が送られる。
In step S1002, the fret state of the string whose vibration is detected is detected. In step S1003, a scale code (pitch) is acquired based on the string pressing position detected in the fret detection process.
In step S1004, the acquired scale code (pitch) is set to NSC indicating a new scale code.
In S1005, it is determined whether the new scale code NSC matches the OSC indicating the previous scale code. If N, the process proceeds to S1006, and information for correcting the pitch for the sound source SS (pitch bend information). A scale code (hereinafter referred to as “center position information” as appropriate) set in accordance with the string pressing position is sent.

S1005でYの場合及びS1006の後、処理はS1007に進み、設定されているスケールコード(音程)及びベロシティVELによって発音(ノートオン)を開始する。
S1008において、前回のスケールコードOSCに新しいスケールコードNSCが設定される。すなわち、今回のスケールコードがOSCに保存される。
S1008の後、メインルーチン(図8)へリターンする。
In the case of Y in S1005 and after S1006, the process proceeds to S1007, and sound generation (note-on) is started by the set scale code (pitch) and velocity VEL.
In S1008, a new scale code NSC is set as the previous scale code OSC. That is, the current scale code is stored in the OSC.
After S1008, the process returns to the main routine (FIG. 8).

図13は、図8にM7として示すSTEP2のフローチャートの詳細を示すもので、S20において、今回正負フラグb=フラグMTかどうかすなわちSTEP0の方向と同一のゼロクロス点の到来かどうかを判断し、Yの場合にはS21に進む。S21では、レジスタCHTRRへ開放弦周期CHTIOをセットし、S22に進む。S22では、今回波高値c>(7/8)×前回の波高値AMP(b)かどうか、つまり波高値が前回と今回とで略同一かどうかをチェックし、Yの場合つまり美しい自然減衰の場合には、S23に進み、フラグDUBを0にセットし、S24に進む。S24では、周期計算を行い、今回のゼロクロス時刻t−前回のゼロクロス時刻データTFN(b)を前回周期データTP(b)に入力し、今回のゼロクロス時刻tを前回ゼロクロス時刻データTFN(b)として入力する。S24におけるTP(b)は、STEP3でノートオン(1.5波)の条件として使用される。また、S241では、STEP2の波高値VEL2に今回波高値cをセットする。さらに、S242では、図12のサブルーチンNOTE_ONが実行され、S243でレジスタSTEPが3とセットされる。さらに、また、S244では、今回波高値cを前回の波高値AMP(b)ヘ書込む。S244の後、メインルーチンへリターン(RET)する。   FIG. 13 shows the details of the flowchart of STEP 2 shown as M 7 in FIG. 8. In S 20, it is determined whether or not the current positive / negative flag b = flag MT, that is, whether or not the same zero cross point as the direction of STEP 0 has arrived. In this case, the process proceeds to S21. In S21, the open string period CHTIO is set in the register CHTRR, and the process proceeds to S22. In S22, it is checked whether or not the current peak value c> (7/8) × previous peak value AMP (b), that is, whether the peak value is substantially the same between the previous peak and the current peak. In this case, the process proceeds to S23, the flag DUB is set to 0, and the process proceeds to S24. In S24, a cycle calculation is performed, and the current zero cross time t−the previous zero cross time data TFN (b) is input to the previous cycle data TP (b), and the current zero cross time t is set as the previous zero cross time data TFN (b). input. TP (b) in S24 is used as a note-on (1.5 wave) condition in STEP3. In S241, the current peak value c is set to the peak value VEL2 of STEP2. Further, in S242, the subroutine NOTE_ON of FIG. 12 is executed, and in step S243, the register STEP is set to 3. Furthermore, in S244, the current peak value c is written into the previous peak value AMP (b). After S244, the process returns to the main routine (RET).

S20でNの場合には、S25に進み、フラグDUBすなわち同一方向の入力波形がきたということを意味するフラグを1にし、S26に進む。S26では、今回波高値c>前回の波高値AMP(b)かどうかが判断され、Yの場合にはS29に進む。S29では今回波高値cに前回の波高値AMP(b)が書替えられ、レジスタTの内容tに前回のゼロクロス時刻データTFN(b)が書替えられる。また、S22において、Nの場合には、S27に進み、フラグDUB=1かどうか、つまり前回STEP2を実行したとき、ダブッたか否かのチェックを行い、Yの場合つまりダブッていればS28に進む。S28では、フラグDUBを0にする。この場合にはS29に進みメインルーチンにリターンする。またS26のNのときも、同様にメインルーチンヘリターン(RET)する。   In the case of N in S20, the process proceeds to S25, in which the flag DUB, that is, the flag indicating that the input waveform in the same direction has come is set to 1, and the process proceeds to S26. In S26, it is determined whether or not the current peak value c> the previous peak value AMP (b). If Y, the process proceeds to S29. In S29, the previous peak value AMP (b) is rewritten to the current peak value c, and the previous zero cross time data TFN (b) is rewritten to the contents t of the register T. In S22, if N, the process proceeds to S27, where it is checked whether or not the flag DUB = 1, that is, whether or not the previous STEP2 was executed. If Y, that is, if it is double, the process proceeds to S28. . In S28, the flag DUB is set to zero. In this case, the process proceeds to S29 and returns to the main routine. Similarly, when the answer is N in S26, the process returns (RET) to the main routine.

以上述べたSTEP2では、今回正負フラグbとしてフラグMT=1が書替えられ、レジスタCHTRRに0フレット周期すなわち開放弦周期CHTIOが書替えられ、またフラグDUBが0にセットされ、さらにt−TFN(1)→TP(1)なる周期計算が行われ、また今回ゼロクロス時刻tに前回のゼロクロス時刻データTFN(1)が書き替えられ、今回波高値cがSTEP2の波高値VEL2としてセットされ、図12のサブルーチンNOTE_ONが実行され、さらに今回波高値cとして前回波高値AMP(1)がセットされる。   In STEP 2 described above, the flag MT = 1 is rewritten as the current positive / negative flag b, the 0 fret period, that is, the open string period CHTIO is rewritten in the register CHTRR, the flag DUB is set to 0, and t-TFN (1) → The period calculation of TP (1) is performed, and the previous zero-cross time data TFN (1) is rewritten at the current zero-cross time t, the current peak value c is set as the peak value VEL2 of STEP2, and the subroutine of FIG. NOTE_ON is executed, and the previous peak value AMP (1) is set as the current peak value c.

図14は、図8にM8として示すSTEP3のフローチャートであり、S30でフラグMT≠今回正負フラグbかどうかが判断され、正常の場合すなわちYのときは、S31に進む。S31では、(1/8)c<AMP(b)ならXが0、また逆の場合にはX=1にセットされ、S32に進む。S32では今回波高値cとして前回の波高値AMP(b)が書替えられる。
そしてS33において、STEP2で得られたVELより今回波高値cが大であれば、ベロシティVELは今回波高値cが入力される。もし逆ならば、このベロシティVELは変化しない。次に今回正負フラグbにフラグMTが移替えられ、これによりピッチ変更側が逆にされる。これは、後述するSTEP4からフラグMTの意味が変り、ピッチ変更側を意味している。そして、S34で[t−TFN(b)→TP(b)]なる周期計算が行われる。また、今回のゼロクロス時刻tとして前回のゼロクロス時刻データでTFN(b)が書替えられる。
FIG. 14 is a flowchart of STEP3 shown as M8 in FIG. 8. In S30, it is determined whether or not the flag MT ≠ currently positive / negative flag b. If normal, that is, if Y, the process proceeds to S31. In S31, if (1/8) c <AMP (b), X is set to 0, and in the opposite case, X = 1 is set, and the process proceeds to S32. In S32, the previous peak value AMP (b) is rewritten as the current peak value c.
In S33, if the current peak value c is larger than the VEL obtained in STEP 2, the current peak value c is input to the velocity VEL. If vice versa, this velocity VEL does not change. Next, the flag MT is transferred to the current positive / negative flag b, thereby reversing the pitch change side. This means that the meaning of the flag MT is changed from STEP 4 described later, and means the pitch change side. Then, a period calculation of [t-TFN (b) → TP (b)] is performed in S34. Also, TFN (b) is rewritten with the previous zero cross time data as the current zero cross time t.

次に、S35において、X=0かどうかを判断し、Yの場合にはS36に進み、周波数上限THLIM<前回の周期データTP(b)かどうか、つまりピッチ抽出上限チェックを行い、その結果、最高音の周期より大きな周期をもてば、許容範囲にあるということでYとなり、S37に進む。S37では、トリガー時の周波数下限TTLIM>前回の周期データTP(b)かどうか、つまりピッチ抽出下限チェックを行い、最低音の周期より小の周期をもてば許容範囲にあり、Yの判断をしてS38に進む。S37のピッチ抽出下限は、後述するSTEP4のピッチ抽出下限とは定数が異なる。
具体的には、周波数上限THLIMは、最高音フレットの2〜3半音上の音高周期に相当し、トリガー時の周波数下限TTLIMは、開放弦の開放弦フレットの5半音下の音高周期に相当するものとする。
Next, in S35, it is determined whether or not X = 0. If Y, the process proceeds to S36, where frequency upper limit THLIM <previous period data TP (b) is checked, that is, pitch extraction upper limit is checked. If it has a period larger than the period of the highest sound, it is Y because it is within the allowable range, and the process proceeds to S37. In S37, whether the frequency lower limit TTLIM at the time of trigger> previous cycle data TP (b) is checked, that is, the pitch extraction lower limit is checked. Then, the process proceeds to S38. The pitch extraction lower limit of S37 is different in constant from the pitch extraction lower limit of STEP 4 described later.
Specifically, the upper frequency limit THLIM corresponds to the pitch period 2 to 3 semitones above the highest note fret, and the lower frequency limit TTLIM at the time of triggering is the pitch period 5 semitones below the open string fret of the open string. It shall be equivalent.

S38では、前回の周期データTP(b)を前回抽出された周期データTTPとしてセットすなわち、ピッチ抽出側で抽出されたピッチをセーブ(これは後述するSTEP4で使用される)し、S39に進む。S39では、前回の周期データTP(b)≒TP(b’)かどうか、すなわち極性の違うゼロクロス点間の周期の略一致のチェックである1.5波ピッチ抽出チェックを行い、Yの場合にはS301で次のような処理が行われる。すなわち、前回のゼロクロス時刻データTFN(b’)として時刻記憶レジスタTFRが書替えられ、また今回のゼロクロス時刻tが前回のゼロクロス時刻データTFとしてセットされ、波形ナンバーカウンタHNCをクリアする。このカウンタHNCは後述するSTEP4にて使用される。レジスタSTEPは4にセットされ、ノートオンフラグONFは2(発音状態)にセットされ、定数TTUは0すなわち(MIN)にセットされ、定数TTWは最高MAXにセットされる。これらはいずれも後述するSTEP4にて使用するものである。また、リラティブオフの為の前回波高値レジスタAMRL1がクリアされる。   In S38, the previous cycle data TP (b) is set as the previously extracted cycle data TTP, that is, the pitch extracted on the pitch extraction side is saved (this is used in STEP 4 described later), and the process proceeds to S39. In S39, a 1.5-wave pitch extraction check is performed to check whether the previous cycle data TP (b) ≈TP (b ′), that is, a substantially equal cycle between zero-cross points having different polarities. In S301, the following processing is performed. That is, the time storage register TFR is rewritten as the previous zero cross time data TFN (b '), the current zero cross time t is set as the previous zero cross time data TF, and the waveform number counter HNC is cleared. This counter HNC is used in STEP 4 described later. The register STEP is set to 4, the note-on flag ONF is set to 2 (sounding state), the constant TTU is set to 0, that is, (MIN), and the constant TTW is set to the maximum MAX. These are all used in STEP 4 described later. Also, the previous peak value register AMRL1 for the relative off is cleared.

次にS310で、いま求まったTP(b)の周期データを、Tレジスタへ入力し、S311で音高コードKを求めるサブルーチンPITCHCAL(図15)へジャンプする。
S312では、波高値VEL2に今回波高値cが設定され、S313では、VEL2の値を利用してベロシティVELを補正するためにアフタータッチ情報が音源に出力される。S314では、波高値VEL2がSTEP1の波高値の1/4以下であるかが判断され、Yの場合、すなわちVEL2≦(1/4)VELの場合、ミュートフラグMfに1が設定される。また、S314でNの場合、すなわちVEL2>(1/4)VELの場合、ミュートフラグMfに0が設定される。S314,S315の後、メインルーチンヘリターン(RET)する。
Next, in S310, the period data of TP (b) obtained now is input to the T register, and in S311, the subroutine PITCHCAL (FIG. 15) for obtaining the pitch code K is jumped to.
In S312, the current peak value c is set to the peak value VEL2, and in S313, aftertouch information is output to the sound source in order to correct the velocity VEL using the value of VEL2. In S314, it is determined whether or not the peak value VEL2 is equal to or less than ¼ of the peak value of STEP1, and in the case of Y, that is, when VEL2 ≦ (1/4) VEL, 1 is set to the mute flag Mf. In the case of N in S314, that is, when VEL2> (1/4) VEL, 0 is set to the mute flag Mf. After S314 and S315, return (RET) to the main routine.

図15は、前記S311のサブルーチンの詳細な内容を示している。
マイコンMCPは、まずオクターブ値OCTを0とし(S181)、抽出ピッチデータTがマイコンMCPの内に記憶している音程データ変換テーブル内の基準ピッチデータT0「4525」より小さいか否か判断する(S182)。いま抽出ピッチデータが例えば「9800」であったとすると、このデータT「9800」は基準ピッチデータT0「4525」より大きいので、S183に進み、抽出ピッチデータT「9800」を1/2にして「4900」とし、オクターブ値OCTを−1して「−1」とし(S184)、再びS182に戻って、1/2にした抽出ピッチデータで「4900」が基準ピッチデータT0「4525」より小さいか否か判断する。
FIG. 15 shows the detailed contents of the subroutine of S311.
The microcomputer MCP first sets the octave value OCT to 0 (S181), and determines whether or not the extracted pitch data T is smaller than the reference pitch data T0 “4525” in the pitch data conversion table stored in the microcomputer MCP ( S182). If the extracted pitch data is “9800”, for example, this data T “9800” is larger than the reference pitch data T0 “4525”, so that the process proceeds to S183 and the extracted pitch data T “9800” is halved to “ 4900 ", the octave value OCT is set to -1 to" -1 "(S184), the process returns to S182 again, and is" 4900 "less than the reference pitch data T0" 4525 "in the halved extracted pitch data? Judge whether or not.

今度も基準ピッチデータT0より大きいので、再度S183,S184の処理を繰り返し、抽出ピッチデータTを1/2にして「2450」とし、オクターブ値を−1して「−2」とし、同じく抽出ピッチデータT「2450」が基準ピッチデータT0「4525」より小さいか否か判断する(S182)。   This time, since it is larger than the reference pitch data T0, the processing of S183 and S184 is repeated again, the extraction pitch data T is halved to “2450”, the octave value is −1 to “−2”, and the extraction pitch is also the same. It is determined whether or not the data T “2450” is smaller than the reference pitch data T0 “4525” (S182).

今度は基準ピッチデータT0より小さくなるので、S185に進み、抽出ピッチデータT「2450」が1/2の基準ピッチデータT0「2262.5」より大きいか否か判断する。抽出ピッチデータT「2450」の方が大きいので、S188に進み、上記基準ピッチデータT0「4525」により抽出ピッチデータT「2450」を引いてオクターブ未満の端数データt「2075」を求め、順番データmを「0」とし(S189)、この「0」の順番データmに応じた差分ピッチデータdTm「129」より上記端数データt「2075」が小さいか否か判断する(S190)。   This time, since it becomes smaller than the reference pitch data T0, the process proceeds to S185, and it is determined whether or not the extracted pitch data T “2450” is larger than the half of the reference pitch data T0 “2262.5”. Since the extracted pitch data T “2450” is larger, the process proceeds to S188, and the extracted pitch data T “2450” is subtracted from the reference pitch data T0 “4525” to obtain fractional data t “2075” less than an octave. m is set to “0” (S189), and it is determined whether or not the fraction data t “2075” is smaller than the differential pitch data dTm “129” corresponding to the order data m of “0” (S190).

差分ピッチデータdTmの方が小さいので、S191に進んで、端数データt「2075」より先頭の差分ピッチデータdTm「129」を引いて「1946」とし、順番データmを+1して「1」とする(S192)。そして、端数データtが差分ピッチデータdTmより小さくなるまで、ステップS191,S192の処理を繰り返して、端数データtより差分ピッチデータdTmを順番に引いていく。
そして、差分ピッチデータdTmが「73」まで差し引かれ、順番データmが「21」になると、端数データtが残り「17」となり、次の差分ピッチデータdTm(m=21)「70」より小さくなるので、S193に進み、K=K0+12×OCT+(m+t/dTm)/2=57.0+12×(−2)+(21+17/70)/2=43.62の演算を実行して、新たな音高コードKを求める。この音高はG1♯よりやや上の音高となる。なお、K0はスケールA3の音高コードである。
Since the difference pitch data dTm is smaller, the process proceeds to S191, and the first difference pitch data dTm “129” is subtracted from the fraction data t “2075” to be “1946”, and the order data m is incremented by “1”. (S192). Then, until the fraction data t becomes smaller than the differential pitch data dTm, the processes of steps S191 and S192 are repeated, and the differential pitch data dTm is sequentially subtracted from the fraction data t.
When the difference pitch data dTm is subtracted to “73” and the order data m becomes “21”, the fraction data t remains “17”, which is smaller than the next difference pitch data dTm (m = 21) “70”. Therefore, the process proceeds to S193, and an operation of K = K0 + 12 × OCT + (m + t / dTm) /2=57.0+12× (−2) + (21 + 17/70) /2=43.62 is executed to obtain a new sound. Find the high code K. This pitch is slightly higher than G1 #. K0 is a pitch code of scale A3.

こうして、音程データ変換テーブルに記憶されたA3〜A4の1オクターブ分のピッチの差分データdTmだけで、他のオクターブの音高データを求めることができる。
また、抽出したピッチデータTがl/2の基準ピッチデータT0/2「2262.5」より小さければ、S185〜S187で抽出ピッチデータTが「2262.5」より大きくなるまで2倍(n=1,2,3・・・・・・)していき、以後は上述したS188〜S193の処理を行って、音高データKを求める。
In this way, pitch data of another octave can be obtained from only the difference data dTm of the pitch of one octave A3 to A4 stored in the pitch data conversion table.
Also, if the extracted pitch data T is smaller than the reference pitch data T0 / 2 “2262.5” of l / 2, the extracted pitch data T is increased by 2 n times (n in S185 to S187 until the extracted pitch data T becomes larger than “2262.5”. = 1, 2, 3,...), And thereafter, the processing of S188 to S193 described above is performed to obtain the pitch data K.

以上要約すると、マイコンMCPは、S181〜S187で、抽出ピッチデータTを2倍(n=・・・・・・,−2,−1,0,1,2・・・・・・)して、音程データ変換テーブルに記憶されているピッチデータの範囲内にはいるようにすることにより、このnの値であるオクターブ値OCTを求め、S188〜S192で、上記抽出ピッチデータTのオクターブ未満の端数データと差分ピッチデータdTmの累算データとの対応から音名を求められることになる。 In summary, the microcomputer MCP multiplies the extracted pitch data T by 2n (n =..., -2, -1, 0, 1, 2,...) In S181 to S187. The octave value OCT which is the value of n is obtained by being within the range of the pitch data stored in the pitch data conversion table, and less than the octave of the extracted pitch data T in S188 to S192. The pitch name can be obtained from the correspondence between the fraction data and the accumulated data of the differential pitch data dTm.

また、上記実施例では、音高の表示を、シリアル番号とするようにしたが、オクターブ、音階名(コード)、半音以下のデータにて表現するようにしてもよく、その他どのような表現形態であってもよい。
さらに、上記実施例ではピッチデータを50セント単位(半音の半分)でもつようにしたが、100セント単位(半音毎)にもってもよく、あるいはさらに細分化してもつようにしてもよく、加えて、1オクターブを超えてそのようなデータをもつようにしてもよい。
このようにして、周期データから、対応する音高コードを求めることができ、図14のSTEP3の処理時には、音高コードは、半音以上のものとされ(S311)、発音時の音高はクロマチックに指定されることになる。
In the above embodiment, the pitch is displayed as a serial number. However, it may be expressed by octave, scale name (code), data less than a semitone, and any other expression form. It may be.
Further, in the above embodiment, the pitch data is held in units of 50 cents (half semitone), but may be in units of 100 cents (every semitone), or may be further subdivided. You may have such data in excess of one octave.
In this way, the corresponding pitch code can be obtained from the periodic data. During the processing of STEP 3 in FIG. 14, the pitch code is set to a semitone or more (S311), and the pitch at the time of pronunciation is chromatic. Will be specified.

さて、図14のS30において、Nの場合(同一方向のゼロクロス点検出の場合)は、S303に進み、前回の波高値AMP(b)<今回波高値cかどうかが判断され、Yの場合はS304に進む。S304では、今回波高値cが前回の波高値AMP(b)としてセットされ、ベロシティVELまたはレジスタCの値cの内のいずれか大きい値がべロシティVELにセットされる。S303,S35,S36,S37,S39のいずれの場合もNの場合には、メインルーチンヘリターン(RET)する。   Now, in S30 of FIG. 14, in the case of N (in the case of zero cross point detection in the same direction), the process proceeds to S303, where it is determined whether or not the previous peak value AMP (b) <current peak value c. The process proceeds to S304. In S304, the current peak value c is set as the previous peak value AMP (b), and the larger one of the velocity VEL and the value c of the register C is set to the velocity VEL. If any of S303, S35, S36, S37, and S39 is N, the process returns to the main routine (RET).

S31において、X=1すなわち異常となる場合、(1/8)b1<b0のときと、(1/8)a2<a1のときのジャッジではいずれもその条件を満足せず、X=1となる。
すなわち、波形入力初期等に入力される波形のピークは、ノイズによるもので、これらのノイズの周期を検出して発音開始を指示すると、全くおかしな音が発生してしまう。そこで、S31では、波高値が大きく変わったことを検知して、X=1とし、S35でNの判断をするようにする。そして、S31にて波形が正常な変化をすることが検知されてから、発音開始を指示するようにする。
In S31, when X = 1, that is, when there is an abnormality, the judgment when (1/8) b1 <b0 and (1/8) a2 <a1 do not satisfy the condition, and X = 1. Become.
That is, the peak of the waveform input at the initial stage of waveform input or the like is due to noise, and if the period of these noises is detected and the start of sound generation is instructed, a completely strange sound will be generated. Therefore, in S31, it is detected that the peak value has changed significantly, X = 1, and N is determined in S35. Then, after it is detected in S31 that the waveform changes normally, the start of sound generation is instructed.

ここでは、TP(b)≒TP(b’)の検出がなされたときにノートオンとなる。
以上述べたSTEP3では、MT=1≠b、AMP(0)←c、max[VEL、c(のいずれか大きい方)]→VEL、MT←b=0、TP(0)←[t−TFN(0)]、TFN(0)←t、TTP←TP(0)、TFR←TFN(1)、TF←t、HNC←0、ONF←2、TTU←0(MIN)、TTW←MAX、AMRL1←0、ノートオン条件TP(0)≒TP(1)についての処理がなされる。そして、適切な波形入力に応答してこのSTEP3において、抽出されたピッチに従ったクロマチックな音高の楽音が発生開始されることになる。すなわち、周期検出を開始してから、l.5周期程度の時間経過で発音指示が音源SSに対しなされることになる。
Here, note-on occurs when TP (b) ≈TP (b ′) is detected.
In STEP 3 described above, MT = 1 ≠ b, AMP (0) ← c, max [VEL, c (whichever is greater)] → VEL, MT ← b = 0, TP (0) ← [t−TFN (0)], TFN (0) ← t, TTP ← TP (0), TFR ← TFN (1), TF ← t, HNC ← 0, ONF ← 2, TTU ← 0 (MIN), TTW ← MAX, AMRL1 Processing for ← 0, note-on condition TP (0) ≈TP (1) is performed. Then, in response to an appropriate waveform input, a musical tone having a chromatic pitch according to the extracted pitch is started in STEP3. That is, after the period detection is started, l. A sound generation instruction is given to the sound source SS after about five cycles.

図16は、図8のM9として示すSTEP4のフローチャートであり、この場合ピッチ抽出のみを行うルート(1)、実際にピッチ変更を行うルート(2)がある。先ず、S40,S41,S42,S63〜S67に示すルート(1)について説明する。S40において、波形ナンバーカウンタHNC>3が判断され、Yの場合にはS41に進む。S41では、リラティブオンしきい値TRLRL<[今回波高値c−前回の波高値AMP(b)]かどうかの判断が行われ、Nの場合にはS42に進む。S42では今回正負フラグb=フラグMTつまりピッチ変更側かどうかが判断され、Yの場合にはS43に進む。   FIG. 16 is a flowchart of STEP 4 shown as M9 in FIG. 8. In this case, there is a route (1) for performing only pitch extraction and a route (2) for actually changing the pitch. First, the route (1) shown in S40, S41, S42, and S63 to S67 will be described. In S40, the waveform number counter HNC> 3 is determined. If Y, the process proceeds to S41. In S41, it is determined whether or not the relative on threshold value TRLRL <[current peak value c−previous peak value AMP (b)]. If N, the process proceeds to S42. In S42, it is determined whether or not the current positive / negative flag b = flag MT, that is, the pitch change side. If Y, the process proceeds to S43.

ところで、初期状態では、前記波形ナンバーカウンタHNCは0である(図14のS301参照)ので、S40ではNの判断をしてS42へ進む。そして、例えば、理想的な波形入力の場合は、b=1でMT=0であるから、S42からS63へ進む。   By the way, in the initial state, the waveform number counter HNC is 0 (see S301 in FIG. 14). Therefore, N is determined in S40 and the process proceeds to S42. For example, in the case of an ideal waveform input, since b = 1 and MT = 0, the process proceeds from S42 to S63.

S63においては、同じ極性のピークが続けて入力されてきているか(ダブりであるか)、否かチェックするために、レジスタRIV=1かどうかが判断され、Yの場合にはS68に進み、また、Nの場合(ダブリでない場合)にはS64に進み、ここで以下の処理が行われる。すなわち、S64では今回波高値cが前回の波高値AMP(b)に入力され、リラティブオフ処理のために前回の振幅値AMRL1が前々回の振幅値AMRL2に入力される。なお、いまの場合はAMRL1の内容は0である(STEP3のS30参照)。さらにS64において、前回の波高値AMP(b’)と今回波高値cうちいずれか大きい方が前回振幅値AMRL1に入力される。つまり、周期の中で2つある正,負のピーク値について大きい値のピーク値が振幅値AMRL1にセットされる。そして、S65で波形ナンバーカウンタHNC>8かどうかが判断され、ここで波形ナンバーカウンタ(ピッチ変更側でないゼロクロスカウンタ)NHCが+1され、カウントアップされる。   In S63, it is determined whether or not the register RIV = 1 in order to check whether the same polarity peak has been continuously input (doubled) or not. If Y, the process proceeds to S68. , N (when not double), the process proceeds to S64, where the following processing is performed. That is, in S64, the current peak value c is input to the previous peak value AMP (b), and the previous amplitude value AMRL1 is input to the previous amplitude value AMRL2 for the relative off process. In this case, the content of AMRL1 is 0 (see S30 in STEP 3). Furthermore, in S64, the larger one of the previous peak value AMP (b ') and the current peak value c is input to the previous amplitude value AMRL1. That is, a peak value having a large value for two positive and negative peak values in the cycle is set as the amplitude value AMRL1. Then, in S65, it is determined whether or not the waveform number counter HNC> 8. Here, the waveform number counter (zero cross counter not on the pitch change side) NHC is incremented by 1 and counted up.

従って、波形ナンバーカウンタHNCは、上限が9となる。そして、S65もしくはS66の処理の後S67へ進行する。S67では、レジスタRIVを1とし、今回のゼロクロス時刻tから時刻記憶レジスタTFRの内容を引算して、周期レジスタTTRへ入力する。そして、今回のゼロクロス時刻tは、時刻記憶レジスタTFRへセーブされ、この後、メインルーチンにリターン(RET)する。   Therefore, the upper limit of the waveform number counter HNC is 9. And it progresses to S67 after the process of S65 or S66. In S67, the register RIV is set to 1, and the contents of the time storage register TFR are subtracted from the current zero-crossing time t and input to the period register TTR. Then, the current zero crossing time t is saved in the time storage register TFR, and thereafter, the process returns to the main routine (RET).

S63でYの場合は、S68に進み今回波高値c>前回の波高値AMP(b)かどうかが判断され、Yの場合はS69に進む。S69では、今回波高値cに前回の波高値AMP(b)が書替えられ、S70に進む。S70では今回波高値c>前回の振幅値AMRL1かどうかが判断され、Yの場合にはS71に進み、ここで今回波高値cが前回の振幅値AMRL1に入力される。
もし、S68でNの判断がなされるとすぐにメインルーチンへリターンする。従って、新しい入力波形のピークが大である場合についてのみ、新しい波形の振幅値が登録される。(その場合は、倍音のピークをひろっていないと考えられるので。)
In the case of Y in S63, the process proceeds to S68, and it is determined whether or not the current peak value c> the previous peak value AMP (b). If Y, the process proceeds to S69. In S69, the previous peak value AMP (b) is rewritten to the current peak value c, and the process proceeds to S70. In S70, it is determined whether or not the current peak value c> the previous amplitude value AMRL1, and if Y, the process proceeds to S71, where the current peak value c is input to the previous amplitude value AMRL1.
If N is determined in S68, the process returns to the main routine as soon as possible. Accordingly, only when the peak of the new input waveform is large, the amplitude value of the new waveform is registered. (In that case, it seems that the peak of overtones is not widened.)

また、S70でNのときと、S71の処理の終了のときには、同様にメインルーチンヘリターンする。
以上述べたようにルート(1)は、以下のような処理がなされる。MT=0≠b、RIV=0、AMP(1)←c、AMRL2←AMRL1←max[AMP(0),c(のいずれか大きい方)]、HNC←(HNC+1)=1、RIV←1、TTR←(t−TFR)、TFR←1が処理される。従って、周期レジスタTTRに前回の同極性のゼロクロス点(STEP2→3のところ)から今回のゼロクロス点までの時刻情報の差つまり、周期情報が求まったことになる。そして、メインルーチンヘ戻り、次のゼロクロスインターラプトを待つ。
Similarly, when the answer is N in S70 and when the process of S71 is completed, the process returns to the main routine.
As described above, route (1) is processed as follows. MT = 0 ≠ b, RIV = 0, AMP (1) ← c, AMRL2 ← AMRL1 ← max [AMP (0), c (whichever is greater)], HNC ← (HNC + 1) = 1, RIV ← 1, TTR ← (t−TFR) and TFR ← 1 are processed. Therefore, the difference in time information from the previous zero-crossing point of the same polarity (from STEP2 → 3) to the current zero-crossing point, that is, the period information, is obtained in the period register TTR. Then, the process returns to the main routine and waits for the next zero cross interrupt.

次に、S40〜S62に示すルート(2)へ進んだ場合の説明を行う。いま、波形ナンバーカウンタHNC=1なので(S66参照)、S40からS42へ進む。S42では、MT=0、b=0なのでYとなり、S43へ進む。S43では、レジスタRIV=1かどうかが判断される。既にルート(1)において、レジスタRIVは1とされている(S67参照)ので、S43の判断はいまの場合Yとなり、S44へ進む。   Next, a description will be given of a case where the route proceeds to route (2) shown in S40 to S62. Since the waveform number counter HNC = 1 (see S66), the process proceeds from S40 to S42. In S42, since MT = 0 and b = 0, the result is Y, and the process proceeds to S43. In S43, it is determined whether or not the register RIV = 1. Since the register RIV is already set to 1 in the route (1) (see S67), the determination in S43 is Y in this case, and the process proceeds to S44.

S44では、レジスタSTEP=4かどうかが判断され、Yの場合にはS441に進む。S441では、ミュートフラグMfが1であるかが判断され、Yの場合にはS442に進み、Nの場合にはS45に進む。
S442では、今回波高値cがベロシティVELの1/4以下であるか(c≦(1/4)VEL)が判断され、Yの場合にはS74に進み、Nの場合にはS443に進む。S443では、ミュートフラグMfにゼロを設定し、S45へ進む。
S45では、今回波高値c<60H(Hは16進法表現を示す)かどうかが判断され、いま波高値は大なのでYとなり、S46に進む。S46では、前々回の振幅値AMRL2−前回の振幅値AMRL≦(1/32)×前々回の振幅値AMRL2かどうかが判断され、Yの場合にはS47に進み、リラティブオフカウンタFOFRが0にセットされる。このリラティブオフの処理については後述する。そして、S48では周期計算が行われる。具体的には(今回のゼロクロス時刻t−前回のゼロクロス時刻データTF)が今回の周期情報ttとしてレジスタTOTOにセットされる。そして、S49に進み、S49では、今回の周波数情報tt>周波数上限THLIM(発音開始後の上限)かどうかが判断され、Yの場合にはS50に進む。
In S44, it is determined whether or not the register STEP = 4. If Y, the process proceeds to S441. In S441, it is determined whether the mute flag Mf is 1. If Y, the process proceeds to S442, and if N, the process proceeds to S45.
In S442, it is determined whether or not the current peak value c is ¼ or less of the velocity VEL (c ≦ (1/4) VEL). If Y, the process proceeds to S74, and if N, the process proceeds to S443. In S443, the mute flag Mf is set to zero, and the process proceeds to S45.
In S45, it is determined whether or not the current peak value c <60H (H indicates hexadecimal notation). Since the peak value is now large, the result is Y, and the process proceeds to S46. In S46, it is determined whether or not the previous amplitude value AMRL2−the previous amplitude value AMRL ≦ (1/32) × the previous amplitude value AMRL2, and if Y, the process proceeds to S47 and the relative off counter FOFR is set to 0. The The relative off process will be described later. In S48, a period calculation is performed. Specifically, (current zero crossing time t−previous zero crossing time data TF) is set in the register TOTO as the current cycle information tt. In S49, it is determined whether or not current frequency information tt> frequency upper limit THLIM (upper limit after starting sound generation). If Y, the process proceeds to S50.

S49の周波数上限THLIMは、STEP3のS36で使用したトリガー時(発音開始時)周波数の許容範囲の上限(従って周期として最小で、最高音フレットの2〜3半音上の音高周期に相当する)と同一のものである。
次に、S50では次の処理が行われる。すなわち、レジスタRIVを0にし、今回のゼロクロス時刻tが前回のゼロクロス時刻データTFとして入力され、また前回の波高値AMP(b)が前々回波高値eに入力され、さらに今回波高値cが前回の波高値AMP(b)に入力される。
The frequency upper limit THLIM in S49 is the upper limit of the allowable frequency range at the time of trigger (starting sound generation) used in S36 of STEP 3 (thus, the minimum period corresponds to the pitch period two to three semitones of the highest sound fret). Is the same.
Next, in S50, the following processing is performed. That is, the register RIV is set to 0, the current zero-crossing time t is input as the previous zero-crossing time data TF, the previous peak value AMP (b) is input to the previous peak value e, and the current peak value c is further changed to the previous peak value c. It is input to the peak value AMP (b).

そして、S50の処理の後S51に進み、S51では、周波数下限TLLIM>今回の周期情報ttかどうかが判断され、Yの場合すなわち今回の周期がノートオン中のピッチ抽出音域下限以下になった場合にはS52に進む。
この場合、周波数下限TLLIMは、例えば、開放弦音階の1オクターブ下にセットされる。つまり、STEP3の周波数下限TTLIM(S37参照)に比較して、許容範囲を広くしている。このようにすることで、トレモロアームの操作等による周波数変さらに対応し得るようになる。
従って、周波数の上限、下限について許容範囲に入る場合についてのみS52まで進み、そうでない場合はS49,S51よりメインルーチンへリターンする。
Then, after the process of S50, the process proceeds to S51. In S51, it is determined whether or not the frequency lower limit TLLIM> current cycle information tt. The process proceeds to S52.
In this case, the lower frequency limit TLLIM is set, for example, one octave below the open string scale. That is, the allowable range is widened compared to the lower frequency limit TTLIM (see S37) of STEP3. By doing so, it becomes possible to further cope with frequency changes due to operation of the tremolo arm or the like.
Accordingly, the process proceeds to S52 only when the upper and lower limits of the frequency are within the allowable range. Otherwise, the process returns to the main routine from S49 and S51.

次に、S52では周期データTTPが前々回抽出された周期データhに入力され、また、今回の周期情報ttが前回抽出された周期データTTPに入力される。そして、S53で今回波高値cがベロシティVELに書込まれ、S54に進む。S54では、ノーチェンジレベルNCHLV>(前々回波高値e−今回波高値c)かどうかの判断が行われ、Yの場合にはS55に進む。
すなわち、前回の同極性の波高値(e=AMP(b))と今回の波高値cとが大きく変化している場合は、その差がNCHLVを超えることになり、そのようなときに、抽出された周期情報に基づきピッチ変更を行うと、不自然な音高変化を呈することになる可能性が高い。そこで、S54でNの判断がなされると、S55以降の処理をすることなく、メインルーチンへリターンする。
Next, in S52, the cycle data TTP is input to the cycle data h extracted last time, and the current cycle information tt is input to the cycle data TTP extracted last time. In S53, the current peak value c is written into the velocity VEL, and the process proceeds to S54. In S54, it is determined whether or not the no-change level NCHLV> (previous peak value e−current peak value c). If Y, the process proceeds to S55.
That is, if the previous peak value (e = AMP (b)) of the same polarity and the current peak value c have changed greatly, the difference will exceed NCHLV. If the pitch is changed based on the periodic information, there is a high possibility that an unnatural pitch change will be exhibited. Therefore, if a determination of N is made in S54, the process returns to the main routine without performing the processes in and after S55.

次に、S54でYの場合、S55では、リラティブオフカウンタFOFR=0か否かが判断される。後述するリラティブオフ処理を行っているときは、リラティブオフカウンタFOFRは0でなくなっており、そのような場合もピッチ変更(S602を参照)の処理を行うことなく、S55でNの判断をしてメインルーチンヘリターンする。そして、S55にて、Yの判断をしたときは、S56,S57へと順次進む。
ここで2波3値一致条件が判断される。S56では今回の周期情報tt×2−7>|今回の周期情報tt−前々回周期データh|が判断され、Yの場合にはS57に進み、またS57では今回の周期情報tt×2−7>|今回の周期情報tt−周期レジスタTTRの内容|が判断され、Yの場合にはS58に進む。
Next, in the case of Y in S54, it is determined in S55 whether or not the relative off counter FOFR = 0. When the relative off process described later is being performed, the relative off counter FOFR is not 0, and in such a case, N is determined in S55 without performing the process of changing the pitch (see S602). Return to the main routine. When the determination of Y is made in S55, the process proceeds to S56 and S57 in order.
Here, the two-wave ternary matching condition is determined. In S56, current cycle information tt × 2 −7 > | current cycle information tt−previous cycle data h | is determined. If Y, the process proceeds to S57. In S57, current cycle information tt × 2 −7 > The current cycle information tt—the contents of the cycle register TTR | is determined. If Y, the process proceeds to S58.

すなわち、S56では、今回の周期情報tt(S43参照)が、前回の周期データh(=TTP)(S52参照)の値と略一致するか否かを判断し、S57では、今回の周期情報ttの値が、それに重なる周期でTTRとほぼ一致するか否かを判断する。なお、その限界範囲は、2−7×ttとして周期情報に依存してその値が変わるようになっている。勿論、これは固定の値としてもよいが、本実施形態採用技術の方が良好な結果を得ることができる。 That is, in S56, it is determined whether or not the current cycle information tt (see S43) substantially matches the value of the previous cycle data h (= TTP) (see S52). In S57, the current cycle information tt It is determined whether or not the value of T is substantially equal to TTR in a period overlapping therewith. The limit range is 2 −7 × tt, and its value changes depending on the period information. Of course, this may be a fixed value, but a better result can be obtained by the technique employing the present embodiment.

次のS58では、今回の周期情報tt>定数TTUかどうかが判断され、YならばS59に進み、ここで今回の周期情報tt<定数TTWかどうかが判断され、YならばS60へ進む。なお、S58,S59は急激なピッチ変更を認めないための判断である。   In next S58, it is determined whether or not current cycle information tt> constant TTU. If Y, the process proceeds to S59. Here, it is determined whether current cycle information tt <constant TTW, and if Y, the process proceeds to S60. Note that S58 and S59 are judgments for preventing a rapid pitch change.

つまり、S58の定数TTUは、STEP3のS301でいま0とされ、定数TTWは同様にMAXの値とされており、初めてこのフローを通るときは必ずS58,S59でYの判断がなされるが、その後は後述するS62において、定数TTUには、(17/32)tt(略1オクターブ高音の周期情報)がセットされ、定数TTWには同様にS62にて(31/16)tt(ほぼ1オクターブ低音の周期情報)がセットされる。従って、急激にオクターブアップする(これは、フレットを離してミュート操作したとき等に生ずる)ことやオクターブダウンすること(これは波形のピークをとり逃したとき等に起る)があったときは、ピッチ変更をすると、不自然となるので、ピッチ変更をしないようにブランチする。   That is, the constant TTU of S58 is set to 0 at S301 of STEP3, and the constant TTW is similarly set to the value of MAX. When this flow is first passed for the first time, a determination of Y is always made at S58 and S59. Thereafter, in S62, which will be described later, (17/32) tt (approximately 1 octave treble period information) is set in the constant TTU, and (31/16) tt (approximately 1 octave) in S62 in the same manner in the constant TTW. Low frequency information) is set. Therefore, when there is a sudden octave up (this occurs when the mute operation is performed with the frets released) or an octave down (this occurs when a waveform peak is missed, etc.) If the pitch is changed, it becomes unnatural, so the branch is made so as not to change the pitch.

もし、S58,S59でYの判断がなされたときは、次にS60へ進む。S60では、レジスタSTEP=4にされたかどうかの判断が行われ、Yの場合には、S601へ進み、周期情報ttをレジスタTへセットし、S602にて音高コードを求める。このS602は、上述したS311と同様の音高コードを求めるサブルーチンPITCHCAL(図15)の実行を意味する。   If YES is determined in S58 and S59, the process proceeds to S60. In S60, it is determined whether or not the register STEP = 4 is set. If Y, the process proceeds to S601, the period information tt is set in the register T, and the pitch code is obtained in S602. S602 means execution of a subroutine PITCHCAL (FIG. 15) for obtaining a pitch code similar to S311 described above.

その結果、半音未満の音高コードを含む音高コードKが得られ、それをもって、音源SSに対しピッチ変更指示をする。
次にS62に進み、今回の周期情報ttに対応して時定数チェンジをし、また定数TTUが(17/32)×今回の周期情報ttに書替えられ、さらに定数TTTWが(31/16)×今回の周期情報ttに書替えられる。
As a result, a pitch code K including a pitch code of less than a semitone is obtained, and a pitch change instruction is given to the sound source SS.
Next, in S62, the time constant is changed corresponding to the current cycle information tt, the constant TTU is rewritten to (17/32) × current cycle information tt, and the constant TTTW is also (31/16) ×. It is rewritten to the current cycle information tt.

つまり、後述するように、リラティブオフの処理がなされたときに限り、STEP=5となるが、そのときは、ピッチ変更を行うことなく時定数チェンジを行う。この時定数チェンジの処理とは、レジスタに今回の周期情報ttの値に基づくデータをマイコンMCPがセットすることをいう。これは、既に説明したとおりである。   That is, as will be described later, STEP = 5 only when the relative-off process is performed. At that time, the time constant is changed without changing the pitch. This process of changing the time constant means that the microcomputer MCP sets data based on the value of the current cycle information tt in a register. This is as already described.

そして、S62の処理の終了でメインルーチンヘリターンする。従って、以上述べたようにルート(2)は、次の処理がなされる。
すなわち、HNC=1、MT=0=b、RIV=1、FOFR←0、tt←(t−TF)、RIV←0、TF←t、e←AMP(0)、AMP(0)←c、h←TTP、TTP←tt、VEL←cであり、
Then, the process returns to the main routine at the end of the process of S62. Therefore, as described above, the route (2) is subjected to the following processing.
That is, HNC = 1, MT = 0 = b, RIV = 1, FOFR ← 0, tt ← (t−TF), RIV ← 0, TF ← t, e ← AMP (0), AMP (0) ← c, h ← TTP, TTP ← tt, VEL ← c,

さらに、
(1)TTP≒TTR≒tt、
(2)TTU<tt<TTW、
(3)AMP(0)−c<NCHLV
の3条件の満足で、ttに従った半音未満(100セント未満)の音高変更も含むピッチ変更を行う。しかる後、TTU←(17/32)×tt、TTW←(31/16)×ttがなされる。
further,
(1) TTP≈TTR≈tt,
(2) TTU <tt <TTW,
(3) AMP (0) -c <NCHLV
When the three conditions are satisfied, the pitch is changed including the pitch change of less than a semitone (less than 100 cents) according to tt. Thereafter, TTU ← (17/32) × tt and TTW ← (31/16) × tt are made.

従って、ルート(2)にて、実際の音源SSに対するピッチ変更が行われ、続くゼロクロスインタラプトでルート(1)の処理、同様に、続くゼロクロスインタラプトで、ルート(2)の処理が行われる。このようにして、ルート(1)では、単に周期を抽出(S67参照)し、ルート(2)では実際のピッチ変更(S602参照)し、時定数チェンジ処理(S62参照)が行われることになる。   Accordingly, the pitch change for the actual sound source SS is performed in the route (2), and the processing of the route (1) is performed at the subsequent zero cross interrupt, and similarly the processing of the route (2) is performed at the subsequent zero cross interrupt. In this way, in the route (1), the period is simply extracted (see S67), in the route (2), the actual pitch is changed (see S602), and the time constant change process (see S62) is performed. .

なお、STEP4におけるS40において、ルート(1)のS66で波形ナンバーカウンタHNCが3を超えるように、カウントアップされた後は、Yの判断がなされ、次にS41へ行き、リラティブオンの条件を検出する。これは、c−AMP(b)>TRLRLであり、前回の振幅値AMRL1に比べて今回の振幅値がしきい値TRLRLを超えて増大したとき、つまり、これは弦操作後に同じ弦を市政ピッキングしたとき(トレモロ奏法等による)にこのようなことがおき、この場合はS41でリラティブオンの処理をすべくS41からS78へ進み、時定数変換制御回路TTCの時定数チェンジレジスタCHTRRへ最高音フレット(例えば22フレット)の周期CHTIMをセットする。しかる後、図16のS60へ進み、当該発音中の楽音をノートオフした後、再発音開始する。   In S40 in STEP 4, after counting up so that the waveform number counter HNC exceeds 3 in S66 of route (1), a determination of Y is made, and then the process goes to S41 to detect the condition of relative on To do. This is c-AMP (b)> TRRLL, and when the current amplitude value exceeds the threshold value TRLRL as compared to the previous amplitude value AMRL1, that is, this is the same string picking after the string operation. When this occurs (according to the tremolo technique, etc.), in this case, in S41, the process proceeds from S41 to S78 to perform the relative on process, and the highest sound fret is sent to the time constant change register CHTRR of the time constant conversion control circuit TTC. Set period CHTIM (for example, 22 frets). Thereafter, the process proceeds to S60 in FIG. 16, where the sounding sound that is being generated is note-off, and then re-sounding is started.

通常の演奏操作によれば、S40,S41,S42へ進み、上述したルート(1)もしくはルート(2)へ進む。
次に、リラティブオフ処理を説明する。つまり、フレット操作している状態から、開放弦状態へ移行すると、波形の振幅レベルは急激に落ちてきて、前々回の波高値AMRL2と前回の波高値AMRL1との差が(1/32)AMRL2を超えるようになると、S46からS74へ進む。そして、リラティブオフカウンタFOFRが定数ROFCTを超えるまでカウントアップするようにS74からS75へ進む。このとき、S75からS48へ行きS49〜S55の処理を行うが、FOFR=0でないので、リラティブオフ処理に入る直前ではピッチ変更を行うことなくメインルーチンへ戻る。
According to the normal performance operation, the process proceeds to S40, S41, S42, and proceeds to the route (1) or the route (2) described above.
Next, the relative off process will be described. That is, when the state of fret operation is shifted to the open string state, the amplitude level of the waveform drops rapidly, and the difference between the previous peak value AMRL2 and the previous peak value AMRL1 is (1/32) AMRL2. If it exceeds, the process proceeds from S46 to S74. Then, the process proceeds from S74 to S75 so as to count up until the relative off counter FOFR exceeds the constant ROFCT. At this time, the process goes from S75 to S48 to perform the processes of S49 to S55. However, since FOFR = 0 is not satisfied, the process returns to the main routine without changing the pitch immediately before entering the relative off process.

そして、S74でYと判断すると、FOFRの値が3となったとき(ROFCTは2である)、S74からS75へ行く。
ただし、S46のジャッジでYの判断が一度でもあると、S46からS47へ進み、FOFRをリセットするようになる。従って、ROFCTで指定される回数だけ続けてS46の条件を満足しなければ、リラティブオフの処理はなされない。なお、ROFCTの値は、音高が高い弦について大きな値としておけば、略一定の時間経過で、いずれの弦についてもリラティブオフ処理ができる。
If it is determined as Y in S74, when the value of FOFR becomes 3 (ROFCT is 2), the process proceeds from S74 to S75.
However, if the judgment of Y is once even at the judgment of S46, the process proceeds from S46 to S47 and the FOFR is reset. Therefore, if the condition of S46 is not satisfied continuously for the number of times specified by ROFCT, the relative off process is not performed. In addition, if the value of ROFCT is set to a large value for a string with a high pitch, the relative off processing can be performed for any string in a substantially constant time.

そして、S74からS76へ行くと、リラティブオフカウンタFOFRをリセットし、レジスタSTEPを5とし、S77へ進んで音源SSに対しノートオフを指示する。このSTEPが5の状態では、ピッチ抽出処理をSTEP4の時と同様に実行するが、S60からS601、S602を介することなくS62へ進むので、音源SSに対しては、ピッチ変更はされない。ただし、S62において抽出した周期に従って時定数チェンジ処理を行う。   When the process goes from S74 to S76, the relative off counter FOFR is reset, the register STEP is set to 5, and the process goes to S77 to instruct the sound source SS to perform note-off. In this state of STEP 5, the pitch extraction process is executed in the same manner as in STEP 4, but since the process proceeds from S60 to S62 without going through S601 and S602, the pitch is not changed for the sound source SS. However, the time constant change process is performed according to the period extracted in S62.

そして、STEPが5の状態では、リラティブオンの処理を受付けるが(S41,S78)、それ以外の場合では、図8のメインルーチンの中で、振動レベルが減少してきたことが検知されることによりM14でSTEPが0となり、初期状態に戻る。
なお、S46で使用するAMRL1、AMRL2はS64で作られており、1周期の中でレベルが大な方のピーク(最大ピークと最小ピークとの一方)が、この値とされ、最大ピークaが最小ピークb−1より必ず大である場合であって、an+1とan+2、an+2とan+3、an+3とan+4の差がいずれも所定値を超えるようになっている。
When the STEP is 5, the relative on process is accepted (S41, S78). In other cases, it is detected in the main routine of FIG. 8 that the vibration level has decreased. At M14, STEP becomes 0 and the initial state is restored.
The AMRL1 and AMRL2 used in S46 are created in S64, and the peak with the larger level (one of the maximum peak and the minimum peak) in one cycle is set to this value, and the maximum peak a k Is always larger than the minimum peak b K −1, and the difference between an + 1 and an + 2, an + 2 and an + 3, and an + 3 and an + 4 all exceed a predetermined value.

また、このときルート(2)の処理においては、最小ピークbn+1、bn+2、bn+3が極端に減少してきているので、S54でNの判断が成されて、メインルーチンヘリターンし、ピッチ変更処理はなされない。
次に、ピッチ抽出しているなかで、オクターブ関係にある倍音、つまりオクターブ高い音やオクターブ低い音が続けて検出されたときの処理について説明する。
At this time, in the processing of the route (2), since the minimum peaks bn + 1, bn + 2, and bn + 3 are extremely decreased, the determination of N is made in S54, the process returns to the main routine, and the pitch changing process is not performed. Not.
Next, a description will be given of processing when an overtone having an octave relation, that is, an octave higher sound or a lower octave sound is continuously detected during pitch extraction.

既に説明したように、S58ではttがTTUを超えなかったとき、つまり、前回抽出した周期の17/32倍した値TTUより小になったとき、S76へ進む。つまり、オクターブ高い音が抽出されたときは、指定していたフレットから指を離してミュート操作をした場合とみなし、オクターブ高い音を出力することなく、S58からS76へ行き、リラティブオフ時同様S76,S77の処理によって当該音の発音を停止する。
また、S59では、ttがTTWを超えなかったとき、つまり前回抽出した周期の31/16倍した値TTWより大となったとき、S60へ進むことなく、メインルーチンへリターンする。
As already described, when the tt does not exceed the TTU in S58, that is, when it becomes smaller than the value TTU that is 17/32 times the previously extracted period, the process proceeds to S76. In other words, when a sound with a high octave is extracted, it is considered that the mute operation is performed by releasing the finger from the designated fret, and the process goes from S58 to S76 without outputting a high octave sound. , S77 stops the sound generation.
In S59, when tt does not exceed TTW, that is, when it becomes larger than the value TTW which is 31/16 times the previously extracted period, the process returns to the main routine without proceeding to S60.

通常ノートオフ近辺の非常に波形が小さい場合、他のピッキングによってヘキサピックアップのクロストオークやボディの共振によって波形が乗ってくる。すると、1オクターブ下の入力波形が続けて検出されてしまうことがある。
このような場合、何等処理を施さないと、急にオクターブ下の音を出力してしまい、極めて不自然となる。そのために、S57,S56でTan+2≒Tan+3≒Tbn+2が検出されても、Tan+3>Tan+1×(31/16)となるので、ピッチ変更することなく、S59からメインルーチンヘリターンする。
Normally, when the waveform is very small near the note-off, the waveform is picked up by the picking up crosstalk or the resonance of the body due to other picking. Then, an input waveform that is one octave below may be detected continuously.
In such a case, if no processing is performed, a sound under octave is suddenly output, which is extremely unnatural. For this reason, even if Tan + 2≈Tan + 3≈Tbn + 2 is detected in S57 and S56, Tan + 3> Tan + 1 × (31/16), so that the routine returns from S59 to the main routine without changing the pitch.

次に、ダブリの波形が抽出される場合つまり、同じ極性のゼロクロス点が拭けて到来する場合について説明する。MT=1の場合の例を考えると、基本波周期と倍音成分の周期が非整数倍の関係にあるので、倍音の位相がずれて行き、同じ極性のゼロクロスを検出してしまうことになり、そのために誤ったピッチ変更をしないようにしないといけない。
そこで、図のダブリと書いてあるゼロクロス時のSTEP4の処理では、S42からS43へ行き、S43ではYの判断をしてS72へ行く。ここで、(an+3)と(an+2)の大きさが比較され、もし(an+3)が(an+2)より大であれば、S72でYの判断をし、AMP(1)に、(an+3)の値をセットし、もし逆の場合は何等変更処理をしない。
Next, a case where a double waveform is extracted, that is, a case where a zero-cross point having the same polarity is wiped out will be described. Considering an example in the case of MT = 1, since the fundamental wave period and the period of the harmonic component are in a non-integer multiple relationship, the phase of the harmonic will be shifted, and a zero cross of the same polarity will be detected. For this reason, it is necessary to prevent incorrect pitch changes.
Therefore, in the process of STEP 4 at the time of zero crossing, which is written as “double” in the figure, the process goes from S42 to S43, and in S43, the determination of Y is made and the process goes to S72. Here, the magnitudes of (an + 3) and (an + 2) are compared. If (an + 3) is larger than (an + 2), a determination of Y is made in S72, and the value of (an + 3) is set in AMP (1). If the reverse is true, no change processing is performed.

ところで、このダブリの場合抽出している時刻データは何等使用しないので、周期情報Tan+3は何等変わらない。また、当然周期データに基づくピッチ変更は行わない。
同様に、波形のダブリの場合の例、すなわちMT=0の状態では、ダブリの状態が生じているときに、S42からS63へ行き、Yの判断をしてS68へ行く。S68では、いまの場合(an+2)と(an+3)との比較をして、(an+3)が(an+2)より大なときに限りS69へ行き、AMP(1)を書替える。この場合は、さらに前回の振幅値AMRL1と今回の振幅情報(波高値c)の比較をS70で行って、もしYならばS71へ進み、今回の振幅情報cを前回の振幅値AMRL1へセットする。
このようにして、倍音の影響で、波形がダブったときにも、S56,S57を満足しない限りピッチ変更処理はなされないことになる。
By the way, since the extracted time data is not used in the case of this double, the cycle information Tan + 3 is not changed at all. Of course, the pitch is not changed based on the period data.
Similarly, in the case of a double wave, that is, in a state where MT = 0, when a double state occurs, the process goes from S42 to S63, and the determination of Y is made, and the process goes to S68. In S68, (an + 2) is compared with (an + 3) in this case, and only when (an + 3) is larger than (an + 2), the process goes to S69 to rewrite AMP (1). In this case, the previous amplitude value AMRL1 is compared with the current amplitude information (crest value c) in S70. If Y, the process proceeds to S71, and the current amplitude information c is set to the previous amplitude value AMRL1. .
In this way, even when the waveform is doubled due to the influence of overtones, the pitch changing process is not performed unless S56 and S57 are satisfied.

以上述べたように、本実施形態に係る電子ギター1は、フレットスキャン部FSと、ピッチ抽出回路PCと、マイコンMCPとを備えている。フレットスキャン部FSは、指板上における押弦操作に基づいて発生すべき楽音の音高を決定し、ピッチ抽出回路PCは、張設された弦の振動を検出する。また、マイコンMCPは、検出された弦の振動のレベルが第1のしきい値を超えたか否か判別する。そして、マイコンMCPは、第1のしきい値を超えたと判別された第1の区間における弦の振動のレベルと、当該第1の区間に続く第2の区間における弦の振動のレベルとに基づいて決定した第1の音量で、決定された音高の楽音を発生させる制御を行う。さらに、マイコンMCPは、第2の区間に続く第3の区間以降における弦の振動のレベルに基づいて、第1の音量を補正する。   As described above, the electronic guitar 1 according to this embodiment includes the fret scan unit FS, the pitch extraction circuit PC, and the microcomputer MCP. The fret scanning unit FS determines the pitch of a musical sound to be generated based on the string pressing operation on the fingerboard, and the pitch extraction circuit PC detects vibration of the stretched string. Further, the microcomputer MCP determines whether or not the detected vibration level of the string exceeds the first threshold value. Then, the microcomputer MCP is based on the level of string vibration in the first section determined to exceed the first threshold and the level of string vibration in the second section following the first section. Control is performed to generate a musical tone having the determined pitch at the first volume determined in the above. Further, the microcomputer MCP corrects the first volume based on the vibration level of the string in the third and subsequent sections following the second section.

そのため、ピッキングが行われた直後の弦の振動のレベルに応じた音量で、早期に楽音を発生させることができるとともに、弦の振動が安定した区間における弦の振動のレベルに応じた音量に補正することができる。
従って、電子弦楽器による楽音の発生の遅れを抑制しつつ、発生される楽音の強さをより適切なものとすることができる。
Therefore, it is possible to generate a musical tone at an early stage with the volume corresponding to the string vibration level immediately after picking, and to correct the volume according to the string vibration level in the section where the string vibration is stable. can do.
Therefore, the intensity of the generated musical sound can be made more appropriate while suppressing the delay of the musical sound generated by the electronic stringed instrument.

また、マイコンMCPは、第3の区間以降に前記検出された弦の振動が、第1の音量よりも、第2のしきい値以上小さい期間が所定期間継続した場合に、楽音の発生をミュートさせる。
そのため、弾弦された後に、弦を抑える等によってミュートが行われたことを検出することができるため、種々の奏法に対して、適切な音量の楽音を発生させることができる。
Further, the microcomputer MCP mutes the generation of a musical tone when the detected vibration of the string after the third interval continues for a predetermined period that is smaller than the first volume by a second threshold or more. Let
For this reason, it is possible to detect that the mute has been performed after the string is played, for example, by suppressing the string, so that it is possible to generate a musical sound having an appropriate volume for various playing methods.

また、マイコンMCPは、楽音の発生をミュートさせた後、検出された弦の振動が、第1の音量よりも、第3のしきい値以上小さい状態でなくなった場合、ミュートを解除する。
そのため、ミュートが終了したことを速やかに検出して、弦の振動に応じた音量で楽音の発生を行うことができるため、演奏において違和感が生じることを抑制できる。
Further, the microcomputer MCP cancels the mute when the detected vibration of the string is not smaller than the first sound volume by the third threshold value after the generation of the musical sound is muted.
Therefore, it is possible to promptly detect the end of mute and generate a musical sound with a volume corresponding to the vibration of the strings, so that it is possible to suppress a sense of incongruity during performance.

なお、前記実施例においては、最大ピーク点、最小ピーク点の次のゼロクロス点毎の間隔から周期抽出を行うようにしたが、その他の方式、例えは最大ピーク点間や最小ピーク点間の時間間隔から周期抽出を行ってもよい。また、それに合わせて回路構成は種々変更し得る。
また、前記実施例においては、この発明を電子ギター(ギターシンセサイザ)に適用したものであったが、それに限らない。ピッチ抽出を行って、オリジナルの信号とは別の音響信号を発生するタイプの楽器または装置であれば、種々適用可能である。
In the above embodiment, the period is extracted from the interval of each zero cross point next to the maximum peak point and the minimum peak point. However, other methods, for example, the time between the maximum peak points and the time between the minimum peak points are used. Period extraction may be performed from the interval. Further, the circuit configuration can be variously changed in accordance with it.
In the above embodiment, the present invention is applied to an electronic guitar (guitar synthesizer). However, the present invention is not limited to this. Any instrument or device of a type that performs pitch extraction and generates an acoustic signal different from the original signal can be applied.

上述した一連の処理は、ハードウェアにより実行させることもできるし、ソフトウェアにより実行させることもできる。
換言すると、図2及び図4等の構成は例示に過ぎず、特に限定されない。すなわち、上述した一連の処理を全体として実行できる機能が電子ギター1に備えられていれば足り、この機能を実現するためにどのような機能構成及び回路構成とするかは特に図2及び図4の例に限定されない。
また、1つの機能ブロックは、ハードウェア単体で構成してもよいし、ソフトウェア単体で構成してもよいし、それらの組み合わせで構成してもよい。
The series of processes described above can be executed by hardware or can be executed by software.
In other words, the configurations of FIGS. 2 and 4 are merely examples, and are not particularly limited. That is, it is sufficient that the electronic guitar 1 has a function capable of executing the above-described series of processing as a whole, and what functional configuration and circuit configuration are used in order to realize this function are particularly shown in FIGS. It is not limited to the example.
In addition, one functional block may be constituted by hardware alone, software alone, or a combination thereof.

一連の処理をソフトウェアにより実行させる場合には、そのソフトウェアを構成するプログラムが、コンピュータ等にネットワークや記録媒体からインストールされる。
コンピュータは、専用のハードウェアに組み込まれているコンピュータであってもよい。また、コンピュータは、各種のプログラムをインストールすることで、各種の機能を実行することが可能なコンピュータ、例えば汎用のパーソナルコンピュータであってもよい。
When a series of processing is executed by software, a program constituting the software is installed on a computer or the like from a network or a recording medium.
The computer may be a computer incorporated in dedicated hardware. The computer may be a computer capable of executing various functions by installing various programs, for example, a general-purpose personal computer.

このようなプログラムを含む記録媒体は、ユーザにプログラムを提供するために装置本体とは別に配布されるリムーバブルメディアにより構成されるだけでなく、装置本体に予め組み込まれた状態でユーザに提供される記録媒体等で構成される。リムーバブルメディアは、例えば、磁気ディスク(フロッピディスクを含む)、光ディスク、または光磁気ディスク等により構成される。光ディスクは、例えば、CD−ROM(Compact Disk−Read Only Memory),DVD(Digital Versatile Disk),Blu−ray Disc(ブルーレイディスク)(登録商標)等により構成される。光磁気ディスクは、MD(Mini−Disk)等により構成される。また、装置本体に予め組み込まれた状態でユーザに提供される記録媒体は、例えば、プログラムが記録されているROMやハードディスク等で構成される。   A recording medium including such a program is provided not only to a removable medium distributed separately from the apparatus main body in order to provide the program to the user, but also to the user in a state of being incorporated in the apparatus main body in advance. It consists of a recording medium. The removable medium is composed of, for example, a magnetic disk (including a floppy disk), an optical disk, a magneto-optical disk, or the like. The optical disc is composed of, for example, a CD-ROM (Compact Disk-Read Only Memory), a DVD (Digital Versatile Disc), a Blu-ray Disc (Blu-ray Disc) (registered trademark), and the like. The magneto-optical disk is configured by an MD (Mini-Disk) or the like. In addition, the recording medium provided to the user in a state of being preinstalled in the apparatus main body is configured by, for example, a ROM or a hard disk in which a program is recorded.

なお、本明細書において、記録媒体に記録されるプログラムを記述するステップは、その順序に沿って時系列的に行われる処理はもちろん、必ずしも時系列的に処理されなくとも、並列的あるいは個別に実行される処理をも含むものである。   In the present specification, the step of describing the program recorded on the recording medium is not limited to the processing performed in chronological order according to the order, but is not necessarily performed in chronological order, either in parallel or individually. The process to be executed is also included.

以上、本発明のいくつかの実施形態について説明したが、これらの実施形態は、例示に過ぎず、本発明の技術的範囲を限定するものではない。本発明はその他の様々な実施形態を取ることが可能であり、さらに、本発明の要旨を逸脱しない範囲で、省略や置換等種々の変更を行うことができる。これら実施形態やその変形は、本明細書等に記載された発明の範囲や要旨に含まれるとともに、特許請求の範囲に記載された発明とその均等の範囲に含まれる。   As mentioned above, although several embodiment of this invention was described, these embodiment is only an illustration and does not limit the technical scope of this invention. The present invention can take other various embodiments, and various modifications such as omission and replacement can be made without departing from the gist of the present invention. These embodiments and modifications thereof are included in the scope and gist of the invention described in this specification and the like, and are included in the invention described in the claims and the equivalent scope thereof.

以下に、本願の出願当初の特許請求の範囲に記載された発明を付記する。
[付記1]
指板上における押弦操作に基づいて発生すべき楽音の音高を決定する音高決定手段と、
張設された弦の振動を検出する弦振動検出手段と、
前記検出された弦の振動のレベルが第1のしきい値を超えたか否か判別する第1の判別手段と、
前記第1のしきい値を超えたと判別された第1の区間における弦の振動のレベルと、当該第1の区間に続く第2の区間における弦の振動のレベルとに基づいて決定した第1の音量で、前記決定された音高の楽音を発生させる制御を行う制御手段と、
前記第2の区間に続く第3の区間以降における弦の振動のレベルに基づいて、前記第1の音量を補正する補正手段と、
を有する電子弦楽器。
[付記2]
前記制御手段は、前記第3の区間以降に前記検出された弦の振動が、前記第1の音量よりも、第2のしきい値以上小さい期間が所定期間継続した場合に、楽音の発生をミュートさせる付記1に記載の電子弦楽器。
[付記3]
前記制御手段は、前記楽音の発生をミュートさせた後、前記検出された弦の振動が、前記第1の音量よりも、第3のしきい値以上小さい状態でなくなった場合、ミュートを解除する付記2に記載の電子弦楽器。
[付記4]
張設された弦の振動を検出する弦振動検出手段を有する電子弦楽器に用いられる楽音制御方法であって、
指板上における押弦操作に基づいて発生すべき楽音の音高を決定し、
前記検出された弦の振動のレベルが第1のしきい値を超えたか否か判別し、
前記第1のしきい値を超えたと判別された第1の区間における弦の振動のレベルと、当該第1の区間に続く第2の区間における弦の振動のレベルとに基づいて決定した第1の音量で、前記決定された音高の楽音を発生させる制御を行い、
前記第2の区間に続く第3の区間以降における弦の振動のレベルに基づいて、前記第1の音量を補正する、楽音制御方法。
[付記5]
張設された弦の振動を検出する弦振動検出手段を有する電子弦楽器に用いられるコンピュータに、
指板上における押弦操作に基づいて発生すべき楽音の音高を決定する音高決定ステップと、
前記検出された弦の振動のレベルが第1のしきい値を超えたか否か判別する第1の判別ステップと、
前記第1のしきい値を超えたと判別された第1の区間における弦の振動のレベルと、当該第1の区間に続く第2の区間における弦の振動のレベルとに基づいて決定した第1の音量で、前記決定された音高の楽音を発生させる制御を行う制御ステップと、
前記第2の区間に続く第3の区間以降における弦の振動のレベルに基づいて、前記第1の音量を補正する補正ステップと、
を実行させるプログラム。
The invention described in the scope of claims at the beginning of the filing of the present application will be appended.
[Appendix 1]
A pitch determining means for determining a pitch of a musical tone to be generated based on a string pressing operation on the fingerboard;
A string vibration detecting means for detecting vibration of the stretched string;
First discriminating means for discriminating whether or not the detected level of vibration of the string exceeds a first threshold value;
The first value determined based on the level of string vibration in the first section determined to exceed the first threshold and the level of string vibration in the second section following the first section. Control means for performing control to generate a musical tone of the determined pitch at a volume of
Correction means for correcting the first volume based on the vibration level of the string in the third and subsequent sections following the second section;
Electronic stringed instrument with
[Appendix 2]
The control means generates a musical tone when the vibration of the detected string after the third interval continues for a predetermined period that is smaller than the first volume by a second threshold value or more. The electronic stringed instrument according to appendix 1, which is muted.
[Appendix 3]
The control means cancels mute when the occurrence of the musical sound is muted and the detected vibration of the string is not smaller than the first sound volume by a third threshold value or more. The electronic stringed instrument according to appendix 2.
[Appendix 4]
A musical tone control method used for an electronic stringed instrument having a string vibration detecting means for detecting vibration of a stretched string,
Determine the pitch of the musical sound that should be generated based on the string-pressing operation on the fingerboard,
Determining whether the detected string vibration level exceeds a first threshold;
The first value determined based on the level of string vibration in the first section determined to exceed the first threshold and the level of string vibration in the second section following the first section. Control to generate a musical tone of the determined pitch at a volume of
A musical tone control method for correcting the first sound volume based on a vibration level of a string in a third and subsequent sections following the second section.
[Appendix 5]
In a computer used for an electronic stringed instrument having string vibration detection means for detecting vibration of a stretched string,
A pitch determination step for determining a pitch of a musical sound to be generated based on a string pressing operation on the fingerboard;
A first determination step of determining whether or not the detected level of vibration of the string exceeds a first threshold value;
The first value determined based on the level of string vibration in the first section determined to exceed the first threshold and the level of string vibration in the second section following the first section. A control step for performing control to generate a musical tone of the determined pitch at a volume of
A correction step of correcting the first volume based on the vibration level of the string in the third and subsequent sections following the second section;
A program that executes

1・・・電子ギター、PG・・・スキャンパルス発生器、FS・・・フレットスキャン部、FDC・・・フレット検出回路、PC・・・ピッチ抽出回路、LPF・・・ローパスフィルタ、AMC・・・増幅回路、ZCR・・・ゼロクロス点取込回路、ABS・・・絶対値取込回路、FB・・・指板、MCP・・・マイコン、IC・・・割込制御回路、TMR・・・タイマー、A/D・・・アナログ−デジタル変換回路、MEM・・・メモリ、SOB・・・音源発生装置、SS・・・音源、D/A・・・デジタル−アナログ変換回路、AMC・・・増幅回路、DCD・・・アドレスデコーダ   DESCRIPTION OF SYMBOLS 1 ... Electronic guitar, PG ... Scan pulse generator, FS ... Fret scan part, FDC ... Fret detection circuit, PC ... Pitch extraction circuit, LPF ... Low pass filter, AMC ... Amplification circuit, ZCR ... Zero cross point acquisition circuit, ABS ... Absolute value acquisition circuit, FB ... Fingerboard, MCP ... Microcomputer, IC ... Interrupt control circuit, TMR ... Timer, A / D ... Analog-to-digital conversion circuit, MEM ... Memory, SOB ... Sound source generator, SS ... Sound source, D / A ... Digital-to-analog conversion circuit, AMC ... Amplifier circuit, DCD ... Address decoder

Claims (5)

指板上における押弦操作に基づいて発生すべき楽音の音高を決定する音高決定手段と、
張設された弦の振動を検出する弦振動検出手段と、
前記弦の振動に応じた波形信号における或るゼロクロス点を示す第1ゼロクロス点から前記第1ゼロクロス点の次のゼロクロス点を示す第2ゼロクロス点までの第1の区間で、前記弦の振動のレベルが第1のしきい値を超えたか否か判別する第1の判別手段と、
前記第1のしきい値を超えたと判別された前記第1の区間における弦の振動のレベルと、前記第2ゼロクロス点から前記第2ゼロクロス点の次のゼロクロス点を示す第3ゼロクロス点までの第2の区間における弦の振動のレベルとに基づいて決定した第1の音量で、前記決定された音高の楽音を発生させる制御を行う制御手段と、
前記第3ゼロクロス点から前記第3ゼロクロス点の次のゼロクロス点を示す第4ゼロクロス点までの第3の区間以降における弦の振動のレベルに基づいて、前記第1の音量を補正する補正手段と、
を有する電子弦楽器。
A pitch determining means for determining a pitch of a musical tone to be generated based on a string pressing operation on the fingerboard;
A string vibration detecting means for detecting vibration of the stretched string;
In a first section from a first zero cross point indicating a certain zero cross point to a second zero cross point next to the first zero cross point in a waveform signal corresponding to the vibration of the string, the vibration of the string First discriminating means for discriminating whether or not the level exceeds a first threshold value;
The level of vibration of the strings in the first and the determined first interval exceeds a threshold value, from the second zero-cross point to the third zero-cross point indicating the next zero cross point of the second zero-cross point Control means for performing control to generate a musical tone of the determined pitch at a first volume determined based on a level of string vibration in the second section;
Correction means for correcting the first volume based on a level of vibration of the string in a third section and thereafter from the third zero cross point to a fourth zero cross point indicating the next zero cross point of the third zero cross point ; ,
Electronic stringed instrument with
前記制御手段は、前記第3の区間以降に前記検出された弦の振動のレベルに基づいて決定した音量が、前記第1の音量よりも、第2のしきい値以上小さい期間が所定期間継続した場合に、楽音の発生をミュートさせる請求項1に記載の電子弦楽器。 The control means continues for a predetermined period during which the volume determined based on the detected vibration level of the string after the third interval is smaller than the first volume by a second threshold value or more. The electronic stringed instrument according to claim 1, wherein in the case where the sound is generated, the generation of musical sound is muted. 前記制御手段は、前記楽音の発生をミュートさせた後、前記検出された弦の振動のレベルに基づいて決定した音量が、前記第1の音量よりも、第3のしきい値以上小さい状態でなくなった場合、ミュートを解除する請求項2に記載の電子弦楽器。 The control means, after muting the generation of the musical sound, in a state where the volume determined based on the detected level of string vibration is smaller than the first volume by a third threshold value or more. The electronic stringed instrument according to claim 2, wherein the mute is canceled when it is lost. 張設された弦の振動を検出する弦振動検出手段を有する電子弦楽器に用いられる楽音制御方法であって、
指板上における押弦操作に基づいて発生すべき楽音の音高を決定し、
前記弦の振動に応じた波形信号における或るゼロクロス点を示す第1ゼロクロス点から前記第1ゼロクロス点の次のゼロクロス点を示す第2ゼロクロス点までの第1の区間で、前記弦の振動のレベルが第1のしきい値を超えたか否か判別し、
前記第1のしきい値を超えたと判別された第1の区間における弦の振動のレベルと、前記第2ゼロクロス点から前記第2ゼロクロス点の次のゼロクロス点を示す第3ゼロクロス点までの第2の区間における弦の振動のレベルとに基づいて決定した第1の音量で、前記決定された音高の楽音を発生させる制御を行い、
前記第3ゼロクロス点から前記第3ゼロクロス点の次のゼロクロス点を示す第4ゼロクロス点までの第3の区間以降における弦の振動のレベルに基づいて、前記第1の音量を補正する、楽音制御方法。
A musical tone control method used for an electronic stringed instrument having a string vibration detecting means for detecting vibration of a stretched string,
Determine the pitch of the musical sound that should be generated based on the string-pressing operation on the fingerboard,
In a first section from a first zero cross point indicating a certain zero cross point to a second zero cross point next to the first zero cross point in a waveform signal corresponding to the vibration of the string, the vibration of the string Determine if the level has exceeded the first threshold,
The vibration level of the string in the first section determined to have exceeded the first threshold, and the first zero cross point from the second zero cross point to the third zero cross point next to the second zero cross point . Performing control to generate a musical tone of the determined pitch at a first volume determined based on the level of vibration of the string in the section of 2,
Musical tone control for correcting the first volume based on the vibration level of the string in the third and subsequent sections from the third zero cross point to the fourth zero cross point indicating the next zero cross point of the third zero cross point Method.
張設された弦の振動を検出する弦振動検出手段を有する電子弦楽器に用いられるコンピュータに、
指板上における押弦操作に基づいて発生すべき楽音の音高を決定する音高決定ステップと、
前記弦の振動に応じた波形信号における或るゼロクロス点を示す第1ゼロクロス点から前記第1ゼロクロス点の次のゼロクロス点を示す第2ゼロクロス点までの第1の区間で、前記弦の振動のレベルが第1のしきい値を超えたか否か判別する第1の判別ステップと、
前記第1のしきい値を超えたと判別された第1の区間における弦の振動のレベルと、前記第2ゼロクロス点から前記第2ゼロクロス点の次のゼロクロス点を示す第3ゼロクロス点までの第2の区間における弦の振動のレベルとに基づいて決定した第1の音量で、前記決定された音高の楽音を発生させる制御を行う制御ステップと、
前記第3ゼロクロス点から前記第3ゼロクロス点の次のゼロクロス点を示す第4ゼロクロス点までの第3の区間以降における弦の振動のレベルに基づいて、前記第1の音量を補正する補正ステップと、
を実行させるプログラム。
In a computer used for an electronic stringed instrument having string vibration detection means for detecting vibration of a stretched string,
A pitch determination step for determining a pitch of a musical sound to be generated based on a string pressing operation on the fingerboard;
In a first section from a first zero cross point indicating a certain zero cross point to a second zero cross point next to the first zero cross point in a waveform signal corresponding to the vibration of the string, the vibration of the string A first determination step of determining whether or not the level exceeds a first threshold;
The vibration level of the string in the first section determined to have exceeded the first threshold, and the first zero cross point from the second zero cross point to the third zero cross point next to the second zero cross point . A control step for performing control to generate a musical tone of the determined pitch at a first volume determined based on the level of vibration of the string in the section of 2;
A correcting step for correcting the first volume based on a vibration level of the string in a third section and thereafter from the third zero cross point to a fourth zero cross point indicating the next zero cross point of the third zero cross point ; ,
A program that executes
JP2013221467A 2013-10-24 2013-10-24 Electronic stringed instrument, musical sound control method and program Active JP6361109B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2013221467A JP6361109B2 (en) 2013-10-24 2013-10-24 Electronic stringed instrument, musical sound control method and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2013221467A JP6361109B2 (en) 2013-10-24 2013-10-24 Electronic stringed instrument, musical sound control method and program

Publications (2)

Publication Number Publication Date
JP2015082094A JP2015082094A (en) 2015-04-27
JP6361109B2 true JP6361109B2 (en) 2018-07-25

Family

ID=53012692

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2013221467A Active JP6361109B2 (en) 2013-10-24 2013-10-24 Electronic stringed instrument, musical sound control method and program

Country Status (1)

Country Link
JP (1) JP6361109B2 (en)

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0782320B2 (en) * 1987-03-06 1995-09-06 カシオ計算機株式会社 Music control device
JP2778645B2 (en) * 1987-10-07 1998-07-23 カシオ計算機株式会社 Electronic string instrument
JP2734521B2 (en) * 1988-03-31 1998-03-30 カシオ計算機株式会社 Music control device
JP2615825B2 (en) * 1988-05-02 1997-06-04 カシオ計算機株式会社 Electronic string instrument
JP6135312B2 (en) * 2013-06-10 2017-05-31 カシオ計算機株式会社 Electronic stringed instrument, musical sound control method and program

Also Published As

Publication number Publication date
JP2015082094A (en) 2015-04-27

Similar Documents

Publication Publication Date Title
US5966687A (en) Vocal pitch corrector
JPH0196700A (en) Input controller for electronic musical instrument
WO2004051622A1 (en) Musical composition data creation device and method
JP2734521B2 (en) Music control device
JP6175812B2 (en) Musical sound information processing apparatus and program
JP2840819B2 (en) Method and apparatus for recognizing start and end of sound
JP5732982B2 (en) Musical sound generation device and musical sound generation program
JP6135312B2 (en) Electronic stringed instrument, musical sound control method and program
JP6361109B2 (en) Electronic stringed instrument, musical sound control method and program
JPH0371718B2 (en)
JP2014153434A (en) Electronic stringed instrument, musical sound generation method and program
JP2015082092A (en) Electronic stringed instrument, method for controlling musical sound, and program
JPH08227296A (en) Sound signal processor
JP6149890B2 (en) Musical sound generation device and musical sound generation program
US9542923B1 (en) Music synthesizer
JP5742592B2 (en) Musical sound generation device, musical sound generation program, and electronic musical instrument
JP2775633B2 (en) Music control device
JP2611263B2 (en) Sound control device
JP2015172679A (en) Musical sound generation device, and musical sound generation method and program
JP5151603B2 (en) Electronic musical instruments
JP2661066B2 (en) Sound control device
JP2661481B2 (en) Electronic musical instrument
JP2958778B2 (en) Tone generator
JP6387621B2 (en) Electronic string instrument string position detection device, string position detection method and program
JP2591000B2 (en) Electronic string instrument

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20161020

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20170925

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20171017

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20171215

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20180611

R150 Certificate of patent or registration of utility model

Ref document number: 6361109

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150