JP4061489B2 - Communication speed control method for fieldbus system - Google Patents

Communication speed control method for fieldbus system Download PDF

Info

Publication number
JP4061489B2
JP4061489B2 JP2003006411A JP2003006411A JP4061489B2 JP 4061489 B2 JP4061489 B2 JP 4061489B2 JP 2003006411 A JP2003006411 A JP 2003006411A JP 2003006411 A JP2003006411 A JP 2003006411A JP 4061489 B2 JP4061489 B2 JP 4061489B2
Authority
JP
Japan
Prior art keywords
communication
slave
communication speed
master unit
disconnection
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2003006411A
Other languages
Japanese (ja)
Other versions
JP2004221904A (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 JP2003006411A priority Critical patent/JP4061489B2/en
Publication of JP2004221904A publication Critical patent/JP2004221904A/en
Application granted granted Critical
Publication of JP4061489B2 publication Critical patent/JP4061489B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Safety Devices In Control Systems (AREA)
  • Small-Scale Networks (AREA)
  • Communication Control (AREA)

Description

【0001】
【発明の属する技術分野】
この発明は、フィールドバスシステムの通信速度制御方法に関するもので、特に、フィールドバスの断線といった異常事態における通信速度の制御に関する。
【0002】
【従来の技術】
FA(ファクトリーオートメーション)で用いられるPLC(プログラマブルコントローラ)は、スイッチやセンサなどの入力機器のON/OFF情報を入力し、ラダー言語などで書かれたシーケンスプログラム(ユーザプログラム)に沿って論理演算を実行する。そして、PLCは、得られた演算結果にしたがって、リレー,バルブ,アクチュエータなどの出力機器に対し、ON/OFF情報の信号を出力することで制御が実行される。
【0003】
係るPLCの一形態として、各機能ごとに生成されたユニットを複数用意し、電気,機械的に連結して構成するものがある。係るタイプを構成するためのユニットとしては、電源ユニット,CPUユニット,I/Oユニット,マスタユニット等各種のものがある。
【0004】
そして、上記したマスタユニットは、フィールドバス等の制御系ネットワークに接続され、その制御系ネットワークに接続された各種のスレーブと制御系ネットワークを介して通信可能となっている。この種のスレーブの一例として、リモートIOがある。すなわち、上記した入力機器や出力機器は、PLCを構成するI/Oユニットに接続することもあるが、仮に全ての入出力機器を直接I/Oユニットに接続した場合には、それら入出力機器とI/Oユニットを結ぶ配線が、入出力機器の数だけ存在することになり、係る多数の配線がPLC(I/Oユニット)を起点として工場内に引き回されることになり、好ましくない。
【0005】
そこで、制御対象の付近に入出力機器を接続するための端子台となるリモートIOを設置し、そのリモートIOに各種の入出力機器を接続する。そして、PLC(マスタユニット)に接続されたネットワークケーブル(通信線)に対して各リモートIOを接続し、各リモートIOとPLCとの間ではマスタ−スレーブ間通信などによってI/Oデータの送受を行い、実際の入出力機器に対しては係るリモートIOを介して情報の伝達をするようにしている。
【0006】
上記したネットワーク構成の一例を示すと、図1のようなものがある。すなわち、PLC1を構成するユニットの1つであるマスタユニット2並びにスレーブ3が、バス型のフィールドバス4に接続される。さらに、最近ではフィールドバス4を用いたネットワークにおいても非常に早い通信速度を使用することが多くなってきているため、フィールドバス4の端部には、終端抵抗5を接続するようになっている。
【0007】
なお、上記のフィールドバス4における通信速度は、予め決めた速度をマスタユニット並びにスレーブに設定しておき、その決めた通信速度で通信を行う。そして、通常は同一のフィールドバス4では、単一の通信速度が用いられる。これらのことは、たとえば特許文献1の従来技術の説明などに開示されている。なお、特許文献1に記載の発明は、制御装置(PLC)と入出力装置間をシリアルバス方式で通信するものであって、同一の伝送線路に異なる通信速度に対応した入出力装置(高速対応の入出力装置と低速対応の入出力装置)を接続した状態で通信可能にするものである。但し、この特許文献に記載の発明も、個々の入出力装置との通信速度は一義的に決まっている。
【0008】
【特許文献1】
特開2002−082719
【特許文献2】
特開平11−298561
【0009】
【発明が解決しようとする課題】
しかしながら、上記した特許文献1に示した発明では、以下に示す問題がある。すなわち、フィールドバス4を構成する通信線が断線した場合、断線された箇所よりも下流側に位置するスレーブ3と通信できなくなることは当然であるが、断線箇所より上流側でフィールドバス4を介してマスタユニット2と物理的に接続が維持されたスレーブ3も通信不能となることが多々ある。これは、断線したことにより、終端抵抗が不在のネットワーク構成となるので、高い通信速度では通信回線が安定せず、通信できないスレーブ3が発生するためである。
【0010】
したがって、断線時にマスタ−スレーブ間通信により、どのスレーブ3が接続されているかを特定することを利用して断線箇所を早期発見することは困難であった。さらに、断線が発生すると正常な制御ができないので、システムが緊急停止することになるが、すべてのスレーブ3と通信できなくなるので、例えばスレーブ3に接続された制御対象の装置を安全な状態になるまで動作させ、その後停止するような緊急退避制御処理もできなくなる。そのため、例えば半導体プロセスなどにおいては、処理中のウエハが不良品となり歩留まりの低下を招くなどの問題を生じる。
【0011】
なお、例えば本発明と直接関連しないが、一般のデータ伝送をするモデムなどでは、通信回線の状況に応じて通信速度を自動的に増減する技術が実装されている(特許文献2等)。これにより、ノイズなどが発生し環境の悪い通信回線では、通信速度を遅くして確実に相手にデータを送信し、環境が良い通信回線では通信速度を早くして高速にデータを送信することができる。但し、このモデムの発明は、通信線に断線など生じておらず、相手との通信は正常に行える環境下にあることを前提としており、本発明が対象とする断線を発生した場合には、通信不可となる。
【0012】
本発明は、通信が断線した場合でも断線箇所までは通信可能にすることができるフィールドバスシステムの通信速度制御方法を提供することを目的とする。
【0013】
【課題を解決するための手段】
上記した目的を達成するため、本発明に係るフィールドバスシステムの通信速度制御方法は、プログラマブルコントローラを構成するマスタユニットと、スレーブが、バス型のフィールドバスに接続されるとともに、そのフィールドバスの終端には終端抵抗が接続されたフィールドバスシステムにおける通信速度の制御方法であって、正常時は、前記終端抵抗が必要な高速の通信速度で前記マスタユニットと前記スレーブが通信を行い、前記プログラマブルコントローラを構成するユニットが、前記フィールドバスに接続された前記スレーブのうち、予め設定した個数以上の複数のスレーブが通信不能になった場合に断線と判断した時は、前記マスタユニットは、終端抵抗が不在な状態でも通信可能な低速の通信速度に切り替えて前記スレーブと通信を行うようにした。
【0015】
プログラマブルコントローラを構成するユニット」は、実施の形態でも示したように、CPUユニットや、マスタユニットとすることができるし、断線検知用の専用のユニットや他のユニットによっても実現できる。
【0018】
本発明によれば、フィールドバスの断線が発生した場合に、自動的に低速の通信速度に下げることができる。これにより、終端抵抗がなくてもフィールドバスに接続された断線箇所よりもマスタユニット側に存在するスレーブと通信が可能となる。
【0019】
その結果、断線箇所よりマスタユニット側に存在するスレーブと通信することができるので、どのスレーブが断線により通信不能になったかを知ることができ、断線箇所の予測をすることが可能となる。また、通信可能なスレーブと通信することで、そのスレーブに接続された機器に対して制御が可能となる。
【0020】
【発明の実施の形態】
図2は、本発明が適用されるフィールドバスシステムの一例を示している。図2に示すように、PLC10と各種のスレーブ20が、フィールドバス30を介して接続されネットワークシステムを構築している。スレーブ20としては、リモートIOその他の機器がある。フィールドバス30は、各スレーブ20を直列に接続したバス型である。そのため、そのフィールドバス30の終端には、終端抵抗31が接続されている。また、本実施の形態では、通信回線の二重化等がされておらず、通信回線(ケーブル)が断線されると、その断線箇所より下流側とは通信不可能となるようなネットワーク構成をとっている。
【0021】
PLC10は、各機能ごとに生成されたユニットを連結することにより構成され、例えば、CPUユニット11,マスタユニット12などがある。マスタユニット12は、フィールドバス30に接続され、各スレーブ20と通信を行うようになっている。さらに、PLC10の内部バスを介してCPUユニット11のIOメモリにアクセスし、IOデータ等の読み書きを行うようになっている。
【0022】
マスタユニット12は、図3に示すように、フィールドバスに接続され、実際にデータの送受を行う通信インタフェース12aと、その通信インタフェース12aを介してマスタ−スレーブ間通信をし、スレーブ20との間でI/Oデータの送受を行なったり、所定のコマンドの送信並びにそれに基づくレスポンスの受信を行うマスタ用ASIC12bと、各種の制御を行うMPU12dと、各種の制御実行時にワークエリア等として使用されるRAM12cと、上記制御を行うプログラムや、各種の設定データ等が格納されたEEPROM12eと、他のユニットなどと通信を行うためのインタフェース12hと、動作状態(通信状態)や異常/正常などを示すLED表示部12f並びにアドレスの設定などを行うための設定スイッチ12gを備えている。なお、基本的なハードウェア構成等は、従来のマスタユニットと同様であるので、その詳細な説明を省略する。
【0023】
ここで本発明では、マスタユニット12がフィールドバス30を介してスレーブ20と通信する際の通信速度として複数種用意している。そして、その複数種の通信速度の少なくとも1つは、通信線つまりフィールドバス30が断線して終端抵抗31が存在しない状態になった場合でも、通信可能となる十分低い通信速度としている。この十分低い通信速度としては、例えば100から200bps程度とすることができるが、これ以外の速度でももちろんよい。そして、他の通信速度としては、正常時に各スレーブ20と通信を行う高速の通信速度であり、この高速の通信速度は、1つでも良いし、特許文献1に示されたように複数設けても良い。さらに、通信線が断線されていない正常時に使用される通信速度として複数用意した場合に、特許文献1のように入出力機器(スレーブ20)ごとに異ならせても良いし、通信回線の状態に応じて適切な通信速度を切り替えながら使用するようにしても良い。
【0024】
さらに、MPU12dが行う制御としては、CPUユニット11その他のユニット等と通信したり、マスタ用ASIC12bを動作させたりするようになっている。特に本発明との関係でいうと、フィールドバス30の断線時に通信速度を十分低い通信速度に切り替え、当該通信速度でスレーブ20と通信を行うようにしている。さらに上記した断線の有無の判断は、マスタユニット12自体が行っても良いし、実際の判断自体はCPUユニット11が行い、そのCPUユニット11からの通知に基づいて通信速度を切り替えるようにしてもよい。
【0025】
CPUユニット11は、図4に示すように、システムプログラムはフラッシュメモリからなるシステムメモリ(SROM)11aに格納されており、このシステムプロクラムは、MPU11bに呼び出され、MPU11bは、ワークメモリ(WRAM)11cを適宜使用しながらプログラムに従った所定の処理を実行する。
【0026】
また、運転時において、ユーザデータの1つであるユーザプログラムは、ユーザメモリ11dに格納されている。このユーザメモリ11dは、高速RAMであるSRAMにより構成され、電源OFF時には内容を保持することができない。従って、同一内容のユーザプログラムを、電源OFF時にも内容を保持するフラッシュメモリから構成されるバックアップメモリ11eに格納しておく。そして、電源ON時にバックアップメモリ11eに格納されたユーザプログラムをユーザメモリ11dに転送するようにしている。また、I/Oデータやパラメータは、IOメモリ11fに格納されている。
【0027】
そして、これらユーザメモリ11dに格納されたユーザプログラム(命令オブジェクトコード)は、ASIC11gに順次呼び出され、呼び出した命令オブジェクトを解析し、命令実行をする。また、この命令実行時に、適宜IOメモリ11fにアクセスし、I/Oデータを読み書きしたり、パラメータを取得する。さらに、I/Oデータは、I/Oバス11hを介して他のユニットひいては、マスタユニット12経由でスレーブ20との間で送受される。
【0028】
ここで本発明では、CPUユニット11側にフィールドバス30の断線を検知する機能と、断線を検知した場合にマスタユニット12に通知する機能を設けた。具体的には、いずれもユーザプログラムに組み込むことで実現している。
【0029】
すなわち、IOメモリ11fの所定エリアには各スレーブ20のステータスビットが書き込まれている。これは、マスタユニット12がフィールドバス30に接続されたスレーブ20から一定期間応答がないと異常が発生したと判断し、IOメモリ11fのステータスビットに異常フラグを立てるようになっている。従って、ユーザプログラム中に、上記ステータスビットを監視し、所定のスレーブのステータスビットの異常フラグが立ったことを条件に、マスタユニットに断線通知をするプログラムを組み込む。
【0030】
そして、断線と判断する異常フラグであるが、例えば、全てのスレーブ20の異常フラグがONになることを条件としても良いし、複数のスレーブの異常フラグがONになることを条件としても良いし、複数の特定のスレーブの異常フラグがONになることを条件としても良い。
【0031】
すなわち、高速の通信速度でマスタ−スレーブ間通信をしている場合に、フィールドバス30が断線し、終端抵抗31が不在になると、多くの場合全てのスレーブ20と通信ができなくなる。従って、全てのスレーブ20の異常フラグがONになると、断線を生じたと推定できる。
【0032】
また、フィールドバス30に接続されている複数のスレーブ20の内の1つのスレーブの異常フラグONになった場合には、そのスレーブ20の故障などのおそれが高いが、同時に複数のスレーブ20と通信不能になり当該複数のスレーブ20の異常フラグがONになると、その複数のスレーブ20が同時に故障した可能性よりも通信線の不良(断線)の可能性の方が高い。従って、任意の複数のスレーブ20の異常フラグが同時にONになると、断線を生じたと推定できる。なお、同時とは、例えば同一のサイクルタイム中としてもよいし、数サイクル分まで含むようにすることもできる。もちろんそれ以上の期間まで含めることもできる。
【0033】
これにより、サイクリックにユーザプログラムが実行される都度、断線のチェックが行われ、断線が発生したと判断した場合には、マスタユニット12に通知する。これに伴い、マスタユニット12は、断線発生時に速やかに自動的に通信速度を十分に低い速度に下げることができる。
【0034】
スレーブ20は、自動速度追従機能を備えている。つまり、マスタユニット12から指定された通信速度に合わせて、自己の通信インタフェースで処理する通信速度を変更することができる。これにより、ネットワーク全体の通信速度をマスタユニット12側の通信速度の切替のみで変更できる。
【0035】
従って、フィールドバス30が断線して終端抵抗31が不在になったとしても、マスタユニット12から断線箇所までに接続されたスレーブ20に対してはマスタ−スレーブ間通信を継続することができる。よって、どのスレーブ20が接続されているかを特定することができ、断線箇所を早期に発見することが可能となる。さらに、断線が発生してシステムが緊急停止した場合でも、例えば通信可能なスレーブ20に接続された制御対象の装置を安全な状態になるまで動作させ、その後停止するような緊急退避制御処理を実行することができる。そのため、例えば半導体プロセスなどにおいては、処理中のウエハが不良品となることが抑制できたり、各種ロボット等を基準位置まで戻すことができる。なお、上記した緊急退避処理を実行するプログラムは、例えばユーザプログラムとしてCPUユニット11に実装しておき、緊急時に当該プログラムを実行することにより、動作させることができる。
【0036】
なお、上記した例では、通常の制御を行うユーザプログラムの一部に組み込み、ステータスビットのON/OFFの状態により断線を判断するようにしたが、本発明はこれに限ることはなく、MPU11bに別途アプリケーションプログラムを組み込み、より高機能な判断をすることもできる。
【0037】
また、ツールなどを使用してマスタユニット12に通信速度切替条件(例えば、「スレーブが2台以上異常の場合」など)を書き込んでおき、マスタユニット12側で断線を判断し、自動的に通信速度の切り替えを行うようにすることもできる。つまり、マスタユニット12は、各スレーブ20と通信をしているので、立ち上げ時に存在していたスレーブから一定期間応答がない場合には異常と判断する機能を有している。従って、例えばMPU12dに、異常になったスレーブの有無を監視し、係る異常になったスレーブが複数存在した場合に断線を生じたと判断し、十分に遅い通信速度に切り替えるようなプログラムを組み込むことにより、マスタユニット12側の判断で自動的に通信速度を切り替えることができる。なお、いずれのユニットが判断する場合でも、断線の判断のアルゴリズムは上記したものに限られないのはもちろんである。
【0038】
【発明の効果】
以上のように、この発明では、フィールドバスが断線した場合でも、自動的に通信速度を低速に下げることにより、断線箇所までは通信可能にすることができる。
【図面の簡単な説明】
【図1】従来例を示す図である。
【図2】本発明に係るフィールドバスシステムの好適な一実施の形態を示す図である。
【図3】マスタユニットの内部構造を示すブロック図である。
【図4】スレーブの内部構造を示すブロック図である。
【符号の説明】
10 PLC
11 CPUユニット
11a システムメモリ
11b MPU
11c ワークメモリ(WRAM)
11d ユーザメモリ(RAM)
11e バックアップメモリ(BROM)
11f IOメモリ
11g ASIC
11f I/Oバス
12 マスタユニット
12a 通信インタフェース
12b マスタ用ASIC
12c RAM
12d MPU
12e EEPROM
12f LED表示部
12g 設定スイッチ
12h インタフェース
20 スレーブ
30 フィールドバス
31 終端抵抗
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a communication speed control method for a fieldbus system, and more particularly to control of a communication speed in an abnormal situation such as disconnection of a fieldbus.
[0002]
[Prior art]
PLC (programmable controller) used in FA (factory automation) inputs ON / OFF information of input devices such as switches and sensors, and performs logical operations according to a sequence program (user program) written in a ladder language. Execute. Then, the PLC performs control by outputting a signal of ON / OFF information to an output device such as a relay, a valve, or an actuator according to the obtained calculation result.
[0003]
As one form of such a PLC, there is one in which a plurality of units generated for each function are prepared and electrically and mechanically connected. As a unit for constituting such a type, there are various types such as a power supply unit, a CPU unit, an I / O unit, and a master unit.
[0004]
The master unit described above is connected to a control system network such as a field bus, and can communicate with various slaves connected to the control system network via the control system network. An example of this type of slave is a remote IO. In other words, the input device and output device described above may be connected to the I / O unit constituting the PLC, but if all the input / output devices are directly connected to the I / O unit, these input / output devices are connected. There are as many wirings connecting the I / O units to the I / O units, and a large number of such wirings are routed in the factory starting from the PLC (I / O unit), which is not preferable. .
[0005]
Therefore, a remote IO serving as a terminal block for connecting an input / output device near the control target is installed, and various input / output devices are connected to the remote IO. Then, each remote IO is connected to a network cable (communication line) connected to the PLC (master unit), and I / O data is transmitted and received between each remote IO and the PLC by master-slave communication or the like. The information is transmitted to the actual input / output device via the remote IO.
[0006]
An example of the network configuration described above is shown in FIG. That is, the master unit 2 and the slave 3 which are one of the units constituting the PLC 1 are connected to the bus type field bus 4. Further, recently, a very high communication speed is often used even in a network using the fieldbus 4, so that a termination resistor 5 is connected to the end of the fieldbus 4. .
[0007]
Note that the communication speed in the fieldbus 4 is set to a master unit and a slave, and communication is performed at the determined communication speed. Usually, a single communication speed is used in the same field bus 4. These are disclosed in, for example, the description of the prior art in Patent Document 1. The invention described in Patent Document 1 communicates between a control device (PLC) and an input / output device by a serial bus method, and is an input / output device corresponding to different communication speeds on the same transmission line (high-speed support). Communication with a low-speed input / output device). However, in the invention described in this patent document, the communication speed with each input / output device is uniquely determined.
[0008]
[Patent Document 1]
JP 2002-082719 A
[Patent Document 2]
JP-A-11-298561
[0009]
[Problems to be solved by the invention]
However, the above-described invention disclosed in Patent Document 1 has the following problems. That is, when the communication line constituting the field bus 4 is disconnected, it is natural that communication with the slave 3 located downstream from the disconnected position is disabled, but via the field bus 4 upstream from the disconnected position. In many cases, the slave 3 that is physically connected to the master unit 2 is also unable to communicate. This is because the disconnection results in a network configuration in which no terminating resistor is present, so that the communication line is not stable at a high communication speed, and a slave 3 that cannot communicate is generated.
[0010]
Therefore, it has been difficult to detect a disconnection point at an early stage by identifying which slave 3 is connected by master-slave communication at the time of disconnection. Further, when the disconnection occurs, normal control cannot be performed, and the system is urgently stopped. However, since communication with all the slaves 3 cannot be performed, for example, the control target device connected to the slaves 3 is in a safe state. The emergency evacuation control process that operates until it stops and then stops becomes impossible. Therefore, for example, in a semiconductor process or the like, a problem occurs such that a wafer being processed becomes a defective product, resulting in a decrease in yield.
[0011]
For example, although not directly related to the present invention, a technique for automatically increasing / decreasing the communication speed according to the state of the communication line is implemented in a modem that performs general data transmission (Patent Document 2, etc.). As a result, in communication lines where noise is generated and the environment is poor, the communication speed can be reduced and data is reliably transmitted to the other party, and in communication environments where the environment is good, the communication speed can be increased and data transmitted at high speed it can. However, the invention of this modem is based on the premise that there is no disconnection or the like in the communication line and that communication with the other party can be normally performed, and when the disconnection targeted by the present invention occurs, Communication is not possible.
[0012]
An object of the present invention is to provide a communication speed control method for a fieldbus system that enables communication up to a disconnection point even when communication is disconnected.
[0013]
[Means for Solving the Problems]
In order to achieve the above object, a communication speed control method for a fieldbus system according to the present invention includes a master unit and a slave constituting a programmable controller connected to a bus-type fieldbus, and the termination of the fieldbus. Is a communication speed control method in a fieldbus system to which a terminating resistor is connected, and when normal, the master unit and the slave communicate at a high communication speed that requires the terminating resistor, and the programmable controller Is determined to be disconnected when a plurality of slaves more than a preset number among the slaves connected to the fieldbus are unable to communicate, the master unit has a termination resistance. Switch to a lower communication speed that allows communication in the absence. It was to communicate with the.
[0015]
As described in the embodiment, the “unit constituting the programmable controller” can be a CPU unit or a master unit, or can be realized by a dedicated unit for disconnection detection or another unit.
[0018]
According to the present invention, when a fieldbus disconnection occurs, the communication speed can be automatically reduced to a low communication speed. As a result, communication with a slave existing on the master unit side with respect to the disconnection point connected to the field bus is possible without a termination resistor.
[0019]
As a result, since it is possible to communicate with the slave existing on the master unit side from the disconnection location, it is possible to know which slave has become unable to communicate due to disconnection, and it is possible to predict the disconnection location. In addition, by communicating with a communicable slave, it is possible to control a device connected to the slave.
[0020]
DETAILED DESCRIPTION OF THE INVENTION
FIG. 2 shows an example of a fieldbus system to which the present invention is applied. As shown in FIG. 2, a PLC 10 and various slaves 20 are connected via a field bus 30 to construct a network system. The slave 20 includes a remote IO and other devices. The field bus 30 is a bus type in which the slaves 20 are connected in series. Therefore, a termination resistor 31 is connected to the end of the fieldbus 30. Further, in this embodiment, the communication line is not duplicated, and when the communication line (cable) is disconnected, the network configuration is such that communication with the downstream side from the disconnected part becomes impossible. Yes.
[0021]
The PLC 10 is configured by connecting units generated for each function, and includes, for example, a CPU unit 11 and a master unit 12. The master unit 12 is connected to the field bus 30 and communicates with each slave 20. Further, the IO memory of the CPU unit 11 is accessed via the internal bus of the PLC 10 to read / write IO data and the like.
[0022]
As shown in FIG. 3, the master unit 12 is connected to the field bus, and performs communication between the master and the slave via the communication interface 12 a that actually transmits and receives data, and the slave 20. The master ASIC 12b for sending / receiving I / O data, sending a predetermined command and receiving a response based on the I / O data, the MPU 12d for performing various controls, and the RAM 12c used as a work area or the like when executing various controls An EEPROM 12e in which a program for performing the above control, various setting data, and the like are stored, an interface 12h for communicating with other units, and an LED display indicating an operation state (communication state), abnormality / normality The setting switch 12 for setting the unit 12f and address It is equipped with a. The basic hardware configuration and the like are the same as those of the conventional master unit, and thus detailed description thereof is omitted.
[0023]
Here, in the present invention, a plurality of kinds of communication speeds are prepared as the communication speed when the master unit 12 communicates with the slave 20 via the field bus 30. At least one of the plurality of types of communication speeds is set to a sufficiently low communication speed that enables communication even when the communication line, that is, the field bus 30 is disconnected and the termination resistor 31 does not exist. The sufficiently low communication speed can be, for example, about 100 to 200 bps, but other speeds may be used. The other communication speed is a high-speed communication speed that communicates with each slave 20 during normal operation. One high-speed communication speed may be used, or a plurality of high-speed communication speeds are provided as shown in Patent Document 1. Also good. Further, when a plurality of communication speeds used in a normal state where the communication line is not disconnected are prepared, they may be different for each input / output device (slave 20) as in Patent Document 1, or the communication line state may be changed. Accordingly, it may be used while switching an appropriate communication speed.
[0024]
Further, as control performed by the MPU 12d, communication with the CPU unit 11 and other units is performed, and the master ASIC 12b is operated. Particularly in relation to the present invention, when the fieldbus 30 is disconnected, the communication speed is switched to a sufficiently low communication speed, and communication with the slave 20 is performed at the communication speed. Further, the determination of the presence / absence of the disconnection may be performed by the master unit 12 itself, or the actual determination itself may be performed by the CPU unit 11 and the communication speed may be switched based on the notification from the CPU unit 11. Good.
[0025]
As shown in FIG. 4, the CPU unit 11 stores a system program in a system memory (SROM) 11a composed of a flash memory. The system program is called by the MPU 11b, and the MPU 11b is a work memory (WRAM) 11c. A predetermined process according to the program is executed while appropriately using.
[0026]
During operation, a user program that is one of user data is stored in the user memory 11d. The user memory 11d is composed of an SRAM that is a high-speed RAM, and cannot retain its contents when the power is turned off. Therefore, the user program having the same content is stored in the backup memory 11e composed of a flash memory that retains the content even when the power is turned off. When the power is turned on, the user program stored in the backup memory 11e is transferred to the user memory 11d. Further, I / O data and parameters are stored in the IO memory 11f.
[0027]
The user program (instruction object code) stored in the user memory 11d is sequentially called by the ASIC 11g, analyzes the called instruction object, and executes the instruction. Further, when this instruction is executed, the IO memory 11f is accessed as appropriate to read / write I / O data or acquire parameters. Further, the I / O data is transmitted / received to / from the slave 20 via the I / O bus 11h and the master unit 12 via other units.
[0028]
Here, in the present invention, a function of detecting disconnection of the field bus 30 and a function of notifying the master unit 12 when disconnection is detected are provided on the CPU unit 11 side. Specifically, both are realized by being incorporated into a user program.
[0029]
That is, the status bit of each slave 20 is written in a predetermined area of the IO memory 11f. This is because the master unit 12 determines that an abnormality has occurred if there is no response from the slave 20 connected to the field bus 30 for a certain period of time, and sets an abnormality flag in the status bit of the IO memory 11f. Therefore, a program for monitoring the status bit and notifying the master unit of disconnection on the condition that the abnormal flag of the status bit of the predetermined slave is set is incorporated in the user program.
[0030]
The abnormality flag is determined to be a disconnection. For example, the abnormality flag of all the slaves 20 may be on, or the abnormality flag of a plurality of slaves may be on. The condition may be that the abnormality flags of a plurality of specific slaves are turned on.
[0031]
In other words, when the master-slave communication is performed at a high communication speed, if the field bus 30 is disconnected and the termination resistor 31 is absent, in many cases, communication with all the slaves 20 becomes impossible. Therefore, it can be estimated that the disconnection has occurred when the abnormality flags of all the slaves 20 are turned ON.
[0032]
Further, when the abnormality flag of one slave among the plurality of slaves 20 connected to the field bus 30 is turned ON, there is a high possibility of failure of the slave 20, but it is possible to communicate with the plurality of slaves 20 at the same time. When it becomes impossible and the abnormality flag of the plurality of slaves 20 is turned ON, the possibility of a communication line failure (disconnection) is higher than the possibility that the plurality of slaves 20 have failed simultaneously. Therefore, it can be estimated that the disconnection has occurred when the abnormality flags of any of the plurality of slaves 20 are simultaneously turned ON. Note that “simultaneous” may be, for example, within the same cycle time, or may include up to several cycles. Of course, it can be included even longer.
[0033]
Thereby, each time the user program is executed cyclically, the disconnection is checked, and when it is determined that the disconnection has occurred, the master unit 12 is notified. Accordingly, the master unit 12 can automatically reduce the communication speed to a sufficiently low speed quickly when a disconnection occurs.
[0034]
The slave 20 has an automatic speed tracking function. That is, the communication speed processed by the own communication interface can be changed in accordance with the communication speed designated by the master unit 12. Thereby, the communication speed of the whole network can be changed only by switching the communication speed on the master unit 12 side.
[0035]
Therefore, even if the field bus 30 is disconnected and the termination resistor 31 is absent, the master-slave communication can be continued for the slave 20 connected from the master unit 12 to the disconnected portion. Therefore, it is possible to specify which slave 20 is connected, and it is possible to find a disconnection point at an early stage. Furthermore, even when the disconnection occurs and the system is urgently stopped, for example, an emergency evacuation control process is executed in which the control target device connected to the communicable slave 20 is operated until it is in a safe state and then stopped. can do. Therefore, for example, in a semiconductor process or the like, it is possible to suppress the wafer being processed from becoming a defective product, and it is possible to return various robots to the reference position. Note that the program for executing the emergency evacuation process described above can be operated by mounting the program on the CPU unit 11 as a user program, for example, and executing the program in an emergency.
[0036]
In the above-described example, the disconnection is determined based on the ON / OFF state of the status bit incorporated in a part of the user program that performs normal control. However, the present invention is not limited to this, and the MPU 11b includes A separate application program can be installed to make more sophisticated judgments.
[0037]
Write communication speed switching conditions (for example, “when two or more slaves are abnormal”) to the master unit 12 using a tool, etc., determine disconnection on the master unit 12 side, and automatically communicate. It is also possible to switch speeds. That is, since the master unit 12 communicates with each slave 20, it has a function of determining that there is an abnormality when there is no response for a certain period from the slave that was present at the time of startup. Therefore, for example, by installing a program in MPU 12d that monitors the presence or absence of an abnormal slave, determines that a disconnection has occurred when there are a plurality of such abnormal slaves, and switches to a sufficiently slow communication speed. The communication speed can be automatically switched based on the determination on the master unit 12 side. Of course, regardless of which unit determines, the disconnection determination algorithm is not limited to the above.
[0038]
【The invention's effect】
As described above, according to the present invention, even when the fieldbus is disconnected, it is possible to enable communication up to the disconnection point by automatically reducing the communication speed to a low speed.
[Brief description of the drawings]
FIG. 1 is a diagram showing a conventional example.
FIG. 2 is a diagram showing a preferred embodiment of a fieldbus system according to the present invention.
FIG. 3 is a block diagram showing an internal structure of the master unit.
FIG. 4 is a block diagram showing an internal structure of a slave.
[Explanation of symbols]
10 PLC
11 CPU unit 11a System memory 11b MPU
11c Work memory (WRAM)
11d User memory (RAM)
11e Backup memory (BROM)
11f IO memory 11g ASIC
11f I / O bus 12 Master unit 12a Communication interface 12b Master ASIC
12c RAM
12d MPU
12e EEPROM
12f LED display unit 12g Setting switch 12h Interface 20 Slave 30 Fieldbus 31 Terminating resistor

