JP7256610B2 - Detection device, method, system, calculation device, and calculation method - Google Patents

Detection device, method, system, calculation device, and calculation method Download PDF

Info

Publication number
JP7256610B2
JP7256610B2 JP2018122433A JP2018122433A JP7256610B2 JP 7256610 B2 JP7256610 B2 JP 7256610B2 JP 2018122433 A JP2018122433 A JP 2018122433A JP 2018122433 A JP2018122433 A JP 2018122433A JP 7256610 B2 JP7256610 B2 JP 7256610B2
Authority
JP
Japan
Prior art keywords
angle
magnetic field
angle signal
rotation
field data
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
JP2018122433A
Other languages
Japanese (ja)
Other versions
JP2020003316A (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.)
Asahi Kasei EMD Corp
Original Assignee
Asahi Kasei EMD 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 Asahi Kasei EMD Corp filed Critical Asahi Kasei EMD Corp
Priority to JP2018122433A priority Critical patent/JP7256610B2/en
Publication of JP2020003316A publication Critical patent/JP2020003316A/en
Priority to JP2022206078A priority patent/JP7381707B2/en
Application granted granted Critical
Publication of JP7256610B2 publication Critical patent/JP7256610B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

本発明は、検出装置、方法、システム、算出装置、および算出方法に関する。 The present invention relates to detection devices, methods, systems, calculation devices, and calculation methods.

2相正弦波方式のセンサの出力に基づき、モータ軸等の回転部材の回転角度を検出する検出装置が知られている。このような検出装置において、事前にモータの回転軸1回転分の角度誤差を数値列で取得して記憶し、実際の回転角度検出時には、記憶されている数値列を読み出して検出値を補正する方法がある。また、検出装置において、事前に角度誤差情報をフーリエ級数展開して求めた係数を記憶し、検出装置の起動時等に係数を読み出してフーリエ逆変換して得られた角度誤差データを用いて、検出値を補正する方法がある(特許文献1参照)。また、モータ等の組立精度の高精度化などによって、検出の誤差の要因となる成分を個別に改善する方法がある。
特許文献1 特開平4-125409号公報
2. Description of the Related Art A detection device is known that detects the rotation angle of a rotating member such as a motor shaft based on the output of a two-phase sine wave sensor. In such a detection device, the angle error for one rotation of the rotating shaft of the motor is obtained in advance as a numerical string and stored, and when the actual rotation angle is detected, the stored numerical string is read out to correct the detected value. There is a way. Further, in the detection device, the coefficient obtained by Fourier series expansion of the angle error information is stored in advance, and when the detection device is started, etc., the coefficient is read out and the angle error data obtained by inverse Fourier transform is used to There is a method of correcting the detected value (see Patent Document 1). There is also a method of individually improving components that cause detection errors by increasing assembly accuracy of motors and the like.
Patent Document 1 Japanese Patent Application Laid-Open No. 4-125409

しかし、角度誤差データによる補正は、組立誤差等により補正精度が落ちることがあった。また、組立精度を高精度化するために、調整コストが大きくなってしまう。 However, the correction based on the angle error data sometimes has a lower correction accuracy due to an assembly error or the like. In addition, the adjustment cost increases in order to improve the assembly accuracy.

上記課題を解決するために、本発明の第1の態様においては、回転体の回転角度を検出する検出装置であって、回転体の回転に応じて変化する第1磁場データを取得する第1取得部と、回転体の回転に応じて第1磁場データとは異なる位相で変化する第2磁場データを取得する第2取得部と、第1磁場データおよび第2磁場データに基づいて角度信号を出力する角度算出部と、角度信号を角度信号の傾きを用いて補正する補正部とを備える検出装置を提供する。 In order to solve the above problems, in a first aspect of the present invention, there is provided a detection device for detecting a rotation angle of a rotating body, which acquires first magnetic field data that changes according to rotation of the rotating body. an acquisition unit, a second acquisition unit that acquires second magnetic field data that changes in a phase different from the first magnetic field data according to the rotation of the rotating body, and an angle signal based on the first magnetic field data and the second magnetic field data. A detection device is provided that includes an angle calculation unit that outputs an angle signal, and a correction unit that corrects an angle signal using an inclination of the angle signal.

本発明の第2の態様においては、回転体の回転角度を検出する方法であって、回転体の回転に応じて変化する第1磁場データを取得する段階と、回転体の回転に応じて第1磁場データとは異なる位相で変化する第2磁場データを取得する段階と、第1磁場データおよび第2磁場データに基づいて角度信号を出力する段階と、角度信号を、角度信号の傾きを用いて補正する段階とを備える方法を提供する。 According to a second aspect of the present invention, there is provided a method for detecting a rotation angle of a rotating body, comprising the steps of obtaining first magnetic field data that changes according to the rotation of the rotating body; Acquiring second magnetic field data that changes in phase different from the first magnetic field data; outputting an angle signal based on the first magnetic field data and the second magnetic field data; and compensating for .

本発明の第3の態様においては、モータと、モータの回転に応じて変化する第1磁場データを出力する第1磁場センサと、モータの回転に応じて第1磁場データとは異なる位相で変化する第2磁場データを出力する第2磁場センサと、第1磁場データおよび第2磁場データに基づいてモータの回転角度を検出する第1の態様の検出装置と、モータの回転角度の検出結果に応じてモータの回転を制御するモータ制御回路とを備えるシステムを提供する。 In a third aspect of the present invention, a motor, a first magnetic field sensor that outputs first magnetic field data that changes according to the rotation of the motor, and a phase that is different from that of the first magnetic field data that changes according to the rotation of the motor a second magnetic field sensor for outputting second magnetic field data, a detecting device according to the first aspect for detecting the rotation angle of the motor based on the first magnetic field data and the second magnetic field data, and the detection result of the rotation angle of the motor and a motor control circuit for controlling rotation of the motor in response.

本発明の第4の態様においては、回転体の1回転あたり複数の周期を有する電気角を示す角度信号を補正する補正パラメータを算出する算出装置であって、複数の周期のうちの少なくとも1つの周期の角度信号の傾きを算出する傾き算出部と、少なくとも1つの周期の角度信号と、少なくとも1つの周期の角度信号の傾きを有する直線との間の差分をフーリエ級数展開して、補正係数を算出する係数算出部と、回転体の1回転あたり複数の周期の角度信号の傾きを一致させた角度信号の複数の周期の移行点におけるオフセットを算出するオフセット算出部とを備え、算出装置は、角度信号の傾き、補正係数、およびオフセットを含む補正パラメータを出力する算出装置を提供する。 In a fourth aspect of the present invention, there is provided a calculation device for calculating a correction parameter for correcting an angle signal indicating an electrical angle having a plurality of cycles per rotation of a rotating body, wherein at least one of the plurality of cycles a slope calculation unit that calculates the slope of the angle signal of the period; and the difference between the angle signal of at least one period and the straight line having the slope of the angle signal of the at least one period is subjected to Fourier series expansion to obtain a correction coefficient. and an offset calculation unit for calculating an offset at a transition point of a plurality of cycles of the angle signal obtained by matching the slopes of the angle signals of a plurality of cycles per rotation of the rotating body. A computing device is provided that outputs correction parameters including the slope of the angle signal, a correction factor, and an offset.

本発明の第5の態様においては、回転体の1回転あたり複数の周期を有する電気角を示す角度信号を補正する補正パラメータを算出する算出方法であって、複数の周期のうちの少なくとも1つの周期の角度信号の傾きを算出する傾き算出段階と、少なくとも1つの周期の角度信号と、少なくとも1つの周期の角度信号の傾きを有する直線との間の差分をフーリエ級数展開して、補正係数を算出する係数算出段階と、回転体の1回転あたり複数の周期の角度信号の傾きを一致させた角度信号の複数の周期の移行点におけるオフセットを算出するオフセット算出段階と、角度信号の記傾き、補正係数、およびオフセットを含む補正パラメータを出力する段階とを備える算出方法を提供する。 According to a fifth aspect of the present invention, there is provided a calculation method for calculating a correction parameter for correcting an angle signal indicating an electrical angle having a plurality of cycles per rotation of a rotating body, wherein at least one of the plurality of cycles a slope calculation step of calculating the slope of the angle signal of the period; performing Fourier series expansion on the difference between the angle signal of at least one period and the straight line having the slope of the angle signal of the at least one period to obtain a correction factor an offset calculation step of calculating an offset at transition points of a plurality of cycles of the angle signal in which the slopes of the angle signals of a plurality of cycles per rotation of the rotating body are matched; a slope of the angle signal; and outputting correction parameters including correction factors and offsets.

なお、上記の発明の概要は、本発明の必要な特徴の全てを列挙したものではない。また、これらの特徴群のサブコンビネーションもまた、発明となりうる。 It should be noted that the above summary of the invention does not list all the necessary features of the invention. Subcombinations of these feature groups can also be inventions.

本実施形態に係るシステム10の構成を示す。1 shows the configuration of a system 10 according to this embodiment. 検出された電気角および機械角の角度信号の一例を示す。An example of angle signals of detected electrical angles and mechanical angles is shown. 本実施形態に係る検出装置50の構成を示す。The configuration of a detection device 50 according to the present embodiment is shown. 本実施形態の検出装置50における補正パラメータの算出のフローを示す。4 shows a flow of calculation of correction parameters in the detection device 50 of the present embodiment. 本実施形態の検出装置50における補正パラメータの算出のフローにおいて補正された角度信号の一例を示す。An example of the angle signal corrected in the correction parameter calculation flow in the detection device 50 of the present embodiment is shown. 本実施形態の検出装置50における実際の検出動作のフローを示す。The flow of the actual detection operation in the detection device 50 of this embodiment is shown. 他の実施形態の補正パラメータの算出のフローにおいて補正された角度信号の一例を示す。An example of the angle signal corrected in the correction parameter calculation flow of another embodiment is shown. 本実施形態に係る検出装置50の他の構成を示す。3 shows another configuration of the detection device 50 according to this embodiment. 本実施形態の複数の態様が全体的または部分的に具現化されうるコンピュータ1900の例を示す。19 illustrates an example computer 1900 in which aspects of the present embodiments may be implemented in whole or in part.

以下、発明の実施の形態を通じて本発明を説明するが、以下の実施形態は特許請求の範囲にかかる発明を限定するものではない。また、実施形態の中で説明されている特徴の組み合わせの全てが発明の解決手段に必須であるとは限らない。 Hereinafter, the present invention will be described through embodiments of the invention, but the following embodiments do not limit the invention according to the claims. Also, not all combinations of features described in the embodiments are essential for the solution of the invention.

図1は、本実施形態に係るシステム10の構成を示す。システム10は、第1磁場センサ30および第2磁場センサ40から出力される信号に基づいて、モータ20等の回転体の回転角度を示す電気角を算出し、電気角に基づいて機械角を算出してよい。システム10は、算出した機械角に応じてモータ20の回転を制御する。回転体は、一例として、モータ20の回転軸またはモータ20の歯車等である。 FIG. 1 shows the configuration of a system 10 according to this embodiment. The system 10 calculates an electrical angle indicating the rotation angle of a rotating body such as the motor 20 based on signals output from the first magnetic field sensor 30 and the second magnetic field sensor 40, and calculates a mechanical angle based on the electrical angle. You can The system 10 controls rotation of the motor 20 according to the calculated mechanical angle. The rotating body is, for example, the rotating shaft of the motor 20 or the gear of the motor 20 .

ここで、電気角は、第1磁場センサ30または第2磁場センサ40からの正弦波状または余弦波状の信号の1周期を360度(1周期)とした場合の角度である。機械角は、回転体の1回転を360度とした場合の角度(回転体の回転角度)である。1周期の機械角は、複数の周期の電気角に相当してよい。 Here, the electrical angle is an angle when one cycle of the sinusoidal or cosine wave signal from the first magnetic field sensor 30 or the second magnetic field sensor 40 is 360 degrees (one cycle). The mechanical angle is an angle (rotational angle of the rotating body) when one rotation of the rotating body is 360 degrees. One cycle of the mechanical angle may correspond to a plurality of cycles of the electrical angle.

システム10は、モータ20と、第1磁場センサ30と、第2磁場センサ40と、検出装置50と、モータ制御回路60とを備える。 The system 10 comprises a motor 20 , a first magnetic field sensor 30 , a second magnetic field sensor 40 , a sensing device 50 and a motor control circuit 60 .

モータ20は、回転軸に接続された歯車を回転させ、工作機械または産業用ロボット等を駆動させるものであってよい。モータ20の歯車は、磁性体材料を含むものであってよい。 The motor 20 may rotate a gear connected to a rotating shaft to drive a machine tool, an industrial robot, or the like. The gears of the motor 20 may contain magnetic material.

第1磁場センサ30および第2磁場センサ40は、一例として、磁場を検出するホール素子を有する。第1磁場センサ30および第2磁場センサ40は、一例として、歯車の近傍で、磁石と歯車の間に配置される。第1磁場センサ30および第2磁場センサ40は、歯車の回転により、第1磁場センサ30および第2磁場センサ40と歯車との間の距離が変化して、磁束密度が変化する磁場が印加される。第1磁場センサ30および第2磁場センサ40は、印加される磁場に位相差が生じるように、互いにずれた位置に配置されてよい。第1磁場センサ30は、モータ20の回転に応じて変化する第1磁場データを出力する。第2磁場センサ40は、モータ20の回転に応じて第1磁場データとは異なる位相で変化する第2磁場データを出力する。第1磁場センサ30および第2磁場センサ40は、例えば、印加された磁場の磁束密度に応じて、互いに位相差が90度となる正弦波状または余弦波状の電気信号(A相信号およびB相信号)を、磁場データとして出力する。 The first magnetic field sensor 30 and the second magnetic field sensor 40 have, for example, Hall elements that detect magnetic fields. The first magnetic field sensor 30 and the second magnetic field sensor 40 are arranged, for example, near the gear and between the magnet and the gear. The rotation of the gear changes the distance between the first magnetic field sensor 30 and the second magnetic field sensor 40 and the gear, and a magnetic field that changes the magnetic flux density is applied to the first magnetic field sensor 30 and the second magnetic field sensor 40. be. The first magnetic field sensor 30 and the second magnetic field sensor 40 may be arranged at mutually shifted positions so that the applied magnetic field has a phase difference. The first magnetic field sensor 30 outputs first magnetic field data that changes according to the rotation of the motor 20 . The second magnetic field sensor 40 outputs second magnetic field data that changes in a phase different from that of the first magnetic field data according to the rotation of the motor 20 . The first magnetic field sensor 30 and the second magnetic field sensor 40 generate, for example, sine wave or cosine wave electrical signals (A phase signal and B phase signal) having a phase difference of 90 degrees with respect to the magnetic flux density of the applied magnetic field. ) are output as magnetic field data.

