JP2006112346A - Signal processor - Google Patents

Signal processor Download PDF

Info

Publication number
JP2006112346A
JP2006112346A JP2004301667A JP2004301667A JP2006112346A JP 2006112346 A JP2006112346 A JP 2006112346A JP 2004301667 A JP2004301667 A JP 2004301667A JP 2004301667 A JP2004301667 A JP 2004301667A JP 2006112346 A JP2006112346 A JP 2006112346A
Authority
JP
Japan
Prior art keywords
command
signal
processing
input
communication
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.)
Granted
Application number
JP2004301667A
Other languages
Japanese (ja)
Other versions
JP4259449B2 (en
Inventor
Takayoshi Honda
隆芳 本多
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.)
Denso Corp
Original Assignee
Denso Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Denso Corp filed Critical Denso Corp
Priority to JP2004301667A priority Critical patent/JP4259449B2/en
Publication of JP2006112346A publication Critical patent/JP2006112346A/en
Application granted granted Critical
Publication of JP4259449B2 publication Critical patent/JP4259449B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To accurately perform digital filter processing on a second device side even if noise occurs in an A/D converting request command from a second device to a first device in a signal processor enabling the second device performing the digital filter processing for the time-series A/D converted values of analog signals to transmit the A/D conversion request command to the first device with an A/D converter for each prescribed interval and acquiring, as a response to the command, the A/D converted values of analog signals from the first device. <P>SOLUTION: When a chip select signal (CS) given from a processing IC as the second device is low, an input IC as the first device communicates with the processing IC and returns the A/D converted values for each receipt of the A/D conversion request command (cmdB). Particularly, the signal processor transmits the A/D converted values (S570) irrespective of the type of the command from the processing IC until the CS becomes high after the device determines once that it received cmdB after the CS becomes low (S440: NO). <P>COPYRIGHT: (C)2006,JPO&NCIPI

Description

本発明は、アナログ信号をA/D変換してデジタルフィルタ処理を行う信号処理装置に関するものである。   The present invention relates to a signal processing apparatus that performs A / D conversion on an analog signal to perform digital filter processing.

従来より、例えば自動車のエンジンを制御する装置では、ノックセンサからのアナログ信号(いわゆるノック信号)をA/D変換器により一定のサンプリング間隔毎にA/D変換すると共に、そのA/D変換された時系列のデータをデジタルフィルタに供給し、そのデジタルフィルタ処理結果を用いてノッキングの有無を判定(ノック判定)している(例えば、特許文献1参照)。   2. Description of the Related Art Conventionally, in an apparatus for controlling an automobile engine, for example, an analog signal (a so-called knock signal) from a knock sensor is A / D converted at a certain sampling interval by an A / D converter, and the A / D conversion is performed. The time-series data is supplied to a digital filter, and the presence or absence of knocking is determined (knock determination) using the digital filter processing result (see, for example, Patent Document 1).

そして、このようにアナログ信号をA/D変換してデジタルフィルタ処理を行う信号処理装置の形態としては、A/D変換器を有した第1装置と、その第1装置と通信ラインを介し一定時間毎に通信して、A/D変換器によるアナログ信号のA/D変換値を順次取得し、その取得した時系列のA/D変換値に対しデジタルフィルタ処理を行う第2装置とからなり、第2装置が、第1装置へ複数種類のコマンドのうちのA/D変換要求コマンドを一定時間毎に送信し、第1装置が、そのA/D変換要求コマンドを受信する毎に、A/D変換器によるアナログ信号のA/D変換値を第2装置へ返送することで、第1装置から第2装置へアナログ信号の一定時間毎のA/D変換値が転送される、といった形態が考えられる(例えば、特許文献2参照)。   And as a form of the signal processing apparatus which performs A / D conversion of an analog signal and performs digital filter in this way, the first apparatus having an A / D converter, and the first apparatus and a fixed line via a communication line It consists of a second device that communicates every time, sequentially acquires A / D conversion values of analog signals by the A / D converter, and performs digital filter processing on the acquired time-series A / D conversion values Each time the second device transmits an A / D conversion request command of a plurality of types of commands to the first device at regular intervals, and the first device receives the A / D conversion request command, A A mode in which the A / D conversion value of the analog signal is transferred from the first device to the second device by returning the A / D conversion value of the analog signal by the / D converter to the second device. (For example, see Patent Document 2) .

また一般に、上記第1装置と第2装置との各々はIC化されると共に、第1装置としてのICは、外部から与えられる通信許可信号としてのチップセレクト信号がアクティブレベルである場合に、他のICと通信するように構成される。このため、第2装置は、第1装置に対する通信許可信号としてのチップセレクト信号をアクティブレベルにした上で、その第1装置と一定時間毎に通信することとなる。
特開平7−293314号公報 特開平9−282265号公報
In general, each of the first device and the second device is integrated into an IC. When the chip select signal as a communication permission signal given from the outside is at an active level, the IC as the first device Configured to communicate with the IC. Therefore, the second device communicates with the first device at regular intervals after setting the chip select signal as a communication permission signal for the first device to the active level.
JP-A-7-293314 JP-A-9-282265

ところで、上記形態の信号処理装置では、第1装置が第2装置からのA/D変換要求コマンドを受信すると、第2装置へアナログ信号のA/D変換値を返す、といったやり取りを行うため、もし、第2装置からのA/D変換要求コマンドがノイズによりデータ化けして第1装置に違うコマンドとして受信された場合には、第1装置から第2装置へA/D変換値が返送されなかったり、本来のA/D変換値とは違う値が返送されてしまう可能性がある。そして、このような事象が起こると、第2装置側でのデジタルフィルタ処理結果が不正確なものになってしまう。デジタルフィルタ処理においては、一定時間毎の連続したA/D変換値を順次処理する必要があり、A/D変換値が途中で欠けたり、いきなり不定な値になると、正しいデジタルフィルタ処理結果が得られず、延いては、そのフィルタ処理結果を用いる制御の精度が低下してしまうのである。   By the way, in the signal processing device of the above embodiment, when the first device receives the A / D conversion request command from the second device, the A / D conversion value of the analog signal is returned to the second device. If an A / D conversion request command from the second device is garbled due to noise and is received as a different command by the first device, an A / D conversion value is returned from the first device to the second device. Or a value different from the original A / D conversion value may be returned. When such an event occurs, the digital filter processing result on the second device side becomes inaccurate. In digital filter processing, it is necessary to sequentially process continuous A / D conversion values at regular intervals. If the A / D conversion values are missing or suddenly become indefinite values, a correct digital filter processing result is obtained. In other words, the accuracy of control using the filter processing result is lowered.

本発明は、こうした問題に鑑みなされたものであり、アナログ信号の時系列のA/D変換値に対してデジタルフィルタ処理を行う第2装置が、A/D変換器を有した第1装置へA/D変換要求コマンドを一定時間毎に送信し、そのコマンドに対する応答として第1装置からアナログ信号のA/D変換値を取得するように構成された信号処理装置において、第2装置から第1装置へのA/D変換要求コマンドにノイズが乗った場合でも、第2装置側にてデジタルフィルタ処理を正確に実施可能にすることを目的としている。   The present invention has been made in view of these problems, and the second device that performs digital filter processing on time-series A / D conversion values of analog signals is changed to a first device having an A / D converter. In a signal processing device configured to transmit an A / D conversion request command at regular time intervals and acquire an A / D conversion value of an analog signal from the first device as a response to the command, the first signal from the second device is An object is to enable the second device to accurately perform digital filter processing even when noise is added to the A / D conversion request command to the device.

上記目的を達成するためになされた請求項1記載の信号処理装置は、アナログ信号をA/D変換するA/D変換器を有すると共に、外部からの通信許可信号がアクティブレベルである場合に他の装置と通信ラインを介して通信する第1装置と、その第1装置と通信ラインを介して接続され、前記通信許可信号をアクティブレベルにして第1装置と一定時間毎に通信することにより、前記A/D変換器によるアナログ信号の一定時間毎のA/D変換値を順次取得して、その取得した時系列のA/D変換値に対しデジタルフィルタ処理を行う第2装置とからなる。そして、この信号処理装置では、第2装置が、通信許可信号をアクティブレベルにした状態で、第1装置へ複数種類のコマンドのうちのA/D変換要求コマンドを一定時間毎に送信し、第1装置が、そのA/D変換要求コマンドを受信する毎に、A/D変換器によるアナログ信号のA/D変換値を第2装置へ返送することにより、第1装置から第2装置へ、A/D変換器によるアナログ信号の一定時間毎のA/D変換値が転送される。   The signal processing device according to claim 1, which has been made to achieve the above object, has an A / D converter for A / D converting an analog signal, and other when an external communication permission signal is at an active level. A first device that communicates with the first device via a communication line; and the first device that is connected to the first device via a communication line, and the communication permission signal is set to an active level to communicate with the first device at regular intervals, A second apparatus that sequentially acquires A / D conversion values of the analog signal by the A / D converter at regular intervals and performs digital filter processing on the acquired time-series A / D conversion values. In this signal processing device, the second device transmits an A / D conversion request command of a plurality of types of commands to the first device at regular intervals while the communication permission signal is set to the active level. Each time one device receives the A / D conversion request command, the A / D conversion value of the analog signal from the A / D converter is sent back to the second device, so that the first device transfers to the second device. The A / D conversion value of the analog signal by the A / D converter is transferred every predetermined time.

そして特に、この信号処理装置において、第1装置は、通信許可信号がアクティブレベルになってから、A/D変換要求コマンドを受信したと一度判断すると、その後、通信許可信号が非アクティブレベルとなるまでは、第2装置からのコマンドがA/D変換要求コマンドであるか否かに拘わらず、その第2装置からのコマンドを受信する毎に、第2装置へA/D変換器によるアナログ信号のA/D変換値を送信するようになっている。   In particular, in this signal processing device, when the first device once determines that the A / D conversion request command has been received after the communication permission signal becomes active level, the communication permission signal then becomes inactive level. Until, every time a command from the second device is received regardless of whether the command from the second device is an A / D conversion request command, an analog signal from the A / D converter is sent to the second device. A / D conversion values are transmitted.

このような請求項1の信号処理装置によれば、第1装置は、通信許可信号がアクティブレベルになってから、一度でもA/D変換要求コマンドを受信した後は、第2装置からのA/D変換要求コマンドにノイズが乗って、そのA/D変換要求コマンドを不定なコマンドや違うコマンドとして受信したとしても、A/D変換要求コマンドを受信した時と全く同様に、第2装置へAD変換値を送信することとなるため、第2装置では、正しいA/D変換値を受信することができ、デジタルフィルタ処理を正確に実施することができる。   According to such a signal processing device of claim 1, after the first device receives the A / D conversion request command even once after the communication permission signal becomes the active level, the first device receives the A from the second device. Even if noise is added to the / D conversion request command and the A / D conversion request command is received as an indefinite command or a different command, it is sent to the second device in exactly the same way as when the A / D conversion request command is received. Since the AD conversion value is transmitted, the second device can receive the correct A / D conversion value and can accurately perform the digital filter processing.

次に、請求項2記載の信号処理装置では、請求項1の信号処理装置において、第2装置は、通信許可信号をアクティブレベルにした後、第1装置へ、A/D変換要求コマンド以外の機能設定用コマンドを所定個数だけ送信してから、A/D変換要求コマンドの送信を開始し、第1装置は、通信許可信号がアクティブレベルになってから前記機能設定用コマンドを受信すると、その機能設定用コマンドに応じて内部の機能を設定するようになっている。   Next, in the signal processing device according to claim 2, in the signal processing device according to claim 1, after the second device sets the communication permission signal to an active level, the second device sends a signal other than an A / D conversion request command to the first device. After transmitting a predetermined number of function setting commands, transmission of an A / D conversion request command is started. When the first device receives the function setting command after the communication permission signal becomes active, The internal functions are set according to the function setting command.

そして、このような請求項2の信号処理装置によれば、第1装置と第2装置との通信期間毎に、第2装置から第1装置へA/D変換要求コマンドに先立って送信する機能設定用コマンドにより、その第1装置の内部機能の設定を任意に変えることができ、非常に有利である。   According to such a signal processing device of claim 2, the function of transmitting from the second device to the first device prior to the A / D conversion request command for each communication period between the first device and the second device. The setting command allows the setting of the internal function of the first device to be changed arbitrarily, which is very advantageous.

尚、機能設定用コマンドとしては、どのような機能を設定するためのコマンドであっても良いが、例えば、第1装置がA/D変換器に入力されるアナログ信号を増幅するアンプ(増幅器)を備えているならば、その増幅器のゲインを指令するコマンドが考えられる。また例えば、第1装置が異なるアナログ信号をそれぞれ入力するための複数の入力チャンネルのうちの何れか1つを選択して、その選択した入力チャンネルに入力されているアナログ信号をA/D変換器に入力させるマルチプレクサを備えているならば、そのマルチプレクサに選択させる入力チャンネルを指令するコマンドが考えられる。   The function setting command may be a command for setting any function. For example, an amplifier (amplifier) that amplifies an analog signal input to the A / D converter by the first device. , A command to command the gain of the amplifier can be considered. In addition, for example, the first device selects any one of a plurality of input channels for inputting different analog signals, and the analog signal input to the selected input channel is converted into an A / D converter. If it is provided with a multiplexer to be input to, a command for instructing the input channel to be selected by the multiplexer can be considered.

また、請求項2の信号処理装置において、第2装置が機能設定用コマンドを送信する回数は、請求項3に記載のような回数であることが好ましい。
即ち、通信許可信号がアクティブレベルになってからA/D変換器の出力を安定させるまでに必要な時間(換言すれば、A/D変換器の初期設定を完了させるまでに必要な時間)をT1とし、第1装置と第2装置との通信間隔である前記一定時間をT2とすると、第2装置は、通信許可信号をアクティブレベルにした後、機能設定用コマンドを「T1/T2」以上である整数値の回数だけ送信した後、A/D変換要求コマンドの送信を開始するように構成するのが好ましい。つまり、機能設定用コマンドの送信期間を、A/D変換器の出力を安定させるまでの時間稼ぎとして利用するのである。
In the signal processing device according to claim 2, it is preferable that the number of times the second device transmits the function setting command is the number of times as described in claim 3.
That is, the time required for stabilizing the output of the A / D converter after the communication permission signal becomes active level (in other words, the time required for completing the initial setting of the A / D converter). Assuming T1 and T2 as the predetermined time, which is the communication interval between the first device and the second device, the second device sets the function permission command to “T1 / T2” or higher after setting the communication permission signal to the active level. It is preferable that the transmission of the A / D conversion request command is started after the number of times of the integer value is transmitted. That is, the transmission period of the function setting command is used as time gain until the output of the A / D converter is stabilized.

そして、このような請求項3の信号処理装置によれば、第2装置は、出力値が安定した後のA/D変換器によるA/D変換値を取得することができ、延いては、デジタルフィルタ処理の正確性を高めることができる。また、故意に遅延を設けるための特別なコマンドを設定する必要もない。   And according to such a signal processing device of claim 3, the second device can acquire the A / D conversion value by the A / D converter after the output value is stabilized, The accuracy of digital filter processing can be improved. In addition, it is not necessary to set a special command for intentionally providing a delay.

次に、請求項4記載の信号処理装置では、請求項2,3の信号処理装置において、第2装置は、通信許可信号をアクティブレベルにしてからA/D変換要求コマンドを送信するまでの機能設定用コマンドの送信個数を、その機能設定用コマンド中に含ませて第1装置へ送信するようになっている。そして、第1装置は、第2装置からの機能設定用コマンド中に含まれている前記送信個数と、通信許可信号がアクティブレベルになってから第2装置から実際に送信されて来た機能設定用コマンドの数とを比較して、不一致ならば異常と判断するようになっている。   Next, in the signal processing device according to claim 4, in the signal processing device according to claims 2 and 3, the second device has a function from when the communication permission signal is set to the active level to when the A / D conversion request command is transmitted. The number of setting commands to be transmitted is included in the function setting command and transmitted to the first device. Then, the first device sets the number of transmissions included in the function setting command from the second device and the function setting actually transmitted from the second device after the communication permission signal becomes the active level. The number of commands is compared, and if they do not match, it is determined that there is an abnormality.

このような請求項4の信号処理装置によれば、第1装置は、第2装置から送信される機能設定用コマンドの数を知ることができるため、その第2装置からの機能設定用コマンドがノイズによりA/D変換要求コマンドにデータ化けして、そのデータ化けしたA/D変換要求コマンドを受信したとしても、そのような異常の発生を検知することができる。   According to such a signal processing device of claim 4, since the first device can know the number of function setting commands transmitted from the second device, the function setting commands from the second device are Even if the data is converted into an A / D conversion request command due to noise and the converted A / D conversion request command is received, the occurrence of such an abnormality can be detected.

