[go: up one dir, main page]

JP2002281787A - Speed control method of stepping motor, weaving control method in welding machine, metal body to be welded - Google Patents

Speed control method of stepping motor, weaving control method in welding machine, metal body to be welded

Info

Publication number
JP2002281787A
JP2002281787A JP2001079902A JP2001079902A JP2002281787A JP 2002281787 A JP2002281787 A JP 2002281787A JP 2001079902 A JP2001079902 A JP 2001079902A JP 2001079902 A JP2001079902 A JP 2001079902A JP 2002281787 A JP2002281787 A JP 2002281787A
Authority
JP
Japan
Prior art keywords
pulses
output
stepping motor
speed
acceleration
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.)
Pending
Application number
JP2001079902A
Other languages
Japanese (ja)
Inventor
Hisashi Hattori
恒 服部
Ikuo Mibu
生男 壬生
Kenichi Maeda
謙一 前田
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.)
Hitachi Engineering and Services Co Ltd
Tokyo Gas Co Ltd
Original Assignee
Hitachi Engineering and Services Co Ltd
Tokyo Gas Co Ltd
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 Hitachi Engineering and Services Co Ltd, Tokyo Gas Co Ltd filed Critical Hitachi Engineering and Services Co Ltd
Priority to JP2001079902A priority Critical patent/JP2002281787A/en
Publication of JP2002281787A publication Critical patent/JP2002281787A/en
Pending legal-status Critical Current

Links

Landscapes

  • Control Of Stepping Motors (AREA)

Abstract

(57)【要約】 【課題】 脱調を起こすことなく大きな加減速を実現す
ることができるステッピングモータの速度制御方法を提
供する。 【解決手段】 a1〜a4が前回の長周期における計算
された出力パルス数で整数値、b1〜b4が今回の長周
期における計算された出力パルス数で整数値である。す
なわち、当初の計算では、a1〜b4に記憶されたパル
ス数が、2ms毎にこの順番で出力されることになってい
る。ソート用バッファc1〜c4は、出力パルスバッフ
ァに入れられた今回出力値b1〜b4を並べ替えるため
のバッファである。出力レジスタは、シフトレジスタの
機能を有し、2ms毎に図の左端のレジスタ内の値に相当
する数のパルスが出力され、その都度、各レジスタの値
が左側にシフトされる。
(57) [Problem] To provide a speed control method of a stepping motor capable of realizing large acceleration / deceleration without step-out. SOLUTION: a1 to a4 are integer numbers indicating the number of output pulses calculated in the previous long cycle, and b1 to b4 are integer numbers indicating the number of output pulses calculated in the present long cycle. That is, in the initial calculation, the number of pulses stored in a1 to b4 is output in this order every 2 ms. The sorting buffers c1 to c4 are buffers for rearranging the current output values b1 to b4 stored in the output pulse buffer. The output register has the function of a shift register, and outputs a number of pulses corresponding to the value in the leftmost register in the figure every 2 ms. Each time, the value of each register is shifted to the left.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明はステッピングモータ
の速度制御方法、当該ステッピングモータの速度制御方
法を使用した溶接機におけるウィービング制御方法、及
び、このウィービング制御方法を使用して溶接された被
溶接金属体に関するものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a speed control method for a stepping motor, a weaving control method in a welding machine using the stepping motor speed control method, and a metal to be welded using the weaving control method. It is about the body.

【0002】[0002]

【従来の技術】アークを利用して金属体の溶接を行う溶
接機にいては、溶接ワイヤを溶接部の幅方向に高速で運
動させることにより、溶融金属が溶接部の幅方向全体に
行き渡るようにしている。このような溶接ワイヤの往復
運動をウィービングと呼んでいる。
2. Description of the Related Art In a welding machine for welding a metal body by using an arc, a welding wire is moved at a high speed in a width direction of a welding portion so that a molten metal spreads over the entire width direction of the welding portion. I have to. Such reciprocating movement of the welding wire is called weaving.

【0003】従来、このようなウィービングを行うため
に、溶接トーチをサーボモータにより駆動することが行
われてきた。サーボモータは高速な加減速制御が可能で
あり、このような機能を必要とされるウィービング制御
に使用するのに最適なものと考えられていた。
Conventionally, in order to perform such weaving, a welding torch has been driven by a servomotor. Servomotors are capable of high-speed acceleration / deceleration control, and have been considered to be optimal for use in weaving control that requires such a function.

【0004】しかしながら、サーボモータは、その位置
制御を行うためにエンコーダ等の付属装置を用いたフィ
ードバック制御を不可欠のものとしており、溶接のアー
クや漏れ電流により発生する高ノイズ下においては、こ
れらのエンコーダがノイズにより誤動作してしまうとい
う問題があった。また、フィードバック制御装置を必要
とするため、価格が高価になるという問題点があった。
[0004] However, the servomotor requires feedback control using an accessory device such as an encoder in order to control the position of the servomotor. There is a problem that the encoder malfunctions due to noise. In addition, since a feedback control device is required, there is a problem that the price is high.

【0005】[0005]

【発明が解決しようとする課題】発明者らは、このよう
な問題点を解決するため、ウィービング制御に、サーボ
モータの代わりにステッピングモータを使用することを
考慮した。ステッピングモータはエンコーダ等のセンサ
を必要とせず、かつ、フィードバック制御を行わないの
で、ノイズに強く、かつ安価であるという特長を有す
る。
SUMMARY OF THE INVENTION In order to solve such a problem, the inventors have considered using a stepping motor instead of a servo motor for weaving control. Since the stepping motor does not require a sensor such as an encoder and does not perform feedback control, it has a feature of being resistant to noise and being inexpensive.

【0006】しかしながら、市販のステッピングモータ
は、加減速を大きくすると脱調を起こすことがある。ま
た、一定速度で運転される場合でも、その速度がパルス
数に対して半端なものである場合には、平均的に一定速
度を保つために指令パルス数を頻繁に変動させなければ
ならず、これに起因して脱調を起こすことがある。
However, a commercially available stepping motor may lose synchronism when the acceleration / deceleration is increased. Also, even when operating at a constant speed, if the speed is odd with respect to the number of pulses, the number of command pulses must be changed frequently to maintain a constant speed on average, This can cause loss of synchrony.

【0007】本発明はこのような事情に鑑みてなされた
もので、加減速を大きくしても脱調することなく、かつ
一定速度を保つために指令パルス数を頻繁に変動させな
くて済むようにし、安価でノイズに強いステッピングモ
ータにおいても、脱調を起こすことなく大きな加減速を
実現することができるステッピングモータの速度制御方
法、このようなステッピングモータの制御方法を使用し
た溶接機におけるウィービング制御方法、及びこのよう
な溶接機によって溶接された被溶接金属体を提供するこ
とを課題とする。
SUMMARY OF THE INVENTION The present invention has been made in view of the above circumstances, and it is not necessary to frequently change the number of command pulses so as not to lose synchronism even if acceleration / deceleration is increased and to maintain a constant speed. A speed control method of a stepping motor capable of realizing a large acceleration / deceleration without step-out even in a stepping motor which is inexpensive and resistant to noise, and a weaving control in a welding machine using such a stepping motor control method. It is an object to provide a method and a metal body to be welded by such a welding machine.

【0008】[0008]

