JP2013006465A - Electronic control device - Google Patents

Electronic control device Download PDF

Info

Publication number
JP2013006465A
JP2013006465A JP2011139229A JP2011139229A JP2013006465A JP 2013006465 A JP2013006465 A JP 2013006465A JP 2011139229 A JP2011139229 A JP 2011139229A JP 2011139229 A JP2011139229 A JP 2011139229A JP 2013006465 A JP2013006465 A JP 2013006465A
Authority
JP
Japan
Prior art keywords
timing
input signal
sampling
timing generation
generation unit
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2011139229A
Other languages
Japanese (ja)
Other versions
JP5582100B2 (en
Inventor
Masaya Taki
雅也 滝
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 JP2011139229A priority Critical patent/JP5582100B2/en
Priority to DE102012105267.0A priority patent/DE102012105267B4/en
Publication of JP2013006465A publication Critical patent/JP2013006465A/en
Application granted granted Critical
Publication of JP5582100B2 publication Critical patent/JP5582100B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G04HOROLOGY
    • G04GELECTRONIC TIME-PIECES
    • G04G3/00Producing timing pulses

Abstract

PROBLEM TO BE SOLVED: To avoid the effect of the superimposed noise caused by the pulse output on the sampling of input signals in the electronic control device that obtains the input signal while outputting the pulse signal.SOLUTION: A microcomputer of an electronic control unit (ECU) includes: a first timer that generates a pulse output (a); and a second timer that generates the sampling timing of an input signal (b). When the sampling timing of the input signal agrees to the edge timing of the pulse output (c), and the input signal comes to strongly receive the superimposed noise. Then, the sampling timing of the input signal is adjusted by the first timer and the second timer not to agree to the edge timing of the pulse output (d). As a result, the effect of the superimposed noise exerts on the sampling of the input signal can be avoided.

Description

本発明は、電子制御装置に関する。   The present invention relates to an electronic control device.

従来、マイクロコンピュータ(以下、適宜「マイコン」という)の動作クロックが異常となる故障を検出し、システムの信頼性向上を図る電子制御装置が知られている。例えば特許文献1には、マイコンから動作クロックに同期した信号を出力し、これを別クロックで動作するマイコンなどで監視する「クロック監視」の方法が開示されている。
ところが、一般に動作クロックなどの高周波デジタル信号は、その付近に実装された入力信号にパルス性のノイズを重畳させることが良く知られており、問題となっている。
2. Description of the Related Art Conventionally, there is known an electronic control device that detects a failure in which an operation clock of a microcomputer (hereinafter referred to as “microcomputer” as appropriate) is abnormal and improves the reliability of the system. For example, Patent Document 1 discloses a “clock monitoring” method in which a signal synchronized with an operation clock is output from a microcomputer, and this is monitored by a microcomputer operating with another clock.
However, it is well known that high-frequency digital signals such as operation clocks generally superimpose pulsed noise on an input signal mounted in the vicinity thereof.

そこで、このような重畳ノイズの影響を低減するために様々な手法が提案されている。例えば、サンプリングした入力信号をソフトウェアで演算により平滑化する。あるいは、高周波デジタル出力の信号線とその他の信号線とを分離して実装することでノイズの重畳レベルを低減する。また、特許文献2に開示されたノイズ検出装置は、入力信号に含まれるパルス性ノイズを検出するノイズ検波回路を設け、ノイズ検波回路によってノイズ検出された期間はパルス性ノイズを除去するものである。   Therefore, various methods have been proposed to reduce the influence of such superimposed noise. For example, the sampled input signal is smoothed by calculation using software. Alternatively, the high level digital output signal line and other signal lines are separately mounted to reduce the noise superposition level. Further, the noise detection device disclosed in Patent Document 2 includes a noise detection circuit that detects pulse noise included in an input signal, and removes the pulse noise during a period in which noise is detected by the noise detection circuit. .

特開2009−202612号公報JP 2009-202612 A 特開2008−277969号公報JP 2008-277969 A

しかし、上述の手法について、ソフトウェア演算による平滑化は、信号の応答性を低下させるとともに、マイコンの処理能力や演算に用いるROM/RAMの圧迫を引き起こす問題がある。また、信号線の分離実装は、レイアウトの自由度を奪うことから電子制御装置の小型化を阻害する要因となりうる。さらに、特許文献2のノイズ除去装置では、ノイズ検波回路を設けるためコストアップするという問題がある。   However, with the above-described method, smoothing by software calculation has a problem of reducing the responsiveness of the signal and causing compression of the processing capacity of the microcomputer and the ROM / RAM used for the calculation. Further, the separate mounting of the signal lines can be a factor that hinders downsizing of the electronic control device because it deprives the freedom of layout. Furthermore, the noise removing device of Patent Document 2 has a problem of increasing the cost because a noise detection circuit is provided.

本発明は、このような点に鑑みて創作されたものであり、その目的は、パルス信号を出力しつつ入力信号を取得する電子制御装置において、パルス出力によって生ずる重畳ノイズが入力信号のサンプリングに及ぼす影響を回避することにある。   The present invention was created in view of the above points, and its purpose is to superimpose noise generated by pulse output in sampling of the input signal in an electronic control device that acquires the input signal while outputting the pulse signal. It is to avoid the effect.

請求項1に記載の電子制御装置は、マイクロコンピュータと、マイクロコンピュータから出力されるパルス信号を伝送する出力信号線と、マイクロコンピュータへ入力信号を伝送する入力信号線とを備える。
マイクロコンピュータは、パルス信号の周期的な「立ち上がり及び立ち下がりタイミング」であるエッジタイミングを生成する第1タイミング生成手段、及び、入力信号の値を周期的に取得するためのサンプリングタイミングを生成する第2タイミング生成手段を有する。第1タイミング生成手段および第2タイミング生成手段は、パルス信号のエッジタイミングと入力信号のサンプリングタイミングとに時間差をもたらすタイミング不一致処理を実行する。
According to another aspect of the present invention, an electronic control device includes a microcomputer, an output signal line that transmits a pulse signal output from the microcomputer, and an input signal line that transmits an input signal to the microcomputer.
The microcomputer generates first timing generation means for generating edge timing which is periodic “rise and fall timing” of the pulse signal, and first sampling timing for periodically acquiring the value of the input signal. 2 timing generating means. The first timing generation unit and the second timing generation unit execute timing mismatch processing that causes a time difference between the edge timing of the pulse signal and the sampling timing of the input signal.

このタイミング不一致処理によって、パルス信号のエッジタイミングと入力信号のサンプリングタイミングとを意図的にずらすため、入力信号のサンプリングにおいて、パルス出力によって生ずる重畳ノイズの影響を回避することができる。
この処理は、マイコンの処理能力やROM/RAMをほとんど圧迫することなく実現可能である。また、新たな回路の追加や信号の平滑化が不要であるため、素子の増加によるコストアップや信号応答性の低下を招くこともない。さらに、出力信号線と入力信号線とを分離実装しないので、電子制御装置の小型化が阻害されることもない。
By this timing mismatch processing, the edge timing of the pulse signal and the sampling timing of the input signal are intentionally shifted, so that the influence of superimposed noise caused by the pulse output can be avoided in the sampling of the input signal.
This process can be realized with almost no pressure on the processing capacity of the microcomputer and the ROM / RAM. In addition, since it is not necessary to add a new circuit or smooth the signal, there is no increase in cost due to an increase in elements and a decrease in signal response. Further, since the output signal line and the input signal line are not separately mounted, the electronic control device is not hindered in size reduction.

請求項2に記載の電子制御装置は、第1タイミング生成手段によってパルス信号の出力が開始され当該パルス信号による処理が実行された後、第2タイミング生成手段が入力信号のサンプリングを「開始する前」に、タイミング不一致処理を実行する。
このようにパルス信号による任意の処理が一旦実行されると、その後の処理において、パルス信号のエッジタイミングは既知情報から「静的」に定まらない。そこで、請求項2に記載の発明では、「既に出力されているエッジタイミングと、これから生成しようとするサンプリングタイミングとの時間的関係が不明な状態」から、「動的なタイミング不一致処理」を実行する。
また、ここで「開始する前」とは例えば「μs」オーダーの時間をいい、現実的には、限りなく「開始と同時に」に近い意味である。
In the electronic control device according to claim 2, after the output of the pulse signal is started by the first timing generation unit and the processing by the pulse signal is executed, the second timing generation unit “before starting the sampling of the input signal” The timing mismatch process is executed.
As described above, once arbitrary processing using the pulse signal is executed, the edge timing of the pulse signal is not determined to be “static” from the known information in the subsequent processing. Therefore, in the invention according to claim 2, “dynamic timing mismatch processing” is executed from “a state in which the temporal relationship between the already output edge timing and the sampling timing to be generated is unknown”. To do.
Here, “before starting” means, for example, a time in the order of “μs”, and practically means as close as possible to “at the same time as starting”.

請求項3〜5に記載の発明は、請求項2に記載の「動的なタイミング不一致処理」を具体的に示す。
請求項3に記載の発明では、第1タイミング生成手段が出力するタイマ値を入力信号のサンプリングタイミングに対応して所定の値に書き換える。
ここで、「所定の値」は、例えばパルス周期の(1/4)に相当する時間差値である。これにより、入力信号のサンプリング開始と同時に、パルス信号は、エッジタイミングがサンプリングタイミングに対しパルス周期の1/4周期分進んだ信号として書き換えられる。すなわち、サンプリングタイミングは、パルス信号の「ある立ち上がりタイミングと次の立ち下がりタイミングとの間のタイミング」、あるいは「ある立ち下がりタイミングと次の立ち上がりタイミングとの間のタイミング」に生成されることとなる。この処理を「書き換え型処理」という。
The inventions according to claims 3 to 5 specifically show “dynamic timing mismatch processing” according to claim 2.
According to the third aspect of the present invention, the timer value output from the first timing generation means is rewritten to a predetermined value corresponding to the sampling timing of the input signal.
Here, the “predetermined value” is a time difference value corresponding to, for example, (1/4) of the pulse period. Thereby, simultaneously with the start of sampling of the input signal, the pulse signal is rewritten as a signal whose edge timing is advanced by 1/4 of the pulse period with respect to the sampling timing. That is, the sampling timing is generated at “a timing between a certain rising timing and the next falling timing” or “a timing between a certain falling timing and the next rising timing” of the pulse signal. . This process is called “rewritable process”.

「書き換え型処理」では、第2タイミング生成手段がそれ自身の生成するタイミングを変更するのでなく、相手方である第1タイミング生成手段のタイミングのみを変更する。また、第1タイミング生成手段のタイミングを変更するとき、第1タイミング生成手段の現在値に関係なく、常に、決まった「所定の値」に画一的に書き換えるので、演算負荷を軽減することができる。さらに、後述する「待機型処理」のように入力信号のサンプリング開始が遅れることがないため、迅速な処理が可能である。   In “rewritable processing”, the second timing generation means does not change the timing generated by itself, but changes only the timing of the first timing generation means that is the counterpart. In addition, when changing the timing of the first timing generation means, it is always rewritten uniformly to a predetermined “predetermined value” regardless of the current value of the first timing generation means, so that the calculation load can be reduced. it can. Furthermore, unlike the “stand-by process” described later, the start of sampling of the input signal is not delayed, so that a quick process is possible.

請求項4に記載の発明では、第2タイミング生成手段は、第1タイミング生成手段が出力するタイマ値が所定の値になるのを待って起動する。
ここで、「所定の値」は、例えば請求項3に記載の「所定の値」と同じ値、すなわち、パルス周期の(1/4)に相当する値を採用することができる。これにより、パルス信号のエッジタイミングが所定の値だけずれるのを待って、第2タイミング生成手段は、サンプリングタイミングの生成を開始する。この処理を「待機型処理」という。
「待機型処理」では、既に出力しているパルス信号を変更することなく、安定したパルス出力を継続させることができる。また、マイコンの演算が簡素となる。
According to the fourth aspect of the present invention, the second timing generation unit is activated after the timer value output from the first timing generation unit reaches a predetermined value.
Here, as the “predetermined value”, for example, the same value as the “predetermined value” described in claim 3, that is, a value corresponding to (1/4) of the pulse period can be adopted. As a result, after waiting for the edge timing of the pulse signal to deviate by a predetermined value, the second timing generation means starts generating the sampling timing. This processing is called “standby processing”.
In the “standby processing”, stable pulse output can be continued without changing the pulse signal already output. In addition, the calculation of the microcomputer is simplified.

請求項5に記載の発明では、第2タイミング生成手段は、第1タイミング生成手段が出力するタイマ値の現在値に基づいて、特定回のサンプリング周期を所定の周期に変更する。ここで、「特定回」は、例えば起動1回目の周期である。第2タイミング生成手段は、エッジタイミングの現在値を取得し、それに基づいて、サンプリングタイミングの周期を起動1回目のみ特別に変更することで、2回目以降のサンプリングタイミングをエッジタイミングに対してずらす。この処理を「周期変更型処理」という。
「周期変更型処理」では、第2タイミング生成手段は、第1タイミング生成手段の生成するエッジタイミングの現在値に基づき、「特定回」のサンプリングタイミングの周期を演算する。既に出力しているパルス信号を変更することがないため、安定したパルス出力を継続させることができる。
According to the fifth aspect of the present invention, the second timing generation unit changes the sampling cycle of a specific number of times to a predetermined cycle based on the current value of the timer value output from the first timing generation unit. Here, “specific times” is, for example, a cycle of the first activation. The second timing generation means acquires the current value of the edge timing, and based on this, changes the sampling timing period only for the first time of activation, thereby shifting the second and subsequent sampling timings with respect to the edge timing. This process is referred to as “cycle change type process”.
In the “cycle changing type process”, the second timing generation unit calculates the cycle of the sampling timing “specific times” based on the current value of the edge timing generated by the first timing generation unit. Since the pulse signal that has already been output is not changed, stable pulse output can be continued.

請求項6に記載の電子制御装置は、第1タイミング生成手段によってパルス信号の出力が開始され当該パルス信号による処理が実行された後、さらに第2タイミング生成手段が入力信号のサンプリングを「開始した後」に、タイミング不一致処理を実行する。
すなわち、動的な処理をするという点で請求項2に記載の発明と同じである。しかし、処理実行時にサンプリングタイミングが既に出力されており、請求項2に記載の発明に対し第1タイミング生成手段と第2タイミング生成手段との役割を逆転させるものである。
よって、請求項6に記載の発明は、「既に出力されているサンプリングタイミングと、これから改めて生成しようとするエッジタイミングとの時間的関係が不明な状態」から、「動的なタイミング不一致処理」を実行する。ここでも、「開始した後」とは例えば「μs」オーダーの時間をいい、現実的には、限りなく「開始と同時に」に近い意味である。
In the electronic control device according to claim 6, after the output of the pulse signal is started by the first timing generation unit and the processing by the pulse signal is executed, the second timing generation unit further “starts sampling of the input signal After, timing mismatch processing is executed.
That is, the present invention is the same as that of the second aspect in that dynamic processing is performed. However, the sampling timing has already been output when the processing is executed, and the roles of the first timing generation means and the second timing generation means are reversed with respect to the invention according to claim 2.
Therefore, the invention according to claim 6 performs “dynamic timing mismatch processing” from “a state in which the temporal relationship between the sampling timing already output and the edge timing to be generated again is unknown”. Execute. Here, “after starting” means, for example, a time in the order of “μs”, and practically means “as soon as starting”.

請求項7〜9に記載の発明は、それぞれ請求項3〜5に記載の発明に対応し、請求項6に記載の「動的なタイミング不一致処理」を具体的に示す。
請求項7に記載の発明では、第2タイミング生成手段が出力するタイマ値をパルス信号のエッジタイミングに対応して所定の値に書き換える。
請求項8に記載の発明では、第1タイミング生成手段は、第2タイミング生成手段が出力するタイマ値が所定の値になるのを待って出力する。
請求項9に記載の発明では、第1タイミング生成手段は、第2タイミング生成手段が出力するタイマ値の現在値に基づいて、特定回のパルス周期を所定の周期に変更する。
これらの発明の技術的特徴は、請求項3〜5に記載の発明と同様である。
The inventions according to claims 7 to 9 respectively correspond to the inventions according to claims 3 to 5, and specifically show “dynamic timing mismatch processing” according to claim 6.
In the seventh aspect of the invention, the timer value output from the second timing generation means is rewritten to a predetermined value corresponding to the edge timing of the pulse signal.
In the eighth aspect of the invention, the first timing generation means waits until the timer value output from the second timing generation means reaches a predetermined value and outputs it.
In the ninth aspect of the invention, the first timing generation unit changes the pulse cycle of a specific number of times to a predetermined cycle based on the current value of the timer value output from the second timing generation unit.
The technical features of these inventions are the same as those of the inventions described in claims 3-5.

以上、請求項2〜9に記載の電子制御装置が「動的なタイミング不一致処理」を実行するのに対し、請求項10に記載の電子制御装置は、「静的なタイミング不一致処理」を実行する。すなわち、第1タイミング生成手段および第2タイミング生成手段は、パルス信号のエッジタイミングと入力信号のサンプリングタイミングとを、予め所定の時間ずらして起動される。このように、本発明の電子制御装置は、動的な処理にも静的な処理にも適用することができる。   As described above, the electronic control device according to claims 2 to 9 executes “dynamic timing mismatch processing”, whereas the electronic control device according to claim 10 executes “static timing mismatch processing”. To do. That is, the first timing generation means and the second timing generation means are activated by shifting the edge timing of the pulse signal and the sampling timing of the input signal by a predetermined time in advance. As described above, the electronic control device of the present invention can be applied to both dynamic processing and static processing.

請求項11に記載の電子制御装置は、請求項1に記載の電子制御装置に対し、第2タイミング生成手段が生成するサンプリングタイミングが、入力信号の値を「周期的に」取得するためのものでなく、入力信号の値を「都度」取得するためのものである点が異なる。   According to an eleventh aspect of the present invention, in the electronic control device according to the first aspect, the sampling timing generated by the second timing generation means acquires the value of the input signal “periodically” with respect to the electronic control device according to the first aspect. Rather, it is for acquiring the value of the input signal “every time”.

この場合のタイミング不一致処理において、請求項12に記載の発明では、第2タイミング生成手段によってサンプリングタイミングが生成された後、第1タイミング生成手段が出力するタイマ値が所定の値になるのを待って入力信号の値を取得する。ここで、「所定の値」の考え方は、上述の請求項3または4に準ずる。
このように、入力信号のサンプリングが周期的に実行されるのでなく都度実行される場合であっても、「パルス出力によって生ずる重畳ノイズの影響を回避する」効果は同様に発揮される。
In the timing mismatch processing in this case, in the invention described in claim 12, after the sampling timing is generated by the second timing generation unit, the timer value output from the first timing generation unit waits for a predetermined value. To get the value of the input signal. Here, the concept of “predetermined value” is in accordance with the third or fourth aspect described above.
As described above, the effect of “avoiding the influence of the superimposed noise caused by the pulse output” is similarly exerted even when the sampling of the input signal is not performed periodically but is performed each time.

本発明の第1〜第3実施形態によるECU(電子制御装置)を適用した電動パワーステアリング装置の概略構成図。The schematic block diagram of the electric power steering device to which ECU (electronic control unit) by 1st-3rd embodiment of this invention is applied. 本発明の第1〜第3実施形態によるECUのシステム図。The system diagram of ECU by the 1st-3rd embodiment of the present invention. (a)パルス出力信号、(b)入力信号の波形図。(A) Pulse output signal, (b) Waveform diagram of input signal. 本発明の第1〜第3実施形態によるECUのサンプリングタイミングを説明するタイミングチャート。The timing chart explaining the sampling timing of ECU by the 1st-3rd embodiment of the present invention. 本発明の第1実施形態によるECUのタイミング不一致処理のフローチャート。The flowchart of the timing mismatch processing of ECU by 1st Embodiment of this invention. 本発明の第2実施形態によるECUのタイミング不一致処理のフローチャート。The flowchart of the timing mismatch processing of ECU by 2nd Embodiment of this invention. 本発明の第3実施形態によるECUのタイミング不一致処理のフローチャート。The flowchart of the timing mismatch processing of ECU by 3rd Embodiment of this invention. 本発明の第4実施形態によるECUのサンプリングタイミングを説明するタイミングチャート。The timing chart explaining the sampling timing of ECU by 4th Embodiment of this invention.

自動車等のハンドル操作をアシストするための電動パワーステアリング装置に本発明の電子制御装置(以下「ECU」という)を適用した実施形態を図面に基づいて説明する。
(第1実施形態)
図1は、電動パワーステアリング装置を備えたステアリングシステムの全体構成を示す。ステアリングシステム90に備えられる電動パワーステアリング装置1は、ハンドル91に接続されたステアリングシャフト92に操舵トルクを検出するためのトルクセンサ94を設置している。ステアリングシャフト92の先端にはピニオンギア96が設けられており、ピニオンギア96はラック軸97に噛み合っている。ラック軸97の両端には、タイロッド等を介して一対の車輪98が回転可能に連結されている。
An embodiment in which an electronic control device (hereinafter referred to as “ECU”) of the present invention is applied to an electric power steering device for assisting steering operation of an automobile or the like will be described with reference to the drawings.
(First embodiment)
FIG. 1 shows the overall configuration of a steering system provided with an electric power steering device. In the electric power steering apparatus 1 provided in the steering system 90, a torque sensor 94 for detecting a steering torque is installed on a steering shaft 92 connected to a handle 91. A pinion gear 96 is provided at the tip of the steering shaft 92, and the pinion gear 96 meshes with the rack shaft 97. A pair of wheels 98 are rotatably connected to both ends of the rack shaft 97 via tie rods or the like.

これにより、運転者がハンドル91を回転させると、ハンドル91に接続されたステアリングシャフト92が回転し、ステアリングシャフト92の回転運動は、ピニオンギア96によってラック軸97の直線運動に変換され、ラック軸97の直線運動変位に応じた角度について一対の車輪98が操舵される。   As a result, when the driver rotates the handle 91, the steering shaft 92 connected to the handle 91 rotates, and the rotational motion of the steering shaft 92 is converted into the linear motion of the rack shaft 97 by the pinion gear 96. The pair of wheels 98 are steered at an angle corresponding to 97 linear motion displacement.

電動パワーステアリング装置1は、操舵アシストトルクを発生するモータ80、モータ80の回転を減速してステアリングシャフト92に伝える減速ギア89、及び、モータ駆動装置2を備える。モータ80は3相ブラシレスモータであり、減速ギア89を正逆回転させる。モータ駆動装置2は、ECU10を備える。モータ駆動装置2は、また、モータ80の回転角を検出する回転角センサ85、上述のトルクセンサ94、車速を検出する車速センサ95を含む。
この構成により、電動パワーステアリング装置1は、ハンドル91の操舵を補助するための操舵アシストトルクを発生し、ステアリングシャフト92に伝達する。
The electric power steering apparatus 1 includes a motor 80 that generates a steering assist torque, a reduction gear 89 that reduces the rotation of the motor 80 and transmits the rotation to the steering shaft 92, and the motor driving apparatus 2. The motor 80 is a three-phase brushless motor, and rotates the reduction gear 89 forward and backward. The motor drive device 2 includes an ECU 10. The motor drive device 2 also includes a rotation angle sensor 85 that detects the rotation angle of the motor 80, the above-described torque sensor 94, and a vehicle speed sensor 95 that detects the vehicle speed.
With this configuration, the electric power steering apparatus 1 generates a steering assist torque for assisting the steering of the handle 91 and transmits the steering assist torque to the steering shaft 92.

図2にECUのシステム概略図を示す。ECU10は、マイコン11、クロック監視回路31、駆動回路32等を備えている。マイコン11は、上述の回転角センサ85、トルクセンサ94および車速センサ95等から入力した信号に基づいてプログラムを実行し、モータ80を駆動するための駆動回路32を制御する。また、駆動回路32からは、入力信号線22を経由してマイコン11へ入力信号が入力される。   FIG. 2 shows a schematic system diagram of the ECU. The ECU 10 includes a microcomputer 11, a clock monitoring circuit 31, a drive circuit 32, and the like. The microcomputer 11 executes a program based on the signals input from the rotation angle sensor 85, the torque sensor 94, the vehicle speed sensor 95, and the like, and controls the drive circuit 32 for driving the motor 80. An input signal is input from the drive circuit 32 to the microcomputer 11 via the input signal line 22.

また、マイコン11は、動作クロックに同期したパルス信号を、出力信号線21を経由してクロック監視回路31に出力する。クロック監視回路31は、マイコン11から出力されるパルス信号に基づいて、マイコン11の動作クロックが正常であるか否かを監視する。このパルス信号は、高周波デジタル信号である。   The microcomputer 11 outputs a pulse signal synchronized with the operation clock to the clock monitoring circuit 31 via the output signal line 21. The clock monitoring circuit 31 monitors whether the operation clock of the microcomputer 11 is normal based on the pulse signal output from the microcomputer 11. This pulse signal is a high-frequency digital signal.

マイコン11は、プログラムを実行するCPU(中央演算処理装置)12、CPU12によって実行されるプログラムを記憶するROM13、CPU12による演算結果等を記憶するためのRAM14、入力信号が入力される入力回路17の他、第1タイマ15および第2タイマ16を備えている。これらの構成要素は、バスライン19によって互いに通信されている。   The microcomputer 11 includes a CPU (central processing unit) 12 that executes a program, a ROM 13 that stores a program executed by the CPU 12, a RAM 14 that stores calculation results by the CPU 12, and an input circuit 17 that receives input signals. In addition, a first timer 15 and a second timer 16 are provided. These components are in communication with each other via a bus line 19.

「第1タイミング生成手段」としての第1タイマ15は、クロック監視回路31に出力するパルス信号のパルス周期、すなわち、信号のHI/LOが周期的に切り替わる「立ち上がり及び立ち下がりタイミング」に相当するエッジタイミングを生成する。
「第2タイミング生成手段」としての第2タイマ16は、入力回路17に入力される入力信号の値を周期的に取得するためのサンプリングタイミングを生成する。
The first timer 15 as “first timing generation means” corresponds to the “rising and falling timing” at which the pulse period of the pulse signal output to the clock monitoring circuit 31, that is, the HI / LO of the signal is periodically switched. Edge timing is generated.
The second timer 16 as “second timing generation means” generates a sampling timing for periodically acquiring the value of the input signal input to the input circuit 17.

ここで、入力信号線22と出力信号線21とは、マイコン11付近で互いに近接して実装されるため、高周波デジタル信号であるパルス信号から入力信号にパルス性ノイズが重畳することが避けられない。図3および図4(a)、(b)に示すように、重畳ノイズは、特にパルス信号のエッジタイミングに発生する。
なお、図3(b)および図4(b)では、入力信号は正弦波信号で例示されているが、これに限らず、入力信号は、どのような波形の信号であってもよい。
Here, since the input signal line 22 and the output signal line 21 are mounted close to each other in the vicinity of the microcomputer 11, it is inevitable that pulse noise is superimposed on the input signal from the pulse signal that is a high-frequency digital signal. . As shown in FIG. 3 and FIGS. 4A and 4B, the superimposed noise occurs particularly at the edge timing of the pulse signal.
In FIG. 3B and FIG. 4B, the input signal is exemplified as a sine wave signal. However, the input signal is not limited to this, and the input signal may be a signal having any waveform.

そして、図4(c)に示す比較例のように、入力信号のサンプリングタイミングがパルス信号のエッジタイミングに一致する場合、入力信号は、重畳ノイズの影響を強く受けることとなる。一方、図4(d)に示す本実施形態では、入力信号のサンプリングタイミングがパルス信号のエッジタイミングに一致しないため、重畳ノイズの影響を回避することができる。すなわち、重畳ノイズは、一般的なノイズ源からのノイズとは異なり、タイミングを調整することで影響を回避することが可能である。
また、本実施形態では、サンプリング周期Tsはパルス周期Tpの2倍に設定されている。この技術的意義については、第4実施形態のところで対比しつつ説明する。
If the sampling timing of the input signal coincides with the edge timing of the pulse signal as in the comparative example shown in FIG. 4C, the input signal is strongly affected by the superimposed noise. On the other hand, in this embodiment shown in FIG. 4D, the sampling timing of the input signal does not coincide with the edge timing of the pulse signal, so that the influence of the superimposed noise can be avoided. In other words, unlike the noise from a general noise source, the superimposed noise can be avoided by adjusting the timing.
In the present embodiment, the sampling period Ts is set to twice the pulse period Tp. This technical significance will be described in comparison with the fourth embodiment.

このように、ECU10は、第1タイマ15が生成するパルス信号のエッジタイミングと、第2タイマ16が生成する入力信号のサンプリングタイミングとを意図的にずらす処理を実行する。この処理を、「タイミング不一致処理」という。
次に、第1実施形態のタイミング不一致処理のフローについて、図5のフローチャートを参照して説明する。以下のフローチャートの説明で記号Sは「ステップ」を示す。
In this way, the ECU 10 executes a process of intentionally shifting the edge timing of the pulse signal generated by the first timer 15 and the sampling timing of the input signal generated by the second timer 16. This process is called “timing mismatch process”.
Next, the flow of the timing mismatch process of the first embodiment will be described with reference to the flowchart of FIG. In the description of the flowchart below, the symbol S indicates “step”.

S1では、第1タイマ15を起動してパルス信号の出力を開始する。続くS2では、任意の「処理X」が実行される。処理Xは、例えばデバイスの初期化等の処理である。
処理X実行後のS31にて、マイコン11は、第1タイマ15のカウンタ値を所定の値Kに書き換えるとともに、S4にて、第2タイマ16が起動開始し、入力信号のサンプリングを開始する。以下、本実施形態の処理を「書き換え型処理」という。
ここで、「カウンタ値」は、特許請求の範囲に記載の「タイマ値」と相関のある値である。すなわち、直接「タイマ値」を書き換えてもよく、「カウンタ値」を書き換えることによって間接的に「タイマ値」を書き換えるようにしてもよい。
In S1, the first timer 15 is activated to start outputting a pulse signal. In the subsequent S2, an arbitrary “processing X” is executed. The process X is a process such as device initialization.
In S31 after execution of process X, the microcomputer 11 rewrites the counter value of the first timer 15 to a predetermined value K, and in S4, the second timer 16 starts to start and starts sampling of the input signal. Hereinafter, the processing of the present embodiment is referred to as “rewritable processing”.
Here, the “counter value” is a value correlated with the “timer value” recited in the claims. That is, the “timer value” may be directly rewritten, or the “timer value” may be rewritten indirectly by rewriting the “counter value”.

また、「値K」は、入力信号のサンプリングタイミングに対しパルス信号のエッジタイミングが先行する「時間差値」を意味する。言い換えれば、エッジタイミングから値Kに相当する時間が経過した時刻にサンプリングが実行されることとなる。
ところで、パルス周期の1周期には、立ち上がり及び立ち下がりの2つのエッジタイミングが含まれるため、エッジタイミングの周期は、パルス周期の半分(Tp/2)で表される。そこで、値Kを、0でなく(K≠0)、かつ下式1に示すように「N×(Tp/2)(Nは自然数)と異なる値(望ましくは、可及的に近似しない値)」に設定することにより、エッジタイミングとサンプリングタイミングとの一致を回避することができる。
K≠±N×(Tp/2)=±Tp/2,±Tp,±3Tp/2,±2Tp・・・
・・・(式1)
具体的には、値Kを、例えば「0.25Tp」に設定すればよい。あるいは、値Kを、「0.25Tp」を「中間値」としつつ、重畳ノイズの影響を受けない範囲で、所定の幅(本例では「±0.1Tp」)を持たせ、下式2のように設定することができる。
0.15Tp≦K≦0.35Tp ・・・(式2)
The “value K” means a “time difference value” in which the edge timing of the pulse signal precedes the sampling timing of the input signal. In other words, sampling is performed at the time when the time corresponding to the value K has elapsed from the edge timing.
By the way, since one edge of the pulse period includes two edge timings of rising edge and falling edge, the edge timing period is represented by half of the pulse period (Tp / 2). Therefore, the value K is not 0 (K ≠ 0) and is different from “N × (Tp / 2) (N is a natural number) as shown in the following formula 1 (preferably a value that is not approximated as much as possible). ) ”, It is possible to avoid the coincidence between the edge timing and the sampling timing.
K ≠ ± N × (Tp / 2) = ± Tp / 2, ± Tp, ± 3 Tp / 2, ± 2 Tp
... (Formula 1)
Specifically, the value K may be set to “0.25 Tp”, for example. Alternatively, the value K is set to “0.25 Tp” as an “intermediate value” and has a predetermined width (in this example, “± 0.1 Tp”) within a range that is not affected by the superimposed noise. Can be set as follows.
0.15 Tp ≦ K ≦ 0.35 Tp (Formula 2)