次に、請求項5記載の信号処理装置では、請求項2〜4の信号処理装置において、第1装置は、通信許可信号がアクティブレベルである期間中に発生した通信異常を表す異常情報を、通信許可信号が一旦非アクティブレベルとなって次にアクティブレベルとなった際に、機能設定用コマンドに対する応答データ中に含ませて第2装置へ送信するようになっている。   Next, in the signal processing device according to claim 5, in the signal processing device according to claims 2 to 4, the first device includes abnormality information representing a communication abnormality that occurs during a period in which the communication permission signal is at an active level. When the communication permission signal once becomes inactive level and then becomes active level, it is included in the response data for the function setting command and transmitted to the second device.

このような請求項5の信号処理装置によれば、第1装置から第2装置への通信異常情報を、次の通信期間において、機能設定用コマンドに対する応答データ中に含ませて送るようにしているため、その通信異常情報をA/D変換値と一緒に送信しなくても済む。   According to such a signal processing device of claim 5, the communication abnormality information from the first device to the second device is included in the response data for the function setting command and sent in the next communication period. Therefore, it is not necessary to transmit the communication abnormality information together with the A / D conversion value.

このため、第2装置からのA/D変換要求コマンドに対する第1装置からの応答データの全ビット或いはより多くのビットを、A/D変換値のデータにすることができ、第1装置から第2装置へのA/D変換値の転送を効率良く行うことができる。また、通信異常が発生したことを、その異常が起こった通信期間中に送信するよりも、次回の正常な通信期間において送信する方が信頼性が高いという点でも有利である。   For this reason, all or more bits of response data from the first device in response to the A / D conversion request command from the second device can be converted to A / D conversion value data. It is possible to efficiently transfer the A / D conversion value to the two devices. In addition, it is advantageous in that it is more reliable to transmit the occurrence of a communication abnormality during the next normal communication period than to transmit during the communication period in which the abnormality has occurred.

尚、第1装置が検知する通信異常としては、どのような異常でも良いが、例えば、第2装置からの機能設定用コマンドが終わってA/D変換要求コマンドを受信し出したのに、再び機能設定用コマンドを受信したとか、請求項4に記載の異常が考えられる。   The communication abnormality detected by the first device may be any abnormality. For example, after the function setting command from the second device is over and the A / D conversion request command is received, An abnormality described in claim 4 is conceivable, such as receiving a function setting command.

次に、請求項6記載の信号処理装置では、請求項2〜5の信号処理装置において、第1装置は、アナログ信号として、エンジンのノッキングを検出するための複数のノックセンサからのアナログ信号を入力し、その複数のアナログ信号のうち、第2装置からの機能設定用コマンドによって指示される1つのアナログ信号を選択してA/D変換器に入力させるようになっている。   Next, in the signal processing device according to claim 6, in the signal processing device according to claims 2 to 5, the first device outputs analog signals from a plurality of knock sensors for detecting engine knock as analog signals. Among the plurality of analog signals, one analog signal indicated by the function setting command from the second device is selected and input to the A / D converter.

そして、第2装置は、エンジンの各気筒毎に設定されるノック判定区間の何れかが終了すると、通信許可信号をアクティブレベルから非アクティブレベルにし、その後、次の気筒のノック判定区間が到来する前に、通信許可信号をアクティブレベルにして、機能設定用コマンドを送信することにより、前記複数のアナログ信号のうち、次の気筒のノッキングを判定するためのアナログ信号を第1装置に選択させると共に、A/D変換要求コマンドの送信も開始するようになっている。   When any of the knock determination sections set for each cylinder of the engine ends, the second device changes the communication permission signal from the active level to the inactive level, and then the knock determination section of the next cylinder arrives. Before setting the communication permission signal to an active level and transmitting a function setting command, the first device is made to select an analog signal for determining knocking of the next cylinder among the plurality of analog signals. The transmission of the A / D conversion request command is also started.

つまり、ノックセンサからのアナログ信号をA/D変換し更にデジタルフィルタ処理してノッキングの有無を判定(ノック判定)する場合、そのようなノック判定の実施対象期間であるノック判定区間が始まった時点からA/D変換値のデジタルフィルタ処理を開始したのでは、そのデジタルフィルタ処理の初期の処理結果が正確な値を示さず、ノック判定区間全域に亘るノック判定を正確に行うことができない。デジタルフィルタ処理においては、初期の入力に対しては適切な出力値が得られず、適切な出力値が得られるまでには、そのデジタルフィルタ処理の次数や構成に応じた個数の入力が必要なためである。   That is, when the analog signal from the knock sensor is A / D converted and further subjected to digital filter processing to determine the presence or absence of knocking (knock determination), the point at which the knock determination section, which is the target period for such knock determination, has started When the digital filter processing of the A / D conversion value is started, the initial processing result of the digital filter processing does not indicate an accurate value, and the knock determination over the entire knock determination section cannot be performed accurately. In digital filter processing, an appropriate output value cannot be obtained for an initial input, and the number of inputs corresponding to the order and configuration of the digital filter processing is required until an appropriate output value is obtained. Because.

そこで、請求項6の信号処理装置では、何れかの気筒のノック判定区間が終了してから次の気筒のノック判定区間が始まる前に、A/D変換器に入力されるアナログ信号を切り替えると共に、そのアナログ信号のA/D変換を開始させて、第1装置から第2装置へA/D変換値を転送するようにしており、これにより、ノック判定区間が開始される少し前から、A/D変換とデジタルフィルタ処理を開始できるようにしている。   Therefore, in the signal processing device according to the sixth aspect, the analog signal input to the A / D converter is switched before the knock determination section of the next cylinder starts after the knock determination section of any cylinder ends. The A / D conversion of the analog signal is started and the A / D conversion value is transferred from the first device to the second device, so that A / D conversion and digital filter processing can be started.

このため、ノック判定区間が始まる前に、A/D変換器は元よりデジタルフィルタ処理の出力値(処理結果)も安定化させることが可能となり、延いては、そのデジタルフィルタ処理結果を用いたノック判定の精度を向上させることができる。   For this reason, before the knock determination section starts, the A / D converter can stabilize the output value (processing result) of the digital filter processing from the beginning, and the digital filter processing result is used. The accuracy of knock determination can be improved.

次に、請求項7記載の信号処理装置では、請求項2〜6の信号処理装置において、第2装置は、機能設定用コマンドに対する第1装置からの受信データ(つまり、機能設定用コマンドに対する第1装置からの応答データを受信したデータ)が格納される第1格納部と、A/D変換要求コマンドに対する第1装置からの受信データ(つまり、A/D変換要求コマンドに対する第1装置からの応答データを受信したデータ)が格納される第2格納部とを別々に備えている。   Next, in the signal processing device according to claim 7, in the signal processing device according to claims 2 to 6, the second device receives the data received from the first device in response to the function setting command (that is, the first to the function setting command). Data stored in response data from one device) and received data from the first device in response to the A / D conversion request command (that is, from the first device in response to the A / D conversion request command). And a second storage unit in which the response data is received).

そして、このような請求項7の信号処理装置によれば、コマンド毎に、そのコマンドに対する受信データを格納するための格納部が別れているため、A/D変換要求コマンドに対する受信データ(つまり、A/D変換値)で、機能設定用コマンドに対する受信データが上書きされてしまうことがなく、第2装置は、第1装置との通信終了後に、機能設定用コマンドに対する受信データのチェックを行うことができる。よって、第2装置の処理負荷を低減させることができる。   According to such a signal processing device of claim 7, since the storage unit for storing the received data for the command is separated for each command, the received data for the A / D conversion request command (that is, The received data for the function setting command is not overwritten with the A / D conversion value), and the second device checks the received data for the function setting command after the communication with the first device is completed. Can do. Therefore, the processing load of the second device can be reduced.

次に、請求項8記載の信号処理装置では、請求項2〜7の信号処理装置において、第2装置は、通信許可信号をアクティブレベルにした後、機能設定用コマンドとして、同じ内容の機能設定用コマンドを複数個送信する。そして、第1装置は、第2装置から受信した複数個の機能設定用コマンドの内容の多数決をとり、その多数決の結果に応じて内部の機能を設定するようになっている。   Next, in the signal processing device according to claim 8, in the signal processing device according to claims 2 to 7, after the second device sets the communication permission signal to the active level, the function setting having the same contents is set as a function setting command. Multiple commands are sent. The first device takes a majority vote of the contents of a plurality of function setting commands received from the second device, and sets internal functions according to the result of the majority vote.

このような請求項8の信号処理装置によれば、第1装置は、第2装置から複数回受信した機能設定用コマンドの多数決をとるため、第2装置から第1装置への機能設定用コマンドのうち、特に最後の機能設定用コマンドにノイズが乗ったとしても、内部の機能(例えば、前述した入力チャンネルやゲイン等)を正しく設定することができるようになる。   According to such a signal processing device of claim 8, the first device takes the majority of the function setting commands received a plurality of times from the second device, and therefore the function setting commands from the second device to the first device. In particular, even if noise is added to the last function setting command, internal functions (for example, the input channel and gain described above) can be set correctly.

次に、請求項9記載の信号処理装置では、請求項1〜8の信号処理装置において、前記一定時間毎のタイミング信号が第1装置側で生成され、そのタイミング信号に従って、A/D変換器によるアナログ信号のA/D変換及び第1装置と第2装置との通信が実行されるようになっている。   Next, in the signal processing device according to claim 9, in the signal processing device according to claims 1 to 8, the timing signal for each predetermined time is generated on the first device side, and an A / D converter is generated according to the timing signal. A / D conversion of analog signals and communication between the first device and the second device are performed.

このような請求項9の信号処理装置によれば、A/D変換器を有する第1装置側で一定時間毎のタイミングを生成しているため、A/D変換間隔を正確なものにすることができる。つまり、逆の構成として、第2装置がタイミングを決定する上でのマスターとなり、例えば、第1装置は、第2装置からの一定時間毎のコマンドを受信するとA/D変換器を起動させると共にA/D変換値を送信する、といった構成も考えられるが、この構成の場合には、通信遅延などによってA/D変換タイミングがずれてしまう可能性がある。これに対して、請求項9の信号処理装置によれば、正確な一定時間毎のA/D変換値に対してデジタルフィルタ処理を実施することができ、そのフィルタ処理結果を用いる制御の精度を高めることができる。   According to such a signal processing device of the ninth aspect, since the first device side having the A / D converter generates the timing every predetermined time, the A / D conversion interval is made accurate. Can do. In other words, as a reverse configuration, the second device becomes a master in determining the timing. For example, the first device activates the A / D converter upon receiving a command at regular intervals from the second device. Although a configuration in which an A / D conversion value is transmitted is also conceivable, in this configuration, there is a possibility that the A / D conversion timing may be shifted due to a communication delay or the like. On the other hand, according to the signal processing device of the ninth aspect, the digital filter processing can be performed on the accurate A / D conversion value at every fixed time, and the accuracy of control using the filter processing result is improved. Can be increased.

以下に、本発明が適用された実施形態の信号処理装置について説明する。尚、本実施形態の信号処理装置は、自動車に搭載される例えばV型6気筒エンジンのノック判定に用いられるものである。   Hereinafter, a signal processing apparatus according to an embodiment to which the present invention is applied will be described. The signal processing apparatus according to the present embodiment is used for knock determination of, for example, a V-type 6-cylinder engine mounted on an automobile.

まず図1に示すように、本実施形態の信号処理装置は、第1装置としての入力IC11と、第2装置としての処理IC13とからなり、その入力IC11と処理IC13は、後述する5本の信号線1〜5によって通信可能に接続されている。   First, as shown in FIG. 1, the signal processing apparatus according to the present embodiment includes an input IC 11 serving as a first apparatus and a processing IC 13 serving as a second apparatus. The input IC 11 and the processing IC 13 include five described later. The signal lines 1 to 5 are communicably connected.

入力IC11には、処理IC13と通信するための通信部15と、A/D変換器17と、複数の入力チャンネルch0〜chNのうちの何れか1つを選択して、その選択した入力チャンネルに入力されているアナログ信号を出力するマルチプレクサ(MPX)19と、マルチプレクサ19の出力を所定のゲインで増幅してA/D変換器17に入力させるアンプ(Amp)21と、A/D変換器17の起動間隔(即ちA/D変換間隔)及びIC11,13間の通信間隔を決定する一定時間Tc毎(本実施形態では10μs毎)のタイミング信号を生成して出力するタイマ(Timer)23と、それらを制御する制御部25とが備えられている。   The input IC 11 selects any one of the communication unit 15 for communicating with the processing IC 13, the A / D converter 17, and the plurality of input channels ch0 to chN, and sets the selected input channel. A multiplexer (MPX) 19 that outputs an input analog signal, an amplifier (Amp) 21 that amplifies the output of the multiplexer 19 with a predetermined gain and inputs the amplified signal to the A / D converter 17, and an A / D converter 17 A timer (Timer) 23 that generates and outputs a timing signal for every predetermined time Tc (in this embodiment, every 10 μs) for determining the activation interval (ie, A / D conversion interval) and the communication interval between the ICs 11 and 13; And a control unit 25 for controlling them.

