JP4671171B2 - Motor control device - Google Patents

Motor control device Download PDF

Info

Publication number
JP4671171B2
JP4671171B2 JP2005148057A JP2005148057A JP4671171B2 JP 4671171 B2 JP4671171 B2 JP 4671171B2 JP 2005148057 A JP2005148057 A JP 2005148057A JP 2005148057 A JP2005148057 A JP 2005148057A JP 4671171 B2 JP4671171 B2 JP 4671171B2
Authority
JP
Japan
Prior art keywords
gain
speed
command
value
absolute value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2005148057A
Other languages
Japanese (ja)
Other versions
JP2006323745A (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.)
Yaskawa Electric Corp
Original Assignee
Yaskawa Electric 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 Yaskawa Electric Corp filed Critical Yaskawa Electric Corp
Priority to JP2005148057A priority Critical patent/JP4671171B2/en
Publication of JP2006323745A publication Critical patent/JP2006323745A/en
Application granted granted Critical
Publication of JP4671171B2 publication Critical patent/JP4671171B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Control Of Position Or Direction (AREA)
  • Control Of Electric Motors In General (AREA)

Description

本発明は、ロボットや工作機械などを駆動するサーボモータで、動作状態に応じて制御パラメータを切換えるゲイン切換器を備えたモータ制御装置とその制御方法に関するものである。   The present invention relates to a motor control apparatus and a control method therefor, which is a servo motor that drives a robot, a machine tool, etc., and includes a gain switching device that switches control parameters according to the operating state.

従来の動作状態に応じて制御パラメータを切り換えるゲイン切換器を備えたモータ制御装置においては、電動機の極低速状態、特に停止状態に限り発生する振動を回避することを目的するものやサーボゲインを不連続に切り換えても、モータにその不連続の影響が出ないようにすることを目的とするゲイン切換器を備えたモータ制御装置であった。
特許文献1では、電動機の極低速状態、特に停止状態に限り発生する振動を回避するゲイン切換器を備えたモータ制御装置が記載されている。以下、簡単に図面を用いて説明する。図7(従来装置1の図)において、701は指令パルスを発生するパルス発生器であり、指令パルスを702のサーボドライバが受け取る。サーボドライバ702は、703のパルス間隔計測器と704のサーボ定数切換器と705のサーボ制御器で構成されている。指令パルスは、サンプリング周期毎にパルス間隔計測器703へ入力される。パルス間隔計測器703は指令パルスが入力されない場合にカウントし、指令パルスが入力された場合はゼロクリアし、パルス間隔をサンプリング周期単位で計測するものである。パルス間隔計測器703で計測されたパルス間隔がサーボ定数切換器704の切換設定値以上の時間になれば、サーボ定数が切り換えられ、反対にパルス間隔計測器703で計測されたパルス間隔が、サーボ定数切換器704の切換設定値未満の時間になれば、切り換え前のサーボ定数に切り換える。指令パルスが切換え設定値以上の時間入力されない場合、低いサーボゲインとなり、それ以外の場合、高いサーボゲインとなる。
In a motor control device equipped with a gain switching device that switches control parameters according to the conventional operating state, a motor control device intended to avoid vibrations that occur only when the motor is in a very low speed state, particularly in a stopped state, or a servo gain is disabled. The motor control device is provided with a gain switching device for the purpose of preventing the motor from being affected by the discontinuity even when switching continuously.
Patent Document 1 describes a motor control device provided with a gain switching device that avoids vibrations that occur only in an extremely low speed state of an electric motor, particularly in a stopped state. Hereinafter, it will be briefly described with reference to the drawings. In FIG. 7 (the diagram of the conventional apparatus 1), reference numeral 701 denotes a pulse generator that generates a command pulse, and the servo driver of 702 receives the command pulse. The servo driver 702 includes a pulse interval measuring device 703, a servo constant switching device 704, and a servo controller 705. The command pulse is input to the pulse interval measuring device 703 every sampling period. The pulse interval measuring device 703 counts when a command pulse is not input, clears it to zero when a command pulse is input, and measures the pulse interval in units of sampling periods. When the pulse interval measured by the pulse interval measuring device 703 is equal to or longer than the switching set value of the servo constant switching device 704, the servo constant is switched. Conversely, the pulse interval measured by the pulse interval measuring device 703 is changed to the servo interval. When the time is shorter than the switching set value of the constant switching unit 704, the servo constant before switching is switched. When the command pulse is not input for a time longer than the switching set value, the servo gain is low, and otherwise the servo gain is high.

特許文献2では、サーボゲインを不連続に切換えても、モータにその不連続の影響が出ないようにするゲイン切換器を備えたモータ制御装置が記載されている。以下、簡単に図面を用いて説明する。図8(従来装置2の図)において、位置指令Psと810の検出器の出力であるモータ位置Pfbを800の減算器に入力し、減算器800の出力Erを801の位置ループゲインと乗算する。位置ループゲイン乗算結果である速度指令Vsと、803の速度検出器の出力であるモータ速度を802の減算器に入力する。減算器802の出力である速度偏差Evは804の速度ループゲインと乗算するとともに805の積分器に入力し、積分器出力を806の速度ループ積分ゲインと乗算する。速度ループゲイン乗算結果と速度ループ積分ゲイン乗算結果を807の加算器に入力し、加算器807の出力であるトルク指令を808のサーボアンプに入力し、サーボアンプ808では809のサーボモータを駆動する電流を出力する。サーボモータに結合された810の検出器によりモータ位置を出力して、フィードバック制御している。ゲイン切換は、動作状態データ(位置指令、位置フィードバック、速度フィードバック、トルク指令)に応じて811の動作状態判断部でゲイン切換信号を812のゲイン変更部と813の速度偏差積分値変更部に送信し、ゲイン変更部812では予め設定しておいた位置ループゲインと速度ループゲインと速度ループ積分ゲインに変更する。また、速度偏差積分値変更部813では動作状態判定部811から動作状態データを受け取り、ゲイン変更部812から新旧のゲインを受け取り、積分器805から現在の積分値を受け取って新しい積分値を生成し変更するものである。アンプへの出力が連続的になるように、ゲイン切換と同時に積分器805の積分値を調整する。この積分器805の積分値の調整は、ゲイン切換前の各ゲインをKp1、Kv1、Ki1、積分値をΣEv1、そしてゲイン切換後の各ゲインをKp2、Kv2、Ki2とすると、新しい積分値ΣEv2はゲイン切換前後でサーボアンプへの指令が等しいという条件より、   Patent Document 2 describes a motor control device including a gain switching unit that prevents the motor from being affected by the discontinuity even when the servo gain is switched discontinuously. Hereinafter, it will be briefly described with reference to the drawings. In FIG. 8 (the figure of the conventional apparatus 2), the position command Ps and the motor position Pfb, which is the output of the detector 810, are input to the subtractor 800, and the output Er of the subtractor 800 is multiplied by the position loop gain of 801. . The speed command Vs that is the result of the position loop gain multiplication and the motor speed that is the output of the speed detector 803 are input to the subtracter 802. The speed deviation Ev, which is the output of the subtractor 802, is multiplied by the speed loop gain of 804 and input to the integrator of 805, and the integrator output is multiplied by the speed loop integral gain of 806. The speed loop gain multiplication result and the speed loop integral gain multiplication result are input to the adder 807, the torque command output from the adder 807 is input to the servo amplifier 808, and the servo amplifier 808 drives the servo motor 809. Output current. The motor position is output by a detector 810 coupled to the servo motor, and feedback control is performed. In gain switching, a gain switching signal is transmitted to a gain changing unit 812 and a speed deviation integrated value changing unit 813 by an operating state determining unit 811 according to operating state data (position command, position feedback, speed feedback, torque command). Then, the gain changing unit 812 changes the position loop gain, speed loop gain, and speed loop integral gain set in advance. The speed deviation integrated value changing unit 813 receives operating state data from the operating state determining unit 811, receives old and new gains from the gain changing unit 812, receives the current integrated value from the integrator 805, and generates a new integrated value. To change. The integral value of the integrator 805 is adjusted simultaneously with the gain switching so that the output to the amplifier becomes continuous. Adjustment of the integral value of the integrator 805 is as follows. When the gains before gain switching are Kp1, Kv1, Ki1, the integral values are ΣEv1, and the gains after gain switching are Kp2, Kv2, Ki2, the new integral value ΣEv2 is From the condition that the command to the servo amplifier is the same before and after gain switching,

となり、この(2)式を変形して、 And transforming this equation (2)

