JP6135539B2 - Electronic control unit - Google Patents

Electronic control unit Download PDF

Info

Publication number
JP6135539B2
JP6135539B2 JP2014025529A JP2014025529A JP6135539B2 JP 6135539 B2 JP6135539 B2 JP 6135539B2 JP 2014025529 A JP2014025529 A JP 2014025529A JP 2014025529 A JP2014025529 A JP 2014025529A JP 6135539 B2 JP6135539 B2 JP 6135539B2
Authority
JP
Japan
Prior art keywords
measurement
timer
voltage
clocks
value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2014025529A
Other languages
Japanese (ja)
Other versions
JP2015154191A (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.)
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 JP2014025529A priority Critical patent/JP6135539B2/en
Priority to DE102015202271.4A priority patent/DE102015202271A1/en
Publication of JP2015154191A publication Critical patent/JP2015154191A/en
Application granted granted Critical
Publication of JP6135539B2 publication Critical patent/JP6135539B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03LAUTOMATIC CONTROL, STARTING, SYNCHRONISATION OR STABILISATION OF GENERATORS OF ELECTRONIC OSCILLATIONS OR PULSES
    • H03L1/00Stabilisation of generator output against variations of physical values, e.g. power supply
    • H03L1/02Stabilisation of generator output against variations of physical values, e.g. power supply against variations of temperature only
    • H03L1/022Stabilisation of generator output against variations of physical values, e.g. power supply against variations of temperature only by indirect stabilisation, i.e. by generating an electrical correction signal which is a function of the temperature
    • H03L1/026Stabilisation of generator output against variations of physical values, e.g. power supply against variations of temperature only by indirect stabilisation, i.e. by generating an electrical correction signal which is a function of the temperature by using a memory for digitally storing correction values
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03LAUTOMATIC CONTROL, STARTING, SYNCHRONISATION OR STABILISATION OF GENERATORS OF ELECTRONIC OSCILLATIONS OR PULSES
    • H03L1/00Stabilisation of generator output against variations of physical values, e.g. power supply

Landscapes

  • Stabilization Of Oscillater, Synchronisation, Frequency Synthesizers (AREA)
  • Oscillators With Electromechanical Resonators (AREA)

Description

本発明は、複数の発振回路を備えた電子制御装置に関する。   The present invention relates to an electronic control device including a plurality of oscillation circuits.

従来より、例えばマイクロコンピュータと集積回路とのそれぞれが発振回路を備えることで、複数の発振回路を備えた電子制御装置(ECU:Electronic Control Unit)が供されている。発振回路としてのコンデンサと抵抗を用いたCR発振回路は、水晶発振子を用いる場合と比べて低コストで実現できるという利点があるが、温度や電圧の変動に対して基準発振周波数の精度が貧弱であるという問題がある。この点に対し、例えば特許文献1には、工場での製造時に基準発振周波数の温度特性や電圧特性を不揮発性メモリに記憶させておく技術が開示されている。特許文献1によれば、不揮発性メモリに記憶されている温度特性や電圧特性を使用時に参照することで、温度や電圧の変動による基準発振周波数のずれに対して適切に対処することができる。   2. Description of the Related Art Conventionally, for example, each of a microcomputer and an integrated circuit includes an oscillation circuit, so that an electronic control unit (ECU) including a plurality of oscillation circuits is provided. The CR oscillation circuit using a capacitor and resistor as an oscillation circuit has the advantage of being able to be realized at a lower cost than the case of using a crystal oscillator, but the accuracy of the reference oscillation frequency is poor with respect to temperature and voltage fluctuations. There is a problem that. On the other hand, for example, Patent Document 1 discloses a technique for storing temperature characteristics and voltage characteristics of a reference oscillation frequency in a non-volatile memory at the time of manufacturing in a factory. According to Patent Document 1, it is possible to appropriately cope with a deviation in the reference oscillation frequency due to temperature and voltage fluctuations by referring to temperature characteristics and voltage characteristics stored in a nonvolatile memory at the time of use.

特開平5−75445号公報Japanese Patent Laid-Open No. 5-75445

しかしながら、特許文献1では、工場での製造時に基準発振周波数の温度特性や電圧特性を不揮発性メモリに記憶させておく必要があるので、工程の増加やコスト高を招くという問題がある。又、CR発振回路は、経年変化により基準発振周波数のずれが発生する可能性もあるが、特許文献1では、経年変化による基準発振周波数のずれが考慮されていない。そのため、経年変化による基準発振周波数のずれが発生すると、不揮発性メモリに記憶されている温度特性や電圧特性を参照したとしても、温度や電圧の変動による基準発振周波数のずれに対して適切に対処することができない虞もある。   However, in Patent Document 1, it is necessary to store the temperature characteristics and voltage characteristics of the reference oscillation frequency in the nonvolatile memory at the time of manufacture at the factory, which causes a problem of increasing the number of processes and increasing the cost. Further, in the CR oscillation circuit, there is a possibility that the reference oscillation frequency shifts due to aging. However, Patent Document 1 does not consider the reference oscillation frequency shift due to aging. For this reason, when a deviation of the reference oscillation frequency due to aging occurs, even if the temperature characteristics and voltage characteristics stored in the non-volatile memory are referenced, the deviation of the reference oscillation frequency due to temperature and voltage fluctuations can be dealt with appropriately. There is a possibility that it cannot be done.

本発明は、上記した事情に鑑みてなされたものであり、その目的は、工場での製造時での工程の増加やコスト高を招くことなく、経年変化による基準発振周波数のずれが発生した場合でも、温度や電圧の変動に対して適切に対処することができる電子制御装置を提供することにある。   The present invention has been made in view of the above-described circumstances, and its purpose is when a shift in the reference oscillation frequency due to secular change occurs without causing an increase in process and cost in manufacturing at a factory. However, an object of the present invention is to provide an electronic control device that can appropriately cope with temperature and voltage fluctuations.

請求項1に記載した発明によれば、第1の計測手段は、第1の発振回路から出力される第1のクロック信号のクロック数を計測する。第2の計測手段は、第2の発振回路から出力される第2のクロック信号のクロック数を計測する。計測制御手段は、第1のクロック信号及び第2のクロック信号のそれぞれのクロック数の計測を同時に開始させて所定の計測期間の経過後に同時に終了させる。差分演算手段は、クロック数の計測が同時に終了された時点での当該クロック数の差分を示す指標を演算する。記憶制御手段は、その演算された指標と、クロック数の計測が同時に終了された時点での第2の発振回路の温度及び第2の発振回路に印加される電圧のうち少なくとも一方の物理量との対応を記憶手段に記憶させる。記憶制御手段は、計測期間内での物理量の変動幅が所定値未満である場合に、指標と物理量との対応を記憶手段に記憶させ、計測期間内での物理量の変動幅が所定値以上である場合に、指標と物理量との対応の記憶手段への記憶を禁止する。
According to the first aspect of the present invention, the first measuring unit measures the number of clocks of the first clock signal output from the first oscillation circuit. The second measuring means measures the number of clocks of the second clock signal output from the second oscillation circuit. The measurement control means starts the measurement of the number of clocks of each of the first clock signal and the second clock signal at the same time, and ends them simultaneously after a predetermined measurement period has elapsed. The difference calculating means calculates an index indicating the difference in the number of clocks at the time when the measurement of the number of clocks is simultaneously completed. The storage control means includes the calculated index and at least one physical quantity of the temperature of the second oscillation circuit and the voltage applied to the second oscillation circuit when the measurement of the number of clocks is simultaneously completed. The correspondence is stored in the storage means. The storage control means stores the correspondence between the index and the physical quantity in the storage means when the fluctuation range of the physical quantity in the measurement period is less than the predetermined value, and the fluctuation quantity of the physical quantity in the measurement period is equal to or greater than the predetermined value. In some cases, storage of the correspondence between the index and the physical quantity in the storage unit is prohibited.