このフローでは、処理Xが途中(S2)に実行されることにより、第2タイマ16の起動時に、第1タイマ15のカウンタ値の現在値が静的に定まらない。したがって、第1タイマ15と第2タイマ16との時間的な関係を「動的」に調整し、エッジタイミングとサンプリングタイミングとの一致を回避する必要がある。これにより、入力信号のサンプリングにおいて、パルス出力によって生ずる重畳ノイズの影響を回避することができる。   In this flow, the process X is executed halfway (S2), so that the current value of the counter value of the first timer 15 is not statically determined when the second timer 16 is activated. Therefore, it is necessary to adjust the temporal relationship between the first timer 15 and the second timer 16 to “dynamic” to avoid the coincidence between the edge timing and the sampling timing. Thereby, in the sampling of the input signal, it is possible to avoid the influence of the superimposed noise caused by the pulse output.

特に本実施形態の「書き換え型処理」では、第2タイマ16自身のタイミングを変更するのでなく、相手方である第1タイマ15のタイミングのみを変更する。また、第1タイマ15のタイミングを変更するとき、第1タイマ15の現在値に関係なく、常に、決まった値Kに画一的に書き換えるので、演算負荷を軽減することができる。さらに、後述する「待機型処理」のように入力信号のサンプリング開始が遅れることがないため、迅速な処理が可能である。   In particular, in the “rewritable processing” of the present embodiment, the timing of the second timer 16 itself is not changed, but only the timing of the counterpart first timer 15 is changed. Further, when the timing of the first timer 15 is changed, regardless of the current value of the first timer 15, it is always rewritten uniformly to a predetermined value K, so that the calculation load can be reduced. Furthermore, unlike the “stand-by process” described later, the start of sampling of the input signal is not delayed, so that a quick process is possible.