としている。ゲイン切換後は、切換後のKp2を使って指令速度Vsを算出し、指令速度Vsとモータ速度を使って速度偏差Evを算出し、Kv2、Ki2を使ってサーボアンプ808へのトルク指令を算出している。
特開平8−241129(3頁図1) 特開平7−194157(4頁図3)
It is said. After gain switching, command speed Vs is calculated using Kp2 after switching, speed deviation Ev is calculated using command speed Vs and motor speed, and torque command to servo amplifier 808 is calculated using Kv2 and Ki2. is doing.
Japanese Patent Laid-Open No. 8-241129 (FIG. 1 on page 3) Japanese Patent Application Laid-Open No. 7-194157 (FIG. 3 on page 4)

従来のゲイン切換装置を備えたモータ制御装置の中で、特許文献1ではパルス発生器からの指令パルスのみを条件としてゲイン切換えしており、例えば指令パルスが入力されている期間はハイゲインとし、指令パルスが入力されない期間をローゲインとすると位置決め時間整定時間が延びるという問題がある。また、(3)式に示すような積分器の積分値の調整をしていないため、ゲイン切換時にオーバーシュートが発生するという問題がある。 特許文献2ではゲイン切換条件を位置指令、位置フィードバック、速度フィードバック、トルク指令としており、これらの値は動作条件で異なるのでその都度、ゲイン切換条件を設定する必要がある。また、(3)式は計算に利用する変数が多く複雑であると共に速度PI制御を対象とした積分補正式であり、速度I−P制御にする時には補正式を変更しなければならないという問題がある。
本発明では、このような問題点に鑑みてなされたものであり、制御ゲイン切換えを簡素化し、PI型とI−P型の速度制御両方で利用できる積分補正式を用いて補正し、ゲイン切換後のオーバーシュートを抑制し、位置決め時間が短く、設定の誤りなどをユーザが監視でき安全に調整ができるモータ制御装置と制御方法を提供することを目的とする。
Among the motor control devices provided with the conventional gain switching device, in Patent Document 1, gain switching is performed only on the condition of a command pulse from a pulse generator. For example, a high gain is set during a period in which the command pulse is input. If the period during which no pulse is input is a low gain, there is a problem that the positioning time settling time is extended. Further, since the integration value of the integrator as shown in the equation (3) is not adjusted, there is a problem that overshoot occurs at the time of gain switching. In Patent Document 2, the gain switching condition is a position command, position feedback, speed feedback, and torque command, and these values differ depending on the operating condition. Therefore, it is necessary to set the gain switching condition each time. Also, equation (3) is an integral correction equation for speed PI control that is complicated and has many variables to be used for calculation, and there is a problem that the correction equation must be changed when using speed IP control. is there.
The present invention has been made in view of such a problem. The control gain switching is simplified, and correction is performed using an integral correction formula that can be used in both PI type and IP type speed control. An object of the present invention is to provide a motor control device and a control method that can suppress subsequent overshoot, have a short positioning time, can be monitored by a user, and can be adjusted safely.

上記問題を解決するため、本発明は、次のように構成したのである。
請求項1に記載の発明は、位置指令を生成する位置指令生成器と、前記位置指令とモータ位置の偏差を入力し速度指令を生成する位置制御器と、前記速度指令とモータ速度の偏差を入力しトルク指令を生成する速度制御器と、前記トルク指令を入力しモータ駆動電流を生成する電流制御器と、前記位置制御器の位置制御ゲインと前記速度制御器の速度制御ゲインを状態に応じて切換えるゲイン切換器とを備えたモータ制御装置において、前記ゲイン切換器は、前記位置指令の時間差分の絶対値である位置指令差分絶対値が所定値以上のときは前記位置制御ゲインと前記速度制御ゲインを第1所定値に切換え、前記位置指令差分絶対値が所定値よりも小さく、前記位置偏差の絶対値である位置偏差絶対値が所定値以上のときは第2所定値に切換え、前記位置指令差分絶対値が所定値よりも小さく前記位置偏差絶対値が所定値よりも小さい時は第3所定値に切換えるとともに、前記速度制御器の積分器出力値を(1)式で補正することを特徴とするものである。
In order to solve the above problem, the present invention is configured as follows.
The invention according to claim 1 is a position command generator that generates a position command, a position controller that inputs a deviation between the position command and the motor position and generates a speed command, and a deviation between the speed command and the motor speed. Input a speed controller that generates a torque command, a current controller that inputs the torque command and generates a motor drive current, a position control gain of the position controller, and a speed control gain of the speed controller according to the state A gain switching device that switches between the position control gain and the speed when the absolute value of the position command difference, which is the absolute value of the time difference of the position command, is greater than or equal to a predetermined value. The control gain is switched to the first predetermined value. When the absolute value of the position command difference is smaller than the predetermined value and the absolute value of the position deviation, which is the absolute value of the positional deviation, is greater than or equal to the predetermined value, the control gain is switched to the second predetermined value. When the absolute value of the position command difference is smaller than the predetermined value and the absolute value of the position deviation is smaller than the predetermined value, the position command difference absolute value is switched to the third predetermined value and the integrator output value of the speed controller is corrected by the equation (1). It is characterized by doing.

ここで、v:積分器出力値、Kv:速度ループゲイン、Ts:速度制御のサンプリング時間、Ki:速度ループ積分ゲイン、Verr:速度偏差 を表す。
請求項2に記載の発明は、請求項1に記載のモータ制御装置において、前記速度制御器はI−P制御器であることを特徴とするものである。
請求項3に記載の発明は、請求項1に記載のモータ制御装置において、前記速度制御器はPI制御器であることを特徴とするものである。
請求項4に記載の発明は、請求項1に記載のモータ制御装置において、前記ゲイン切換器は、外部信号の値に応じて、前記位置制御ゲインおよび前記速度制御ゲインを切換えることを特徴とするものである。
請求項5に記載の発明は、請求項1に記載のモータ制御装置において、前記ゲイン切換器は、現在のゲイン設定値を表示できるモニタを備えたことを特徴とするものである。
請求項6に記載の発明は、位置指令を発生する位置指令発生器と、前記位置指令とモータ位置の偏差を入力し速度指令を生成する位置制御器と、前記速度指令とモータ速度の偏差を入力しトルク指令を生成する速度制御器と、前記トルク指令を入力しモータ駆動電流を生成する電流制御器と、前記位置制御器の位置制御ゲインと前記速度制御器の速度制御ゲインを状態に応じて切換えるゲイン切換器とを備えたモータ制御装置のモータ制御方法において、位置指令の時間差分の絶対値である位置指令差分絶対値を求めるステップST1と、前記位置指令差分絶対値を所定値と比較し、前記位置指令差分絶対値が大きい場合はステップST4へ移行し、小さい場合はステップST3へ移行するステップST2と、位置制御ゲイン、速度制御ゲインを第1所定値に切換えるステップST4と、位置偏差絶対値を所定値と比較し、前記位置偏差絶対値が大きい場合はステップST5へ移行し、小さい場合はステップST6へ移行するステップST3と、前記位置制御ゲイン、前記速度制御ゲインを第2所定値に切換えるステップST5と、前記位置制御ゲイン、前記速度制御ゲインを第3所定値に切換えるステップST6と、前記速度制御器の積分器出力を(1)式で補正するステップST7とを備えることを特徴とするものである。
Here, v: integrator output value, Kv: speed loop gain, Ts: speed control sampling time, Ki: speed loop integral gain, Verr: speed deviation.
According to a second aspect of the present invention, in the motor control device according to the first aspect, the speed controller is an IP controller.
According to a third aspect of the present invention, in the motor control device according to the first aspect, the speed controller is a PI controller.
According to a fourth aspect of the present invention, in the motor control device according to the first aspect, the gain switching unit switches the position control gain and the speed control gain according to a value of an external signal. Is.
According to a fifth aspect of the present invention, in the motor control device according to the first aspect, the gain switching device includes a monitor capable of displaying a current gain setting value.
According to a sixth aspect of the present invention, there is provided a position command generator that generates a position command, a position controller that generates a speed command by inputting a deviation between the position command and the motor position, and a deviation between the speed command and the motor speed. Input a speed controller that generates a torque command, a current controller that inputs the torque command and generates a motor drive current, a position control gain of the position controller, and a speed control gain of the speed controller according to the state In a motor control method of a motor control device comprising a gain switching device for switching, a step ST1 for obtaining a position command difference absolute value that is an absolute value of a time difference of a position command, and comparing the position command difference absolute value with a predetermined value When the absolute value of the position command difference is large, the process proceeds to step ST4. When the absolute value is small, the process proceeds to step ST2, where the position control gain and speed control gain are shifted. Step ST4 for switching to the first predetermined value, the position deviation absolute value is compared with the predetermined value, and if the position deviation absolute value is large, the process proceeds to step ST5, and if it is small, the process proceeds to step ST6. Step ST5 for switching the position control gain and the speed control gain to the second predetermined value, Step ST6 for switching the position control gain and the speed control gain to the third predetermined value, and the integrator output of the speed controller (1) Step ST7 which correct | amends by Formula), It is characterized by the above-mentioned.