検出装置50は、第1磁場センサ30および第2磁場センサ40に有線または無線で接続される。検出装置50は、第1磁場センサ30および第2磁場センサ40からの第1磁場データおよび第2磁場データを受信し、第1磁場データおよび第2磁場データに基づいて、モータ20の回転角度を検出する。検出装置50は、第1取得部100と、第2取得部110と、電気角算出部120と、電気角補正部130と、機械角算出部140と、機械角補正部150とを備える。 The detection device 50 is wired or wirelessly connected to the first magnetic field sensor 30 and the second magnetic field sensor 40 . The detection device 50 receives the first magnetic field data and the second magnetic field data from the first magnetic field sensor 30 and the second magnetic field sensor 40, and determines the rotation angle of the motor 20 based on the first magnetic field data and the second magnetic field data. To detect. The detection device 50 includes a first acquisition section 100 , a second acquisition section 110 , an electrical angle calculation section 120 , an electrical angle correction section 130 , a mechanical angle calculation section 140 and a mechanical angle correction section 150 .

第1取得部100および第2取得部110は、第1磁場センサ30および第2磁場センサ40からの第1磁場データおよび第2磁場データをそれぞれ取得する。電気角算出部120は、第1取得部100および第2取得部110に接続され、第1磁場データおよび第2磁場データに基づいて、電気角を算出する。電気角補正部130は、電気角算出部120に接続され、算出された電気角を補正する。機械角算出部140は、電気角補正部130に接続され、補正した電気角から機械角を算出する。機械角補正部150は、機械角算出部140に接続され、算出された機械角を補正し、補正した機械角を示す角度信号をモータ制御回路60に出力する。 The first acquisition unit 100 and the second acquisition unit 110 acquire first magnetic field data and second magnetic field data from the first magnetic field sensor 30 and the second magnetic field sensor 40, respectively. The electrical angle calculation unit 120 is connected to the first acquisition unit 100 and the second acquisition unit 110, and calculates the electrical angle based on the first magnetic field data and the second magnetic field data. The electrical angle correction section 130 is connected to the electrical angle calculation section 120 and corrects the calculated electrical angle. The mechanical angle calculator 140 is connected to the electrical angle corrector 130 and calculates a mechanical angle from the corrected electrical angle. The mechanical angle corrector 150 is connected to the mechanical angle calculator 140 , corrects the calculated mechanical angle, and outputs an angle signal indicating the corrected mechanical angle to the motor control circuit 60 .

モータ制御回路60は、検出装置50およびモータ20に有線または無線で接続され、検出装置50からの角度信号に応じて、モータ20の回転速度および回転方向等を制御する。モータ制御回路60は、モータ20が有する各コイルに流す電流を制御してよい。 The motor control circuit 60 is wired or wirelessly connected to the detection device 50 and the motor 20 , and controls the rotation speed, rotation direction, etc. of the motor 20 according to the angle signal from the detection device 50 . The motor control circuit 60 may control the current that flows through each coil of the motor 20 .

図2は、検出装置50が検出する電気角および機械角の角度信号の一例を示す。図2は、回転体1回転分の信号を示し、一例として、機械角1周期で、電気角3周期分である場合を示す。図2の(a)および(d)は、横軸が時間で縦軸が電圧を示す。図2の(a)および(d)は、第1取得部100が取得した第1磁場データの正弦波を、当該正弦波の中心電圧を閾値としてコンパレートしてパルス波形にした理想値および実際の検出値を示す。図2の(b)、(c)、(e)、および(f)は、横軸が時間で縦軸が角度を示す。図2の(b)および(e)は、検出装置50が第1磁場データおよび第2磁場データに基づいて算出した電気角の角度信号の理想値および実際の検出値を示す。図2の(c)および(f)は、検出装置50が電気角に基づいて算出した機械角の角度信号の理想値および実際の検出値を示す。 FIG. 2 shows an example of angle signals of electrical angles and mechanical angles detected by the detection device 50 . FIG. 2 shows a signal for one rotation of the rotating body, and shows, as an example, a case in which one mechanical angle cycle corresponds to three electrical angle cycles. In (a) and (d) of FIG. 2, the horizontal axis represents time and the vertical axis represents voltage. (a) and (d) of FIG. 2 show an ideal value and an actual pulse waveform obtained by comparing the sine wave of the first magnetic field data acquired by the first acquisition unit 100 using the center voltage of the sine wave as a threshold. shows the detected value of In (b), (c), (e), and (f) of FIG. 2, the horizontal axis indicates time and the vertical axis indicates angle. (b) and (e) of FIG. 2 show the ideal value and the actual detected value of the angular signal of the electrical angle calculated by the detection device 50 based on the first magnetic field data and the second magnetic field data. (c) and (f) of FIG. 2 show the ideal value and the actual detected value of the angle signal of the mechanical angle calculated by the detection device 50 based on the electrical angle.

図2の(a)、(b)および(c)における理想値は、モータ20の組み付け誤差等が無く、検出装置50における検出に誤差が生じない場合の値である。組み付け誤差等が無い場合には、第1磁場センサ30が出力した第1磁場データの正弦波の複数の周期が均一となるため、図2の(a)に示すように、検出装置50が検出するパルス波の複数の周期は均一となる。この場合に第2磁場センサ40が出力する第2磁場データも同様である。図2の(b)に示すように、第1磁場データおよび第2磁場データの基づき算出される電気角は、同様に複数の周期で均一な長さを有し、図2の(c)に示すように、このような電気角に基づき算出される機械角は、1周期にわたって直線状の理想値を有する。 The ideal values in (a), (b) and (c) of FIG. 2 are values when there is no assembly error of the motor 20 and no error occurs in detection by the detection device 50 . When there is no assembly error or the like, the plurality of cycles of the sine wave of the first magnetic field data output by the first magnetic field sensor 30 are uniform. A plurality of periods of the pulse wave to be generated are uniform. The same applies to the second magnetic field data output by the second magnetic field sensor 40 in this case. As shown in (b) of FIG. 2, the electrical angle calculated based on the first magnetic field data and the second magnetic field data similarly has a uniform length over a plurality of periods, and is shown in (c) of FIG. As shown, the mechanical angle calculated based on such an electrical angle has a linear ideal value over one cycle.

実際の検出においては、モータ20の組み付け誤差等があるため、図2の(d)、(e)および(f)に示すように、検出装置50で検出する値に誤差が生じる。図2の(e)および(f)における実際の検出値は、検出装置50において検出した、電気角補正部130および機械角補正部150による補正が施されていない値である。組み付け誤差等がある場合には、第1磁場センサ30が出力した第1磁場データの正弦波の複数の周期は、回転体1回転あたりでばらつきを有するため、図2の(d)に示すように、検出装置50が検出するパルス波の複数の周期の長さは、同様に、回転体1回転あたりでばらつきを有する。このような場合、図2の(e)に示すように、第1磁場データおよび第2磁場データの基づき算出される電気角は、同様に複数の周期で不均一な長さを有し、図2の(f)に示すように、電気角に基づき算出される機械角は、電気角の周期性の乱れに応じた誤差を有する。 In actual detection, there are errors in the assembly of the motor 20 and the like, so errors occur in the values detected by the detection device 50 as shown in (d), (e) and (f) of FIG. The actual detected values in (e) and (f) of FIG. 2 are values detected by the detecting device 50 and not corrected by the electrical angle corrector 130 and the mechanical angle corrector 150 . If there is an assembly error or the like, a plurality of cycles of the sinusoidal wave of the first magnetic field data output by the first magnetic field sensor 30 varies per rotation of the rotating body. Furthermore, the lengths of the plurality of cycles of the pulse wave detected by the detection device 50 similarly vary per rotation of the rotating body. In such a case, as shown in (e) of FIG. 2, the electrical angle calculated based on the first magnetic field data and the second magnetic field data similarly has non-uniform lengths in a plurality of cycles, and As shown in (f) of 2, the mechanical angle calculated based on the electrical angle has an error corresponding to the disturbance of the periodicity of the electrical angle.

従って、回転体1回転あたりで電気角の複数の周期の長さが均一であることを前提に検出値の誤差の補正を行うと、図2の(d)、(e)および(f)に示すような周期性の乱れにより、電気角または機械角の補正の精度が落ちてしまう。 Therefore, if the errors in the detected values are corrected on the premise that the lengths of a plurality of cycles of the electrical angle per one rotation of the rotating body are uniform, the values shown in (d), (e) and (f) of FIG. 2 are obtained. Periodic disturbances such as those shown degrade the accuracy of the electrical or mechanical angle correction.

図3は、本実施形態に係る検出装置50のより詳細な構成を示す。検出装置50は、電気角の各周期の傾きを用いて算出した補正パラメータにより、角度信号を補正して、回転体の回転角度を検出する。検出装置50は、予め、角度信号の傾きを用いて補正パラメータを算出して記憶する補正パラメータの算出動作と、モータ20の回転制御等において、検出した角度信号を、記憶された補正パラメータを用いて補正して出力する実際の検出動作とを行う。 FIG. 3 shows a more detailed configuration of the detection device 50 according to this embodiment. The detection device 50 corrects the angle signal with a correction parameter calculated using the inclination of each period of the electrical angle, and detects the rotation angle of the rotating body. The detection device 50 uses the stored correction parameter to detect the detected angle signal in the correction parameter calculation operation of calculating and storing the correction parameter using the inclination of the angle signal in advance, and in the rotation control of the motor 20 and the like. and the actual detection operation of correcting and outputting.

検出装置50は、第1取得部100と、第2取得部110と、第1比較器300と、第2比較器310と、カウンタ320と、信号調整部330と、電気角算出部120と、電気角補正部130と、機械角算出部140と、機械角補正部150と、記憶部340とを備える。なお、検出装置50において、電気角補正部130、機械角補正部150、および記憶部340以外の構成は、補正パラメータの算出動作と実際の検出動作とで、同様の処理を行うものであってよい。 The detection device 50 includes a first acquisition unit 100, a second acquisition unit 110, a first comparator 300, a second comparator 310, a counter 320, a signal adjustment unit 330, an electrical angle calculation unit 120, It includes an electrical angle correction section 130 , a mechanical angle calculation section 140 , a mechanical angle correction section 150 and a storage section 340 . In the detection device 50, the components other than the electrical angle correction section 130, the mechanical angle correction section 150, and the storage section 340 perform the same processing in the correction parameter calculation operation and the actual detection operation. good.

電気角算出部120および機械角算出部140の少なくとも一方は、角度算出部として機能してよく、電気角補正部130および機械角補正部150の少なくとも一方は、補正部として機能してよい。 At least one of the electrical angle calculator 120 and the mechanical angle calculator 140 may function as an angle calculator, and at least one of the electrical angle corrector 130 and the mechanical angle corrector 150 may function as a corrector.

第1取得部100は、第1磁場センサ30からの第1磁場データを取得して、第1磁場データを信号調整部330および第1比較器300に出力する。第2取得部110は、第2磁場センサ40からの第2磁場データを取得して、第2磁場データを信号調整部330および第2比較器310に出力する。第1取得部100および第2取得部110は、第1磁場データおよび第2磁場データを有線または無線で受信し、増幅して出力してよい。 The first acquisition unit 100 acquires first magnetic field data from the first magnetic field sensor 30 and outputs the first magnetic field data to the signal adjustment unit 330 and the first comparator 300 . The second acquisition unit 110 acquires the second magnetic field data from the second magnetic field sensor 40 and outputs the second magnetic field data to the signal adjustment unit 330 and the second comparator 310 . The first acquisition unit 100 and the second acquisition unit 110 may receive the first magnetic field data and the second magnetic field data by wire or wirelessly, amplify them, and output them.

第1比較器300および第2比較器310は、第1取得部100および第2取得部110にそれぞれ接続され、それぞれ第1磁場データおよび第2磁場データの信号の電圧を閾値電圧と比較して、比較結果を示すパルス信号を出力する。閾値電圧は、例えば第1磁場データまたは第2磁場データの信号の最大電圧と最小電圧の中心の電圧であってよく、一例として0Vであってよい。 The first comparator 300 and the second comparator 310 are connected to the first acquisition unit 100 and the second acquisition unit 110, respectively, and compare the voltages of the signals of the first magnetic field data and the second magnetic field data with the threshold voltage. , output a pulse signal indicating the comparison result. The threshold voltage may be, for example, the center voltage between the maximum voltage and the minimum voltage of the signal of the first magnetic field data or the second magnetic field data, and may be 0V as an example.

カウンタ320は、第1比較器300および第2比較器310に接続される。カウンタ320は、第1比較器300および第2比較器310からのパルス信号の立ち上がりおよび立ち下がりをカウントアップして、波数情報を出力してよい。波数情報は、一例として、立ち上がりおよび立ち下がりの累積数、または取得した磁場データが回転体1回転あたりの電気角のいずれの周期に属するかを示す情報(例えば、機械角1周期中の電気角の周期番号等)であってよい。 A counter 320 is connected to the first comparator 300 and the second comparator 310 . The counter 320 may count up the rising and falling edges of the pulse signals from the first comparator 300 and the second comparator 310 and output wave number information. Wavenumber information is, for example, the accumulated number of rising and falling edges, or information indicating to which cycle of the electrical angle per rotation of the rotating body the acquired magnetic field data belongs (for example, the electrical angle in one cycle of the mechanical angle period number, etc.).

信号調整部330は、第1取得部100および第2取得部110に接続される。信号調整部330は、アナログデジタルコンバータ331,332と、オフセット/ゲイン/位相算出部339と、オフセット調整部333,334と、ゲイン調整部335,336と、位相調整部337,338とを有する。 The signal conditioning unit 330 is connected to the first acquisition unit 100 and the second acquisition unit 110 . The signal adjuster 330 has analog-to-digital converters 331 and 332 , an offset/gain/phase calculator 339 , offset adjusters 333 and 334 , gain adjusters 335 and 336 , and phase adjusters 337 and 338 .