そして、マルチプレクサ19の入力チャンネルch0〜chNのうち、チャンネルch0には、エンジンにおける右バンクの各気筒(第1気筒#1、第3気筒#3、及び第5気筒#5)のノッキングを検出するために設けられた第1ノックセンサ27からのアナログ信号が入力され、チャンネルch1には、エンジンにおける左バンクの各気筒(第2気筒#2、第4気筒#4、及び第6気筒#6)のノッキングを検出するために設けられた第2ノックセンサ29からのアナログ信号が入力されている。   Of the input channels ch0 to chN of the multiplexer 19, the knocking of each cylinder (first cylinder # 1, third cylinder # 3, and fifth cylinder # 5) of the right bank in the engine is detected in the channel ch0. The analog signal from the first knock sensor 27 provided for the purpose is input, and each cylinder (second cylinder # 2, fourth cylinder # 4, and sixth cylinder # 6) of the left bank in the engine is input to the channel ch1. An analog signal is input from a second knock sensor 29 provided to detect the knocking.

また、処理IC13には、入力IC11と通信するための通信部31と、エンジンのクランク軸の回転に同期して回転センサにより発生される周知の回転パルス信号(図示省略)に基づいてクランク位置(クランク軸の回転位置)を検出する回転処理部33と、デジタルフィルタ処理を行うデジタルフィルタ35と、そのデジタルフィルタ35の処理結果が順次格納されるメモリ37と、通信部31及びデジタルフィルタ35の起動/停止等の処理を行うCPU39とが備えられている。   The processing IC 13 includes a communication unit 31 for communicating with the input IC 11 and a crank position (not shown) based on a known rotation pulse signal (not shown) generated by a rotation sensor in synchronization with the rotation of the crankshaft of the engine. A rotation processing unit 33 for detecting the rotation position of the crankshaft, a digital filter 35 for performing digital filter processing, a memory 37 for sequentially storing the processing results of the digital filter 35, and activation of the communication unit 31 and the digital filter 35. CPU39 which performs processing, such as / stop.

そして、通信部31には、処理IC13から入力IC11へ送信するコマンド(図中では「cmd」と記している)のうち、後述するコマンドA(cmdA)の送信個数が書き込まれるレジスタ41と、コマンドAとして送信されるデータ(コマンドA送信データ)が書き込まれるレジスタ42と、後述するコマンドB(cmdB)として送信されるデータ(コマンドB送信データ)が書き込まれるレジスタ43と、コマンドAに対する入力IC11からの応答データを受信したデータ(コマンドA受信データ)が格納される第1格納部としてのレジスタ44と、コマンドBに対する入力IC11からの応答データを受信したデータ(コマンドB受信データ)が格納される第2格納部としてのレジスタ45とが備えられている。   The communication unit 31 includes a register 41 in which the number of commands A (cmdA), which will be described later, among commands sent from the processing IC 13 to the input IC 11 (indicated as “cmd” in the drawing) is written, and a command A register 42 to which data (command A transmission data) to be transmitted as A is written, a register 43 to which data (command B transmission data) to be transmitted as command B (cmdB) described later is written, and an input IC 11 for the command A Register 44 serving as a first storage unit for storing data (command A received data) received, and data for receiving response data from the input IC 11 for command B (command B received data) are stored. A register 45 serving as a second storage unit is provided.

尚、入力IC11側の通信部15にも、入力IC11から処理IC13へ送信するデータが格納される送信データレジスタ46と、処理IC13からの受信データが格納される受信データレジスタ47とが備えられている。   The communication unit 15 on the input IC 11 side also includes a transmission data register 46 that stores data to be transmitted from the input IC 11 to the processing IC 13 and a reception data register 47 that stores reception data from the processing IC 13. Yes.

一方、入力IC11と処理IC13を結ぶ信号線1〜5のうち、信号線1は、入力IC11に対するチップセレクト信号CS用の信号線である。そして、処理IC13の通信部31が、その信号線1のレベル(つまり、チップセレクト信号CSのレベル)をアクティブレベル(本実施形態ではローレベル)にすると、入力IC11の通信部15が通信動作を行う通信許可状態となる。   On the other hand, among the signal lines 1 to 5 connecting the input IC 11 and the processing IC 13, the signal line 1 is a signal line for a chip select signal CS for the input IC 11. When the communication unit 31 of the processing IC 13 sets the level of the signal line 1 (that is, the level of the chip select signal CS) to the active level (low level in the present embodiment), the communication unit 15 of the input IC 11 performs the communication operation. The communication to be performed is permitted.

また、信号線2は、処理IC13の通信部31から入力IC11の通信部15へ、通信クロックCLKを供給するための信号線である。そして、両IC11,13の通信部15,31は、その通信クロックCLKに同期してデータを1ビットずつ送受信し合う。   The signal line 2 is a signal line for supplying the communication clock CLK from the communication unit 31 of the processing IC 13 to the communication unit 15 of the input IC 11. The communication units 15 and 31 of both ICs 11 and 13 transmit and receive data one bit at a time in synchronization with the communication clock CLK.

そして、信号線3は、処理IC13の通信部31から入力IC11の通信部15へデータを送信するための通信ラインであり、信号線4は、入力IC11の通信部15から処理IC13の通信部31へデータを送信するための通信ラインである。   The signal line 3 is a communication line for transmitting data from the communication unit 31 of the processing IC 13 to the communication unit 15 of the input IC 11, and the signal line 4 is the communication unit 31 of the processing IC 13 from the communication unit 15 of the input IC 11. It is a communication line for transmitting data to.

また、信号線5は、タイマ23から上記タイミング信号が出力される毎にハイレベルとなるトリガ信号(つまり、10μs毎に立ち上がるトリガ信号)Tgを、入力IC11の通信部15から処理IC13の通信部31へ供給するための信号線である。   Further, the signal line 5 sends a trigger signal Tg that goes high every time the timing signal is output from the timer 23 (that is, a trigger signal that rises every 10 μs) from the communication unit 15 of the input IC 11 to the communication unit of the processing IC 13. 31 is a signal line for supplying to 31.

次に、入力IC11と処理IC13との間でやり取りされる通信データのフォーマットについて、図2を用いて説明する。
まず、本実施形態において、両IC11,13間の1回の通信でやり取りされる通信データは、16ビットとなっている。
Next, the format of communication data exchanged between the input IC 11 and the processing IC 13 will be described with reference to FIG.
First, in this embodiment, communication data exchanged by one communication between both ICs 11 and 13 is 16 bits.

そして、処理IC13から入力IC11へは、図2(a)に示すように、コマンドAとコマンドBとの2種類のコマンドが送信される。
コマンドAは、機能設定用コマンドに相当し、入力IC11に対して、少なくとも、マルチプレクサ19に選択させるチャンネル(ch)と、アンプ21のゲインとを指示するコマンドである。
Then, two types of commands, command A and command B, are transmitted from the processing IC 13 to the input IC 11 as shown in FIG.
The command A corresponds to a function setting command, and is a command for instructing the input IC 11 at least a channel (ch) to be selected by the multiplexer 19 and the gain of the amplifier 21.

そして、コマンドAは、そのコマンドがコマンドAであることを示す2ビットのコマンドコード“10”と、マルチプレクサ19に選択させるチャンネルを示す2ビットと、アンプ21のゲインを示す3ビットと、その他の情報(その他1)を示す3ビットと、残りの6ビットとからなり、その残りの6ビットは未使用で常に“0”に設定される。   The command A includes a 2-bit command code “10” indicating that the command is the command A, 2 bits indicating the channel to be selected by the multiplexer 19, 3 bits indicating the gain of the amplifier 21, and the like. It consists of 3 bits indicating information (other 1) and the remaining 6 bits. The remaining 6 bits are unused and are always set to “0”.

また、コマンドBは、A/D変換要求コマンドに相当し、入力IC11に対して、A/D変換器17によるアナログ信号のA/D変換及びそのA/D変換値を要求するコマンドである。   Command B corresponds to an A / D conversion request command, and is a command for requesting A / D conversion of an analog signal by the A / D converter 17 and its A / D conversion value from the input IC 11.

そして、コマンドBは、そのコマンドがコマンドBであることを示す2ビットのコマンドコード“01”と、残りの14ビットとからなり、その残りの14ビットは未使用で常に“0”に設定される。   The command B includes a 2-bit command code “01” indicating that the command is the command B, and the remaining 14 bits. The remaining 14 bits are unused and are always set to “0”. The

一方、入力IC11から処理IC13へは、図2(b)に示すように、処理IC13からのコマンドAに対する設定結果を報告するための応答データ(以下、コマンドA応答データという)と、処理IC13からのコマンドBに対する応答データ(以下、コマンドB応答データという)とが送信される。   On the other hand, from the input IC 11 to the processing IC 13, as shown in FIG. 2B, response data for reporting the setting result for the command A from the processing IC 13 (hereinafter referred to as command A response data), and Response data for the command B (hereinafter referred to as command B response data) is transmitted.

そして、コマンドA応答データは、その応答データがコマンドAに対するものであることを示す2ビットのコマンドコード“10”と、マルチプレクサ19に実際に選択させたチャンネルを示す2ビットと、実際に設定したアンプ21のゲインを示す3ビットと、その他の情報(その他2)を示す3ビットと、残りの6ビットとからなり、その残りの6ビットは未使用で常に“0”に設定される。   The command A response data is actually set with a 2-bit command code “10” indicating that the response data is for command A, and 2 bits indicating the channel actually selected by the multiplexer 19. It consists of 3 bits indicating the gain of the amplifier 21, 3 bits indicating other information (other 2), and the remaining 6 bits. The remaining 6 bits are unused and are always set to "0".

また、コマンドB応答データは、その応答データがコマンドBに対するものであることを示す2ビットのコマンドコード“01”と、A/D変換器17によるA/D変換値である14ビットとからなる。   The command B response data is composed of a 2-bit command code “01” indicating that the response data is for the command B, and 14 bits as an A / D conversion value by the A / D converter 17. .

次に、入力IC11と処理IC13とで実施される通信の概要について、図3及び図4を用いて説明する。尚、以下の説明において、「CA」とはエンジンのクランク軸の回転角度(クランクアングル)を意味し、「TDC」とは気筒の上死点のことである。そして、図3の最上段は、エンジンの30°CA毎(クランク軸が30°回転する毎)のタイミングを示している。また、図4は、図3において点線の四角枠K1で囲んだ期間の通信状態を表したものである。   Next, an outline of communication performed between the input IC 11 and the processing IC 13 will be described with reference to FIGS. In the following description, “CA” means the rotation angle (crank angle) of the crankshaft of the engine, and “TDC” means the top dead center of the cylinder. 3 shows the timing of every 30 ° CA of the engine (each time the crankshaft rotates 30 °). FIG. 4 shows a communication state in a period surrounded by a dotted square frame K1 in FIG.

まず、図3に示すように、本実施形態では、各気筒のTDCのタイミングからATDC90°CA(TDCから90°CAだけ後)のタイミングまでが、その気筒についてのノック判定区間(ノッキングの有無を判定する対象の区間)となっている。   First, as shown in FIG. 3, in this embodiment, the knock determination interval (the presence / absence of knocking) for the cylinder from the TDC timing of each cylinder to the timing of ATDC 90 ° CA (after 90 ° CA from TDC) is determined. The section to be determined).

(1)そして、何れかの気筒のATDC90°CAのタイミングであって、その気筒のノック判定区間の終了タイミングになると、処理IC13から入力IC11へのチップセレクト信号CSがローレベルからハイレベル(非アクティブレベル)になって、両IC11,13間の通信が一旦終了し、その後、処理IC13にて次の通信期間のための準備処理が終了すると、この時点は次の気筒のノック判定区間が始まるTDCタイミングよりも十分に前であり、その時点で処理IC13から入力IC11へのチップセレクト信号CSがローレベルに切り替えられて、両IC11,13間の通信が再び開始される。   (1) Then, at the timing of ATDC 90 ° CA of any cylinder and the end timing of the knock determination section of that cylinder, the chip select signal CS from the processing IC 13 to the input IC 11 changes from low level to high level (non-level). Active level), the communication between the ICs 11 and 13 is temporarily terminated, and then the processing IC 13 completes the preparation process for the next communication period, and at this time, the knock determination section of the next cylinder starts. It is well before the TDC timing. At that time, the chip select signal CS from the processing IC 13 to the input IC 11 is switched to the low level, and communication between the ICs 11 and 13 is started again.

このため、チップセレクト信号CSは、何れかの気筒のATDC90°CAタイミングでローレベルからハイレベルとなり、次の気筒のTDCタイミングよりも十分に前のタイミングでハイレベルからローレベルになる。   For this reason, the chip select signal CS changes from the low level to the high level at the ATDC 90 ° CA timing of any cylinder, and changes from the high level to the low level sufficiently before the TDC timing of the next cylinder.

(2)ここで、チップセレクト信号CSがハイレベルからローレベルになると、図4に示すように、処理IC13の通信部31が、入力IC11へ、信号線2を介して通信クロックCLKを出力すると共に、その通信クロックCLKに同期して、レジスタ42内のコマンドA(コマンドA送信データ)を信号線3を介して1ビットずつ送信する。更に、これと並行して、処理IC13の通信部31は、上記通信クロックCLKに同期して、入力IC11から信号線4を介して送られてくるデータを1ビットずつ受信しレジスタ44に格納する。   (2) Here, when the chip select signal CS changes from the high level to the low level, the communication unit 31 of the processing IC 13 outputs the communication clock CLK to the input IC 11 via the signal line 2 as shown in FIG. At the same time, the command A (command A transmission data) in the register 42 is transmitted bit by bit through the signal line 3 in synchronization with the communication clock CLK. In parallel with this, the communication unit 31 of the processing IC 13 receives the data transmitted from the input IC 11 via the signal line 4 bit by bit in synchronization with the communication clock CLK and stores it in the register 44. .

(3)そして、入力IC11の通信部15は、上記通信クロックCLKに同期して、処理IC13から信号線3を介して送られてくるコマンドAを1ビットずつ受信し受信データレジスタ47に格納すると共に、その通信クロックCLKに同期して、送信データレジスタ46内の送信データを信号線4を介して1ビットずつ処理IC13へ送信する。   (3) The communication unit 15 of the input IC 11 receives the command A sent from the processing IC 13 via the signal line 3 bit by bit in synchronization with the communication clock CLK, and stores it in the reception data register 47. At the same time, the transmission data in the transmission data register 46 is transmitted to the processing IC 13 bit by bit via the signal line 4 in synchronization with the communication clock CLK.

このため、通信クロックCLKに同期して、処理IC13の通信部31におけるレジスタ42内のコマンドAが、入力IC11の通信部15における受信データレジスタ47へ転送されると共に、入力IC11の通信部15における送信データレジスタ46内の送信データが、処理IC13の通信部31におけるレジスタ44に転送されることとなる。   Therefore, in synchronization with the communication clock CLK, the command A in the register 42 in the communication unit 31 of the processing IC 13 is transferred to the reception data register 47 in the communication unit 15 of the input IC 11 and at the communication unit 15 of the input IC 11. The transmission data in the transmission data register 46 is transferred to the register 44 in the communication unit 31 of the processing IC 13.

尚、チップセレクト信号CSがローレベルになった直後において、入力IC11の通信部15における送信データレジスタ46内には、有効なデータが格納されていないため、入力IC11から処理IC13へ最初に送信されるデータは、デフォルト値のダミーデータとなる。また、入力IC11では、処理IC13から受信したコマンドAの指示内容に従って、マルチプレクサ19が選択する入力チャンネルがチャンネルch0とチャンネルch1との何れかに設定されると共に、アンプ21のゲインが設定される。また、チップセレクト信号CSがローレベルになってから、上記(2),(3)による両IC11,13間の1回目のデータ送受信(データ交換)が完了するまでの時間は、10μs未満である。   Immediately after the chip select signal CS becomes low level, valid data is not stored in the transmission data register 46 in the communication unit 15 of the input IC 11, so that it is first transmitted from the input IC 11 to the processing IC 13. The default data is dummy data. In the input IC 11, the input channel selected by the multiplexer 19 is set to either channel ch 0 or channel ch 1 and the gain of the amplifier 21 is set in accordance with the instruction content of the command A received from the processing IC 13. Also, the time from when the chip select signal CS becomes low level to when the first data transmission / reception (data exchange) between the ICs 11 and 13 according to (2) and (3) is completed is less than 10 μs. .

(4)一方、チップセレクト信号CSがローレベルになると、入力IC11では、タイマ23が起動されて、以後、10μs毎に、そのタイマ23からタイミング信号が出力される。尚、図4における「Timer」の段(下から2段目)において、上向き矢印(↑)は、タイマ23からタイミング信号が出力される10μs毎のタイミングを示している。   (4) On the other hand, when the chip select signal CS becomes low level, the input IC 11 starts the timer 23 and thereafter outputs a timing signal from the timer 23 every 10 μs. In the “Timer” stage (second stage from the bottom) in FIG. 4, the upward arrow (↑) indicates the timing of every 10 μs at which the timing signal is output from the timer 23.

(5)そして、タイマ23からタイミング信号が出力される毎に、入力IC11から処理IC13へのトリガ信号Tgがハイレベルとなると共に、入力IC11内においては、A/D変換器17が、マルチプレクサ19からアンプ21を介して入力されるアナログ信号をA/D変換する。   (5) Each time the timing signal is output from the timer 23, the trigger signal Tg from the input IC 11 to the processing IC 13 becomes high level, and the A / D converter 17 is connected to the multiplexer 19 in the input IC 11. A / D conversion is performed on the analog signal input via the amplifier 21.

(6)また、入力IC11からのトリガ信号Tgがハイレベルになると、処理IC13では、通信部31が、上記(2)と同様に、入力IC11へレジスタ42内のコマンドAを送信すると共に、入力IC11から送られてくるデータをレジスタ44に格納する。   (6) When the trigger signal Tg from the input IC 11 becomes high level, in the processing IC 13, the communication unit 31 transmits the command A in the register 42 to the input IC 11 and inputs the same as in (2) above. Data sent from the IC 11 is stored in the register 44.

(7)そして、入力IC11の通信部15も、上記(3)と同様の手順で、処理IC13からのコマンドAを受信データレジスタ47に格納すると共に、送信データレジスタ46内の送信データを処理IC13へ送信するが、この場合において、送信データレジスタ46には、前回受信したコマンドAに対する設定結果を報告するためのコマンドA応答データが格納されている。   (7) Then, the communication unit 15 of the input IC 11 also stores the command A from the processing IC 13 in the reception data register 47 and the transmission data in the transmission data register 46 in the processing IC 13 in the same procedure as the above (3). In this case, the transmission data register 46 stores command A response data for reporting the setting result for the command A received last time.

このため、処理IC13から入力IC11へは、前回と同じ内容のコマンドAが送信され、入力IC11から処理IC13へは、前回のコマンドAに対する設定結果を報告するためのコマンドA応答データ(図4中では「結果」とされている)が送信されることとなる。   Therefore, the command A having the same contents as the previous command is transmitted from the processing IC 13 to the input IC 11, and the command A response data for reporting the setting result for the previous command A (in FIG. 4). In this case, “result” is transmitted.

(8)その後、上記(6),(7)による両IC11,13間のデータ送受信が完了すると、入力IC11から処理IC13へのトリガ信号Tgがローレベルに戻る。
尚、本実施形態では、通信クロックCLKが2MHzであり、通信データが16ビットであるため、1回のデータ送受信に要する時間は8μs(=0.5μs×16)であり、また、トリガ信号Tgがハイレベルになってから通信が開始されるまでの遅れは1μs以下となっている。また更に、A/D変換器17がA/D変換に要する時間は9μs以内となっている。よって、両IC11,13の通信間隔である10μs以内に、1回のデータ送受信とA/D変換とが全て完了する。
(8) After that, when the data transmission / reception between the ICs 11 and 13 by the above (6) and (7) is completed, the trigger signal Tg from the input IC 11 to the processing IC 13 returns to the low level.
In this embodiment, since the communication clock CLK is 2 MHz and the communication data is 16 bits, the time required for one data transmission / reception is 8 μs (= 0.5 μs × 16), and the trigger signal Tg The delay from when the signal becomes high level to when communication is started is 1 μs or less. Furthermore, the time required for A / D conversion by the A / D converter 17 is within 9 μs. Therefore, all data transmission / reception and A / D conversion are completed within 10 μs, which is the communication interval between the ICs 11 and 13.