請求項1および6に記載の発明によると、速度制御方式(速度PI制御や速度I−P制御)によらず、ゲイン切換後のオーバーシュートを抑制できる。また、ゲイン切換条件を位置指令の差分値の絶対値を使っており、動作条件に大きく依存しないため切換条件の設定が容易である。
請求項2に記載の発明によると、積分補正式を使わなくとも位置P速度I−P制御でオーバーシュートを抑制できる。
請求項3に記載の発明によると、積分補正式を使わなくとも位置P速度PI制御でオーバーシュートを抑制できる。
請求項4に記載の発明によると、内部状態よりも外部信号(例えば負荷状態)を優先させてゲイン切換ができる。
請求項5に記載の発明によると、現在のゲイン設定値をモニタできるので、設定の誤りなどをユーザーが監視でき、安全に調整ができる。
According to the first and sixth aspects of the invention, overshoot after gain switching can be suppressed regardless of the speed control method (speed PI control or speed IP control). Further, since the absolute value of the difference value of the position command is used as the gain switching condition and does not largely depend on the operating condition, the switching condition can be easily set.
According to the second aspect of the present invention, overshoot can be suppressed by the position P speed IP control without using the integral correction formula.
According to the third aspect of the present invention, overshoot can be suppressed by the position P speed PI control without using the integral correction formula.
According to the fourth aspect of the present invention, gain switching can be performed by giving priority to an external signal (for example, a load state) over an internal state.
According to the fifth aspect of the present invention, since the current gain setting value can be monitored, the user can monitor setting errors and the like, and can be adjusted safely.

以下、本発明の実施の形態について図を参照して説明する。   Hereinafter, embodiments of the present invention will be described with reference to the drawings.

図1は、本発明のモータ制御装置の全体構成図であり、本実施例では速度比例積分制御を速度I−P制御に限定して説明する。速度PI制御においても、同様の方法で実現できる。図において、1は指令発生器であり、2の位置指令と3のモータ位置を4の減算器に入力した結果、5の位置偏差を出力する。位置偏差5は6の位置ループゲインと乗算し、乗算結果は速度指令となる。速度指令と7の差分演算器の出力であるモータ速度を8の減算器に入力する。減算器8の出力は速度偏差であり、速度偏差とモータ速度を9の速度I−P制御器に入力する。速度I−P制御器9では、速度偏差を10の積分制御器に入力する。積分制御器10では、(1)式を計算する。   FIG. 1 is an overall configuration diagram of a motor control device according to the present invention. In this embodiment, speed proportional integral control is limited to speed IP control. The speed PI control can be realized by the same method. In the figure, reference numeral 1 denotes a command generator, which outputs a position deviation of 5 as a result of inputting a position command of 2 and a motor position of 3 to a subtracter of 4. The position deviation 5 is multiplied by a position loop gain of 6, and the multiplication result is a speed command. The speed command and the motor speed that is the output of the difference calculator 7 are input to the subtracter 8. The output of the subtracter 8 is a speed deviation, and the speed deviation and the motor speed are input to a speed IP controller 9. In the speed IP controller 9, the speed deviation is input to the 10 integral controller. The integration controller 10 calculates the equation (1).

まず、(1)式の右辺第1項の計算を説明する。1サンプリング過去の積分出力値(v[i−1])に1サンプリング過去の速度ループゲイン(Kv[i−1])を乗算し、乗算結果を現在の速度ループゲイン(Kv[i])で除算する。次に(1)式の右辺第2項の計算を説明する。速度偏差(Verr[i])とサンプリング時間Tsを乗算し、乗算結果を速度ループ積分ゲイン(Ki[i])で乗算する。(1)式の右辺第1項と第2項の和が積分制御器の出力値となる。次に、積分制御器の出力値と速度フィードバックを11の減算器に入力し、減算器11の出力と12の速度ループゲインを乗算する。乗算結果であるトルク指令を13の電流制御器に入力し、電流制御器13では14のモータを駆動する電流を出力する。モータ14が駆動されると回転数に応じて15の検出器でモータ位置3が出力される。次に16のゲイン切換器を説明する。ゲイン切換器16には位置指令2と位置偏差5を入力し、ゲイン切換器16では、位置指令2の差分値の絶対値と位置偏差5の絶対値を計算する。位置指令2の差分値の絶対値が所定値よりも大きい時(これを状態1とする)には、モータが動きだすことを表しており、位置ループゲインKp1,速度ループゲインKv1,速度ループ積分ゲインKi1を位置ループゲイン6と速度ループゲイン12と積分制御器10の速度ループ積分ゲインに設定する。次に位置指令2の差分値の絶対値が0となり、位置偏差の絶対値が所定値以上の時(これを状態2とする)では、指令は0であるが、まだ駆動中であるので、位置ループゲインKp2,速度ループゲインKv2,速度ループ積分ゲインKi2を位置ループゲイン6と速度ループゲイン12と積分制御器10の速度ループ積分ゲインに設定する。最後に位置指令2の差分の絶対値が0で、位置偏差の絶対値が所定値以下の時(これを状態3とする)、モータは停止状態であると見なし、位置ループゲインKp3,速度ループゲインKv3,速度ループ積分ゲインKi3を位置ループゲイン6と速度ループゲイン12と積分制御器10の速度ループ積分ゲインに設定する。ゲイン切換時点、例えば状態1から状態2に変わった瞬間は、現在速度ループゲイン(Kv[i])はKv2であり、1サンプリング過去の速度ループゲイン(Kv[i−1])はKv1を表す。また、状態1が持続されている間は、現在の速度ループゲインも1サンプリング過去の速度ループゲインもKv1を表す。この時、(1)式のKv[i−1]はKv1であり、Kv[i]もKv1であることを表している。上記説明では、状態2と3の速度ループゲイン、位置ループゲイン、速度ループ積分ゲインは異なるが、同値としても良い。18は、現在の速度ループゲインを表示するモニタである。モニタ18の出力信号を計測装置などで取り込むことにより、運転状態を確認することができる。   First, calculation of the first term on the right side of equation (1) will be described. Multiply the integrated output value (v [i-1]) past 1 sampling by the velocity loop gain (Kv [i-1]) past 1 sampling, and the multiplication result is the current speed loop gain (Kv [i]). Divide. Next, calculation of the second term on the right side of the equation (1) will be described. The speed deviation (Verr [i]) is multiplied by the sampling time Ts, and the multiplication result is multiplied by the speed loop integral gain (Ki [i]). The sum of the first and second terms on the right side of equation (1) is the output value of the integral controller. Next, the output value of the integral controller and the speed feedback are input to the 11 subtractor, and the output of the subtractor 11 and the speed loop gain of 12 are multiplied. A torque command, which is a multiplication result, is input to 13 current controllers, and the current controller 13 outputs a current for driving 14 motors. When the motor 14 is driven, the motor position 3 is output by 15 detectors according to the rotational speed. Next, the 16 gain changers will be described. A position command 2 and a position deviation 5 are input to the gain switch 16, and the gain switch 16 calculates the absolute value of the difference value of the position command 2 and the absolute value of the position deviation 5. When the absolute value of the difference value of the position command 2 is larger than a predetermined value (this is assumed to be state 1), this indicates that the motor starts to move, and position loop gain Kp1, speed loop gain Kv1, speed loop integral gain Ki1 is set to the position loop gain 6, the speed loop gain 12, and the speed loop integral gain of the integral controller 10. Next, when the absolute value of the difference value of the position command 2 is 0 and the absolute value of the position deviation is greater than or equal to a predetermined value (this is referred to as state 2), the command is 0, but is still being driven. Position loop gain Kp2, speed loop gain Kv2, and speed loop integral gain Ki2 are set as position loop gain 6, speed loop gain 12, and speed loop integral gain of integral controller 10. Finally, when the absolute value of the difference of the position command 2 is 0 and the absolute value of the position deviation is equal to or smaller than a predetermined value (this is referred to as state 3), the motor is considered to be stopped, and the position loop gain Kp3, speed loop The gain Kv3, the speed loop integral gain Ki3 are set to the position loop gain 6, the speed loop gain 12, and the speed loop integral gain of the integral controller 10. At the time of gain switching, for example, at the moment when the state 1 changes to the state 2, the current speed loop gain (Kv [i]) is Kv2, and the speed loop gain (Kv [i-1]) of one sampling past represents Kv1. . While state 1 is maintained, both the current speed loop gain and the speed loop gain of one sampling past represent Kv1. At this time, Kv [i-1] in the equation (1) is Kv1, and Kv [i] is also Kv1. In the above description, the speed loop gain, the position loop gain, and the speed loop integral gain in states 2 and 3 are different, but may be the same value. Reference numeral 18 denotes a monitor that displays the current speed loop gain. The operation state can be confirmed by capturing the output signal of the monitor 18 with a measuring device or the like.