アナログデジタルコンバータ331,332は、第1取得部100および第2取得部110からの磁場データのアナログ信号をデジタル信号へ変換する。オフセット/ゲイン/位相算出部339は、アナログデジタルコンバータ331,332、カウンタ320、および記憶部340に接続される。オフセット/ゲイン/位相算出部339は、カウンタ320からの波数情報に応じて、アナログデジタルコンバータ331,332からのデジタル信号のオフセット、ゲイン、および位相の調整パラメータを算出し、記憶部340に出力する。なお、オフセット/ゲイン/位相算出部339は、カウンタ320からの波数情報を使用せず、波数情報に依存しない調整パラメータを算出してもよい。 The analog-to-digital converters 331 and 332 convert analog signals of the magnetic field data from the first acquisition section 100 and the second acquisition section 110 into digital signals. Offset/gain/phase calculator 339 is connected to analog-to-digital converters 331 and 332 , counter 320 , and storage 340 . The offset/gain/phase calculator 339 calculates the offset, gain, and phase adjustment parameters of the digital signals from the analog-to-digital converters 331 and 332 according to the wavenumber information from the counter 320, and outputs them to the storage unit 340. . Note that the offset/gain/phase calculator 339 may calculate an adjustment parameter independent of the wavenumber information without using the wavenumber information from the counter 320 .

オフセット調整部333,334は、アナログデジタルコンバータ331,332および記憶部340に接続され、調整パラメータに応じてデジタル信号のオフセットを調整する。オフセット調整部333,334は、一例として、デジタル信号の最大電圧と最小電圧との間の中心電圧が0Vとなるようにオフセットを調整する。ゲイン調整部335,336は、オフセット調整部333,334および記憶部340に接続され、調整パラメータに応じてデジタル信号のゲインを調整する。ゲイン調整部335,336は、一例として、第1磁場データのデジタル信号の振幅と第2磁場データのデジタル信号の振幅が同一になるようにゲインを調整する。位相調整部337,338は、ゲイン調整部335,336および記憶部340に接続され、調整パラメータに応じてデジタル信号の位相を調整する。位相調整部337,338は、一例として、第1磁場データのデジタル信号と第2磁場データのデジタル信号との間の位相差が、予め定められた位相差となるように調整する。位相調整部337,338は、調整した信号AおよびBを出力する。 The offset adjustment units 333 and 334 are connected to the analog-to-digital converters 331 and 332 and the storage unit 340, and adjust the offset of the digital signal according to adjustment parameters. As an example, the offset adjustment units 333 and 334 adjust the offset so that the center voltage between the maximum voltage and the minimum voltage of the digital signal is 0V. The gain adjustment units 335 and 336 are connected to the offset adjustment units 333 and 334 and the storage unit 340, and adjust the gain of the digital signal according to the adjustment parameters. For example, the gain adjusters 335 and 336 adjust gains so that the amplitude of the digital signal of the first magnetic field data and the amplitude of the digital signal of the second magnetic field data are the same. Phase adjusters 337 and 338 are connected to gain adjusters 335 and 336 and memory 340 and adjust the phase of the digital signal according to the adjustment parameter. As an example, the phase adjusters 337 and 338 adjust the phase difference between the digital signal of the first magnetic field data and the digital signal of the second magnetic field data to be a predetermined phase difference. Phase adjusters 337 and 338 output adjusted signals A and B. FIG.

電気角算出部120は、信号調整部330に接続され、第1磁場データの信号Aおよび第2磁場データの信号Bに基づいて電気角ΘE0を算出する。電気角算出部120は、信号AおよびBから逆正接を用いて電気角(電気内挿角)ΘE0を算出して、角度信号ΘE0を出力してよい。角度信号ΘE0は、回転体の1回転あたり複数の周期を有する電気角を示すものであってよい。 The electrical angle calculator 120 is connected to the signal adjuster 330 and calculates an electrical angle ΘE0 based on the signal A of the first magnetic field data and the signal B of the second magnetic field data. The electrical angle calculator 120 may calculate an electrical angle (electrical interpolation angle) ΘE0 from the signals A and B using the arctangent, and output the angle signal ΘE0. The angle signal ΘE0 may indicate an electrical angle having a plurality of cycles per rotation of the rotating body.

電気角補正部130は、電気角算出部120に接続され、電気角算出部120からの角度信号ΘE0を、角度信号ΘE0の傾きを用いて補正する。電気角補正部130は、角度信号ΘE0を、回転体の1回転中の各電気角ΘE0が複数の周期のいずれに位置するかに応じて、異なる角度信号ΘE0の傾きを用いて補正してよい。電気角補正部130は、傾き算出部350と、直線生成部351と、差分算出部352と、係数算出部353と、差分補正部354と、傾き補正部355とを有する。 The electrical angle correction section 130 is connected to the electrical angle calculation section 120 and corrects the angle signal .THETA.E0 from the electrical angle calculation section 120 using the inclination of the angle signal .THETA.E0. The electrical angle correction unit 130 may correct the angle signal ΘE0 using different slopes of the angle signal ΘE0 depending on which of a plurality of cycles each electrical angle ΘE0 during one rotation of the rotating body is positioned. . The electrical angle corrector 130 has a tilt calculator 350 , a straight line generator 351 , a difference calculator 352 , a coefficient calculator 353 , a difference corrector 354 , and a tilt corrector 355 .

傾き算出部350は、電気角算出部120およびカウンタ320に接続され、電気角算出部120からの角度信号ΘE0を受信し、複数の周期のうちの少なくとも1つの周期の角度信号ΘE0の傾きを算出する。傾き算出部350は、補正パラメータの算出動作において、回転体の1回転あたり複数の周期分の電気角を示す角度信号ΘE0を受け取り、電気角の周期毎に角度信号ΘE0の傾きk0を算出して、記憶部340および直線生成部351に出力してよい。 The inclination calculator 350 is connected to the electrical angle calculator 120 and the counter 320, receives the angle signal ΘE0 from the electrical angle calculator 120, and calculates the inclination of the angle signal ΘE0 in at least one cycle out of a plurality of cycles. do. In the correction parameter calculation operation, the tilt calculator 350 receives the angle signal ΘE0 indicating the electrical angle for a plurality of cycles per rotation of the rotating body, and calculates the tilt k0 of the angle signal ΘE0 for each cycle of the electrical angle. , to the storage unit 340 and the straight line generation unit 351 .

直線生成部351は、傾き算出部350およびカウンタ320に接続される。直線生成部351は、補正パラメータの算出動作において、電気角の周期毎に、傾き算出部350から受け取った傾きk0を有する参照電気角ΘErefの直線を生成して、参照電気角ΘErefを出力してよい。 Straight line generator 351 is connected to slope calculator 350 and counter 320 . In the correction parameter calculation operation, the straight line generator 351 generates a straight line of the reference electrical angle ΘEref having the slope k0 received from the slope calculator 350 and outputs the reference electrical angle ΘEref for each cycle of the electrical angle. good.

差分算出部352は、電気角算出部120および直線生成部351に接続され、複数の周期のうちの少なくとも1つの周期の角度信号ΘE0と、当該少なくとも1つの周期の角度信号ΘE0の傾きk0を有する直線との間の差分情報を算出する。差分算出部352は、補正パラメータの算出動作において、電気角の周期毎に、検出した電気角ΘE0から、対応する参照電気角ΘErefを減算して得られた差分を、差分情報として出力してよい。 The difference calculator 352 is connected to the electrical angle calculator 120 and the straight line generator 351, and has an angle signal ΘE0 of at least one cycle out of a plurality of cycles and a slope k0 of the angle signal ΘE0 of the at least one cycle. Calculate the difference information between the straight line. In the correction parameter calculation operation, the difference calculator 352 may output the difference obtained by subtracting the corresponding reference electrical angle ΘEref from the detected electrical angle ΘE0 for each period of the electrical angle, as difference information. .

係数算出部353は、差分算出部352とカウンタ320と直線生成部351とに接続される。係数算出部353は、少なくとも1つの周期の角度信号ΘE0と、当該少なくとも1つの周期の角度信号ΘE0の傾きk0を有する直線との間の差分をフーリエ級数展開して、補正係数を算出する。係数算出部353は、補正パラメータの算出動作において、差分算出部352により算出された少なくとも電気角1周期分の差分をフーリエ級数展開することにより、電気角の周期毎に補正係数を算出してよい。係数算出部353は、算出した補正係数を出力して記憶部340に記憶させる。 The coefficient calculator 353 is connected to the difference calculator 352 , the counter 320 and the straight line generator 351 . The coefficient calculator 353 performs Fourier series expansion on the difference between the angle signal .THETA.E0 of at least one cycle and the straight line having the slope k0 of the angle signal .THETA.E0 of the at least one cycle, and calculates the correction coefficient. In the correction parameter calculation operation, the coefficient calculator 353 may calculate a correction coefficient for each electrical angle cycle by performing Fourier series expansion on the difference for at least one electrical angle cycle calculated by the difference calculator 352 . . The coefficient calculation unit 353 outputs the calculated correction coefficient and stores it in the storage unit 340 .

差分補正部354は、電気角算出部120および記憶部340に接続される。差分補正部354は、電気角算出部120からの角度信号ΘE0を、記憶部340に記憶された補正係数を適用した逆フーリエ関数から得られる差分情報を用いて補正する。差分補正部354は、補正パラメータの算出動作において、および実際の検出動作前に、記憶部340から、補正対象の電気角ΘE0の周期に対応する補正係数を読み出し、補正係数を逆フーリエ関数に適用し、補正対象の電気角ΘE0に対応する時点の差分情報を導出してよい。差分補正部354は、補正パラメータの算出動作および実際の検出動作において、差分情報により電気角ΘE0を補正して、補正後の電気角を示す角度信号ΘE1を出力してよい。 Difference correction section 354 is connected to electrical angle calculation section 120 and storage section 340 . The difference correction unit 354 corrects the angle signal ΘE0 from the electrical angle calculation unit 120 using difference information obtained from the inverse Fourier function to which the correction coefficients stored in the storage unit 340 are applied. During the correction parameter calculation operation and before the actual detection operation, the difference correction unit 354 reads the correction coefficient corresponding to the period of the electrical angle ΘE0 to be corrected from the storage unit 340, and applies the correction coefficient to the inverse Fourier function. , and the difference information at the time point corresponding to the electrical angle ΘE0 to be corrected may be derived. The difference correction unit 354 may correct the electrical angle ΘE0 based on the difference information in the correction parameter calculation operation and the actual detection operation, and output an angle signal ΘE1 indicating the corrected electrical angle.

傾き補正部355は、差分補正部354および記憶部340に接続され、回転体の1回転あたり複数の周期の角度信号の傾きを一致させる。傾き補正部355は、補正パラメータの算出動作において、回転体の1回転における複数の周期分の電気角ΘE1を差分補正部354から受け取り、記憶部340から電気角の周期毎の傾きk0を読み出して、電気角の周期毎に異なる傾きk0を一致させるように電気角ΘE1を補正してよい。傾き補正部355は、補正パラメータの算出動作において、傾き補正前後の電気角の差分を補正パラメータとして記憶部340に記憶させてよい。一方、傾き補正部355は、実際の検出動作において、記憶部340から、傾き補正前後の電気角の差分または周期毎の傾きk0を補正パラメータとして読み出し、電気角ΘE1を補正してよい。電気角傾き補正部355は、補正した電気角ΘE2を出力してよい。 The tilt correction unit 355 is connected to the difference correction unit 354 and the storage unit 340, and matches the tilts of the angle signals of a plurality of cycles per rotation of the rotating body. In the correction parameter calculation operation, the tilt correction unit 355 receives the electrical angles ΘE1 for a plurality of cycles in one rotation of the rotating body from the difference correction unit 354, and reads the tilt k0 for each cycle of the electrical angle from the storage unit 340. , the electrical angle .THETA.E1 may be corrected so that the slope k0, which differs for each cycle of the electrical angle, is matched. In the correction parameter calculation operation, the tilt correction section 355 may store the difference in electrical angle before and after the tilt correction in the storage section 340 as a correction parameter. On the other hand, in the actual detection operation, the tilt correction unit 355 may read the difference between the electrical angles before and after the tilt correction or the tilt k0 for each period from the storage unit 340 as a correction parameter, and correct the electrical angle ΘE1. The electrical angle tilt corrector 355 may output the corrected electrical angle ΘE2.

機械角算出部140は、電気角補正部130および記憶部340に接続され、電気角ΘE2とカウンタ320からの波数情報とから機械角ΘM0を算出する。機械角算出部140は、補正パラメータの算出動作および実際の検出動作において、波数情報から、電気角ΘE2が回転体の1回転中のいずれの周期の電気角であるかを導出し、電気角ΘE2から機械角ΘM0を算出することができる。機械角算出部140は、算出した機械角を示す角度信号ΘM0を出力する。 Mechanical angle calculator 140 is connected to electrical angle corrector 130 and memory 340 and calculates mechanical angle ΘM0 from electrical angle ΘE2 and wavenumber information from counter 320 . Mechanical angle calculator 140 derives from the wave number information in which cycle the electrical angle . The mechanical angle ΘM0 can be calculated from . The mechanical angle calculator 140 outputs an angle signal ΘM0 indicating the calculated mechanical angle.

機械角補正部150は、機械角算出部140および出力端子OUTに接続され、機械角算出部140からの角度信号ΘM0を補正する。機械角補正部150は、オフセット算出部360と、オフセット加算部361とを有する。 Mechanical angle correction section 150 is connected to mechanical angle calculation section 140 and output terminal OUT, and corrects angle signal ΘM0 from mechanical angle calculation section 140 . The mechanical angle corrector 150 has an offset calculator 360 and an offset adder 361 .

