JP3901082B2 - A / D converter controller - Google Patents

A / D converter controller Download PDF

Info

Publication number
JP3901082B2
JP3901082B2 JP2002354837A JP2002354837A JP3901082B2 JP 3901082 B2 JP3901082 B2 JP 3901082B2 JP 2002354837 A JP2002354837 A JP 2002354837A JP 2002354837 A JP2002354837 A JP 2002354837A JP 3901082 B2 JP3901082 B2 JP 3901082B2
Authority
JP
Japan
Prior art keywords
converter
time
conversion
control device
control
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2002354837A
Other languages
Japanese (ja)
Other versions
JP2004187207A (en
Inventor
鎮男 眞鍋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Toyota Motor Corp
Original Assignee
Toyota Motor 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 Toyota Motor Corp filed Critical Toyota Motor Corp
Priority to JP2002354837A priority Critical patent/JP3901082B2/en
Publication of JP2004187207A publication Critical patent/JP2004187207A/en
Application granted granted Critical
Publication of JP3901082B2 publication Critical patent/JP3901082B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Analogue/Digital Conversion (AREA)

Description

【0001】
【発明の属する技術分野】
本発明は、アナログ信号をデジタル信号に変換するA/D変換器の制御装置に関する。
【0002】
【従来の技術】
従来より、電磁弁や電磁式のアクチュエータには、例えばその動力源としてリニアソレノイドが設けられており、電磁弁の開度やアクチュエータの変位量を調整する際には、その変位量を検出し、その検出変位量が目標変位量となるようにフィードバック制御が行われる。この変位量はリニアソレノイドを流れる電流値に基づいて検出することができるため、リニアソレノイドの通電電流値を検出し、その通電電流値が目標変位量に応じた目標電流値となるようにフィードバック制御が行われるようになっている。
【0003】
このような誘導性負荷に流れる電流をフィードバック制御する技術として、例えば特許文献1に示される制御装置が提案されている。この制御装置は、自動車に搭載された電磁弁に組み込まれたリニアソレノイド制御装置である。このリニアソレノイド制御装置において、制御CPUは例えばホストCPUから入力される目標電流値とリニアソレノイドに実際に流れた実電流値(検出電流値)との偏差に基づき、リニアソレノイドをデューティ駆動するためのデューティ比を算出するフィードバック演算を実行する。PWM信号出力回路は、制御CPUによって算出されたデューティ比に対応したPWM信号を所定の一定周期にて出力することで、スイッチング素子をデューティ駆動することによりリニアソレノイドを通電駆動する。また、リニアソレノイドの通電経路に設けられた電流検出用抵抗の両端電圧はA/D変換器にてA/D変換され、リニアソレノイドに流れた電流を表す検出電流値として、A/Dデータ受渡用RAMに入力される。制御CPUはPWM信号出力回路から出力されるPWM信号の一定周期よりも短い周期毎にA/D変換器を起動させる。そして、制御CPUは、A/Dデータ受渡用RAMからPWM信号のm周期時間(mは整数)分の複数の検出電流値を取り込み、該取り込んだ検出電流値を算術平均することにより、m周期時間内の平均電流値を算出する。この後、制御CPUは、前記PWM信号の一定周期よりも長い所定周期毎に平均電流値と目標電流値とに基づきフィードバック演算を行い、PWM信号用のデューティ比を算出する。そして、このように算出された最新のデューティ比がPWM信号出力回路の各出力周期に反映されてそのデューティ比に応じたPWM信号が出力され、リニアソレノイドが通電駆動されることとなる。
【0004】
【特許文献1】
特開平11−308107号公報
【0005】
【発明が解決しようとする課題】
特許文献1の制御方法において、リニアソレノイドの制御精度を向上させるためには、正確な平均電流値を得ることが必要となり、そのためには、検出電流値のA/D変換の周期を均一にする、すなわち、制御CPUによるA/D変換器の起動周期を均一にすることが必要とされる。制御CPUはA/D変換完了に伴ってA/D変換器から出力される割込信号に基づいて、A/D変換された検出電流値のA/Dデータ受渡用RAMへの取り込み処理、及び複数の検出電流値に基づく平均電流値の算出処理等のA/D割込処理を実行する。このA/D割込処理の後、制御CPUは、前回の起動時刻に対して、A/D変換の周期時間を加えることにより次回のA/D変換器の起動時刻を設定する。ここで、制御CPUはリニアソレノイドの制御以外の他の優先度の高い割込制御を実行するものとする。すると、例えば、制御CPUによるA/D割込処理の実行中に、他の優先度の高い割込制御のための割込が発生すると、制御CPUはA/D割込処理を途中で中断する。そして、制御CPUは、その優先度の高い割込処理を実行した後、前記中断したA/D割込処理を再実行してそれが完了すると、A/D変換器の起動時刻の設定を行う。そのため、このように他の優先度の高い割込処理の割込が発生すると、A/D変換器の起動時刻の設定時期がA/D変換周期の終端側に遅れることとなる。A/D変換器の起動時刻の設定処理にも所定の時間を要するため、起動時刻の設定開始時期が前記A/D変換周期の終端時期よりも前の時刻であったとしても、その設定終了時期が前記A/D変換周期の終端時期よりも後の時刻となることがある。この場合には次回のA/D変換の起動時刻において制御CPUがA/D変換を起動することができず、A/D変換周期の1周期分における検出電流値を取得することができなくなる。その結果、正確な平均電流値を得られなくなり、リニアソレノイドの制御精度が低下するという問題がある。
【0006】
本発明は、こうした問題に鑑みてなされたものであり、その目的は、A/D変換器を所定周期にて起動させることができるA/D変換器制御装置を提供することにある。
【0007】
【課題を解決するための手段】
以下、上記目的を達成するための手段及びその作用効果について記載する。
請求項1に記載の発明は、入力信号を取り込んでデジタル値に変換するA/D変換器と、前記A/D変換器の変換完了に伴い、前記A/D変換器の前回の起動時刻に所定の変換周期時間を加算して次回の起動時刻の設定処理を行うとともに、その設定された起動時刻となった時に前記A/D変換器を起動させる制御部とを備え、前記A/D変換器に所定の変換周期にてA/D変換を行わせるようにしたA/D変換器制御装置において、前記制御部は、前記設定処理の開始時刻が次回の起動時刻以降の時間であるときには前記A/D変換器を強制的に起動させることを特徴とする。
【0008】
A/D変換器制御装置において、A/D変換器の変換完了に伴う割込が発生しても、他の優先度の高い割込処理が発生すると、その優先度の高い割込処理が実行された後、起動時刻の設定処理が実行される。そのため、このように他の優先度の高い割込処理が発生すると、起動時刻の設定時期がA/D変換の変換周期の終端側に遅れることとなる。この設定処理の開始時刻が次回の起動時刻以降である場合には、その次回の起動時刻にてA/D変換器を起動することができず、A/D変換の検出電流値の取りこぼしが発生することとなる。
【0009】
この構成によれば、A/D変換器の変換完了に伴う起動時刻の設定処理の開始時刻が次回の起動時刻以降の時間であるときにはA/D変換器を強制的に起動される。そのため、A/D変換器をほぼ所定の変換周期にて連続して起動させることができ、A/D変換の検出電流値のとりこぼしをなくすことができる。
【0010】
請求項2に記載の発明は、請求項1に記載のA/D変換器制御装置において、前記制御部は、前記設定処理の開始時刻が次回の起動時刻よりも前の所定時間以内の時刻であるときには前記A/D変換器を強制的に起動させることを特徴とする。
【0011】
A/D変換器の起動時刻の設定処理にも所定の時間を要するため、起動時刻の設定処理の開始時刻が変換周期の終端時期よりも前の時刻であったとしても、設定処理の終了が変換周期の終端時期よりも後の時刻となることがある。この場合にも次回の起動時刻にてA/D変換器を起動することができず、A/D変換の検出電流値の取りこぼしが発生することとなる。
【0012】
この構成によれば、A/D変換器の変換完了に伴う起動時刻の設定処理の開始時刻が次回の起動時刻よりも前の所定時間以内の時刻であるときにはA/D変換器を強制的に起動させる。そのため、A/D変換器をほぼ所定の変換周期にて連続して起動させることができ、A/D変換の検出電流値のとりこぼしをなくすことができる。
【0013】
請求項3に記載の発明のように、所定時間として少なくとも起動時間の設定処理に要する時間を含むようにしてもよい。
請求項4に記載の発明は、請求項1〜3のいずれかに記載のA/D変換器制御装置において、前記制御部は、前記A/D変換器の強制起動が連続して所定回数以上行われたときには、前回の起動時期として現在時刻を設定することを特徴とする。
【0014】
この構成によれば、A/D変換器の強制起動が連続して所定回数以上行われると、A/D変換の変換周期は本来の変換周期から大きくずれるおそれがある。この構成によれば、A/D変換器の強制起動が連続して所定回数以上行われたときには、前回の起動時期として現在時刻が設定されるので、A/D変換の変換周期を本来の変換周期にすることができるようになる。
【0015】
【発明の実施の形態】
以下、本発明を具体化した一実施形態を図面に従って説明する。
図1は、本発明が適用されたA/D変換器制御装置10の構成を表すブロック図である。
【0016】
本実施形態のA/D変換器制御装置10は、自動車に搭載されたエンジンを目標状態に制御するために、エンジンに設けられたリニアソレノイド24を通電制御するとともに、A/D変換器28の起動制御、及びエンジンの燃料噴射制御及び点火制御等の制御をも実施するものである。
【0017】
A/D変換器制御装置10には制御IC12が備えられている。この制御IC12は、例えば変速機コントロール用のCPUによって算出されたリニアソレノイド24に流すべき電流を表すデータ(目標電流値)に従い、リニアソレノイド24に流れる電流をフィードバック制御する。
【0018】
制御IC12は、制御CPU14とPWM信号出力回路16とデータ受渡用RAM18とを備えている。制御CPU14は、リニアソレノイド24をPWM信号にてデューティ駆動するための制御指令値としてのデューティ比を算出し、その検出結果をPWMデータ(駆動データ)としてPWM信号出力回路16に出力する。
【0019】
PWM信号出力回路16は、制御CPU14からリニアソレノイド24に対するPWMデータを読み込み、リニアソレノイド24をデューティ駆動するための制御信号としてのPWM信号SG1を生成する。
【0020】
一方、制御対象となるリニアソレノイド24は、バッテリの正極(電源電圧Vb)からバッテリの負極(グランド)に至る電源ライン中に配設されている。電源ラインにおけるリニアソレノイド24の電源Vb側には、スイッチング手段としてのFET22が設けられている。このFET22のゲート端子にはPWM信号SG1が入力される。PWM信号SG1がHレベルであるときにFET22はオン状態となり、バッテリからリニアソレノイド24への通電経路を通電させる。逆に、PWM信号SG1がLレベルであるときにFET22はオフ状態となり、リニアソレノイド24の通電経路を遮断する。
【0021】
また、リニアソレノイド24のグランド側には、検出手段としての電流検出用抵抗26が設けられている。つまり、所定の電位差を生じる電源ライン中に、誘導性負荷としてのリニアソレノイド24およびスイッチング素子としてのFET22が直列に接続され、この直列回路に対し電流検出用抵抗26が直列に接続されている。この抵抗26は、リニアソレノイド24に流れる電流を検出するためのものである。
【0022】
電流検出用抵抗26の両端はA/D変換器(A/D変換手段)28に接続されている。A/D変換器28は、制御CPU14から一定のA/D変換周期にて出力される起動信号KSに基づいて起動される。A/D変換器28は、制御CPU14によって起動される毎に、リニアソレノイド24に流れた電流を表す電流検出信号(電圧)を順に取り込んでデジタル値に変換し、A/D変換が完了すると制御CPU14に対して割込信号WSを出力する。
【0023】
制御CPU14は、A/D変換器28から入力される割込信号WSに基づいてA/D割込処理を実行する。このA/D割込処理では、A/D変換器28によって変換されたデジタル値をデータ受渡用RAM18に順次格納するとともに、データ受渡用RAM18に格納されたPWM信号SG1の1周期時間分に相当するデジタル値を平均することによりリニアソレノイド24に流れる通電電流の平均電流値を算出する。また、制御CPU14はこの平均電流値の算出処理の後に、A/D変換器28の次回の起動時刻の設定処理を行う。更に、制御CPU14は、現在時刻Tpが次回の遅延トリガ設定時刻Tn以上のときには、A/D変換器28を強制的に起動させるようになっている。
【0024】
次に、A/D変換器制御装置10の作用を説明する。
図1に示されるように、制御CPU14での機能構成として、フィードバック(以下、F/B)演算部30と、平均値算出部32と、割込時間設定部34とを有する。
【0025】
平均値算出部32は、A/D変換器28のA/D変換完了に伴う割込信号WSに基づいて、A/D変換器28によって変換されたデジタル値をデータ受渡用RAM18に順次格納する。また、平均値算出部32は、データ受渡用RAM18に格納されたPWM信号SG1の1周期時間分に相当するデジタル値を平均することによりリニアソレノイド24に流れる平均電流値を算出する。
【0026】
F/B演算部30は、リニアソレノイド24の目標電流値と平均値算出部32によって算出された平均電流値とを入力し、この目標電流値と平均電流値とに基づいてリニアソレノイド24の通電電流が目標電流値となるように制御するためのデューティ比を算出する。
【0027】
割込時間設定部34は、平均値算出部32の平均電流値の算出後において、次回のA/D変換器28の起動時期を設定する。
割込時間設定部34での割込時間設定処理に関し、より詳しくは、図2に示すように、制御CPU14は、ステップ110で現在時刻Tpを取り込む。
【0028】
次のステップ120において、制御CPU14は前回の遅延トリガ設定時刻ToにA/D変換周期Aを加算することにより次回の遅延トリガ設定時刻Tnを更新する。
【0029】
この後、ステップ130において、制御CPU14は現在時刻Tpが前回(n回)の遅延トリガ設定時刻Toより大きいかどうかを判定する。現在時刻Tpが前回の遅延トリガ設定時刻To以下であると判定すると(ステップ130:NO)、ステップ200に移行する。
【0030】
一方、現在時刻Tpが前回の遅延トリガ設定時刻Toより大きいと判定すると(ステップ130:YES)、ステップ140に進む。ステップ140において、制御CPU14は現在時刻Tpが次回(n+1回)の遅延トリガ設定時刻Tnより小さいかどうかを判定する。現在時刻Tpが次回の遅延トリガ設定時刻Tn以上であると判定すると(ステップ140:NO)、ステップ200に移行する。
【0031】
一方、現在時刻Tpが次回の遅延トリガ設定時刻Tnより小さいと判定すると(ステップ140:YES)、ステップ150に進む。
ステップ150において、制御CPU14は次回の遅延トリガ設定時刻TrとしてTnを設定する。次に、制御CPU14はステップ160において、強制起動回数Mを0に設定し、続くステップ170において前回の遅延トリガ設定時刻ToをTnに更新する。
【0032】
そして、ステップ180において、時間が経過して前記ステップ150にて設定された遅延トリガ設定時刻Trになると、制御CPU14は遅延トリガを出力してA/D変換器28を起動させる。
【0033】
また、ステップ130においてNOと判定されたり、ステップ140においてNOと判定されると、変換周期が本来のA/D変換周期からずれていると考えられるため、ステップ200において、制御CPU14はA/D変換器28を強制的に起動する。そして、ステップ210では制御CPU14は強制起動回数Mをインクリメントする。
【0034】
ステップ210に続くステップ220において、制御CPU14は強制起動回数Mが3より大きいかどうかを判定する。ここで、強制起動回数Mが3以下であると判定すると(ステップ220:NO)、処理はステップ230に進み、強制起動回数Mが3より大きいと判定すると(ステップ220:YES)、処理はステップ240に進む。
【0035】
ステップ230では、制御CPU14は前回の遅延トリガ設定時刻ToをTnに更新する。
ステップ240では、前回の遅延トリガ設定時刻Toを現在時刻Tpに更新する。
【0036】
この図2の処理を図式化したのが図3及び図4である。図3に示すように、PWM信号出力回路16のPWM信号SG1の出力周期において、A/D変換器28は所定のA/D変換周期にて起動される。
【0037】
この詳細を図4に示す。A/D変換器28の変換完了に伴う割込信号WSの入力された時刻が次回の遅延トリガ設定時刻Trより小さいと、次回の遅延トリガ設定時刻Trは前回の遅延トリガ設定時刻Toに対して変換周期Aを加えた値に設定される。そして、時間が経過してその設定された起動時間になると、A/D変換器28が起動されてリニアソレノイド24の通電電流のA/D変換が実行される。
【0038】
また、図4に鎖線で示すように、A/D変換器28の変換完了に伴う割込信号WSの入力された時刻が次回の遅延トリガ設定時刻Tr以上であると、制御CPU14によってA/D変換器28は強制的に起動されてリニアソレノイド24の通電電流のA/D変換が実行される。このとき、前回の遅延トリガ設定時刻ToはTnに更新される。
【0039】
さて、本実施の形態は、以下の効果がある。
・ 制御CPU14はA/D変換器28の変換完了に伴うA/D変換器28の起動時間の設定処理の開始時刻が次回の起動時刻以降の時間であるときにはA/D変換器を強制的に起動させるようにしている。そのため、A/D変換器28をほぼ所定の変換周期Aにて連続して起動させることができ、A/D変換の検出電流値のとりこぼしをなくすことができる。
【0040】
・ 制御CPU14はA/D変換器28の変換完了に伴う起動時刻の設定処理の開始時刻が次回の起動時刻よりも前の所定時間以内の時刻であるときにはA/D変換器28を強制的に起動させる。そのため、A/D変換器28をほぼ所定の変換周期にて連続して起動させることができ、A/D変換の検出電流値のとりこぼしをなくすことができる。
【0041】
・ 制御CPU14はA/D変換器28の強制起動が連続して所定回数以上行われたときには、前回の起動時期として現在時刻が設定されるので、A/D変換の変換周期を本来の変換周期にすることができるようになる。
【0042】
なお、実施の形態は、次のように変更してもよい。
・ 上記実施形態では、A/D変換器28の強制起動が連続して3回以上行われたときには、前回の起動時期として現在時刻を設定するようにしたが、この強制起動の回数は任意に設定してもよい。
【0043】
・ 上記実施形態では、リニアソレノイド24のフィードバック制御装置に具体化したが、これに限定されず、制御対象の動作状態を検出して目標値となるようにフィードバック制御を行うものに具体化することができる。
【0044】
次に、上記各実施形態から把握できる他の技術的思想を、以下に記載する。
・ アナログ入力信号を取り込んでデジタル値に変換するA/D変換器の変換完了に伴い、前記A/D変換器の前回の起動時刻に所定の変換周期時間を加算して次回の起動時刻を設定し、その設定された起動時刻となった時に前記A/D変換器を起動させることにより、前記A/D変換器に所定の変換周期にてA/D変換を行わせるようにしたA/D変換器制御方法において、前記次回の起動時刻の設定処理の開始時刻が次回の起動時刻以降の時間であるときには前記A/D変換器を強制的に起動させるようにしたことを特徴とするA/D変換器制御方法。
【図面の簡単な説明】
【図1】本発明が適用されたA/D変換器制御装置の構成を表す機能ブロック図。
【図2】制御装置が実行する起動時間設定制御を示すフローチャート。
【図3】起動時間設定制御の実行タイミングを示す説明図。
【図4】起動時間設定制御の実行タイミングを示す説明図。
【符号の説明】
10…A/D変換器制御装置、12…制御IC、14…制御部としての制御CPU、16…PWM信号出力回路、18…データ受渡用RAM、24…リニアソレノイド、26…電流検出用抵抗、28…A/D変換器、30…フィードバック演算部、32…平均値算出部、34…割込時間設定部、A…変換周期、Tp…現在時刻、WS…割込信号。
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a control device for an A / D converter that converts an analog signal into a digital signal.
[0002]
[Prior art]
Conventionally, electromagnetic valves and electromagnetic actuators have been provided with, for example, a linear solenoid as a power source, and when adjusting the opening of the electromagnetic valve and the displacement amount of the actuator, the displacement amount is detected, Feedback control is performed so that the detected displacement amount becomes the target displacement amount. Since this amount of displacement can be detected based on the value of the current flowing through the linear solenoid, feedback control is performed so that the energized current value of the linear solenoid is detected and the energized current value becomes the target current value corresponding to the target displacement amount. Is to be done.
[0003]
As a technique for performing feedback control of the current flowing through such an inductive load, for example, a control device disclosed in Patent Document 1 has been proposed. This control device is a linear solenoid control device incorporated in an electromagnetic valve mounted on an automobile. In this linear solenoid control device, for example, the control CPU is for duty-driving the linear solenoid based on a deviation between a target current value input from the host CPU and an actual current value (detected current value) actually flowing to the linear solenoid. A feedback calculation for calculating the duty ratio is executed. The PWM signal output circuit outputs a PWM signal corresponding to the duty ratio calculated by the control CPU at a predetermined constant period, thereby energizing the linear solenoid by driving the switching element with a duty. The voltage across the current detection resistor provided in the energization path of the linear solenoid is A / D converted by an A / D converter, and A / D data is delivered as a detected current value representing the current flowing through the linear solenoid. Is input to the RAM. The control CPU activates the A / D converter every cycle shorter than a certain cycle of the PWM signal output from the PWM signal output circuit. Then, the control CPU fetches a plurality of detected current values for m cycle time (m is an integer) of the PWM signal from the A / D data delivery RAM, and arithmetically averages the fetched detected current values to obtain m cycles. Calculate the average current value over time. Thereafter, the control CPU performs a feedback calculation based on the average current value and the target current value every predetermined period longer than the constant period of the PWM signal, and calculates the duty ratio for the PWM signal. Then, the latest duty ratio calculated in this way is reflected in each output cycle of the PWM signal output circuit, a PWM signal corresponding to the duty ratio is output, and the linear solenoid is energized and driven.
[0004]
[Patent Document 1]
Japanese Patent Laid-Open No. 11-308107
[Problems to be solved by the invention]
In the control method of Patent Document 1, in order to improve the control accuracy of the linear solenoid, it is necessary to obtain an accurate average current value. For this purpose, the A / D conversion cycle of the detected current value is made uniform. That is, it is necessary to make the start cycle of the A / D converter by the control CPU uniform. The control CPU captures the A / D converted detected current value into the A / D data delivery RAM based on the interrupt signal output from the A / D converter upon completion of the A / D conversion, and An A / D interrupt process such as an average current value calculation process based on a plurality of detected current values is executed. After the A / D interrupt process, the control CPU sets the next activation time of the A / D converter by adding the A / D conversion cycle time to the previous activation time. Here, it is assumed that the control CPU executes interrupt control with high priority other than the control of the linear solenoid. Then, for example, when an interrupt for other high priority interrupt control occurs during execution of the A / D interrupt process by the control CPU, the control CPU interrupts the A / D interrupt process halfway. . Then, the control CPU executes the interrupt process with the high priority, then re-executes the interrupted A / D interrupt process, and when it completes, sets the start time of the A / D converter . For this reason, when another interrupt process with a higher priority occurs in this way, the setting time of the start time of the A / D converter is delayed toward the end of the A / D conversion cycle. Since a predetermined time is also required for setting the start time of the A / D converter, even if the start time setting start time is earlier than the end time of the A / D conversion cycle, the setting end is completed. The timing may be later than the end timing of the A / D conversion cycle. In this case, the control CPU cannot activate A / D conversion at the next A / D conversion activation time, and cannot detect a detected current value for one A / D conversion period. As a result, there is a problem that an accurate average current value cannot be obtained and the control accuracy of the linear solenoid is lowered.
[0006]
The present invention has been made in view of these problems, and an object of the present invention is to provide an A / D converter control device capable of starting an A / D converter at a predetermined period.
[0007]
[Means for Solving the Problems]
In the following, means for achieving the above object and its effects are described.
According to the first aspect of the present invention, an A / D converter that takes in an input signal and converts it into a digital value, and when the conversion of the A / D converter is completed, the A / D converter is activated at the previous activation time. A controller for starting the A / D converter when the set start time is reached and adding the predetermined conversion cycle time to the next start time; In the A / D converter control apparatus in which the A / D converter is caused to perform A / D conversion at a predetermined conversion cycle, the control unit is configured to execute the setting process when the start time of the setting process is a time after the next activation time. The A / D converter is forcibly activated.
[0008]
In the A / D converter control device, even if an interrupt occurs upon completion of conversion of the A / D converter, if another higher priority interrupt process occurs, the higher priority interrupt process is executed. After that, the startup time setting process is executed. For this reason, when another interrupt process with a higher priority occurs in this way, the setting time of the activation time is delayed toward the end of the conversion period of the A / D conversion. If the start time of this setting process is after the next start time, the A / D converter cannot be started at the next start time, and the detected current value of A / D conversion is lost. Will be.
[0009]
According to this configuration, the A / D converter is forcibly activated when the start time of the activation time setting process upon completion of conversion of the A / D converter is a time after the next activation time. For this reason, the A / D converter can be continuously activated at substantially a predetermined conversion cycle, and the detection current value of A / D conversion can be eliminated.
[0010]
According to a second aspect of the present invention, in the A / D converter control device according to the first aspect, the control unit is configured to start the setting process at a time within a predetermined time before the next activation time. In some cases, the A / D converter is forcibly activated.
[0011]
Since a predetermined time is also required for the setting process of the start time of the A / D converter, even if the start time of the start time setting process is a time before the end time of the conversion cycle, the setting process ends. The time may be later than the end time of the conversion cycle. Also in this case, the A / D converter cannot be started at the next starting time, and the detection current value of A / D conversion is lost.
[0012]
According to this configuration, when the start time of the start time setting process upon completion of conversion of the A / D converter is within a predetermined time before the next start time, the A / D converter is forcibly forced. Start. For this reason, the A / D converter can be continuously activated at substantially a predetermined conversion cycle, and the detection current value of A / D conversion can be eliminated.
[0013]
As in the third aspect of the invention, the predetermined time may include at least the time required for the start time setting process.
According to a fourth aspect of the present invention, in the A / D converter control device according to any one of the first to third aspects, the control unit is configured to perform a forcible activation of the A / D converter continuously a predetermined number of times or more. When performed, the present time is set as the previous activation time.
[0014]
According to this configuration, when the A / D converter is forcibly activated continuously for a predetermined number of times or more, the conversion cycle of the A / D conversion may deviate greatly from the original conversion cycle. According to this configuration, when the A / D converter is forcibly activated continuously for a predetermined number of times or more, the current time is set as the previous activation time. It becomes possible to make a period.
[0015]
DETAILED DESCRIPTION OF THE INVENTION
DESCRIPTION OF EXEMPLARY EMBODIMENTS Hereinafter, an embodiment of the invention will be described with reference to the drawings.
FIG. 1 is a block diagram showing the configuration of an A / D converter control device 10 to which the present invention is applied.
[0016]
The A / D converter control device 10 of the present embodiment controls energization of the linear solenoid 24 provided in the engine and controls the A / D converter 28 in order to control the engine mounted on the automobile to the target state. Controls such as start-up control and engine fuel injection control and ignition control are also performed.
[0017]
The A / D converter control device 10 is provided with a control IC 12. The control IC 12 feedback-controls the current flowing through the linear solenoid 24 in accordance with data (target current value) representing the current to flow through the linear solenoid 24 calculated by, for example, the transmission control CPU.
[0018]
The control IC 12 includes a control CPU 14, a PWM signal output circuit 16, and a data delivery RAM 18. The control CPU 14 calculates a duty ratio as a control command value for duty driving the linear solenoid 24 with a PWM signal, and outputs the detection result to the PWM signal output circuit 16 as PWM data (drive data).
[0019]
The PWM signal output circuit 16 reads PWM data for the linear solenoid 24 from the control CPU 14, and generates a PWM signal SG1 as a control signal for duty driving the linear solenoid 24.
[0020]
On the other hand, the linear solenoid 24 to be controlled is disposed in a power supply line from the positive electrode (power supply voltage Vb) of the battery to the negative electrode (ground) of the battery. On the power supply line side of the linear solenoid 24 in the power supply line, an FET 22 as switching means is provided. The PWM signal SG1 is input to the gate terminal of the FET 22. When the PWM signal SG1 is at the H level, the FET 22 is turned on, and the energization path from the battery to the linear solenoid 24 is energized. Conversely, when the PWM signal SG1 is at the L level, the FET 22 is turned off, and the energization path of the linear solenoid 24 is interrupted.
[0021]
Further, a current detection resistor 26 is provided as a detection means on the ground side of the linear solenoid 24. That is, a linear solenoid 24 as an inductive load and an FET 22 as a switching element are connected in series in a power supply line that generates a predetermined potential difference, and a current detection resistor 26 is connected in series to this series circuit. This resistor 26 is for detecting the current flowing through the linear solenoid 24.
[0022]
Both ends of the current detection resistor 26 are connected to an A / D converter (A / D conversion means) 28. The A / D converter 28 is activated based on the activation signal KS output from the control CPU 14 at a constant A / D conversion cycle. Each time the A / D converter 28 is activated by the control CPU 14, the A / D converter 28 sequentially takes in a current detection signal (voltage) representing the current flowing through the linear solenoid 24 and converts it into a digital value. An interrupt signal WS is output to the CPU 14.
[0023]
The control CPU 14 executes A / D interrupt processing based on the interrupt signal WS input from the A / D converter 28. In this A / D interrupt process, the digital value converted by the A / D converter 28 is sequentially stored in the data delivery RAM 18 and corresponds to one cycle time of the PWM signal SG1 stored in the data delivery RAM 18. The average value of the energizing current flowing through the linear solenoid 24 is calculated by averaging the digital values to be calculated. Further, the control CPU 14 performs setting processing for the next activation time of the A / D converter 28 after the calculation processing of the average current value. Further, the control CPU 14 forcibly starts the A / D converter 28 when the current time Tp is equal to or greater than the next delay trigger set time Tn.
[0024]
Next, the operation of the A / D converter control device 10 will be described.
As shown in FIG. 1, the functional configuration of the control CPU 14 includes a feedback (hereinafter referred to as F / B) calculation unit 30, an average value calculation unit 32, and an interrupt time setting unit 34.
[0025]
The average value calculation unit 32 sequentially stores the digital value converted by the A / D converter 28 in the data delivery RAM 18 based on the interrupt signal WS accompanying the completion of the A / D conversion of the A / D converter 28. . The average value calculation unit 32 calculates an average current value flowing through the linear solenoid 24 by averaging digital values corresponding to one cycle time of the PWM signal SG1 stored in the data delivery RAM 18.
[0026]
The F / B calculation unit 30 inputs the target current value of the linear solenoid 24 and the average current value calculated by the average value calculation unit 32, and energizes the linear solenoid 24 based on the target current value and the average current value. A duty ratio for controlling the current to be a target current value is calculated.
[0027]
The interrupt time setting unit 34 sets the next activation timing of the A / D converter 28 after the average current value is calculated by the average value calculation unit 32.
Regarding the interrupt time setting process in the interrupt time setting unit 34, more specifically, as shown in FIG. 2, the control CPU 14 captures the current time Tp in step 110.
[0028]
In the next step 120, the control CPU 14 updates the next delay trigger setting time Tn by adding the A / D conversion period A to the previous delay trigger setting time To.
[0029]
Thereafter, in step 130, the control CPU 14 determines whether or not the current time Tp is greater than the previous (n times) delay trigger set time To. If it is determined that the current time Tp is less than or equal to the previous delay trigger setting time To (step 130: NO), the process proceeds to step 200.
[0030]
On the other hand, if it is determined that the current time Tp is greater than the previous delay trigger setting time To (step 130: YES), the process proceeds to step 140. In step 140, the control CPU 14 determines whether or not the current time Tp is smaller than the next (n + 1) delay trigger set time Tn. If it is determined that the current time Tp is equal to or greater than the next delay trigger setting time Tn (step 140: NO), the process proceeds to step 200.
[0031]
On the other hand, if it is determined that the current time Tp is smaller than the next delay trigger setting time Tn (step 140: YES), the process proceeds to step 150.
In step 150, the control CPU 14 sets Tn as the next delay trigger setting time Tr. Next, in step 160, the control CPU 14 sets the forced activation count M to 0, and in the subsequent step 170, updates the previous delay trigger setting time To to Tn.
[0032]
In step 180, when the time elapses and the delay trigger setting time Tr set in step 150 is reached, the control CPU 14 outputs a delay trigger to activate the A / D converter 28.
[0033]
If NO is determined in step 130 or NO in step 140, the conversion cycle is considered to be deviated from the original A / D conversion cycle. The converter 28 is forcibly activated. In step 210, the control CPU 14 increments the forced activation count M.
[0034]
In step 220 following step 210, the control CPU 14 determines whether or not the number of forced activations M is greater than 3. If it is determined that the number of forced activations M is 3 or less (step 220: NO), the process proceeds to step 230. If it is determined that the number of forced activations M is greater than 3 (step 220: YES), the process is stepped. Proceed to 240.
[0035]
In step 230, the control CPU 14 updates the previous delay trigger setting time To to Tn.
In step 240, the previous delay trigger setting time To is updated to the current time Tp.
[0036]
FIG. 3 and FIG. 4 schematically illustrate the processing of FIG. As shown in FIG. 3, in the output cycle of the PWM signal SG1 of the PWM signal output circuit 16, the A / D converter 28 is activated at a predetermined A / D conversion cycle.
[0037]
The details are shown in FIG. If the time when the interrupt signal WS input upon completion of the conversion of the A / D converter 28 is smaller than the next delay trigger setting time Tr, the next delay trigger setting time Tr is in relation to the previous delay trigger setting time To. A value obtained by adding the conversion period A is set. When the time has elapsed and the set activation time is reached, the A / D converter 28 is activated and A / D conversion of the energization current of the linear solenoid 24 is executed.
[0038]
Further, as indicated by a chain line in FIG. 4, if the time when the interrupt signal WS input upon completion of conversion of the A / D converter 28 is equal to or greater than the next delay trigger setting time Tr, the control CPU 14 performs A / D The converter 28 is forcibly activated to execute A / D conversion of the energization current of the linear solenoid 24. At this time, the previous delay trigger setting time To is updated to Tn.
[0039]
Now, this embodiment has the following effects.
The control CPU 14 forcibly activates the A / D converter when the start time of the start time setting process of the A / D converter 28 upon completion of the conversion of the A / D converter 28 is a time after the next start time. I try to start it. For this reason, the A / D converter 28 can be continuously activated substantially at a predetermined conversion period A, and the detection current value of A / D conversion can be eliminated.
[0040]
The control CPU 14 forcibly activates the A / D converter 28 when the start time of the start time setting process upon completion of conversion of the A / D converter 28 is within a predetermined time before the next start time. Start. For this reason, the A / D converter 28 can be continuously activated with a substantially predetermined conversion period, and the detection current value of the A / D conversion can be omitted.
[0041]
The control CPU 14 sets the current conversion time of the A / D conversion as the original conversion cycle because the current time is set as the previous activation time when the A / D converter 28 is continuously activated for a predetermined number of times or more. To be able to.
[0042]
The embodiment may be changed as follows.
In the above embodiment, when the A / D converter 28 is forcibly activated three or more times in succession, the current time is set as the previous activation time. It may be set.
[0043]
In the above-described embodiment, the feedback control device for the linear solenoid 24 is embodied. However, the present invention is not limited to this, and the embodiment is embodied to perform feedback control so that the operation state of the control target is detected and the target value is obtained. Can do.
[0044]
Next, other technical ideas that can be grasped from the above embodiments will be described below.
・ With the completion of conversion of the A / D converter that takes in analog input signals and converts them to digital values, a predetermined conversion cycle time is added to the previous start time of the A / D converter to set the next start time Then, the A / D converter is activated at a predetermined conversion cycle by activating the A / D converter when the set activation time is reached. In the converter control method, the A / D converter is forcibly started when the start time of the next start time setting process is a time after the next start time. D converter control method.
[Brief description of the drawings]
FIG. 1 is a functional block diagram showing a configuration of an A / D converter control device to which the present invention is applied.
FIG. 2 is a flowchart showing start-up time setting control executed by the control device.
FIG. 3 is an explanatory diagram showing execution timing of startup time setting control.
FIG. 4 is an explanatory diagram showing execution timing of startup time setting control.
[Explanation of symbols]
DESCRIPTION OF SYMBOLS 10 ... A / D converter control apparatus, 12 ... Control IC, 14 ... Control CPU as a control part, 16 ... PWM signal output circuit, 18 ... RAM for data delivery, 24 ... Linear solenoid, 26 ... Resistance for electric current detection, 28 ... A / D converter, 30 ... feedback calculation unit, 32 ... average value calculation unit, 34 ... interrupt time setting unit, A ... conversion cycle, Tp ... current time, WS ... interrupt signal.

Claims (4)

入力信号を取り込んでデジタル値に変換するA/D変換器と、
前記A/D変換器の変換完了に伴い、前記A/D変換器の前回の起動時刻に所定の変換周期時間を加算して次回の起動時刻の設定処理を行うとともに、その設定された起動時刻となった時に前記A/D変換器を起動させる制御部とを備え、前記A/D変換器に所定の変換周期にてA/D変換を行わせるようにしたA/D変換器制御装置において、
前記制御部は、前記設定処理の開始時刻が次回の起動時刻以降の時間であるときには前記A/D変換器を強制的に起動させる
ことを特徴とするA/D変換器制御装置。
An A / D converter that takes an input signal and converts it into a digital value;
Upon completion of the conversion of the A / D converter, a predetermined conversion cycle time is added to the previous activation time of the A / D converter to perform the next activation time setting process, and the set activation time A controller that activates the A / D converter when the A / D converter is reached, and causes the A / D converter to perform A / D conversion at a predetermined conversion cycle. ,
The control unit forcibly starts the A / D converter when the start time of the setting process is a time after the next start time.
請求項1に記載のA/D変換器制御装置において、
前記制御部は、前記設定処理の開始時刻が次回の起動時刻よりも前の所定時間以内の時刻であるときには前記A/D変換器を強制的に起動させる
ことを特徴とするA/D変換器制御装置。
The A / D converter control device according to claim 1,
The control unit forcibly activates the A / D converter when a start time of the setting process is within a predetermined time before a next activation time Control device.
請求項2に記載のA/D変換器制御装置において、
前記所定時間は、少なくとも前記設定処理に要する時間を含むことを特徴とするA/D変換器制御装置。
The A / D converter control device according to claim 2,
The A / D converter control device, wherein the predetermined time includes at least a time required for the setting process.
請求項1〜3のいずれかに記載のA/D変換器制御装置において、
前記制御部は、前記A/D変換器の強制起動が連続して所定回数以上行われたときには、前回の起動時期として現在時刻を設定する
ことを特徴とするA/D変換器制御装置。
In the A / D converter control device according to any one of claims 1 to 3,
The A / D converter control device, wherein the controller sets the current time as the previous activation timing when the A / D converter is continuously activated for a predetermined number of times or more.
JP2002354837A 2002-12-06 2002-12-06 A / D converter controller Expired - Fee Related JP3901082B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2002354837A JP3901082B2 (en) 2002-12-06 2002-12-06 A / D converter controller

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2002354837A JP3901082B2 (en) 2002-12-06 2002-12-06 A / D converter controller

Publications (2)

Publication Number Publication Date
JP2004187207A JP2004187207A (en) 2004-07-02
JP3901082B2 true JP3901082B2 (en) 2007-04-04

Family

ID=32755702

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2002354837A Expired - Fee Related JP3901082B2 (en) 2002-12-06 2002-12-06 A / D converter controller

Country Status (1)

Country Link
JP (1) JP3901082B2 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6079620B2 (en) * 2013-12-27 2017-02-15 株式会社デンソー Solenoid valve control device
JP6354671B2 (en) * 2015-06-10 2018-07-11 株式会社デンソー Electronic control unit
JP6471649B2 (en) * 2015-08-25 2019-02-20 株式会社デンソー Electronic control unit
JP6632488B2 (en) * 2016-07-20 2020-01-22 株式会社デンソーテン CONTROL DEVICE AND AD CONVERSION CONTROL METHOD

Also Published As

Publication number Publication date
JP2004187207A (en) 2004-07-02

Similar Documents

Publication Publication Date Title
JP5029663B2 (en) Fuel injection control device
CN107532535B (en) Control device
KR101597660B1 (en) Method and device for learning the rest position of the gas pedal of a motor vehicle
JP2010255444A (en) Device and method for fuel injection control of internal combustion engine
US9322410B2 (en) Electric pump device
JP3901082B2 (en) A / D converter controller
JP2011064196A (en) Operation method by pulse width modulation of heating element in automobile and glow plug controller for performing the method
JPH04276156A (en) Method and device for inspecting measurement of automobile
JP2007166892A (en) Method and device for deciding rotational speed of electric machine
JP4878118B2 (en) Method for closed-loop control of current through an electromagnetic actuator
JP4127039B2 (en) Feedback control device
JPH11117795A (en) Method and device for controlling load
JP2009250182A (en) Heating element control device
US10270373B2 (en) Method for controlling the current of an inductive load
WO2007115439A1 (en) Driving controlling method and apparatus for electromagnetic fuel pump nozzle
JP5900369B2 (en) Solenoid valve drive
JP2013137028A (en) Device and method for fuel injection control of internal combustion engine
JP2010206247A (en) Induction load controller
JP3632096B2 (en) Solenoid drive
JP5886685B2 (en) Fuel supply control device for internal combustion engine
JP5849994B2 (en) Actuator drive
JP5648622B2 (en) Solenoid valve drive device for fuel injection control device
JP4980457B2 (en) Electronic throttle valve control device
JP2007524338A (en) Electric motor control device especially for powered vehicles
KR102462269B1 (en) Apparatus and method for diagnosing over current of peak and hold injector driver

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20050426

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20061127

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20061225

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

Free format text: PAYMENT UNTIL: 20110112

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20110112

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20120112

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20130112

Year of fee payment: 6

LAPS Cancellation because of no payment of annual fees