次に、本発明のモータ制御装置(図1)と従来のモータ制御装置1(図8)をシミュレーションした。このシミュレーションでの各条件を説明する。指令発生器1では、速度台形指令を積分して位置指令として、減算器4に入力する。指令は、0sから加速し、0.1sで最大速度1000(1/min)に到達する。0.1sから0.3sまで1000(1/min)を維持し、0.3sから0.4sまで減速し、指令払い出し終了は0.4sとなる。その後、指令0であり、0.6sからまた負方向に加速し、0.7sで−1000(1/min)に到達し、0.7sから0.9sまで−1000(1/min)を維持し、0.9sから減速して1sで指令払い出し完了とする速度台形指令とした。モータ14には、定格トルクの10%に相当する外乱トルクが入力される。ゲイン切換器16の切換条件とゲイン設定値を次のように設定した。状態1は位置指令の差分の絶対値が1パルス以上として、位置ループゲインKp1=100Hz、速度ループゲインKv1=160Hz、速度ループ積分ゲインKi1=2πKv1として、状態2は位置指令2の差分の絶対値が0で位置偏差の絶対値が10パルスよりも大きい時とし、位置ループゲインKp2=90Hz、速度ループゲインKv2=150Hz、速度ループ積分ゲインKi2=2πKv2とした。さらに状態3は位置指令2の差分の絶対値が0で、位置偏差の絶対値が10パルス以下の時として、位置ループゲインKp3=80Hz、速度ループゲインKv3=80Hz、速度ループ積分ゲインKi3=2πKv3とした。それに対して従来装置1では、指令が1パルス以上の時には、位置ループゲインKp1=100Hz、速度ループゲインKv1=160Hz、速度ループ積分ゲインKi1=2πKv1とし、指令が0で、位置ループゲインKp3=80Hz、速度ループゲインKv3=80Hz、速度ループ積分ゲインKi3=2πKv3とした。この条件でモータ速度の波形比較(図5)とモータ位置の波形比較(図6)をした。まず図5を説明する。本発明の装置ではゲイン切換は図中AとBの時点で実行される。A時点以前が状態2であり、A時点以降が状態3である。またB時点以降は状態1である。従来装置のゲイン切換は、指令払い出し完了時点(図中0.4s)から0.6sまでは位置ループゲインKp3=80Hz、速度ループゲインKv3=80Hz、速度ループ積分ゲインKi3=2πKv3であり、0.6s以降は、位置ループゲインKp1=100Hz、速度ループゲインKv1=160Hz、速度ループ積分ゲインKi1=2πKv1としている。従来装置では、指令払い出し完了後にゲインを低くする為、0速度に到達する時間が本発明に比べて20ms長い事がわかる。また、指令1パルス以上になる時点(0.6s)から、従来装置1ではオーバーシュートが発生しているのに対して、本発明ではオーバーシュートがなく良好な結果となっている。次に図6を説明する。図中A、Bの説明は図5の説明と同じであるので説明を省略する。A時点で本発明装置の結果は、従来装置1の結果に比べて10パルス程度目標位置に近づいていることがわかる。また、位置決め整定時間を指令払い出し後、±2パルス以内に入ったときとすると、本発明装置は従来装置1の結果に比べて、20ms程度位置決め時間が短縮されていることがわかる。   Next, the motor control device of the present invention (FIG. 1) and the conventional motor control device 1 (FIG. 8) were simulated. Each condition in this simulation will be described. The command generator 1 integrates the speed trapezoid command and inputs it to the subtracter 4 as a position command. The command accelerates from 0 s and reaches a maximum speed of 1000 (1 / min) in 0.1 s. It maintains 1000 (1 / min) from 0.1 s to 0.3 s, decelerates from 0.3 s to 0.4 s, and the command payout end is 0.4 s. After that, it is command 0, accelerates in the negative direction again from 0.6s, reaches -1000 (1 / min) at 0.7s, and maintains -1000 (1 / min) from 0.7s to 0.9s. Then, the speed trapezoidal command is set to decelerate from 0.9 s and complete the command payout in 1 s. A disturbance torque corresponding to 10% of the rated torque is input to the motor 14. The switching condition and gain setting value of the gain switch 16 were set as follows. In state 1, the absolute value of the position command difference is 1 pulse or more, position loop gain Kp1 = 100 Hz, speed loop gain Kv1 = 160 Hz, speed loop integral gain Ki1 = 2πKv1, state 2 is the absolute value of the difference in position command 2 Is 0 and the absolute value of the position deviation is larger than 10 pulses, the position loop gain Kp2 = 90 Hz, the speed loop gain Kv2 = 150 Hz, and the speed loop integral gain Ki2 = 2πKv2. Further, in state 3, when the absolute value of the difference of the position command 2 is 0 and the absolute value of the position deviation is 10 pulses or less, the position loop gain Kp3 = 80 Hz, the speed loop gain Kv3 = 80 Hz, and the speed loop integral gain Ki3 = 2πKv3. It was. On the other hand, in the conventional apparatus 1, when the command is 1 pulse or more, the position loop gain Kp1 = 100 Hz, the speed loop gain Kv1 = 160 Hz, the speed loop integral gain Ki1 = 2πKv1, the command is 0, and the position loop gain Kp3 = 80 Hz. The speed loop gain Kv3 = 80 Hz and the speed loop integral gain Ki3 = 2πKv3. Under these conditions, the motor speed waveform comparison (FIG. 5) and the motor position waveform comparison (FIG. 6) were performed. First, FIG. 5 will be described. In the apparatus of the present invention, gain switching is executed at time points A and B in the figure. State 2 is before time A, and state 3 is after time A. Further, the state 1 is after time B. In the conventional apparatus, the gain switching is performed by the position loop gain Kp3 = 80 Hz, the speed loop gain Kv3 = 80 Hz, and the speed loop integral gain Ki3 = 2πKv3 from the command payout completion time (0.4 s in the figure) to 0.6 s. After 6 s, the position loop gain Kp1 = 100 Hz, the speed loop gain Kv1 = 160 Hz, and the speed loop integral gain Ki1 = 2πKv1. In the conventional apparatus, since the gain is lowered after the command payout is completed, it can be seen that the time to reach the zero speed is 20 ms longer than the present invention. Further, overshoot has occurred in the conventional apparatus 1 from the time point (0.6 s) when the command becomes 1 pulse or more, whereas in the present invention, there is no overshoot and a good result is obtained. Next, FIG. 6 will be described. Description of A and B in the figure is the same as that of FIG. It can be seen that at time A, the result of the device of the present invention approaches the target position by about 10 pulses compared to the result of the conventional device 1. Also, if the positioning settling time is within ± 2 pulses after the command is issued, it can be seen that the positioning time of the device of the present invention is shortened by about 20 ms compared to the result of the conventional device 1.

図2は、請求項2記載のゲイン切換器を表している。図において、1は指令生成器であり、2の位置指令と3のモータ位置を4の減算器に入力し5の位置偏差を出力する。位置偏差5は6の位置ループゲインと乗算し、乗算結果は速度指令となる。速度指令と7の差分演算器の出力であるモータ速度を8の減算器に入力する。減算器8の出力は速度偏差であり、速度偏差と12の速度ループゲインを乗算する。乗算結果を201の積分制御器に入力する。速度偏差から積分出力値までの関係は、(4)式となる。   FIG. 2 shows a gain switch according to claim 2. In the figure, 1 is a command generator, which inputs a position command of 2 and a motor position of 3 to a subtracter of 4 and outputs a position deviation of 5. The position deviation 5 is multiplied by a position loop gain of 6, and the multiplication result is a speed command. The speed command and the motor speed that is the output of the difference calculator 7 are input to the subtracter 8. The output of the subtracter 8 is a speed deviation, and the speed deviation is multiplied by 12 speed loop gains. The multiplication result is input to the integration controller 201. The relationship from the speed deviation to the integral output value is expressed by equation (4).