オフセット算出部360は、機械角算出部140および記憶部340に接続され、傾き補正部355において傾きを一致させた電気角の角度信号の複数の周期の移行点におけるオフセットを算出する。ここで、移行点は、電気角の隣り合う異なる周期に移行する時点であり、当該移行点におけるオフセットは、当該移行点に対応する時点での機械角のオフセットである。オフセット算出部360は、補正パラメータの算出動作において、電気角の複数の周期の移行点に対応する部分における機械角ΘM0のオフセットΘMoffを、機械角算出部140により算出された機械角ΘM0と、理想機械角ΘMiとを用いて算出してよい。オフセット算出部360は、事前に、検出装置50の初期調整時等にユーザ等により外部から入力された理想機械角ΘMiを記憶してよい。ここで、理想機械角ΘMiは、図2の(c)と同じものであってよく、モータ20の組み付け誤差等が無く、検出装置50における検出に誤差が生じない場合の機械角であってよい。オフセット算出部360は、算出したオフセットΘMoffを記憶部340に出力して記憶させる。 The offset calculation unit 360 is connected to the mechanical angle calculation unit 140 and the storage unit 340, and calculates offsets at transition points of a plurality of periods of the angle signals of the electrical angles whose tilts are matched by the tilt correction unit 355. FIG. Here, the transition point is the time point at which the electrical angle transitions to different adjacent cycles, and the offset at the transition point is the mechanical angle offset at the time point corresponding to the transition point. In the operation of calculating the correction parameter, the offset calculator 360 combines the offset ΘMoff of the mechanical angle ΘM0 at the portion corresponding to the transition point of a plurality of cycles of the electrical angle with the mechanical angle ΘM0 calculated by the mechanical angle calculator 140 and the ideal It may be calculated using the mechanical angle ΘMi. The offset calculator 360 may store in advance the ideal mechanical angle ΘMi externally input by the user or the like during the initial adjustment of the detection device 50 or the like. Here, the ideal mechanical angle ΘMi may be the same as that shown in FIG. 2C, and may be a mechanical angle when there is no assembly error of the motor 20 and no error occurs in detection by the detection device 50. . The offset calculation unit 360 outputs the calculated offset ΘMoff to the storage unit 340 for storage.

オフセット加算部361は、記憶部340および機械角算出部140に接続され、角度信号の複数の周期の移行点におけるオフセットΘMoffを、機械角算出部140からの角度信号ΘM0に加算する。オフセット加算部361は、実際の検出動作前に、角度信号ΘM0に対応する、電気角の周期毎に異なるオフセットΘMoffを記憶部340から読み出してよい。オフセット加算部361は、実際の検出動作において、角度信号ΘM0に対応する電気角の周期のオフセットΘMoffを加算してよい。 Offset addition section 361 is connected to storage section 340 and mechanical angle calculation section 140 , and adds offset ΘMoff at transition points of a plurality of cycles of the angle signal to angle signal ΘM 0 from mechanical angle calculation section 140 . The offset adder 361 may read from the storage 340 the offset ΘMoff corresponding to the angle signal ΘM0 and different for each period of the electrical angle before the actual detection operation. In an actual detection operation, the offset adding section 361 may add an electrical angle period offset ΘMoff corresponding to the angle signal ΘM0.

記憶部340は、一例として、不揮発性RAM、ROM、またはハードディスク等の不揮発性メモリであってよい。記憶部340は、カウンタ320、オフセット/ゲイン/位相算出部339、傾き算出部350、係数算出部353、およびオフセット算出部360に接続される。記憶部340は、補正パラメータの算出動作において、係数算出部353から受け取った補正係数と、傾き算出部350からの傾きk0と、傾き補正部355からの差分と、オフセット算出部360から受け取ったオフセットΘMoffとのうちの少なくとも1つの補正パラメータを、対応する電気角の周期に関連付けて記憶してよい。記憶部340は、カウンタ320からの波数情報から、補正パラメータが回転体1回転中のいずれの電気角の周期に対応するかを判断して、補正パラメータと電気角の周期とを関連付けてよい。記憶部340は、実際の検出動作前に、電気角の周期毎に補正パラメータが読み出されてよい。 The storage unit 340 may be, for example, a nonvolatile memory such as a nonvolatile RAM, ROM, or hard disk. Storage unit 340 is connected to counter 320 , offset/gain/phase calculator 339 , slope calculator 350 , coefficient calculator 353 , and offset calculator 360 . In the correction parameter calculation operation, the storage unit 340 stores the correction coefficient received from the coefficient calculation unit 353, the slope k0 from the slope calculation unit 350, the difference from the slope correction unit 355, and the offset received from the offset calculation unit 360. ΘMoff and at least one correction parameter may be stored in association with the period of the corresponding electrical angle. The storage unit 340 may determine from the wavenumber information from the counter 320 which electrical angle period in one rotation of the rotor corresponds to the correction parameter, and associate the correction parameter with the electrical angle period. The storage unit 340 may read the correction parameter for each electrical angle period before the actual detection operation.

図4は、本実施形態に係る検出装置50における補正パラメータの算出動作のフローを示す。本実施形態は、一例として、機械角1周期で、電気角3周期分である場合を示す。ここで、検出装置50は、補正パラメータの算出を、検出装置50のキャリブレーション等において実行してよい。また、検出装置50は、補正パラメータの算出を、前回の検出動作において検出した磁場データまたは角度信号を用いて実行してもよい。 FIG. 4 shows the flow of the correction parameter calculation operation in the detection device 50 according to this embodiment. In this embodiment, as an example, one cycle of the mechanical angle corresponds to three cycles of the electrical angle. Here, the detection device 50 may calculate the correction parameters during calibration of the detection device 50 or the like. Further, the detection device 50 may calculate the correction parameter using the magnetic field data or the angle signal detected in the previous detection operation.

S400において、第1取得部100および第2取得部110は、第1磁場センサ30および第2磁場センサ40からの第1磁場データおよび第2磁場データをそれぞれ取得する。信号調整部330は、取得した第1磁場データおよび第2磁場データをそれぞれ調整し、第1磁場データの信号Aおよび第2磁場データの信号Bを電気角算出部120に出力する。 In S400, the first acquisition unit 100 and the second acquisition unit 110 acquire first magnetic field data and second magnetic field data from the first magnetic field sensor 30 and the second magnetic field sensor 40, respectively. Signal adjusting section 330 adjusts the acquired first magnetic field data and second magnetic field data, respectively, and outputs first magnetic field data signal A and second magnetic field data signal B to electrical angle calculating section 120 .

S410において、電気角算出部120は、逆正接の(数1)式を用いて、信号Aおよび信号Bから電気角ΘE0を算出してよい。
(数1)
ΘE0=Atan2(A,B)
In S410, the electrical angle calculation unit 120 may calculate the electrical angle ΘE0 from the signals A and B using the arctangent equation (Equation 1).
(Number 1)
ΘE0=Atan2(A, B)

S420において、電気角補正部130は、電気角ΘE0の差分補正をする。電気角補正部130は、機械角1周期分または電気角1周期分毎に補正パラメータを算出してよい。 In S420, the electrical angle correction unit 130 performs difference correction of the electrical angle ΘE0. The electrical angle corrector 130 may calculate the correction parameter for each cycle of the mechanical angle or for each cycle of the electrical angle.

傾き算出部350は、一例として、電気角ΘE0の各周期の始点と終点の値を結ぶ直線の傾きk0を算出してよい。また、傾き算出部350は、各周期で、電気角ΘE0を最小二乗法で近似した直線の傾きを傾きk0として算出してよい。直線生成部351は、例えば、傾き算出部350からの傾きk0を有する参照電気角ΘErefの直線を生成し、電気角ΘE0に対応する時点での参照電気角ΘErefを出力する。差分算出部352は、(数2)式により、算出された電気角ΘE0から、参照電気角ΘErefを減算して、差分を算出してよい。
(数2)
差分=ΘE0-ΘEref
As an example, the slope calculator 350 may calculate the slope k0 of a straight line connecting the starting point and the ending point of each cycle of the electrical angle ΘE0. Further, the slope calculator 350 may calculate the slope of a straight line obtained by approximating the electrical angle ΘE0 by the method of least squares as the slope k0 in each cycle. The straight line generator 351 generates, for example, a straight line of the reference electrical angle ΘEref having a slope k0 from the slope calculator 350, and outputs the reference electrical angle ΘEref at the point corresponding to the electrical angle ΘE0. The difference calculation unit 352 may calculate the difference by subtracting the reference electrical angle ΘEref from the calculated electrical angle ΘE0 using Equation (2).
(Number 2)
Difference = ΘE0 - ΘEref

係数算出部353は、一例として、(数3)式により、電気角の周期毎に、差分算出部352からの差分をフーリエ級数展開して、補正係数a1~a8を算出する。係数算出部353は、算出した補正係数a1~a8を記憶部340に記憶させる。
(数3)
ΘE0-ΘEref≒a1×sinΘ+a2×cosΘ+a3×sin2Θ+a4×cos2Θ+a5×sin3Θ+a6×cos3Θ+a7×sin4Θ+a8×cos4Θ
As an example, the coefficient calculation unit 353 performs Fourier series expansion on the difference from the difference calculation unit 352 for each period of the electrical angle to calculate the correction coefficients a1 to a8 using Equation (3). The coefficient calculation unit 353 causes the storage unit 340 to store the calculated correction coefficients a1 to a8.
(Number 3)
ΘE0−ΘEref≈a1×sinΘ+a2×cosΘ+a3×sin2Θ+a4×cos2Θ+a5×sin3Θ+a6×cos3Θ+a7×sin4Θ+a8×cos4Θ

差分補正部354は、一例として、(数4)式により、記憶部340から読み出した補正係数a1~a8を適用した逆フーリエ関数から差分を導出し、電気角ΘE0から当該差分を減算して補正する。差分補正部354は、補正後の電気角ΘE1を傾き補正部355に出力する。
(数4)
ΘE1=ΘE0-(a1×sinΘE0+a2×cosΘE0+a3×sin2ΘE0+a4×cos2ΘE0+a5×sin3ΘE0+a6×cos3ΘE0+a7×sin4ΘE0+a8×cos4ΘE0)
As an example, the difference correction unit 354 derives the difference from the inverse Fourier function to which the correction coefficients a1 to a8 read from the storage unit 340 are applied, and subtracts the difference from the electrical angle ΘE0 to correct the difference, using equation (4). do. The difference corrector 354 outputs the corrected electrical angle ΘE1 to the tilt corrector 355 .
(Number 4)
ΘE1=ΘE0−(a1×sinΘE0+a2×cosΘE0+a3×sin2ΘE0+a4×cos2ΘE0+a5×sin3ΘE0+a6×cos3ΘE0+a7×sin4ΘE0+a8×cos4ΘE0)

ここで、電気角補正部130は、差分補正を複数回実行してよい。電気角補正部130は、例えば、差分補正部354により補正した電気角ΘE1を、再度、傾き算出部350、直線生成部351、差分算出部352、および係数算出部353で処理することにより補正係数a1-2~a8-2を算出してよい。電気角補正部130は、差分補正部354により補正係数a1-2~a8-2を用いて電気角ΘE1を上記と同様に補正してよい。 Here, the electrical angle correction section 130 may perform difference correction multiple times. The electrical angle correction unit 130, for example, processes the electrical angle ΘE1 corrected by the difference correction unit 354 again with the inclination calculation unit 350, the straight line generation unit 351, the difference calculation unit 352, and the coefficient calculation unit 353 to obtain a correction coefficient. a1-2 to a8-2 may be calculated. The electrical angle corrector 130 may correct the electrical angle ΘE1 by using the correction coefficients a1-2 to a8-2 by the difference corrector 354 in the same manner as described above.

S430において、傾き補正部355は、電気角ΘE1の傾きを補正する。傾き補正部355は、機械角1周期あたり電気角ΘE1の複数の周期が、略同一の傾き(例えば、図2の(b)に示すような理想値の電気角の周期と同じ傾き)となるように補正してよい。傾き補正部355は、一例として、電気角の1周期毎に、傾き算出部350から対応する傾きk0を受け取り、逆数1/k0を生成して、逆数1/k0を電気角ΘE1の傾きk0に乗算する。これにより、傾き補正部355は、電気角ΘE1の複数の周期の傾きが略1となるように補正することができる。 In S430, the tilt corrector 355 corrects the tilt of the electrical angle ΘE1. The inclination corrector 355 makes a plurality of cycles of the electrical angle ΘE1 in one cycle of the mechanical angle substantially the same slope (for example, the same slope as the cycle of the ideal electrical angle as shown in FIG. 2B). can be corrected as follows. For example, the tilt correction unit 355 receives the corresponding tilt k0 from the tilt calculator 350 for each period of the electrical angle, generates the reciprocal 1/k0, and converts the reciprocal 1/k0 to the tilt k0 of the electrical angle ΘE1. Multiply. As a result, the inclination corrector 355 can correct the inclination of the electrical angle ΘE1 over a plurality of periods to be approximately 1.

ここで、傾き補正部355は、差分補正部354により補正した電気角ΘE1について傾き算出部350により再度算出した傾きk1を用いて、同様に電気角ΘE1の傾きを補正してもよい。 Here, the tilt correction unit 355 may similarly correct the tilt of the electrical angle ΘE1 corrected by the difference correction unit 354 using the tilt k1 recalculated by the tilt calculation unit 350 .

傾き補正部355は、補正後の電気角ΘE2を機械角算出部140に出力する。傾き補正部355は、電気角ΘE1と電気角ΘE2との間の差分を求めて、補正パラメータとして記憶部340に記憶させてよい。 The tilt corrector 355 outputs the corrected electrical angle ΘE2 to the mechanical angle calculator 140 . The inclination corrector 355 may obtain the difference between the electrical angle ΘE1 and the electrical angle ΘE2 and store it in the storage 340 as a correction parameter.

S440において、機械角算出部140は、受け取った電気角ΘE2と波数情報とから機械角ΘM0を算出する。機械角算出部140は、一例として、本実施形態において、波数情報が回転体1回転中の電気角の1番目の周期を示す場合は、電気角0~360度が機械角0~120度に対応することから、電気角ΘE2から機械角ΘM0を算出してよい。機械角算出部140は、算出した機械角ΘM0を機械角補正部150に出力する。 In S440, the mechanical angle calculator 140 calculates a mechanical angle ΘM0 from the received electrical angle ΘE2 and wavenumber information. As an example, in this embodiment, the mechanical angle calculator 140 converts the electrical angle of 0 to 360 degrees into the mechanical angle of 0 to 120 degrees when the wave number information indicates the first cycle of the electrical angle during one rotation of the rotating body. Since they correspond, the mechanical angle ΘM0 may be calculated from the electrical angle ΘE2. The mechanical angle calculator 140 outputs the calculated mechanical angle ΘM0 to the mechanical angle corrector 150 .