Claims (1)

プログラマブルコントローラを構成するマスタユニットと、スレーブが、バス型のフィールドバスに接続されるとともに、そのフィールドバスの終端には終端抵抗が接続されたフィールドバスシステムにおける通信速度の制御方法であって、
正常時は、前記終端抵抗が必要な高速の通信速度で前記マスタユニットと前記スレーブが通信を行い、
前記プログラマブルコントローラを構成するユニットが、前記フィールドバスに接続された前記スレーブのうち、予め設定した個数以上の複数のスレーブが通信不能になった場合に断線と判断した時は、前記マスタユニットは、終端抵抗が不在な状態でも通信可能な低速の通信速度に切り替えて前記スレーブと通信を行うことを特徴とするフィールドバスシステムの通信速度制御方法。
A method for controlling a communication speed in a field bus system in which a master unit and a slave constituting a programmable controller are connected to a bus-type field bus and a termination resistor is connected to the end of the field bus,
When normal, the master unit and the slave communicate at a high communication speed that requires the termination resistor,
When the unit that constitutes the programmable controller determines that the master unit is disconnected when a plurality of slaves of a predetermined number or more among the slaves connected to the field bus are disabled, the master unit is: A communication speed control method for a fieldbus system, wherein communication is performed with the slave by switching to a low communication speed at which communication is possible even in the absence of a termination resistor.
JP2003006411A 2003-01-14 2003-01-14 Communication speed control method for fieldbus system Expired - Fee Related JP4061489B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2003006411A JP4061489B2 (en) 2003-01-14 2003-01-14 Communication speed control method for fieldbus system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2003006411A JP4061489B2 (en) 2003-01-14 2003-01-14 Communication speed control method for fieldbus system