(4) (4)

v:積分器出力値、Kv:速度ループゲイン、Ts:速度制御のサンプリング時間、Ki:速度ループ積分ゲイン、Verr:速度偏差
モータ速度と202の速度ループゲインを乗算した結果と積分出力値を11の減算器に入力する。減算器11の出力であるトルク指令を13の電流制御器に入力し、電流制御器13は14のモータを駆動する電流を出力する。16のゲイン切換器を説明する。ゲイン切換器16には位置指令2と位置偏差5を入力し、ゲイン切換器では、位置指令2の差分値の絶対値と位置偏差5の絶対値を計算する。位置指令2の差分値の絶対値が所定値よりも大きい時(これを状態1とする)には、モータが動きだすことを表しており、位置ループゲインKp1,速度ループゲインKv1,速度ループ積分ゲインKi1を位置ループゲイン6と速度ループゲイン12、202と積分制御器201の速度ループ積分ゲインに設定する。次に位置指令2の差分値の絶対値が0となり、位置偏差の絶対値が所定値以上の時(これを状態2とする)では、指令は0であるが、まだ駆動中であるので、位置ループゲインKp2,速度ループゲインKv2,速度ループ積分ゲインKi2を位置ループゲイン6と速度ループゲイン12、202と積分制御器201の速度ループ積分ゲインに設定する。最後に位置指令2の差分の絶対値が0で、位置偏差の絶対値が所定値以下の時(これを状態3とする)、モータは停止状態であると見なし、位置ループゲインKp3,速度ループゲインKv3,速度ループ積分ゲインKi3を位置ループゲイン6と速度ループゲイン12、202と積分制御器201の速度ループ積分ゲインに設定する。ゲイン切換時点、例えば状態1から状態2に変わった瞬間は、現在速度ループゲイン(Kv[i])はKv2であり、1サンプリング過去の速度ループゲイン(Kv[i−1])はKv1を表す。また、状態1が持続されている間は、現在の速度ループゲインも1サンプリング過去の速度ループゲインもKv1を表す。この時、(4)式の1サンプリング過去の積分出力値に使用するKv[i−1]はKv1であり、現在の積分出力値に使用するKv[i]もKv1であることを表している。18は、現在の速度ループゲインを表示するモニタである。モニタ18の出力信号を計測装置などで取り込むことにより、運転状態を確認することができる。
v: integrator output value, Kv: speed loop gain, Ts: speed control sampling time, Ki: speed loop integral gain, Verr: speed deviation motor speed multiplied by 202 speed loop gain, and integral output value 11 Input to the subtractor. A torque command, which is the output of the subtractor 11, is input to the 13 current controller, and the current controller 13 outputs a current for driving the 14 motor. The 16 gain changers will be described. A position command 2 and a position deviation 5 are input to the gain switch 16 and the gain switch calculates the absolute value of the difference value of the position command 2 and the absolute value of the position deviation 5. When the absolute value of the difference value of the position command 2 is larger than a predetermined value (this is assumed to be state 1), this indicates that the motor starts to move, and the position loop gain Kp1, the speed loop gain Kv1, and the speed loop integral gain Ki1 is set to the position loop gain 6, the speed loop gains 12 and 202, and the speed loop integral gain of the integral controller 201. Next, when the absolute value of the difference value of the position command 2 is 0 and the absolute value of the position deviation is greater than or equal to a predetermined value (this is referred to as state 2), the command is 0, but is still being driven. The position loop gain Kp2, the speed loop gain Kv2, and the speed loop integral gain Ki2 are set as the position loop gain 6, the speed loop gains 12 and 202, and the speed loop integral gain of the integral controller 201. Finally, when the absolute value of the difference of the position command 2 is 0 and the absolute value of the position deviation is equal to or smaller than a predetermined value (this is referred to as state 3), the motor is considered to be stopped, and the position loop gain Kp3, speed loop The gain Kv3, the speed loop integral gain Ki3 are set to the position loop gain 6, the speed loop gains 12, 202, and the speed loop integral gain of the integral controller 201. At the time of gain switching, for example, at the moment when the state changes from state 1 to state 2, the current speed loop gain (Kv [i]) is Kv2, and the speed loop gain (Kv [i-1]) of one sampling past represents Kv1. . While state 1 is maintained, both the current speed loop gain and the speed loop gain of one sampling past represent Kv1. At this time, Kv [i−1] used for the integrated output value of one sampling past in the equation (4) is Kv1, and Kv [i] used for the current integrated output value is also Kv1. . Reference numeral 18 denotes a monitor that displays the current speed loop gain. The operation state can be confirmed by capturing the output signal of the monitor 18 with a measuring device or the like.

図3は、請求項3記載のゲイン切換装置を表している。図において、1は指令発生器であり、2の位置指令と3のモータ位置を4の減算器に入力した結果、5の位置偏差を出力する。位置偏差5と6の位置ループゲインを乗算し、乗算結果は速度指令となる。速度指令と7の差分演算器の出力であるモータ速度を8の減算器に入力する。減算器8の出力は速度偏差であり、速度偏差を300の速度PI制御器に入力する。速度PI制御器300では、速度偏差と12の速度ループゲインを乗算し、乗算結果を201の積分制御器に入力する。速度偏差から積分出力値までの関係は(4)式となる。   FIG. 3 shows a gain switching device according to claim 3. In the figure, reference numeral 1 denotes a command generator, which outputs a position deviation of 5 as a result of inputting a position command of 2 and a motor position of 3 to a subtracter of 4. The position loop gain of the position deviations 5 and 6 is multiplied, and the multiplication result becomes a speed command. The speed command and the motor speed that is the output of the difference calculator 7 are input to the subtracter 8. The output of the subtracter 8 is a speed deviation, and the speed deviation is input to the 300 speed PI controller. The speed PI controller 300 multiplies the speed deviation and the speed loop gain of 12, and inputs the multiplication result to the integral controller 201. The relationship from the speed deviation to the integrated output value is expressed by equation (4).

モータ速度と速度ループゲイン12の乗算結果と積分出力値を301の加算器に入力する。加算器301の出力であるトルク指令を13の電流制御器に入力し、電流制御器13は14のモータを駆動する電流を出力する。16のゲイン切換器を説明する。ゲイン切換器16には位置指令2と位置偏差5を入力し、ゲイン切換器では、位置指令2の差分値の絶対値と位置偏差5の絶対値を計算する。位置指令2の差分値の絶対値が所定値よりも大きい時(これを状態1とする)には、モータが動きだすことを表しており、位置ループゲインKp1,速度ループゲインKv1,速度ループ積分ゲインKi1を位置ループゲイン6と速度ループゲイン12と積分制御器201の速度ループ積分ゲインに設定する。次に位置指令2の差分値の絶対値が0となり、位置偏差の絶対値が所定値以上の時(これを状態2とする)では、指令は0であるが、まだ駆動中であるので、位置ループゲインKp2,速度ループゲインKv2,速度ループ積分ゲインKi2を位置ループゲイン6と速度ループゲイン12と積分制御器201の速度ループ積分ゲインに設定する。最後に位置指令2の差分の絶対値が0で、位置偏差の絶対値が所定値以下の時(これを状態3とする)、モータは停止状態であると見なし、位置ループゲインKp3,速度ループゲインKv3,速度ループ積分ゲインKi3を位置ループゲイン6と速度ループゲイン12と積分制御器201の速度ループ積分ゲインに設定する。ゲイン切換時点、例えば状態1から状態2に変わった瞬間は、現在速度ループゲイン(Kv[i])はKv2であり、1サンプリング過去の速度ループゲイン(Kv[i−1])はKv1を表す。また、状態1が持続されている間は、現在の速度ループゲインも1サンプリング過去の速度ループゲインもKv1を表す。この時、(4)式のKv[i−1]はKv1であり、Kv[i]もKv1であることを表している。18は、現在の速度ループゲインを表示するモニタである。モニタ18の出力信号を計測装置などで取り込むことにより、運転状態を確認することができる。   The multiplication result of the motor speed and the speed loop gain 12 and the integrated output value are input to the 301 adder. A torque command that is an output of the adder 301 is input to the 13 current controller, and the current controller 13 outputs a current that drives the 14 motors. The 16 gain changers will be described. A position command 2 and a position deviation 5 are input to the gain switch 16 and the gain switch calculates the absolute value of the difference value of the position command 2 and the absolute value of the position deviation 5. When the absolute value of the difference value of the position command 2 is larger than a predetermined value (this is assumed to be state 1), this indicates that the motor starts to move, and the position loop gain Kp1, the speed loop gain Kv1, and the speed loop integral gain Ki1 is set to the position loop gain 6, the speed loop gain 12, and the speed loop integral gain of the integral controller 201. Next, when the absolute value of the difference value of the position command 2 is 0 and the absolute value of the position deviation is greater than or equal to a predetermined value (this is referred to as state 2), the command is 0, but is still being driven. Position loop gain Kp2, speed loop gain Kv2, and speed loop integral gain Ki2 are set to position loop gain 6, speed loop gain 12, and speed loop integral gain of integral controller 201. Finally, when the absolute value of the difference of the position command 2 is 0 and the absolute value of the position deviation is equal to or smaller than a predetermined value (this is referred to as state 3), the motor is considered to be stopped, and the position loop gain Kp3, speed loop The gain Kv3, the speed loop integral gain Ki3 are set to the position loop gain 6, the speed loop gain 12, and the speed loop integral gain of the integral controller 201. At the time of gain switching, for example, at the moment when the state changes from state 1 to state 2, the current speed loop gain (Kv [i]) is Kv2, and the speed loop gain (Kv [i-1]) of one sampling past represents Kv1. . While state 1 is maintained, both the current speed loop gain and the speed loop gain of one sampling past represent Kv1. At this time, Kv [i−1] in the equation (4) is Kv1, and Kv [i] is also Kv1. Reference numeral 18 denotes a monitor that displays the current speed loop gain. The operation state can be confirmed by capturing the output signal of the monitor 18 with a measuring device or the like.