S450において、オフセット算出部360は、機械角の1周期で、電気角の複数の周期の間の移行点に対応する部分のオフセットΘMoffを算出する。オフセット算出部360は、一例として、理想機械角ΘMiと、算出した機械角ΘM0との間のオフセットΘMoffを算出する。オフセット算出部360は、算出したオフセットΘMoffを記憶部340に記憶させる。 In S450, the offset calculator 360 calculates an offset ΘMoff of a portion corresponding to a transition point between a plurality of cycles of the electrical angle in one cycle of the mechanical angle. As an example, the offset calculator 360 calculates an offset ΘMoff between the ideal mechanical angle ΘMi and the calculated mechanical angle ΘM0. The offset calculation unit 360 causes the storage unit 340 to store the calculated offset ΘMoff.

検出装置50は、少なくとも機械角1周期分の補正パラメータを算出すると、補正パラメータの算出動作を終了してよい。 When the detection device 50 calculates the correction parameters for at least one cycle of the mechanical angle, the detection device 50 may end the calculation operation of the correction parameters.

図5は、本実施形態の検出装置50における補正パラメータの算出のフローにおいて補正された角度信号の一例を示す。図5の(a)~(e)は、横軸が時間で縦軸が角度を示す。図5の(a)は、S410において算出した電気角ΘE0を実線で、参照電気角ΘErefを点線で示す。図5の(a)に示すように、モータ20の組み付け誤差等により、電気角ΘE0の1周期目、2周期目、および3周期目はそれぞれ異なる長さを有する。 FIG. 5 shows an example of the angle signal corrected in the correction parameter calculation flow in the detection device 50 of the present embodiment. In (a) to (e) of FIG. 5, the horizontal axis indicates time and the vertical axis indicates angle. In (a) of FIG. 5, the electrical angle ΘE0 calculated in S410 is indicated by a solid line, and the reference electrical angle ΘEref is indicated by a dotted line. As shown in FIG. 5A, the first, second, and third periods of the electrical angle .THETA.E0 have different lengths due to an assembly error of the motor 20 or the like.

図5の(b)は、S420において差分補正をした電気角ΘE1を実線で、差分補正前の電気角ΘE0を点線で示す。図5の(b)に示すように、差分補正部354は、各周期の傾きk0を有する直線状の参照電気角ΘEref(図5(a)の点線)との差分を、電気角ΘE0から減算しているため、差分補正後の電気角ΘE1は、参照電気角ΘErefと略同一の直線状となっている。ここで、差分算出部352は、1周期目の電気角ΘE0と参照電気角ΘEref1との差分を、2周期目の電気角ΘE0と参照電気角ΘEref2との差分を、3周期目の電気角ΘE0と参照電気角ΘEref3との差分をそれぞれ算出してよい。 FIG. 5(b) shows the electrical angle .theta.E1 after difference correction in S420 with a solid line, and the electrical angle .theta.E0 before the difference correction with a dotted line. As shown in FIG. 5B, the difference correction unit 354 subtracts the difference from the linear reference electrical angle ΘEref (dotted line in FIG. 5A) having the slope k0 of each period from the electrical angle ΘE0. Therefore, the electrical angle .theta.E1 after the difference correction is substantially the same linear shape as the reference electrical angle .theta.Eref. Here, the difference calculator 352 calculates the difference between the electrical angle ΘE0 in the first period and the reference electrical angle ΘEref1, the electrical angle ΘE0 in the second period and the electrical angle ΘEref2 in the third period, and the electrical angle ΘE0 in the third period. and the reference electrical angle ΘEref3 may be calculated.

図5の(c)は、S430において傾き補正をした電気角ΘE2を実線で、傾き補正前の電気角ΘE1を点線で示す。図5の(c)に示すように、電気角ΘE1の1周期目、2周期目、および3周期目は傾きk0が一致するように補正されている。 FIG. 5(c) shows the electrical angle .THETA.E2 corrected in S430 by a solid line, and the electrical angle .THETA.E1 before the tilt correction by a dotted line. As shown in (c) of FIG. 5, the first, second, and third cycles of the electrical angle ΘE1 are corrected so that the slopes k0 are the same.

図5の(d)は、S440において算出した1周期分の機械角ΘM0を実線で、理想機械角ΘMiを点線で示す。S430において傾き補正をしたため、算出した機械角ΘM0は、電気角の各周期の移行点に相当する位置において、理想機械角ΘMiに対してオフセットΘMoffが生じている。機械角ΘM0は、電気角の1周期目と2周期目との間の移行点に相当する位置においてオフセットΘMoff1が、電気角の2周期目と3周期目との間の移行点に相当する位置においてオフセットΘMoff2が生じている。 In (d) of FIG. 5, the mechanical angle ΘM0 for one period calculated in S440 is indicated by a solid line, and the ideal mechanical angle ΘMi is indicated by a dotted line. Since the inclination is corrected in S430, the calculated mechanical angle .THETA.M0 has an offset .THETA.Moff with respect to the ideal mechanical angle .THETA.Mi at the position corresponding to the transition point of each cycle of the electrical angle. The mechanical angle ΘM0 is at a position corresponding to the transition point between the first and second periods of the electrical angle, and the offset ΘMoff1 is at a position corresponding to the transition point between the second and third periods of the electrical angle. An offset ΘMoff2 occurs at .

図5の(e)は、S450においてオフセット補正した機械角ΘM1を実線で、オフセット補正前の機械角ΘM0を点線で示す。オフセット算出部360は、オフセットΘMoff1とオフセットΘMoff2とを、理想機械角ΘMiを基準に算出する。オフセット加算部361は、機械角ΘM0に、対応する電気角の周期のオフセットΘMoffを加算する。図5の(e)に示すように、補正後の機械角ΘM1は、理想機械角ΘMiと略同一の値を有するようになっている。 FIG. 5(e) shows the mechanical angle .THETA.M1 offset-corrected in S450 by a solid line, and the mechanical angle .THETA.M0 before offset correction by a dotted line. The offset calculator 360 calculates the offset ΘMoff1 and the offset ΘMoff2 based on the ideal mechanical angle ΘMi. The offset adder 361 adds an offset ΘMoff of the period of the corresponding electrical angle to the mechanical angle ΘM0. As shown in FIG. 5(e), the corrected mechanical angle .THETA.M1 has substantially the same value as the ideal mechanical angle .THETA.Mi.

以上のような本実施形態の検出装置50は、機械角1周期あたりでの電気角の周期性の乱れを考慮した補正パラメータを算出して、記憶することができる。 The detection device 50 of the present embodiment as described above can calculate and store a correction parameter that takes into consideration the disturbance of the periodicity of the electrical angle per mechanical angle cycle.

図6は、本実施形態の検出装置50における実際の検出動作のフローを示す。なお、図6のS600,S610,およびS630は、図4のS400、S410、およびS440の処理とそれぞれ同様であるため、詳細な説明は省略する。 FIG. 6 shows the flow of the actual detection operation in the detection device 50 of this embodiment. Note that S600, S610, and S630 of FIG. 6 are the same as the processing of S400, S410, and S440 of FIG. 4, respectively, so detailed description thereof will be omitted.

S620において、電気角補正部130は、電気角ΘE0の補正を行う。差分補正部354は、検出動作前、例えば検出装置50の電源がオンされた際等に記憶部340から補正係数を読み出し、補正係数を適用した逆フーリエ関数で差分を導出して、機械角1周期分の差分を差分補正部354内に記憶してよい。差分補正部354は、電気角算出部120により算出した電気角ΘE0から、当該電気角ΘE0に対応する時点の差分を減算して補正してよい。差分補正部354は、補正後の電気角ΘE1を傾き補正部355に出力する。 In S620, the electrical angle correction unit 130 corrects the electrical angle ΘE0. The difference correction unit 354 reads the correction coefficient from the storage unit 340 before the detection operation, for example, when the power of the detection device 50 is turned on, derives the difference by the inverse Fourier function to which the correction coefficient is applied, and calculates the mechanical angle 1 A period's difference may be stored in the difference correction unit 354 . The difference corrector 354 may correct the electrical angle ΘE0 calculated by the electrical angle calculator 120 by subtracting the difference at the time corresponding to the electrical angle ΘE0. The difference corrector 354 outputs the corrected electrical angle ΘE1 to the tilt corrector 355 .

傾き補正部355は、検出動作前、例えば検出装置50の電源がオンされた際等に、記憶部340から機械角1周期分の補正パラメータを読み出してよい。傾き補正部355は、補正パラメータの算出動作における傾き補正前後の電気角の差分を記憶部340から読み出してよい。また、傾き補正部355は、記憶部340から電気角ΘE1の各周期に対応する傾きk0を読み出し、当該傾きk0から傾き補正前後の電気角の差分を導出してもよい。例えば、傾き補正部355は、原点が同じである、傾きk0の直線と傾き1の直線との間の各時点での差分を求めてよい。そして、傾き補正部355は、検出動作において、補正パラメータである差分を電気角ΘE1に適用(例えば加算)してよい。また、傾き補正部355は、補正パラメータの算出動作のフローにおけるS430と同様に、電気角ΘE1を補正してもよい。 The tilt correction unit 355 may read correction parameters for one cycle of the mechanical angle from the storage unit 340 before the detection operation, for example, when the power of the detection device 50 is turned on. The tilt correction unit 355 may read out from the storage unit 340 the difference in electrical angle before and after the tilt correction in the correction parameter calculation operation. Further, the tilt correction unit 355 may read the tilt k0 corresponding to each cycle of the electrical angle ΘE1 from the storage unit 340, and derive the difference between the electrical angles before and after the tilt correction from the tilt k0. For example, the tilt correction unit 355 may obtain the difference at each point between a straight line with a slope of k0 and a straight line with a slope of 1, which have the same origin. Then, the tilt corrector 355 may apply (for example, add) the difference, which is a correction parameter, to the electrical angle ΘE1 in the detection operation. In addition, the inclination correction unit 355 may correct the electrical angle ΘE1 in the same manner as S430 in the correction parameter calculation operation flow.

S640において、オフセット加算部361は、機械角ΘM0のオフセット補正を行う。オフセット加算部361は、検出動作前、例えば検出装置50の電源がオンされた際等に記憶部340から機械角1周期分の機械角ΘM0のオフセットΘMoffを読み出し、当該オフセットΘMoffをオフセット加算部361内に記憶してよい。オフセット加算部361は、機械角算出部140により算出した機械角ΘM0から、当該機械角ΘM0に対応するオフセットΘMoffを減算して補正してよい。例えば、オフセット加算部361は、電気角の2周期目に対応する機械角ΘM0に対しては、図5の(d)に示すオフセットΘMoff1を用い、電気角の3周期目に対応する機械角ΘM0に対しては、図5の(d)に示すオフセットΘMoff2を用いてオフセット補正してよい。 In S640, the offset adder 361 performs offset correction of the mechanical angle ΘM0. The offset adder 361 reads the offset ΘMoff of the mechanical angle ΘM0 for one cycle of the mechanical angle from the storage 340 before the detection operation, for example, when the power of the detector 50 is turned on. can be stored inside. The offset adder 361 may correct the mechanical angle ΘM0 calculated by the mechanical angle calculator 140 by subtracting the offset ΘMoff corresponding to the mechanical angle ΘM0. For example, the offset adder 361 uses the offset ΘMoff1 shown in FIG. may be offset-corrected using the offset ΘMoff2 shown in FIG. 5(d).

S650において、オフセット加算部361は、補正した機械角の角度信号ΘM1を出力端子OUTから出力する。これにより、例えばモータ制御回路60は、検出装置50の出力端子OUTから出力された角度信号ΘM1に応じてモータ20の回転を制御することができる。 In S650, the offset adding section 361 outputs the angle signal ΘM1 of the corrected mechanical angle from the output terminal OUT. Thereby, for example, the motor control circuit 60 can control the rotation of the motor 20 in accordance with the angle signal ΘM1 output from the output terminal OUT of the detection device 50 .

以上のような本実施形態の検出装置50の検出動作により、検出した角度信号に対して電気角の周期性の乱れを考慮した補正を実行でき、精度のよい角度信号を出力できる。 With the detection operation of the detection device 50 of the present embodiment as described above, it is possible to correct the detected angle signal in consideration of the disturbance of the periodicity of the electrical angle, and to output the angle signal with high accuracy.

図7は、他の実施形態の検出装置50における補正パラメータの算出のフローにおいて補正された角度信号の一例を示す。図7の実施形態は、電気角に対しては補正を行わず、機械角に対して補正を行う。 FIG. 7 shows an example of the angle signal corrected in the correction parameter calculation flow in the detection device 50 of another embodiment. The embodiment of FIG. 7 does not correct for the electrical angle, but corrects for the mechanical angle.

図7の(a)は、検出装置50により検出した磁場データから算出した電気角を示す。図7の(a)に示すように、検出された電気角の1周期目、2周期目、および3周期目はそれぞれ異なる長さを有する。 (a) of FIG. 7 shows the electrical angle calculated from the magnetic field data detected by the detector 50 . As shown in FIG. 7A, the first, second, and third cycles of the detected electrical angle have different lengths.

図7の(b)は、検出装置50により図7(a)の電気角から算出した1周期分の機械角を実線で、参照機械角ΘMrefを点線で示す。図7の(b)に示すように、電気角に対して補正を行っていないため、電気角の誤差が機械角に残存している。 FIG. 7(b) shows the mechanical angle for one cycle calculated from the electrical angle of FIG. 7(a) by the detecting device 50 with a solid line, and the reference mechanical angle ΘMref with a dotted line. As shown in FIG. 7B, since the electrical angle is not corrected, the electrical angle error remains in the mechanical angle.