Publications (2)

Publication Number Publication Date
JP2004221904A JP2004221904A (en) 2004-08-05
JP4061489B2 true JP4061489B2 (en) 2008-03-19

Family

ID=32896787

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2003006411A Expired - Fee Related JP4061489B2 (en) 2003-01-14 2003-01-14 Communication speed control method for fieldbus system

Country Status (1)

Country Link
JP (1) JP4061489B2 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9130557B2 (en) 2012-12-03 2015-09-08 Samsung Electronics Co., Ltd. Operating method of input/output interface
USRE49506E1 (en) 2012-12-03 2023-04-25 Samsung Electronics Co., Ltd. High/low speed mode selection for output driver circuits of a memory interface

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4549926B2 (en) * 2005-05-20 2010-09-22 三菱電機株式会社 Programmable control device
JP2008052315A (en) * 2006-08-22 2008-03-06 Yokogawa Electric Corp Field bus communication diagnostic apparatus and field bus communication diagnostic method
JP6375144B2 (en) * 2014-05-15 2018-08-15 西部電機株式会社 Control system, failure diagnosis method and program
KR102048639B1 (en) * 2018-09-04 2019-11-25 벨로넥트 인코퍼레이션 Method for detecting and complementing connection failure of a bus and device for said method
WO2021152761A1 (en) * 2020-01-30 2021-08-05 東芝キヤリア株式会社 Communication system, master device used in communication system, slave device, and communication method

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9130557B2 (en) 2012-12-03 2015-09-08 Samsung Electronics Co., Ltd. Operating method of input/output interface
US9575923B2 (en) 2012-12-03 2017-02-21 Samsung Electronics Co., Ltd. Input/output interface
US9934169B2 (en) 2012-12-03 2018-04-03 Samsung Electronics Co., Ltd. Operating method of input/output interface
USRE49506E1 (en) 2012-12-03 2023-04-25 Samsung Electronics Co., Ltd. High/low speed mode selection for output driver circuits of a memory interface
USRE49535E1 (en) 2012-12-03 2023-05-23 Samsung Electronics Co., Ltd. Memory interface with selectable connections for input receiver circuits based on operating mode