次に、本発明のモータ制御装置(図3)と従来のモータ制御装置2(図8)をシミュレーションした。このシミュレーションでの各条件を説明する。指令発生器1では、速度台形指令を積分して位置指令として、減算器4に入力する。指令は、0sから加速し、0.1sで最大速度1000(1/min)に到達する。0.1sから0.3sまで速度1000(1/min)を維持し、0.3sから0.4sまで減速し、指令払い出し終了は、0.4sとなる。その後、指令0であり、0.6sからまた負方向に加速し、0.7sで−1000(1/min)に到達し、0.7sから0.9sまで速度−1000(1/min)を維持し、0.9sから減速して、1sで指令払い出し完了とする速度台形指令とした。モータ13には、定格トルクの10%に相当する外乱トルクを入力した。ゲイン切換器16の切換条件とゲイン設定値を次のように設定した。状態1は位置指令の差分の絶対値が1パルス以上として、位置ループゲインKp1=100Hz、速度ループゲインKv1=160Hz、速度ループ積分ゲインKi1=2πKv1として、状態2は位置指令2の差分の絶対値が0で位置偏差の絶対値が10パルスよりも大きい時とし、位置ループゲインKp2=90Hz、速度ループゲインKv2=150Hz、速度ループ積分ゲインKi2=2πKv2とした。さらに状態3は位置指令2の差分の絶対値が0で、位置偏差の絶対値が10パルス以下の時として、位置ループゲインKp3=80Hz、速度ループゲインKv3=80Hz、速度ループ積分ゲインKi3=2πKv3とした。それに対して従来装置2では、位置指令の差分値が1パルス以上の時には、位置ループゲインKp1=100Hz、速度ループゲインKv1=160Hz、速度ループ積分ゲインKvi1=(2πKv1)^2とし、位置指令の差分値が0で速度フィードバックが1(1/min)より大きい時には、位置ループゲインKp2=90Hz、速度ループゲインKv2=150Hz、速度ループ積分ゲインKvi2=(2πKv2)^2とし、位置指令の差分値が0で速度フィードバックが1(1/min)以下であれば、位置ループゲインKp3=80Hz、速度ループゲインKv3=80Hz、速度ループ積分ゲインKvi3=(2πKv3)^2とした。従来装置2の説明には、ゲイン切換の条件に、動作状態(位置指令、位置フィードバック、速度フィードバック、トルク指令)を使うとあるが、どのような状態でゲイン切り換えするのかが、説明されていないため、上記のように位置指令の差分値とモータ速度を切換条件とした。この条件でモータ速度の波形比較(図9)とモータ位置の波形比較(図10)をした。まず図9を説明する。本発明の装置ではゲイン切換は図中BとCの時点で実行される。B時点以前が状態2であり、B時点以降が状態3であり、C時点以降は状態1である。従来装置のゲイン切換は、図中AとCの時点で実行される。A時点以前はKp2、Kv2、Kvi2のゲインを利用し、A時点からC時点まではKp3、Kv3、Kvi3のゲインを利用し、C時点以降はKp1、Kv1、Kvi1を利用するようにしている。A時点以前は、本発明装置による結果と従来装置による結果は一致しており良好であるが、A時点のゲイン切換により、従来装置2では速度フィードバックが、不連続な動きをしていることがわかる。それに対して、本発明装置のゲイン切換時点Bでは、不連続な動きはほとんど見られず良好である。C時点は指令が入力され、ゲイン切換が行われるが、本発明装置1および従来装置2で良好な結果となった。次に図10を説明する。図中A、B、Cは上記説明と同じなので、説明を省略する。A時点以前は、本発明装置と従来装置2の結果は一致し、良好であるが、A時点のゲインの切り換わりで、従来装置の応答が遅くなっていることがわかる。位置決め完了を目標位置の±5パルスとすると従来装置2の応答は6ms程度遅れている。   Next, the motor control device of the present invention (FIG. 3) and the conventional motor control device 2 (FIG. 8) were simulated. Each condition in this simulation will be described. The command generator 1 integrates the speed trapezoid command and inputs it to the subtracter 4 as a position command. The command accelerates from 0 s and reaches a maximum speed of 1000 (1 / min) in 0.1 s. The speed 1000 (1 / min) is maintained from 0.1 s to 0.3 s, the speed is reduced from 0.3 s to 0.4 s, and the completion of command payout is 0.4 s. After that, the command is 0, acceleration is again negative from 0.6 s, reaches −1000 (1 / min) at 0.7 s, and reaches speed −1000 (1 / min) from 0.7 s to 0.9 s. The speed trapezoidal command is set to be maintained, decelerated from 0.9 s, and command delivery completed in 1 s. A disturbance torque corresponding to 10% of the rated torque was input to the motor 13. The switching condition and gain setting value of the gain switch 16 were set as follows. State 1 has an absolute value of position command difference of 1 pulse or more, position loop gain Kp1 = 100 Hz, speed loop gain Kv1 = 160 Hz, speed loop integral gain Ki1 = 2πKv1, state 2 has an absolute value of difference of position command 2 Is 0 and the absolute value of the position deviation is larger than 10 pulses, the position loop gain Kp2 = 90 Hz, the speed loop gain Kv2 = 150 Hz, and the speed loop integral gain Ki2 = 2πKv2. Further, in state 3, when the absolute value of the difference of the position command 2 is 0 and the absolute value of the position deviation is 10 pulses or less, the position loop gain Kp3 = 80 Hz, the speed loop gain Kv3 = 80 Hz, and the speed loop integral gain Ki3 = 2πKv3. It was. On the other hand, in the conventional apparatus 2, when the position command difference value is 1 pulse or more, the position loop gain Kp1 = 100 Hz, the speed loop gain Kv1 = 160 Hz, the speed loop integral gain Kvi1 = (2πKv1) ^ 2, and the position command When the difference value is 0 and the speed feedback is larger than 1 (1 / min), the position loop gain Kp2 = 90 Hz, the speed loop gain Kv2 = 150 Hz, the speed loop integral gain Kvi2 = (2πKv2) ^ 2, and the position command difference value. Is 0 and the speed feedback is 1 (1 / min) or less, the position loop gain Kp3 = 80 Hz, the speed loop gain Kv3 = 80 Hz, and the speed loop integral gain Kvi3 = (2πKv3) ^ 2. In the description of the conventional apparatus 2, an operation state (position command, position feedback, speed feedback, torque command) is used as a gain switching condition, but it does not explain in what state the gain switching is performed. Therefore, as described above, the difference value of the position command and the motor speed are set as the switching conditions. Under these conditions, the motor speed waveform comparison (FIG. 9) and the motor position waveform comparison (FIG. 10) were performed. First, FIG. 9 will be described. In the apparatus of the present invention, gain switching is executed at time points B and C in the figure. The state before time B is state 2, the time after time B is state 3, and the time after time C is state 1. The gain switching of the conventional device is executed at time points A and C in the figure. The gains of Kp2, Kv2, and Kvi2 are used before time A, the gains of Kp3, Kv3, and Kvi3 are used from time A to time C, and Kp1, Kv1, and Kvi1 are used after time C. Before the time A, the result of the device of the present invention and the result of the conventional device agree and are good, but due to the gain switching at the time A, the speed feedback in the conventional device 2 may be discontinuous. Recognize. On the other hand, at the gain switching time B of the device of the present invention, the discontinuous movement is hardly seen, which is good. At time C, a command is input and gain switching is performed, but the present invention device 1 and the conventional device 2 have good results. Next, FIG. 10 will be described. In the figure, A, B, and C are the same as described above, and thus the description thereof is omitted. Before time A, the results of the device of the present invention and the conventional device 2 agree and are good, but it can be seen that the response of the conventional device is delayed due to the gain switching at time A. If positioning completion is set to ± 5 pulses of the target position, the response of the conventional apparatus 2 is delayed by about 6 ms.