【課題を解決するための手段】前記課題を解決するため
の第1の手段は、ステッピングモータの速度を制御する
方法であって、短周期の第1サンプリング周期と、その
整数倍の周期の第2サンプリング周期を設定し、第1サ
ンプリング周期毎のステッピングモータの指令速度を求
め、その指令速度に対応する出力パルス数を求めるに際
し、端数パルス分は順次、次のサンプリング時刻におけ
る出力パルスに累算して加えることにより、第1サンプ
リング周期毎の出力パルス数を求め、求められた出力パ
ルス数を、前記第2サンプリング内でソートして出力パ
ルス数の順に並べ替え、(1) モータが加速中のとき、加
速から定速運転に移るとき、定速運転から加速に移ると
きは、前記第2サンプリング周期中においては、パルス
数の小さいものから大きいものの順に前記第1サンプリ
ング周期ごとに出力パルス数に対応するパルスを出力
し、(2) モータが減速中、減速から定速運転に移ると
き、定速運転から減速に移るときは、前記第2サンプリ
ング周期中においては、パルス数の大きいものから小さ
いものの順に前記第1サンプリング周期ごとに出力パル
ス数に対応するパルスを出力し、(3) モータが定速運転
中のときは、前記第2サンプリング周期中において、パ
ルス数の小さいものから大きいものの順に前記第1サン
プリング周期ごとに出力パルス数に対応するパルスを出
力する制御と、パルス数の大きいものから小さいものの
順に前記第1サンプリング周期ごとに出力パルス数に対
応するパルスを出力する制御とを前記第2サンプリング
周期毎に交互に繰り返し、(4) モータが加速から減速に
移るとき、又は減速から加速に移るときは、前記第2サ
ンプリング周期中において、ソート前に計算されたパル
ス数をそのまま出力することを特徴とするステッピング
モータの速度制御方法(請求項1)である。
According to a first aspect of the present invention, there is provided a method of controlling a speed of a stepping motor, comprising: a first sampling cycle having a short period and a first sampling period having an integral multiple thereof. Two sampling periods are set, the command speed of the stepping motor is obtained for each first sampling period, and the number of output pulses corresponding to the command speed is calculated. The fractional pulses are sequentially accumulated in the output pulse at the next sampling time. The number of output pulses for each first sampling period is obtained, and the obtained number of output pulses is sorted in the second sampling and rearranged in the order of the number of output pulses. When moving from acceleration to constant-speed operation, or when moving from constant-speed operation to acceleration, during the second sampling period, the pulse number is smaller. A pulse corresponding to the number of output pulses is output in order of the first sampling cycle in descending order of the number of pulses. (2) When the motor shifts from deceleration to constant speed operation during deceleration, or when the motor shifts from constant speed operation to deceleration, During the two sampling periods, pulses corresponding to the number of output pulses are output in the first sampling period in ascending order from the largest pulse number to the smallest pulse number. (3) When the motor is operating at a constant speed, the second pulse is output. During the sampling period, control is performed to output pulses corresponding to the number of output pulses in each of the first sampling periods in order from the smallest pulse number to the largest pulse. The control for outputting pulses corresponding to the number of output pulses is alternately repeated for each second sampling period. A method for controlling the speed of a stepping motor, comprising: outputting the number of pulses calculated before sorting during the second sampling period when shifting to deceleration or shifting from deceleration to acceleration (claim 1). It is.

【0009】本手段においては、長周期である第2サン
プリング周期毎に速度パターンを決定することを基本と
するが、この第2サンプリング周期を分割した短周期で
ある第1サンプリング周期毎にパルスを出力するように
している。
In this means, the speed pattern is basically determined for each second sampling period which is a long period, but a pulse is generated for each first sampling period which is a short period obtained by dividing the second sampling period. Output.

【0010】よって、第1に比較的長周期における速度
パターンの変化を考慮しながら短周期でパルスを出力し
ているので、ステッピングモータの速度変化がスムース
に行われる。このため脱調の危険性が低くなり、それに
伴って、安定に実現できる加減速度を大きくすることが
できる。
[0010] First, since pulses are output in a short cycle while considering changes in the speed pattern in a relatively long cycle, the speed of the stepping motor is smoothly changed. For this reason, the risk of step-out is reduced, and the acceleration / deceleration that can be stably realized can be increased accordingly.

【0011】また、第2のサンプリング周期内で第1の
サンプリング周期毎の出力パルス数をソートしている。
そして、加速中のとき、加速から定速運転に移るとき、
定速運転から加速に移るときは、前記第2サンプリング
周期中においては、パルス数の小さいものから大きいも
のの順に前記第1サンプリング周期ごとに出力パルス数
に対応するパルスを出力しているので、加速中において
は出力パルス数が単調増加となり、モータ速度が減速す
ることがなくなるので、脱調が起こりにくい。
Further, the number of output pulses for each first sampling period is sorted in the second sampling period.
And when moving from acceleration to constant speed operation during acceleration,
When shifting from constant speed operation to acceleration, during the second sampling period, pulses corresponding to the number of output pulses are output in the first sampling period in ascending order of the pulse number. In the middle, the number of output pulses monotonically increases and the motor speed does not decrease, so that step-out hardly occurs.

【0012】同様、モータが減速中、減速から定速運転
に移るとき、定速運転から減速に移るときは、前記第2
サンプリング周期中においては、パルス数の大きいもの
から小さいものの順に前記第1サンプリング周期ごとに
出力パルス数に対応するパルスを出力しているので、減
速中においては出力パルス数が単調減少となり、モータ
速度が加速することがなくなるので、脱調が起こりにく
い。
Similarly, when the motor shifts from deceleration to constant speed operation during deceleration, and when the motor shifts from constant speed operation to deceleration, the second
During the sampling period, pulses corresponding to the number of output pulses are output in the first sampling period in ascending order of the number of pulses, so that the number of output pulses monotonically decreases during deceleration, and the motor speed is reduced. Is no longer accelerated, so step-out is unlikely to occur.

【0013】又、モータが定速運転中のときは、前記第
2サンプリング周期中において、パルス数の小さいもの
から大きいものの順に前記第1サンプリング周期ごとに
出力パルス数に対応するパルスを出力する制御と、パル
ス数の大きいものから小さいものの順に前記第1サンプ
リング周期ごとに出力パルス数に対応するパルスを出力
する制御とを前記第2サンプリング周期毎に交互に繰り
返しているので、第2サンプリング周期中では、モータ
は定速と加速のみ、又は定速と減速のみの速度変動を行
い、パルスの端数を調整するために加速と減速を短周期
で繰り返すようなことがない。よって、脱調が起こりに
くい。又、本手段によれば、パルスの端数処理を行って
もスムースな運転ができるので、指令速度を連続的に変
えることができる。
When the motor is operating at a constant speed, control is performed such that during the second sampling cycle, pulses corresponding to the number of output pulses are output in the first sampling cycle in ascending order of the number of pulses from the smallest. And the control of outputting pulses corresponding to the number of output pulses in the first sampling cycle in the order from the largest pulse number to the smallest pulse number are alternately repeated in the second sampling cycle. In this case, the motor changes the speed only at a constant speed and acceleration or only at a constant speed and deceleration, and does not repeat acceleration and deceleration in a short cycle to adjust the fraction of the pulse. Therefore, step-out is unlikely to occur. According to this means, even if the fraction processing of the pulse is performed, the smooth operation can be performed, so that the command speed can be continuously changed.

【0014】モータが加速から減速に移るとき、又は減
速から加速に移るときは、ソートを行ったものを出力す
ると制御が乱れるので、前記第2サンプリング周期中に
おいて、ソート前に計算されたパルス数をそのまま出力
する。
When the motor shifts from acceleration to deceleration or from deceleration to acceleration, control is disturbed if a sorted signal is output. Therefore, during the second sampling period, the number of pulses calculated before the sorting is calculated. Is output as is.

【0015】以上の説明において、加速、減速、定速の
判定は、例えば、第2サンプリング周期中の平均モータ
速度を前回サンプリング周期と今回サンプリング周期に
ついて比較し、これらの値の差が所定値以上の場合は加
減速、所定値未満の場合は定速と判断する。又、ソート
前の最初の出力と最後の出力を比較して、後者が前者よ
り所定値以上大きければ加速、前者が後者より所定値以
上大きければ減速、それ以外は定速と判断するようにし
てもよい。
In the above description, the acceleration, deceleration and constant speed are determined, for example, by comparing the average motor speed during the second sampling cycle with the previous sampling cycle and the current sampling cycle, and when the difference between these values is equal to or greater than a predetermined value. Is determined to be acceleration / deceleration, and if less than the predetermined value, it is determined to be constant. Also, by comparing the first output and the last output before sorting, if the latter is larger than the former by a predetermined value, it is determined that acceleration is performed, if the former is larger than the latter by a predetermined value, deceleration is performed, otherwise, it is determined that the speed is constant. Is also good.

【0016】又、加速から減速、減速から加速に移る場
合であることを判断するのは、例えば以下のようにす
る。すなわち、ソート前において、今回の第2サンプリ
ング周期中の第1サンプリングタイミングにおける最大
速度と、最初の第1サンプリングタイミングにおける速
度の差(絶対値)が所定値以上で、かつ、今回の第2サ
ンプリング周期中の第1サンプリングタイミングにおけ
る最大速度と、最後の第1サンプリングタイミングにお
ける速度の差(絶対値)が所定値以上であるとき、加速
から減速に移行していると判断する。
The determination of the transition from acceleration to deceleration and from deceleration to acceleration is made, for example, as follows. That is, before sorting, the difference (absolute value) between the maximum speed at the first sampling timing during the current second sampling period and the speed at the first first sampling timing is equal to or greater than a predetermined value, and When the difference (absolute value) between the maximum speed at the first sampling timing in the cycle and the speed at the last first sampling timing is equal to or greater than a predetermined value, it is determined that the operation has shifted from acceleration to deceleration.

【0017】同様、ソート前において、今回の第2サン
プリング周期中の第1サンプリングタイミングにおける
最小速度と、最初の第1サンプリングタイミングにおけ
る速度の差(絶対値)が所定値以上で、かつ、今回の第
2サンプリング周期中の第1サンプリングタイミングに
おける最小速度と、最後の第1サンプリングタイミング
における速度の差(絶対値)が所定値以上であるとき、
減速から加速に移行していると判断する。
Similarly, before sorting, the difference (absolute value) between the minimum speed at the first sampling timing in the current second sampling cycle and the speed at the first first sampling timing is equal to or more than a predetermined value, and When the difference (absolute value) between the minimum speed at the first sampling timing in the second sampling cycle and the speed at the last first sampling timing is equal to or greater than a predetermined value,
It is determined that the mode has shifted from deceleration to acceleration.

【0018】これらの判断においは、定速運転中である
という判断と、加速から減速、減速から加速に移る場合
であるとの判断が両方出ることがあるが、この場合は後
者を優先させることが望ましい。
In these determinations, there may be both a determination that the vehicle is operating at a constant speed and a determination that the vehicle is moving from acceleration to deceleration and from deceleration to acceleration. In this case, the latter is given priority. Is desirable.

【0019】前記課題を解決するための第2の手段は、
前記第1の手段であって、前記第1サンプリング周期
が、ステッピングモータの定格サンプリング周期(定格
出力周期)より短く設定されていることを特徴とするも
の(請求項2)である。
A second means for solving the above-mentioned problem is:
The first means, wherein the first sampling cycle is set shorter than a rated sampling cycle (rated output cycle) of the stepping motor (Claim 2).

【0020】前述のように、前記第1の手段において
は、ステッピングモータの加減速をスムースにし、か
つ、無駄な加減速を無くすることができるので、前記第
1のサンプリング周期を、ステッピングモータの定格サ
ンプリング周期より短くすることができる。これによ
り、ステッピングモータの加減速を定格より大きくする
ことができる。
As described above, in the first means, the acceleration and deceleration of the stepping motor can be made smooth and unnecessary acceleration and deceleration can be eliminated. It can be shorter than the rated sampling period. Thereby, the acceleration / deceleration of the stepping motor can be made larger than the rating.

【0021】前記課題を解決するための第3の手段は、
ステッピングモータの速度を制御する方法であって、加
減速を行うとき、その加減速時の速度パターンをS字型
として出力パルス数を求めることを特徴とするステッピ
ングモータの速度制御方法(請求項3)である。
A third means for solving the above problem is as follows.
A method for controlling the speed of a stepping motor, comprising the steps of: when performing acceleration / deceleration, determining the number of output pulses by setting the speed pattern at the time of acceleration / deceleration to an S-shape. ).

【0022】ステッピングモータで加減速を行うとき
は、速度をランプ状に加減速するのが一般的である。し
かし、この方法によると、加減速の開始及び終了時に大
きな加速度がステッピングモータにかかり、ステッピン
グモータが脱調する可能性がある。本手段においては、
加減速時の速度パターンをS字型として出力パルス数を
求めているので、ランプ状に加減速を行う場合に比し
て、ステッピングモータにかかる加速度を小さくするこ
とができ、ステッピングモータの脱調を防止することが
できる。よって、その分、急激な加減速を行うことがで
きる。
When accelerating or decelerating with a stepping motor, the speed is generally ramped. However, according to this method, a large acceleration is applied to the stepping motor at the start and end of the acceleration / deceleration, and the stepping motor may lose synchronism. In this means,
Since the number of output pulses is obtained by setting the speed pattern at the time of acceleration / deceleration to an S-shape, the acceleration applied to the stepping motor can be reduced as compared with the case where acceleration / deceleration is performed in a ramp shape, and the stepping motor loses synchronism. Can be prevented. Therefore, rapid acceleration / deceleration can be performed accordingly.

【0023】前記課題を解決するための第4の手段は、
前記第1の手段又は第2の手段と、前記第3の手段とを
組み合わせたステッピングモータの速度制御方法(請求
項4)である。
A fourth means for solving the above-mentioned problem is:
This is a speed control method for a stepping motor in which the first means or the second means is combined with the third means (claim 4).

【0024】本手段においては、前記第1の手段又は第
2の手段と、前記第3の手段の作用効果が共に奏され、
これらを組み合わせた作用効果を得ることができる。
In the present means, the functions and effects of the first means or the second means and the third means are exhibited together,
The effect obtained by combining these can be obtained.

【0025】前記課題を解決するための第5の手段は、
溶接機においてトーチのウィービングを行うためにステ
ッピングモータを使用し、そのステッピングモータを前
記第1の手段から第4の手段のいずれかにより制御する
ことを特徴とする溶接機におけるウィービング制御方法
(請求項5)である。
A fifth means for solving the above problem is as follows.
A weaving control method for a welding machine, comprising: using a stepping motor for weaving a torch in a welding machine; and controlling the stepping motor by any of the first to fourth means. 5).

【0026】本手段によれば、溶接トーチのウィービン
グ制御を、ステッピングモータを使用してスムースかつ
高速に行うことができるので、ノイズに強く安価な装置
により、高速で精密なウィービング制御を実現すること
ができる。
According to this means, the weaving control of the welding torch can be performed smoothly and at high speed by using the stepping motor. Therefore, high-speed and precise weaving control can be realized by an inexpensive device which is resistant to noise. Can be.

【0027】前記課題を解決するための第6の手段は、
前記第5の手段を使用して溶接されたことを特徴とする
被溶接金属体(請求項6)である。
A sixth means for solving the above-mentioned problem is:
A welded metal body welded using the fifth means (claim 6).

【0028】本手段においては、高速で精密なウィービ
ング制御を使用して溶接が行われているので、製造費用
が安価となる。
In this means, since welding is performed using high-speed and precise weaving control, the manufacturing cost is reduced.

【0029】[0029]

【発明の実施の形態】以下、本発明の実施の形態の例を
図を用いて説明する。以下の処理においては、ステッピ
ングモータの標準出力周期が8msであるものとし、それ
を改良して2ms周期で出力を行うものとする。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS Hereinafter, embodiments of the present invention will be described with reference to the drawings. In the following processing, it is assumed that the standard output cycle of the stepping motor is 8 ms, and the output is performed at a cycle of 2 ms by improving the standard output cycle.

【0030】図1は、制御に用いるためのバッファとレ
ジスタの一部を示す図であり、これらのバッファとレジ
スタは、マイクロコンピュータのメモリを使用しても実
現できる。出力バッファレジスタは、2ms(短周期)毎
に出力されるパルス数を計算して格納しておくもので、
今回の長周期(8ms)と、前回の長周期における値の整
数値と、その端数が記憶されている。
FIG. 1 is a diagram showing a part of buffers and registers used for control. These buffers and registers can be realized by using a memory of a microcomputer. The output buffer register calculates and stores the number of pulses output every 2 ms (short cycle).
The current long cycle (8 ms), the integer value of the value in the previous long cycle, and its fraction are stored.

【0031】図において、a1〜a4が前回の長周期に
おける計算された出力パルス数で整数値、b1〜b4が
今回の長周期における計算された出力パルス数で整数値
である。すなわち、当初の計算では、a1〜b4に記憶
されたパルス数が、2ms毎にこの順番で出力されること
になっている。a'1〜b'4は、速度をパルス数に計算する
ときに出た端数が格納される場所であり、端数の処理方
法については後述する。
In the figure, a1 to a4 are integer values of the number of output pulses calculated in the previous long cycle, and b1 to b4 are integer numbers of the calculated output pulses in the current long cycle. That is, in the initial calculation, the number of pulses stored in a1 to b4 is output in this order every 2 ms. a'1 to b'4 are locations where fractions obtained when calculating the speed into the number of pulses are stored, and a method of processing the fraction will be described later.

【0032】ソート用バッファc1〜c4は、出力パル
スバッファに入れられた今回出力値b1〜b4を並べ替
えるためのバッファである。出力レジスタは、シフトレ
ジスタの機能を有し、2ms毎に図の左端のレジスタ内の
値に相当する数のパルスが出力され、その都度、各レジ
スタの値が左側にシフトされる。
The sorting buffers c1 to c4 are buffers for rearranging the current output values b1 to b4 stored in the output pulse buffer. The output register has the function of a shift register, and outputs a number of pulses corresponding to the value in the leftmost register in the figure every 2 ms. Each time, the value of each register is shifted to the left.

【0033】以下、このようなバッファやレジスタを用
いた本発明の実施の形態であるステッピングモータの制
御方法の例を図2、図3に示すフローチャートを使用し
て説明する。図2は、制御の全体の流れを示すフローチ
ャートであり、図3は、その中で本発明の技術的思想の
中心部分であるソートの機能を示すフローチャートであ
る。
An example of a method of controlling a stepping motor according to an embodiment of the present invention using such buffers and registers will be described below with reference to flowcharts shown in FIGS. FIG. 2 is a flowchart showing the overall flow of control, and FIG. 3 is a flowchart showing a sorting function which is a central part of the technical idea of the present invention.

【0034】図2に示すフローチャートは、短周期であ
る2ms毎に起動される。まず、S11で8msの長周期タ
イミングであるかどうかを判断し、長周期タイミングで
ない場合はステップS16に移行する。
The flowchart shown in FIG. 2 is activated every short period of 2 ms. First, it is determined in S11 whether or not the timing is a long cycle timing of 8 ms. If the timing is not the long cycle timing, the process proceeds to step S16.

【0035】長周期タイミングである場合は、ステップ
S12に移行し、今回の8msの間に出力するパルス数を
計算する。すなわち、今、次の2ms、4ms、6msの4回
分の出力パルス数を計算する。ここで、2msごとに1パ
ルス出力されたときモータの回転数がa[rpm]であった
とする。あるタイミングでの速度指令がb[rpm]であっ
たとすると、出力すべきパルス数はb/a個であるが、
この値は整数とならないのが普通である。
If it is the long cycle timing, the process proceeds to step S12, and the number of pulses to be output during the current 8 ms is calculated. That is, the number of output pulses for four times of the next 2 ms, 4 ms, and 6 ms is calculated. Here, it is assumed that the rotation number of the motor is a [rpm] when one pulse is output every 2 ms. If the speed command at a certain timing is b [rpm], the number of pulses to be output is b / a.
This value is usually not an integer.

【0036】この問題を解決するために、本実施の形態
においては、以下のような端数処理を行っている。すな
わち、計算されたパルス数に端数が出た場合、それを次
回の出力パルスの計算に加えることにより、端数を吸収
する。すなわち、前回の出力パルスの計算における端数
をcとすると、今回の出力パルス数Nと出力パルスの端
数c’は、 N=[b/a+c] …(1) c’=b/a+c−N …(2) となる。ただし、[ ]は、[ ]内の値を超えない最大の整
数を示す。このようにして計算された出力パルス数が、
出力パルスバッファのb1〜b4に入れられる。そし
て、端数c’の値は、b'1〜b'4に入れられる。その後、
出力パルスバッファのb1〜b4の値をソートバッファ
に移してステップS13のソート処理に移行する。
In order to solve this problem, in the present embodiment, the following fraction processing is performed. In other words, if the calculated pulse number has a fraction, the fraction is absorbed by adding it to the calculation of the next output pulse. That is, assuming that the fraction in the previous output pulse calculation is c, the current output pulse number N and the output pulse fraction c ′ are: N = [b / a + c] (1) c ′ = b / a + c−N (2) However, [] indicates the largest integer that does not exceed the value in []. The number of output pulses calculated in this way is
The output pulse buffers are stored in b1 to b4. Then, the value of the fraction c 'is put in b'1 to b'4. afterwards,
The values of b1 to b4 in the output pulse buffer are transferred to the sort buffer, and the flow shifts to the sort processing in step S13.

【0037】ソート処理においては、図3に示すような
処理を行う。まず、ステップS131で、ステッピング
モータが加速中であるかどうかを判断する。これは、出
力パルスバッファの前回出力値であるa1〜a4の平均
値又は積算値と、今回出力値であるb1〜b4の平均値
又は積算値を比較し、後者の方が前者よりも所定値以上
大きかったら加速中であると判断することにより行う。
もし、加速中であれば、ステップS132に移行し、ソ
ート用バッファの値を左から小さい順に並べ替える。
In the sorting process, a process as shown in FIG. 3 is performed. First, in step S131, it is determined whether the stepping motor is accelerating. This compares the average value or integrated value of the previous output values a1 to a4 of the output pulse buffer with the average value or integrated value of the current output values b1 to b4, and the latter is a predetermined value compared to the former. If it is larger than this, it is determined that the vehicle is accelerating.
If the acceleration is being performed, the process proceeds to step S132, and the values of the sort buffer are rearranged in ascending order from the left.

【0038】次に、ステップS133で、ステッピング
モータが減速中であるかどうかを判断する。これは、出
力パルスバッファの前回出力値であるa1〜a4の平均
値又は積算値と、今回出力値であるb1〜b4の平均値
又は積算値を比較し、前者の方が後者よりも所定値以上
大きかったら減速中であると判断することにより行う。
もし、減速中であれば、ステップS134に移行し、ソ
ート用バッファの値を左から大きい順に並べ替える。
Next, in step S133, it is determined whether or not the stepping motor is decelerating. This is because the average value or integrated value of the previous output values a1 to a4 of the output pulse buffer is compared with the average value or integrated value of the current output values b1 to b4, and the former is a predetermined value compared to the latter. If it is larger than the above, it is determined that the vehicle is decelerating.
If the vehicle is decelerating, the process proceeds to step S134, and the values of the sort buffer are rearranged in descending order from the left.

【0039】次に、ステップS135で、ステッピング
モータが定速であるかどうかを判断する。これは、加速
中という条件にも、減速中という条件にも当てはまらな
いことにより判断される。この場合には、ステップS1
36に移行し前回の8msにおいて、パルス数を小さい順
に並べ替えたときは大きい順に並べ替え、前回の8msに
おいて、パルス数を大きい順に並べ替えたときは小さい
順に並べ替える。すなわち、定速状態が継続する場合に
は、小さい順と大きい順に、8ms毎に交互に並べ替え
る。
Next, in step S135, it is determined whether or not the stepping motor is at a constant speed. This is determined because neither the condition during acceleration nor the condition during deceleration is applied. In this case, step S1
When the process is shifted to 36 and the pulse number is rearranged in ascending order in the previous 8 ms, the pulse is rearranged in descending order, and in the previous 8 ms, the pulse number is rearranged in ascending order. That is, when the constant speed state continues, the data is rearranged alternately every 8 ms in ascending order and descending order.

【0040】最後に、ステップ147で対象とする8ms
の間に、速度指令が加速から減速、又は減速から加速に
切り替わっていないかどうかをチェックする。なお、こ
のチェックは、ステップS141の前に行い、この条件
に当てはまるときはソートを行わないでステップS16
に移行するようにしてもよい。
Finally, 8 ms targeted in step 147
During the period, it is checked whether the speed command has switched from acceleration to deceleration or from deceleration to acceleration. Note that this check is performed before step S141, and when this condition is satisfied, sorting is not performed and step S16 is performed.
It may be made to shift to.

【0041】この条件に当てはまるかどうかは、本実施
の形態においては以下のように判断している。すなわ
ち、今回の8msに出力される4回のパルス出力のうち、
最大のパルス数のものと、最初に出力されるパルス数と
の差が所定値以上であり、かつ、最大のパルス数のもの
と、最後に出力されるパルス数との差が所定値以上であ
ある場合は、加速から減速に移行していると判断する。
Whether or not this condition is satisfied is determined in the present embodiment as follows. That is, of the four pulse outputs output in 8 ms this time,
The difference between the maximum pulse number and the first output pulse number is equal to or greater than a predetermined value, and the difference between the maximum pulse number and the last output pulse number is equal to or greater than a predetermined value. If so, it is determined that the mode has shifted from acceleration to deceleration.

【0042】又、今回の8msに出力される4回のパルス
出力のうち、最初に出力されるパルス数と最小のパルス
数のものとの差が所定値以上であり、かつ、最後に出力
されるパルス数と最小のパルス数のものとの差が所定値
以上である場合は、減速から加速に移行していると判断
する。
Also, of the four pulse outputs output in the current 8 ms, the difference between the first output pulse number and the minimum pulse number output is greater than a predetermined value, and the last output pulse number is the last output pulse number. If the difference between the number of pulses and the minimum number of pulses is equal to or greater than a predetermined value, it is determined that the mode has shifted from deceleration to acceleration.

【0043】そして、このようなときはパルスのソート
を行わないで、ステップS138で、出力パルスバッフ
ァからソート用バッファに移された値をそのままの状態
にするようにする。すでに、ステップS132、S13
4、S136でソートを行ってしまっている場合は元に
戻す。
In such a case, the pulses are not sorted, and the value transferred from the output pulse buffer to the sort buffer is left as it is in step S138. Steps S132 and S13 have already been performed.
4. If the sort has been performed in S136, the process is returned to the original state.

【0044】このようにして、ソート処理が終了した場
合は、図1のステップS14に移行して、ソートされた
結果を、出力レジスタd1〜d4に移す。そして、ステ
ップS15で、出力パルスバッファの今回出力値b1〜
b4、b'1〜b'4を、前回出力値a1〜a4、a'1〜a'4に
移す。
When the sorting process is completed as described above, the process proceeds to step S14 in FIG. 1, and the sorted result is transferred to the output registers d1 to d4. Then, in step S15, the current output values b1 to b1 of the output pulse buffer
b4, b'1 to b'4 are moved to the previous output values a1 to a4, a'1 to a'4.

【0045】最後に、ステップS16で、図1に示す出
力レジスタの左端のレジスタに対応するパルス数を出力
すると共に、出力レジスタを左側へシフトする。
Finally, in step S16, the number of pulses corresponding to the leftmost register of the output register shown in FIG. 1 is output, and the output register is shifted to the left.

【0046】図4〜図7に、実際のステッピングモータ
の速度制御の例を示す。図4は定速運転、図5は加速運
転、図6は減速運転、図7は加速運転から減速運転への
移行時の例を示すものである。いずれの図においても、
タイミングは、制御の開始からのmsを示すものであり、
モータ速度は、1ms当たりのパルス数(kpps)、計算パ
ルス数は2ms毎に出力されるべきパルス数、整数パルス
数は前記(1)式により計算されたパルス数N、残端数
パルス数は前記(2)式により計算された半端のパルス
数c’である。いずれの方式においても、パルスモータ
の定格のパルス出力タイミングは8ms毎であるとし、そ
れを4等分した2ms毎にパルスを出力するようにしてい
る。
4 to 7 show examples of actual speed control of the stepping motor. 4 shows an example of a constant speed operation, FIG. 5 shows an example of an acceleration operation, FIG. 6 shows an example of a deceleration operation, and FIG. 7 shows an example of a transition from an acceleration operation to a deceleration operation. In both figures,
The timing indicates ms from the start of control,
The motor speed is the number of pulses per 1 ms (kpps), the calculated number of pulses is the number of pulses to be output every 2 ms, the integer number of pulses is the number of pulses N calculated by the above equation (1), and the remaining number of pulses is This is the odd pulse number c ′ calculated by the equation (2). In any of the methods, the rated pulse output timing of the pulse motor is assumed to be every 8 ms, and a pulse is output every 2 ms obtained by dividing the pulse output timing into four.

【0047】図4は、定速運転を行っている場合を示
し、モータ速度が16.7[kpps]とされている場合のもので
ある。このときの理論的な計算パルス数は33.4となる。
このとき、(1)式で計算された整数パルス数、残端数
パルス数は、図に示すようなものとなる。この実施の形
態においては、8ms毎に計算された整数パルス数をソー
トしている。すなわち、0〜6msにおいては整数パルス
数を小さい順に並べ、次の8ms〜14msにおいては整数パ
ルスを大きい順に並べ、これを8ms毎に交互に繰り返
す。もちろん、最初の8msに整数パルスを大きい順に並
べ、次の8msに整数パルスを小さい順に並べるようにし
て、これを交互に繰り返してもよい。
FIG. 4 shows a case in which a constant speed operation is performed, in which the motor speed is 16.7 [kpps]. The theoretical number of calculated pulses at this time is 33.4.
At this time, the number of integer pulses and the number of remaining fraction pulses calculated by the equation (1) are as shown in the figure. In this embodiment, the number of integer pulses calculated every 8 ms is sorted. That is, the integer pulse number is arranged in ascending order from 0 to 6 ms, and the integer pulses are arranged in descending order from 8 ms to 14 ms, and this is alternately repeated every 8 ms. Of course, the integer pulses may be arranged in descending order in the first 8 ms, and the integer pulses may be arranged in descending order in the next 8 ms, and this may be alternately repeated.

【0048】このようにして、ソート後パルス数が得ら
れるので、これを2ms毎に出力パルスとして出力する。
図4に、ソート前のパルス数とソート後のパルス数を合
わせて図示するが、これによると、本発明の特徴である
ソート機能によって、出力パルス数の変動、すなわちモ
ータ速度の変動が少なくなり、脱調が起こりにくくなる
ことがわかる。
In this way, the number of pulses after sorting is obtained, and this is output as an output pulse every 2 ms.
FIG. 4 shows the number of pulses before sorting and the number of pulses after sorting together. According to this, the variation of the number of output pulses, that is, the variation of the motor speed is reduced by the sorting function which is a feature of the present invention. It can be seen that step-out is less likely to occur.

【0049】図5は、ステッピングモータに加速状態の
速度指令が与えられている例を示すものであり、この場
合は、求められた2ms毎の整数パルス数を8msの間でソ
ートしてソート後パルス数を求めるのは、図4に示され
た例と同じであるが、ソートの方法としては常にパルス
数が小さい順に並べている。図5の場合は、この結果、
整数パルス数とソート後パルス数は同じとなっている。
FIG. 5 shows an example in which a speed command in an accelerating state is given to the stepping motor. In this case, the obtained integer number of pulses every 2 ms is sorted between 8 ms and then sorted. The number of pulses is obtained in the same manner as in the example shown in FIG. 4, but as a sorting method, the pulses are always arranged in ascending order of the number of pulses. In the case of FIG.
The integer pulse number and the sorted pulse number are the same.

【0050】図6は、ステッピングモータに減速状態の
速度指令が与えられている例を示すものであり、この場
合も、求められた2ms毎の整数パルス数を8msの間でソ
ートしてソート後パルス数を求めるのは、図4に示され
た例と同じであるが、ソートの方法としては常にパルス
数が大きい順に並べている。図6の場合は、この結果、
整数パルス数とソート後パルス数は同じとなっている。
FIG. 6 shows an example in which a speed command in a decelerating state is given to the stepping motor. In this case as well, the obtained integer number of pulses every 2 ms is sorted for 8 ms and then sorted. The number of pulses is obtained in the same manner as in the example shown in FIG. 4, but as a sorting method, the pulses are always arranged in descending order of the number of pulses. In the case of FIG.
The integer pulse number and the sorted pulse number are the same.

【0051】図4から図6における例においては、今回
の8ms周期内の2ms毎の整数パルスの和と、前回の8ms
周期内の2ms毎の整数パルスの和が1以内のとき定速状
態、前者が後者より1を超えて大きいとき加速状態、後
者が前者より1を超えて大きいとき減速状態と判断す
る。
In the examples shown in FIGS. 4 to 6, the sum of the integer pulses every 2 ms in the current 8 ms cycle and the previous 8 ms
A constant speed state is determined when the sum of integer pulses every 2 ms in the cycle is less than 1, an acceleration state is determined when the former is greater than 1 and a deceleration state is determined when the latter is greater than 1 and greater than the former.

【0052】図7に、ステッピングモータの速度指令が
加速から減速に移るときの速度制御の例を示す。最初の
8msにおいてはモータは加速状態にあると判定されソー
トはパルス数の小さい順に行われる。
FIG. 7 shows an example of speed control when the speed command of the stepping motor shifts from acceleration to deceleration. In the first 8 ms, the motor is determined to be in an accelerating state, and sorting is performed in ascending order of the number of pulses.

【0053】次の8msにおいては、今回の8ms周期内の
2ms毎の整数パルスの和よりも、前回の8ms周期内の2
ms毎の整数パルスの和を1[kpps]を超えて大きいので、
一旦は加速状態にあると判断される。しかし、その区間
の最高出力パルス数である50[kpps]よりも、最初の出力
パルス数が2を超えて大きく、かつ、その区間の最高出
力パルス数である50よりも、最後の出力パルス数が2を
超えて小さいため、加速状態から減速状態への移行期間
であると判断され、ソートされないパルス数がそのまま
出力される。
In the next 8 ms, the sum of the integer pulses every 2 ms in the current 8 ms cycle is larger than the sum of the integer pulses in the previous 8 ms cycle.
Since the sum of the integer pulses per ms exceeds 1 [kpps],
It is once determined that the vehicle is in an acceleration state. However, the first output pulse number is larger than 50 [kpps], which is the maximum output pulse number in the section, and the last output pulse number is more than 50, which is the maximum output pulse number in the section. Is smaller than 2 so that it is determined that the transition period is from the acceleration state to the deceleration state, and the number of unsorted pulses is output as it is.

【0054】続く2回の8ms周期においては減速状態に
あると判断され、出力パルス数が大きい順にソートされ
たパルス数が出力される。
In the subsequent two 8 ms periods, it is determined that the vehicle is in the deceleration state, and the pulse numbers sorted in descending order of the output pulse number are output.

【0055】以上の説明においては、標準出力周期であ
る8msを基準にして、その中でソートを行ってきたが、
たとえばその倍の周期である16msを基準にしてソートを
行ってもよく、標準出力周期と関係のない周期でソート
を行うようにしてもよい。
In the above description, sorting has been performed based on the standard output cycle of 8 ms.
For example, the sorting may be performed based on 16 ms, which is twice as long as the standard, or the sorting may be performed at a cycle irrelevant to the standard output cycle.

【0056】定速運転時は、ソートの基準周期を大きく
するほど速度変動が現れる周期を大きくすることがで
き、より脱調が起きにくくなる。例えば、2msで出力を
行う場合、32ms毎にソートを行えば、8msでソートを行
ったときに対して、速度変動回数を1/4にすることが
できる。
At the time of constant speed operation, as the reference cycle of sorting is increased, the cycle in which the speed fluctuation appears can be increased, and the step-out becomes more difficult to occur. For example, in the case of performing output in 2 ms, if sorting is performed every 32 ms, the number of speed fluctuations can be reduced to 1/4 of that in the case of performing sorting in 8 ms.

【0057】図8にステッピングモータの加速パターン
の例を示す。従来のステッピングモータの加減速制御に
おいては、図8(a)に示すように、ランプ状に加速
(又は減速)を行うようにされていた。しかし、この場
合、図8(a)に示すように、加速の開始時と終了時に
瞬間的に大きな加速度がモータに作用し、脱調を生じや
すかった。そのため、ランプの傾き、すなわち加速度を
余り大きくすることができなかった。
FIG. 8 shows an example of the acceleration pattern of the stepping motor. In a conventional acceleration / deceleration control of a stepping motor, as shown in FIG. 8A, acceleration (or deceleration) is performed in a ramp shape. However, in this case, as shown in FIG. 8A, a large acceleration instantaneously acts on the motor at the start and end of the acceleration, so that the motor is likely to lose synchronism. Therefore, the inclination of the ramp, that is, the acceleration cannot be made too large.

【0058】図8(b)は、本発明の実施の形態である
加速制御の1例を示すもので、加速開始点と加速終了点
との間を、S字型のパターンの速度とするように制御し
ている。具体的には、加速開始点Aと加速終了点Bとの
中点Cに対して互いに点対称な2つの放物線で加速開始
点Aと加速終了点を結び、しかも、これらの放物線の軸
が図の縦軸に平行で、かつその頂点が、それぞれ点A、
Bにあるようにする。
FIG. 8B shows an example of the acceleration control according to the embodiment of the present invention, in which the speed between the acceleration start point and the acceleration end point is set to the speed of the S-shaped pattern. Is controlled. Specifically, the acceleration start point A and the acceleration end point are connected by two parabolas that are point-symmetric with respect to the midpoint C between the acceleration start point A and the acceleration end point B, and the axes of these parabolas are shown in FIG. And the vertices thereof are points A,
B.

【0059】このようにすると、図8(b)に示すよう
に、加速度は0からランプ状に増加し、中点Cで最大と
なり、以後ランプ状に低下して点Bで0に戻るようにな
る。よって、最大加速度が小さくなると共に滑らかにな
るので、モータが脱調しにくい。よって、その分、全体
としての加速度を大きくすることができる。
In this way, as shown in FIG. 8 (b), the acceleration increases in a ramp form from 0, reaches a maximum at the middle point C, then decreases in a ramp form and returns to 0 at the point B. Become. Therefore, since the maximum acceleration becomes smaller and smoother, the motor hardly loses synchronism. Therefore, the acceleration as a whole can be increased accordingly.