Also Published As

Publication number Publication date
JP2004221904A (en) 2004-08-05

Similar Documents

Publication Publication Date Title
JP5348489B2 (en) controller
JP3918950B2 (en) Safety device
US7120505B2 (en) Safety network system, safety slave, and safety controller
EP3333657B1 (en) Communication system, communication device, and communication program
KR100689323B1 (en) Fieldbus network multiplexing system
JP2003099102A (en) Input/output device having setting functional property, failure separating functional property and redundant failure supporting functional property
US7246270B2 (en) Programmable controller with CPU and communication units and method of controlling same
JP6638489B2 (en) Relay device, control method of relay device, control program, and recording medium
JP4061489B2 (en) Communication speed control method for fieldbus system
EP1363174B1 (en) Communication control system and method for supervising a failure
JP2006036187A (en) Control device for automobile and method for monitoring abnormality thereof
JP2013201664A (en) Redundant communication device
WO2021176972A1 (en) Cable abnormality assessment system, slave device, and cable abnormality assessment method
JP4793589B2 (en) Safety remote I / O terminal
JP4747683B2 (en) On-vehicle electronic control system, fault diagnosis method thereof, and on-vehicle electronic control device
JP4239784B2 (en) Distributed control device
CN111942306A (en) Automobile electronic actuator control method and system
JP4042234B2 (en) FA network and robot controller
JP2007028409A (en) Communication system and node connection form specific method
US20240161713A1 (en) Systems and methods of fault detection for input/output modules of industrial systems
JPH11136848A (en) Overcurrent protection circuit and communication device
WO2022107347A1 (en) Slave device, network system, method and program for controlling slave device
JP4026409B2 (en) CPU device for controller, CPU unit, CPU base, and abnormality processing method for CPU device
JP3166127B2 (en) LAN switching system and power system monitoring and control system
JP2023161769A (en) Switching method for duplex communication interface module

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20050920

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20070827

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20070904

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20071101

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20071211

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

Ref document number: 4061489

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20110111

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20110111

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20120111

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20130111

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20140111

Year of fee payment: 6

LAPS Cancellation because of no payment of annual fees