図4は請求項4に記載のモータ制御装置を表しており、400の外部信号(例えば、現在の負荷状態を表す信号)を16のゲイン切換装置に入力し、モータ制御装置の位置ループゲイン6と速度ループゲイン12と速度ループ積分ゲイン201を外部信号400の値に応じて、位置ループゲイン(Kp1,Kp2,Kp3)のいずれか一つと速度ループゲイン(Kv1,Kv2,Kv3)のいずれか一つと速度ループ積分ゲイン(Ki1,Ki2,Ki3)のいずれか一つを設定する。ゲイン設定の組み合わせとして、例えば位置ループゲインKp1と速度ループゲインKv1と速度ループ積分ゲインKi1を選択する。外部信号を割り込み動作として、位置指令の差分値の絶対値や位置偏差の絶対値条件よりも優先順位を高くしてゲイン切り換えを行うことができる。   FIG. 4 shows a motor control device according to a fourth aspect of the invention. 400 external signals (for example, a signal indicating the current load state) are input to 16 gain switching devices, and the position loop gain 6 of the motor control device is shown. The speed loop gain 12 and the speed loop integral gain 201 are set to any one of the position loop gain (Kp1, Kp2, Kp3) and the speed loop gain (Kv1, Kv2, Kv3) according to the value of the external signal 400. One of the speed loop integral gains (Ki1, Ki2, Ki3) is set. As a combination of gain settings, for example, a position loop gain Kp1, a speed loop gain Kv1, and a speed loop integral gain Ki1 are selected. Using an external signal as an interrupt operation, gain switching can be performed with higher priority than the absolute value condition of the difference value of position command and the absolute value condition of position deviation.

図12は、請求項5に記載のゲイン切換器であり、ゲイン切換器で設定されている速度ループゲインをモニタした結果を表している。図12の説明を容易にする為に、図11の説明を交えて以下説明する。図11は本発明のゲイン切換条件に設定している位置指令差分値の絶対値と位置偏差の絶対値の状態変化を表している。図11の状態変化に対応するように図12の速度ループゲインが変化している。図11の指令払い出し完了時点以前(状態1)は、図12では速度ループゲインは160Hzになっており、図11の指令払い出し完了(位置指令の差分値の絶対値が0)時点以降から位置偏差の絶対値が10パルスよりも大きい時(状態2)は、図12では速度ループゲインは150Hzとなる。図11で位置指令の差分値の絶対値が0で位置偏差の絶対値が10パルス以内(状態3)で図12では速度ループゲインは80Hzとなっている。さらに、図11で指令開始(位置指令差分値の絶対値が1パルス以上)時点で、図12では速度ループゲインは第1所定値の160Hzとなる事を表している。従来のゲイン切換装置は、ユーザーが現在どのゲイン状態であるのかを確認できなかった。本発明では、例えば、この速度ループゲインをゲイン切換条件設定時にチェックし、デバッグ機能として利用できる。
図13は本発明のモータ制御方法を示すフローチャートである。図13においてステップST1で位置指令の時間差分の絶対値を求める。次にステップST2で位置指令差分絶対値と所定値を比較し、大きい場合はステップST4へ、小さい場合はステップST3へ移行する。次にステップST3で位置偏差の絶対値と所定値を比較し、大きい場合はステップST5へ、小さい場合はステップST6へ移行する。次にステップST4で位置制御ゲイン、速度制御ゲインを第1所定値に切換える。また、ステップST5で位置制御ゲイン、速度制御ゲインを中間ゲインの第2所定値に切換える。さらに、ステップST6で位置制御ゲイン、速度制御ゲインを第3所定値に切換える。次にステップST7で速度制御器の積分器出力を補正式(1)を使用して補正する。なお第1所定値>第2所定値>第3所定値である。
FIG. 12 is a gain switch according to claim 5 and shows the result of monitoring the speed loop gain set by the gain switch. In order to facilitate the description of FIG. 12, the following description will be made in conjunction with the description of FIG. FIG. 11 shows the state change of the absolute value of the position command difference value and the absolute value of the position deviation set in the gain switching condition of the present invention. The speed loop gain of FIG. 12 changes so as to correspond to the state change of FIG. Before the command payout completion time (state 1) in FIG. 11, the speed loop gain is 160 Hz in FIG. 12, and the position deviation from the time after the command payout completion (absolute value of the position command difference value is 0) in FIG. When the absolute value of is larger than 10 pulses (state 2), the speed loop gain is 150 Hz in FIG. In FIG. 11, the absolute value of the difference value of the position command is 0, the absolute value of the position deviation is within 10 pulses (state 3), and in FIG. 12, the speed loop gain is 80 Hz. Furthermore, in FIG. 11, when the command is started (the absolute value of the position command difference value is 1 pulse or more), FIG. 12 shows that the speed loop gain is the first predetermined value of 160 Hz. The conventional gain switching device cannot confirm which gain state the user is currently in. In the present invention, for example, this speed loop gain is checked when the gain switching condition is set, and can be used as a debugging function.
FIG. 13 is a flowchart showing the motor control method of the present invention. In FIG. 13, the absolute value of the time difference of the position command is obtained in step ST1. Next, in step ST2, the position command difference absolute value is compared with a predetermined value. If larger, the process proceeds to step ST4, and if smaller, the process proceeds to step ST3. Next, in step ST3, the absolute value of the position deviation is compared with a predetermined value, and if larger, the process proceeds to step ST5, and if smaller, the process proceeds to step ST6. Next, in step ST4, the position control gain and the speed control gain are switched to the first predetermined value. In step ST5, the position control gain and the speed control gain are switched to the second predetermined value of the intermediate gain. In step ST6, the position control gain and the speed control gain are switched to a third predetermined value. Next, in step ST7, the integrator output of the speed controller is corrected using the correction equation (1). The first predetermined value> the second predetermined value> the third predetermined value.

本発明によると、制御ゲイン切換えを簡素化し、PI型とI−P型の速度制御両方で利用できる積分補正式を用いて補正し、位置決め時間の短いモータ制御装置と制御方法を提供できるので、ロボットや工作機械だけでなくなめらかなエレベータ制御への適用も期待できる。   According to the present invention, it is possible to provide a motor control device and a control method having a short positioning time by simplifying control gain switching and correcting using an integral correction formula that can be used in both PI type and IP type speed control. It can be expected to be applied not only to robots and machine tools but also to smooth elevator control.

本発明の第1実施例を表すモータ制御装置Motor controller representing first embodiment of the present invention 本発明の第2実施例を表すモータ制御装置Motor control device representing a second embodiment of the present invention 本発明の第3実施例を表すモータ制御装置Motor control device representing a third embodiment of the present invention 本発明の第4実施例を表すモータ制御装置Motor controller representing a fourth embodiment of the present invention 請求項1記載の装置と従来装置1(図8)との速度フィードバック比較結果Results of speed feedback comparison between the apparatus according to claim 1 and the conventional apparatus 1 (FIG. 8) 請求項1記載の装置と従来装置1(図8)との位置フィードバック比較結果Position feedback comparison result between the apparatus according to claim 1 and the conventional apparatus 1 (FIG. 8) 従来装置1Conventional device 1 従来装置2Conventional device 2 請求項3記載の装置と従来装置2(図9)との速度フィードバック比較結果Results of speed feedback comparison between the apparatus according to claim 3 and the conventional apparatus 2 (FIG. 9) 請求項3記載の装置と従来装置2(図9)との位置フィードバック比較結果Position feedback comparison result between the apparatus according to claim 3 and the conventional apparatus 2 (FIG. 9) 位置指令差分の絶対値と位置偏差の絶対値の結果Result of absolute value of position command difference and absolute value of position deviation 速度ループゲインのモニタ結果Monitoring result of speed loop gain モータ制御方法を示すフローチャートFlow chart showing motor control method