第1の発振回路では経年変化による基準発振周波数のずれが発生していないが、第2の発振回路で経年変化による基準発振周波数のずれが発生すると、所定の計測期間内でのクロック数の差分が発生する。この場合、そのクロック数の差分を示す指標を演算し、その演算した指標を用いることで、第2の発振回路から出力されるクロック数を、第1の発振回路から出力されるクロック数に合わせて補正することができる。又、その演算した指標を、クロック数の計測が同時に終了された時点での温度や電圧と対応付けて記憶することで、温度や電圧の変動をも考慮してクロック数を補正することができる。その結果、複数の発振回路を備える構成において、何れかの発振回路で経年変化による基準発振周波数のずれが発生した場合でも、温度や電圧の変動に対して適切に対処することができる。このとき、工場での製造時に基準発振周波数の温度特性や電圧特性を記憶させておく必要はなく、工程の増加やコスト高を招くことはない。   In the first oscillation circuit, the deviation of the reference oscillation frequency due to secular change does not occur, but when the deviation of the reference oscillation frequency due to secular change occurs in the second oscillation circuit, the difference in the number of clocks within a predetermined measurement period. Will occur. In this case, an index indicating the difference in the number of clocks is calculated, and by using the calculated index, the number of clocks output from the second oscillation circuit is matched with the number of clocks output from the first oscillation circuit. Can be corrected. Further, by storing the calculated index in association with the temperature and voltage at the time when the measurement of the number of clocks is simultaneously completed, the number of clocks can be corrected in consideration of temperature and voltage fluctuations. . As a result, in a configuration including a plurality of oscillation circuits, even when a deviation of the reference oscillation frequency due to aging occurs in any of the oscillation circuits, it is possible to appropriately cope with temperature and voltage fluctuations. At this time, it is not necessary to memorize the temperature characteristic and voltage characteristic of the reference oscillation frequency at the time of manufacture in the factory, and there is no increase in the process and cost.

本発明の一実施形態を示す機能ブロック図Functional block diagram showing an embodiment of the present invention フローチャートflowchart 基板温度及び電圧の変動を示す図(その1)Diagram showing fluctuations in substrate temperature and voltage (1) 学習値テーブルを示す図(その1)The figure which shows a learning value table (the 1) 基板温度及び電圧の変動を示す図(その2)Diagram showing fluctuations in substrate temperature and voltage (Part 2) 学習値テーブルを示す図(その2)The figure which shows a learning value table (the 2) 学習値テーブルを示す図(その3)The figure which shows a learning value table (the 3) 学習値テーブルを示す図(その4)The figure which shows a learning value table (the 4)

以下、本発明を、車両に搭載可能な電子制御装置(ECU:Electronic Control Unit)に適用した一実施形態について図面を参照して説明する。電子制御装置1は、例えば車両の駆動源であるエンジンの駆動を制御するエンジンECUであり、周囲温度の変動が激しい環境で使用される装置である。電子制御装置1は、マイクロコンピュータ(マイコン)2と、タイマIC(Integrated Circuit)3(集積回路)と、水晶発振子4と、温度センサ5と、AD変換部6とを有する。   Hereinafter, an embodiment in which the present invention is applied to an electronic control unit (ECU) that can be mounted on a vehicle will be described with reference to the drawings. The electronic control device 1 is, for example, an engine ECU that controls the driving of an engine that is a driving source of a vehicle, and is a device that is used in an environment where the ambient temperature varies greatly. The electronic control device 1 includes a microcomputer 2, a timer IC (Integrated Circuit) 3 (integrated circuit), a crystal oscillator 4, a temperature sensor 5, and an AD conversion unit 6.

マイコン2は、高精度発振回路7(第1の発振回路)を有する。又、マイコン2は、実行する機能に応じて、計測制御部8(計測制御手段)と、計測部9(第1の計測手段)と、差分比率演算部10(差分演算手段)と、温度検出部11(温度検出手段)と、電圧検出部12(電圧検出手段)と、記憶制御部13(記憶制御手段)と、補正部14(補正手段)とを有する。マイコン2は、これら各部8〜14をソフトウェアにより実現している。又、マイコン2は、不揮発性メモリ15(記憶手段)を有する。タイマIC3は、低精度発振回路16(第2の発振回路)を有する。又、タイマIC3は、計測部17(第2の計測手段)をソフトウェアにより実現している。   The microcomputer 2 has a high-precision oscillation circuit 7 (first oscillation circuit). The microcomputer 2 also includes a measurement control unit 8 (measurement control unit), a measurement unit 9 (first measurement unit), a difference ratio calculation unit 10 (difference calculation unit), and temperature detection according to functions to be executed. A unit 11 (temperature detection unit), a voltage detection unit 12 (voltage detection unit), a storage control unit 13 (storage control unit), and a correction unit 14 (correction unit). The microcomputer 2 realizes these units 8 to 14 by software. Further, the microcomputer 2 has a nonvolatile memory 15 (storage means). The timer IC 3 has a low-precision oscillation circuit 16 (second oscillation circuit). The timer IC 3 realizes the measuring unit 17 (second measuring means) by software.

水晶発振子4は、圧電体である水晶の結晶に電圧が加えられると(電界が印加されると)、圧電体が変形して発振信号を出力する(発振する)。マイコン2において、高精度発振回路7は、水晶発振子4から発振信号を入力すると、その入力した発振信号からクロック信号(第1のクロック信号)を生成して計測制御部8及び計測部9に出力する。マイコン2は、高精度発振回路7から出力されるクロック信号を動作クロックとして動作する。高精度発振回路7は、水晶発振子4の発振周波数の精度が高いことから、経年変化による基準発振周波数のずれが極めて小さい性質を有する。   When a voltage is applied to the crystal of the quartz crystal that is a piezoelectric body (when an electric field is applied), the piezoelectric body is deformed and outputs an oscillation signal (oscillates). In the microcomputer 2, when the oscillation signal is input from the crystal oscillator 4, the high-precision oscillation circuit 7 generates a clock signal (first clock signal) from the input oscillation signal and supplies the clock signal to the measurement control unit 8 and the measurement unit 9. Output. The microcomputer 2 operates using the clock signal output from the high precision oscillation circuit 7 as an operation clock. The high-accuracy oscillation circuit 7 has the property that the deviation of the reference oscillation frequency due to secular change is extremely small because the accuracy of the oscillation frequency of the crystal oscillator 4 is high.