(第2、第3実施形態)
タイミング不一致処理の別の形態を第2、第3実施形態として説明する。以下の実施形態において、ECU10のシステム構成(図2参照)は、第1実施形態と同様である。
第1実施形態では、第2タイマ16自身のタイミングを変更せず、相手方である第1タイマ15のタイミングを変更する。それに対し、第2、第3実施形態では、第2タイマ16自身のタイミングを変更することを特徴とする。
(Second and third embodiments)
Other forms of timing mismatch processing will be described as second and third embodiments. In the following embodiment, the system configuration (see FIG. 2) of the ECU 10 is the same as that of the first embodiment.
In the first embodiment, the timing of the first timer 15 as the counterpart is changed without changing the timing of the second timer 16 itself. On the other hand, the second and third embodiments are characterized in that the timing of the second timer 16 itself is changed.

第2実施形態のタイミング不一致処理のフローについて、図6のフローチャートを参照して説明する。ここで、第1実施形態と実質的に同一のステップには同一のステップ記号を付す。図6に示すように、S1、S2、S4は、第1実施形態(図5)と実質的に同一であり、処理X実行(S2)後の「S32」のみが、第1実施形態の「S31」に対して異なる。   The flow of the timing mismatch process of the second embodiment will be described with reference to the flowchart of FIG. Here, substantially the same steps as those in the first embodiment are denoted by the same step symbols. As shown in FIG. 6, S1, S2, and S4 are substantially the same as those in the first embodiment (FIG. 5), and only “S32” after execution of the process X (S2) is “ Different from S31 ".