(9)そして、以後は、処理IC13からのコマンドAの送信回数が所定回数(本実施形態では、4回)となるまで、上記(6)〜(8)の動作が繰り返されることとなる。
尚、上記(2)〜(9)が、図4において点線の四角枠K2で囲まれた期間の動作である。
(9) Thereafter, the above operations (6) to (8) are repeated until the number of transmissions of the command A from the processing IC 13 reaches a predetermined number (4 times in the present embodiment).
Note that the above (2) to (9) are operations during a period surrounded by a dotted square frame K2 in FIG.

(10)処理IC13から送信されたコマンドAが4個目に達し、その後、入力IC11から処理IC13へのトリガ信号Tgがハイレベルになると、処理IC13の通信部31と入力IC11の通信部15とが、上記(6),(7)と同様にデータの送受信を行うが、この場合、処理IC13の通信部31は、入力IC11へ、レジスタ43内のコマンドBを送信し、それと並行して、入力IC11から送られてくるデータをレジスタ44に格納する。   (10) When the command A transmitted from the processing IC 13 reaches the fourth command, and then the trigger signal Tg from the input IC 11 to the processing IC 13 becomes high level, the communication unit 31 of the processing IC 13 and the communication unit 15 of the input IC 11 However, data is transmitted and received in the same manner as in (6) and (7) above. In this case, the communication unit 31 of the processing IC 13 transmits the command B in the register 43 to the input IC 11, and in parallel therewith, Data sent from the input IC 11 is stored in the register 44.

このため、4個目のコマンドAの転送が終了した後の最初のデータ送受信では、処理IC13から入力IC11へ、コマンドBが送信され、入力IC11から処理IC13へは、前回のコマンドAに対する設定結果を報告するためのコマンドA応答データが送信されて、そのコマンドA応答データがレジスタ44に格納されることとなる。   Therefore, in the first data transmission / reception after the transfer of the fourth command A is completed, the command B is transmitted from the processing IC 13 to the input IC 11, and the setting result for the previous command A is transmitted from the input IC 11 to the processing IC 13. Is transmitted, and the command A response data is stored in the register 44.

尚、この(10)が、図4において点線の四角枠K3で囲まれた期間の動作である。
(11)そして、その後、次の10μs毎のタイミングが到来して、入力IC11から処理IC13へのトリガ信号Tgがハイレベルになった場合にも、処理IC13の通信部31と入力IC11の通信部15とが、上記(6),(7)と同様にデータの送受信を行うが、この場合、処理IC13の通信部31は、入力IC11へレジスタ43内のコマンドBを送信すると共に、入力IC11から送られてくるデータを、レジスタ44ではなく、レジスタ45へ格納する。
This (10) is the operation during the period surrounded by the dotted square frame K3 in FIG.
(11) After that, when the next 10 μs timing comes and the trigger signal Tg from the input IC 11 to the processing IC 13 becomes high level, the communication unit 31 of the processing IC 13 and the communication unit of the input IC 11 15 transmits and receives data in the same manner as in the above (6) and (7). In this case, the communication unit 31 of the processing IC 13 transmits the command B in the register 43 to the input IC 11 and from the input IC 11. The sent data is stored not in the register 44 but in the register 45.

そして更に、入力IC11の通信部15は、処理IC13から送られてくるコマンドBを受信データレジスタ47に格納すると共に、送信データレジスタ46内の送信データを処理IC13へ送信するが、この場合において、送信データレジスタ46には、前回受信したコマンドBに対する応答データとして、A/D変換器17による最新のA/D変換値(即ち、前回のデータ送受信中にA/D変換器17によってA/D変換した値)を含んだコマンドB応答データが格納されている。   Further, the communication unit 15 of the input IC 11 stores the command B transmitted from the processing IC 13 in the reception data register 47 and transmits the transmission data in the transmission data register 46 to the processing IC 13. In this case, In the transmission data register 46, the latest A / D conversion value by the A / D converter 17 (that is, the A / D converter 17 by the A / D converter 17 during the previous data transmission / reception) as response data for the command B received last time. Command B response data including the converted value) is stored.

このため、処理IC13から入力IC11へは、前回と同じコマンドBが送信され、入力IC11から処理IC13へは、A/D変換器17による最新のA/D変換値を含んだコマンドB応答データ(図4中では「AD値」とされている)が送信されることとなる。   For this reason, the same command B as the previous one is transmitted from the processing IC 13 to the input IC 11, and the command B response data including the latest A / D conversion value by the A / D converter 17 is transmitted from the input IC 11 to the processing IC 13. In FIG. 4, "AD value" is transmitted.

(12)以後は、処理IC13から入力IC11へのチップセレクト信号CSがハイレベルになるまで、上記(11)の動作が繰り返されることとなる。
そして、上記(11),(12)が、図4において点線の四角枠K4で囲まれた期間の動作である。
(12) Thereafter, the operation of (11) is repeated until the chip select signal CS from the processing IC 13 to the input IC 11 becomes high level.
The above (11) and (12) are the operations during the period surrounded by the dotted square frame K4 in FIG.

尚、上記(11)にて、処理IC13側では、通信部31のレジスタ45に格納された入力IC11からのA/D変換値が、デジタルフィルタ35へそのまま転送されてデジタルフィルタ処理される。そして、そのデジタルフィルタ35による10μs毎のフィルタ処理結果はメモリ37に順次格納される。また、メモリ37には、10μs毎のフィルタ処理結果を、そのまま記憶するようにしても良いが、所定のクランク角度分や所定個数分ずつ積算するなどして、データ圧縮した形態で記憶するようにしても良い。一方、図4における「A/D変換処理」の段(最下段)において、左から3つ目までのA/D変換値に()を付けて「(AD変換)」と記載しているのは、その3つ目までのA/D変換値が実際にはデジタルフィルタ処理に使用されない(つまり、処理IC13へは送信されない)ことを表している。   In the above (11), on the processing IC 13 side, the A / D conversion value from the input IC 11 stored in the register 45 of the communication unit 31 is directly transferred to the digital filter 35 and subjected to digital filter processing. The filter processing results every 10 μs by the digital filter 35 are sequentially stored in the memory 37. The memory 37 may store the filter processing results every 10 μs as they are, but store them in a data-compressed form, for example, by adding a predetermined crank angle or a predetermined number. May be. On the other hand, in the "A / D conversion process" stage (bottom stage) in FIG. 4, the A / D conversion values from the left to the third A / D conversion value are indicated with "(AD conversion)". Indicates that the third A / D conversion value is not actually used for digital filter processing (that is, not transmitted to the processing IC 13).

次に、上記のようなIC11,13間の通信を実現するために、処理IC13のCPU39と、処理IC13の通信部31と、入力IC11の通信部15とで、それぞれ実行される処理の内容について、図5〜図7を用いて説明する。   Next, in order to realize the communication between the ICs 11 and 13 as described above, the contents of the processes respectively executed by the CPU 39 of the processing IC 13, the communication unit 31 of the processing IC 13, and the communication unit 15 of the input IC 11. This will be described with reference to FIGS.

まず図5は、処理IC13のCPU39にて30°CA毎に実行される30°CA割込処理の内容を表すフローチャートである。尚、この30°CA割込処理は、回転処理部33からの指令によって起動される。   First, FIG. 5 is a flowchart showing the contents of 30 ° CA interrupt processing executed every 30 ° CA by the CPU 39 of the processing IC 13. The 30 ° CA interrupt process is activated by a command from the rotation processing unit 33.

図5に示すように、処理IC13のCPU39が30°CA割込処理を開始すると、まずS110にて、回転処理部33により検出されている現在のクランク位置を参照して、今回の30°CA毎のタイミングが何れかの気筒のATDC90°CAのタイミングであるか否か(つまり、現在のクランク位置が何れかの気筒のATDC90°CAであるか否か)を判定する。   As shown in FIG. 5, when the CPU 39 of the processing IC 13 starts the 30 ° CA interrupt process, first, in S110, the current crank position detected by the rotation processing unit 33 is referred to and the current 30 ° CA is detected. It is determined whether each timing is the timing of ATDC 90 ° CA of any cylinder (that is, whether the current crank position is ATDC 90 ° CA of any cylinder).

ここで、何れかの気筒のATDC90°CAのタイミングでなければ(S110:NO)、そのまま処理を終了するが、何れかの気筒のATDC90°CAのタイミングであれば(S110:YES)、S120に進んで、デジタルフィルタ35と通信部31に停止指示を出して、それらの作動を停止させる。すると、通信部31は、後述する図6のS220にて、入力IC11へのチップセレクト信号CSをハイレベルにすることとなり、これに伴い、入力IC11の通信部15も通信動作を停止することとなる。   If it is not the timing of ATDC 90 ° CA of any cylinder (S110: NO), the processing is terminated as it is, but if it is the timing of ATDC 90 ° CA of any cylinder (S110: YES), the process proceeds to S120. Proceeding, a stop instruction is issued to the digital filter 35 and the communication unit 31 to stop their operations. Then, the communication unit 31 sets the chip select signal CS to the input IC 11 to the high level in S220 of FIG. 6 to be described later. Accordingly, the communication unit 15 of the input IC 11 also stops the communication operation. Become.

そして、続くS130にて、メモリ37からデジタルフィルタ35によるフィルタ処理結果を読み出す。尚、ここで読み出されるフィルタ処理結果のうち、前回のTDCタイミングから今回のATDC90°CAタイミングまでのフィルタ処理結果が、当該CPU39或いは他のCPUによるノック判定(ノッキングの有無の判定)に用いられ、更に、そのノック判定結果がエンジンの点火時期制御にフィードバックされる。   In subsequent S 130, the filter processing result by the digital filter 35 is read from the memory 37. Of the filter processing results read out here, the filter processing results from the previous TDC timing to the current ATDC 90 ° CA timing are used for knock determination (determination of knocking) by the CPU 39 or another CPU. Further, the knock determination result is fed back to the ignition timing control of the engine.

次にS140にて、通信部31のレジスタ44から受信データを読み出す。尚、この時にレジスタ44から読み出される受信データは、前回の通信期間中において、入力IC11が送信した最後のコマンドA応答データ(つまり、処理IC13がコマンドBを最初に送信した時に、入力IC11が送信したコマンドA応答データ)を受信したデータであって、図4の四角枠K3で囲まれた期間において入力IC11から受信したデータである。   Next, in S140, the received data is read from the register 44 of the communication unit 31. The received data read from the register 44 at this time is the last command A response data transmitted by the input IC 11 during the previous communication period (that is, the input IC 11 transmits when the processing IC 13 first transmits the command B). Command A response data) received from the input IC 11 during the period surrounded by the square frame K3 in FIG.

そして、次のS150にて、次の通信期間のための準備処理として、次の通信期間において入力IC11へ送信するコマンドAのデータ(コマンドA送信データ)を通信部31のレジスタ42に書き込むと共に、入力IC11へ送信するコマンドBのデータ(コマンドB送信データ)を通信部31のレジスタ43に書き込み、更に、コマンドAの送信個数(本実施形態では“4”)を通信部31のレジスタ41に書き込む。   Then, in the next S150, as preparation processing for the next communication period, the command A data (command A transmission data) to be transmitted to the input IC 11 in the next communication period is written in the register 42 of the communication unit 31, and Command B data (command B transmission data) to be transmitted to the input IC 11 is written to the register 43 of the communication unit 31, and further, the number of transmissions of the command A (“4” in this embodiment) is written to the register 41 of the communication unit 31. .

尚、このときにレジスタ42へ書き込むコマンドA送信データの各ビットのうち、マルチプレクサ19に選択させるチャンネルを示す2ビット(先頭から3ビット目と4ビット目)は、2つのノックセンサ27,29のうち、次にTDCを迎える気筒が設けられたバンク側のノックセンサからのアナログ信号が入力されているチャンネルを選択する値に設定される。よって、例えば、今回のATDC90°CAタイミングが、第6気筒#6のATDC90°CAタイミングであった場合、次にTDCを迎えるのは第1気筒#1であるため、レジスタ42へ書き込まれるコマンドA送信データの先頭から3ビット目と4ビット目は、右バンク側のノックセンサ27に対応したチャンネルch0を選択する値に設定される(図3参照)。   Of the bits of command A transmission data to be written to the register 42 at this time, 2 bits (third and fourth bits from the head) indicating the channel to be selected by the multiplexer 19 are the two knock sensors 27 and 29. Of these, the value is set to select a channel to which an analog signal is input from a knock sensor on the bank side where a cylinder that reaches TDC next is provided. Therefore, for example, if the current ATDC 90 ° CA timing is the ATDC 90 ° CA timing of the sixth cylinder # 6, the command A to be written to the register 42 is the first cylinder # 1 since it is the first cylinder # 1. The third and fourth bits from the beginning of the transmission data are set to values for selecting the channel ch0 corresponding to the knock sensor 27 on the right bank side (see FIG. 3).

次にS160にて、デジタルフィルタ35を初期化すると共に、そのデジタルフィルタ35と通信部31に起動指示を出して、それらを起動させる。すると、通信部31は、後述する図6のS230にて、入力IC11へのチップセレクト信号CSをハイレベルからローレベルにし、入力IC11との通信動作を開始することとなる。   Next, in S160, the digital filter 35 is initialized, and an activation instruction is issued to the digital filter 35 and the communication unit 31 to activate them. Then, the communication unit 31 changes the chip select signal CS to the input IC 11 from the high level to the low level in S230 of FIG. 6 to be described later, and starts the communication operation with the input IC 11.

次にS170にて、上記S140でレジスタ44から読み出した受信データ(コマンドA受信データ)の内容が正常であるか否かをチェックする。つまり、レジスタ44から読み出したコマンドA受信データが表す入力IC11側での設定結果内容と、前回の通信期間に入力IC11へ送信したコマンドAの設定指示内容とを比較して、両内容が一致していたならば正常と判定し、不一致ならば異常と判定する。   Next, in S170, it is checked whether or not the content of the reception data (command A reception data) read from the register 44 in S140 is normal. That is, the setting result content on the input IC 11 side represented by the command A received data read from the register 44 is compared with the setting instruction content of the command A transmitted to the input IC 11 during the previous communication period, and both contents match. If it matches, it is determined as normal, and if it does not match, it is determined as abnormal.

そして、このS170にて、正常と判定した場合には、そのまま当該30°CA割込処理を終了するが、異常と判定した場合には、S180に進んで、例えば、入力IC11をリセットするとか、上記S130でメモリ37から読み出したフィルタ処理結果をノック判定に用いずに破棄する、といったフェイルセーフ用の異常処理を実施し、その後、当該30°CA割込処理を終了する。   If it is determined in S170 that it is normal, the 30 ° CA interrupt processing is terminated as it is. If it is determined that there is an abnormality, the process proceeds to S180, for example, the input IC 11 is reset, Fail-safe abnormality processing such as discarding the filter processing result read from the memory 37 in S130 without using it for knock determination is performed, and then the 30 ° CA interrupt processing is terminated.

次に、図6に示すように、処理IC13の通信部31は、まずS210にて、CPU39が上記S120の処理で出す停止指示と、CPU39が上記S160の処理で出す起動指示との、何れかを受けるまで待機し、停止指示を受けたならば、S220へ進んで、入力IC11へのチップセレクト信号CSをハイレベルにする。そして、その後、S210に戻る。   Next, as shown in FIG. 6, the communication unit 31 of the processing IC 13 first, in S210, either a stop instruction issued by the CPU 39 in the process of S120 or a start instruction issued by the CPU 39 in the process of S160. If the stop instruction is received, the process proceeds to S220, and the chip select signal CS to the input IC 11 is set to the high level. Then, the process returns to S210.

また、CPU39からの起動指示を受けたならば、S210からS230へ移行して、入力IC11へのチップセレクト信号CSをローレベルにし、次のS240へ進む。
そして、S240では、上記(2)で述べたように、入力IC11へ、信号線2を介して通信クロックCLKを出力すると共に、その通信クロックCLKに同期して、レジスタ42内のコマンドA送信データ(即ち、CPU39が図5のS150でレジスタ42に書き込んだコマンドAのデータ)を信号線3を介して1ビットずつ送信し、更に、これと並行して、入力IC11から信号線4を介して送られてくるデータを1ビットずつ受信し、レジスタ44にコマンドA受信データとして格納する。但し、前述したように、チップセレクト信号CSがローレベルになってから最初のデータ送受信時において、入力IC11から送信されてくるデータは、デフォルト値のダミーデータである。
If the activation instruction is received from the CPU 39, the process proceeds from S210 to S230, the chip select signal CS to the input IC 11 is set to the low level, and the process proceeds to the next S240.
In S240, as described in (2) above, the communication clock CLK is output to the input IC 11 via the signal line 2, and the command A transmission data in the register 42 is synchronized with the communication clock CLK. (That is, the data of the command A written to the register 42 by the CPU 39 in S150 of FIG. 5) is transmitted bit by bit through the signal line 3, and in parallel with this, from the input IC 11 through the signal line 4 Received data is received bit by bit and stored in the register 44 as command A received data. However, as described above, at the time of the first data transmission / reception after the chip select signal CS becomes low level, the data transmitted from the input IC 11 is dummy data having a default value.