計測制御部8は、後述するタイマ差分比率演算処理の開始タイミングになると、開始命令を計測部9、温度検出部11、電圧検出部12及びタイマIC3の計測部17に同時に出力する。又、計測制御部8は、開始命令を出力すると同時に、高精度発振回路7から入力しているクロック信号のクロック数(パルス数)の計測を開始する。そして、計測制御部8は、計測中のクロック数が予め規定されている基準値に達すると、終了命令を計測部9、温度検出部11、電圧検出部12及びタイマIC3の計測部17に同時に出力し、クロック数の計測を終了する。基準値は、工場での製造時に設定される固定値であっても良いし整備士等が例えば使用環境等を考慮して変更可能な可変値であっても良い。   The measurement control unit 8 outputs a start command simultaneously to the measurement unit 9, the temperature detection unit 11, the voltage detection unit 12, and the measurement unit 17 of the timer IC 3 at the start timing of a timer difference ratio calculation process described later. Further, the measurement control unit 8 outputs a start command, and at the same time, starts measuring the number of clocks (number of pulses) of the clock signal input from the high precision oscillation circuit 7. When the number of clocks being measured reaches a predetermined reference value, the measurement control unit 8 sends an end command to the measurement unit 9, the temperature detection unit 11, the voltage detection unit 12, and the measurement unit 17 of the timer IC 3 simultaneously. Output and finish measuring the number of clocks. The reference value may be a fixed value set at the time of manufacture in a factory, or may be a variable value that can be changed by a mechanic or the like in consideration of, for example, the use environment.

計測部9は、計測制御部8から開始命令を入力すると、高精度発振回路7から入力しているクロック信号のクロック数(パルス数)の計測を開始する。そして、計測部9は、クロック数の計測中に計測制御部8から終了命令を入力すると、クロック数の計測を終了し、その計測したクロック数(計測期間内のクロック数)に応じた値をマイコン内のタイマ値として差分比率演算部10に出力する。   When the measurement unit 9 receives a start command from the measurement control unit 8, the measurement unit 9 starts measuring the number of clocks (number of pulses) of the clock signal input from the high-precision oscillation circuit 7. Then, when the measurement unit 9 inputs an end command from the measurement control unit 8 during the measurement of the number of clocks, the measurement unit 9 ends the measurement of the number of clocks and sets a value corresponding to the measured number of clocks (the number of clocks within the measurement period). It outputs to the difference ratio calculation part 10 as a timer value in a microcomputer.

タイマIC3において、低精度発振回路16は、CR発振回路により構成されており、CR発振回路により発振された発振信号からクロック信号(第2クロック信号)を生成して計測部17に出力する。タイマIC3は、低精度発振回路16から出力されるクロック信号を動作クロックとして動作する。低精度発振回路16を構成するCR発振回路は、温度や電圧の変動に対して基準発振周波数の精度が貧弱であり、又、経年変化による基準発振周波数のずれが上記した高精度発振回路7よりも大きい性質を有する。   In the timer IC 3, the low-accuracy oscillation circuit 16 includes a CR oscillation circuit, generates a clock signal (second clock signal) from the oscillation signal oscillated by the CR oscillation circuit, and outputs the clock signal to the measurement unit 17. The timer IC 3 operates using the clock signal output from the low precision oscillation circuit 16 as an operation clock. The CR oscillation circuit constituting the low-accuracy oscillation circuit 16 has poor accuracy of the reference oscillation frequency with respect to temperature and voltage fluctuations, and the deviation of the reference oscillation frequency due to secular change is higher than that of the high-precision oscillation circuit 7 described above. Also has great properties.

計測部17は、計測制御部8から開始命令を入力すると、低精度発振回路16から入力しているクロック信号のクロック数(パルス数)の計測を開始する。そして、計測部17は、クロック数の計測中に計測制御部8から終了命令を入力すると、クロック数の計測を終了し、その計測したクロック数(計測期間内のクロック数)に応じた値をタイマIC内のタイマ値として差分比率演算部10及び補正部14に出力する。   When the measurement unit 17 receives a start command from the measurement control unit 8, the measurement unit 17 starts measuring the number of clocks (number of pulses) of the clock signal input from the low-precision oscillation circuit 16. When the measurement unit 17 inputs an end command from the measurement control unit 8 during the measurement of the number of clocks, the measurement unit 17 ends the measurement of the number of clocks and sets a value corresponding to the measured number of clocks (the number of clocks within the measurement period). The value is output to the difference ratio calculation unit 10 and the correction unit 14 as a timer value in the timer IC.

温度センサ5は、タイマIC3が実装されている基板の温度(基板温度)を低精度発振回路16の温度として検出し、その検出した基板温度を温度検出部11に出力する。温度検出部11は、計測制御部8から開始命令を入力すると、温度センサ5から入力している基板温度の監視を開始する。温度検出部11は、基板温度の監視を開始すると、監視を開始した以降で基板温度が最大値を上回る毎に基板温度の最大値を更新し、最小値を下回る毎に基板温度の最小値を更新する。温度検出部11は、基板温度の監視中に計測制御部8から終了命令を入力すると、温度センサ5から入力している基板温度の監視を終了する。そして、温度検出部11は、開始命令を入力してから終了命令を入力するまでの計測期間内での基板温度の最大値と最小値との差分の絶対値を演算し、その演算した差分の絶対値を予め規定されている所定値と比較する。基板温度の判定基準となる所定値も、上記した基準値と同様に、工場での製造時に設定される固定値であっても良いし整備士等が例えば使用環境等を考慮して変更可能な可変値であっても良い。温度検出部11は、演算した差分の絶対値が所定値未満であれば、監視を終了した時点での基板温度を記憶制御部13に出力する。一方、温度検出部11は、演算した差分の絶対値が所定値以上であれば、監視を終了した時点での基板温度を記憶制御部13に出力しない(出力を禁止する)。   The temperature sensor 5 detects the temperature of the substrate on which the timer IC 3 is mounted (substrate temperature) as the temperature of the low-accuracy oscillation circuit 16 and outputs the detected substrate temperature to the temperature detection unit 11. When the temperature detection unit 11 receives a start command from the measurement control unit 8, the temperature detection unit 11 starts monitoring the substrate temperature input from the temperature sensor 5. When the temperature detection unit 11 starts monitoring the substrate temperature, the temperature detection unit 11 updates the maximum value of the substrate temperature every time the substrate temperature exceeds the maximum value after starting the monitoring, and sets the minimum value of the substrate temperature every time the temperature falls below the minimum value. Update. When the temperature detection unit 11 inputs an end command from the measurement control unit 8 while monitoring the substrate temperature, the temperature detection unit 11 ends the monitoring of the substrate temperature input from the temperature sensor 5. Then, the temperature detection unit 11 calculates the absolute value of the difference between the maximum value and the minimum value of the substrate temperature within the measurement period from the input of the start command to the input of the end command, and the calculated difference The absolute value is compared with a predetermined value defined in advance. The predetermined value that is a criterion for determining the substrate temperature may be a fixed value that is set at the time of manufacture in the factory, as in the case of the above-described reference value. It may be a variable value. If the absolute value of the calculated difference is less than the predetermined value, the temperature detection unit 11 outputs the substrate temperature at the time when the monitoring is finished to the storage control unit 13. On the other hand, if the absolute value of the calculated difference is equal to or greater than a predetermined value, the temperature detection unit 11 does not output the substrate temperature at the time of termination of monitoring to the storage control unit 13 (prohibits output).