S32にて、マイコン11は、第1タイマ15のカウンタ値が所定の値Kであるか否かを判断する。YESの場合、次のS4に移行し、NOの場合、S32の前に戻り、再度S32の判断を行う。つまり、第1タイマ15のカウンタ値が所定の値Kになるのを待ってS4に移行する。以下、本実施形態の処理を「待機型処理」という。
なお、「カウンタ値」は、第1実施形態と同様、「タイマ値」と相関のある値である。
「待機型処理」では、既に出力しているパルス信号を変更することなく、安定したパルス出力を継続させることができる。また、マイコン11の演算が簡素となる。
In S32, the microcomputer 11 determines whether or not the counter value of the first timer 15 is a predetermined value K. If YES, the process proceeds to the next S4. If NO, the process returns to before S32 and the determination of S32 is performed again. That is, after the counter value of the first timer 15 reaches the predetermined value K, the process proceeds to S4. Hereinafter, the processing of this embodiment is referred to as “standby processing”.
The “counter value” is a value correlated with the “timer value”, as in the first embodiment.
In the “standby processing”, stable pulse output can be continued without changing the pulse signal already output. Further, the calculation of the microcomputer 11 is simplified.

第3実施形態のタイミング不一致処理のフローについて、図7のフローチャートを参照して説明する。ここで、S1、S2、S4は、第1、第2実施形態と実質的に同一であり、処理X実行(S2)後の「S33」のみが、第1、第2実施形態に対して異なる。
S33にて、マイコン11は、第1タイマ15のカウンタ現在値Vpを取得する。そして、取得した現在値Vpに基づき、第2タイマ16は、エッジタイミングとサンプリングタイミングとをずらすように、特定回のサンプリング周期を変更しつつ起動する(S4)。「特定回のサンプリング周期を変更する」とは、例えば起動1回目の周期のみ、サンプリング周期を通常周期に対して特別に変更することをいう。以下、本実施形態の処理を「周期変更型処理」という。
「周期変更型処理」では、取得したカウンタ現在値Vpに基づく演算により、起動1回目のサンプリングタイミングを決定する。既に出力しているパルス信号を変更することがないため、安定したパルス出力を継続させることができる。
The flow of the timing mismatch process of the third embodiment will be described with reference to the flowchart of FIG. Here, S1, S2, and S4 are substantially the same as those in the first and second embodiments, and only “S33” after execution of process X (S2) is different from that in the first and second embodiments. .
In S <b> 33, the microcomputer 11 acquires the counter current value Vp of the first timer 15. Then, based on the acquired current value Vp, the second timer 16 is activated while changing the sampling cycle of a specific number of times so as to shift the edge timing and the sampling timing (S4). “Changing the sampling cycle at a specific time” means, for example, changing the sampling cycle specially with respect to the normal cycle only in the first cycle of activation. Hereinafter, the processing according to the present embodiment is referred to as “period change processing”.
In the “cycle change type process”, the first sampling timing is determined by calculation based on the acquired counter current value Vp. Since the pulse signal that has already been output is not changed, stable pulse output can be continued.