図7の(c)は、差分補正をした機械角を実線で、差分補正前の機械角を点線で示す。検出装置50は、機械角について、電気角の各周期に対応する部分毎に異なる傾きを用いて補正を行ってよい。検出装置50は、例えば、機械角について、電気角の各周期に対応する部分毎に始点と終点を結ぶ直線の傾きを求め、当該傾きを有する参照機械角ΘMrefと、算出した機械角との間の差分を算出してよい。検出装置50は、電気角の1周期目に対応する機械角に対しては参照機械角ΘMref1を、電気角の2周期目に対応する機械角に対しては参照機械角ΘMref2を、電気角の3周期目に対応する機械角に対しては参照機械角ΘMref3を用いて差分を算出してよい。 In (c) of FIG. 7, the mechanical angle after the difference correction is indicated by a solid line, and the mechanical angle before the difference correction is indicated by a dotted line. The detection device 50 may correct the mechanical angle using a different inclination for each portion corresponding to each cycle of the electrical angle. For example, the detection device 50 obtains the slope of a straight line connecting the start point and the end point for each portion corresponding to each cycle of the electrical angle, and calculates the relationship between the reference mechanical angle ΘMref having the slope and the calculated mechanical angle. can be calculated. The detection device 50 calculates a reference mechanical angle ΘMref1 for the mechanical angle corresponding to the first cycle of the electrical angle, a reference mechanical angle ΘMref2 for the mechanical angle corresponding to the second cycle of the electrical angle, and a reference mechanical angle ΘMref2 for the mechanical angle corresponding to the second cycle of the electrical angle. The difference may be calculated using the reference mechanical angle ΘMref3 for the mechanical angle corresponding to the third cycle.

検出装置50は、S420と同様に、参照機械角ΘMrefと算出した機械角との間の差分をフーリエ級数展開して補正係数を算出し、補正係数を記憶部340に記憶させてよい。検出装置50は、S420と同様に、記憶部340から読み出した補正係数を適用した逆フーリエ関数から差分を導出し、機械角から差分を減算して補正してよい。図7の(c)に示すように、差分補正後の機械角は、参照機械角ΘMrefと同様に直線状となっているが、電気角の各周期に対応する部分毎に傾きが異なる。 The detection device 50 may perform Fourier series expansion on the difference between the reference mechanical angle ΘMref and the calculated mechanical angle to calculate a correction coefficient, and store the correction coefficient in the storage unit 340, as in S420. The detection device 50 may derive the difference from the inverse Fourier function to which the correction coefficient read from the storage unit 340 is applied, and subtract the difference from the mechanical angle for correction, as in S420. As shown in (c) of FIG. 7, the mechanical angle after the difference correction is linear like the reference mechanical angle ΘMref, but the inclination differs for each portion corresponding to each cycle of the electrical angle.

図7の(d)は、傾き補正した機械角を実線で、理想機械角ΘMiを点線で示す。検出装置50は、機械角について、電気角の各周期に対応する部分毎に傾き補正を行ってよい。検出装置50は、一例として、電気角の各周期に対応する部分毎に算出した傾きに、当該傾きの逆数を乗算することにより、電気角の複数の周期に対応する機械角の複数の傾きを一致させる。図7の(d)に示すように、傾きを補正したため、機械角において、電気角の複数の周期の間の移行点に対応する部分で理想機械角ΘMiに対してオフセットΘMoff1およびΘMoff2が生じる。 In (d) of FIG. 7, the tilt-corrected mechanical angle is indicated by a solid line, and the ideal mechanical angle ΘMi is indicated by a dotted line. The detection device 50 may correct the inclination of the mechanical angle for each portion corresponding to each period of the electrical angle. As an example, the detection device 50 multiplies the slope calculated for each portion corresponding to each cycle of the electrical angle by the reciprocal of the slope, thereby obtaining a plurality of slopes of the mechanical angle corresponding to a plurality of cycles of the electrical angle. match. As shown in FIG. 7(d), since the tilt is corrected, offsets ΘMoff1 and ΘMoff2 are generated with respect to the ideal mechanical angle ΘMi at portions corresponding to transition points between a plurality of cycles of the electrical angle.

図7の(e)は、オフセット補正した機械角を実線で、オフセット補正前の機械角を点線で示す。図7の(e)におけるオフセット補正は、S450およびS640と同様の処理であるため、詳細な説明は省略する。 (e) of FIG. 7 shows the offset-corrected mechanical angle with a solid line, and the mechanical angle before the offset correction with a dotted line. Since the offset correction in (e) of FIG. 7 is the same processing as S450 and S640, detailed description thereof will be omitted.

以上のような本実施形態の検出装置50により、電気角の周期性の乱れを考慮して精度よく機械角を補正できる補正パラメータを得ることができる。検出装置50は、本実施形態で算出した機械角に対する補正パラメータを、実際の検出動作において、図6における電気角および機械角に対する補正と同様に適用することができる。 With the detecting device 50 of the present embodiment as described above, it is possible to obtain a correction parameter capable of accurately correcting the mechanical angle in consideration of the disturbance of the periodicity of the electrical angle. The detection device 50 can apply the correction parameter for the mechanical angle calculated in this embodiment to the actual detection operation in the same manner as the correction for the electrical angle and the mechanical angle in FIG.

なお、本実施形態の検出装置50は、補正パラメータの算出に用いられる、傾き算出部350、直線生成部351、差分算出部352、係数算出部353、およびオフセット算出部360の少なくとも1つを有さなくてもよい。検出装置50は、予めマイクロコンピュータ等の外部の装置で算出した補正パラメータを記憶部340に記憶しておき、実際の検出動作において、記憶した補正パラメータを用いて角度信号を補正してよい。 Note that the detection device 50 of the present embodiment includes at least one of the inclination calculator 350, the straight line generator 351, the difference calculator 352, the coefficient calculator 353, and the offset calculator 360, which are used to calculate the correction parameters. You don't have to. The detection device 50 may store correction parameters calculated in advance by an external device such as a microcomputer in the storage unit 340, and correct the angle signal using the stored correction parameters in an actual detection operation.

また、本実施形態の検出装置50は、第1比較器300、第2比較器310、およびカウンタ320を有さなくてもよい。この場合、検出装置50は、同じ検出対象の回転体の回転角度を検出するために併設された他の検出装置から回転角度等の情報を受け取り、当該情報から波数情報を得てよい。 Also, the detection device 50 of this embodiment may not have the first comparator 300 , the second comparator 310 and the counter 320 . In this case, the detection device 50 may receive information such as the rotation angle from another detection device provided to detect the rotation angle of the same detection target rotating body, and obtain the wave number information from the information.

また、本実施形態の検出装置50は、傾き補正およびオフセット補正の少なくとも一方は必須では無く、傾き補正部355、オフセット算出部360、およびオフセット加算部361のうちの少なくとも1つを有さなくてもよい。また、本実施形態の検出装置50は、差分補正部354による補正と傾き補正部355による補正の順序を入れ替えてもよい。 At least one of tilt correction and offset correction is not essential for the detection device 50 of the present embodiment, and at least one of the tilt correction unit 355, the offset calculation unit 360, and the offset addition unit 361 is not provided. good too. Further, the detection device 50 of this embodiment may change the order of the correction by the difference correction unit 354 and the correction by the tilt correction unit 355 .

また、図3に示す検出装置50は、オフセット/ゲイン/位相算出部339、傾き算出部350、直線生成部351、差分算出部352、係数算出部353、およびオフセット算出部360を含む補正パラメータ算出用ブロックを有さなくてもよい。補正パラメータ算出用ブロックは、検出装置50とは別の算出装置として構成されてよい。 3 includes an offset/gain/phase calculator 339, a slope calculator 350, a straight line generator 351, a difference calculator 352, a coefficient calculator 353 and an offset calculator 360. It is not necessary to have a block for The correction parameter calculation block may be configured as a calculation device separate from the detection device 50 .

算出装置は、検出装置50の検出したデータを受け取ってよく、当該データに基づいて、回転体の1回転あたり複数の周期を有する電気角を示す角度信号を補正する補正パラメータを算出する。算出装置は、オフセット/ゲイン/位相算出部339、傾き算出部350、直線生成部351、差分算出部352、係数算出部353、およびオフセット算出部360を備える。これらの構成は、検出装置50の構成と同様に機能してよい。算出装置は、算出した補正パラメータを出力して、検出装置50の記憶部340に記憶させてよい。補正パラメータは、検出装置50の量産出荷時の初期調整に用いられてよい。 The calculation device may receive data detected by the detection device 50, and based on the data, calculate a correction parameter for correcting an angle signal indicating an electrical angle having a plurality of cycles per rotation of the rotating body. The calculator includes an offset/gain/phase calculator 339 , a slope calculator 350 , a straight line generator 351 , a difference calculator 352 , a coefficient calculator 353 and an offset calculator 360 . These configurations may function similarly to the configuration of detection device 50 . The calculation device may output the calculated correction parameters and store them in the storage unit 340 of the detection device 50 . The correction parameters may be used for initial adjustment at the time of shipment of mass production of the detection device 50 .

図8は、本実施形態に係る検出装置50の他の構成を示す。図8の検出装置50は、図3の検出装置50の構成と同一の構成を有し、ただし第1比較器300および第2比較器310は、信号調整部330の出力にそれぞれ接続される。 FIG. 8 shows another configuration of the detection device 50 according to this embodiment. The detection device 50 of FIG. 8 has the same configuration as the detection device 50 of FIG.

第1比較器300および第2比較器310は、信号調整部330の位相調整部337、338にそれぞれ接続され、位相調整部337、338からの信号A、Bを閾値とそれぞれ比較して、比較結果を示すパルス信号を出力してよい。 The first comparator 300 and the second comparator 310 are connected to the phase adjusters 337 and 338 of the signal adjuster 330, respectively, and compare the signals A and B from the phase adjusters 337 and 338 with the threshold values to obtain a comparison result. A pulse signal indicating the result may be output.

図9は、本発明の複数の態様が全体的または部分的に具現化されてよいコンピュータ1900の例を示す。コンピュータ1900にインストールされたプログラムは、コンピュータ1900に、本発明の実施形態に係る装置に関連付けられる操作または当該装置の1または複数のセクションとして機能させることができ、または当該操作または当該1または複数のセクションを実行させることができ、および/またはコンピュータ1900に、本発明の実施形態に係るプロセスまたは当該プロセスの段階を実行させることができる。そのようなプログラムは、コンピュータ1900に、本明細書に記載のフローチャートおよびブロック図のブロックのうちのいくつかまたはすべてに関連付けられた特定の操作を実行させるべく、CPU2000によって実行されてよい。 FIG. 9 illustrates an example computer 1900 upon which aspects of the invention may be implemented in whole or in part. Programs installed on the computer 1900 may cause the computer 1900 to function as one or more sections of an operation or apparatus associated with an apparatus according to embodiments of the invention, or may Sections may be executed and/or computer 1900 may be caused to execute processes or steps of such processes according to embodiments of the present invention. Such programs may be executed by CPU 2000 to cause computer 1900 to perform certain operations associated with some or all of the blocks in the flowcharts and block diagrams described herein.

本実施形態に係るコンピュータ1900は、ホスト・コントローラ2082により相互に接続されるCPU2000、RAM2020、グラフィック・コントローラ2075、及び表示装置2080を有するCPU周辺部と、入出力コントローラ2084によりホスト・コントローラ2082に接続される通信インターフェイス2030、ハードディスクドライブ2040、及びDVDドライブ2060を有する入出力部と、入出力コントローラ2084に接続されるROM2010、フラッシュメモリ・ドライブ2050、及び入出力チップ2070を有するレガシー入出力部を備える。 The computer 1900 according to the present embodiment includes a CPU peripheral section having a CPU 2000, a RAM 2020, a graphic controller 2075, and a display device 2080, which are interconnected by a host controller 2082, and an input/output controller 2084, which is connected to the host controller 2082. and a legacy input/output unit having a ROM 2010, a flash memory drive 2050, and an input/output chip 2070 connected to an input/output controller 2084. .

ホスト・コントローラ2082は、RAM2020と、高い転送レートでRAM2020をアクセスするCPU2000及びグラフィック・コントローラ2075とを接続する。CPU2000は、ROM2010及びRAM2020に格納されたプログラムに基づいて動作し、各部の制御を行う。グラフィック・コントローラ2075は、CPU2000等がRAM2020内に設けたフレーム・バッファ上に生成する画像データを取得し、表示装置2080上に表示させる。これに代えて、グラフィック・コントローラ2075は、CPU2000等が生成する画像データを格納するフレーム・バッファを、内部に含んでもよい。 Host controller 2082 connects RAM 2020 to CPU 2000 and graphics controller 2075 that access RAM 2020 at a high transfer rate. The CPU 2000 operates based on programs stored in the ROM 2010 and RAM 2020, and controls each section. The graphic controller 2075 acquires image data generated by the CPU 2000 or the like on a frame buffer provided in the RAM 2020 and displays it on the display device 2080 . Alternatively, the graphics controller 2075 may internally include a frame buffer for storing image data generated by the CPU 2000 or the like.

入出力コントローラ2084は、ホスト・コントローラ2082と、比較的高速な入出力装置である通信インターフェイス2030、ハードディスクドライブ2040、DVDドライブ2060を接続する。通信インターフェイス2030は、有線又は無線によりネットワークを介して他の装置と通信する。また、通信インターフェイスは、通信を行うハードウェアとして機能する。ハードディスクドライブ2040は、コンピュータ1900内のCPU2000が使用するプログラム及びデータを格納する。DVDドライブ2060は、DVD2095からプログラム又はデータを読み取り、RAM2020を介してハードディスクドライブ2040に提供する。 The input/output controller 2084 connects the host controller 2082 with the communication interface 2030, hard disk drive 2040, and DVD drive 2060, which are relatively high-speed input/output devices. Communication interface 2030 communicates with other devices via a network by wire or wirelessly. Also, the communication interface functions as hardware for communication. Hard disk drive 2040 stores programs and data used by CPU 2000 in computer 1900 . DVD drive 2060 reads programs or data from DVD 2095 and provides them to hard disk drive 2040 via RAM 2020 .