符号の説明Explanation of symbols

1 指令発生器
2 位置指令
3 モータ位置
4、8、11、800、802 減算器
5 位置偏差
6 位置制御ゲイン
7 差分演算器
9、200、300 速度比例積分制御器
10、201 積分制御器
12、202 速度制御ゲイン
13 電流制御器
14、809 サーボモータ
15、810 検出器
16 ゲイン切換器
17 設定パラメータ
18 モニタ
301、807 加算器
400 外部信号
701 パルス発生器
702 サーボドライバ
703 パルス間隔計測器
704 サーボ定数切換器
705 サーボ制御器
801 位置ループゲイン
803 速度検出器
804 速度ループゲイン
805 積分器
806 速度ループ積分ゲイン
808 サーボアンプ
811 動作状態判断部
812 ゲイン変更部
813 速度偏差積分値変更部

DESCRIPTION OF SYMBOLS 1 Command generator 2 Position command 3 Motor position 4, 8, 11, 800, 802 Subtractor 5 Position deviation 6 Position control gain 7 Difference calculator 9, 200, 300 Speed proportional integration controller 10, 201 Integration controller 12, 202 Speed control gain 13 Current controller 14, 809 Servo motor 15, 810 Detector 16 Gain switch 17 Setting parameter 18 Monitor 301, 807 Adder 400 External signal 701 Pulse generator 702 Servo driver 703 Pulse interval measuring instrument 704 Servo constant Switch 705 Servo controller 801 Position loop gain 803 Speed detector 804 Speed loop gain 805 Integrator 806 Speed loop integral gain 808 Servo amplifier 811 Operation state determination unit 812 Gain change unit 813 Speed deviation integral value change unit

Claims (1)

位置指令を生成する位置指令生成器と、前記位置指令とモータ位置の偏差を入力し速度指令を生成する位置制御器と、前記速度指令とモータ速度の偏差を入力しトルク指令を生成する速度制御器と、前記トルク指令を入力しモータ駆動電流を生成する電流制御器と、前記位置制御器の位置制御ゲインと前記速度制御器の速度制御ゲインを位置指令差分絶対値と位置偏差絶対値の値に応じて切換えるゲイン切換器とを備えたモータ制御装置において、
前記位置指令の時間差分の絶対値である位置指令差分絶対値が1パルス以上のときは、
前記位置制御ゲイン、前記速度制御ゲインを第1所定値に切換え、前記位置指令差分絶対値が0で前記位置偏差の絶対値である位置偏差絶対値が所定値以上のときは、前記位置制御ゲイン、前記速度制御ゲインを前記第1所定値より小さい値を持つ第2所定値に切換え、
前記位置指令差分絶対値が0で前記位置偏差絶対値が所定値よりも小さい時は、前記位置制御ゲイン、前記速度制御ゲインを前記第2所定値より小さい値を持つ第3所定値に切換える前記ゲイン切換器を備え、前記速度制御器はI−P制御もしくはP−I制御器で、積分器出力値に速度ゲインを乗算する構成であり、前記積分器出力は1サンプリング過去の積分出力値v[i−1]に1サンプリング過去の速度ループゲインKv[i−1]を乗算し該乗算結果を現在の速度ループゲインKv[i]で除算した結果と、現在の速度偏差Verr[i]とサンプリング時間Tsを乗算し乗算結果を速度ループ積分ゲインKi[i]で乗算した結果と、を加算した値であることを特徴とするモータ制御装置。
A position command generator for generating a position command, a position controller for inputting a deviation between the position command and the motor position to generate a speed command, and a speed control for generating a torque command by inputting the deviation between the speed command and the motor speed. , A current controller that inputs the torque command to generate a motor drive current, a position control gain of the position controller, and a speed control gain of the speed controller, the position command difference absolute value and the position deviation absolute value In a motor control device provided with a gain switching device that switches according to
When the position command difference absolute value that is the absolute value of the time difference of the position command is 1 pulse or more,
The position control gain and the speed control gain are switched to a first predetermined value, and when the position command difference absolute value is 0 and the position deviation absolute value, which is the absolute value of the position deviation, is greater than or equal to a predetermined value, the position control gain , Switching the speed control gain to a second predetermined value having a value smaller than the first predetermined value,
When the position command difference absolute value is 0 and the position deviation absolute value is smaller than a predetermined value, the position control gain and the speed control gain are switched to a third predetermined value having a value smaller than the second predetermined value. A gain switch, wherein the speed controller is an IP control or a PI controller, and is configured to multiply the integrator output value by a speed gain, and the integrator output is an integral output value v of one sampling past. Multiply [i−1] by one sampling past speed loop gain Kv [i−1] and divide the result by the current speed loop gain Kv [i], and the current speed deviation Verr [i] A motor control device characterized by being a value obtained by adding a result obtained by multiplying a sampling time Ts and multiplying the multiplication result by a speed loop integral gain Ki [i] .
JP2005148057A 2005-05-20 2005-05-20 Motor control device Expired - Fee Related JP4671171B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2005148057A JP4671171B2 (en) 2005-05-20 2005-05-20 Motor control device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2005148057A JP4671171B2 (en) 2005-05-20 2005-05-20 Motor control device

Publications (2)

Publication Number Publication Date
JP2006323745A JP2006323745A (en) 2006-11-30
JP4671171B2 true JP4671171B2 (en) 2011-04-13

Family

ID=37543360

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2005148057A Expired - Fee Related JP4671171B2 (en) 2005-05-20 2005-05-20 Motor control device

Country Status (1)

Country Link
JP (1) JP4671171B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013027105A (en) * 2011-07-19 2013-02-04 Toshiba Corp Motor driving circuit and motor driving system
KR102121393B1 (en) * 2019-03-18 2020-06-10 군산대학교 산학협력단 Position Control Method And Position Controller

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11231941A (en) * 1998-02-10 1999-08-27 Matsushita Electric Ind Co Ltd Method and device for controlling positioning
JP2000284805A (en) * 1999-03-31 2000-10-13 Shibaura Mechatronics Corp Feedback controller
JP2000293234A (en) * 1999-04-08 2000-10-20 Matsushita Electric Ind Co Ltd Motor control gain switching method

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11231941A (en) * 1998-02-10 1999-08-27 Matsushita Electric Ind Co Ltd Method and device for controlling positioning
JP2000284805A (en) * 1999-03-31 2000-10-13 Shibaura Mechatronics Corp Feedback controller
JP2000293234A (en) * 1999-04-08 2000-10-20 Matsushita Electric Ind Co Ltd Motor control gain switching method

Also Published As

Publication number Publication date
JP2006323745A (en) 2006-11-30

Similar Documents

Publication Publication Date Title
US8928267B2 (en) Motor controller
JP4335123B2 (en) Control device
JP5596093B2 (en) Motor controller for correcting backlash
US20060161274A1 (en) Position control device, measuring device and machining device
US20200171661A1 (en) Method for transmitting information in controller and method for detecting abnormality in encoder
JP2016004316A (en) Motor control device for controlling motor
JP5623757B2 (en) Motor control method and apparatus
JP4075803B2 (en) Motor control device
JP2019144809A (en) Servo control device
JP2011176907A5 (en)
US20070007927A1 (en) Position controller and controlling method therefor
JP5201300B2 (en) Motor control device
JP4671171B2 (en) Motor control device
JPH09282020A (en) Servo motor driving device
KR101711996B1 (en) Electric gripper system and control method thereof
JPH11143548A (en) Friction compensating method for motor
JP5018410B2 (en) Electric motor control device
JP4636271B2 (en) Servo control device and adjustment method thereof
JP4409115B2 (en) Position control device and position control method
JP2011175308A (en) Method and apparatus for controlling feed drive system of machine tool
JP3438195B2 (en) Motor control device
JP3352612B2 (en) Position control servo device and servo control method for position control system
JP2003047269A (en) Servo controller
JP7501402B2 (en) Control system and control method
JP4987302B2 (en) Driving method of stepping motor

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20080411

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20100107

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20100202

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20100319

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20100928

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20101125

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

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20110109

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

Free format text: PAYMENT UNTIL: 20140128

Year of fee payment: 3

LAPS Cancellation because of no payment of annual fees