(第4実施形態)
次に、パルス周期Tpとサンプリング周期Tsとの関係について説明する。
図4(c)に示すように、第1実施形態では、サンプリング周期Tsはパルス周期Tpの2倍に設定される。Nを自然数とすると、このようにサンプリング周期Tsがパルス周期TpのN倍の場合には、毎回のサンプリングタイミングにおいて、パルス立ち上がりのエッジタイミングとの時間差(K値)が一定になる。
(Fourth embodiment)
Next, the relationship between the pulse period Tp and the sampling period Ts will be described.
As shown in FIG. 4C, in the first embodiment, the sampling period Ts is set to twice the pulse period Tp. When N is a natural number, when the sampling period Ts is N times the pulse period Tp, the time difference (K value) from the edge timing of the pulse rise is constant at each sampling timing.

また、サンプリング周期Tsがパルス周期Tpの(N/2)倍の場合であっても、毎回のサンプリングタイミングにおいて、パルス立ち上がりまたは立ち下がりのエッジタイミングとの時間差(K値)が交互に一定になる。   Further, even when the sampling period Ts is (N / 2) times the pulse period Tp, the time difference (K value) from the rising edge or falling edge timing is alternately constant at each sampling timing. .

「サンプリング周期Tsがパルス周期Tpの(N/2)倍」を言い換えると、「サンプリング周期Tsがパルス周期の半分(Tp/2)の(N/1)倍」となる。ここで、「N倍」をあえて「(N/1)倍」というのは、倍数の分母が「1」であることを強調するためである。倍数の分母が「1」である場合、上述のように、値Kを「(1/4)Tp」すなわち「0.25Tp」に設定すれば、あるいは「0.25Tp」を中間値とする所定の範囲の値に設定すれば、毎回のサンプリングタイミングにおいてエッジタイミングとの時間差を略一定に維持し、タイミングの一致を回避することができる。   In other words, “the sampling period Ts is (N / 2) times the pulse period Tp” is “the sampling period Ts is (N / 1) times half the pulse period (Tp / 2)”. Here, “N times” means “(N / 1) times” in order to emphasize that the denominator of the multiple is “1”. When the denominator of the multiple is “1”, as described above, the value K is set to “(1/4) Tp”, that is, “0.25 Tp”, or “0.25 Tp” is set as an intermediate value. If the value is set within this range, the time difference from the edge timing can be maintained substantially constant at each sampling timing, and timing coincidence can be avoided.