次にS250にて、CPU39からの停止指示を受けたか否かを判定し、停止指示を受けたならばS220へ移行するが、停止指示を受けていなければ、次のS260に進んで、入力IC11からのトリガ信号Tgがハイレベルか否かを判定する。   Next, in S250, it is determined whether or not a stop instruction is received from the CPU 39. If a stop instruction is received, the process proceeds to S220. If a stop instruction is not received, the process proceeds to the next S260 and the input IC11. It is determined whether the trigger signal Tg from is at a high level.

そして、トリガ信号Tgがハイレベルでなければ(ローレベルであれば)、S250へ戻るが、トリガ信号Tgがハイレベルになったならば(S260:YES)、S270に進む。   If the trigger signal Tg is not at a high level (if it is at a low level), the process returns to S250, but if the trigger signal Tg is at a high level (S260: YES), the process proceeds to S270.

S270では、レジスタ41内の送信個数(即ち、CPU39が図5のS150でレジスタ41に書き込んだコマンドAの送信個数=4)を読み出して、その読み出した送信個数を、“コマンドA個数”という変数として記憶すると共に、そのコマンドA個数の値をデクリメント(−1)する。   In S270, the number of transmissions in the register 41 (that is, the number of transmissions of the command A written by the CPU 39 to the register 41 in S150 in FIG. 5 = 4) is read, and the number of transmissions read is a variable “command A number”. And the value of the command A number is decremented (−1).

そして、次のS280にて、コマンドA個数の値が0になったか否かを判定し、コマンドA個数の値が0でなければ、S240へ戻る。また、上記S280にて、コマンドA個数値が0であると判定した場合には、S240へ戻らずにS290へ進む。   Then, in the next S280, it is determined whether or not the value of the command A number has become 0. If the value of the command A number is not 0, the process returns to S240. If it is determined in S280 that the command A number value is 0, the process proceeds to S290 without returning to S240.

よって、処理IC13の通信部31は、上記S230でチップセレクト信号CSをローレベルにしてから、S240〜S280の処理を4回実施することとなり、これにより、入力IC11へのコマンドAの送信及び入力IC11からのデータ受信を4回実施することとなる。そして、このS240〜S280の処理により、上記(2)〜(9)で述べた図4の四角枠K2内の期間における通信動作が実現されている。   Therefore, the communication unit 31 of the processing IC 13 performs the processing of S240 to S280 four times after setting the chip select signal CS to the low level in S230, thereby transmitting and inputting the command A to the input IC11. Data reception from the IC 11 is performed four times. And the communication operation | movement in the period in the square frame K2 of FIG. 4 described by said (2)-(9) is implement | achieved by this process of S240-S280.

次にS290では、S240と同様のデータ送受信動作を行うが、入力IC11へは、レジスタ42内のコマンドA送信データではなく、レジスタ43内のコマンドB送信データ(即ち、CPU39が図5のS150でレジスタ43に書き込んだコマンドBのデータ)を送信する。   Next, in S290, the same data transmission / reception operation as in S240 is performed. However, the command B transmission data in the register 43 (that is, the CPU 39 in S150 in FIG. 5) is not sent to the input IC 11 but the command A transmission data in the register 42. The command B data written to the register 43 is transmitted.

そして、続くS300にて、CPU39からの停止指示を受けたか否かを判定し、停止指示を受けたならばS220へ移行するが、停止指示を受けていなければ、次のS310に進んで、入力IC11からのトリガ信号Tgがハイレベルか否かを判定する。そして、トリガ信号Tgがハイレベルでなければ(ローレベルであれば)、S300へ戻るが、トリガ信号Tgがハイレベルになったならば(S310:YES)、S320に進む。   Then, in subsequent S300, it is determined whether or not a stop instruction from the CPU 39 has been received. If a stop instruction has been received, the process proceeds to S220. If a stop instruction has not been received, the process proceeds to the next S310 to input. It is determined whether or not the trigger signal Tg from the IC 11 is at a high level. If the trigger signal Tg is not at a high level (if it is at a low level), the process returns to S300, but if the trigger signal Tg is at a high level (S310: YES), the process proceeds to S320.

よって、処理IC13の通信部31は、4個目のコマンドAを送信した後の最初のデータ送受信では、コマンドBを送信することとなり、レジスタ44には、前回送信したコマンドA(即ち、4個目のコマンドA)に対する設定結果を報告するための入力IC11からのコマンドA応答データが、コマンドA受信データとして格納されることとなる。   Therefore, the communication unit 31 of the processing IC 13 transmits the command B in the first data transmission / reception after transmitting the fourth command A, and the command A (that is, four commands) transmitted last time is transmitted to the register 44. Command A response data from the input IC 11 for reporting the setting result for the command A) of the eye is stored as command A received data.

そして、このS290〜S310の処理により、上記(10)で述べた図4の四角枠K3内の期間における通信動作が実現されている。
次にS320では、S290と同様のデータ送受信動作を行って、入力ICへ前回と同じコマンドBを送信するが、入力IC11から送られてくるデータは、レジスタ44ではなく、レジスタ45にコマンドB受信データとして格納する。そして、そのレジスタ45に格納したデータのうち、先頭の2ビットを除く下位14ビット(即ち、入力IC11からのA/D変換値)を、デジタルフィルタ35へ転送する。
And the communication operation in the period within the square frame K3 of FIG. 4 described in the above (10) is realized by the processing of S290 to S310.
Next, in S320, the same data transmission / reception operation as in S290 is performed, and the same command B as the previous one is transmitted to the input IC, but the data sent from the input IC11 is received by the register 45 instead of the register 44. Store as data. Of the data stored in the register 45, the lower 14 bits (that is, the A / D conversion value from the input IC 11) excluding the first 2 bits are transferred to the digital filter 35.

次にS330にて、CPU39からの停止指示を受けたか否かを判定し、停止指示を受けたならばS220へ移行するが、停止指示を受けていなければ、S340に進んで、入力IC11からのトリガ信号Tgがハイレベルか否かを判定する。そして、トリガ信号Tgがハイレベルでなければ(ローレベルであれば)、S330へ戻り、トリガ信号Tgがハイレベルになったならば(S340:YES)、S320に戻って、再び、データの送受信(詳しくは、入力IC11へのコマンドBの送信及び入力IC11からのコマンドB応答データの受信)を行う。   Next, in S330, it is determined whether or not a stop instruction is received from the CPU 39. If a stop instruction is received, the process proceeds to S220. If a stop instruction is not received, the process proceeds to S340 and the input IC 11 receives the instruction. It is determined whether or not the trigger signal Tg is at a high level. If the trigger signal Tg is not at a high level (if it is at a low level), the process returns to S330. If the trigger signal Tg is at a high level (S340: YES), the process returns to S320 to transmit / receive data again. (Specifically, the command B is transmitted to the input IC 11 and the command B response data is received from the input IC 11).

そして、このS320〜S340の処理により、上記(11),(12)で述べた図4の四角枠K4内の期間における通信動作が実現されている。
次に、図7に示すように、入力IC11の通信部15は、まずS410にて、処理IC13からのチップセレクト信号CSがローレベルか否かを判定し、チップセレクト信号CSがローレベルになるまで何もせずに待つ。つまり、通信動作を停止する。
And the communication operation in the period within the square frame K4 of FIG. 4 described in the above (11) and (12) is realized by the processing of S320 to S340.
Next, as shown in FIG. 7, the communication unit 15 of the input IC 11 first determines in S410 whether or not the chip select signal CS from the processing IC 13 is low level, and the chip select signal CS becomes low level. Wait without doing anything. That is, the communication operation is stopped.

そして、チップセレクト信号CSローレベルになったと判定すると(S410:YES)、S420に進み、処理IC13から信号線2を介して供給される通信クロックCLKに同期して、データの送受信を行う。   If it is determined that the chip select signal CS is at the low level (S410: YES), the process proceeds to S420, and data is transmitted and received in synchronization with the communication clock CLK supplied from the processing IC 13 via the signal line 2.

即ち、上記(3)で述べたように、処理IC13から信号線3を介して送られてくる16ビットのデータを1ビットずつ受信して受信データレジスタ47に格納すると共に、送信データレジスタ46内の16ビットの送信データを信号線4を介して1ビットずつ処理IC13へ送信する。但し、前述したように、チップセレクト信号CSがローレベルになってから最初に送信する送信データは、デフォルト値のダミーデータである。   That is, as described in the above (3), 16-bit data transmitted from the processing IC 13 via the signal line 3 is received bit by bit and stored in the reception data register 47, and in the transmission data register 46. 16-bit transmission data is transmitted to the processing IC 13 bit by bit through the signal line 4. However, as described above, the transmission data to be transmitted first after the chip select signal CS becomes the low level is the default value dummy data.

そして、このような16ビット分のデータ送受信が終わると、次のS430にて、処理IC13へのトリガ信号Tgをローレベルに設定する。尚、チップセレクト信号CSがハイレベルからローレベルに変化した時点でのトリガ信号Tgの初期値はローレベルであるため、最初のデータ送受信時において、トリガ信号Tgは継続してローレベルのままとなる(図4参照)。   When such 16-bit data transmission / reception is completed, the trigger signal Tg to the processing IC 13 is set to a low level in the next S430. Since the initial value of the trigger signal Tg when the chip select signal CS changes from the high level to the low level is the low level, the trigger signal Tg continues to remain at the low level at the time of the first data transmission / reception. (See FIG. 4).

そして、続くS440にて、上記S420で今回受信した受信データレジスタ47内の受信データにおける先頭の2ビット(コマンドコード)が“10”であるか否かにより、その受信データがコマンドAであるか否かを判定し、コマンドAであれば、S450に進んで、制御部25に、その受信したコマンドAの指示内容に従って、マルチプレクサ19が選択する入力チャンネルやアンプ21のゲインなどを設定させる。   In subsequent S440, whether the received data is command A depending on whether or not the first 2 bits (command code) in the received data in the received data register 47 received this time in S420 is “10”. If YES in step S450, the flow advances to step S450 to cause the control unit 25 to set the input channel selected by the multiplexer 19, the gain of the amplifier 21, and the like according to the instruction content of the received command A.

次にS460にて、次回の送信準備として、今回受信したコマンドAに対する設定結果(つまり、マルチプレクサ19に実際に選択させたチャンネルや実際に設定したアンプ21のゲインなど)を処理IC13へ報告するためのコマンドA応答データを作成して、送信データレジスタ46に格納する。   Next, in S460, in preparation for the next transmission, the setting result for the command A received this time (that is, the channel actually selected by the multiplexer 19 and the gain of the amplifier 21 actually set) is reported to the processing IC 13. Command A response data is generated and stored in the transmission data register 46.

そして、続くS470にて、チップセレクト信号CSがローレベルのままか否かを判定し、チップセレクト信号CSがローレベルでなければ(ハイレベルになったならば)、S410へ戻るが、チップセレクト信号CSがローレベルのままならば、S480に進んで、タイマ23から10μs毎のタイミング信号が出力されたか否かを判定する。そして、タイミング信号が出力されていなければ、S470に戻るが、タイミング信号が出力されたならば、S490に進む。   Then, in subsequent S470, it is determined whether or not the chip select signal CS remains at a low level. If the chip select signal CS is not at a low level (if it is at a high level), the process returns to S410, but the chip select signal CS is returned. If the signal CS remains at the low level, the process proceeds to S480, where it is determined whether or not the timing signal is output from the timer 23 every 10 μs. If the timing signal is not output, the process returns to S470. If the timing signal is output, the process proceeds to S490.

S490では、処理IC13へのトリガ信号Tgを、それまでのローレベルからハイレベルに設定し、次のS500にて、A/D変換器17にA/D変換を開始させる。そして、その後、S420に戻る。   In S490, the trigger signal Tg to the processing IC 13 is set from the low level until then to the high level, and in the next S500, the A / D converter 17 starts A / D conversion. Then, the process returns to S420.

すると、トリガ信号Tgがハイレベルになったことにより、S420にて、処理IC13とのデータ送受信が再び行われるが、この場合のS420では、前回のS460で送信データレジスタ46に格納しておいたコマンドA応答データを処理IC13へ送信することとなる。   Then, since the trigger signal Tg becomes high level, data transmission / reception with the processing IC 13 is performed again in S420. In this case, in S420, the data was stored in the transmission data register 46 in the previous S460. The command A response data is transmitted to the processing IC 13.

そして、処理IC13からコマンドAが送信され続けて、上記S440で受信データがコマンドAであると判定している間は、S420〜S500の処理が繰り返されることとなる。そして、このS420〜S500の処理により、図4の四角枠K2,K3内の期間における通信動作が実現される。   Then, while the command A is continuously transmitted from the processing IC 13 and it is determined in S440 that the received data is the command A, the processing of S420 to S500 is repeated. And the communication operation in the period in the square frames K2 and K3 in FIG. 4 is realized by the processing of S420 to S500.

一方、上記S440にて、S420で今回受信した受信データがコマンドAではないと判定した場合には(S440:NO)、今回受信したデータがコマンドBであると判断して、S510に移行する。尚、このような判断ができるのは、本実施形態では、処理IC13から入力IC11へ送信されるのが、コマンドAかコマンドBの何れか一方であるからである。   On the other hand, if it is determined in S440 that the received data received this time in S420 is not command A (S440: NO), it is determined that the data received this time is command B, and the process proceeds to S510. Note that such a determination can be made because, in the present embodiment, either the command A or the command B is transmitted from the processing IC 13 to the input IC 11.

S510では、今回受信した受信データレジスタ47内の受信データがコマンドBであるか否かを、その受信データにおける先頭の2ビット(コマンドコード)に基づいて念のため確認する。即ち、受信データにおける先頭の2ビットが“01”であるか否かを確認する。尚、もし、受信データがコマンドBでなかったならば、不定コマンドを受信したという異常(即ち、コマンドBを受信するはずなのに、コマンドBではないコマンドを受信したという異常)が発生したことを示す異常情報を記憶しておく。   In S510, it is confirmed as a precaution based on the first two bits (command code) in the received data whether the received data in the received data register 47 received this time is the command B or not. That is, it is confirmed whether or not the first two bits in the received data are “01”. If the received data is not command B, it indicates that an abnormality that an indefinite command has been received (that is, an abnormality that a command that is not command B but that command B should have been received) has occurred. Anomaly information is stored.

そして、次のS520にて、次回の送信準備として、今回受信したコマンドBに対する応答データとして、A/D変換器17による最新のA/D変換値(即ち、今回のデータ送受信中にA/D変換器17によってA/D変換した値)を含んだコマンドB応答データを作成し、それを送信データレジスタ46に格納する。   In the next S520, as the next transmission preparation, as the response data for the command B received this time, the latest A / D conversion value by the A / D converter 17 (that is, the A / D during the current data transmission / reception). Command B response data including the value A / D converted by the converter 17 is created and stored in the transmission data register 46.

そして、続くS530にて、チップセレクト信号CSがローレベルのままか否かを判定し、チップセレクト信号CSがローレベルでなければ(ハイレベルになったならば)、S410へ戻るが、チップセレクト信号CSがローレベルのままならば、S540に進んで、タイマ23から10μs毎のタイミング信号が出力されたか否かを判定する。そして、タイミング信号が出力されていなければ、S530に戻るが、タイミング信号が出力されたならば、S550に進む。   In subsequent S530, it is determined whether or not the chip select signal CS remains at a low level. If the chip select signal CS is not at a low level (if it has become a high level), the process returns to S410. If the signal CS remains at the low level, the process proceeds to S540, and it is determined whether or not the timing signal is output from the timer 23 every 10 μs. If the timing signal is not output, the process returns to S530, but if the timing signal is output, the process proceeds to S550.

S550では、処理IC13へのトリガ信号Tgを、それまでのローレベルからハイレベルに設定し、次のS560にて、A/D変換器17にA/D変換を開始させる。
そして、その後、S570に進み、上記S420と同様に、処理IC13から信号線2を介して供給される通信クロックCLKに同期して、データの送受信を行う。但し、この場合には、前回のS520で送信データレジスタ46に格納しておいたコマンドB応答データを処理IC13へ送信することとなる。
In S550, the trigger signal Tg to the processing IC 13 is set from the low level until then to the high level, and in the next S560, the A / D converter 17 starts A / D conversion.
Thereafter, the process proceeds to S570, and data is transmitted and received in synchronization with the communication clock CLK supplied from the processing IC 13 via the signal line 2 in the same manner as in S420. However, in this case, the command B response data stored in the transmission data register 46 in the previous S520 is transmitted to the processing IC 13.