また、入出力コントローラ2084には、ROM2010と、フラッシュメモリ・ドライブ2050、及び入出力チップ2070の比較的低速な入出力装置とが接続される。ROM2010は、コンピュータ1900が起動時に実行するブート・プログラム、及び/又は、コンピュータ1900のハードウェアに依存するプログラム等を格納する。フラッシュメモリ・ドライブ2050は、フラッシュメモリ2090からプログラム又はデータを読み取り、RAM2020を介してハードディスクドライブ2040に提供する。入出力チップ2070は、フラッシュメモリ・ドライブ2050を入出力コントローラ2084へと接続するとともに、例えばパラレル・ポート、シリアル・ポート、キーボード・ポート、マウス・ポート等を介して各種の入出力装置を入出力コントローラ2084へと接続する。 The I/O controller 2084 is also connected to the ROM 2010 , the flash memory drive 2050 and the I/O chip 2070 , which are relatively low-speed I/O devices. The ROM 2010 stores a boot program executed by the computer 1900 at startup and/or a program depending on the hardware of the computer 1900, and the like. Flash memory drive 2050 reads programs or data from flash memory 2090 and provides them to hard disk drive 2040 via RAM 2020 . The input/output chip 2070 connects the flash memory drive 2050 to the input/output controller 2084 and inputs/outputs various input/output devices via, for example, parallel ports, serial ports, keyboard ports, mouse ports, and the like. Connect to controller 2084 .

RAM2020を介してハードディスクドライブ2040に提供されるプログラムは、フラッシュメモリ2090、DVD2095、又はICカード等の記録媒体に格納されて利用者によって提供される。プログラムは、記録媒体から読み出され、RAM2020を介してコンピュータ1900内のハードディスクドライブ2040にインストールされ、CPU2000において実行される。これらのプログラム内に記述される情報処理は、コンピュータ1900に読み取られ、ソフトウェアと、上記様々なタイプのハードウェア資源との間の協働をもたらす。装置または方法が、コンピュータ1900の使用に従い情報の操作または処理を実現することによって構成されてよい。 A program provided to the hard disk drive 2040 via the RAM 2020 is stored in a recording medium such as the flash memory 2090, DVD 2095, or IC card and provided by the user. The program is read from the recording medium, installed in hard disk drive 2040 in computer 1900 via RAM 2020, and executed in CPU 2000. FIG. The information processing described in these programs is read by computer 1900 and provides cooperation between the software and the various types of hardware resources described above. An apparatus or method may be configured by implementing the manipulation or processing of information in accordance with the use of computer 1900 .

一例として、コンピュータ1900と外部の装置等との間で通信を行う場合には、CPU2000は、RAM2020上にロードされた通信プログラムを実行し、通信プログラムに記述された処理内容に基づいて、通信インターフェイス2030に対して通信処理を指示する。通信インターフェイス2030は、CPU2000の制御を受けて、RAM2020、ハードディスクドライブ2040、フラッシュメモリ2090、又はDVD2095等の記憶装置上に設けた送信バッファ領域等に記憶された送信データを読み出してネットワークへと送信し、もしくは、ネットワークから受信した受信データを記憶装置上に設けた受信バッファ領域等へと書き込む。このように、通信インターフェイス2030は、DMA(ダイレクト・メモリ・アクセス)方式により記憶装置との間で送受信データを転送してもよく、これに代えて、CPU2000が転送元の記憶装置又は通信インターフェイス2030からデータを読み出し、転送先の通信インターフェイス2030又は記憶装置へとデータを書き込むことにより送受信データを転送してもよい。 As an example, when communicating between the computer 1900 and an external device or the like, the CPU 2000 executes a communication program loaded on the RAM 2020, and based on the processing content described in the communication program, the communication interface. 2030 is instructed to perform communication processing. Under the control of the CPU 2000, the communication interface 2030 reads transmission data stored in a transmission buffer area or the like provided on a storage device such as the RAM 2020, the hard disk drive 2040, the flash memory 2090, or the DVD 2095, and transmits the transmission data to the network. Alternatively, the received data received from the network is written into a receive buffer area or the like provided on the storage device. In this way, the communication interface 2030 may transfer data to and from a storage device using a DMA (direct memory access) method. The transmission/reception data may be transferred by reading the data from and writing the data to the communication interface 2030 or storage device of the transfer destination.

また、CPU2000は、ハードディスクドライブ2040、DVDドライブ2060(DVD2095)、フラッシュメモリ・ドライブ2050(フラッシュメモリ2090)等の外部記憶装置に格納されたファイルまたはデータベース等の中から、全部または必要な部分をDMA転送等によりRAM2020へと読み込ませ、RAM2020上のデータに対して各種の処理を行う。そして、CPU2000は、処理を終えたデータを、DMA転送等により外部記憶装置へと書き戻す。このような処理において、RAM2020は、外部記憶装置の内容を一時的に保持するものとみなせるから、本実施形態においてはRAM2020及び外部記憶装置等をメモリ、記憶部、または記憶装置等と総称する。 The CPU 2000 also DMAs all or necessary portions of files or databases stored in external storage devices such as the hard disk drive 2040, DVD drive 2060 (DVD 2095), and flash memory drive 2050 (flash memory 2090). The data is read into the RAM 2020 by transfer or the like, and various processes are performed on the data on the RAM 2020 . Then, the CPU 2000 writes the processed data back to the external storage device by DMA transfer or the like. In such processing, the RAM 2020 can be regarded as temporarily holding the contents of the external storage device. Therefore, in this embodiment, the RAM 2020 and the external storage device are collectively referred to as a memory, a storage unit, or a storage device.

本実施形態における各種のプログラム、データ、テーブル、データベース等の各種の情報は、このような記憶装置上に格納されて、情報処理の対象となる。なお、CPU2000は、RAM2020の一部をキャッシュメモリに保持し、キャッシュメモリ上で読み書きを行うこともできる。このような形態においても、キャッシュメモリはRAM2020の機能の一部を担うから、本実施形態においては、区別して示す場合を除き、キャッシュメモリもRAM2020、メモリ、及び/又は記憶装置に含まれるものとする。 Various kinds of information such as various programs, data, tables, databases, etc. in this embodiment are stored in such a storage device, and are subject to information processing. Note that the CPU 2000 can also hold part of the RAM 2020 in cache memory and perform reading and writing on the cache memory. Even in such a form, the cache memory is responsible for part of the functions of the RAM 2020, so in this embodiment, unless otherwise indicated, the cache memory is also included in the RAM 2020, memory, and/or storage device. do.

また、CPU2000は、RAM2020から読み出したデータに対して、プログラムの命令列により指定された、本実施形態中に記載した各種の演算、情報の加工、条件判断、情報の検索・置換等を含む各種の処理を行い、RAM2020へと書き戻す。例えば、CPU2000は、条件判断を行う場合においては、本実施形態において示した各種の変数が、他の変数または定数と比較して、大きい、小さい、以上、以下、等しい等の条件を満たすか否かを判断し、条件が成立した場合(又は不成立であった場合)に、異なる命令列へと分岐し、またはサブルーチンを呼び出す。 In addition, the CPU 2000 performs various operations, including various calculations, information processing, condition determination, information search/replacement, etc., which are specified by the instruction sequence of the program, on the data read from the RAM 2020, and which are described in the present embodiment. and write it back to the RAM 2020 . For example, when performing conditional judgment, the CPU 2000 compares the various variables shown in this embodiment with other variables or constants to determine whether or not the conditions such as greater, lesser, greater than, less than or equal to are satisfied. If the condition is satisfied (or not satisfied), branch to a different instruction sequence or call a subroutine.

また、CPU2000は、記憶装置内のファイルまたはデータベース等に格納された情報を検索することができる。例えば、第1属性の属性値に対し第2属性の属性値がそれぞれ対応付けられた複数のエントリが記憶装置に格納されている場合において、CPU2000は、記憶装置に格納されている複数のエントリの中から第1属性の属性値が指定された条件と一致するエントリを検索し、そのエントリに格納されている第2属性の属性値を読み出すことにより、所定の条件を満たす第1属性に対応付けられた第2属性の属性値を得ることができる。 The CPU 2000 can also search for information stored in a file, database, or the like in the storage device. For example, when a plurality of entries in which attribute values of a first attribute are respectively associated with attribute values of a second attribute are stored in the storage device, the CPU 2000 performs processing of the plurality of entries stored in the storage device. An entry whose attribute value of the first attribute matches the specified condition is searched from among the entries, and the attribute value of the second attribute stored in that entry is read out to associate it with the first attribute that satisfies the predetermined condition. It is possible to obtain the attribute value of the given second attribute.

また、実施形態の説明において複数の要素が列挙された場合には、列挙された要素以外の要素を用いてもよい。例えば、「Xは、A、B及びCを用いてYを実行する」と記載される場合、Xは、A、B及びCに加え、Dを用いてYを実行してもよい。 Also, when a plurality of elements are listed in the description of the embodiment, elements other than the listed elements may be used. For example, when it is stated that "X performs Y using A, B and C," X may perform Y using D in addition to A, B and C.

以上、本発明を実施の形態を用いて説明したが、本発明の技術的範囲は上記実施の形態に記載の範囲には限定されない。上記実施の形態に、多様な変更または改良を加えることが可能であることが当業者に明らかである。その様な変更または改良を加えた形態も本発明の技術的範囲に含まれ得ることが、特許請求の範囲の記載から明らかである。 Although the present invention has been described above using the embodiments, the technical scope of the present invention is not limited to the scope described in the above embodiments. It is obvious to those skilled in the art that various modifications and improvements can be made to the above embodiments. It is clear from the description of the scope of claims that forms with such modifications or improvements can also be included in the technical scope of the present invention.

特許請求の範囲、明細書、および図面中において示した装置、システム10、プログラム、および方法における動作、手順、ステップ、および段階等の各処理の実行順序は、特段「より前に」、「先立って」等と明示しておらず、また、前の処理の出力を後の処理で用いるのでない限り、任意の順序で実現しうることに留意すべきである。特許請求の範囲、明細書、および図面中の動作フローに関して、便宜上「まず、」、「次に、」等を用いて説明したとしても、この順で実施することが必須であることを意味するものではない。 The execution order of each process such as actions, procedures, steps, and stages in the device, system 10, program, and method shown in the claims, the specification, and the drawings is particularly "before", "before", and "before". It should be noted that it can be implemented in any order unless it is expressly stated as such and the output of a previous process is used in a later process. Regarding the operation flow in the claims, the specification, and the drawings, even if the description is made using "first," "next," etc. for the sake of convenience, it means that it is essential to carry out in this order. not a thing

10 システム
20 モータ
30 第1磁場センサ
40 第2磁場センサ
50 検出装置
60 モータ制御回路
100 第1取得部
110 第2取得部
120 電気角算出部
130 電気角補正部
140 機械角算出部
150 機械角補正部
300 第1比較器
310 第2比較器
320 カウンタ
330 信号調整部
331,332 アナログデジタルコンバータ
333,334 オフセット調整部
335,336 ゲイン調整部
337,338 位相調整部
339 オフセット/ゲイン/位相算出部
340 記憶部
350 傾き算出部
351 直線生成部
352 差分算出部
353 係数算出部
354 差分補正部
355 傾き補正部
360 オフセット算出部
361 オフセット加算部
1900 コンピュータ
2000 CPU
2010 ROM
2020 RAM
2030 通信インターフェイス
2040 ハードディスクドライブ
2050 フラッシュメモリ・ドライブ
2060 DVDドライブ
2070 入出力チップ
2075 グラフィック・コントローラ
2080 表示装置
2082 ホスト・コントローラ
2084 入出力コントローラ
2090 フラッシュメモリ
2095 DVD
10 system 20 motor 30 first magnetic field sensor 40 second magnetic field sensor 50 detection device 60 motor control circuit 100 first acquisition unit 110 second acquisition unit 120 electrical angle calculation unit 130 electrical angle correction unit 140 mechanical angle calculation unit 150 mechanical angle correction Section 300 First Comparator 310 Second Comparator 320 Counter 330 Signal Adjustment Sections 331 and 332 Analog-to-Digital Converters 333 and 334 Offset Adjustment Sections 335 and 336 Gain Adjustment Sections 337 and 338 Phase Adjustment Section 339 Offset/Gain/Phase Calculation Section 340 Storage unit 350 Inclination calculation unit 351 Straight line generation unit 352 Difference calculation unit 353 Coefficient calculation unit 354 Difference correction unit 355 Inclination correction unit 360 Offset calculation unit 361 Offset addition unit 1900 Computer 2000 CPU
2010 ROM
2020 RAM
2030 communication interface 2040 hard disk drive 2050 flash memory drive 2060 DVD drive 2070 input/output chip 2075 graphic controller 2080 display device 2082 host controller 2084 input/output controller 2090 flash memory 2095 DVD

Claims (8)

