Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JP7651889B2 - Servo driver and servo system - Google Patents
[go: Go Back, main page]

JP7651889B2 - Servo driver and servo system - Google Patents

Servo driver and servo system Download PDF

Info

Publication number
JP7651889B2
JP7651889B2 JP2021038182A JP2021038182A JP7651889B2 JP 7651889 B2 JP7651889 B2 JP 7651889B2 JP 2021038182 A JP2021038182 A JP 2021038182A JP 2021038182 A JP2021038182 A JP 2021038182A JP 7651889 B2 JP7651889 B2 JP 7651889B2
Authority
JP
Japan
Prior art keywords
servo
hash value
servo driver
motor
hash
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2021038182A
Other languages
Japanese (ja)
Other versions
JP2022138348A (en
Inventor
羊二 岩永
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Omron Corp
Original Assignee
Omron Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Omron Corp filed Critical Omron Corp
Priority to JP2021038182A priority Critical patent/JP7651889B2/en
Publication of JP2022138348A publication Critical patent/JP2022138348A/en
Application granted granted Critical
Publication of JP7651889B2 publication Critical patent/JP7651889B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/02Total factory control, e.g. smart factories, flexible manufacturing systems [FMS] or integrated manufacturing systems [IMS]

Landscapes

  • Control Of Electric Motors In General (AREA)

Description

本発明は、サーボドライバ及びサーボシステムに関する。 The present invention relates to a servo driver and a servo system.

サーボシステムでは、一般に、PLC等のコントローラからの指令に従って、サーボドライバによるサーボモータのサーボ制御が行われる。サーボモータには固有のパラメータが設定されている。サーボドライバは、このようなパラメータをサーボモータが備えるエンコーダのElectrically Erasable Programmable Read-Only Memory(EEPROM)等の不揮発性メモリから取得し、取
得したパラメータを用いてサーボモータのサーボ制御を行う。
In a servo system, a servo driver generally controls a servo motor in accordance with commands from a controller such as a PLC. Each servo motor has its own set of parameters. The servo driver obtains these parameters from a non-volatile memory such as an Electrically Erasable Programmable Read-Only Memory (EEPROM) of an encoder provided in the servo motor, and performs servo control of the servo motor using the obtained parameters.

サーボモータのパラメータはサーボモータ毎に異なるため、サーボモータが交換された場合には、交換されたサーボモータからパラメータを取得しなおすことになる。そのため、サーボドライバは、エンコーダの不揮発性メモリに記憶されたモータやエンコーダのシリアル番号等のサーボモータの識別情報によってサーボモータの個体認識を行い、当該識別情報が異なる場合にはサーボモータが交換されたことを検知する。そして、サーボドライバは、サーボモータの交換を検知した場合には、異常を発報することができる。 Since the parameters of a servo motor are different for each servo motor, when a servo motor is replaced, the parameters must be reacquired from the replaced servo motor. For this reason, the servo driver recognizes the individual servo motor using the servo motor's identification information, such as the motor and encoder serial numbers stored in the encoder's non-volatile memory, and detects that the servo motor has been replaced if the identification information differs. Then, when the servo driver detects that a servo motor has been replaced, it can issue an error alert.

特開平8-023692号公報Japanese Patent Application Publication No. 8-023692 特開2018-021789号公報JP 2018-021789 A 国際公開第2014/109054号International Publication No. 2014/109054

ここで、サーボドライバとサーボモータとが異なる供給元から供給されている等の事情がある場合、エンコーダの不揮発性メモリのいずれの領域に識別情報が記憶されているか不明な場合がある。このような場合、サーボドライバは、サーボモータから識別情報を取得することができないため、サーボモータの交換を検知することができない。そのため、サーボドライバは、異常を発報することができず、交換前のサーボモータから取得したパラメータで交換後のサーボモータのサーボ制御が行われてしまう虞がある。 If the servo driver and the servo motor are supplied by different suppliers, it may be unclear in which area of the encoder's non-volatile memory the identification information is stored. In such a case, the servo driver cannot obtain the identification information from the servo motor, and therefore cannot detect the replacement of the servo motor. As a result, the servo driver cannot report an abnormality, and there is a risk that the servo control of the replaced servo motor will be performed using the parameters obtained from the previous servo motor.

本発明は、このような問題に鑑みてなされたものであり、サーボモータの交換の検知精度を高めることができるサーボドライバ及びサーボシステムを提供することを目的とする。 The present invention was made in consideration of these problems, and aims to provide a servo driver and a servo system that can improve the accuracy of detecting servo motor replacement.

開示の技術の1つの側面は、次のようなサーボドライバによって例示される。本サーボドライバは、エンコーダとモータ本体とを含むサーボモータを制御するサーボドライバであって、上記サーボモータをサーボ制御するサーボ制御部と、上記エンコーダに設けられたメモリであって、上記サーボドライバの通電時に上記サーボドライバからアクセスが可能である不揮発性メモリのデータを一塊の所定データとして取得し、取得した上記所定データをハッシュ関数に入力してハッシュ値を算出する演算処理を行う算出部と、上記算出部により算出された上記ハッシュ値を記憶する記憶部と、次の上記サーボドライバへの通電時に、上記サーボドライバからアクセス可能な所定エンコーダが有する不揮発性メモリに対して上記算出部による上記演算処理を行うことで得られる所定ハッシュ値が、上記記
憶部が記憶する上記ハッシュ値と異なる場合に、上記サーボモータの交換を検知する検知部と、を備える。
One aspect of the disclosed technology is exemplified by a servo driver as follows: The servo driver is a servo driver that controls a servo motor including an encoder and a motor main body, and includes: a servo control unit that servo-controls the servo motor, a calculation unit that is a memory provided in the encoder and that performs an arithmetic process of acquiring data from a nonvolatile memory accessible from the servo driver when the servo driver is energized as a block of predetermined data and inputting the acquired predetermined data into a hash function to calculate a hash value, a storage unit that stores the hash value calculated by the calculation unit, and a detection unit that detects replacement of the servo motor when the predetermined hash value obtained by performing the arithmetic process by the calculation unit on the nonvolatile memory of a predetermined encoder accessible from the servo driver when the servo driver is next energized is different from the hash value stored in the storage unit.

上記サーボドライバは、エンコーダの不揮発性メモリに保存されたデータを取得し、そのハッシュ値を基にサーボモータの交換を検知する。すなわち、上記サーボドライバは、サーボモータからシリアル番号等の情報を取得して比較するのではないため、上記不揮発性メモリに保存されるデータの配置が不明な場合でも、サーボモータの交換を検知することができる。そのため、上記サーボドライバによれば、サーボモータの交換の検知精度を高めることができる。上記算出部は、例えば、上記エンコーダの上記不揮発性メモリに保存された全データを所定データとして取得するものであってよい。なお、サーボドライバの記憶部は、最も新しい上記サーボドライバへの通電時における、上記算出部により算出される上記ハッシュ値を記憶するものであってよい。 The servo driver acquires data stored in the non-volatile memory of the encoder and detects the replacement of the servo motor based on the hash value. In other words, since the servo driver does not acquire and compare information such as a serial number from the servo motor, it can detect the replacement of the servo motor even if the arrangement of the data stored in the non-volatile memory is unknown. Therefore, the servo driver can improve the accuracy of detecting the replacement of the servo motor. The calculation unit may, for example, acquire all data stored in the non-volatile memory of the encoder as the specified data. The storage unit of the servo driver may store the hash value calculated by the calculation unit when the most recent power is applied to the servo driver.

ここで、上記算出部は、上記エンコーダの上記不揮発性メモリに保存されたデータのうち、上記サーボドライバがアクセス可能であって値が変動する可変データを除いたデータを上記所定データとして取得するものであってよい。上記不揮発性メモリには、温度センサによって例示される各種センサ等が計測した計測データのように、値が変動する可変データが格納されることがある。このような可変データを除外することで、上記サーボドライバは、サーボモータが交換されていないにもかかわらず、サーボモータが交換されたと誤検知することが抑制される。 The calculation unit may acquire, as the predetermined data, data stored in the non-volatile memory of the encoder, excluding variable data that is accessible by the servo driver and whose value fluctuates. The non-volatile memory may store variable data whose value fluctuates, such as measurement data measured by various sensors, such as a temperature sensor. By excluding such variable data, the servo driver is prevented from erroneously detecting that the servo motor has been replaced when the servo motor has not been replaced.

上記算出部は、上記演算処理において、上記所定データのハッシュ値を、第1のアルゴリズムの第1ハッシュ関数及び第2のアルゴリズムの第2ハッシュ関数の夫々について算出してもよい。そして、上記検知部は、上記記憶部に保存済みの上記第1ハッシュ関数で算出されたハッシュ値と、上記次のサーボドライバへの通電時に上記演算処理で上記第1ハッシュ関数を用いて得られるハッシュ値とを比較し、上記記憶部に保存済みの上記第2ハッシュ関数で算出されたハッシュ値と、上記次のサーボドライバへの通電時に上記演算処理で上記第2ハッシュ関数を用いて得られるハッシュ値とを比較し、上記第1ハッシュ関数で算出されたハッシュ値及び上記第2ハッシュ関数で算出されたハッシュ値の少なくとも一方でハッシュ値が異なる場合に、上記サーボモータの交換を検知するものであってもよい。ハッシュ関数では、入力されるデータが異なるにもかかわらず同一の値が算出されるコリジョンが発生しうる。2つの異なるアルゴリズムを用いることで、このようなコリジョンの発生によるモータ交換の検知精度低下が抑制される。 In the arithmetic process, the calculation unit may calculate a hash value of the predetermined data for each of a first hash function of a first algorithm and a second hash function of a second algorithm. The detection unit may compare the hash value calculated by the first hash function stored in the storage unit with a hash value obtained by using the first hash function in the arithmetic process when the next servo driver is energized, and compare the hash value calculated by the second hash function stored in the storage unit with a hash value obtained by using the second hash function in the arithmetic process when the next servo driver is energized, and detect the replacement of the servo motor when at least one of the hash values calculated by the first hash function and the second hash function differs. In hash functions, collisions may occur in which the same value is calculated despite different input data. By using two different algorithms, the decrease in detection accuracy of motor replacement due to the occurrence of such collisions is suppressed.

そして、上記サーボ制御部は、上記サーボドライバの通電時に上記検知部によって上記サーボモータの交換が検知されると、その時点で上記サーボドライバに接続されているサーボモータの制御を禁止するものであってもよい。このような特徴を備えることで、交換前のサーボモータ制御用に設定されたパラメータで交換後のサーボモータを制御することが抑制される。 The servo control unit may prohibit control of the servo motor connected to the servo driver at that time when the detection unit detects replacement of the servo motor while the servo driver is energized. By providing such a feature, it is possible to prevent the replaced servo motor from being controlled with parameters set for controlling the servo motor before replacement.

ここで、本発明をサーボシステムの側面から捉えることもできる。すなわち、本サーボシステムは、エンコーダとモータ本体とを含むサーボモータと、上記サーボモータを制御するサーボドライバと、を含む。上記サーボドライバは、上記サーボモータをサーボ制御するサーボ制御部と、上記エンコーダに設けられたメモリであって、上記サーボドライバの通電時に上記サーボドライバからアクセスが可能である不揮発性メモリのデータを一塊の所定データとして取得し、取得した上記所定データをハッシュ関数に入力してハッシュ値を算出する演算処理を行う算出部と、上記算出部により算出された上記ハッシュ値を記憶する記憶部と、次の上記サーボドライバへの通電時に、上記サーボドライバからアクセス可能な所定エンコーダが有する不揮発性メモリに対して上記算出部による上記演算処理を行うことで得られる所定ハッシュ値が、上記記憶部が記憶する上記ハッシュ値と異なる
場合に、上記サーボモータの交換を検知する検知部と、を含む。
Here, the present invention can also be seen from the aspect of a servo system. That is, the servo system includes a servo motor including an encoder and a motor body, and a servo driver that controls the servo motor. The servo driver includes a servo control unit that servo-controls the servo motor, a calculation unit that is a memory provided in the encoder and that acquires data from a non-volatile memory that is accessible from the servo driver when the servo driver is energized as a block of predetermined data, inputs the acquired predetermined data into a hash function, and performs an arithmetic process to calculate a hash value, a storage unit that stores the hash value calculated by the calculation unit, and a detection unit that detects replacement of the servo motor when the predetermined hash value obtained by performing the arithmetic process by the calculation unit on the non-volatile memory of a predetermined encoder that is accessible from the servo driver when the servo driver is next energized is different from the hash value stored in the storage unit.

開示の技術によれば、サーボモータ交換の検知精度を高めることができる。 The disclosed technology can improve the accuracy of detecting servo motor replacement.

図1は、サーボシステムの構成例を概略的に示す図である。FIG. 1 is a diagram illustrating an example of the configuration of a servo system. 図2は、モータの概略構成を示す図である。FIG. 2 is a diagram showing a schematic configuration of the motor. 図3は、エンコーダの記憶部に記憶されるデータの一例を示す第1の図である。FIG. 3 is a first diagram illustrating an example of data stored in the storage unit of the encoder. 図4は、サーボドライバが有する機能部の概略構成を示す図である。FIG. 4 is a diagram showing a schematic configuration of the functional units of the servo driver. 図5は、サーボドライバによるモータの交換を検知する処理フローを示す図である。FIG. 5 is a diagram showing a process flow for detecting motor replacement by the servo driver. 図6は、エンコーダの記憶部に記憶されるデータの一例を示す第2の図である。FIG. 6 is a second diagram showing an example of data stored in the storage unit of the encoder. 図7は、第1変形例におけるサーボドライバによるモータの交換を検知する検知フローを示す図である。FIG. 7 is a diagram showing a detection flow for detecting replacement of a motor by a servo driver in the first modified example. 図8は、第2変形例におけるサーボドライバによるモータの交換を検知する検知フローを示す図である。FIG. 8 is a diagram showing a detection flow for detecting replacement of a motor by a servo driver in the second modified example.

以下、本発明の実施の形態について、図面を参照しながら詳細に説明する。なお、図中同一または相当部分には同一符号を付して、その説明は繰り返さない。本開示では、サーボシステムの一つの例示的形態として、産業用システムを示す。しかしながら、本発明に係るサーボシステムの用途は特に限定されるものではない。 Embodiments of the present invention will now be described in detail with reference to the drawings. Note that identical or corresponding parts in the drawings are given the same reference numerals and their description will not be repeated. In this disclosure, an industrial system is shown as one exemplary embodiment of a servo system. However, the use of the servo system according to the present invention is not particularly limited.

<実施形態>
図1は、サーボシステム100の構成例を概略的に示す図である。サーボシステム100は、Programmable Logic Controller(PLC)1と、サーボドライバ2とを含む。サーボドライバ2はサーボモータ3を駆動制御するように配置される。サーボモータ3の出力軸32は、カップリング51によって、ねじ軸52と繋がれている。ねじ軸52には精密ステージ53が配置され、サーボモータ(以下、「モータ」という)3の駆動により精密ステージ53が変位するように構成されている。ねじ軸52に沿った精密ステージ53の駆動範囲の両端部には、ストッパ(図示省略)が設けられる。精密ステージ53がストッパに接触する際の衝撃は、モータ3のトルク制御によって可及的に軽減される。精密ステージ53には、ワーク8が載せられている。このように図に示すサーボシステム100においては、モータ3による駆動軸の1本の駆動軸が設けられているが、駆動軸は2本以上設けられていてもよい。
<Embodiment>
FIG. 1 is a diagram showing a schematic configuration example of a servo system 100. The servo system 100 includes a programmable logic controller (PLC) 1 and a servo driver 2. The servo driver 2 is arranged to drive and control a servo motor 3. The output shaft 32 of the servo motor 3 is connected to a screw shaft 52 by a coupling 51. A precision stage 53 is arranged on the screw shaft 52, and is configured to be displaced by driving a servo motor (hereinafter referred to as a "motor") 3. Stoppers (not shown) are provided at both ends of the driving range of the precision stage 53 along the screw shaft 52. The impact when the precision stage 53 contacts the stopper is reduced as much as possible by torque control of the motor 3. A workpiece 8 is placed on the precision stage 53. In the servo system 100 shown in the figure, one driving shaft driven by the motor 3 is provided, but two or more driving shafts may be provided.

ここで、PLC1は、サーボドライバ2に指令信号を出力する。PLC1は、予め準備されたプログラムに従う処理を実行することによって、たとえばサーボドライバ2の監視装置として機能する。 Here, PLC 1 outputs a command signal to servo driver 2. PLC 1 functions, for example, as a monitoring device for servo driver 2 by executing processing according to a pre-prepared program.

そして、サーボドライバ2は、PLC1から指令信号を受ける。さらにサーボドライバ2は、モータ3からフィードバック信号を受ける。サーボドライバ2においては、それぞれ、位置制御器、速度制御器、電流制御器等を利用したフィードバック制御を行うサーボ系が形成されており、これらの信号を利用して、モータ3をサーボ制御し駆動する。 The servo driver 2 receives a command signal from the PLC 1. The servo driver 2 also receives a feedback signal from the motor 3. In the servo driver 2, a servo system is formed that performs feedback control using a position controller, a speed controller, a current controller, etc., and these signals are used to servo-control and drive the motor 3.

また、モータ3は、モータ本体30とエンコーダ31とを含む。モータ3は、例えばACサーボモータである。モータ3は、サーボドライバ2からの駆動電流を、動力線40を
介して給電される。エンコーダ31は、モータ本体30の出力軸32の変位を検出する。エンコーダ31が検出する出力軸32の変位としては、例えば、出力軸32の回転方向や回転量、回転速度等を挙げることができる。エンコーダ31は、検出された変位を示すフィードバック信号を、エンコーダケーブル41を介してサーボドライバ2に出力する。
The motor 3 also includes a motor body 30 and an encoder 31. The motor 3 is, for example, an AC servo motor. The motor 3 is supplied with a driving current from the servo driver 2 via a power line 40. The encoder 31 detects the displacement of an output shaft 32 of the motor body 30. Examples of the displacement of the output shaft 32 detected by the encoder 31 include the rotation direction, rotation amount, and rotation speed of the output shaft 32. The encoder 31 outputs a feedback signal indicating the detected displacement to the servo driver 2 via an encoder cable 41.

次に、エンコーダ31の機能的な構成について、説明する。図2は、モータ3の概略構成を示す図である。モータ3が備えるエンコーダ31は、信号生成部311と、通信部312と、記憶部313と、を含む。 Next, the functional configuration of the encoder 31 will be described. FIG. 2 is a diagram showing a schematic configuration of the motor 3. The encoder 31 provided in the motor 3 includes a signal generating unit 311, a communication unit 312, and a storage unit 313.

信号生成部311は、サーボドライバ2により駆動されるモータ3のモータ本体30の動作を検出して、検出された動作を示すフィードバック信号を生成する。フィードバック信号は通信部312に出力される。フィードバック信号には、例えばモータ本体30の回転軸の回転位置(角度)についての情報、当該回転軸の回転速度についての情報、当該回転軸の回転方向についての情報などが含まれる。信号生成部311の構成には、例えば公知のインクリメンタル型またはアブソリュート型の構成を適用することができる。 The signal generating unit 311 detects the operation of the motor body 30 of the motor 3 driven by the servo driver 2, and generates a feedback signal indicating the detected operation. The feedback signal is output to the communication unit 312. The feedback signal includes, for example, information about the rotational position (angle) of the rotating shaft of the motor body 30, information about the rotational speed of the rotating shaft, information about the rotation direction of the rotating shaft, and the like. The signal generating unit 311 can be configured, for example, as a known incremental or absolute type.

通信部312は、サーボドライバ2と通信するためのインターフェイスである。本実施の形態において、通信部312は、エンコーダケーブル41を介して、フィードバック信号をサーボドライバ2に送る。この実施の形態では、通信部312からのフィードバック信号及び検出信号の送信には、シリアル通信が適用される。これにより、ケーブルに含まれる信号線の本数を少なくすることができる。エンコーダケーブル41によるシリアル通信には、例えばRecommended Standards 232(RS-232C)、RS-422、あるいはRS-485などの公知の通信規格を採用することができる。 The communication unit 312 is an interface for communicating with the servo driver 2. In this embodiment, the communication unit 312 sends a feedback signal to the servo driver 2 via the encoder cable 41. In this embodiment, serial communication is used to transmit the feedback signal and the detection signal from the communication unit 312. This makes it possible to reduce the number of signal lines included in the cable. For serial communication via the encoder cable 41, a known communication standard such as Recommended Standards 232 (RS-232C), RS-422, or RS-485 can be adopted.

記憶部313は、モータ3のサーボ制御に係るデータを記憶する記憶部である。記憶部313は、例えば、EEPROMである。図3は、エンコーダ31の記憶部313に記憶されるデータの一例を示す第1の図である。図3では、データが記憶される位置と、当該位置に記憶されるデータとが対応付けて示される。位置は、例えば、アドレスによって示される。記憶部313には、エンコーダシリアル番号、各種パラメータ等のエンコーダ31に係るデータが保存される。そして、エンコーダ31を製造するメーカーとモータ本体30を製造するメーカーとは異なることがある。そのため、記憶部313には、さらに、モータ用領域が設けられる。図3では、モータ用領域に保存されるデータを矢印で示している。 The memory unit 313 is a memory unit that stores data related to servo control of the motor 3. The memory unit 313 is, for example, an EEPROM. FIG. 3 is a first diagram showing an example of data stored in the memory unit 313 of the encoder 31. In FIG. 3, the position where the data is stored and the data stored in that position are shown in correspondence with each other. The position is indicated by, for example, an address. The memory unit 313 stores data related to the encoder 31, such as the encoder serial number and various parameters. The manufacturer of the encoder 31 may be different from the manufacturer of the motor main body 30. For this reason, the memory unit 313 is further provided with a motor area. In FIG. 3, the data stored in the motor area is indicated by an arrow.

モータ用領域には、モータ本体30の駆動に用いられる各種パラメータがモータ本体30のメーカーによって保存される。図3の例では、モータ用領域には、モータ型名、モータシリアル番号、サーボ制御用パラメータが保存される。そして、モータ本体30のサーボ制御用パラメータはモータ本体30の個体毎に調整される。そのため、モータ本体30のサーボ制御用パラメータは、同じ型名のモータ本体30であっても、個体毎(モータ本体30のシリアル番号毎)に異なることがある。すなわち、モータ本体30の型名が同じであっても、サーボ制御に好適なサーボ制御用パラメータはモータ本体30の個体毎に異なることがある。 In the motor area, various parameters used to drive the motor body 30 are stored by the manufacturer of the motor body 30. In the example of FIG. 3, the motor type name, motor serial number, and servo control parameters are stored in the motor area. The servo control parameters of the motor body 30 are adjusted for each individual motor body 30. Therefore, the servo control parameters of the motor body 30 may differ for each individual motor body 30 (for each serial number of the motor body 30) even if the motor body 30 has the same type name. In other words, even if the motor body 30 has the same type name, the servo control parameters suitable for servo control may differ for each individual motor body 30.

記憶部313には、上記のように、予め設定されたデータが保存される。記憶部313に保存されたデータは、サーボドライバ2からの指令に応じて、通信部312からサーボドライバ2に送信される。なお、図3に示す記憶部313の構成はあくまで一例であって、記憶部313の構成はエンコーダ31のメーカーが決定し、エンコーダ31によって異なる。 As described above, the memory unit 313 stores preset data. The data stored in the memory unit 313 is transmitted from the communication unit 312 to the servo driver 2 in response to a command from the servo driver 2. Note that the configuration of the memory unit 313 shown in FIG. 3 is merely an example, and the configuration of the memory unit 313 is determined by the manufacturer of the encoder 31 and varies depending on the encoder 31.

サーボドライバ2とモータ3の供給元が同一である場合、供給元は記憶部313の構成をサーボドライバ2に設定することができる。そのため、サーボドライバ2は、記憶部313からモータ本体30の型名、シリアル番号及びエンコーダ31のシリアル番号を取得することで、モータ3の交換を検知することができる。しかしながら、サーボドライバ2とモータ3の供給元が異なる場合(例えば、サーボドライバ2とエンコーダ31の供給元が異なる場合)、記憶部313の構成をサーボドライバ2の供給元は把握することができず、サーボドライバ2の供給元は、記憶部313の構成をサーボドライバ2に設定することができなくなる。そのため、サーボドライバ2は、新たに接続されたモータ3の記憶部313からモータ3の型名、シリアル番号及びエンコーダ31のシリアル番号を取得できず、モータ3の交換を検知できなくなる。そこで、本実施形態では、このような課題を解決するため、サーボドライバ2は以下に説明する機能部を備える。 When the servo driver 2 and the motor 3 are supplied from the same supplier, the supplier can set the configuration of the storage unit 313 in the servo driver 2. Therefore, the servo driver 2 can detect the replacement of the motor 3 by obtaining the model name, serial number, and serial number of the encoder 31 from the storage unit 313. However, when the servo driver 2 and the motor 3 are supplied from different suppliers (for example, when the servo driver 2 and the encoder 31 are supplied from different suppliers), the supplier of the servo driver 2 cannot grasp the configuration of the storage unit 313, and the supplier of the servo driver 2 cannot set the configuration of the storage unit 313 in the servo driver 2. Therefore, the servo driver 2 cannot obtain the model name, serial number, and serial number of the encoder 31 from the storage unit 313 of the newly connected motor 3, and cannot detect the replacement of the motor 3. Therefore, in this embodiment, in order to solve such problems, the servo driver 2 has the functional units described below.

図4は、サーボドライバ2が有する機能部の概略構成を示す図である。サーボドライバ2は、演算装置、記憶装置等を有するコンピュータとみなすことができる。図4に示す機能部は、サーボドライバ2において所定のプログラム等が実行されることで実現される。サーボドライバ2は、通信部21、サーボ制御部22、算出部23、検知部24及び記憶部25を有するが、これら以外の機能部を有していても構わない。 Figure 4 is a diagram showing the schematic configuration of the functional units of the servo driver 2. The servo driver 2 can be regarded as a computer having an arithmetic unit, a storage device, etc. The functional units shown in Figure 4 are realized by executing a predetermined program, etc. in the servo driver 2. The servo driver 2 has a communication unit 21, a servo control unit 22, a calculation unit 23, a detection unit 24, and a storage unit 25, but may have other functional units.

通信部21は、通信ケーブル11を介して外部との通信を司る機能である。例えば、通信部21は、PLC1との通信のためのインターフェイスとして機能する。さらに、通信部21は、エンコーダケーブル41を介したエンコーダ31との通信のためのインターフェイスとしても機能する。 The communication unit 21 is responsible for communication with the outside world via the communication cable 11. For example, the communication unit 21 functions as an interface for communication with the PLC 1. Furthermore, the communication unit 21 also functions as an interface for communication with the encoder 31 via the encoder cable 41.

サーボ制御部22は、PLC1からの指令に基づいてモータ3をサーボ制御するための機能部であり、具体的には、位置制御器、速度制御器、電流制御器等を利用したフィードバック制御を行う機能部である。なお、位置制御器、速度制御器、電流制御器等については、制御対象であるモータ3のサーボ制御が好適に行われるよう速度ゲイン等の制御パラメータが適宜設定される。 The servo control unit 22 is a functional unit for servo-controlling the motor 3 based on commands from the PLC 1, and specifically, is a functional unit for performing feedback control using a position controller, a speed controller, a current controller, etc. Note that for the position controller, speed controller, current controller, etc., control parameters such as speed gain are appropriately set so that servo control of the motor 3, which is the object of control, is performed appropriately.

算出部23は、例えば、サーボドライバ2の通電時等に、エンコーダ31の記憶部313に保存されたデータを取得する。ここで、算出部23は、取得したデータの意味を解釈する必要はない。そのため、検知部24は、記憶部313に保存されたデータを単なるビット列(一塊のデータ)として取得すればよい。そして、算出部23は、記憶部313から取得したデータをハッシュ関数に入力することでハッシュ値を算出する演算処理を行う。 The calculation unit 23 acquires data stored in the memory unit 313 of the encoder 31, for example, when the servo driver 2 is energized. Here, the calculation unit 23 does not need to interpret the meaning of the acquired data. Therefore, the detection unit 24 only needs to acquire the data stored in the memory unit 313 as a simple bit string (a block of data). The calculation unit 23 then performs an arithmetic process to calculate a hash value by inputting the data acquired from the memory unit 313 into a hash function.

ここで、算出部23が使用するハッシュ関数としては、様々なアルゴリズムのハッシュ関数を挙げることができる。検知部24が使用するハッシュ関数のアルゴリズムとしては、例えば、SHA-1、SHA-256、SHA-512等を挙げることができる。 Here, the hash function used by the calculation unit 23 can be a hash function of various algorithms. The hash function algorithm used by the detection unit 24 can be, for example, SHA-1, SHA-256, SHA-512, etc.

検知部24は、モータ3の交換を検知する機能部である。検知部24は、算出部23によって算出された算出されたハッシュ値を記憶部25に記憶させる。そして、検知部24は、サーボドライバ2の通電時に算出したハッシュ値と、記憶部25に記憶済みのハッシュ値とを比較し、これらのハッシュ値が異なる場合にはモータ3が交換されたことを検知する。 The detection unit 24 is a functional unit that detects replacement of the motor 3. The detection unit 24 stores the calculated hash value calculated by the calculation unit 23 in the storage unit 25. The detection unit 24 then compares the hash value calculated when the servo driver 2 is energized with the hash value already stored in the storage unit 25, and if these hash values differ, detects that the motor 3 has been replaced.

記憶部25は、モータ3のサーボ制御に用いられるデータや、算出部23が算出したハッシュ値等のように、サーボドライバ2で行われる処理に関連する各種データを記憶する機能部である。 The memory unit 25 is a functional unit that stores various data related to the processing performed by the servo driver 2, such as data used for servo control of the motor 3 and hash values calculated by the calculation unit 23.

続いて、サーボドライバ2によるモータ3の交換を検知する検知フローについて説明する。図5は、サーボドライバ2によるモータ3の交換を検知する処理フローを示す図である。図5に示す処理フローは、例えば、サーボドライバ2の通電時(起動時)に実行される。以下、図5を参照して、検知部24によるモータ3の交換を検知する処理フローについて説明する。 Next, the detection flow for detecting replacement of the motor 3 by the servo driver 2 will be described. FIG. 5 is a diagram showing a process flow for detecting replacement of the motor 3 by the servo driver 2. The process flow shown in FIG. 5 is executed, for example, when the servo driver 2 is energized (started). Below, the process flow for detecting replacement of the motor 3 by the detection unit 24 will be described with reference to FIG. 5.

S1では、算出部23は、エンコーダ31の記憶部313に記憶された全データを取得する。S2では、算出部23は、S1で取得した全データをハッシュ関数に入力してハッシュ値を算出する。 In S1, the calculation unit 23 acquires all data stored in the memory unit 313 of the encoder 31. In S2, the calculation unit 23 inputs all data acquired in S1 into a hash function to calculate a hash value.

S3では、検知部24は、記憶部25に保存済みのハッシュ値があるか否かを判定する。保存済みのハッシュ値がある場合(S3でYES)、処理はS4に進められる。保存済みのハッシュ値がない場合(S3でNO)、処理はS6に進められる。 In S3, the detection unit 24 determines whether or not there is a hash value already stored in the memory unit 25. If there is a hash value already stored (YES in S3), the process proceeds to S4. If there is no hash value already stored (NO in S3), the process proceeds to S6.

S4では、検知部24は、S2で算出部23が算出したハッシュ値と記憶部25に保存済みのハッシュ値とを比較する。これらのハッシュ値が一致する場合(S4でYES)、モータ3は交換されていないと判定されることから、処理はS7に進められる。これらのハッシュ値が異なる場合(S4でNO)、処理はS5に進められる。 In S4, the detection unit 24 compares the hash value calculated by the calculation unit 23 in S2 with the hash value already stored in the memory unit 25. If these hash values match (YES in S4), it is determined that the motor 3 has not been replaced, and the process proceeds to S7. If these hash values differ (NO in S4), the process proceeds to S5.

S5では、検知部24は、モータ3の交換を検知する。モータ3の交換を検知した検知部24は、例えば、警報を出力するとともに、モータ3の駆動を開始しない。警報の出力は、例えば、ブザー音の出力であってよい。また、警報の出力は、PLC1等の上位装置にメッセージを送信することで実現されてもよい。そして、S5に到達する処理フローではS7の処理が実行されないことから、モータ3の駆動開始処理が禁止される。 In S5, the detection unit 24 detects the replacement of the motor 3. The detection unit 24 that detects the replacement of the motor 3, for example, outputs an alarm and does not start driving the motor 3. The alarm output may be, for example, a buzzer sound. The alarm output may also be achieved by sending a message to a higher-level device such as the PLC 1. Then, since the process of S7 is not executed in the process flow that reaches S5, the drive start process of the motor 3 is prohibited.

S6では、算出部23は、S2で算出したハッシュ値を記憶部25に保存する。なお、算出部23は、すでに保存されたハッシュ値がある場合には、当該保存済みのハッシュ値を消去してから今回のサーボドライバ2の通電時におけるS2で算出したハッシュ値の保存を行う。保存したハッシュ値は、例えば、次にサーボドライバ2が通電された時のS4の判定に用いられる。S7では、サーボ制御部22は、モータ3の駆動を開始する。 In S6, the calculation unit 23 stores the hash value calculated in S2 in the storage unit 25. If a hash value has already been stored, the calculation unit 23 erases the stored hash value and then stores the hash value calculated in S2 when the servo driver 2 is currently energized. The stored hash value is used, for example, for the determination in S4 the next time the servo driver 2 is energized. In S7, the servo control unit 22 starts driving the motor 3.

以上説明した実施形態では、サーボドライバ2は、エンコーダ31の記憶部313に記憶された全データについてハッシュ値を算出し、算出したハッシュ値の比較によってモータ3の交換を検知する。そのため、サーボドライバ2は、記憶部313のどの領域にどのようなデータが保存されているかが不明な場合でも、モータ3の交換を検知することができる。 In the embodiment described above, the servo driver 2 calculates hash values for all data stored in the memory unit 313 of the encoder 31, and detects replacement of the motor 3 by comparing the calculated hash values. Therefore, the servo driver 2 can detect replacement of the motor 3 even if it is unclear what data is stored in which area of the memory unit 313.

サーボドライバ2は、エンコーダ31の記憶部313に保存された全データの比較にハッシュ値を採用する。ハッシュ値は、ハッシュ関数のアルゴリズムに応じた固定長のデータとなる。すなわち、記憶部313に保存されたデータが大容量であってもハッシュ値のサイズが大きくなることはない。そのため、本実施形態によれば、ハッシュ値の保存に用いる記憶部25の容量を抑制することができる。また、記憶部313に保存されたデータを比較する際にハッシュ値が用いられることで、記憶部313に保存されたデータをそのまま比較するよりもサーボドライバ2の計算負荷を軽減することができる。 The servo driver 2 uses a hash value to compare all data stored in the memory unit 313 of the encoder 31. The hash value is fixed-length data according to the algorithm of the hash function. In other words, even if the data stored in the memory unit 313 is large, the size of the hash value does not become large. Therefore, according to this embodiment, the capacity of the memory unit 25 used to store the hash value can be reduced. In addition, by using the hash value when comparing the data stored in the memory unit 313, the calculation load of the servo driver 2 can be reduced compared to directly comparing the data stored in the memory unit 313.

<第1変形例>
以上で説明した実施形態では、エンコーダ31の記憶部313には、予め設定されたデータが保存されていた。第1変形例では、記憶部313に温度センサによって例示される各種センサが測定した測定データのような値が変動する可変データも保存される場合について説明する。
<First Modification>
In the embodiment described above, preset data is stored in the storage unit 313 of the encoder 31. In the first modified example, a case will be described in which variable data whose values fluctuate, such as measurement data measured by various sensors exemplified by a temperature sensor, is also stored in the storage unit 313.

図6は、エンコーダ31の記憶部313に記憶されるデータの一例を示す第2の図である。図6の例では、図3に示したデータに加えて、エンコーダ31に接続された各種センサが測定した測定データも記憶部313に保存される。そのため、検知部24が記憶部313の全領域のデータを取得してハッシュ値を算出すると、モータ3が交換されていなくともハッシュ値が異なる場合が生じる。そのため、検知部24は、モータ3の交換を誤検知する場合がある。 Figure 6 is a second diagram showing an example of data stored in the memory unit 313 of the encoder 31. In the example of Figure 6, in addition to the data shown in Figure 3, measurement data measured by various sensors connected to the encoder 31 is also stored in the memory unit 313. Therefore, when the detection unit 24 acquires data from the entire area of the memory unit 313 and calculates a hash value, there are cases where the hash value is different even if the motor 3 has not been replaced. Therefore, the detection unit 24 may erroneously detect the replacement of the motor 3.

そこで、算出部23は、記憶部313に保存されたデータのうち、可変データが保存された領域以外の領域に保存されたデータを取得し、そのハッシュ値を算出する。算出部23は、例えば、記憶部313にアクセスするコマンドにおいて可変データが保存された領域を除いた全データを取得するように指定すればよい。 The calculation unit 23 then acquires data stored in areas other than the area in which the variable data is stored from among the data stored in the storage unit 313, and calculates the hash value of the data. For example, the calculation unit 23 may specify in a command to access the storage unit 313 that all data excluding the area in which the variable data is stored be acquired.

図7は、第1変形例におけるサーボドライバ2によるモータ3の交換を検知する検知フローを示す図である。図7に示す検知フローは、S1に変えてS1aが実行される点で図5に示す検知フローとは異なる。 Figure 7 shows a detection flow for detecting replacement of the motor 3 by the servo driver 2 in the first modified example. The detection flow shown in Figure 7 differs from the detection flow shown in Figure 5 in that S1a is executed instead of S1.

S1aでは、算出部23は、記憶部313からデータを取得するコマンドにおいて、可変データが保存された領域以外の全データを取得するように指示する。すなわち、算出部23は、図5のS1では記憶部313の全領域に保存されたデータを取得するのに対して、図7のS1aでは、可変データが保存された領域を除外して記憶部313に保存されたデータを取得する。 In S1a, the calculation unit 23 instructs the command to acquire data from the storage unit 313 to acquire all data other than the area in which the variable data is stored. That is, in S1 of FIG. 5, the calculation unit 23 acquires data stored in all areas of the storage unit 313, whereas in S1a of FIG. 7, the calculation unit 23 acquires data stored in the storage unit 313 excluding the area in which the variable data is stored.

第1変形例では、可変データが保存された領域を除外して記憶部313に保存されたデータを取得し、取得したデータのハッシュ値が算出される。そのため、記憶部313に保存された可変データの値が変動しても、モータ3が交換されない限りはハッシュ値の変動は生じない。そのため、第1変形例によれば、可変データが記憶部313に保存される場合であっても、検知部24はモータ3の交換を検知できる。 In the first modified example, the data stored in the memory unit 313 is obtained by excluding the area in which the variable data is stored, and a hash value of the obtained data is calculated. Therefore, even if the value of the variable data stored in the memory unit 313 changes, the hash value does not change unless the motor 3 is replaced. Therefore, according to the first modified example, even if variable data is stored in the memory unit 313, the detection unit 24 can detect replacement of the motor 3.

<第2変形例>
以上説明した実施形態では、記憶部313から取得したデータのハッシュ値をひとつのハッシュ関数で算出した。第2変形例では、2つの異なるアルゴリズムのハッシュ関数を用いて、記憶部313から取得したデータのハッシュ値を算出する例について説明する。
<Second Modification>
In the embodiment described above, one hash function is used to calculate the hash value of the data acquired from the storage unit 313. In the second modified example, an example will be described in which hash functions of two different algorithms are used to calculate the hash value of the data acquired from the storage unit 313.

図8は、第2変形例におけるサーボドライバ2によるモータ3の交換を検知する検知フローを示す図である。図8に示す検知フローは、S2に変えてS2aが実行され、S4に変えてS4aが実行され、S6に変えてS6aが実行される点で図5に示す検知フローとは異なる。 Figure 8 is a diagram showing a detection flow for detecting replacement of the motor 3 by the servo driver 2 in the second modified example. The detection flow shown in Figure 8 differs from the detection flow shown in Figure 5 in that S2a is executed instead of S2, S4a is executed instead of S4, and S6a is executed instead of S6.

S2aでは、算出部23は、アルゴリズムの異なる2つのハッシュ関数を用いて、S1で取得したデータのハッシュ値を算出する。算出部23は、例えば、SHA-1のハッシュ関数を用いて、S1で取得したデータのハッシュ値を算出する。また、算出部23は、SHA-256のハッシュ関数を用いて、S1で取得したデータのハッシュ値を算出する。 In S2a, the calculation unit 23 calculates a hash value of the data acquired in S1 using two hash functions with different algorithms. For example, the calculation unit 23 calculates a hash value of the data acquired in S1 using the SHA-1 hash function. The calculation unit 23 also calculates a hash value of the data acquired in S1 using the SHA-256 hash function.

S4aでは、検知部24は、S2aで算出された2つのハッシュ値と、S6で保存された2つのハッシュ値とを比較する。すなわち、検知部24は、S6で保存されたSHA-1で算出されたハッシュ値と、S2aにおいて新たにSHA-1で算出したハッシュ値とを比較する。さらに、検知部24は、S6で保存されたSHA-256で算出されたハッシュ値と、S2aにおいて新たにSHA-256で算出したハッシュ値とを比較する。こ
の比較の結果、SHA-1で算出されたハッシュ値及びSHA-256で算出されたハッシュ値の少なくともいずれか一方が一致しない場合(S4aでNO)、処理はS5に進められる。いずれのハッシュ値も一致する場合(S4aでYES)、処理は、S7に進められる。
In S4a, the detection unit 24 compares the two hash values calculated in S2a with the two hash values stored in S6. That is, the detection unit 24 compares the hash value calculated by SHA-1 stored in S6 with the hash value newly calculated by SHA-1 in S2a. Furthermore, the detection unit 24 compares the hash value calculated by SHA-256 stored in S6 with the hash value newly calculated by SHA-256 in S2a. If the result of this comparison shows that at least one of the hash values calculated by SHA-1 and the hash values calculated by SHA-256 do not match (NO in S4a), the process proceeds to S5. If both hash values match (YES in S4a), the process proceeds to S7.

S6aでは、算出部23は、S2aで算出した2つのハッシュ値を記憶部25に保存する。なお、算出部23は、すでに保存されたハッシュ値がある場合には、当該保存済みのハッシュ値を消去してから今回のサーボドライバ2の通電時におけるS2aで算出した2つのハッシュ値の保存を行う。算出部23は、例えば、2つのハッシュ値の夫々を算出したアルゴリズムと対応付けて記憶部25に保存すればよい。 In S6a, the calculation unit 23 stores the two hash values calculated in S2a in the storage unit 25. If there are already stored hash values, the calculation unit 23 erases the stored hash values and then stores the two hash values calculated in S2a when the servo driver 2 is currently energized. The calculation unit 23 may store the two hash values in the storage unit 25, for example, in association with the algorithm by which they were calculated.

ハッシュ関数は、入力されたデータが異なるにもかかわらず同一のハッシュ値が算出されることがある(コリジョンの発生)。第2変形例では、記憶部313から取得したデータに対して2つの異なるアルゴリズムのハッシュ関数を用いて夫々のハッシュ値を算出し、S4aにおいて少なくとも一方のアルゴリズムで算出したハッシュ値が一致しない場合に、モータ3の交換を検知する。同一の入力データに対して、2つの異なるアルゴリズムのハッシュ関数でコリジョンが発生する確率は極めて低いと考えられる。そのため、第2変形例によれば、モータ3の交換を検知する精度を高めることができる。 Hash functions may calculate the same hash value even when the input data is different (occurrence of a collision). In the second variant, hash values are calculated using hash functions of two different algorithms for the data obtained from the memory unit 313, and if the hash values calculated using at least one of the algorithms in S4a do not match, replacement of the motor 3 is detected. It is considered that the probability of a collision occurring between hash functions of two different algorithms for the same input data is extremely low. Therefore, according to the second variant, the accuracy of detecting replacement of the motor 3 can be improved.

以上説明した実施形態及び変形例は、組み合わせることができる。 The embodiments and variations described above can be combined.

<付記1>
エンコーダ(31)とモータ本体(30)とを含むサーボモータ(3)を制御するサーボドライバ(2)であって、
前記サーボモータ(3)をサーボ制御するサーボ制御部(22)と、
前記エンコーダ(31)に設けられたメモリで(313)あって、前記サーボドライバ(2)の通電時に前記サーボドライバ(2)からアクセスが可能である不揮発性メモリ(313)のデータを一塊の所定データとして取得し、取得した前記所定データをハッシュ関数に入力してハッシュ値を算出する演算処理を行う算出部(23)と、
前記算出部(23)により算出された前記ハッシュ値を記憶する記憶部(25)と、
次の前記サーボドライバ(2)への通電時に、前記サーボドライバ(2)からアクセス可能な所定エンコーダ(31)が有する不揮発性メモリ(313)に対して前記算出部(23)による前記演算処理を行うことで得られる所定ハッシュ値が、前記記憶部(25)が記憶する前記ハッシュ値と異なる場合に、前記サーボモータ(3)の交換を検知する検知部(24)と、
を備える、サーボドライバ(2)。
<Appendix 1>
A servo driver (2) for controlling a servo motor (3) including an encoder (31) and a motor body (30),
a servo control unit (22) for servo-controlling the servo motor (3);
a calculation unit (23) that performs a calculation process of acquiring data from a non-volatile memory (313) that is provided in the encoder (31) and that is accessible from the servo driver (2) when the servo driver (2) is energized as a block of predetermined data, inputting the acquired predetermined data into a hash function, and calculating a hash value;
a storage unit (25) that stores the hash value calculated by the calculation unit (23);
a detection unit (24) that detects replacement of the servo motor (3) when a predetermined hash value obtained by performing the arithmetic processing by the calculation unit (23) on a non-volatile memory (313) of a predetermined encoder (31) accessible from the servo driver (2) during the next power supply to the servo driver (2) differs from the hash value stored in the storage unit (25);
A servo driver (2).

<付記2>
エンコーダ(31)とモータ本体(30)とを含むサーボモータ(3)と、
前記サーボモータ(3)を制御するサーボドライバ(2)と、を含むサーボシステム(100)であって、
前記サーボドライバ(2)は、
前記サーボモータ(3)をサーボ制御するサーボ制御部(22)と、
前記エンコーダ(31)に設けられたメモリ(313)であって、前記サーボドライバ(2)の通電時に前記サーボドライバ(2)からアクセスが可能である不揮発性メモリ(313)のデータを一塊の所定データとして取得し、取得した前記所定データをハッシュ関数に入力してハッシュ値を算出する演算処理を行う算出部(23)と
前記算出部(23)により算出された前記ハッシュ値を記憶する記憶部(25)と、
次の前記サーボドライバ(2)への通電時に、前記サーボドライバ(2)からアクセス可能な所定エンコーダ(31)が有する不揮発性メモリ(313)に対して前記算出部(
23)による前記演算処理を行うことで得られる所定ハッシュ値が、前記記憶部(25)が記憶する前記ハッシュ値と異なる場合に、前記サーボモータ(3)の交換を検知する検知部(24)と、を含む、
サーボシステム(100)。
<Appendix 2>
A servo motor (3) including an encoder (31) and a motor body (30);
A servo system (100) including a servo driver (2) for controlling the servo motor (3),
The servo driver (2)
a servo control unit (22) for servo-controlling the servo motor (3);
a calculation unit (23) that performs an arithmetic process of acquiring data from a non-volatile memory (313) that is accessible from the servo driver (2) when the servo driver (2) is energized as a block of predetermined data, inputting the acquired predetermined data into a hash function, and calculating a hash value; and a storage unit (25) that stores the hash value calculated by the calculation unit (23).
When the servo driver (2) is next energized, the calculation unit (
and a detection unit (24) that detects replacement of the servo motor (3) when a predetermined hash value obtained by performing the arithmetic processing by the storage unit (23) differs from the hash value stored in the storage unit (25).
A servo system (100).

1・・PLC
2・・サーボドライバ
3・・モータ
8・・ワーク
21・・通信部
22・・サーボ制御部
23・・算出部
24・・検知部
25・・記憶部
30・・モータ本体
31・・エンコーダ
311・・信号生成部
312・・通信部
313・・記憶部
32・・出力軸
41・・エンコーダケーブル
51・・カップリング
52・・ねじ軸
53・・精密ステージ53
100・・サーボシステム
1. PLC
Description of the Reference Numerals 2: Servo driver 3: Motor 8: Work 21: Communication unit 22: Servo control unit 23: Calculation unit 24: Detection unit 25: Memory unit 30: Motor body 31: Encoder 311: Signal generation unit 312: Communication unit 313: Memory unit 32: Output shaft 41: Encoder cable 51: Coupling 52: Screw shaft 53: Precision stage 53
100..Servo system

Claims (6)

エンコーダとモータ本体とを含むサーボモータを制御するサーボドライバであって、
前記サーボモータをサーボ制御するサーボ制御部と、
前記エンコーダに設けられたメモリであって、前記サーボドライバの通電時に前記サーボドライバからアクセスが可能である不揮発性メモリ保存された全データを一塊の所定データとして取得し、取得した前記所定データをハッシュ関数に入力してハッシュ値を算出する演算処理を行う算出部と、
前記算出部により算出された前記ハッシュ値を記憶する記憶部と、
次の前記サーボドライバへの通電時に、前記サーボドライバからアクセス可能な所定エンコーダが有する不揮発性メモリに対して前記算出部による前記演算処理を行うことで得られる所定ハッシュ値が、前記記憶部が記憶する前記ハッシュ値と異なる場合に、前記サーボモータの交換を検知する検知部と、を備え、
前記算出部は、
前記演算処理において、前記所定データのハッシュ値を、第1のアルゴリズムの第1ハッシュ関数及び第2のアルゴリズムの第2ハッシュ関数の夫々について算出し、
前記検知部は、
前記記憶部に保存済みの前記第1ハッシュ関数で算出されたハッシュ値と、前記次のサーボドライバへの通電時に前記演算処理で前記第1ハッシュ関数を用いて得られるハッシュ値とを比較し、
前記記憶部に保存済みの前記第2ハッシュ関数で算出されたハッシュ値と、前記次のサーボドライバへの通電時に前記演算処理で前記第2ハッシュ関数を用いて得られるハッシュ値とを比較し、
前記第1ハッシュ関数で算出されたハッシュ値及び前記第2ハッシュ関数で算出されたハッシュ値の少なくとも一方でハッシュ値が異なる場合に、前記サーボモータの交換を検知する、
サーボドライバ。
A servo driver that controls a servo motor including an encoder and a motor body,
a servo control unit that servo-controls the servo motor;
a calculation unit that performs an arithmetic process of acquiring all data stored in a non-volatile memory that is provided in the encoder and that is accessible from the servo driver when the servo driver is energized, as a block of predetermined data, inputting the acquired predetermined data into a hash function, and calculating a hash value;
a storage unit that stores the hash value calculated by the calculation unit;
a detection unit that detects replacement of the servo motor when a predetermined hash value obtained by performing the arithmetic processing on a non-volatile memory of a predetermined encoder accessible from the servo driver by the calculation unit when the servo driver is next energized differs from the hash value stored in the storage unit ,
The calculation unit is
In the calculation process, a hash value of the predetermined data is calculated for each of a first hash function of a first algorithm and a second hash function of a second algorithm;
The detection unit is
comparing the hash value calculated by the first hash function stored in the storage unit with a hash value obtained by using the first hash function in the arithmetic process when the next servo driver is energized;
comparing the hash value calculated by the second hash function stored in the storage unit with a hash value obtained by using the second hash function in the arithmetic process when the next servo driver is energized;
detecting a replacement of the servo motor when at least one of the hash values calculated by the first hash function and the hash value calculated by the second hash function is different;
Servo driver.
前記記憶部は、最も新しい前記サーボドライバへの通電時における、前記算出部により算出される前記ハッシュ値を記憶する、
請求項1に記載のサーボドライバ。
The storage unit stores the hash value calculated by the calculation unit when power is most recently applied to the servo driver.
2. The servo driver according to claim 1.
前記サーボ制御部は、前記サーボドライバの通電時に前記検知部によって前記サーボモータの交換が検知されると、その時点で前記サーボドライバに接続されているサーボモータの制御を禁止する、
請求項1または2に記載のサーボドライバ。
When the detection unit detects replacement of the servo motor while the servo driver is energized, the servo control unit prohibits control of the servo motor connected to the servo driver at that time.
3. The servo driver according to claim 1 or 2 .
エンコーダとモータ本体とを含むサーボモータと、
前記サーボモータを制御するサーボドライバと、を含むサーボシステムであって、
前記サーボドライバは、
前記サーボモータをサーボ制御するサーボ制御部と、
前記エンコーダに設けられたメモリであって、前記サーボドライバの通電時に前記サーボドライバからアクセスが可能である不揮発性メモリに保存された全データを一塊の所定データとして取得し、取得した前記所定データをハッシュ関数に入力してハッシュ値を算出する演算処理を行う算出部と
前記算出部により算出された前記ハッシュ値を記憶する記憶部と、
次の前記サーボドライバへの通電時に、前記サーボドライバからアクセス可能な所定エンコーダが有する不揮発性メモリに対して前記算出部による前記演算処理を行うことで得られる所定ハッシュ値が、前記記憶部が記憶する前記ハッシュ値と異なる場合に、前記サーボモータの交換を検知する検知部と、を含
前記算出部は、
前記演算処理において、前記所定データのハッシュ値を、第1のアルゴリズムの第1ハッシュ関数及び第2のアルゴリズムの第2ハッシュ関数の夫々について算出し、
前記記憶部に保存済みの前記第1ハッシュ関数で算出されたハッシュ値と、前記次のサーボドライバへの通電時に前記演算処理で前記第1ハッシュ関数を用いて得られるハッシュ値とを比較し、
前記記憶部に保存済みの前記第2ハッシュ関数で算出されたハッシュ値と、前記次のサーボドライバへの通電時に前記演算処理で前記第2ハッシュ関数を用いて得られるハッシュ値とを比較し、
前記第1ハッシュ関数で算出されたハッシュ値及び前記第2ハッシュ関数で算出されたハッシュ値の少なくとも一方でハッシュ値が異なる場合に、前記サーボモータの交換を検知する、
サーボシステム。
a servo motor including an encoder and a motor body;
A servo system including:
The servo driver includes:
a servo control unit that servo-controls the servo motor;
a calculation unit that performs an arithmetic process of acquiring all data stored in a non-volatile memory that is provided in the encoder and that is accessible from the servo driver when the servo driver is energized as a block of predetermined data, inputting the acquired predetermined data into a hash function, and calculating a hash value; and a storage unit that stores the hash value calculated by the calculation unit.
a detection unit that detects replacement of the servo motor when a predetermined hash value obtained by performing the arithmetic processing by the calculation unit on a non-volatile memory of a predetermined encoder accessible from the servo driver when power is next applied to the servo driver differs from the hash value stored in the storage unit,
The calculation unit is
In the calculation process, a hash value of the predetermined data is calculated for each of a first hash function of a first algorithm and a second hash function of a second algorithm;
comparing the hash value calculated by the first hash function stored in the storage unit with a hash value obtained by using the first hash function in the arithmetic process when the next servo driver is energized;
comparing the hash value calculated by the second hash function stored in the storage unit with a hash value obtained by using the second hash function in the arithmetic process when the next servo driver is energized;
detecting a replacement of the servo motor when at least one of the hash values calculated by the first hash function and the hash value calculated by the second hash function is different;
Servo system.
前記記憶部は、最も新しい前記サーボドライバへの通電時における、前記算出部により算出される前記ハッシュ値を記憶する、
請求項に記載のサーボシステム。
The storage unit stores the hash value calculated by the calculation unit when power is most recently applied to the servo driver.
5. The servo system according to claim 4 .
前記サーボ制御部は、前記サーボドライバの通電時に前記検知部によって前記サーボモータの交換が検知されると、その時点で前記サーボドライバに接続されているサーボモータの制御を禁止する、
請求項4または5に記載のサーボシステム。
When the detection unit detects replacement of the servo motor while the servo driver is energized, the servo control unit prohibits control of the servo motor connected to the servo driver at that time.
6. The servo system according to claim 4 or 5 .
JP2021038182A 2021-03-10 2021-03-10 Servo driver and servo system Active JP7651889B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2021038182A JP7651889B2 (en) 2021-03-10 2021-03-10 Servo driver and servo system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2021038182A JP7651889B2 (en) 2021-03-10 2021-03-10 Servo driver and servo system

Publications (2)

Publication Number Publication Date
JP2022138348A JP2022138348A (en) 2022-09-26
JP7651889B2 true JP7651889B2 (en) 2025-03-27

Family

ID=83399131

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2021038182A Active JP7651889B2 (en) 2021-03-10 2021-03-10 Servo driver and servo system

Country Status (1)

Country Link
JP (1) JP7651889B2 (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017163760A (en) 2016-03-10 2017-09-14 オムロン株式会社 Motor control device, motor control method, information processing program, and recording medium
JP2018025945A (en) 2016-08-09 2018-02-15 株式会社リコー Diagnostic device, learning device, and diagnostic system
JP2020018168A (en) 2014-12-22 2020-01-30 日本電産株式会社 Motor module and motor authentication method

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2020018168A (en) 2014-12-22 2020-01-30 日本電産株式会社 Motor module and motor authentication method
JP2017163760A (en) 2016-03-10 2017-09-14 オムロン株式会社 Motor control device, motor control method, information processing program, and recording medium
JP2018025945A (en) 2016-08-09 2018-02-15 株式会社リコー Diagnostic device, learning device, and diagnostic system

Also Published As

Publication number Publication date
JP2022138348A (en) 2022-09-26

Similar Documents

Publication Publication Date Title
US11048227B2 (en) Abnormality detection device of machine tool
US11460827B2 (en) Controller and machine learning device
JP3681733B2 (en) Numerical controller
CN107491038B (en) Machine learning machine, numerical control device, and machine learning method for learning threshold value of abnormal load detection
CN101764555B (en) Servo system and safety control device
US10105846B2 (en) Robot control system having stop function
US20150115514A1 (en) Control device for machine tool including rotary indexing device
JP5355530B2 (en) Electric power steering device
US20200026255A1 (en) Abnormality detection device of machine tool
US20060247888A1 (en) Machine tool
JP7651889B2 (en) Servo driver and servo system
JP2007219991A (en) Abnormal load detection device
JP7794961B2 (en) Numerical control device and computer-readable storage medium
CN111722585A (en) Control system for industrial machine
US5418439A (en) Apparatus and method for discriminating position information in a position control system
JP7786238B2 (en) AC motor monitoring device
JP5037437B2 (en) Encoder with internal information output function
JP5090996B2 (en) Pressure abnormality detection device for injection molding machine
CN116593884A (en) Surveillance device
JP2001202134A (en) Control device, its method and alarm output method for the control device
JP7504331B1 (en) Industrial Control Systems
EP0915403A1 (en) Numerical control unit
WO2020189031A1 (en) Information processing device, information processing method, and information processing program
JP7277291B2 (en) Servo motor controller
JPH06155232A (en) Numerical control device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20240116

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20240716

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20240717

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20240917

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20241112

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20250114

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20250212

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20250225

R150 Certificate of patent or registration of utility model

Ref document number: 7651889

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150