そして、このS570にて16ビット分のデータ送受信が終わると、S580に進んで、処理IC13へのトリガ信号Tgをローレベルに設定し、その後、S510へ戻る。
このため、S440にて受信データがコマンドAではない(コマンドBである)と判定して、S510へ移行した後は、S530にてチップセレクト信号CSがハイレベルになったと判定するまで、S510〜S580の処理が繰り返され、タイマ23からタイミング信号が出力される毎に、処理IC13からのコマンドBを受信すると共に、処理IC13へ10μs毎の最新のA/D変換値をコマンドB応答データとして送信することとなる。そして更に、このようなS510〜S580の処理は、処理IC13からのコマンドがコマンドBであるか否かに拘わらず、繰り返されることとなり、このS510〜S580の処理により、図4の四角枠K4内の期間における通信動作が実現される。
When data transmission / reception of 16 bits is completed in S570, the process proceeds to S580, the trigger signal Tg to the processing IC 13 is set to a low level, and then the process returns to S510.
For this reason, after determining that the received data is not command A (command B) in S440 and proceeding to S510, S510 to S530 until it is determined that the chip select signal CS has become high level. Every time the processing of S580 is repeated and the timing signal is output from the timer 23, the command B is received from the processing IC 13 and the latest A / D conversion value every 10 μs is transmitted to the processing IC 13 as command B response data. Will be. Further, the processing of S510 to S580 is repeated regardless of whether or not the command from the processing IC 13 is the command B. By the processing of S510 to S580, the processing within the rectangular frame K4 in FIG. The communication operation during the period is realized.

以上のような本実施形態の信号処理装置では、処理IC13が、入力IC11へのチップセレクト信号CSをローレベルにした状態で、入力IC11へコマンドBを一定時間Tc(=10μs)毎に送信し、入力IC11が、そのコマンドBを受信する毎に、A/D変換器17によるアナログ信号のA/D変換値をコマンドB応答データとして処理IC13へ返送することにより、入力IC11から処理IC13へ、一定時間Tc毎のA/D変換値が転送され、その一定時間Tc毎のA/D変換値が処理IC13側のデジタルフィルタ35にてデジタルフィルタ処理される。   In the signal processing apparatus of the present embodiment as described above, the processing IC 13 transmits the command B to the input IC 11 every predetermined time Tc (= 10 μs) while the chip select signal CS to the input IC 11 is at a low level. Each time the input IC 11 receives the command B, the A / D conversion value of the analog signal by the A / D converter 17 is returned to the processing IC 13 as command B response data, so that the input IC 11 returns to the processing IC 13. The A / D conversion value for every fixed time Tc is transferred, and the A / D conversion value for every fixed time Tc is digitally filtered by the digital filter 35 on the processing IC 13 side.

そして特に、本実施形態の信号処理装置において、入力IC11は、チップセレクト信号CSがローレベルになってから、コマンドBを受信したと一度判断すると(S440:NO)、その後、チップセレクト信号CSがハイレベルとなるまでは、処理IC13からのコマンドがコマンドBであるか否かに拘わらず、その処理IC13からのコマンドを受信する毎に、A/D変換器17による最新のA/D変換値の送信(コマンドB応答データの送信)を実施するようになっている。   In particular, in the signal processing apparatus according to the present embodiment, when the input IC 11 determines once that the command B has been received after the chip select signal CS becomes low level (S440: NO), then the chip select signal CS is Until a high level is reached, the latest A / D conversion value by the A / D converter 17 is received each time a command from the processing IC 13 is received, regardless of whether the command from the processing IC 13 is the command B or not. (Command B response data transmission) is performed.

このため、本実施形態の信号処理装置によれば、入力IC11は、図4の四角枠K4内の期間に例示するように、チップセレクト信号CSがローレベルになってから一度でもコマンドBを受信した後は、処理IC13からのコマンドBにノイズが乗って、そのコマンドBを不定なコマンド(未定義コマンド)やコマンドAとして受信したとしても、ノイズが乗らなかった場合と全く同様に、処理IC13へAD変換値を送信することとなるため、処理IC13では、正しい時系列のA/D変換値を受信することができ、その処理IC13側にて、デジタルフィルタ35へ入力されるA/D変換値が途中で欠けたり、いきなり不定な値になってしまうことが防止される。よって、デジタルフィルタ処理を正確に実施することができる。   Therefore, according to the signal processing apparatus of the present embodiment, the input IC 11 receives the command B even once after the chip select signal CS becomes low level, as exemplified in the period within the square frame K4 in FIG. After that, even if noise is added to the command B from the processing IC 13 and the command B is received as an indefinite command (undefined command) or command A, the processing IC 13 is exactly the same as when no noise is applied. Since the AD conversion value is transmitted to the processing IC 13, the correct time-series A / D conversion value can be received by the processing IC 13, and the A / D conversion input to the digital filter 35 on the processing IC 13 side. It is possible to prevent the value from being cut off in the middle or suddenly becoming an indefinite value. Therefore, digital filter processing can be performed accurately.

例えば、仮に本発明が適用されていないとすると、処理IC13から入力IC11への信号線3にノイズが乗って、コマンドBが不定なコマンドとなった場合、入力IC11から処理IC13へA/D変換値が返送されないか、或いは、不定値が返送されることとなる。すると、図8(a)に示すように、デジタルフィルタ35への入力が不定値(この例では0)となって、異なった周波数として処理されてしまい、その結果、正しいノック判定を行うことができなくなってしまう。   For example, if the present invention is not applied, if the signal B 3 from the processing IC 13 to the input IC 11 has noise and the command B becomes an indefinite command, the A / D conversion from the input IC 11 to the processing IC 13 is performed. Either no value is returned or an indefinite value is returned. Then, as shown in FIG. 8A, the input to the digital filter 35 becomes an indefinite value (0 in this example) and is processed as a different frequency. As a result, correct knock determination can be performed. It becomes impossible.

また、処理IC13から入力IC11への信号線3にノイズが乗って、コマンドBがコマンドAとなった場合、入力IC11では、マルチプレクサ19の選択チャンネル(詳しくは、マルチプレクサ19が選択する入力チャンネル)やアンプ21のゲインを不要に切り替えてしまう。すると、図8(b)に示すように、それ以降のデジタルフィルタ35への入力が、違う入力チャンネルのA/D変換値や異なったゲインでのA/D変換値となってしまい、やはり、正しいノック判定を行うことができない。特に、A/D変換器17がオーバーサンプリング方式のA/D変換器である場合、入力チャンネルやゲインが変わって、それまでとは全く違った電圧が入力されると、その後、たとえ正しい設定に戻せたとしても、A/D変換器17の出力が収束するまでに時間がかかり、ノイズ発生タイミング以降も数回分は影響が残ってしまう。   When the signal B 3 from the processing IC 13 to the input IC 11 is noised and the command B becomes the command A, the input IC 11 has a selection channel of the multiplexer 19 (specifically, an input channel selected by the multiplexer 19) or The gain of the amplifier 21 is switched unnecessarily. Then, as shown in FIG. 8B, the subsequent input to the digital filter 35 becomes an A / D conversion value of a different input channel or an A / D conversion value with a different gain. A correct knock determination cannot be made. In particular, when the A / D converter 17 is an oversampling A / D converter, if the input channel or gain changes and a completely different voltage is input, then the correct setting is made. Even if it can be restored, it takes time until the output of the A / D converter 17 converges, and the influence remains several times after the noise generation timing.

これに対して、本実施形態の信号処理装置において、入力IC11は、一度コマンドBを受信した後は、何のコマンドが来たとしても、コマンドBに対する動作を行うため、信号線3にノイズが乗っても、処理IC13では、連続した正しいA/D変換値を取り込んで、デジタルフィルタ処理を正しく実施することができる。よって、正しいノック判定を行うことができる。   On the other hand, in the signal processing apparatus according to the present embodiment, after receiving the command B once, the input IC 11 performs an operation on the command B no matter what command is received, so that noise is generated in the signal line 3. Even if it is on the board, the processing IC 13 can capture the correct A / D conversion values and carry out the digital filter processing correctly. Therefore, correct knock determination can be performed.

また、本実施形態の信号処理装置において、処理IC13は、チップセレクト信号CSをローレベルにした後、入力IC11へ、機能設定用のコマンドAを送信してからコマンドBの送信を開始し、入力IC11は、コマンドAを受信すると、そのコマンドAに応じて、マルチプレクサ19の選択チャンネルやアンプ21のゲインを設定するようになっている。このため、入力IC11と処理IC13との通信期間毎に、処理IC13から入力IC11へコマンドBに先立って送信するコマンドAにより、その入力IC11での上記選択チャンネルやゲインの設定を変えることができる。   Further, in the signal processing apparatus of the present embodiment, the processing IC 13 sets the chip select signal CS to the low level, then transmits the function setting command A to the input IC 11 and then starts to transmit the command B. When receiving the command A, the IC 11 sets the selected channel of the multiplexer 19 and the gain of the amplifier 21 according to the command A. Therefore, for each communication period between the input IC 11 and the processing IC 13, the setting of the selected channel and gain in the input IC 11 can be changed by the command A transmitted from the processing IC 13 to the input IC 11 prior to the command B.

ここで、本実施形態において、処理IC13がコマンドAを送信する回数は、4回に設定されていたが、それは以下の理由による。
まず、本実施形態において、チップセレクト信号CSがローレベルになってからA/D変換器17の出力を安定させるまでには、所定の時間T1を要する。これは、A/D変換器17としてオーバーサンプリング方式のA/D変換器を用いており、そのA/D変換器17自身のキャリブレーション時間(出力安定化時間)として数十μs必要であり、更に、マルチプレクサ19の選択チャンネルとアンプ21のゲインを変更するのにも一定の時間が必要なためである。そして、本実施形態では、上記所定の時間T1として、30μs必要となっている。
Here, in the present embodiment, the number of times that the processing IC 13 transmits the command A is set to four times, for the following reason.
First, in the present embodiment, a predetermined time T1 is required until the output of the A / D converter 17 is stabilized after the chip select signal CS becomes low level. This uses an oversampling A / D converter as the A / D converter 17 and requires several tens of μs as a calibration time (output stabilization time) of the A / D converter 17 itself. Furthermore, it is because a certain time is required to change the selected channel of the multiplexer 19 and the gain of the amplifier 21. In the present embodiment, 30 μs is required as the predetermined time T1.

そこで、本実施形態では、処理IC13がコマンドAを、「T1/Tc=30μs/10μs」以上の整数値である4回送信するようにして、A/D変換器17の出力が安定するまでの時間を稼いでいる。   Therefore, in this embodiment, the processing IC 13 transmits the command A four times, which is an integer value equal to or greater than “T1 / Tc = 30 μs / 10 μs”, until the output of the A / D converter 17 becomes stable. Earn time.

このため、入力IC11から処理IC13へは、コマンドBに対するコマンドB応答データとして、A/D変換器17の出力が安定した後のA/D変換値が最初から返送されることとなり、処理IC13側でのデジタルフィルタ処理の正確性を高めることができる。また、故意に遅延を設けるための特別なコマンドを設定する必要もない。   For this reason, the A / D conversion value after the output of the A / D converter 17 is stabilized is returned as the command B response data for the command B from the input IC 11 to the processing IC 13. The accuracy of the digital filter processing at can be improved. In addition, it is not necessary to set a special command for intentionally providing a delay.

一方更に、本実施形態の信号処理装置において、処理IC13は、各気筒のノック判定区間が終了するATDC90°CAのタイミングで、チップセレクト信号CSをローレベルからハイレベルにし、その直後であって、次の気筒のノック判定区間が到来するTDCタイミングよりも十分前に、チップセレクト信号CSをローレベルにして、コマンドAの送信を開始することにより、次の気筒のノッキングを判定するためのアナログ信号を入力IC11のマルチプレクサ19に選択させ、コマンドBの送信も開始するようになっている。そして、これにより、各気筒のノック判定区間が開始される前から、A/D変換及びデジタルフィルタ処理を開始できるようにしている。   On the other hand, in the signal processing device of the present embodiment, the processing IC 13 changes the chip select signal CS from low level to high level at the timing of ATDC 90 ° CA when the knock determination section of each cylinder ends, and immediately after that, An analog signal for determining the knocking of the next cylinder by starting the transmission of the command A by setting the chip select signal CS to the low level sufficiently before the TDC timing at which the knocking determination section of the next cylinder arrives. Is selected by the multiplexer 19 of the input IC 11 and the transmission of the command B is also started. Thus, A / D conversion and digital filter processing can be started before the knock determination section of each cylinder is started.

このため、ノック判定区間が始まる前に、A/D変換器17は元よりデジタルフィルタ35の出力値(デジタルフィルタ処理結果)も安定化させることが可能となり、延いては、そのデジタルフィルタ処理結果を用いたノック判定の精度を向上させることができる。つまり、各気筒のBTDC90°CAからTDCまでの期間は、デジタルフィルタ35の出力値を安定化させるための期間になっている。   For this reason, before the knock determination section starts, the A / D converter 17 can also stabilize the output value (digital filter processing result) of the digital filter 35 from the beginning, and consequently the digital filter processing result. The accuracy of knock determination using can be improved. That is, the period from BTDC 90 ° CA to TDC of each cylinder is a period for stabilizing the output value of the digital filter 35.

また、本実施形態において、処理IC13の通信部31は、コマンドAに対する応答結果としてのコマンドA受信データが格納されるレジスタ44と、コマンドBに対する応答結果としてのコマンドB受信デーが格納されるレジスタ45とを別々に備えている。   In this embodiment, the communication unit 31 of the processing IC 13 includes a register 44 that stores command A reception data as a response result to the command A, and a register that stores command B reception data as a response result to the command B. And 45 separately.

このため、コマンドA受信データがコマンドB受信データで上書きされてしまうことがなく、処理IC13のCPU39は、入力IC11との通信終了後に、レジスタ44からコマンドA受信データを読み出して(S140)、そのコマンドA受信データのチェック(S170)を行うことができ、そのCPU39の処理負荷を低減させることができる。   Therefore, the command A received data is not overwritten with the command B received data, and the CPU 39 of the processing IC 13 reads the command A received data from the register 44 after the communication with the input IC 11 is finished (S140). Command A received data can be checked (S170), and the processing load on the CPU 39 can be reduced.

尚、このようにレジスタ44とレジスタ45とを別に設ける構成は、「入力IC11がコマンドB(A/D変換要求コマンド)を一度受信した後、チップセレクト信号CS(通信許可信号)が非アクティブレベルとなるまでは、処理IC13からのコマンドがコマンドBであるか否かに拘わらず、処理IC13からのコマンドを受信する毎に処理IC13へA/D変換器17によるアナログ信号のA/D変換値を送信する」構成でなくても用いることができる。   The configuration in which the register 44 and the register 45 are separately provided in this way is as follows: “After the input IC 11 receives the command B (A / D conversion request command) once, the chip select signal CS (communication permission signal) is inactive level. Until the command is received, the A / D conversion value of the analog signal by the A / D converter 17 is sent to the processing IC 13 every time the command from the processing IC 13 is received regardless of whether the command from the processing IC 13 is the command B or not. It can be used even if it is not a configuration of “transmitting”.