それに対し、図8(c)に示す比較例、及び図8(d)に示す第4実施形態では、サンプリング周期Tsは、パルス周期Tpの1.25倍、言い換えれば、「パルス周期の半分(Tp/2)の(5/2)倍」に設定される。すなわち、倍数の分母が「2」である。
この場合、値Kを「(1/8)Tp」すなわち「0.125Tp」に設定すれば、あるいは「0.125Tp」を中間値とする所定の範囲の値に設定すれば、毎回のサンプリングタイミングにおいて、エッジタイミングとの一致を回避することが可能となる。
On the other hand, in the comparative example shown in FIG. 8C and the fourth embodiment shown in FIG. 8D, the sampling period Ts is 1.25 times the pulse period Tp, in other words, “half the pulse period ( It is set to (5/2) times Tp / 2). That is, the denominator of the multiple is “2”.
In this case, if the value K is set to “(1/8) Tp”, that is, “0.125 Tp”, or is set to a value in a predetermined range with “0.125 Tp” as an intermediate value, the sampling timing of each time Thus, it is possible to avoid the coincidence with the edge timing.

以上の内容を一般化すると、Qを、Q=N/M(N、Mは自然数、かつN/Mは既約分数)で表される有理数とすれば、サンプリング周期Tsがパルス周期の半分(Tp/2)のQ倍の場合、下式3が成り立つことが、エッジタイミングとの一致を回避するための十分条件となる。
K=(1/4M)Tp ・・・(式3)
Generalizing the above contents, if Q is a rational number represented by Q = N / M (N and M are natural numbers and N / M is an irreducible fraction), the sampling period Ts is half the pulse period ( In the case of Q times Tp / 2), the following equation 3 is satisfied, which is a sufficient condition for avoiding coincidence with the edge timing.
K = (1 / 4M) Tp (Formula 3)

つまり、上記実施形態によるタイミング不一致処理は、サンプリング周期Tsがパルス周期Tpの有理数倍に設定される限り、理論的に適用可能である。言い換えれば、上記実施形態によるタイミング不一致処理が適用できない場合とは、サンプリング周期Tsがパルス周期Tpの無理数倍に設定される場合ということになる。しかし、無理数の周期を設定するということは現実的でない。
したがって、サンプリング周期Tsおよびパルス周期Tpが変動せず、一定であれば、上記実施形態によるタイミング不一致処理は、実質的にあらゆる場合に適応可能である。
That is, the timing mismatch processing according to the above embodiment is theoretically applicable as long as the sampling period Ts is set to a rational multiple of the pulse period Tp. In other words, the case where the timing mismatch processing according to the above embodiment cannot be applied means that the sampling period Ts is set to an irrational multiple of the pulse period Tp. However, setting an irrational period is not practical.
Therefore, if the sampling period Ts and the pulse period Tp do not vary and are constant, the timing mismatch processing according to the above embodiment can be applied to virtually any case.

以上、複数の実施形態を通じて説明したように、「処理X」を実行後、マイコン11から出力されるパルス信号のエッジタイミングについては、第1タイマ15のカウンタ値を調べることにより知ることができる。そして、エッジタイミングとサンプリングタイミングとを動的に調整することは容易であり、マイコン11の処理能力やROM13/RAM14をほとんど圧迫することなく実現可能である。
また、新たな回路の追加や信号の平滑化が不要であるため、素子の増加によるコストアップや信号応答性の低下を招くこともない。さらに、出力信号線21と入力信号線22とを分離実装しないので、ECU10の小型化が阻害されることもない。
As described above, as described in the plurality of embodiments, the edge timing of the pulse signal output from the microcomputer 11 after executing “Process X” can be known by examining the counter value of the first timer 15. Then, it is easy to dynamically adjust the edge timing and the sampling timing, which can be realized with almost no pressure on the processing capacity of the microcomputer 11 and the ROM 13 / RAM 14.
In addition, since it is not necessary to add a new circuit or smooth the signal, there is no increase in cost due to an increase in elements and a decrease in signal response. Further, since the output signal line 21 and the input signal line 22 are not separately mounted, the ECU 10 is not hindered in size reduction.

特に、パルス出力がクロック信号のような固定デューティ出力であり、入力信号のサンプリングタイミングもまた第2タイマ16によって周期的に生成される場合には、上記のタイミング不一致処理をシステム起動時に一回だけ行えばよい。したがって、本発明は、マイコン11の定常的な処理能力を抑えつつノイズの影響を低減する手法として極めて有効である。   In particular, when the pulse output is a fixed duty output such as a clock signal and the sampling timing of the input signal is also periodically generated by the second timer 16, the above timing mismatch processing is performed only once at system startup. Just do it. Therefore, the present invention is extremely effective as a technique for reducing the influence of noise while suppressing the steady processing capability of the microcomputer 11.

(その他の実施形態)
(ア)上記第1〜第3実施形態は、いずれも、第1タイマ15によりパルス信号の出力を開始し「処理X」が実行された後、入力信号をサンプリングするための第2タイマ16を起動する場面でのタイミング不一致処理を示している(図5〜7参照)。すなわち、第2タイマ16を主体とし、先行する第1タイマ15が生成するエッジタイミングに対し、遅れて起動する第2タイマ16が実行する処理を対象としている。
(Other embodiments)
(A) In any of the first to third embodiments, the first timer 15 starts outputting the pulse signal, and after the “process X” is executed, the second timer 16 for sampling the input signal is provided. The timing mismatch process in the scene to start is shown (refer FIGS. 5-7). In other words, the second timer 16 is the main subject, and the processing executed by the second timer 16 that starts late with respect to the edge timing generated by the preceding first timer 15 is targeted.

これに対し、他の実施形態では、第1タイマ15を主体とし、既に作動中の第2タイマ16のサンプリングタイミングに応じて第1タイマ15が同様のタイミング不一致処理を実行することとしてもよい。具体的には、第1〜第3実施形態に対応して、下記の第1〜第3変形例のタイミング不一致処理を挙げることができる。   On the other hand, in another embodiment, the first timer 15 may be the main body, and the first timer 15 may perform the same timing mismatch process according to the sampling timing of the already operating second timer 16. Specifically, the timing mismatch processing of the following first to third modifications can be given corresponding to the first to third embodiments.

(第1変形例)
第2タイマ16が出力するカウンタ値をパルス信号のエッジタイミングに対応して所定の値に書き換える(書き換え型処理)。
(第2変形例)
第1タイマ15は、第2タイマ16が出力するカウンタ値が所定の値になるのを待って出力する(待機型処理)。
(第3変形例)
第1タイマ15は、第2タイマ16が出力するカウンタ現在値に基づいて、特定回のパルス出力(例えば、起動1回目)の周期を所定の周期に変更する(周期変更型処理)。
(First modification)
The counter value output from the second timer 16 is rewritten to a predetermined value corresponding to the edge timing of the pulse signal (rewritable processing).
(Second modification)
The first timer 15 waits for the counter value output from the second timer 16 to reach a predetermined value and outputs it (standby processing).
(Third Modification)
The first timer 15 changes the period of a specific number of pulse outputs (for example, the first activation) based on the current counter value output from the second timer 16 to a predetermined period (period change type process).