AD変換部6は、タイマIC3に印加される電圧(タイマIC3の電源電圧であり、正常時では例えば5[V])を検出し、その検出した電圧を電圧検出部12に出力する。電圧検出部12は、計測制御部8から開始命令を入力すると、AD変換部6から入力している電圧の監視を開始する。電圧検出部12は、電圧の監視を開始すると、監視を開始した以降で電圧が最大値を上回る毎に電圧の最大値を更新し、最小値を下回る毎に電圧の最小値を更新する。電圧検出部12は、電圧の監視中に計測制御部8から終了命令を入力すると、AD変換部6から入力している電圧の監視を終了する。そして、電圧検出部12は、開始命令を入力してから終了命令を入力するまでの計測期間内での電圧の最大値と最小値との差分の絶対値を演算し、その演算した差分の絶対値を予め規定されている所定値と比較する。電圧の判定基準となる所定値も、上記した基準値と同様に、工場での製造時に設定される固定値であっても良いし整備士等が例えば使用環境等を考慮して変更可能な可変値であっても良い。電圧検出部12は、演算した差分の絶対値が所定値未満であれば、監視を終了した時点での電圧を記憶制御部13に出力する。一方、電圧検出部12は、演算した差分の絶対値が所定値以上であれば、監視を終了した時点での電圧を記憶制御部13に出力しない(出力を禁止する)。   The AD conversion unit 6 detects the voltage applied to the timer IC 3 (the power supply voltage of the timer IC 3 and is normally 5 [V], for example), and outputs the detected voltage to the voltage detection unit 12. When the voltage detection unit 12 receives a start command from the measurement control unit 8, the voltage detection unit 12 starts monitoring the voltage input from the AD conversion unit 6. When voltage monitoring starts, the voltage detection unit 12 updates the maximum value of the voltage every time the voltage exceeds the maximum value after starting monitoring, and updates the minimum value of the voltage every time the voltage falls below the minimum value. When the voltage detection unit 12 inputs an end command from the measurement control unit 8 during voltage monitoring, the voltage detection unit 12 ends monitoring of the voltage input from the AD conversion unit 6. The voltage detector 12 calculates the absolute value of the difference between the maximum value and the minimum value of the voltage within the measurement period from the input of the start command to the input of the end command, and the absolute value of the calculated difference The value is compared with a predetermined value defined in advance. Similarly to the above-described reference value, the predetermined value serving as the voltage determination reference may be a fixed value set at the time of manufacturing in the factory, or a variable that can be changed by a mechanic considering the use environment, for example. It may be a value. If the absolute value of the calculated difference is less than the predetermined value, the voltage detection unit 12 outputs the voltage at the time when the monitoring is finished to the storage control unit 13. On the other hand, if the absolute value of the calculated difference is equal to or greater than a predetermined value, the voltage detection unit 12 does not output the voltage at the time when the monitoring is terminated to the storage control unit 13 (prohibits output).

記憶制御部13は、温度検出部11から基板温度を入力し、且つ電圧検出部12から電圧を入力したことを条件とし、演算命令を差分比率演算部10に出力する。
差分比率演算部10は、記憶制御部13から演算命令を入力すると、計測部9から入力しているマイコン内のタイマ値と、計測部17から入力しているタイマIC内のタイマ値とを用い、タイマ差分比率を以下の演算式にしたがって演算する。
タイマ差分比率=マイコン内のタイマ値/タイマIC内のタイマ値
そして、差分比率演算部10は、その演算したタイマ差分比率を記憶制御部13に出力する。
The storage control unit 13 outputs a calculation command to the difference ratio calculation unit 10 on condition that the substrate temperature is input from the temperature detection unit 11 and the voltage is input from the voltage detection unit 12.
When the calculation command is input from the storage control unit 13, the difference ratio calculation unit 10 uses the timer value in the microcomputer input from the measurement unit 9 and the timer value in the timer IC input from the measurement unit 17. The timer difference ratio is calculated according to the following calculation formula.
Timer difference ratio = timer value in the microcomputer / timer value in the timer IC Then, the difference ratio calculation unit 10 outputs the calculated timer difference ratio to the storage control unit 13.

不揮発性メモリ15は、基板温度及び電圧を軸(変数)としてタイマ差分比率を記憶可能な学習値テーブルを保持する。記憶制御部13は、差分比率演算部10からタイマ差分比率を入力すると、その入力したタイマ差分比率を、温度検出部11から入力している基板温度と、電圧検出部12から入力している電圧とに対応付けて不揮発性メモリ15の学習値テーブルに記憶させる。又、記憶制御部13は、不揮発性メモリ15の学習値テーブルに記憶されているタイマ差分比率を読出し、その読出したタイマ差分比率を補正部14に出力する。   The nonvolatile memory 15 holds a learning value table capable of storing a timer difference ratio with the substrate temperature and voltage as axes (variables). When the storage controller 13 receives the timer difference ratio from the difference ratio calculator 10, the storage controller 13 receives the input timer difference ratio from the temperature detector 11 and the voltage input from the voltage detector 12. Are stored in the learning value table of the nonvolatile memory 15 in association with. Further, the storage control unit 13 reads the timer difference ratio stored in the learning value table of the nonvolatile memory 15 and outputs the read timer difference ratio to the correction unit 14.

補正部14は、計測部17からタイマIC内のタイマ値を入力し、記憶制御部13からタイマ差分比率を入力すると、計測部17から入力したタイマIC内のタイマ値を、記憶制御部13から入力したタイマ差分比率を用いて補正する。即ち、補正部14は、補正後のタイマIC内のタイマ値を以下の演算式にしたがって演算する。
補正後のタイマIC内のタイマ値=補正前のタイマIC内のタイマ値×タイマ差分比率
このように構成されている電子制御装置1は、例えば車両のACC(アクセサリ)スイッチに連動して起動状態と停止状態とを切換える。即ち、電子制御装置1は、ACCスイッチのオフからオンへの切換を判定すると、停止状態から起動状態に切換わり、ACCスイッチのオンからオフへの切換を判定すると、起動状態から停止状態に切換わる。
When the correction unit 14 inputs the timer value in the timer IC from the measurement unit 17 and inputs the timer difference ratio from the storage control unit 13, the correction unit 14 converts the timer value in the timer IC input from the measurement unit 17 from the storage control unit 13. Correction is made using the input timer difference ratio. That is, the correction unit 14 calculates the timer value in the timer IC after correction according to the following arithmetic expression.
Timer value in timer IC after correction = Timer value in timer IC before correction × Timer difference ratio The electronic control device 1 configured in this way is activated in conjunction with, for example, an ACC (accessory) switch of a vehicle. And switching between the stopped state. That is, when the electronic control unit 1 determines that the ACC switch is switched from OFF to ON, the electronic control unit 1 switches from the stopped state to the activated state. Change.

次に、上記した構成の作用について、図2から図8も参照して説明する。
マイコン2は、電子制御装置1の起動状態では、本発明に関連するタイマ差分比率演算処理の実行要求が発生すると、タイマ差分比率演算処理を実行する。この場合、マイコン2は、例えば実行要求を所定周期で定期的に発生しても良いし、タイマIC3からの命令を受けて実行要求を発生しても良い。
Next, the operation of the above configuration will be described with reference to FIGS.
In the activated state of the electronic control unit 1, the microcomputer 2 executes the timer difference ratio calculation process when a request for execution of the timer difference ratio calculation process related to the present invention occurs. In this case, the microcomputer 2 may generate an execution request periodically at a predetermined cycle, for example, or may generate an execution request in response to an instruction from the timer IC 3.