回転体の回転角度を検出する検出装置であって、
前記回転体の回転に応じて変化する第1磁場データを取得する第1取得部と、
前記回転体の回転に応じて前記第1磁場データとは異なる位相で変化する第2磁場データを取得する第2取得部と、
前記第1磁場データおよび前記第2磁場データに基づいて、前記回転体の1回転あたり複数の周期を有する電気角を示す角度信号を出力する角度算出部と、
前記角度信号を、前記複数の周期のうちの少なくとも1つの周期の前記電気角を近似した直線の傾きである前記角度信号の傾きを用いて補正する補正部と
を備え、
前記補正部は、前記角度信号の前記複数の周期の移行点におけるオフセットを、前記角度信号に加算するオフセット加算部を有し、
前記補正部は、前記角度信号を、前記回転体の1回転中の各電気角が前記複数の周期のいずれに位置するかに応じて、異なる前記角度信号の傾きを用いて補正する
検出装置。
A detection device for detecting the rotation angle of a rotating body,
a first acquisition unit that acquires first magnetic field data that changes according to the rotation of the rotating body;
a second acquisition unit that acquires second magnetic field data that changes in a phase different from that of the first magnetic field data according to the rotation of the rotating body;
an angle calculation unit that outputs an angle signal indicating an electrical angle having a plurality of cycles per rotation of the rotating body based on the first magnetic field data and the second magnetic field data;
a correction unit that corrects the angle signal using the slope of the angle signal, which is the slope of a straight line approximating the electrical angle of at least one cycle of the plurality of cycles;
The correction unit has an offset addition unit that adds an offset at transition points of the plurality of cycles of the angle signal to the angle signal,
The correction unit corrects the angle signal using different inclinations of the angle signal according to which of the plurality of cycles each electrical angle during one rotation of the rotating body is positioned.
回転体の回転角度を検出する検出装置であって、
前記回転体の回転に応じて変化する第1磁場データを取得する第1取得部と、
前記回転体の回転に応じて前記第1磁場データとは異なる位相で変化する第2磁場データを取得する第2取得部と、
前記第1磁場データおよび前記第2磁場データに基づいて、前記回転体の1回転あたり複数の周期を有する電気角を示す角度信号を出力する角度算出部と、
前記角度信号を、前記複数の周期のうちの少なくとも1つの周期の前記電気角を近似した直線の傾きである前記角度信号の傾きを用いて補正する補正部と
を備え、
前記補正部は、前記複数の周期のうちの少なくとも1つの周期の前記角度信号の傾きを算出する傾き算出部を有し、
前記補正部は、前記角度信号を、前記回転体の1回転中の各電気角が前記複数の周期のいずれに位置するかに応じて、異なる前記角度信号の傾きを用いて補正する
検出装置。
A detection device for detecting the rotation angle of a rotating body,
a first acquisition unit that acquires first magnetic field data that changes according to the rotation of the rotating body;
a second acquisition unit that acquires second magnetic field data that changes in a phase different from that of the first magnetic field data according to the rotation of the rotating body;
an angle calculation unit that outputs an angle signal indicating an electrical angle having a plurality of cycles per rotation of the rotating body based on the first magnetic field data and the second magnetic field data;
a correction unit that corrects the angle signal using the slope of the angle signal, which is the slope of a straight line approximating the electrical angle of at least one cycle of the plurality of cycles;
The correction unit has a slope calculation unit that calculates a slope of the angle signal in at least one of the plurality of cycles,
The correction unit corrects the angle signal using different inclinations of the angle signal according to which of the plurality of cycles each electrical angle in one rotation of the rotating body is positioned.
前記補正部は、
前記回転体の1回転あたり前記複数の周期の前記角度信号の傾きを一致させる傾き補正部と、
前記傾きを一致させた前記角度信号の複数の周期の移行点における前記オフセットを算出するオフセット算出部とを有する
請求項に記載の検出装置。
The correction unit is
a tilt correction unit that matches the tilts of the angle signals of the plurality of cycles per rotation of the rotating body;
2. The detection device according to claim 1 , further comprising an offset calculation unit that calculates the offsets at transition points of a plurality of cycles of the angle signal with the slopes matched.
回転体の回転角度を検出する方法であって、
前記回転体の回転に応じて変化する第1磁場データを取得する段階と、
前記回転体の回転に応じて前記第1磁場データとは異なる位相で変化する第2磁場データを取得する段階と、
前記第1磁場データおよび前記第2磁場データに基づいて、前記回転体の1回転あたり複数の周期を有する電気角を示す角度信号を出力する段階と、
前記角度信号を、前記複数の周期のうちの少なくとも1つの周期の前記電気角を近似した直線の傾きである前記角度信号の傾きを用いて補正する段階と
を備え、
前記補正する段階は、
前記角度信号の前記複数の周期の移行点におけるオフセットを、前記角度信号に加算する段階と、
前記角度信号を、前記回転体の1回転中の各電気角が前記複数の周期のいずれに位置するかに応じて、異なる前記角度信号の傾きを用いて補正する段階と、を有する
方法。
A method for detecting the rotation angle of a rotating body, comprising:
obtaining first magnetic field data that varies according to the rotation of the body of rotation;
acquiring second magnetic field data that changes in phase different from the first magnetic field data according to the rotation of the rotating body;
outputting an angle signal indicating an electrical angle having a plurality of cycles per rotation of the rotating body based on the first magnetic field data and the second magnetic field data;
correcting the angle signal using the slope of the angle signal, which is the slope of a straight line approximating the electrical angle of at least one of the plurality of cycles;
The correcting step includes:
adding offsets at the transition points of the plurality of periods of the angle signal to the angle signal;
correcting the angle signal using a different slope of the angle signal according to which of the plurality of cycles each electrical angle in one rotation of the rotating body is positioned.
回転体の回転角度を検出する方法であって、
前記回転体の回転に応じて変化する第1磁場データを取得する段階と、
前記回転体の回転に応じて前記第1磁場データとは異なる位相で変化する第2磁場データを取得する段階と、
前記第1磁場データおよび前記第2磁場データに基づいて、前記回転体の1回転あたり複数の周期を有する電気角を示す角度信号を出力する段階と、
前記角度信号を、前記複数の周期のうちの少なくとも1つの周期の前記電気角を近似した直線の傾きである前記角度信号の傾きを用いて補正する段階と
を備え、
前記補正する段階は、
前記複数の周期のうちの少なくとも1つの周期の前記角度信号の傾きを算出する段階と、
前記角度信号を、前記回転体の1回転中の各電気角が前記複数の周期のいずれに位置するかに応じて、異なる前記角度信号の傾きを用いて補正する段階と、を有する
方法。
A method for detecting the rotation angle of a rotating body, comprising:
obtaining first magnetic field data that varies according to the rotation of the body of rotation;
acquiring second magnetic field data that changes in phase different from the first magnetic field data according to the rotation of the rotating body;
outputting an angle signal indicating an electrical angle having a plurality of cycles per rotation of the rotating body based on the first magnetic field data and the second magnetic field data;
correcting the angle signal using the slope of the angle signal, which is the slope of a straight line approximating the electrical angle of at least one of the plurality of cycles;
The correcting step includes:
calculating a slope of the angle signal for at least one period of the plurality of periods;
correcting the angle signal using a different slope of the angle signal according to which of the plurality of cycles each electrical angle in one rotation of the rotating body is positioned.
モータと、
前記モータの回転に応じて変化する第1磁場データを出力する第1磁場センサと、
前記モータの回転に応じて前記第1磁場データとは異なる位相で変化する第2磁場データを出力する第2磁場センサと、
前記第1磁場データおよび前記第2磁場データに基づいて前記モータの回転角度を検出する請求項1からのいずれか一項に記載の検出装置と、
前記モータの回転角度の検出結果に応じて前記モータの回転を制御するモータ制御回路と
を備えるシステム。
a motor;
a first magnetic field sensor that outputs first magnetic field data that changes according to rotation of the motor;
a second magnetic field sensor that outputs second magnetic field data that changes in a phase different from that of the first magnetic field data according to the rotation of the motor;
The detection device according to any one of claims 1 to 3 , which detects the rotation angle of the motor based on the first magnetic field data and the second magnetic field data;
A system comprising: a motor control circuit that controls rotation of the motor according to a detection result of a rotation angle of the motor.
回転体の1回転あたり複数の周期を有する電気角を示す角度信号を補正する補正パラメータを算出する算出装置であって、
前記複数の周期のうちの少なくとも1つの周期の前記電気角を近似した直線の傾きである前記角度信号の傾きを算出する傾き算出部と、
前記少なくとも1つの周期の前記角度信号と、前記少なくとも1つの周期の前記角度信号の前記傾きを有する直線との間の差分をフーリエ級数展開して、補正係数を算出する係数算出部と、
前記回転体の1回転あたり前記複数の周期の前記角度信号の傾きを一致させた前記角度信号の前記複数の周期の移行点におけるオフセットを算出するオフセット算出部とを備え、
前記算出装置は、前記角度信号の前記傾き、前記補正係数、および前記オフセットを含む前記補正パラメータを出力する
算出装置。
A calculation device for calculating a correction parameter for correcting an angle signal indicating an electrical angle having a plurality of cycles per rotation of a rotating body,
a slope calculation unit that calculates a slope of the angle signal, which is a slope of a straight line approximating the electrical angle of at least one of the plurality of cycles;
a coefficient calculator for calculating a correction coefficient by Fourier series expansion of the difference between the angle signal of at least one cycle and the straight line having the slope of the angle signal of at least one cycle;
an offset calculation unit that calculates an offset at a transition point of the plurality of cycles of the angle signal that matches the slopes of the angle signal of the plurality of cycles per rotation of the rotating body;
The computing device outputs the correction parameters including the slope, the correction factor, and the offset of the angle signal.
回転体の1回転あたり複数の周期を有する電気角を示す角度信号を補正する補正パラメータを算出する算出方法であって、
前記複数の周期のうちの少なくとも1つの周期の前記電気角を近似した直線の傾きである前記角度信号の傾きを算出する傾き算出段階と、
前記少なくとも1つの周期の前記角度信号と、前記少なくとも1つの周期の前記角度信号の前記傾きを有する直線との間の差分をフーリエ級数展開して、補正係数を算出する係数算出段階と、
前記回転体の1回転あたり前記複数の周期の前記角度信号の傾きを一致させた前記角度信号の前記複数の周期の移行点におけるオフセットを算出するオフセット算出段階と、
前記角度信号の前記傾き、前記補正係数、および前記オフセットを含む前記補正パラメータを出力する段階と
を備える算出方法。
A calculation method for calculating a correction parameter for correcting an angle signal indicating an electrical angle having a plurality of cycles per rotation of a rotating body, comprising:
a slope calculation step of calculating a slope of the angle signal, which is a slope of a straight line approximating the electrical angle of at least one of the plurality of cycles;
a coefficient calculation step of calculating a correction coefficient by Fourier series expansion of the difference between the angle signal of at least one cycle and the straight line having the slope of the angle signal of at least one cycle;
an offset calculation step of calculating an offset at a transition point of the plurality of cycles of the angle signal in which slopes of the angle signal of the plurality of cycles are matched per one rotation of the rotating body;
and outputting said correction parameters comprising said slope, said correction factor and said offset of said angle signal.
JP2018122433A 2018-06-27 2018-06-27 Detection device, method, system, calculation device, and calculation method Active JP7256610B2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2018122433A JP7256610B2 (en) 2018-06-27 2018-06-27 Detection device, method, system, calculation device, and calculation method
JP2022206078A JP7381707B2 (en) 2018-06-27 2022-12-22 Detection device, method, system, calculation device, and calculation method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2018122433A JP7256610B2 (en) 2018-06-27 2018-06-27 Detection device, method, system, calculation device, and calculation method

Related Child Applications (1)

Application Number Title Priority Date Filing Date
JP2022206078A Division JP7381707B2 (en) 2018-06-27 2022-12-22 Detection device, method, system, calculation device, and calculation method

Publications (2)

Publication Number Publication Date
JP2020003316A JP2020003316A (en) 2020-01-09
JP7256610B2 true JP7256610B2 (en) 2023-04-12

Family

ID=69099695

Family Applications (2)

Application Number Title Priority Date Filing Date
JP2018122433A Active JP7256610B2 (en) 2018-06-27 2018-06-27 Detection device, method, system, calculation device, and calculation method
JP2022206078A Active JP7381707B2 (en) 2018-06-27 2022-12-22 Detection device, method, system, calculation device, and calculation method

Family Applications After (1)

Application Number Title Priority Date Filing Date
JP2022206078A Active JP7381707B2 (en) 2018-06-27 2022-12-22 Detection device, method, system, calculation device, and calculation method

Country Status (1)

Country Link
JP (2) JP7256610B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP7100677B2 (en) * 2020-05-14 2022-07-13 株式会社小野測器 Test system
US11608109B2 (en) 2020-08-12 2023-03-21 Analog Devices International Unlimited Company Systems and methods for detecting magnetic turn counter errors with redundancy
US11493362B2 (en) 2020-08-12 2022-11-08 Analog Devices International Unlimited Company Systems and methods for detecting magnetic turn counter errors

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013057590A (en) 2011-09-08 2013-03-28 Mitsubishi Heavy Ind Ltd Error frequency component acquisition device, rotation angle acquisition device, motor controller, and rotation angle acquisition method
JP2017156266A (en) 2016-03-03 2017-09-07 日立金属株式会社 Rotation angle sensor and correction method therefor

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013057590A (en) 2011-09-08 2013-03-28 Mitsubishi Heavy Ind Ltd Error frequency component acquisition device, rotation angle acquisition device, motor controller, and rotation angle acquisition method
JP2017156266A (en) 2016-03-03 2017-09-07 日立金属株式会社 Rotation angle sensor and correction method therefor

Also Published As

Publication number Publication date
JP2023024681A (en) 2023-02-16
JP2020003316A (en) 2020-01-09
JP7381707B2 (en) 2023-11-15

Similar Documents

Publication Publication Date Title
JP2023024681A (en) Detector, method, system, calculation device, and method for calculation
JP6575581B2 (en) POSITION ESTIMATION METHOD AND POSITION CONTROL DEVICE
KR102502508B1 (en) Correction table generating apparatus, encoder, and correction table generating method
US9329062B2 (en) Method for calibrating a rotary encoder
CN109696187B (en) Eccentric correcting device of rotary encoder
US10355717B2 (en) Encoder signal processing device, encoder, and signal processing method and recording medium
WO2016204205A1 (en) Detection device, rotation angle detection device, detection method, and program
JP2005208028A (en) Angle operation method for variable reluctance resolver, and angle operation unit for the same
JP4515120B2 (en) Resolver digital angle conversion apparatus and method, and program
JP6668082B2 (en) Encoder
JPWO2007055092A1 (en) Encoder signal processing device
JP7070556B2 (en) Position detection device and position detection method
CN113661375B (en) Angle detecting device
JP6405504B2 (en) Resolver error correction structure, resolver, and resolver error correction method
JP5376338B2 (en) Rotation angle detector
JP6112832B2 (en) Angle correction device and rotation angle sensor
CN115950345A (en) Measurement data processor, position measurement device and computer-implemented method
JP2020012634A (en) Rotary encoder signal processing device and signal processing method thereof
JP6629347B2 (en) Rotation information detection device, angle detection circuit, rotation information detection method, and rotation information detection program
JP6649419B2 (en) Encoder signal processing device and encoder
KR101418150B1 (en) Method and Apparatus for Compensating Sinusoidal Optical Encoder Signal
WO2022254863A1 (en) Angle detection method and angle detection device
JP5018793B2 (en) Rotational speed measuring device
CN117754576A (en) Steering engine position determining method and device and rotatable equipment
CN117885136A (en) Steering engine position calibration method and device and rotatable equipment

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20210325

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20220215

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20220415

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20220823

A601 Written request for extension of time

Free format text: JAPANESE INTERMEDIATE CODE: A601

Effective date: 20221024

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20221222

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20230331

R150 Certificate of patent or registration of utility model

Ref document number: 7256610

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150