つまり、入力IC11を第1装置と呼び、処理IC13を第2装置と呼ぶことにすると、第2装置は、下記のフィルタ処理用装置の特徴を有していれば良い。
即ち、「アナログ信号をA/D変換するA/D変換器を有すると共に、外部からの通信許可信号がアクティブレベルである場合に他の装置と通信ラインを介して通信する第1装置と、
前記第1装置と前記通信ラインを介して接続され、前記通信許可信号をアクティブレベルにして前記第1装置と一定時間毎に通信することにより、前記A/D変換器による前記アナログ信号の一定時間毎のA/D変換値を順次取得して、その取得した時系列のA/D変換値に対しデジタルフィルタ処理を行う第2装置とからなり、
前記第2装置が、前記通信許可信号をアクティブレベルにした状態で、前記第1装置へ複数種類のコマンドのうちのA/D変換要求コマンドを一定時間毎に送信し、前記第1装置が、前記A/D変換要求コマンドを受信する毎に、前記A/D変換器による前記アナログ信号のA/D変換値を前記第2装置へ返送することにより、前記第1装置から前記第2装置へ、前記A/D変換器による前記アナログ信号の一定時間毎のA/D変換値が転送され、
更に、前記第2装置は、前記通信許可信号をアクティブレベルにした後、前記第1装置へ、前記A/D変換要求コマンド以外の機能設定用コマンドを所定個数だけ送信してから、前記A/D変換要求コマンドの送信を開始する信号処理装置において、前記第2装置として用いられるフィルタ処理用装置であって、
前記機能設定用コマンドに対する前記第1装置からの受信データが格納される第1格納部と、前記A/D変換要求コマンドに対する前記第1装置からの受信データが格納される第2格納部とを別々に備えること、を特徴とするフィルタ処理用装置」である。
That is, if the input IC 11 is called a first device and the processing IC 13 is called a second device, the second device only needs to have the characteristics of the following filter processing device.
That is, “a first device that has an A / D converter that A / D converts an analog signal and communicates with another device via a communication line when an external communication permission signal is at an active level;
The analog signal by the A / D converter is connected for a certain time by being connected to the first device via the communication line and communicating with the first device at a certain time by setting the communication permission signal to an active level. A second device that sequentially acquires each A / D conversion value and performs digital filter processing on the acquired time-series A / D conversion value;
The second device transmits an A / D conversion request command of a plurality of types of commands to the first device at regular intervals in a state where the communication permission signal is set to an active level. Each time the A / D conversion request command is received, the A / D conversion value of the analog signal by the A / D converter is returned to the second device, thereby the first device to the second device. The A / D conversion value of the analog signal by the A / D converter is transferred at regular intervals,
Further, after setting the communication permission signal to an active level, the second device transmits a predetermined number of function setting commands other than the A / D conversion request command to the first device, and then the A / D In the signal processing device for starting transmission of the D conversion request command, a filter processing device used as the second device,
A first storage for storing received data from the first device for the function setting command; and a second storage for storing received data from the first device for the A / D conversion request command. A filter processing device characterized by being provided separately.

そして、このような特徴を有した第2装置によれば、その第2装置から第1装置への機能設定用コマンドにノイズが乗った場合でも、図5のS170について述べたように、第1格納部に格納された受信データ(機能設定用コマンドに対する第1装置からの受信データ)と、その第2装置から第1装置へ送信した機能設定用コマンドのデータとを比較することにより、通信異常を検出することができ、間違ったデータがデジタルフィルタに使用されたか否かを確実に確認することができるため、デジタルフィルタ処理を正確に実施可能にすることができる。   Then, according to the second device having such a feature, as described in S170 of FIG. 5, even when noise is applied to the function setting command from the second device to the first device, By comparing the received data stored in the storage unit (received data from the first device for the function setting command) with the data of the function setting command transmitted from the second device to the first device, communication error Can be detected and whether or not wrong data has been used for the digital filter can be surely confirmed, so that the digital filter processing can be performed accurately.

一方更に、上記実施形態では、一定時間Tc毎のタイミング信号が入力IC11側で生成され、そのタイミング信号に従って、A/D変換器17によるアナログ信号のA/D変換と両IC11,12間の通信とが実行されるようになっている。   On the other hand, in the above-described embodiment, a timing signal for every predetermined time Tc is generated on the input IC 11 side, and according to the timing signal, A / D conversion of the analog signal by the A / D converter 17 and communication between the ICs 11 and 12 are performed. And are to be executed.

このため、A/D変換間隔を正確なものにすることができる。つまり、逆の構成として、処理IC13がタイミングを決定する上でのマスターとなり、例えば、入力IC11は、処理IC13からの一定時間Tc毎のコマンドを受信するとA/D変換器17を起動させると共にA/D変換値を送信する、といった構成も考えられるが、この構成の場合には、通信遅延などによってA/D変換タイミングがずれてしまう可能性がある。これに対して、本実施形態の信号処理装置によれば、正確な一定時間Tc毎のA/D変換値に対してデジタルフィルタ処理を実施することができ、そのフィルタ処理結果を用いるノック判定の精度を高めることができる。   For this reason, the A / D conversion interval can be made accurate. In other words, as a reverse configuration, the processing IC 13 becomes a master for determining the timing. For example, when the input IC 11 receives a command from the processing IC 13 every predetermined time Tc, the A / D converter 17 is activated and A Although a configuration in which a / D conversion value is transmitted is also conceivable, in this configuration, there is a possibility that the A / D conversion timing is shifted due to a communication delay or the like. On the other hand, according to the signal processing device of the present embodiment, digital filter processing can be performed on an accurate A / D conversion value for each constant time Tc, and knock determination using the filter processing result can be performed. Accuracy can be increased.

ところで、上記実施形態において、入力IC11の通信部15は、図7のS440にて、受信データの先頭2ビットがコマンドAを示す“10”であるか否かを判定し、“10”でなければ、その受信データがコマンドBであると判断するようにしていたが、S440では、受信データの先頭2ビットがコマンドBを示す“01”であるか否かを判定して、“01”でなければ、受信データがコマンドAであると判断してS450へ進み、“01”であれば、受信データがコマンドBであると判断してS510へ移行するように構成しても良い。   By the way, in the above embodiment, the communication unit 15 of the input IC 11 determines whether or not the first two bits of the received data are “10” indicating the command A in S440 of FIG. For example, it is determined that the received data is the command B, but in S440, it is determined whether or not the first 2 bits of the received data are “01” indicating the command B. Otherwise, it is determined that the received data is the command A and the process proceeds to S450. If “01”, the received data is determined to be the command B and the process proceeds to S510.

また、上記実施形態において、処理IC13のCPU39は、図5のS150にて、レジスタ42に書き込むコマンドA送信データ内に、コマンドAの送信個数を含ませるようにしても良い。例えば、コマンドA送信データの先頭から8〜10ビット目の3ビット(図2にて「その他1」と記した3ビット)を、コマンドAの送信個数を表すデータにすることができる。そして、このようにすれば、処理IC13から入力IC11へ、コマンドAの送信回数が、そのコマンドA中に含まれて送信されることとなる。   In the above embodiment, the CPU 39 of the processing IC 13 may include the number of command A transmissions in the command A transmission data written to the register 42 in S150 of FIG. For example, 3 bits of the 8th to 10th bits (3 bits indicated as “other 1” in FIG. 2) from the head of the command A transmission data can be used as data representing the number of commands A transmitted. In this way, the number of transmissions of the command A is included in the command A and transmitted from the processing IC 13 to the input IC 11.

そして更に、この場合、入力IC11では、処理IC13からのコマンドA中に含まれている送信個数と、チップセレクト信号CSがローレベルになってから処理IC13から実際に送信されて来たコマンドAの数(即ち、図7のS440からS450へ進んだ連続回数)とを比較して、不一致ならば異常と判断すれば良い。   Further, in this case, the input IC 11 includes the number of transmissions included in the command A from the processing IC 13 and the command A actually transmitted from the processing IC 13 after the chip select signal CS becomes low level. The number (that is, the number of continuous times from S440 to S450 in FIG. 7) is compared.