マイコン2は、タイマ差分比率演算処理を開始すると、計測制御部8から開始命令を計測部9、温度検出部11、電圧検出部12及びタイマIC3の計測部17に同時に出力する。マイコン2は、自身の高精度発振回路7から出力されているクロック信号の計測を計測部9にて開始し、タイマIC3の低精度発振回路16から出力されているクロック信号の計測を計測部17にて開始させる(S1)。このとき、マイコン2は、温度センサ5から入力している基板温度の監視を温度検出部11にて開始し、AD変換部6から入力している電圧の監視を電圧検出部12にて開始する。これ以降、マイコン2は、基板温度が最大値を上回る毎に基板温度の最大値を更新し、最小値を下回る毎に基板温度の最小値を更新する。又、マイコン2は、電圧が最大値を上回る毎に電圧の最大値を更新し、最小値を下回る毎に電圧の最小値を更新する(S2)。マイコン2は、計測制御部8にて計測中のクロック数が基準値に達したと判定するまで(S3:NO)、基板温度及び電圧の更新を繰返して行う。   When the microcomputer 2 starts the timer difference ratio calculation process, the microcomputer 2 outputs a start command from the measurement control unit 8 to the measurement unit 9, the temperature detection unit 11, the voltage detection unit 12, and the measurement unit 17 of the timer IC 3 simultaneously. The microcomputer 2 starts measuring the clock signal output from its own high-precision oscillation circuit 7 by the measurement unit 9 and measures the clock signal output from the low-precision oscillation circuit 16 of the timer IC 3. (S1). At this time, the microcomputer 2 starts monitoring the substrate temperature input from the temperature sensor 5 at the temperature detection unit 11 and starts monitoring the voltage input from the AD conversion unit 6 at the voltage detection unit 12. . Thereafter, the microcomputer 2 updates the maximum value of the substrate temperature every time the substrate temperature exceeds the maximum value, and updates the minimum value of the substrate temperature every time it falls below the minimum value. The microcomputer 2 updates the maximum voltage every time the voltage exceeds the maximum value, and updates the minimum voltage every time the voltage falls below the minimum value (S2). The microcomputer 2 repeatedly updates the substrate temperature and voltage until it is determined by the measurement control unit 8 that the number of clocks being measured has reached the reference value (S3: NO).

次いで、マイコン2は、計測制御部8にて計測中のクロック数が基準値に達した(所定の計測期間が経過した)と判定すると(S3:YES)、計測制御部8から終了命令を計測部9、温度検出部11、電圧検出部12及びタイマIC3の計測部17に同時に出力する。マイコン2は、自身の高精度発振回路7から出力されているクロック信号の計測を終了し、タイマIC3の低精度発振回路16から出力されているクロック信号の計測を終了させる(S4)。   Next, when the microcomputer 2 determines that the number of clocks being measured by the measurement control unit 8 has reached the reference value (a predetermined measurement period has elapsed) (S3: YES), the microcomputer 2 measures an end command from the measurement control unit 8. Output simultaneously to the unit 9, the temperature detection unit 11, the voltage detection unit 12, and the measurement unit 17 of the timer IC 3. The microcomputer 2 ends the measurement of the clock signal output from its own high-precision oscillation circuit 7 and ends the measurement of the clock signal output from the low-precision oscillation circuit 16 of the timer IC 3 (S4).

次いで、マイコン2は、計測期間内での基板温度の最大値と最小値との差分の絶対値を温度検出部11にて演算し、その演算した差分の絶対値と所定値とを温度検出部11にて比較する(S5)。マイコン2は、演算した差分の絶対値が所定値未満であると判定すると(S5:YES)、監視を終了した時点での基板温度を現在の基板温度として温度検出部11から記憶制御部13に出力する。   Next, the microcomputer 2 calculates the absolute value of the difference between the maximum value and the minimum value of the substrate temperature within the measurement period by the temperature detection unit 11, and calculates the absolute value of the calculated difference and the predetermined value as the temperature detection unit. 11 is compared (S5). When the microcomputer 2 determines that the absolute value of the calculated difference is less than the predetermined value (S5: YES), the substrate temperature at the time when the monitoring is finished is set as the current substrate temperature from the temperature detection unit 11 to the storage control unit 13. Output.

次いで、マイコン2は、計測期間内での電圧の最大値と最小値との差分の絶対値を電圧検出部12にて演算し、その演算した差分の絶対値と所定値とを電圧検出部12にて比較する(S6)。マイコン2は、演算した差分の絶対値が所定値未満であると判定すると(S6:YES)、監視を終了した時点での電圧を現在の電圧として電圧検出部12から記憶制御部13に出力する。   Next, the microcomputer 2 calculates the absolute value of the difference between the maximum value and the minimum value of the voltage within the measurement period by the voltage detection unit 12, and calculates the absolute value of the calculated difference and the predetermined value as the voltage detection unit 12. (S6). When the microcomputer 2 determines that the absolute value of the calculated difference is less than the predetermined value (S6: YES), the voltage at the time when the monitoring is finished is output from the voltage detection unit 12 to the storage control unit 13 as the current voltage. .

次いで、マイコン2は、記憶制御部13から演算命令を差分比率演算部10に出力し、計測部9から入力しているマイコン内のタイマ値と、計測部17から入力しているタイマIC内のタイマ値とを用い、タイマ差分比率を差分比率演算部10にて演算する(S7)。次いで、マイコン2は、現在の基板温度を学習値テーブルにおいて軸検索し(S8)、現在の電圧を学習値テーブルにおいて軸検索する(S9)。そして、マイコン2は、差分比率演算部10にて演算したタイマ差分比率を、現在の基板温度と現在の電圧に対応付けて不揮発性メモリ15の学習値テーブルに記憶させ(S10)、タイマ差分比率演算処理を終了する。尚、マイコン2は、計測期間内での基板温度の最大値と最小値との差分の絶対値が所定値未満でない(所定値以上である)と判定すると(S5:NO)、タイマ差分比率を差分比率演算部10にて演算することなくタイマ差分比率演算処理を終了する。又、マイコン2は、計測期間内での電圧の最大値と最小値との差分の絶対値が所定値未満でない(所定値以上である)と判定すると(S6:NO)、この場合も、タイマ差分比率を差分比率演算部10にて演算することなくタイマ差分比率演算処理を終了する。   Next, the microcomputer 2 outputs a calculation command from the storage control unit 13 to the difference ratio calculation unit 10, the timer value in the microcomputer input from the measurement unit 9, and the timer IC input from the measurement unit 17. The timer difference ratio is calculated by the difference ratio calculation unit 10 using the timer value (S7). Next, the microcomputer 2 searches for the current substrate temperature in the learned value table (S8), and searches for the current voltage in the learned value table (S9). Then, the microcomputer 2 stores the timer difference ratio calculated by the difference ratio calculation unit 10 in the learning value table of the nonvolatile memory 15 in association with the current substrate temperature and the current voltage (S10), and the timer difference ratio. The computation process ends. If the microcomputer 2 determines that the absolute value of the difference between the maximum value and the minimum value of the substrate temperature within the measurement period is not less than the predetermined value (is greater than or equal to the predetermined value) (S5: NO), the timer difference ratio is set. The timer difference ratio calculation process is terminated without calculation by the difference ratio calculation unit 10. If the microcomputer 2 determines that the absolute value of the difference between the maximum value and the minimum value of the voltage within the measurement period is not less than the predetermined value (is greater than or equal to the predetermined value) (S6: NO), in this case also the timer The timer difference ratio calculation process is terminated without calculating the difference ratio by the difference ratio calculation unit 10.

これ以降、マイコン2は、低精度発振回路16から出力されるクロック信号を用いる際には、その時点での基板温度と電圧に対応して不揮発性メモリ15に記憶されているタイマ差分比率を読出す。そして、マイコン2は、計測部17から入力したタイマIC内のタイマ値を、不揮発性メモリ15から読出したタイマ差分比率を用いて補正部14にて補正する。   Thereafter, when using the clock signal output from the low-accuracy oscillation circuit 16, the microcomputer 2 reads the timer difference ratio stored in the nonvolatile memory 15 corresponding to the substrate temperature and voltage at that time. put out. Then, the microcomputer 2 corrects the timer value in the timer IC input from the measurement unit 17 by the correction unit 14 using the timer difference ratio read from the nonvolatile memory 15.