(イ)上記実施形態における「処理X」を実行しない場合には、第1タイマ15および第2タイマ16は、パルス信号のエッジタイミングと入力信号のサンプリングタイミングとを予め所定の時間ずらして起動されてもよい。この場合、パルス信号のエッジタイミングと入力信号のサンプリングタイミングとは「静的」に調整される。   (A) When “Processing X” in the above embodiment is not executed, the first timer 15 and the second timer 16 are started by shifting the edge timing of the pulse signal and the sampling timing of the input signal by a predetermined time in advance. May be. In this case, the edge timing of the pulse signal and the sampling timing of the input signal are adjusted to “static”.

(ウ)パルス出力信号は、上記実施形態で例示したクロック監視に用いられる信号に限らず、例えば、他のECUとの通信等に用いられる信号等でもよい。
(エ)入力信号は、ECU10の内部(上記実施形態では駆動回路32)から入力される場合に限らず、ECU10の外部から入力されてもよい。
(オ)第1タイミング生成手段および第2タイミング生成手段は、必ずしも「第1タイマ15および第2タイマ16」のように物理的に独立した2つのタイマ素子で構成される必要はない。2つのタイミング生成手段の機能を1つのタイマ素子が兼ね備えてもよい。
また、CPU12がタイミング生成手段として機能してもよい。
(C) The pulse output signal is not limited to the signal used for clock monitoring exemplified in the above embodiment, and may be a signal used for communication with other ECUs, for example.
(D) The input signal is not limited to being input from the inside of the ECU 10 (in the above embodiment, the drive circuit 32), but may be input from the outside of the ECU 10.
(E) The first timing generation means and the second timing generation means do not necessarily need to be composed of two physically independent timer elements like the “first timer 15 and the second timer 16”. One timer element may have the functions of two timing generation means.
Further, the CPU 12 may function as a timing generation unit.

(カ)上記実施形態では、入力信号のサンプリングは周期的に実行された。この場合、サンプリングの開始時にタイミング不一致処理を一度実行すれば、パルス出力が一定のパルス周期Tpで継続される限り、重畳ノイズを回避し続けることとなった。
これに対し、入力信号のサンプリングが周期的でなく、都度実行されてもかまわない。この場合、第2タイマ16は、サンプリングの都度、タイミング不一致処理を実行する。具体例としては、第2タイマ16によってサンプリングタイミングが生成された後、第1タイマ15が出力するカウンタ値が所定の値になるのを待って入力信号の値を取得する。
このように、入力信号のサンプリングが都度実行される場合であっても、「パルス出力によって生ずる重畳ノイズの影響を回避する」効果は同様に発揮される。
(F) In the above embodiment, the sampling of the input signal is periodically executed. In this case, if the timing mismatch processing is executed once at the start of sampling, the superimposed noise is continuously avoided as long as the pulse output is continued at a constant pulse period Tp.
On the other hand, the sampling of the input signal is not periodic and may be executed each time. In this case, the second timer 16 executes timing mismatch processing each time sampling is performed. As a specific example, after the sampling timing is generated by the second timer 16, the value of the input signal is acquired after waiting for the counter value output from the first timer 15 to become a predetermined value.
As described above, even when the sampling of the input signal is executed each time, the effect of “avoiding the influence of the superimposed noise caused by the pulse output” is similarly exhibited.

(キ)本発明の電子制御装置は、電動パワーステアリング装置の他、例えば、VGRS(ギア比可変ステアリング)、ARS(アクティブリアステアリング)等、様々な用途に適用することができる。
以上、本発明はこのような実施形態に限定されるものではなく、発明の趣旨を逸脱しない範囲において、種々の形態で実施することができる。
(G) The electronic control device of the present invention can be applied to various applications such as VGRS (variable gear ratio steering) and ARS (active rear steering) in addition to the electric power steering device.
As mentioned above, this invention is not limited to such embodiment, In the range which does not deviate from the meaning of invention, it can implement with a various form.

1 ・・・電動パワーステアリング装置、
10 ・・・ECU(電子制御装置)、
11 ・・・マイコン(マイクロコンピュータ)、
15 ・・・第1タイマ(第1タイミング生成手段)、
16 ・・・第2タイマ(第2タイミング生成手段)、
21 ・・・出力信号線、
22 ・・・入力信号線、
Tp ・・・パルス周期、
Ts ・・・サンプリング周期。
1 ... Electric power steering device,
10: ECU (electronic control unit),
11 ... microcomputer (microcomputer),
15 ... 1st timer (1st timing production | generation means),
16 ... 2nd timer (2nd timing production | generation means),
21 ... Output signal line,
22 ・ ・ ・ Input signal line,
Tp ... pulse period,
Ts: Sampling cycle.

Claims (12)