このように構成すれば、入力IC11は、例えば、処理IC13からのコマンドAがノイズによりコマンドBにデータ化けして、そのデータ化けしたコマンドBを受信したとしても、そのような異常(つまり、コマンドAの数が正常値でないというコマンド数異常)の発生を検知することができる。   With this configuration, even when the command A from the processing IC 13 is garbled into the command B due to noise and the garbled command B is received, for example, the input IC 11 receives such an abnormality (that is, the command It is possible to detect the occurrence of a command number abnormality in which the number of A is not a normal value.

また、上記実施形態において、入力IC11の通信部15は、チップセレクト信号CSがローレベルである通信期間中に発生した通信異常を表す異常情報(例えば、図7のS510で記憶した異常情報)を、チップセレクト信号CSが一旦ハイレベルとなって次にローレベルとなった次回の通信期間にて、コマンドA応答データ中に含ませて処理IC13へ送信するように構成することもできる。例えば、通信部15は、図7のS460でコマンドA応答データを作成する際において、前回の通信期間中に上記S510の処理で記憶した異常情報があったならば、コマンドA応答データの先頭から8〜10ビット目の3ビット(図2にて「その他2」と記した3ビット)を、上記異常情報を表すデータにすることができる。   In the above embodiment, the communication unit 15 of the input IC 11 displays abnormality information (for example, abnormality information stored in S510 of FIG. 7) indicating a communication abnormality that occurred during the communication period in which the chip select signal CS is at a low level. In the next communication period in which the chip select signal CS once becomes a high level and then becomes a low level, the command A response data may be included and transmitted to the processing IC 13. For example, if the communication unit 15 creates the command A response data in S460 of FIG. 7 and there is abnormality information stored in the process of S510 during the previous communication period, the communication unit 15 starts from the top of the command A response data. 8 bits to 10 bits (3 bits indicated as “other 2” in FIG. 2) can be used as data representing the abnormality information.

そして、このようにすれば、通信期間中に発生した異常を表す異常情報を、入力IC11から処理IC13へ、A/D変換値と一緒に送信しなくても済むため、入力IC11から処理IC13へのA/D変換値の転送を効率良く行うことができる。また、異常が発生したことを、その異常が起こった通信期間中に送信するよりも、次回の正常な通信期間において送信する方が信頼性が高いという点でも有利である。   By doing so, it is not necessary to transmit abnormality information indicating an abnormality that has occurred during the communication period from the input IC 11 to the processing IC 13 together with the A / D conversion value, and therefore, from the input IC 11 to the processing IC 13. The A / D conversion value can be transferred efficiently. In addition, it is advantageous in that it is more reliable to transmit the occurrence of an abnormality during the next normal communication period than to transmit during the communication period in which the abnormality has occurred.

尚、入力IC11からコマンドA応答データ中に含ませて送信する異常情報としては、前述したコマンド数異常の発生を表す情報であっても良い。
また、上記実施形態において、入力IC11の通信部15及び制御部25は、処理IC13から受信した4個のコマンドAの内容の多数決をとり、その多数決の結果に応じて当該入力IC11の内部機能(マルチプレクサ19の選択チャンネルやアンプ21のゲイン)を設定するように構成しても良い。
Note that the abnormality information transmitted from the input IC 11 in the command A response data may be information indicating the occurrence of the above-described abnormality in the number of commands.
In the above embodiment, the communication unit 15 and the control unit 25 of the input IC 11 take the majority of the contents of the four commands A received from the processing IC 13, and the internal function of the input IC 11 according to the result of the majority ( It may be configured to set the selected channel of the multiplexer 19 and the gain of the amplifier 21.

そして、このように構成すれば、処理IC13から入力IC11へのコマンドAのうち、特に最後(4個目)のコマンドAにノイズが乗ったとしても、入力IC11の内部機能を正しく設定することができるようになる。   With this configuration, the internal function of the input IC 11 can be set correctly even if noise is added to the last (fourth) command A among the commands A from the processing IC 13 to the input IC 11. become able to.

一方、上記実施形態において、入力IC11から処理IC13へのコマンドB応答データにおけるビットのうち、A/D変換値以外の2ビットは、コマンドデータではなく、通信エラーチェック用の冗長ビット(パリティなど)としても良い。また、A/D変換器17によるA/D変換値が14ビットではなく16ビットであるならば、コマンドB応答データの全ビットをA/D変換値にすれば良い。   On the other hand, in the above embodiment, of the bits in the command B response data from the input IC 11 to the processing IC 13, 2 bits other than the A / D conversion value are not command data but redundant bits (such as parity) for communication error check. It is also good. If the A / D conversion value by the A / D converter 17 is 16 bits instead of 14 bits, all the bits of the command B response data may be converted to A / D conversion values.

また、上記実施形態において、ノックセンサ27,29から入力IC11のマルチプレクサ19に入力されるA/D変換対象のアナログ信号(ノック信号)は、例えば2.5Vを中心に±2.5Vの範囲で変化する0〜5Vの信号であるが、入力IC11から処理IC13へ送信するA/D変換値としては、下記(A)又は(B)のような形態が考えられる。尚、何れの場合も、A/D変換値のビット数は14ビットであるものとする。   In the above embodiment, the analog signal (knock signal) to be A / D converted that is input from the knock sensors 27 and 29 to the multiplexer 19 of the input IC 11 is, for example, in the range of ± 2.5 V centered on 2.5 V. The A / D conversion value transmitted from the input IC 11 to the processing IC 13 is a signal of 0 to 5 V that changes, and the following forms (A) or (B) are conceivable. In any case, it is assumed that the number of bits of the A / D conversion value is 14 bits.

(A):まず、ノック信号の実際の中心値をA/D変換器17により事前に測定する。そして、入力IC11側では、処理IC13との通信期間中にノック信号をA/D変換した各A/D変換値から、上記中心値の測定値をオフセット値として減じた値を、処理IC13へ送信するA/D変換値とする。つまり、この場合には、入力IC11側でオフセット補正が行われ、処理IC13へは、「中心値(2.5V)=0カウント、最大値(5V)=+8192カウント、最小値(0V)=−8192カウント」というA/D変換値が送信されることとなる。   (A): First, the actual center value of the knock signal is measured in advance by the A / D converter 17. On the input IC 11 side, a value obtained by subtracting the measured value of the center value as an offset value from each A / D conversion value obtained by A / D converting the knock signal during the communication period with the processing IC 13 is transmitted to the processing IC 13. A / D conversion value to be used. In other words, in this case, offset correction is performed on the input IC 11 side, and the processing IC 13 is notified that “center value (2.5 V) = 0 count, maximum value (5 V) = + 8192 count, minimum value (0 V) = −. An A / D conversion value of “8192 counts” will be transmitted.

(B):入力IC11側でオフセット補正せずに、入力IC11から処理IC13へは、ノック信号をA/D変換した各A/D変換値を、そのまま送信する。つまり、「0V=0カウント、5V=16383」というA/D変換値を、処理IC13へ送信する。   (B): Without performing offset correction on the input IC 11 side, each A / D conversion value obtained by A / D converting the knock signal is transmitted as it is from the input IC 11 to the processing IC 13. That is, an A / D conversion value “0V = 0 count, 5V = 16383” is transmitted to the processing IC 13.

そして、この場合、処理IC13側にて、入力IC11より受信した各A/D変換値からノック信号の中心値に該当するオフセット値を減算して、上記(1)の場合と同様に、「中心値(2.5V)=0カウント、最大値(5V)=+8192カウント、最小値(0V)=−8192カウント」というA/D変換値を得るようにすれば良い。   In this case, on the processing IC 13 side, the offset value corresponding to the center value of the knock signal is subtracted from each A / D conversion value received from the input IC 11, and “center” is the same as in the case of (1) above. A / D conversion values of “value (2.5V) = 0 count, maximum value (5V) = + 8192 count, minimum value (0V) = − 8192 count” may be obtained.

尚、処理IC13側で用いるオフセット値としては、固定値(=8192)でも良いが、ノック信号の実際の中心値をA/D変換器17により測定した測定値を、オフセット値として入力IC11から処理IC13へ事前に送信しておくようにしても良い。   The offset value used on the processing IC 13 side may be a fixed value (= 8192), but the measured value obtained by measuring the actual center value of the knock signal by the A / D converter 17 is processed from the input IC 11 as the offset value. You may make it transmit to IC13 in advance.

また、オフセット値を実測して求めた場合、ノック信号の中心値が2.5Vでないと、オフセット補正後のA/D変換値(オフセット値を減じた後のA/D変換値)がオーバーフローする可能性があるため、処理IC13側では、更に、オフセット補正後のA/D変換値に対して、その値が最小値よりも小さければ最小値にし、その値が最大値よりも大きければ最大値にする、といったガード処理を実施すれば良い。このようにすれば、デジタルフィルタ処理対象のA/D変換値がオーバーフローせずに正しく処理することができる。   Further, when the offset value is obtained by actual measurement, if the center value of the knock signal is not 2.5 V, the A / D conversion value after the offset correction (A / D conversion value after subtracting the offset value) overflows. Therefore, on the processing IC 13 side, the A / D conversion value after offset correction is further set to the minimum value if the value is smaller than the minimum value, and the maximum value if the value is larger than the maximum value. What is necessary is just to implement guard processing, such as. In this way, the A / D conversion value subject to digital filter processing can be correctly processed without overflowing.

一方また、処理IC13におけるデジタルフィルタ35としては、FIR型でも良いが、本実施形態ではIIR型を用いている。低周波の信号をエンジンの高回転時までデジタルフィルタ処理する場合、FIR型のデジタルフィルタであると、そのフィルタ及びフィルタ処理結果が安定する前にノック判定区間が終了してしまうからである。   On the other hand, the digital filter 35 in the processing IC 13 may be an FIR type, but an IIR type is used in this embodiment. This is because when a low-frequency signal is digitally filtered until the engine rotates at a high speed, the knock determination section ends before the filter and the filter processing result are stabilized if the FIR type digital filter is used.

以上、本発明の一実施形態について説明したが、本発明はこうした実施形態に何等限定されるものではなく、本発明の要旨を逸脱しない範囲において、種々なる態様で実施し得ることは勿論である。   As mentioned above, although one Embodiment of this invention was described, this invention is not limited to such Embodiment at all, Of course, in the range which does not deviate from the summary of this invention, it can implement in a various aspect. .

例えば、上記実施形態において、入力IC11は、A/D変換値を処理IC13へ素早く返すために、バックグランドで10μs毎に絶えずA/D変換を実行し、その各A/D変換値を、次のコマンドBの受信タイミングで送信するようにしていたが、例えば、コマンドBを受信するとA/D変換器17を起動させて、そのA/D変換値を送信する、という構成でも良い。そして、この場合にも、入力IC11は、一度コマンドBを受信したならば、その後は、何のコマンドを受信しても、A/D変換器17を起動させて、そのA/D変換値を送信する、という動作を行うように構成すれば良い。   For example, in the above embodiment, the input IC 11 continuously executes A / D conversion every 10 μs in the background in order to quickly return the A / D conversion value to the processing IC 13, and each A / D conversion value is However, for example, the configuration may be such that when the command B is received, the A / D converter 17 is activated and the A / D conversion value is transmitted. In this case as well, once the input IC 11 receives the command B, the A / D converter 17 is activated and the A / D conversion value is obtained no matter what command is received thereafter. What is necessary is just to comprise so that operation | movement of transmitting may be performed.

また、上記実施形態において、ノックセンサ27,29は、エンジンの振動に応じたアナログ信号を出力する振動式センサであったが、A/D変換対象のアナログ信号としては、気筒内の圧力を検出する筒内圧センサ(CPS)からの信号や、イオン電流を表す信号でも良い。また更に、A/D変換対象のアナログ信号としては、エンジンのノック判定を行うための信号に限らず、他のアナログ信号であっても良い。   In the above embodiment, the knock sensors 27 and 29 are vibration sensors that output an analog signal corresponding to the vibration of the engine. However, as an analog signal to be A / D converted, the pressure in the cylinder is detected. It may be a signal from the cylinder pressure sensor (CPS) or a signal representing an ionic current. Furthermore, the analog signal to be A / D converted is not limited to a signal for performing engine knock determination, and may be another analog signal.

実施形態の信号処理装置の構成を表すブロック図である。It is a block diagram showing the structure of the signal processing apparatus of embodiment. 通信データのフォーマットを表す図である。It is a figure showing the format of communication data. 入力ICと処理ICとで実施される通信の概要を表す第1のタイムチャートである。It is a 1st time chart showing the outline | summary of the communication implemented by input IC and processing IC. 入力ICと処理ICとで実施される通信の概要を表す第2のタイムチャートである。It is a 2nd time chart showing the outline | summary of the communication implemented by input IC and processing IC. 処理ICのCPUで実行される30°CA割込処理を表すフローチャートである。It is a flowchart showing the 30 degree CA interruption process performed with CPU of processing IC. 処理ICの通信部で実行される処理を表すフローチャートである。It is a flowchart showing the process performed by the communication part of process IC. 入力ICの通信部で実行される処理を表すフローチャートである。It is a flowchart showing the process performed by the communication part of input IC. 本発明が適用されない場合の問題を説明する説明図である。It is explanatory drawing explaining the problem when this invention is not applied.

符号の説明Explanation of symbols

1〜5…信号線、11…入力IC(第1装置)、13…処理IC(第2装置)、15,31…通信部、17…A/D変換器、19…マルチプレクサ、21…アンプ、23…タイマ、25…制御部、27,29…ノックセンサ、33…回転処理部、35…デジタルフィルタ、37…メモリ、41〜45…レジスタ、46…送信データレジスタ、47…受信データレジスタ   DESCRIPTION OF SYMBOLS 1-5 ... Signal line, 11 ... Input IC (1st apparatus), 13 ... Processing IC (2nd apparatus), 15, 31 ... Communication part, 17 ... A / D converter, 19 ... Multiplexer, 21 ... Amplifier, DESCRIPTION OF SYMBOLS 23 ... Timer, 25 ... Control part, 27, 29 ... Knock sensor, 33 ... Rotation processing part, 35 ... Digital filter, 37 ... Memory, 41-45 ... Register, 46 ... Transmission data register, 47 ... Reception data register

Claims (9)

アナログ信号をA/D変換するA/D変換器を有すると共に、外部からの通信許可信号がアクティブレベルである場合に他の装置と通信ラインを介して通信する第1装置と、
前記第1装置と前記通信ラインを介して接続され、前記通信許可信号をアクティブレベルにして前記第1装置と一定時間毎に通信することにより、前記A/D変換器による前記アナログ信号の一定時間毎のA/D変換値を順次取得して、その取得した時系列のA/D変換値に対しデジタルフィルタ処理を行う第2装置とからなり、
前記第2装置が、前記通信許可信号をアクティブレベルにした状態で、前記第1装置へ複数種類のコマンドのうちのA/D変換要求コマンドを一定時間毎に送信し、前記第1装置が、前記A/D変換要求コマンドを受信する毎に、前記A/D変換器による前記アナログ信号のA/D変換値を前記第2装置へ返送することにより、前記第1装置から前記第2装置へ、前記A/D変換器による前記アナログ信号の一定時間毎のA/D変換値が転送される信号処理装置であって、
前記第1装置は、前記通信許可信号がアクティブレベルになってから、前記A/D変換要求コマンドを受信したと一度判断すると、その後、前記通信許可信号が非アクティブレベルとなるまでは、前記第2装置からのコマンドが前記A/D変換要求コマンドであるか否かに拘わらず、前記第2装置からのコマンドを受信する毎に前記第2装置へ前記A/D変換器による前記アナログ信号のA/D変換値を送信すること、
を特徴とする信号処理装置。
A first device having an A / D converter for A / D converting an analog signal and communicating with another device via a communication line when a communication permission signal from the outside is at an active level;
The analog signal by the A / D converter is connected for a certain time by being connected to the first device via the communication line and communicating with the first device at a certain time by setting the communication permission signal to an active level. A second device that sequentially acquires each A / D conversion value and performs digital filter processing on the acquired time-series A / D conversion value;
The second device transmits an A / D conversion request command of a plurality of types of commands to the first device at regular intervals in a state where the communication permission signal is set to an active level. Each time the A / D conversion request command is received, the A / D conversion value of the analog signal by the A / D converter is returned to the second device, thereby the first device to the second device. A signal processing device to which an A / D conversion value of the analog signal by the A / D converter is transferred every predetermined time,
The first device once determines that the A / D conversion request command has been received after the communication permission signal becomes active level, and thereafter, until the communication permission signal becomes inactive level, Regardless of whether the command from the two devices is the A / D conversion request command or not, every time the command from the second device is received, the analog signal by the A / D converter is sent to the second device. Sending an A / D conversion value;
A signal processing device.
請求項1に記載の信号処理装置において、
前記第2装置は、前記通信許可信号をアクティブレベルにした後、前記第1装置へ、前記A/D変換要求コマンド以外の機能設定用コマンドを所定個数だけ送信してから、前記A/D変換要求コマンドの送信を開始し、
前記第1装置は、前記通信許可信号がアクティブレベルになってから前記機能設定用コマンドを受信すると、その機能設定用コマンドに応じて内部の機能を設定すること、
を特徴とする信号処理装置。
The signal processing device according to claim 1,
After the communication permission signal is set to an active level, the second device transmits a predetermined number of function setting commands other than the A / D conversion request command to the first device, and then performs the A / D conversion. Start sending request command,
When the first device receives the function setting command after the communication permission signal becomes an active level, the first device sets an internal function according to the function setting command;
A signal processing device.
請求項2に記載の信号処理装置において、
前記通信許可信号がアクティブレベルになってから前記A/D変換器の出力を安定させるまでに必要な時間をT1とし、前記第1装置と前記第2装置との通信間隔である前記一定時間をT2とすると、
前記第2装置は、前記通信許可信号をアクティブレベルにした後、前記機能設定用コマンドを「T1/T2」以上である整数値の回数だけ送信した後、前記A/D変換要求コマンドの送信を開始すること、
を特徴とする信号処理装置。
The signal processing device according to claim 2,
The time required until the output of the A / D converter is stabilized after the communication permission signal becomes an active level is T1, and the predetermined time which is a communication interval between the first device and the second device is set as T1. T2
The second device sets the communication permission signal to an active level, transmits the function setting command for an integer number of times equal to or greater than “T1 / T2”, and then transmits the A / D conversion request command. To get started,
A signal processing device.
請求項2又は請求項3に記載の信号処理装置において、
前記第2装置は、前記通信許可信号をアクティブレベルにしてから前記A/D変換要求コマンドを送信するまでの前記機能設定用コマンドの送信個数を、その機能設定用コマンド中に含ませて前記第1装置へ送信するようになっており、
前記第1装置は、前記機能設定用コマンド中に含まれている前記送信個数と、前記通信許可信号がアクティブレベルになってから前記第2装置から実際に送信されて来た前記機能設定用コマンドの数とを比較して、不一致ならば異常と判断すること、
を特徴とする信号処理装置。
In the signal processing device according to claim 2 or 3,
The second device includes the number of function setting commands transmitted from when the communication permission signal is set to an active level to when the A / D conversion request command is transmitted, in the function setting command. It is designed to send to 1 device,
The first device includes the function setting command that is actually transmitted from the second device after the number of transmissions included in the function setting command and the communication permission signal becomes an active level. Comparing the number of
A signal processing device.
請求項2ないし請求項4の何れか1項に記載の信号処理装置において、
前記第1装置は、前記通信許可信号がアクティブレベルである期間中に発生した通信異常を表す異常情報を、前記通信許可信号が一旦非アクティブレベルとなって次にアクティブレベルとなった際に、前記機能設定用コマンドに対する応答データ中に含ませて前記第2装置へ送信すること、
を特徴とする信号処理装置。
The signal processing device according to any one of claims 2 to 4,
When the communication permission signal once becomes an inactive level and then becomes an active level, the first device, when the communication permission signal once becomes an inactive level, Including it in response data to the function setting command and transmitting it to the second device;
A signal processing device.
請求項2ないし請求項5の何れか1項に記載の信号処理装置において、
前記第1装置は、前記アナログ信号として、エンジンのノッキングを検出するための複数のノックセンサからのアナログ信号を入力し、その複数のアナログ信号のうち、前記第2装置からの機能設定用コマンドによって指示される1つのアナログ信号を選択して前記A/D変換器に入力させるようになっており、
前記第2装置は、前記エンジンの各気筒毎に設定されるノック判定区間の何れかが終了すると、前記通信許可信号をアクティブレベルから非アクティブレベルにし、その後、次の気筒のノック判定区間が到来する前に、前記通信許可信号をアクティブレベルにして、前記機能設定用コマンドを送信することにより、前記複数のアナログ信号のうち、前記次の気筒のノッキングを判定するためのアナログ信号を前記第1装置に選択させると共に、前記A/D変換要求コマンドの送信も開始するようになっていること、
を特徴とする信号処理装置。
The signal processing device according to any one of claims 2 to 5,
The first device receives analog signals from a plurality of knock sensors for detecting engine knocking as the analog signals, and among the plurality of analog signals, a function setting command from the second device is used. One analog signal to be instructed is selected and input to the A / D converter,
When one of the knock determination intervals set for each cylinder of the engine ends, the second device changes the communication permission signal from the active level to the inactive level, and then the knock determination interval for the next cylinder arrives. Before the operation, the communication permission signal is set to an active level, and the function setting command is transmitted, so that, among the plurality of analog signals, an analog signal for determining knocking of the next cylinder is determined as the first signal. The device is selected and the transmission of the A / D conversion request command is started.
A signal processing device.
請求項2ないし請求項6の何れか1項に記載の信号処理装置において、
前記第2装置は、前記機能設定用コマンドに対する前記第1装置からの受信データが格納される第1格納部と、前記A/D変換要求コマンドに対する前記第1装置からの受信データが格納される第2格納部とを別々に備えること、
を特徴とする信号処理装置。
The signal processing device according to any one of claims 2 to 6,
The second device stores a first storage unit that stores data received from the first device for the function setting command, and stores data received from the first device for the A / D conversion request command. Providing a second storage unit separately;
A signal processing device.
請求項2ないし請求項7の何れか1項に記載の信号処理装置において、
前記第2装置は、前記通信許可信号をアクティブレベルにした後、前記機能設定用コマンドとして、同じ内容の機能設定用コマンドを複数個送信し、
前記第1装置は、前記第2装置から受信した複数個の前記機能設定用コマンドの内容の多数決をとり、その多数決の結果に応じて内部の機能を設定すること、
を特徴とする信号処理装置。
The signal processing device according to any one of claims 2 to 7,
The second device transmits a plurality of function setting commands having the same contents as the function setting command after setting the communication permission signal to an active level,
The first device takes a majority vote of the contents of the plurality of function setting commands received from the second device, and sets an internal function according to the result of the majority vote;
A signal processing device.
請求項1ないし請求項8の何れか1項に記載の信号処理装置において、
前記一定時間毎のタイミング信号が前記第1装置側で生成され、そのタイミング信号に従って、前記A/D変換器による前記アナログ信号のA/D変換及び前記第1装置と前記第2装置との通信が実行されること、
を特徴とする信号処理装置。
The signal processing device according to any one of claims 1 to 8,
A timing signal for each predetermined time is generated on the first device side, and according to the timing signal, A / D conversion of the analog signal by the A / D converter and communication between the first device and the second device. Is executed,
A signal processing device.
JP2004301667A 2004-10-15 2004-10-15 Signal processing device Expired - Fee Related JP4259449B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004301667A JP4259449B2 (en) 2004-10-15 2004-10-15 Signal processing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004301667A JP4259449B2 (en) 2004-10-15 2004-10-15 Signal processing device

Publications (2)

Publication Number Publication Date
JP2006112346A true JP2006112346A (en) 2006-04-27
JP4259449B2 JP4259449B2 (en) 2009-04-30

Family

ID=36381071

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004301667A Expired - Fee Related JP4259449B2 (en) 2004-10-15 2004-10-15 Signal processing device

Country Status (1)

Country Link
JP (1) JP4259449B2 (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7310575B2 (en) 2005-12-26 2007-12-18 Denso Corporation Apparatus for processing sensor signal from knock sensor of internal combustion engine
US7578282B2 (en) 2006-01-27 2009-08-25 Denso Corporation Apparatus for processing sensor signal from knock sensor of internal combustion engine
JP2012181677A (en) * 2011-03-01 2012-09-20 Seiko Epson Corp Physical quantity measuring device
JP2013036354A (en) * 2011-08-04 2013-02-21 Denso Corp Fault determination device for fuel pressure detection command

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7310575B2 (en) 2005-12-26 2007-12-18 Denso Corporation Apparatus for processing sensor signal from knock sensor of internal combustion engine
US7578282B2 (en) 2006-01-27 2009-08-25 Denso Corporation Apparatus for processing sensor signal from knock sensor of internal combustion engine
JP2012181677A (en) * 2011-03-01 2012-09-20 Seiko Epson Corp Physical quantity measuring device
JP2013036354A (en) * 2011-08-04 2013-02-21 Denso Corp Fault determination device for fuel pressure detection command

Also Published As

Publication number Publication date
JP4259449B2 (en) 2009-04-30

Similar Documents

Publication Publication Date Title
JP4375331B2 (en) Knock sensor signal processing device
JP4605035B2 (en) Knock sensor signal processing device
US8972638B2 (en) Serial data communication system and serial data communication method
JP2015228171A (en) Sensor system, sensor, and sensor signal output method
EP1434382A1 (en) Serial data transferring apparatus
JP4259449B2 (en) Signal processing device
JP2006285977A (en) Information processing system
JP2014524692A (en) Measurement value transmitter
JP5253949B2 (en) Communication device and communication program
US8131455B2 (en) Engine control apparatus including computing section and A/D converting section
JP4655656B2 (en) Electronic control unit
KR102253167B1 (en) Vehicle and method of synchronizing sensor data
JP2018155105A (en) Engine control device and electronic control device
JP2000253094A (en) Method and equipment for serial communication
JP5304210B2 (en) Control system
JP2007036850A (en) Character recognizing circuit
KR102143080B1 (en) Communication system for vehicle and operating method thereof
JP2520849B2 (en) Inter-communication device for automobile controller
JP3658151B2 (en) Printing device and printing method
US8639977B2 (en) Control device
JP2007102259A (en) Sensor system, sensor unit, and sensor management program
JPH08163653A (en) Serial communication switching method
JP4665744B2 (en) A / D converter and A / D conversion system
JP4134023B2 (en) Burst transfer system, transfer mediation device
JP4615553B2 (en) Serial data communication system and serial data communication method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20061108

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

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20090202

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

Free format text: PAYMENT UNTIL: 20120220

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Ref document number: 4259449

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20130220

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20140220

Year of fee payment: 5

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees