JPH04165503A - Method and device for controlling driving device - Google Patents

Method and device for controlling driving device

Info

Publication number
JPH04165503A
JPH04165503A JP29334590A JP29334590A JPH04165503A JP H04165503 A JPH04165503 A JP H04165503A JP 29334590 A JP29334590 A JP 29334590A JP 29334590 A JP29334590 A JP 29334590A JP H04165503 A JPH04165503 A JP H04165503A
Authority
JP
Japan
Prior art keywords
drive
signal
input
phase
drive device
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
JP29334590A
Other languages
Japanese (ja)
Inventor
Tetsuya Ogawa
哲也 小川
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.)
Komatsu Ltd
Original Assignee
Komatsu 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 Komatsu Ltd filed Critical Komatsu Ltd
Priority to JP29334590A priority Critical patent/JPH04165503A/en
Publication of JPH04165503A publication Critical patent/JPH04165503A/en
Pending legal-status Critical Current

Links

Landscapes

  • Safety Devices In Control Systems (AREA)
  • Control Of Position Or Direction (AREA)

Abstract

PURPOSE:To prevent the runaway of a driving device even in the case the connection of a detector is mistaken by comparing the driving direction derived, based on a detecting signal with the driving direction given by a driving signal, and inverting the phase of the detecting signal, when both of them are different. CONSTITUTION:When the driving of a servomotor 50 is started, a connection discriminator 24 interrupts tentatively a servo-loop and inspects the connection state of an encoder 52. In the case the connection is erroneous, a phase inverting signal 'H' is outputted and a phase inverter 22 is allowed to invert the phase of a detecting signal of the encoder 52, the wiring is corrected as a software, and the control can be executed in the same way as the connection is executed normally. In such a manner, even if the connection of the encoder 52 is erroneous, of such an accident as a servomotor 50 runs away and a mechanical system is damaged can be prevented, and also, the servomotor 50 can be controlled normally without executing the wiring once again.

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は、サーボモータ等をディジタル制御して駆動す
る駆動装置の制御方法およびその装置に関する。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a method and apparatus for controlling a drive device that digitally controls and drives a servo motor or the like.

〔従来の技術] ロボットや各種の自動Ia緘等の駆動源としてす−ボモ
ータが広く採用されている。このようなロボットや自動
機械の制御は、一般に制御対象の速度と位置とを検出し
、この検出値をサーボモータを含む操作部にフィードバ
ックして、操作量、すなわちサーボモータの駆動を修正
するようにしている。そして、フィードバック制御を行
う場合、サーボモータにエンコーダを取り付けて90度
の位相差を有する一対の検出信号を出力させ、サーボモ
ータの回転速度と回転量、および回転方向とを検出して
制御対象の速度、位置を求めるようにしている。
[Prior Art] Speed motors are widely used as drive sources for robots and various types of automatic Ia gates. Control of such robots and automatic machines generally involves detecting the speed and position of the controlled object, feeding back these detected values to the operating unit including the servo motor, and modifying the amount of operation, that is, the drive of the servo motor. I have to. When performing feedback control, an encoder is attached to the servo motor to output a pair of detection signals with a 90 degree phase difference, and the rotation speed, rotation amount, and rotation direction of the servo motor are detected and the control target is detected. I am trying to find the speed and position.

〔発明が解決しようとする課題] ところが、エンコーダの制御部への結線を誤ると、エン
コーダの出力した90度位相の異なった2つのフィード
ハ・ツタ信号(信号A、B)が、制御部に取り違えて取
り込まれることになり、適切な駆動指令を与えたときに
、制御対象がストロークエンドに達するまでサーボモー
タが暴走し、機械系を破損してしまう。そして、サーボ
モータのこのような暴走を防くためには、エンコーダを
接続した際に、結線状態を充分にチエツクし、結線が誤
っている場合に、配線をしなおさなければならない。
[Problem to be Solved by the Invention] However, if the encoder is incorrectly connected to the control unit, the two feeder signals (signals A and B) output from the encoder that are 90 degrees different in phase may be mistakenly sent to the control unit. When an appropriate drive command is given, the servo motor runs out of control until the controlled object reaches the end of its stroke, causing damage to the mechanical system. In order to prevent such runaway of the servo motor, it is necessary to thoroughly check the wiring condition when connecting the encoder, and if the wiring is incorrect, the wiring must be rewired.

本発明は、前記従来技術の欠点を解消するためになされ
たもので、検出器の結線を間違った場合にも駆動装置が
暴走することがない駆動装置の制御方法およびその装置
を提供することを目的としている。
The present invention has been made in order to eliminate the drawbacks of the prior art, and aims to provide a method and device for controlling a drive device that prevents the drive device from running out of control even if the wiring of the detector is incorrect. The purpose is

〔課題を解決するための手段〕[Means to solve the problem]

上記目的を達成するために、本発明に係る駆動装置の制
御方法は、駆動装置の駆動状態を示す信号を検出し、こ
の検出信号を前記駆動装置に与える駆動信号にフィード
バンクする駆動装置の制御方法において、前記検出信号
に基づいて前記駆動装置の駆動方向を求め、この駆動方
向と前記駆動信号により与えた駆動方向とを比較し、両
者が相違したときに前記検出信号の位相を反転して、検
出信号に基づいて求める前記駆動装置の駆動方向を、前
記駆動信号により与えた駆動方向と一致させることを特
徴としている。
In order to achieve the above object, a method for controlling a drive device according to the present invention detects a signal indicating the drive state of the drive device, and controls the drive device by feedbanking this detection signal to a drive signal applied to the drive device. In the method, the drive direction of the drive device is determined based on the detection signal, the drive direction is compared with the drive direction given by the drive signal, and when the two differ, the phase of the detection signal is inverted. , the drive direction of the drive device determined based on the detection signal is made to match the drive direction given by the drive signal.

そして、検出信号の位相の反転は、駆動装置の駆動開始
時に、検出信号の駆動信号へのフィードハックを遮断し
、駆動装置を予め定めた時間または予め定めた量だけ駆
動して行うとよい。
The phase of the detection signal may be inverted by cutting off the feed-hack of the detection signal to the drive signal when the drive device starts driving, and driving the drive device for a predetermined time or by a predetermined amount.

また、本発明に係る駆動装置の制御装置は、駆動装置の
駆動状態を検出し、位相差を有する一対の検出信号を出
力する駆動検出器と、この駆動検出器が出力する前記一
対の検出信号に基づいて、前記駆動装置の駆動方向を求
めて出力する方向判別器と、この方向判別器に入力する
前記一対の検出信号の位相を反転する位相反転器と、前
記方向判別器が求めた前記駆動装置の駆動方向と駆動装
置に与えた駆動方向とを比較して前記駆動検出器の結線
の正誤を判別し、駆動検出器の結線が誤りであるときに
、前記位相反転器に位相反転信号を与え、前記方向判別
器に入力する前記一対の検出信号の位相を反転させる結
線判別器とを有することを特徴としている。
Further, the control device for a drive device according to the present invention includes a drive detector that detects a drive state of the drive device and outputs a pair of detection signals having a phase difference, and a drive detector that outputs a pair of detection signals that are output from the drive detector. a direction discriminator that determines and outputs the drive direction of the drive device based on the direction discriminator; a phase inverter that inverts the phase of the pair of detection signals input to the direction discriminator; The drive direction of the drive device and the drive direction given to the drive device are compared to determine whether the connection of the drive detector is correct or incorrect, and if the connection of the drive detector is incorrect, a phase inversion signal is sent to the phase inverter. and a connection discriminator that inverts the phase of the pair of detection signals input to the direction discriminator.

〔作用〕[Effect]

上記の如く構成した本発明においては、操作部にフィー
ドハ、りする検出信号によって得られた駆動装置の駆動
方向が、駆動装置に与えた駆動信号による駆動方向と逆
である場合に、検出信号を出力する検出器が誤配線され
たものとして検出信号の位相を反転させる。これにより
、結線をしなおすことなくソフト的に結線の修正をし、
検出信号から得た駆動方向と、駆動信号により指示した
駆動方向とが一致させることができ、駆動装置の暴走を
防止して機械系の破損などをなくすことができる。
In the present invention configured as described above, when the drive direction of the drive device obtained by the detection signal fed to the operation section is opposite to the drive direction caused by the drive signal given to the drive device, the detection signal is The phase of the detection signal is inverted, assuming that the output detector is incorrectly wired. This allows you to modify the wiring using software without having to rewire the wiring.
The drive direction obtained from the detection signal and the drive direction instructed by the drive signal can be matched, and runaway of the drive device can be prevented and damage to the mechanical system can be avoided.

なお、検出信号の反転を行う場合、駆動装!の駆動開始
時に、検出信号の駆動信号へのフィードバックを遮断し
て行うと、より安全に誤配線の修正を行うことができる
ばかりでなく、誤動作のi色囲を小さくすることができ
る。
In addition, when inverting the detection signal, the drive unit! By cutting off the feedback of the detection signal to the drive signal at the start of driving, not only can incorrect wiring be corrected more safely, but also the i-color range of malfunction can be made smaller.

〔実施例〕〔Example〕

本発明に係る駆動装置の制御方法および制御装置の好ま
しい実施例を、添付凹面に従って詳説する。
A preferred embodiment of the control method and control device for a drive device according to the present invention will be described in detail according to the attached concavity.

第1図は、本発明の実施例に係る駆動装置を制御する制
御装置のブロック図である。
FIG. 1 is a block diagram of a control device that controls a drive device according to an embodiment of the present invention.

制御装置10は、図示しない制御対象の目標位1の信号
が入力してくる加算器12と、この加算器12の出力側
に接続した位置偏差増幅器14とを有する。そして、位
置偏差増幅器14は、加算器12が出力する制御対象の
目標位置と検出した実際の位置との偏差を増幅し、パル
スまたはアナログによる速度指令をサーボ増幅器40に
出力する。
The control device 10 includes an adder 12 into which a signal of a target position 1 of a controlled object (not shown) is input, and a position error amplifier 14 connected to the output side of the adder 12. Then, the position error amplifier 14 amplifies the deviation between the target position of the controlled object outputted by the adder 12 and the detected actual position, and outputs a pulse or analog speed command to the servo amplifier 40.

また、制御装置10には、加算器12にスイッチ16を
介して接続したアンプダウンカウンタ18、このアップ
ダウンカウンタ18の入力側に接続した方向判別器20
、エンコーダ52の出力信号を受けて方向判別器20に
信号を出力する位相反転器22とが設けであるとともに
、結線判別器24が設けである。この結線判別器24は
、スイッチ16を開閉するとともに、目標位置信号とア
ップダウンカウンタ18の出力信号とが入力するように
なっており、これらの信号に基づいて、エンコーダ52
が出力した信号の位相を反転させる位相反転信号を位相
反転器22に送出する。
The control device 10 also includes an amplifier down counter 18 connected to the adder 12 via a switch 16, and a direction discriminator 20 connected to the input side of the up/down counter 18.
, a phase inverter 22 that receives the output signal of the encoder 52 and outputs a signal to the direction discriminator 20, and a connection discriminator 24. The connection discriminator 24 opens and closes the switch 16, and receives the target position signal and the output signal of the up/down counter 18.Based on these signals, the encoder 52
A phase inversion signal for inverting the phase of the signal outputted by is sent to the phase inverter 22.

位相反転器22は、第2図に示したように、エクスクル
−シブ・オア回路からなり、エクスクル−シブ・オア回
路の一方の入力端子にエンコーダ52が出力した信号A
、Bの一方の信号(パルス1)が、他方の入力端子に結
線判別器24が出力する位相反転信号が入力するように
なっている。
As shown in FIG. 2, the phase inverter 22 consists of an exclusive OR circuit, and receives the signal A output from the encoder 52 to one input terminal of the exclusive OR circuit.
, B (pulse 1), and the phase inverted signal output from the connection discriminator 24 is input to the other input terminal.

そして、エクスクル−ンブ・オア回路の出力側は、方向
判別器20を構成しているラッチ回路2Bのり、入力ピ
ンに接続しである。
The output side of the exclude-OR circuit is connected to the input pin of the latch circuit 2B constituting the direction discriminator 20.

一方、ラッチ回路28のD2人入力ンには、エンコーダ
52が出力した他方の信号(パルス2)が入力するよう
になっている。また、ラッチ回路28のD3人入力ンに
は、ラッチ回路28のQ4出力ビンの出力信号が入力す
るようになっており、D1人入力ンにはQ2出力ビンの
出力信号が入力するようになっている。従って、ラッチ
回路28は、入力するクロックパルスの立ち上がりによ
って、その時のD1〜D4人カビンの入力状態を対応す
るQ、−Q4出力ビンに出力し、その後この状態を保持
するため、Q2出力ビンの出力を入力とするD1人入力
ンは、D2人入力ンの1クロツク前の内容が入力し、同
様にり1入力ピンは1クロツク前のD1人入力ンの内容
が入力する。このため、ラッチ回路28は、クロックパ
ルスの立ち上がりによってラッチされたときに、Q、出
力ビンに1クコンク前のり、入力ビンの内容が出力され
、Q2出力ビンにラッチ時のD2人入力ンの内容が出さ
れ、Q、出力ビンに1クロンク前のD4人入力ンの内容
が、Q、出力ビンにはラッチ時のD4人入力ンの内容が
出力される。
On the other hand, the other signal (pulse 2) output from the encoder 52 is input to the D2 input of the latch circuit 28. Further, the output signal of the Q4 output bin of the latch circuit 28 is input to the D3 input of the latch circuit 28, and the output signal of the Q2 output bin is input to the D1 input of the latch circuit 28. ing. Therefore, the latch circuit 28 outputs the input states of the D1 to D4 person bins at that time to the corresponding Q and -Q4 output bins according to the rising edge of the input clock pulse, and then maintains this state, so that the Q2 output bin is The D1 input pin, which takes the output as an input, receives the contents of the D2 input pin one clock earlier, and similarly, the contents of the D1 input pin one clock earlier are input to the D1 input pin. Therefore, when the latch circuit 28 is latched by the rising edge of the clock pulse, the content of the input bin is outputted to the output bin Q by one clock, and the content of the input bin D at the time of latching is output to the output bin Q2. is output, and the contents of the D4 input pin one clonk before are output to the Q output bin, and the contents of the D4 input pin at the time of latching are output to the Q output bin.

方向判断器20は、ラッチ回路28とデコード回路30
と2つのNAND回路32.34とから構成しである。
The direction determiner 20 includes a latch circuit 28 and a decoding circuit 30.
and two NAND circuits 32 and 34.

そして、デコード回路30は、A、B、C,D入力ピン
にラッチ回路28のQ、、Q2、Qユ、Q4出力ビンが
接続してあり、これらの出力ビンの状態(H”°または
“L”)に応じて、アップダウンカウンタ18にカウン
トアンプ信号またはカウントダウン信号を出力する。す
なわち、デコード回路30の1.8.7.14出力ビン
には、アップダウンカウンタ】8にカウントアンプさせ
るパルスを出力するNAND回路32の入力側が接続し
てあり、4.2.13.11出カピンには、アップダウ
ンカウンタ18にカウントダウンをさせるパルスを出力
するNAND回路34の入力端が接続してあり、入力す
るクロックパルスに同期して、A−D入力ピンの入力状
態に応してNAND回路32.34の接続しであるいず
れかの出力ビンからパルスを出力する。
The decoding circuit 30 has the Q, , Q2, QU, and Q4 output bins of the latch circuit 28 connected to the A, B, C, and D input pins, and determines the state of these output bins (H"° or " A count amplifier signal or a countdown signal is output to the up/down counter 18 in accordance with the up/down counter 18. In other words, the 1.8.7.14 output bin of the decoding circuit 30 outputs a pulse that causes the up/down counter 8 to count and amplify. The input side of a NAND circuit 32 that outputs is connected to the 4.2.13.11 output pin, and the input end of a NAND circuit 34 that outputs a pulse that causes the up/down counter 18 to count down is connected to the 4.2.13.11 output pin. In synchronization with the input clock pulse, a pulse is output from one of the output bins connected to the NAND circuits 32 and 34 depending on the input state of the A-D input pin.

位置偏差増幅器14から速度指令を受けるサーボ増幅器
40は、位置偏差増幅器14の出力信号が入力する加算
器42と、エンコーダ52の出力信号からサーボモータ
50の回転速度を求めて加算器42に入力する回転速度
演算器46と、加算器42の出力を増幅する速度偏差増
幅器44とから構成しである。そして、サーボ増幅器4
0の出力、すなわち速度偏差増幅器44の出力は、操作
部を構成している駆動装置としてのサーボモータ50に
与えられる。
The servo amplifier 40 that receives the speed command from the position error amplifier 14 calculates the rotational speed of the servo motor 50 from the adder 42 to which the output signal of the position error amplifier 14 is input and the output signal of the encoder 52 and inputs it to the adder 42. It consists of a rotational speed calculator 46 and a speed deviation amplifier 44 that amplifies the output of the adder 42. And servo amplifier 4
The output of 0, that is, the output of the speed deviation amplifier 44, is given to a servo motor 50 as a driving device constituting the operating section.

サーボモータ50には、エンコーダ52が取り付けであ
る。エンコーダ52は、サーボモータ50の回転に応し
て、サーボモータ50の駆動状態を示す90度位相のず
れている一対の矩形パルスからなる検出信号A、Bを出
力する。
An encoder 52 is attached to the servo motor 50. In response to the rotation of the servo motor 50, the encoder 52 outputs detection signals A and B consisting of a pair of rectangular pulses that are 90 degrees out of phase and indicate the driving state of the servo motor 50.

なお、第1図の破線に示したようにサーボモータ50に
タコジエレ不一夕54を設け、このタコジェレ不−夕5
4の回転をエンコーダ52によって検出してもよい。
Incidentally, as shown by the broken line in FIG.
4 may be detected by the encoder 52.

上記の如く構成した実施例の作用は、次のとおりである
The operation of the embodiment configured as described above is as follows.

なお、実施例の説明においては、サーボモータ50が正
回転した場合に、エンコーダ52は、第4図(A)のよ
うに信号Aが信号Bより位相の進んだ検出信号を出力す
るものとする。そして、エンコーダ52の結線が正常で
ある場合、サーボモータ50が正回転すると、位相反転
H22であるエクスクル−シブ・オア回路に信号Aが入
力し、方向判別器20のランチ回路28のDt入カピン
に信号が入力するとともに、方向判別器20は、ランチ
回路28のD4人入力ンに入力する信号がD2人入力ン
に入力する信号より位相が進んでいる時に、アンプダウ
ンカウンタJ8にカウントアンプさせるパルスを出力し
、D2人入力ンに入力する信号がD4人入力ンに入力す
る信号より位相が進んでいるときに、アンプダウンカウ
ンタ18にカウントダウンさせる信号を出力するものき
する。
In the description of the embodiment, it is assumed that when the servo motor 50 rotates in the forward direction, the encoder 52 outputs a detection signal in which the signal A leads the signal B in phase as shown in FIG. 4(A). . When the connection of the encoder 52 is normal, when the servo motor 50 rotates forward, the signal A is input to the exclusive OR circuit which is the phase inversion H22, and the Dt input pin of the launch circuit 28 of the direction discriminator 20 is input. At the same time, the direction discriminator 20 causes the amplifier down counter J8 to count and amplify when the signal input to the D4 input of the launch circuit 28 is ahead of the signal input to the D2 input. A pulse is output, and when the signal input to the D2 input is ahead of the signal input to the D4 input, a signal is output to cause the amplifier down counter 18 to count down.

制御装置10は、図示しない入力装置等から例えばサー
ボモータ50を正回転(アンプダウンカウンタ18がカ
ウントアンプする方向の回転)させる駆動命令が与えら
れと、結線判別器24がスイッチ16をオフしてサーボ
ループを遮断するとともに、位相反転522であるエク
スクル−シブ・オア回路に位相反転信号“L“°を送出
する(第3図ステップ60.61)、また、制御装置1
0は、エンコーダ52の結線が誤っていた場合において
も、サーボモータ50が暴走しない程度の位置指令(例
えば、アンプダウンカウンタ18のカウント値が+50
となる程度)を位置偏差増幅器14に与える(ステップ
62)。
When the control device 10 receives, for example, a drive command to rotate the servo motor 50 forward (rotation in the direction in which the amplifier down counter 18 counts and amps) from an input device (not shown), the connection discriminator 24 turns off the switch 16. The servo loop is cut off and the phase inversion signal "L"° is sent to the exclusive OR circuit which is the phase inversion 522 (step 60.61 in FIG. 3).
0 indicates a position command that does not cause the servo motor 50 to run out of control even if the encoder 52 is incorrectly connected (for example, the count value of the amplifier down counter 18 is +50).
) is applied to the position error amplifier 14 (step 62).

位置偏差増幅器14ば、与えられた位置に応じたパルス
信号からなる速度指令信号をサーボ増幅器40の加算器
42を介して速度偏差増幅器44に入力する。速度偏差
増幅器44は、入力した速度指令信号を増幅してサーボ
モータ50に与え駆動する。
The position error amplifier 14 inputs a speed command signal consisting of a pulse signal corresponding to the given position to the speed error amplifier 44 via the adder 42 of the servo amplifier 40. The speed deviation amplifier 44 amplifies the input speed command signal and supplies it to the servo motor 50 to drive it.

サーボモータ50が回転すると、エンコーダ52がその
回転を検出し、第4図(A)に示したように、90度の
位相差を有する一対のパルス信号A、Bを出力し、制御
装置10の位相反転器22に送出する。また、サーボ増
幅器40の回転速度演算器46は、エンコーダ52が出
力した信号A、Bからサーボモータ50の回転速度を求
め、加算器42に送る。加算器42は、位置偏差増幅器
14から与えられた速度指令と、回転速度演算器46が
求めたサーボモータ50の実際の回転速度との差を求め
て速度偏差増幅器44に送出する。そして、速度偏差増
幅器44は、加算器42の出力信号に基づいて、サーボ
モータ50の回転速度が位置偏差増幅器14の出力した
速度指令の速度となるようにサーボモータ50を駆動す
る。
When the servo motor 50 rotates, the encoder 52 detects the rotation and outputs a pair of pulse signals A and B having a phase difference of 90 degrees, as shown in FIG. The signal is sent to the phase inverter 22. Further, the rotation speed calculator 46 of the servo amplifier 40 calculates the rotation speed of the servo motor 50 from the signals A and B output from the encoder 52 and sends it to the adder 42 . The adder 42 calculates the difference between the speed command given from the position deviation amplifier 14 and the actual rotation speed of the servo motor 50 calculated by the rotation speed calculator 46, and sends the difference to the speed deviation amplifier 44. Then, the speed deviation amplifier 44 drives the servo motor 50 based on the output signal of the adder 42 so that the rotation speed of the servo motor 50 becomes the speed of the speed command output from the position deviation amplifier 14.

一方、位相反転器(エクスクル−シブ・オア回路)22
には、一方の入力端子にエンコーダ52が出力した信号
A、Bの一方が入力し、方向判別器200ランチ回路2
8のD2人入力ピンこ他方が入力する。そして、エクス
クル−ツブ・オア回路22は、他方の入力端子に結線判
別器24が出力した位相反転信号“°L°゛が入力して
いるため、エンコーダ52が出力したパルスI (信号
A、Bのいずれか一方)が入力してくると、パルス1と
同し位相の信号をう、子回路28に出力する。すなわち
、エクスクル−ノブ オア回路22は、パルスlが“L
”のときには”L″′を出力し、“Ho。
On the other hand, phase inverter (exclusive OR circuit) 22
, one of the signals A and B output from the encoder 52 is input to one input terminal, and the direction discriminator 200 launch circuit 2
8 D2 input pin The other person inputs. Since the exclusive-OR circuit 22 receives the phase inverted signal "°L°" output from the connection discriminator 24 at the other input terminal, the pulse I (signal A, B ), it outputs a signal with the same phase as pulse 1 to the sub-circuit 28. In other words, the exclusive-knob OR circuit 22 is configured so that the pulse 1 is "L".
”, it outputs “L”’ and “Ho”.

のときには°゛H′′を出力する。When this happens, °゛H'' is output.

前記したように、ラッチ回路28は、Q1出力ビンに1
クロツク前のDz入カビンの内容が、Q、出力ピンにラ
ッチ時のD2人入力ンの内容が、Q、出力ビンに1クロ
ツク前のり、入力ピンの内容が、Q、出力ビンにランチ
時のD4人入力ンの内容が出力される。そこで、ランチ
回路28は、方向判別器20の入力ボート1であるD4
人入力ンに、エクスクルーシブ・オア回路22を介して
入力してくるエンコーダパルス1が、方向判別器20の
入力ボート2であるD2人入力ンに入力してくるエンコ
ーダパルス2より、第6図に示したヨウに位相が90度
遅れていると、クロックパルスによってラッチされたと
き、Q、−Q4出力ピンの出力状態が同図の如くなる。
As mentioned above, the latch circuit 28 has a
The contents of the Dz input pin before the clock are Q, the contents of the D2 input pin when latched to the output pin are Q, the contents of the Dz input pin are 1 clock ahead of the output pin, and the contents of the input pin are Q, and the contents of the input pin are Q when the output pin is latched. The contents of the D4 person input are output. Therefore, the launch circuit 28 is connected to D4, which is the input port 1 of the direction discriminator 20.
The encoder pulse 1 inputted to the human input terminal via the exclusive OR circuit 22 is converted from the encoder pulse 2 inputted to the input port D2, which is the input port 2 of the direction discriminator 20, as shown in FIG. If the phase is delayed by 90 degrees from the phase shown, the output states of the Q and -Q4 output pins will be as shown in the figure when latched by the clock pulse.

方向判断器20のデコード回路30は、A−D入力ビン
にラッチ回路28の出力が入力してくると、各入力ビン
の入力状態に対応して、パルスを出力する出力ビンを選
択する。すなわち、デコード回路30は、A入力ビンを
最下位ビット、D入力ビンを最上位ビットとして、各入
力ビンの入力状態を調べ、例えば入力状態(ランチ回路
28の出力状態)が第6図の左端のようなっている場合
、13出力ビンからパルスを出力する。これにより、N
AND回路34が、第4図(B)のようにカウントダウ
ンパルスをアップダウンカウンタ18に出力する。
When the output of the latch circuit 28 is input to the A-D input bin, the decoding circuit 30 of the direction determining device 20 selects an output bin to output a pulse in accordance with the input state of each input bin. That is, the decoding circuit 30 examines the input state of each input bin with the A input bin as the least significant bit and the D input bin as the most significant bit. If it is like this, output the pulse from the 13 output bin. This results in N
The AND circuit 34 outputs a countdown pulse to the up/down counter 18 as shown in FIG. 4(B).

以下、同様にして、方向判別B20は、う、子回路28
のD2.D4人入力ンの入力状態が第6図のようになっ
ている場合、第4図(B)のようにカウントダウンパル
スをアップダウンカウンタ18に出力する。
Hereinafter, in the same manner, the direction determination B20 is performed by the child circuit 28.
D2. When the input state of the D4 input terminal is as shown in FIG. 6, a countdown pulse is output to the up/down counter 18 as shown in FIG. 4(B).

一方、結線判別器24は、アンプダウンカウンタ18の
計数状態を監視しており、アンプダウンカウンタI8が
カウントダウンすると、エンコーダ52の接続が間違っ
ているものと判断して、位相反転器22であるエクスク
ルーシブ・オア回路に位相反転信号“H”を出力しく第
3図ステ、プロ3.64)、ステンブ62に戻る。
On the other hand, the connection discriminator 24 monitors the counting state of the amplifier down counter 18, and when the amplifier down counter I8 counts down, it determines that the connection of the encoder 52 is wrong, and the exclusive・Output the phase inversion signal "H" to the OR circuit (Step 3.64 in Figure 3) and return to step 62.

エクスクル−シブ・オア回路22は、結線判別器24か
ら位相反転信号“H”が入力すると、他方の入力端子に
入力してくるエンコーダパルス1の位相を反転してラッ
チ回路28のD4人入力ンに送出する、従って、方向判
別回路20の入力ボート1であるり、入力ビンに入力す
る信号は、エンコーダパルス1の位相を反転した信号と
なり、入力ボート2であるD2人入力ンに入力するエン
コーダパルス2より位相が90度進んだ状態となる。す
なわち、方向判別回路20の入力ボート1.2であるラ
ッチ回路28のり、、D、入力ビンに入力する信号の状
態が第7図の上部に示したようになり、エンコーダ52
が正常に接続されたと同様となって、Q1〜Q4出力ビ
ンの出力状態が同図のようになる。
When the exclusive OR circuit 22 receives the phase inversion signal "H" from the connection discriminator 24, the exclusive OR circuit 22 inverts the phase of the encoder pulse 1 input to the other input terminal and outputs the D4 input terminal of the latch circuit 28. Therefore, the signal input to the input port 1 or input bin of the direction determination circuit 20 is a signal with the phase of encoder pulse 1 inverted, and the signal input to the input port 2, D2 input bin, is a signal with the phase of encoder pulse 1 inverted. The phase is 90 degrees ahead of that of pulse 2. That is, the state of the signal input to the input bin of the latch circuit 28, which is the input port 1.2 of the direction determination circuit 20, becomes as shown in the upper part of FIG.
is connected normally, and the output states of the Q1 to Q4 output bins become as shown in the figure.

この結果、方向判別器20のテコ−1′回#!30は、
■、8.7.14出力ピンのいずれかからパルスを出力
するようになり、NAND回路32が第4図(C)に示
したようにアップダウンカウンタ18にカウントアツプ
パルスを出力する。従って、結線判別2g24は、アッ
プダウンカウンタ18がカウントアツプすることにより
、結線がOKであると判断しくステ、プロ3.65)、
スインチ16を閉してサーボループを接続する。そして
、制御装置IOは、位置偏差増幅器I4に加X器12の
出力を入力し、通常の制御状態に移行する。
As a result, the direction discriminator 20 uses the lever 1' times #! 30 is
(2) A pulse is output from one of the 8.7.14 output pins, and the NAND circuit 32 outputs a count-up pulse to the up-down counter 18 as shown in FIG. 4(C). Therefore, the connection determination 2g24 determines that the connection is OK when the up/down counter 18 counts up.Pro 3.65)
Close the switch 16 and connect the servo loop. Then, the control device IO inputs the output of the X adder 12 to the position error amplifier I4, and shifts to a normal control state.

なお、エンコーダ52の結線が正常である場合には、結
線判別器24が位相反転信号″L”を出力している状態
において、方向判別器20の入力ボートl、2に第4図
(D)のような信号が入力し、方向判別器20のNAN
D回昂32がカウントアツプ信号を出力する。このため
、結線判別器24は、エンコーダ52の結線が正常であ
ると判断してスイッチI6を閉し、サーボループを接続
して通常の制御状態に移jテする。
In addition, when the connection of the encoder 52 is normal, and the connection discriminator 24 is outputting the phase inverted signal "L", the input ports 1 and 2 of the direction discriminator 20 are connected as shown in FIG. 4(D). A signal like this is input, and the NAN of the direction discriminator 20
The D recovery 32 outputs a count up signal. Therefore, the connection discriminator 24 determines that the connection of the encoder 52 is normal, closes the switch I6, connects the servo loop, and shifts to the normal control state.

このように、実施例においては、結線判別器24がサー
ボモータ50の駆動開始時に、サーボループを一時的に
遮断してエンコーダ52の結線状態を検査し、結線が誤
っている場合に、位相反転信号” H”を出力して位相
反転器22にエンコーダ52の検出信号の位相を反転さ
せ、ソフト的に配線の修正を行って、正常Gこ結線され
たのと同様に制御できるようにしている。従って、実施
例においては、エンコーダ52の結線が間違っていても
サーボモータ50が暴走して機械系を破損するような事
故の発止を防ぐことができ、しかも配線をやりなおすこ
となくサーボモータ50を正常に制御することができる
。また、実施例においては、サーボモータ50の駆動開
始時にサーボルーフ゛を一時的に遮断して結線状態を検
査するため、結線が間違っていた場合であっても、サー
ボモータ50の誤動作の範囲が小さく、ソフト的な誤配
線の修正をより安全に行うことができる。
As described above, in the embodiment, the connection discriminator 24 temporarily interrupts the servo loop to inspect the connection state of the encoder 52 when the servo motor 50 starts driving, and if the connection is incorrect, performs phase inversion. A signal "H" is output to invert the phase of the detection signal of the encoder 52 to the phase inverter 22, and the wiring is corrected using software so that it can be controlled in the same way as if it were normally connected. . Therefore, in the embodiment, even if the encoder 52 is incorrectly connected, it is possible to prevent the servo motor 50 from running out of control and causing damage to the mechanical system, and moreover, the servo motor 50 can be connected without rewiring. Can be controlled normally. Furthermore, in the embodiment, since the servo roof is temporarily shut off when the servo motor 50 starts driving and the wiring state is inspected, even if the wiring is incorrect, the range of malfunction of the servo motor 50 is small. Miswiring can be corrected more safely using software.

なお、第1図において、位置偏差増幅器14がアナログ
の速度指令を出力する場合には、サーボモータ50の駆
動開始時に、結線判別器24によってスイッチI6を切
るとともに、例えばサーボモータ50に3への電流を供
給して制御対象を1mmだけ移動させるような所定の低
速度指令を位1偏差増幅器14に出力させ、その間に結
線判別器24によってアップダウンカウンタ18のカウ
ント値の増減を調べて、エンコーダ52の結線の良否を
判断する。
In addition, in FIG. 1, when the position error amplifier 14 outputs an analog speed command, when the servo motor 50 starts driving, the connection discriminator 24 turns off the switch I6 and, for example, sets the servo motor 50 to 3. A predetermined low speed command that moves the controlled object by 1 mm is outputted to the position deviation amplifier 14 by supplying current, while the connection discriminator 24 checks the increase or decrease in the count value of the up/down counter 18 and outputs it to the encoder. 52 is judged to be good or bad.

また、前記実施例においては、エンコーダ52の検出信
号を回転速度演算器46に入力してサーボモータ50の
回転速度を求める場合について説明したが、第1図の破
線に示したように、タコジェレ7−夕54の出力信号を
加算器42に入力するようにしてもよい。さら二こ、前
記実施例においては、駆動装置がサーボモータ5oであ
る場合について説明したが、駆動装置は油圧ンリンダ等
であってもよい。そして、前記実施例においては、サー
ボモータ50の駆動状態を検出する検出器としてエンコ
ーダ52を用いた場合について説明したが、シンクロや
レヅルハまたは制御対象の位1を検出するリニアエンコ
ーダやポテンショメータ、アブソコーダ、インダクトノ
ン、差動トランス等を用いてもよい。
Further, in the embodiment described above, the case where the rotation speed of the servo motor 50 is determined by inputting the detection signal of the encoder 52 to the rotation speed calculator 46 was explained. - The output signal of the 54 may be input to the adder 42. Further, in the above embodiment, the case where the drive device is the servo motor 5o has been described, but the drive device may be a hydraulic cylinder or the like. In the embodiment described above, the encoder 52 is used as a detector to detect the driving state of the servo motor 50. An inducton, differential transformer, etc. may also be used.

第5回は、他の実施例のブロンク図である。The fifth time is a bronc diagram of another example.

第5図において、制御装置10は、前記実施例と同様に
、加算112とアンプダウンカウンタ18との間に、結
線判別器24によって開閉されるにスイッチ16が設け
である。また、制御■装W10には、位置偏差増幅器1
4の出力信号が入力する加算器70と、加算器70の出
力側に接続した速度偏差増幅器72、およびアップダウ
ンカウンタ1Bの計数値を微分してサーボモータ50の
回転速度を求める微分演算器74、この微分子J算器7
4とアップダウンカウンタ18との間に設けたスイッチ
76とを有している。
In FIG. 5, the control device 10 is provided with a switch 16 between the addition 112 and the amplifier down counter 18, which is opened and closed by the connection discriminator 24, as in the previous embodiment. In addition, the control device W10 includes a position error amplifier 1.
4, a speed deviation amplifier 72 connected to the output side of the adder 70, and a differential calculator 74 that differentiates the count value of the up/down counter 1B to obtain the rotational speed of the servo motor 50. , this micromolecule J calculator 7
4 and a switch 76 provided between the up/down counter 18.

速度偏差増幅器72は、制御装置10の出方信号として
f流増幅器80に電流指令信号を出力する。そして、電
流増幅器8oは、速度偏差増幅器72の出力信号を増幅
してサーボモータ5oに指令された電流を供給し、サー
ボモータ5oを駆動する。なお、スイッチ76は、スイ
ッチ16と同様にサーボモータ50の駆動開始時に、結
線判別器24によって開閉されるようになっている。
Speed deviation amplifier 72 outputs a current command signal to f-flow amplifier 80 as an output signal of control device 10 . The current amplifier 8o amplifies the output signal of the speed deviation amplifier 72, supplies the commanded current to the servo motor 5o, and drives the servo motor 5o. Note that, like the switch 16, the switch 76 is opened and closed by the connection discriminator 24 when the servo motor 50 starts driving.

このように構成した実施例においては、前記実施例と同
様に、サーボモータ50の駆動開始時に、結線判別器2
4がスイッチ16.76を切ってサーボループを遮断し
、速度偏差増幅器72が電流増幅器80に所定の電/A
(トルク)指令を予め定めた時間(例えば0.5秒)だ
け与え、その間に結線判別器24がアップダウンカウン
タ18のカラントイ直の増減をチェンクしてエンコーダ
52の結線状態を検知し、前記と同様の処理を行う。そ
して、本実施例においては、速度偏差を求めるフィード
バック信号も、サーボモータ5oの駆動時に遮断するよ
うにしているため、より安全、正値な制御をjテうこと
かできる。
In the embodiment configured in this way, as in the previous embodiment, when the servo motor 50 starts driving, the connection discriminator 2
4 turns off the switch 16.76 to interrupt the servo loop, and the speed deviation amplifier 72 supplies the current amplifier 80 with a predetermined voltage/A.
(Torque) command is given for a predetermined period of time (for example, 0.5 seconds), during which time the connection discriminator 24 changes the increase/decrease in the up/down counter 18 to detect the connection state of the encoder 52. Perform similar processing. Further, in this embodiment, since the feedback signal for determining the speed deviation is also cut off when the servo motor 5o is driven, safer control with a positive value can be achieved.

〔発明の効果〕〔Effect of the invention〕

以上に説明したように、本発明によれば、操作部にフィ
ードハックする検出信号によって得られた駆動装置の駆
動方向が、駆動装置に与えた駆動信号による駆動方向と
逆である場合に、検出信号を出力する検出器の接続が誤
配線されたものとして検出信号の位相を反転させるため
、結線をしなおすことなく検出信号から得た駆動方向と
、駆動信号により指示した駆動方向とが一敗させること
ができ、駆動装置の暴走を防止してi械系の破損などを
な(すことができる9 なお、検出信号の反転を行う場合、駆動装置の駆動開始
時に、検出信号の駆動信号へのフィードバックを遮断し
て行うと、より安全6二誤配線をソフト的に修正するこ
とができるばかりでなく、誤動作の範囲を小さくするこ
とができる。
As explained above, according to the present invention, when the drive direction of the drive device obtained by the detection signal feed-hacked to the operation unit is opposite to the drive direction by the drive signal given to the drive device, the detection In order to invert the phase of the detection signal by assuming that the connection of the detector that outputs the signal is incorrectly wired, the drive direction obtained from the detection signal and the drive direction instructed by the drive signal will be lost without rewiring. This can prevent the drive device from running out of control and cause damage to the i-mechanical system.9 When inverting the detection signal, when the drive device starts driving, By cutting off the feedback, not only can incorrect wiring be corrected more safely using software, but also the range of malfunction can be reduced.

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

第1図は本発明の実施例に係る駆動装置を制御する制御
装置のブロック図、第2図は実施例の方向判別器と位相
反転器との詳細を示す回路図、第3図は実施例の動作を
説明するフローチャート、第4図は実施例の動作を説明
するタイミングチャート、第5図は他の実施例のブロッ
ク図、第6@第7図は実施例に係る方向判別器のラッチ
回路の入力と出力との関係を示す図である。 10  制御装置、16.76−スイッチ、1日  ア
ンプダウンカウンタ、2〇 一方向判別器、22 =位
相反転器、24− 結線判別珠40  サーボ増幅器、
50 −−m−駆動装置(サーボモータ)、52−−−
駆動検出器(エンコーダ)。
FIG. 1 is a block diagram of a control device for controlling a drive device according to an embodiment of the present invention, FIG. 2 is a circuit diagram showing details of the direction discriminator and phase inverter of the embodiment, and FIG. 3 is an embodiment of the present invention. FIG. 4 is a timing chart explaining the operation of the embodiment, FIG. 5 is a block diagram of another embodiment, and FIGS. 6 and 7 are latch circuits of the direction discriminator according to the embodiment. FIG. 3 is a diagram showing the relationship between input and output. 10 Control device, 16.76-Switch, 1st Amplifier down counter, 20 One-way discriminator, 22 = Phase inverter, 24- Connection discriminator 40 Servo amplifier,
50 --m- drive device (servo motor), 52 ---
Drive detector (encoder).

Claims (3)

【特許請求の範囲】[Claims] (1)駆動装置の駆動状態を示す信号を検出し、この検
出信号を前記駆動装置に与える駆動信号にフィードバッ
クする駆動装置の制御方法において、前記検出信号に基
づいて前記駆動装置の駆動方向を求め、この駆動方向と
前記駆動信号により与えた駆動方向とを比較し、両者が
相違したときに前記検出信号の位相を反転して、検出信
号に基づいて求める前記駆動装置の駆動方向を、前記駆
動信号により与えた駆動方向と一致させることを特徴と
する駆動装置の制御方法。
(1) In a method for controlling a drive device in which a signal indicating a drive state of the drive device is detected and this detection signal is fed back to a drive signal given to the drive device, the drive direction of the drive device is determined based on the detection signal. , this drive direction is compared with the drive direction given by the drive signal, and when the two differ, the phase of the detection signal is inverted, and the drive direction of the drive device determined based on the detection signal is determined by the drive direction. A method for controlling a drive device, characterized in that the drive direction is made to coincide with a drive direction given by a signal.
(2)前記検出信号の位相の反転は、前記駆動装置の駆
動開始時に、前記検出信号の前記駆動信号へのフィード
バックを遮断し、前記駆動装置を予め定めた時間または
予め定めた量だけ駆動して行うことを特徴とする請求項
1に記載の駆動装置の制御方法。
(2) The inversion of the phase of the detection signal cuts off the feedback of the detection signal to the drive signal when the drive device starts driving, and drives the drive device for a predetermined time or by a predetermined amount. 2. The method of controlling a drive device according to claim 1, wherein the method is performed by:
(3)駆動装置の駆動状態を検出し、位相差を有する一
対の検出信号を出力する駆動検出器と、この駆動検出器
が出力する前記一対の検出信号に基づいて、前記駆動装
置の駆動方向を求めて出力する方向判別器と、この方向
判別器に入力する前記一対の検出信号の位相を反転する
位相反転器と、前記方向判別器が求めた前記駆動装置の
駆動方向と駆動装置に与えた駆動方向とを比較して前記
駆動検出器の結線の正誤を判別し、駆動検出器の結線が
誤りであるときに、前記位相反転器に位相反転信号を与
えて前記方向判別器に入力する前記一対の検出信号の位
相を反転させる結線判別器とを有することを特徴とする
駆動装置の制御装置。
(3) a drive detector that detects the drive state of the drive device and outputs a pair of detection signals having a phase difference; and a drive direction of the drive device based on the pair of detection signals output by this drive detector. a direction discriminator that determines and outputs the direction discriminator, a phase inverter that inverts the phase of the pair of detection signals input to the direction discriminator, and a drive direction of the drive device determined by the direction discriminator and a direction that is applied to the drive device. determine whether the connection of the drive detector is correct or incorrect by comparing the drive direction with the drive direction determined, and if the connection of the drive detector is incorrect, provide a phase inversion signal to the phase inverter and input it to the direction discriminator. A control device for a drive device, comprising: a connection discriminator that inverts the phases of the pair of detection signals.
JP29334590A 1990-10-30 1990-10-30 Method and device for controlling driving device Pending JPH04165503A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP29334590A JPH04165503A (en) 1990-10-30 1990-10-30 Method and device for controlling driving device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP29334590A JPH04165503A (en) 1990-10-30 1990-10-30 Method and device for controlling driving device

Publications (1)

Publication Number Publication Date
JPH04165503A true JPH04165503A (en) 1992-06-11

Family

ID=17793601

Family Applications (1)

Application Number Title Priority Date Filing Date
JP29334590A Pending JPH04165503A (en) 1990-10-30 1990-10-30 Method and device for controlling driving device

Country Status (1)

Country Link
JP (1) JPH04165503A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO1996033549A1 (en) * 1995-04-19 1996-10-24 Fanuc Ltd Method and apparatus for detecting runaway of motor
JP2010249096A (en) * 2009-04-20 2010-11-04 Toyota Motor Corp Control device of internal combustion engine

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO1996033549A1 (en) * 1995-04-19 1996-10-24 Fanuc Ltd Method and apparatus for detecting runaway of motor
US5767646A (en) * 1995-04-19 1998-06-16 Fanuc Ltd. Method of and apparatus for detecting anomalous running of motor
JP2010249096A (en) * 2009-04-20 2010-11-04 Toyota Motor Corp Control device of internal combustion engine

Similar Documents

Publication Publication Date Title
US11241792B2 (en) Method and device for detecting abnormality of encoder, and robot control system
JP3461841B2 (en) Electric power steering control device
US4710119A (en) Injection molding machine using servo motor and having mold protecting function
JPH1127801A (en) Control device for electric vehicle
JPH11332002A (en) Controller of motor for electric vehicle
JPH04165503A (en) Method and device for controlling driving device
JP2685962B2 (en) Encoder error detection device
JPH0739190A (en) Brake malfunction detecting method for automatic machine
JPH06239261A (en) Power steering control device
EP4324724A1 (en) Motor driven power steering system of redundancy structure
JPH10277887A (en) Motor controlling method applicable at failure in position sensor
WO2022190541A1 (en) Motor control device
JPH0389880A (en) Abnormality sensing device for servomotor
JPH11119804A (en) Driving controller for servomotor
JPH0421385A (en) Abnormality detector for servo motor controller
JP2667080B2 (en) Transfer control device
US20210382504A1 (en) Control system
JP2605768B2 (en) Safety device
JPH07237174A (en) Control device for industrial robot
JPH0467209A (en) Detecting method for abnormality of industrial robot
JPH10164702A (en) Motor driving controller for electric vehicle
JP3163832B2 (en) Motor control device
JP3294403B2 (en) Elevator door control
JPS6066680A (en) Abnormality detecting circuit of motor drive controller
JP2022127839A (en) Control device