マイクロコンピュータと、
前記マイクロコンピュータから出力されるパルス信号を伝送する出力信号線と、
前記マイクロコンピュータへ入力信号を伝送する入力信号線と、を備え、
前記マイクロコンピュータは、前記パルス信号の周期的な立ち上がり及び立ち下がりタイミングであるエッジタイミングを生成する第1タイミング生成手段、及び、前記入力信号の値を周期的に取得するためのサンプリングタイミングを生成する第2タイミング生成手段を有し、
前記第1タイミング生成手段および前記第2タイミング生成手段は、前記パルス信号のエッジタイミングと前記入力信号のサンプリングタイミングとに時間差をもたらすタイミング不一致処理を実行することを特徴とする電子制御装置。
A microcomputer,
An output signal line for transmitting a pulse signal output from the microcomputer;
An input signal line for transmitting an input signal to the microcomputer,
The microcomputer generates first timing generation means for generating edge timings that are periodic rising and falling timings of the pulse signal, and sampling timing for periodically acquiring the value of the input signal. Having a second timing generation means;
The electronic control device, wherein the first timing generation unit and the second timing generation unit execute timing mismatch processing that causes a time difference between an edge timing of the pulse signal and a sampling timing of the input signal.
前記第1タイミング生成手段によって前記パルス信号の出力が開始され当該パルス信号による処理が実行された後、前記第2タイミング生成手段が前記入力信号のサンプリングを開始する前に、前記タイミング不一致処理を実行することを特徴とする請求項1に記載の電子制御装置。   After the output of the pulse signal is started by the first timing generation means and the processing by the pulse signal is executed, the timing mismatch processing is executed before the second timing generation means starts sampling of the input signal The electronic control device according to claim 1. 前記タイミング不一致処理において、前記第1タイミング生成手段が出力するタイマ値を前記入力信号のサンプリングタイミングに対応して所定の値に書き換えることを特徴とする請求項2に記載の電子制御装置。   3. The electronic control device according to claim 2, wherein, in the timing mismatch processing, the timer value output from the first timing generation unit is rewritten to a predetermined value corresponding to the sampling timing of the input signal. 前記タイミング不一致処理において、前記第2タイミング生成手段は、前記第1タイミング生成手段が出力するタイマ値が所定の値になるのを待って起動することを特徴とする請求項2に記載の電子制御装置。   3. The electronic control according to claim 2, wherein, in the timing mismatch processing, the second timing generation unit is activated after the timer value output from the first timing generation unit reaches a predetermined value. apparatus. 前記タイミング不一致処理において、前記第2タイミング生成手段は、前記第1タイミング生成手段が出力するタイマ値の現在値に基づいて、特定回のサンプリング周期を所定の周期に変更することを特徴とする請求項2に記載の電子制御装置。   In the timing mismatch processing, the second timing generation unit changes a sampling cycle of a specific number of times to a predetermined cycle based on a current value of a timer value output from the first timing generation unit. Item 3. The electronic control device according to Item 2. 前記第1タイミング生成手段によって前記パルス信号の出力が開始され当該パルス信号による処理が実行された後、さらに前記第2タイミング生成手段が前記入力信号のサンプリングを開始した後に、前記タイミング不一致処理を実行することを特徴とする請求項1に記載の電子制御装置。   After the output of the pulse signal is started by the first timing generation means and the processing by the pulse signal is executed, the timing mismatch processing is executed after the second timing generation means starts sampling of the input signal The electronic control device according to claim 1. 前記タイミング不一致処理において、前記第2タイミング生成手段が出力するタイマ値を前記パルス信号のエッジタイミングに対応して所定の値に書き換えることを特徴とする請求項6に記載の電子制御装置。   The electronic control device according to claim 6, wherein in the timing mismatch processing, the timer value output from the second timing generation unit is rewritten to a predetermined value corresponding to an edge timing of the pulse signal. 前記タイミング不一致処理において、前記第1タイミング生成手段は、前記第2タイミング生成手段が出力するタイマ値が所定の値になるのを待って出力することを特徴とする請求項6に記載の電子制御装置。   7. The electronic control according to claim 6, wherein, in the timing mismatch processing, the first timing generation unit waits until the timer value output from the second timing generation unit reaches a predetermined value. apparatus. 前記タイミング不一致処理において、前記第1タイミング生成手段は、前記第2タイミング生成手段が出力するタイマ値の現在値に基づいて、特定回のパルス周期を所定の周期に変更することを特徴とする請求項6に記載の電子制御装置。   In the timing mismatch processing, the first timing generation unit changes a pulse cycle of a specific number of times to a predetermined cycle based on a current value of a timer value output from the second timing generation unit. Item 7. The electronic control device according to Item 6. 前記第1タイミング生成手段および前記第2タイミング生成手段は、前記パルス信号のエッジタイミングと前記入力信号のサンプリングタイミングとを、予め所定の時間ずらして起動されることを特徴とする請求項1に記載の電子制御装置。   The first timing generation unit and the second timing generation unit are started by shifting the edge timing of the pulse signal and the sampling timing of the input signal by a predetermined time in advance. Electronic control unit. マイクロコンピュータと、
前記マイクロコンピュータから出力されるパルス信号を伝送する出力信号線と、
前記マイクロコンピュータへ入力信号を伝送する入力信号線と、を備え、
前記マイクロコンピュータは、前記パルス信号の周期的な立ち上がり及び立ち下がりタイミングであるエッジタイミングを生成する第1タイミング生成手段、及び、前記入力信号の値を都度取得するためのサンプリングタイミングを生成する第2タイミング生成手段を有し、
前記第1タイミング生成手段および前記第2タイミング生成手段は、前記パルス信号のエッジタイミングと前記入力信号のサンプリングタイミングとに時間差をもたらすタイミング不一致処理を実行することを特徴とする電子制御装置。
A microcomputer,
An output signal line for transmitting a pulse signal output from the microcomputer;
An input signal line for transmitting an input signal to the microcomputer,
The microcomputer generates first timing generation means for generating edge timings that are periodic rising and falling timings of the pulse signal, and second sampling timing for acquiring the value of the input signal each time. Having timing generation means;
The electronic control device, wherein the first timing generation unit and the second timing generation unit execute timing mismatch processing that causes a time difference between an edge timing of the pulse signal and a sampling timing of the input signal.
前記タイミング不一致処理において、前記第2タイミング生成手段によってサンプリングタイミングが生成された後に、前記第1タイミング生成手段が出力するタイマ値が所定の値になるのを待って前記入力信号の値を取得することを特徴とする請求項11に記載の電子制御装置。   In the timing mismatch processing, after the sampling timing is generated by the second timing generation unit, the value of the input signal is obtained after the timer value output from the first timing generation unit reaches a predetermined value. The electronic control device according to claim 11.
JP2011139229A 2011-06-23 2011-06-23 Electronic control unit Active JP5582100B2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2011139229A JP5582100B2 (en) 2011-06-23 2011-06-23 Electronic control unit
DE102012105267.0A DE102012105267B4 (en) 2011-06-23 2012-06-18 Electronic control unit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011139229A JP5582100B2 (en) 2011-06-23 2011-06-23 Electronic control unit

Publications (2)

Publication Number Publication Date
JP2013006465A true JP2013006465A (en) 2013-01-10
JP5582100B2 JP5582100B2 (en) 2014-09-03

Family

ID=47321491

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011139229A Active JP5582100B2 (en) 2011-06-23 2011-06-23 Electronic control unit

Country Status (2)

Country Link
JP (1) JP5582100B2 (en)
DE (1) DE102012105267B4 (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH01206726A (en) * 1988-02-15 1989-08-18 Hitachi Ltd Digital and analog consolidation integrated circuit
JPH08298210A (en) * 1995-03-02 1996-11-12 Honda Motor Co Ltd Controller for pulse width modulation solenoid
JPH10107629A (en) * 1996-10-02 1998-04-24 Hitachi Ltd Signal processing unit and system provided with it
JP2004228860A (en) * 2003-01-22 2004-08-12 Denso Corp Semiconductor integrated circuit device
JP2008277969A (en) * 2007-04-26 2008-11-13 Toyota Motor Corp Noise removing device
JP2009202612A (en) * 2008-02-26 2009-09-10 Nsk Ltd Electric power steering device

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6433625B1 (en) 2001-11-01 2002-08-13 Lsi Logic Corporation Noise reduction auto phasing circuit for switched capacitor circuits
US7209061B2 (en) 2005-03-30 2007-04-24 Silicon Laboratories, Inc. Method and system for sampling a signal
US7940202B1 (en) 2008-07-31 2011-05-10 Cypress Semiconductor Corporation Clocking analog components operating in a digital system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH01206726A (en) * 1988-02-15 1989-08-18 Hitachi Ltd Digital and analog consolidation integrated circuit
JPH08298210A (en) * 1995-03-02 1996-11-12 Honda Motor Co Ltd Controller for pulse width modulation solenoid
JPH10107629A (en) * 1996-10-02 1998-04-24 Hitachi Ltd Signal processing unit and system provided with it
JP2004228860A (en) * 2003-01-22 2004-08-12 Denso Corp Semiconductor integrated circuit device
JP2008277969A (en) * 2007-04-26 2008-11-13 Toyota Motor Corp Noise removing device
JP2009202612A (en) * 2008-02-26 2009-09-10 Nsk Ltd Electric power steering device

Also Published As

Publication number Publication date
DE102012105267A1 (en) 2012-12-27
JP5582100B2 (en) 2014-09-03
DE102012105267B4 (en) 2018-07-12

Similar Documents

Publication Publication Date Title
US10654518B2 (en) Motor control apparatus, motor drive system, and motor control method
EP2842838B1 (en) Electric power steering system
JP6579006B2 (en) Sensor device and electric power steering device using the same
JP5196211B2 (en) Vehicle steering system
JP7239030B2 (en) motor controller
JP5655975B1 (en) Multiphase motor control device and electric power steering device using the same
US10053141B2 (en) Communication system
JP6662721B2 (en) Control device, motor control device, and electric power steering device
JP6458673B2 (en) Communications system
JP7010081B2 (en) Motor control device and motor drive system
WO2016098244A1 (en) Motor control device and electric power steering device using same
EP1662647A2 (en) Power steering control device and power steering control method
JP5582100B2 (en) Electronic control unit
JP5831060B2 (en) Motor control device and vehicle steering device
JP6136803B2 (en) Motor control device and electric power steering device using the same
JP5929521B2 (en) Motor control device and electric power steering device using the same
JP2007152994A (en) Electric power steering control device and method
JP6679861B2 (en) Sensor device and electric power steering device using the same
JP6758494B2 (en) Rotation angle detector and AC rotor control device
JP2007062526A (en) Electric power steering device
JP6690164B2 (en) Communications system
JP7227721B2 (en) steering device
JP5387987B2 (en) Motor drive device and control method of electronic control device in motor drive device
JP4105034B2 (en) Electric power steering control device
JP2014171307A (en) Motor control device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20121114

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20131010

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20131217

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20140129

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20140630

R151 Written notification of patent or utility model registration

Ref document number: 5582100

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151

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