【0060】なお、S字カーブをどのようなパターンに
するかは、上記のようなものに限られるものではなく、
例えば、加速時間のうち、最初の1/4を放物線状、次
の1/2をランプ状、次の1/4を再び放物線状とする
ようにしてもよいし、最初の1/3を放物線状、次の1
/3をランプ状、次の1/3を再び放物線状とするよう
にしてもよい。
It should be noted that the pattern of the S-shaped curve is not limited to the one described above.
For example, of the acceleration time, the first 4 may be parabolic, the next ラ ン プ may be ramp-shaped, the next 4 may be parabolic again, or the first 3 may be parabolic. State, next one
A third may be a ramp shape, and the next third may be a parabolic shape again.

【0061】以上のようにして決定された加減速パター
ンに基づいて、図1〜図7に示したような処理を行う
と、さらに滑らかな速度制御となり、ステッピングモー
タの加減速が小さくなって、脱調が起こりにくくなる。
When the processing shown in FIGS. 1 to 7 is performed based on the acceleration / deceleration pattern determined as described above, smoother speed control is achieved, and the acceleration / deceleration of the stepping motor is reduced. Step-out is less likely to occur.

【0062】従来技術の欄で説明したように、溶接機に
おいては溶接ワイヤを往復運動させるウィービングが行
われている。モータを利用してウィービングを行う方法
自体は周知のものであるし、例えば特開平11−179
542号公報、特開平11−179543号公報に記載
されているので、その説明を省略する。
As described in the section of the prior art, weaving is performed in a welding machine to reciprocate a welding wire. The method itself of performing weaving using a motor is well known.
542 and JP-A-11-179543, the description thereof will be omitted.

【0063】これらのウィービングの制御においては、
ウィービング軌跡を所定のものとするために、モータの
加減速制御を行わなければならない。このようなウィー
ビング制御に、モータとして、ステッピングモータを使
用し、今までに説明してきたような本発明の方法により
そのステッピングモータを制御すれば、速度変化を滑ら
かにでき、急加減速を行っても脱調が起こらないので、
ウィービング速度を速くできる。よって、サーボモータ
を使用せずにすみ、安価なシステムによりウィービング
制御が実現できると共に、エンコーダを使用しないので
ノイズに強いシステムとすることができる。
In controlling these weaving,
In order to make the weaving trajectory a predetermined one, acceleration / deceleration control of the motor must be performed. In such a weaving control, a stepping motor is used as a motor, and if the stepping motor is controlled by the method of the present invention as described above, the speed change can be made smooth and rapid acceleration / deceleration can be performed. Does not lose synchronism,
Weaving speed can be increased. Therefore, weaving control can be realized with an inexpensive system without using a servomotor, and a system that is resistant to noise can be achieved because an encoder is not used.

【0064】そして、このようなウィービング制御方法
を使用すれば、被溶接金属体を、安価に製造することが
できる。
When such a weaving control method is used, a metal body to be welded can be manufactured at low cost.

【0065】[0065]

【発明の効果】以上説明したように、本発明のうち請求
項1に係る発明においては、ステッピングモータの速度
変化がスムースに行われる。このため脱調の危険性が低
くなり、それに伴って、安定に実現できる加減速度を大
きくすることができる。
As described above, according to the first aspect of the present invention, the speed of the stepping motor is changed smoothly. For this reason, the risk of step-out is reduced, and the acceleration / deceleration that can be stably realized can be increased accordingly.

【0066】請求項2に係る発明においては、ステッピ
ングモータの加減速を定格より大きくすることができ
る。請求項3に係る発明においては、ステッピングモー
タにかかる加速度を小さくすることができ、その分、急
激な加減速を行うことができる。
In the invention according to claim 2, the acceleration / deceleration of the stepping motor can be made larger than the rated value. According to the third aspect of the present invention, the acceleration applied to the stepping motor can be reduced, and rapid acceleration and deceleration can be performed accordingly.

【0067】請求項4に係る発明においては、請求項1
に係る発明又は請求項2に係る亜発明と、請求項3に係
る発明の作用効果が共に奏され、これらを組み合わせた
作用効果を得ることができる。
In the invention according to claim 4, claim 1 is
And the sub-invention according to claim 2 and the function and effect of the invention according to claim 3 can be obtained, and the function and effect obtained by combining these can be obtained.

【0068】請求項5に係る発明においては、ノイズに
強く安価な装置により、高速で精密なウィービング制御
を実現することができる。請求項6に係る発明において
は、高速で精密なウィービング制御を使用して溶接が行
われているので、製造費用が安価となる。
According to the fifth aspect of the present invention, high-speed and precise weaving control can be realized by an inexpensive device which is resistant to noise. In the invention according to claim 6, since welding is performed using high-speed and precise weaving control, manufacturing costs are reduced.

【図面の簡単な説明】[Brief description of the drawings]

【図1】制御に用いるためのバッファとレジスタの一部
を示す図である。
FIG. 1 is a diagram showing a part of a buffer and a register used for control.

【図2】制御の全体の流れを示すフローチャートであ
る。
FIG. 2 is a flowchart showing an overall flow of control.

【図3】ソートの機能を示すフローチャートである。FIG. 3 is a flowchart illustrating a sorting function.

【図4】定速運転時におけるパルス出力数決定の例を示
す図である。
FIG. 4 is a diagram showing an example of determining the number of pulse outputs during constant speed operation.

【図5】加速運転時におけるパルス出力数決定の例を示
す図である。
FIG. 5 is a diagram showing an example of determining a pulse output number during an acceleration operation.

【図6】減速運転時におけるパルス出力数決定の例を示
す図である。
FIG. 6 is a diagram showing an example of determining the number of pulse outputs during a deceleration operation.

【図7】加速運転から減速運転への移行時おけるパルス
出力数決定の例を示す図である。
FIG. 7 is a diagram illustrating an example of determining the number of pulse outputs when shifting from acceleration operation to deceleration operation.

【図8】ステッピングモータの加速パターンの例を示す
図である。
FIG. 8 is a diagram illustrating an example of an acceleration pattern of a stepping motor.

───────────────────────────────────────────────────── フロントページの続き (72)発明者 壬生 生男 茨城県日立市幸町三丁目2番2号 株式会 社日立エンジニアリングサービス内 (72)発明者 前田 謙一 茨城県日立市幸町三丁目2番2号 株式会 社日立エンジニアリングサービス内 Fターム(参考) 5H580 AA03 BB10 FA13 FA24 GG04 GG08 HH39  ──────────────────────────────────────────────────続 き Continuing from the front page (72) Inventor Ikuo Mibu 3-2-2, Sachimachi, Hitachi-shi, Ibaraki Prefecture Within Hitachi Engineering Services Co., Ltd. (72) Inventor Kenichi Maeda 3-2-2, Sachimachi, Hitachi-shi, Ibaraki No. 2 F-term in Hitachi Engineering Services, Ltd. (reference) 5H580 AA03 BB10 FA13 FA24 GG04 GG08 HH39

Claims (6)