マイコン2は、上記したタイマ差分比率演算処理を実行することで、タイマ差分比率の記憶(更新)を以下のようにして行う。マイコン2は、図3に示すように、例えば計測期間を「600s」とし、その計測期間内での基板温度の変動幅(|Tmax−Tmin|)が所定値(A)未満であり、且つ電圧の変動幅(|Vmax−Vmin|)が所定値(B)未満であるときに、マイコン内のタイマ値を「600s」と計測し、タイマIC内のタイマ値を「630s」と計測すると、タイマ差分比率を以下の演算式にしたがって演算する。
タイマ差分比率=600s/630s≒0.95
The microcomputer 2 performs the above-described timer difference ratio calculation process to store (update) the timer difference ratio as follows. As shown in FIG. 3, the microcomputer 2 sets the measurement period to “600 s”, for example, and the fluctuation range (| T max −T min |) of the substrate temperature within the measurement period is less than a predetermined value (A), When the voltage fluctuation range (| V max −V min |) is less than the predetermined value (B), the timer value in the microcomputer is measured as “600 s”, and the timer value in the timer IC is set to “630 s”. When measured, the timer difference ratio is calculated according to the following calculation formula.
Timer difference ratio = 600 s / 630 s≈0.95

そして、マイコン2は、例えば現在の基板温度を「30℃」と特定し、現在の電圧を「5V」と特定すると、演算したタイマ差分比率である「0.95」を、現在の基板温度である「30℃」と現在の電圧である「5V」に対応付けて不揮発性メモリ15の学習値テーブルに記憶させる。即ち、マイコン2は、図4に示すように、それまでの基板温度が「30℃」、電圧が「5V」であるときのタイマ差分比率である「0.96」を、今回の演算によるタイマ差分比率である「0.95」に更新する。尚、マイコン2は、タイマ差分比率を小数第2位まで演算せずに分数のまま記憶させても良く、「600s/630s」を記憶させても良い。即ち、マイコン2は、タイマ差分比率を小数第2位まで演算せずに分数で記憶させておくことで、タイマIC内のタイマ値を補正する際の誤差を抑制する(精度の低下を回避する)。   For example, if the microcomputer 2 specifies the current substrate temperature as “30 ° C.” and specifies the current voltage as “5 V”, the calculated timer difference ratio “0.95” is set to the current substrate temperature. It is stored in the learning value table of the nonvolatile memory 15 in association with a certain “30 ° C.” and the current voltage “5 V”. That is, as shown in FIG. 4, the microcomputer 2 sets the timer difference ratio “0.96” when the substrate temperature up to that time is “30 ° C.” and the voltage is “5 V” to the timer calculated by this calculation. The difference ratio is updated to “0.95”. The microcomputer 2 may store the timer difference ratio as a fraction without calculating it to the second decimal place, or may store “600 s / 630 s”. That is, the microcomputer 2 stores the fractional ratio of the timer difference ratio without calculating it to the second decimal place, thereby suppressing an error in correcting the timer value in the timer IC (avoiding a decrease in accuracy). ).

補正部14は、計測部17から入力した補正前のタイマIC内のタイマ値を、今回の演算したタイマ差分比率を用いて補正する。即ち、補正部14は、計測部17から入力した補正前のタイマIC内のタイマ値である「630s」に、今回の演算したタイマ差分比率である「600s/630s」を乗算し、補正後のタイマIC内のタイマ値を以下の演算式にしたがって演算する。
補正後のタイマIC内のタイマ値=630s×(600s/630s)=600s
The correction unit 14 corrects the timer value in the timer IC before correction input from the measurement unit 17 by using the timer difference ratio calculated this time. That is, the correction unit 14 multiplies “630 s”, which is the timer value in the timer IC before correction input from the measurement unit 17, by “600 s / 630 s”, which is the timer difference ratio calculated this time. The timer value in the timer IC is calculated according to the following equation.
Timer value in the timer IC after correction = 630 s × (600 s / 630 s) = 600 s

一方、マイコン2は、図5に示すように、計測期間内での電圧の変動幅が所定値未満であるが、基板温度の変動幅が所定値以上であると、タイマ差分比率を演算することはない。即ち、マイコン2は、図6に示すように、それまでの基板温度が「30℃」、電圧が「5V」であるときのタイマ差分比率である「0.96」を更新せずに継続する。尚、マイコン2は、計測期間内での基板温度の変動幅が所定値未満であるが、電圧の変動幅が所定値以上である場合も同様であり、タイマ差分比率を演算することはない。更に、マイコン2は、計測期間内での基板温度の変動幅及び電圧の変動幅の双方がそれぞれの所定値以上である場合も同様であり、タイマ差分比率を演算することはない。   On the other hand, as shown in FIG. 5, the microcomputer 2 calculates a timer difference ratio when the fluctuation range of the voltage within the measurement period is less than the predetermined value but the fluctuation range of the substrate temperature is equal to or larger than the predetermined value. There is no. That is, as shown in FIG. 6, the microcomputer 2 continues without updating the timer difference ratio “0.96” when the substrate temperature up to that point is “30 ° C.” and the voltage is “5 V”. . The microcomputer 2 does not calculate the timer difference ratio when the fluctuation range of the substrate temperature within the measurement period is less than the predetermined value, but the same is true when the fluctuation range of the voltage is greater than or equal to the predetermined value. Further, the microcomputer 2 does not calculate the timer difference ratio when both the fluctuation range of the substrate temperature and the fluctuation range of the voltage within the measurement period are equal to or greater than the respective predetermined values.

以上は、不揮発性メモリ15において、基板温度及び電圧の双方を軸とする学習値テーブルを保持する構成を説明したが、基板温度及び電圧の何れかを軸とする学習値テーブルを保持するようにしても良い。即ち、基板温度の変動は大きいが、電圧の変動が小さい(例えば5[V]で安定している)環境であれば、図7に示すように、基板温度のみを軸とする学習値テーブルを保持しても良い。又、電圧の変動は大きいが、基板温度の変動が小さい(例えば30[℃]で安定している)環境であれば、図8に示すように、電圧のみを軸とする学習値テーブルを保持しても良い。即ち、電子制御装置1が使用される環境に応じて学習値テーブルの軸を決定すれば良い。尚、以上の図3から図8に示した数値は例示である。   In the above, the configuration in which the learning value table having both the substrate temperature and the voltage as the axes is held in the nonvolatile memory 15 is described. However, the learning value table having either the substrate temperature or the voltage as the axes is held. May be. That is, in an environment where the substrate temperature varies greatly but the voltage variation is small (for example, stable at 5 [V]), as shown in FIG. May be held. Also, in an environment where the fluctuation of the voltage is large but the fluctuation of the substrate temperature is small (eg, stable at 30 [° C.]), a learning value table with only the voltage as an axis is held as shown in FIG. You may do it. That is, the learning value table axis may be determined according to the environment in which the electronic control unit 1 is used. The numerical values shown in FIGS. 3 to 8 are examples.