【特許請求の範囲】[Claims] 【請求項1】 ステッピングモータの速度を制御する方
法であって、短周期の第1サンプリング周期と、その整
数倍の周期の第2サンプリング周期を設定し、第1サン
プリング周期毎のステッピングモータの指令速度を求
め、その指令速度に対応する出力パルス数を求めるに際
し、端数パルス分は順次、次のサンプリング時刻におけ
る出力パルスに累算して加えることにより、第1サンプ
リング周期毎の出力パルス数を求め、求められた出力パ
ルス数を、前記第2サンプリング内でソートして出力パ
ルス数の順に並べ替え、(1) モータが加速中のとき、加
速から定速運転に移るとき、定速運転から加速に移ると
きは、前記第2サンプリング周期中においては、パルス
数の小さいものから大きいものの順に前記第1サンプリ
ング周期ごとに出力パルス数に対応するパルスを出力
し、(2) モータが減速中、減速から定速運転に移ると
き、定速運転から減速に移るときは、前記第2サンプリ
ング周期中においては、パルス数の大きいものから小さ
いものの順に前記第1サンプリング周期ごとに出力パル
ス数に対応するパルスを出力し、(3) モータが定速運転
中のときは、前記第2サンプリング周期中において、パ
ルス数の小さいものから大きいものの順に前記第1サン
プリング周期ごとに出力パルス数に対応するパルスを出
力する制御と、パルス数の大きいものから小さいものの
順に前記第1サンプリング周期ごとに出力パルス数に対
応するパルスを出力する制御とを前記第2サンプリング
周期毎に交互に繰り返し、(4) モータが加速から減速に
移るとき、又は減速から加速に移るときは、前記第2サ
ンプリング周期中において、ソート前に計算されたパル
ス数をそのまま出力することを特徴とするステッピング
モータの速度制御方法。
1. A method for controlling the speed of a stepping motor, comprising: setting a first sampling cycle of a short cycle and a second sampling cycle of an integral multiple of the first sampling cycle; When calculating the speed and obtaining the number of output pulses corresponding to the commanded speed, the fractional pulses are sequentially accumulated and added to the output pulses at the next sampling time to obtain the number of output pulses for each first sampling period. The number of output pulses obtained is sorted in the second sampling and rearranged in the order of the number of output pulses. (1) When the motor is accelerating, when moving from acceleration to constant speed operation, and when moving from constant speed operation to acceleration, During the second sampling period, the output pulse is output in the first sampling period in ascending order of the number of pulses during the second sampling period. (2) When the motor is decelerating, when shifting from deceleration to constant speed operation, and when shifting from constant speed operation to deceleration, the number of pulses is large during the second sampling period. Output pulses corresponding to the number of output pulses in the first sampling cycle in ascending order from the smallest one. (3) When the motor is operating at a constant speed, the pulses having the smaller number of pulses in the second sampling cycle are output. Control for outputting pulses corresponding to the number of output pulses in the first sampling cycle in the order of larger ones, and Control for outputting pulses corresponding to the number of output pulses in the first sampling cycle in the order of the largest number of pulses from the largest number of pulses (4) When the motor shifts from acceleration to deceleration, or when the motor shifts from deceleration to acceleration, A speed control method for a stepping motor, wherein the number of pulses calculated before sorting is output as it is during two sampling periods.
【請求項2】 請求項1に記載のステッピングモータの
速度制御方法であって、前記第1サンプリング周期が、
ステッピングモータの定格サンプリング周期(定格出力
周期)より短く設定されていることを特徴とするステッ
ピングモータの速度制御方法。
2. The speed control method for a stepping motor according to claim 1, wherein the first sampling period is:
A speed control method for a stepping motor, wherein the speed is set shorter than a rated sampling cycle (rated output cycle) of the stepping motor.
【請求項3】 ステッピングモータの速度を制御する方
法であって、加減速を行うとき、その加減速時の速度パ
ターンをS字型として出力パルス数を求めることを特徴
とするステッピングモータの速度制御方法。
3. A method for controlling the speed of a stepping motor, wherein the speed pattern during acceleration / deceleration is determined as an S-shape during acceleration / deceleration, and the number of output pulses is obtained. Method.
【請求項4】 請求項1又は請求項2に記載のステッピ
ングモータの速度制御方法と、請求項3に記載のステッ
ピングモータの速度制御方法とを併せて有することを特
徴とするステッピングモータの速度制御方法。
4. A stepping motor speed control comprising a stepping motor speed control method according to claim 1 and a stepping motor speed control method according to claim 3. Method.
【請求項5】 溶接機においてトーチのウィービングを
行うためにステッピングモータを使用し、そのステッピ
ングモータを請求項1から請求項4のうちいずれか1項
に記載のステッピングモータの速度制御方法により制御
することを特徴とする溶接機におけるウィービング制御
方法。
5. A stepping motor is used for weaving a torch in a welding machine, and the stepping motor is controlled by the stepping motor speed control method according to any one of claims 1 to 4. Weaving control method in a welding machine characterized by the above-mentioned.
【請求項6】 請求項5に記載のウィービング制御方法
を使用して溶接されたことを特徴とする被溶接金属体。
6. A welded metal body which is welded by using the weaving control method according to claim 5.
JP2001079902A 2001-03-21 2001-03-21 Speed control method of stepping motor, weaving control method in welding machine, metal body to be welded Pending JP2002281787A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2001079902A JP2002281787A (en) 2001-03-21 2001-03-21 Speed control method of stepping motor, weaving control method in welding machine, metal body to be welded

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2001079902A JP2002281787A (en) 2001-03-21 2001-03-21 Speed control method of stepping motor, weaving control method in welding machine, metal body to be welded

Publications (1)

Publication Number Publication Date
JP2002281787A true JP2002281787A (en) 2002-09-27

Family

ID=18936271

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2001079902A Pending JP2002281787A (en) 2001-03-21 2001-03-21 Speed control method of stepping motor, weaving control method in welding machine, metal body to be welded

Country Status (1)

Country Link
JP (1) JP2002281787A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006129597A (en) * 2004-10-28 2006-05-18 Konica Minolta Photo Imaging Inc Driving method, drive mechanism and image pickup apparatus
JP2013062928A (en) * 2011-09-13 2013-04-04 Fuji Electric Co Ltd Synchronous control system
CN112713839A (en) * 2019-10-24 2021-04-27 日本电产株式会社 Motor control device, motor unit, and motor control method

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006129597A (en) * 2004-10-28 2006-05-18 Konica Minolta Photo Imaging Inc Driving method, drive mechanism and image pickup apparatus
JP2013062928A (en) * 2011-09-13 2013-04-04 Fuji Electric Co Ltd Synchronous control system
CN112713839A (en) * 2019-10-24 2021-04-27 日本电产株式会社 Motor control device, motor unit, and motor control method

Similar Documents

Publication Publication Date Title
KR100197165B1 (en) Charging generator for a vehicle including a circuit for suppressing a sudden change in a field current
JPS6135561B2 (en)
JP2002281787A (en) Speed control method of stepping motor, weaving control method in welding machine, metal body to be welded
JP2000050699A (en) Weak field control method for induction motor
US6046561A (en) Commutation control method for a switched reluctance machine
EP0322386A1 (en) Method and apparatus for controlling the magnitude and direction of a current through a winding
US6154002A (en) Control apparatus for permanent magnet electric motor used in electric motor vehicle
CN111045461B (en) Continuous small line segment discrete speed control method for cutting bed
JP7700549B2 (en) Vehicle entrapment detection device
JP3725155B2 (en) Control method of automatic transmission
JP2749349B2 (en) Step motor drive method
JP4089616B2 (en) Magnetic pole detection device for synchronous AC motor and magnetic pole detection method thereof
JP3020714B2 (en) Stepping motor driving method and device
EP0712202B1 (en) Control apparatus for a pulse motor and method for driving a pulse motor
KR100244680B1 (en) Acceleration/deceleration controller of robot and method of the same
US6555987B2 (en) Step motor control for accommodating friction load variation
JP2002262596A (en) Acceleration / deceleration control method
JPH06250718A (en) NC-Reference quantity generation method for positioning control circuit in machine
JP2003259678A (en) Control device for DC brushless motor
US5002029A (en) Method for controlling the firing angle of an internal-combustion engine
JP2520408B2 (en) Drive control method of stepping motor
US6710633B2 (en) Method and arrangement for frequency generation
JP3725316B2 (en) Driving method of 5-phase stepping motor
JP4491401B2 (en) Motor driving circuit and motor driving method
KR100505050B1 (en) Apparatus for interpolating lineation of positioning module