以上に説明したように本実施形態によれば、電子制御装置1において、高精度発振回路7から出力されるクロック数の計測と低精度発振回路16から出力されるクロック数の計測とを同時に開始して所定の計測期間後に同時に終了する。そして、計測期間内でのクロック数の差分を示す差分比率を演算し、その演算した差分を、クロック数の計測が同時に終了された時点での基板温度や電圧と対応付けて学習値テーブルに記憶するようにした。これにより、低精度発振回路16で経年変化による基準発振周波数のずれが発生した場合でも、基板温度や電圧の変動に対して適切に対処することができる。このとき、工場での製造時に基準発振周波数の温度特性や電圧特性を記憶させておく必要はなく、工程の増加やコスト高を招くことはない。   As described above, according to the present embodiment, in the electronic control unit 1, measurement of the number of clocks output from the high-precision oscillation circuit 7 and measurement of the number of clocks output from the low-precision oscillation circuit 16 are started simultaneously. Then, it ends simultaneously after a predetermined measurement period. Then, the difference ratio indicating the difference in the number of clocks within the measurement period is calculated, and the calculated difference is stored in the learning value table in association with the substrate temperature and voltage at the time when the measurement of the clock number is simultaneously completed. I tried to do it. Thereby, even when the deviation of the reference oscillation frequency due to aging occurs in the low-accuracy oscillation circuit 16, it is possible to appropriately cope with fluctuations in the substrate temperature and voltage. At this time, it is not necessary to memorize the temperature characteristic and voltage characteristic of the reference oscillation frequency at the time of manufacture in the factory, and there is no increase in the process and cost.

又、補正前のタイマIC内のタイマ値を、タイマ差分比率を用いて補正するようにした。これにより、経年変化による基準発振周波数のずれの影響を速やかに解消することができる。   In addition, the timer value in the timer IC before correction is corrected using the timer difference ratio. Thereby, the influence of the deviation of the reference oscillation frequency due to the secular change can be quickly eliminated.

又、計測期間内での基板温度の変動幅が所定値未満であり、且つ電圧の変動幅が所定値未満である場合に、タイマ差分比率を演算して記憶し、基板温度の変動幅が所定値以上である、又は電圧の変動幅が所定値以上である場合に、タイマ差分比率を演算しないようにした。これにより、変動幅が所定値以上である場合には誤学習の可能性が高いので、誤学習の可能性が高いタイマ差分比率を記憶してしまうことを未然に回避し、信頼性を高めることができる。   Further, when the fluctuation range of the substrate temperature within the measurement period is less than the predetermined value and the fluctuation range of the voltage is less than the predetermined value, the timer difference ratio is calculated and stored, and the fluctuation range of the substrate temperature is predetermined. The timer difference ratio is not calculated when the value is equal to or greater than the value or the voltage fluctuation range is equal to or greater than the predetermined value. As a result, since the possibility of mislearning is high when the fluctuation range is greater than or equal to a predetermined value, it is possible to avoid storing a timer difference ratio with a high possibility of mislearning in advance and improve reliability. Can do.

本発明は、上記した実施形態にのみ限定されるものではなく、以下のように変形又は拡張することができる。
水晶発振子を用いることに限らず、経年変化による基準発振周波数のずれが水晶発振子と同程度のセラミック発振子を用いても良い。
クロック数の差分を示す指標として、マイコン内のタイマ値をタイマIC内のタイマ値で除算した値(比率)を演算することに限らず、タイマIC内のタイマ値からマイコン内のタイマ値を減算した値(差分)を演算しても良い。その場合、タイマ差分を以下の演算式にしたがって演算し、
タイマ差分=タイマIC内のタイマ値−マイコン内のタイマ値
補正後のタイマIC内のタイマ値を以下の演算式にしたがって演算しても良い。
The present invention is not limited to the above-described embodiment, and can be modified or expanded as follows.
Not only using a crystal oscillator, but also a ceramic oscillator in which the deviation of the reference oscillation frequency due to secular change is approximately the same as that of the crystal oscillator may be used.
As an index indicating the difference in the number of clocks, the timer value in the microcomputer is subtracted from the timer value in the timer IC as well as calculating the value (ratio) obtained by dividing the timer value in the microcomputer by the timer value in the timer IC. The calculated value (difference) may be calculated. In that case, calculate the timer difference according to the following formula,
Timer difference = timer value in timer IC−timer value in microcomputer The timer value in the timer IC after correction may be calculated according to the following equation.

補正後のタイマIC内のタイマ値=補正前のタイマIC内のタイマ値−タイマ差分
開始命令と終了命令とを区別してクロック数の計測の開始と終了とを制御することに限らず、1つの命令でクロック数の計測の開始と終了とを制御しても良い。即ち、1つの命令でクロック数の計測を終了すると共に次の計測を開始する(再開する)ことで、所定の計測期間の計測を連続的に行っても良い。
Timer value in timer IC after correction = timer value in timer IC before correction−timer difference One is not limited to controlling the start and end of clock number measurement by distinguishing start and end instructions. The start and end of measurement of the number of clocks may be controlled by an instruction. That is, the measurement of a predetermined measurement period may be continuously performed by ending the measurement of the number of clocks with one command and starting (restarting) the next measurement.

タイマ差分比率を演算した後に、計測期間内での基板温度の変動幅や電圧の変動幅をそれぞれの所定値と比較し、条件を満たした場合に、その演算したタイマ差分比率を、現在の基板温度と現在の電圧に対応付けて記憶させても良い。即ち、基板温度の変動幅や電圧の変動幅をそれぞれの所定値と比較した後にタイマ差分比率を演算しても良いし、タイマ差分比率を演算した後に基板温度の変動幅や電圧の変動幅をそれぞれの所定値と比較しても良い。   After calculating the timer difference ratio, compare the substrate temperature fluctuation width and voltage fluctuation width within the measurement period with their respective predetermined values, and if the conditions are met, the calculated timer difference ratio is The temperature may be stored in association with the current voltage. In other words, the timer difference ratio may be calculated after comparing the fluctuation range of the substrate temperature and the fluctuation range of the voltage with the respective predetermined values, or after calculating the timer difference ratio, the fluctuation range of the substrate temperature and the fluctuation range of the voltage are calculated. You may compare with each predetermined value.

図面中、1は電子制御装置、2はマイクロコンピュータ、3はタイマIC(集積回路)、7は高精度発振回路(第1の発振回路)、8は計測制御部(計測制御手段)、9は計測部(第1の計測手段)、10は差分比率演算部(差分演算手段)、11は温度検出部(温度検出手段)、12は電圧検出部(電圧検出手段)、13は記憶制御部(記憶制御手段)、14は補正部(補正手段)、15は不揮発性メモリ(記憶手段)、16は低精度発振回路(第2の発振回路)、17は計測部(第2の計測手段)である。   In the drawings, 1 is an electronic control device, 2 is a microcomputer, 3 is a timer IC (integrated circuit), 7 is a high-precision oscillation circuit (first oscillation circuit), 8 is a measurement control unit (measurement control means), 9 is Measurement unit (first measurement unit), 10 is a difference ratio calculation unit (difference calculation unit), 11 is a temperature detection unit (temperature detection unit), 12 is a voltage detection unit (voltage detection unit), and 13 is a storage control unit ( (Storage control means), 14 is a correction unit (correction means), 15 is a non-volatile memory (storage means), 16 is a low-precision oscillation circuit (second oscillation circuit), and 17 is a measurement unit (second measurement means). is there.

Claims (4)

第1のクロック信号を出力する第1の発振回路(7)と、
第2のクロック信号を出力する第2の発振回路(16)と、
前記第1のクロック信号のクロック数を計測する第1の計測手段(9)と、
前記第2のクロック信号のクロック数を計測する第2の計測手段(17)と、
前記第1のクロック信号及び前記第2のクロック信号のそれぞれのクロック数の計測を同時に開始させて所定の計測期間の経過後に同時に終了させる計測制御手段(8)と、
前記クロック数の計測が同時に終了された時点での当該クロック数の差分を示す指標を演算する差分演算手段(10)と、
前記第2の発振回路の温度を検出する温度検出手段(11)及び前記第2の発振回路に印加される電圧を検出する電圧検出手段(12)のうち少なくとも一方と、
前記指標と、前記クロック数の計測が同時に終了された時点での前記温度検出手段及び前記電圧検出手段のうち少なくとも一方により検出されている物理量との対応を記憶手段(15)に記憶させる記憶制御手段(13)と、を備え
前記記憶制御手段は、前記計測期間内での前記物理量の変動幅が所定値未満である場合に、前記指標と前記物理量との対応を前記記憶手段に記憶させ、前記計測期間内での前記物理量の変動幅が所定値以上である場合に、前記指標と前記物理量との対応の前記記憶手段への記憶を禁止することを特徴とする電子制御装置。
A first oscillation circuit (7) for outputting a first clock signal;
A second oscillation circuit (16) for outputting a second clock signal;
First measuring means (9) for measuring the number of clocks of the first clock signal;
Second measuring means (17) for measuring the number of clocks of the second clock signal;
Measurement control means (8) for simultaneously starting measurement of the number of clocks of each of the first clock signal and the second clock signal and ending simultaneously after a predetermined measurement period has elapsed;
Difference calculating means (10) for calculating an index indicating a difference in the number of clocks at the time when the measurement of the number of clocks is simultaneously terminated;
At least one of temperature detection means (11) for detecting the temperature of the second oscillation circuit and voltage detection means (12) for detecting a voltage applied to the second oscillation circuit;
Storage control for storing in the storage means (15) the correspondence between the index and the physical quantity detected by at least one of the temperature detection means and the voltage detection means when the measurement of the number of clocks is simultaneously completed Means (13) ,
The storage control unit causes the storage unit to store a correspondence between the index and the physical quantity when the fluctuation range of the physical quantity within the measurement period is less than a predetermined value, and the physical quantity within the measurement period. An electronic control device that prohibits the storage of the correspondence between the index and the physical quantity in the storage means when the fluctuation range of the is not less than a predetermined value.
請求項1に記載した電子制御装置において、
前記第2の計測手段により計測された前記第2のクロック信号のクロック数を、前記記憶手段に記憶されている前記指標と前記物理量との対応に基づいて補正する補正手段(14)を備えたことを特徴とする電子制御装置。
The electronic control device according to claim 1,
Correction means (14) for correcting the number of clocks of the second clock signal measured by the second measurement means based on the correspondence between the index and the physical quantity stored in the storage means; An electronic control device characterized by that.
請求項1又は2に記載した電子制御装置において、
前記温度検出手段と前記電圧検出手段との双方を有し、
前記記憶制御手段は、前記指標と、前記クロック数の計測が同時に終了された時点での前記温度検出手段により検出されている温度及び前記電圧検出手段により検出されている電圧との対応を前記記憶手段に記憶させることを特徴とする電子制御装置。
In the electronic control device according to claim 1 or 2,
Having both the temperature detection means and the voltage detection means;
The storage control means stores the correspondence between the index and the temperature detected by the temperature detection means and the voltage detected by the voltage detection means when the measurement of the number of clocks is simultaneously completed. An electronic control device characterized in that it is stored in a means.
請求項1から3の何れか一項に記載した電子制御装置において、
前記第1の発振回路は、前記第1のクロック信号を動作クロックとして動作するマイクロコンピュータ(2)に設けられ、
前記第2の発振回路は、前記第2のクロック信号を動作クロックとして動作する集積回路(3)に設けられていることを特徴とする電子制御装置。
In the electronic control device according to any one of claims 1 to 3,
The first oscillation circuit is provided in a microcomputer (2) that operates using the first clock signal as an operation clock,
The electronic control device according to claim 2, wherein the second oscillation circuit is provided in an integrated circuit (3) that operates using the second clock signal as an operation clock .
JP2014025529A 2014-02-13 2014-02-13 Electronic control unit Active JP6135539B2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2014025529A JP6135539B2 (en) 2014-02-13 2014-02-13 Electronic control unit
DE102015202271.4A DE102015202271A1 (en) 2014-02-13 2015-02-09 ELECTRONIC CONTROL DEVICE WITH OSCILLATOR CIRCUITS

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2014025529A JP6135539B2 (en) 2014-02-13 2014-02-13 Electronic control unit

Publications (2)

Publication Number Publication Date
JP2015154191A JP2015154191A (en) 2015-08-24
JP6135539B2 true JP6135539B2 (en) 2017-05-31

Family

ID=53677055

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2014025529A Active JP6135539B2 (en) 2014-02-13 2014-02-13 Electronic control unit

Country Status (2)

Country Link
JP (1) JP6135539B2 (en)
DE (1) DE102015202271A1 (en)

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0575445A (en) * 1991-07-30 1993-03-26 Ricoh Co Ltd Device and method for correcting fluctuation of oscillation frequency of cpu
JP2003232545A (en) * 2002-02-06 2003-08-22 Dasukomu Aomori:Kk Ultrasonic atomizer and method of extracting hinokitiol solution used for the ultrasonic atomizer
JP2003232876A (en) * 2002-02-07 2003-08-22 Fujitsu Ten Ltd Time correction device
JP2007078405A (en) * 2005-09-12 2007-03-29 Kojima Press Co Ltd Timing program of software timepiece

Also Published As

Publication number Publication date
JP2015154191A (en) 2015-08-24
DE102015202271A1 (en) 2015-08-13

Similar Documents

Publication Publication Date Title
EP3435549B1 (en) Oscillator calibration system
JP5968561B2 (en) Microcomputer and its clock correction method
TWI545888B (en) Oscillator
JP2011199481A (en) Clock system
JP5429653B2 (en) Oscillator and method of manufacturing oscillator
JP2007104162A (en) Manufacturing method of crystal oscillator, and crystal oscillator
JP5573781B2 (en) CR oscillation circuit and frequency correction method thereof
JP6135539B2 (en) Electronic control unit
JP5556579B2 (en) Electronic device and clock correction method
CN102422538A (en) Analog unit
JPH0575445A (en) Device and method for correcting fluctuation of oscillation frequency of cpu
JP4626498B2 (en) Microcomputer
CN115951756A (en) Clock signal calibration device and method, electronic device, and storage medium
JP2014165649A (en) Analog-digital conversion device
US20190339097A1 (en) Absolute encoder
JP6492931B2 (en) Output voltage measurement system
JP4711546B2 (en) Temperature correction method for real-time clock and processing device provided with real-time clock
JP5266168B2 (en) Microcomputer
KR101258721B1 (en) Digital governor controller
JP6529788B2 (en) Oscillator
JP2002311173A (en) Electronic clock, method and program for correcting time error of the same
JP2006229607A (en) Semiconductor device and method of correcting oscillation frequency
JP6513927B2 (en) Oscillator and calibration method therefor
WO2021205534A1 (en) Control device and restoration processing method
JP6163591B2 (en) Oscillator

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20160325

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20170117

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20170124

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20170306

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20170410

R151 Written notification of patent or utility model registration

Ref document number: 6135539

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