JP3187303B2 - Data communication system - Google Patents

Data communication system

Info

Publication number
JP3187303B2
JP3187303B2 JP26578395A JP26578395A JP3187303B2 JP 3187303 B2 JP3187303 B2 JP 3187303B2 JP 26578395 A JP26578395 A JP 26578395A JP 26578395 A JP26578395 A JP 26578395A JP 3187303 B2 JP3187303 B2 JP 3187303B2
Authority
JP
Japan
Prior art keywords
data
station
communication
transmitted
transmission
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 - Lifetime
Application number
JP26578395A
Other languages
Japanese (ja)
Other versions
JPH09107372A (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.)
Mitsubishi Electric Corp
Original Assignee
Mitsubishi Electric Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Mitsubishi Electric Corp filed Critical Mitsubishi Electric Corp
Priority to JP26578395A priority Critical patent/JP3187303B2/en
Publication of JPH09107372A publication Critical patent/JPH09107372A/en
Application granted granted Critical
Publication of JP3187303B2 publication Critical patent/JP3187303B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Small-Scale Networks (AREA)

Description

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

【0001】[0001]

【発明の属する技術分野】この発明は、複数の局をルー
プ型通信路でループ状に接続し、ハイレベル・データリ
ング制御手順による通信方式(以下、HDLC方式とい
う)の通信フォーマットを使用して通信を行うデータ通
信システムに関するものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a method of connecting a plurality of stations in a loop by a loop-type communication path and using a communication format of a communication system (hereinafter, referred to as an HDLC system) by a high-level data ring control procedure. The present invention relates to a data communication system for performing communication.

【0002】[0002]

【従来の技術】図11は従来のデータ通信システムを示
すブロツク構成図である。図において、1a、1b、1
c、・・・・、1nはデータの送受信を行う局であり、
2はこれら各局1a、1b、1c、・・・・、1nをル
ープ状に接続しているループ型通信路である。3は各局
1a、1b、1c、・・・・、1nのデータ送信部であ
り、4は同じくデータ受信部である。5a、5b、5
c、・・・・、5nは各局1a、1b、1c、・・・
・、1nが必要時にループ型通信路2に送出する通信デ
ータであり、6a、6b、6c、・・・・、6nはこの
通信データ5a、5b、5c、・・・・、5nの前に付
加されて送出され、下流の局で受信データサンプリング
用クロックを同期させるために用いられる同期用フラグ
である。
2. Description of the Related Art FIG. 11 is a block diagram showing a conventional data communication system. In the figure, 1a, 1b, 1
.., 1n are stations for transmitting and receiving data,
Reference numeral 2 denotes a loop communication path connecting these stations 1a, 1b, 1c,..., 1n in a loop. Reference numeral 3 denotes a data transmission unit of each station 1a, 1b, 1c,..., 1n, and reference numeral 4 denotes a data reception unit. 5a, 5b, 5
.., 5n are stations 1a, 1b, 1c,.
.., 1n is communication data to be sent to the loop communication path 2 when necessary, and 6a, 6b, 6c,..., 6n are before the communication data 5a, 5b, 5c,. This is a synchronization flag that is added and transmitted, and is used by a downstream station to synchronize the received data sampling clock.

【0003】次に動作について説明する。局1aからル
ープ型通信路2上に通信データ5aを出力するときに
は、まず局1aが下流の局1bに向けて、同期用フラグ
6aを受信側が受信データサンプリング用クロックを同
期させるために必要な数だけ送出し、その後続いて通信
データ5aを送出する。一方、局1bではその同期用フ
ラグ6aによって受信データサンプリング用クロックを
同期させてから通信データ5aを受信する。次に局1b
はさらに下流の局1cに向けて、同期用フラグ6bを受
信側が受信データサンプリング用クロックを同期するの
に必要な数だけ送出し、その後続いて通信データ5bを
送出する。局1cは同期用フラグ6bによって受信デー
タサンプリング用クロックを同期させてから通信データ
5bを受信する。以下この動作を繰り返し、最後に局1
aが局1nからの同期用フラグ6nによって同期させた
受信データサンプリング用クロックを用いて通信データ
5nを受信し、局1aのデータ出力の動作が完了する。
Next, the operation will be described. When the communication data 5a is output from the station 1a onto the loop communication path 2, first, the station 1a sets the synchronization flag 6a toward the downstream station 1b by the number necessary for the receiving side to synchronize the received data sampling clock. And then the communication data 5a. On the other hand, the station 1b receives the communication data 5a after synchronizing the reception data sampling clock with the synchronization flag 6a. Next, station 1b
Sends the synchronization flag 6b to the downstream station 1c as many as necessary for the receiving side to synchronize the received data sampling clock, and then sends the communication data 5b. The station 1c receives the communication data 5b after synchronizing the reception data sampling clock with the synchronization flag 6b. Hereinafter, this operation is repeated.
a receives the communication data 5n using the received data sampling clock synchronized by the synchronization flag 6n from the station 1n, and the data output operation of the station 1a is completed.

【0004】なお、このような従来のデータ通信システ
ムに関連のある技術が記載された文献としては、例えば
特開昭63−198432号公報などがある。
[0004] Incidentally, as a document describing a technique related to such a conventional data communication system, there is, for example, JP-A-63-198432.

【0005】[0005]

【発明が解決しようとする課題】従来のデータ通信シス
テムは以上のように構成されているので、受信データと
自局の基本クロックタイミングの位相比較を行い、その
差分によつて自局のクロックタイミングと受信データを
同期させる場合、当該データ通信システム上の各局1
a、1b、1c、・・・・、1nが通信データ5a、5
b、5c、・・・・、5nを送出する度に、その通信デ
ータ5a、5b、5c、・・・・、5nの先頭に、下流
の局が自局のクロックを受信データに同期させるのに必
要な数の同期用フラグ6a、6b、6c、・・・・、6
nを付けなければならず、そのために送信する通信デー
タ5a、5b、5c、・・・・、5nに局数分の同期に
必要な同期用フラグ6a、6b、6c、・・・・、6n
が加算され、通信時間が長くなるという課題があった。
Since the conventional data communication system is configured as described above, the phase of the received data is compared with the base clock timing of the own station, and the clock timing of the own station is determined based on the difference. When synchronizing the received data with the respective stations 1 on the data communication system,
a, 1b, 1c,..., 1n are communication data 5a, 5
b, 5c,..., 5n, the downstream station synchronizes its own clock with the received data at the beginning of the communication data 5a, 5b, 5c,. , The necessary number of synchronization flags 6a, 6b, 6c,.
n, and the communication data 5a, 5b, 5c,..., 5n to be transmitted for this purpose require synchronization flags 6a, 6b, 6c,.
Is added, and the communication time becomes longer.

【0006】この発明は上記のような課題を解決するた
めになされたもので、主局よりループ型通信路上に常時
データを送出し続けて同期クロックを補正、維持するこ
とにより、各局が通信データを送出する前にわざわざ必
要数の同期用フラグを付加する必要をなくし、データ通
信時間を短縮することが可能なデータ通信システムを得
ることを目的とする。
SUMMARY OF THE INVENTION The present invention has been made to solve the above-described problems. Each station continuously transmits data on a loop-type communication path to correct and maintain a synchronous clock, thereby enabling each station to communicate data. It is an object of the present invention to obtain a data communication system capable of shortening the data communication time by eliminating the need to add the necessary number of synchronization flags before sending the data.

【0007】[0007]

【課題を解決するための手段】請求項1記載の発明に係
るデータ通信システムは、ループ状に接続されたHDL
C方式の通信フォーマットで通信を行う複数の局のうち
の1つを、再生中継を行わずに自局のタイミングで通信
データを送出し、通信データ送信不要時においては常
時、HDLC方式の通信フォーマットで通信データの先
頭と末尾に配されているフラグと同じパターンのパター
ンデータを送出し続ける主局とし、その他の局を、その
パターンデータに基づいて同期クロックを補正、維持
し、データ送信時以外は常に受信データを再生中継し続
ける従局としたものである。
According to a first aspect of the present invention, there is provided a data communication system comprising: an HDL connected in a loop;
One of a plurality of stations communicating in the C format communication format transmits communication data at its own timing without performing regenerative relay, and always uses the HDLC communication format when communication data transmission is not required. The master station continues to transmit the pattern data of the same pattern as the flags arranged at the beginning and end of the communication data, and the other stations correct and maintain the synchronization clock based on the pattern data, except when transmitting data. Is a slave station that constantly reproduces and relays received data.

【0008】請求項2記載の発明に係るデータ通信シス
テムは、各従局に、自局の送信する通信データと上流の
局より受信したパターンデータのビット遅延量を検出す
る遅延検出部、検出された遅延ビット数に従って送信す
る通信データをパターンデータに同期させる送信データ
遅延部、および再生中継する受信データと送信する通信
データの切り替えをバイト単位の区切りで行う送信セレ
クト部を備えたものである。
In the data communication system according to the second aspect of the present invention, each of the slave stations has a delay detecting section for detecting a bit delay amount between communication data transmitted by the own station and pattern data received from an upstream station. It comprises a transmission data delay unit for synchronizing communication data to be transmitted with pattern data in accordance with the number of delay bits, and a transmission selection unit for switching between reception data to be reproduced and relayed and communication data to be transmitted in byte units.

【0009】請求項3記載の発明に係るデータ通信シス
テムは、各従局に、上流の局より受信したパターンデー
タと自局の送信する通信データのビット遅延量を検出す
る遅延検出部、検出された遅延ビット数に従って再生中
継するパターンデータを送信する通信データに同期させ
る受信データ遅延部、および再生中継する受信データと
送信する通信データの切り替えをバイト単位の区切りで
行う送信セレクト部を備えたものである。
According to a third aspect of the present invention, there is provided a data communication system, wherein each of the slave stations detects a bit delay amount between pattern data received from an upstream station and communication data transmitted by the own station. It is provided with a reception data delay unit for synchronizing the pattern data to be reproduced and relayed with the communication data to be transmitted according to the number of delay bits, and a transmission selection unit for switching between the received data to be reproduced and relayed and the communication data to be transmitted in byte units. is there.

【0010】請求項4記載の発明に係るデータ通信シス
テムは、各従局に、自局の送信する通信データを蓄積す
るシフトレジスタ、上流の局より受信したパターンデー
タのバイト単位の区切りを検出して、シフトレジスタに
データ送信のタイミングを与えるデータ送信タイミング
検出部、および再生中継する受信データとシフトレジス
タから出力された送信する通信データの切り替えを行う
送信セレクト部を備えたものである。
In the data communication system according to the present invention, each of the slave stations detects a shift register for storing communication data transmitted by the own station, and detects a byte-unit delimiter of pattern data received from an upstream station. , A data transmission timing detector for giving a data transmission timing to the shift register, and a transmission selector for switching between received data to be reproduced and relayed and communication data to be transmitted outputted from the shift register.

【0011】請求項5記載の発明に係るデータ通信シス
テムは、各従局に、上流の局との間の回線断が検出され
ると、動作クロックのタイミングを、上流の局からのパ
ターンデータに基づく同期クロックから自局で発生する
基本クロックのタイミングに切り替えるとともに、上流
の局からの受信データの再生中継を停止させる送信制御
回路を備えたものである。
In the data communication system according to the present invention, when a slave station detects a line disconnection with an upstream station, the timing of an operation clock is determined based on pattern data from the upstream station. It is provided with a transmission control circuit for switching from the synchronous clock to the timing of the basic clock generated in the own station, and for stopping the reproduction and relay of the received data from the upstream station.

【0012】請求項6記載の発明に係るデータ通信シス
テムは、各従局に、受信データ不良が一定時間以上続い
たことが検出されると、動作クロックのタイミングを、
上流の局からのパターンデータに基づく同期クロックか
ら自局で発生する基本クロックのタイミングに切り替え
るとともに、上流の局からの受信データの再生中継を停
止させる送信制御回路を備えたものである。
In the data communication system according to the present invention, when it is detected by each slave station that the reception data failure has continued for a predetermined time or more, the timing of the operation clock is changed.
It is provided with a transmission control circuit for switching from the synchronous clock based on the pattern data from the upstream station to the timing of the basic clock generated in the own station, and stopping the reproduction relay of the received data from the upstream station.

【0013】[0013]

【発明の実施の形態】以下、この発明の実施の一形態を
説明する。 実施の形態1. 図1はこの発明の実施の形態1によるデータ通信システ
ムを示すブロック構成図である。図において、1a、1
b、1c、・・・・、1nはHDLC方式の通信フォー
マットを使用してデータの送受信を行う複数の局であ
り、その最上流の局1aを主局、他の局1b、1c、1
d、・・・・、1nを従局とする。2はこれら各局1
a、1b、1c、・・・・、1nをループ状に接続して
いるループ型通信路である。3は各局1a、1b、1
c、・・・・、1nのデータ送信部、4は同じくデータ
受信部であり、5a、5b、5c、・・・・、5nは各
局1a、1b、1c、・・・・、1nが送出する通信デ
ータである。また、7はバイト単位でフレーム同期をと
るフレーム同期回路、通信回線切断時や連続して不良デ
ータを受信した時に動作するデータ出力回路などを含ん
だ各局1a、1b、1c、・・・・、1nの通信制御部
である。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS One embodiment of the present invention will be described below. Embodiment 1 FIG. FIG. 1 is a block diagram showing a data communication system according to Embodiment 1 of the present invention. In the figure, 1a, 1
, 1n are a plurality of stations that transmit and receive data using the communication format of the HDLC system, and the most upstream station 1a is the main station, and the other stations 1b, 1c, 1n
.., 1n are slave stations. 2 is each of these stations 1
a, 1b, 1c,..., 1n are loop-type communication paths connecting in a loop. 3 is each station 1a, 1b, 1
.., 1n are data transmitters, 4 is a data receiver, 5a, 5b, 5c,..., 5n is each station 1a, 1b, 1c,. Communication data. Reference numeral 7 denotes each of the stations 1a, 1b, 1c,... Including a frame synchronizing circuit for synchronizing frames in byte units, a data output circuit which operates when a communication line is disconnected or when bad data is continuously received. 1n is a communication control unit.

【0014】ここで、この実施の形態1においては、各
局1a、1b、1c、・・・・、1n中の1つ、例えば
主局1aの位置をループ状に接続された当該データ通信
システムの最上流として、この主局1aを再生中継は行
わずに自局のタイミングで通信データ5aを送出すると
ともに、通信データ送信不要時においては、HDLC方
式の通信フォーマットによる通信データ5aがその先頭
と末尾に備えているフラグと同一パターンのパターンデ
ータを常に送出し続ける主局としている。なお、図中の
8はそのパターンデータを示している。また、その他の
局1b、1c、1d、・・・・、1nは、主局1aより
送出されるパターンデータ8に基づいて同期クロックの
補正、維持を行い、上流の局からの受信データを再生中
継して下流の局に伝送するとともに、自局より通信デー
タ5b、5c、5d、・・・・、5nを送信する場合に
は、上流の局から下流の局へ再生中継するデータを自局
の通信データ5b、5c、5d、・・・・、5nに切り
替えて送信する従局となっている。
Here, in the first embodiment, one of the stations 1a, 1b, 1c,..., 1n, for example, the position of the main station 1a is connected to the data communication system in a loop. As the most upstream, the communication data 5a is transmitted at the own station timing without reproducing and relaying the master station 1a, and when the communication data transmission is unnecessary, the communication data 5a in the communication format of the HDLC system has the head and tail thereof. The master station always sends pattern data of the same pattern as the flag provided in the master station. Note that reference numeral 8 in the figure denotes the pattern data. The other stations 1b, 1c, 1d,..., 1n correct and maintain the synchronous clock based on the pattern data 8 sent from the main station 1a, and reproduce the received data from the upstream station. When the communication data 5b, 5c, 5d,..., 5n is transmitted from the own station while relaying and transmitting the data to the downstream station, the data to be reproduced and relayed from the upstream station to the downstream station is transmitted to the own station. 5n, 5b, 5c, 5d,..., 5n.

【0015】次に動作について説明する。この実施の形
態1によるデータ通信システムにおいては、全ての局1
a、1b、1c、・・・・、1nにおいて同期クロック
を同期させ、またその同期を維持するために、主局1a
よりループ型通信路2上に常時、データ変化によって同
期クロックを同期させるためのパターンデータ8が送出
され続けるようになっている。そのために、各局1a、
1b、1c、・・・・、1nは以下のように動作する。
Next, the operation will be described. In the data communication system according to the first embodiment, all the stations 1
a, 1b, 1c, ····, to synchronize your stomach synchronous clock to 1n, also in order to maintain the synchronization, the main station 1a
Further, the pattern data 8 for synchronizing the synchronization clock by the data change is continuously transmitted on the loop communication path 2 at all times. Therefore, each station 1a,
, 1n operate as follows.

【0016】まず最上流に配置された主局1aの動作か
ら説明する。主局1aは通信データ5aを送信する必要
が生ずると、自局のタイミングでその通信データ5aを
送信する。また、通信データ5aの送信時以外において
は、通信データ5aの代わりに自局タイミングでパター
ンデータ8を常時送信し続ける。ここで、HDLC方式
にて送受信される通信データは、アドレス部、制御部、
情報部およびフレーム検査シーケンス部と、それらの先
端および末尾に配置されてフレームの区切りを示す、特
に意味を持たない符号による所定パターン“01111
110”のフラグとによって形成されている。前記パタ
ーンデータ8はそのフラグと同一のパターン“0111
1110”を有するデータである。このようにして、主
局1aは常時これらのデータを送信し続け、従局1nよ
り受信したデータの再生中継は行っていない。
First, the operation of the main station 1a arranged at the most upstream position will be described. When it becomes necessary to transmit the communication data 5a, the main station 1a transmits the communication data 5a at its own timing. Also, except when transmitting the communication data 5a, the pattern data 8 is always transmitted at the own station timing instead of the communication data 5a. Here, communication data transmitted and received by the HDLC method includes an address unit, a control unit,
The information unit and the frame inspection sequence unit, and a predetermined pattern “01111” that is arranged at the top and the end of the information unit and indicates a frame delimiter and has a sign that has no particular meaning.
The pattern data 8 is formed by the same pattern "0111" as the flag.
In this way, the master station 1a continuously transmits these data, and does not perform the relay of the data received from the slave station 1n.

【0017】次に、その下流に配置された従局1bの動
作について説明する。従局1bはまず、最上流の主局1
aより受信したパターンデータ8のビットが“0”→
“1”または“1”→“0”に変化するデータ変化によ
り、主局1aからの通信データ5aやパターンデータ8
に対する自局の同期クロックを同期させる。以後、その
同期クロックについて、受信した通信データ5aおよび
パターンデータ8のデータ変化に基づいて同期のずれを
自動的に補正することによってその同期を維持する。従
局1bはその同期クロックを使用して上流の主局1aか
ら送られてくる通信データ5aやパターンデータ8のデ
ータを受ける。また、従局1bは自局から通信データ5
bを送信するとき以外はこの同期クロックに同期して、
上流の主局1aより受信した通信データ5aおよびパタ
ーンデータ8を常時再生中継して下流の従局1cへ送出
する。なお、自局より通信データ5bを送信する場合に
は上記同期クロックに同期して、上流の主局1aより受
けたパターンデータ8の一部などのデータを自局の通信
データ5bに切り替えて送信する。
Next, the operation of the slave station 1b disposed downstream thereof will be described. The subordinate station 1b first has the most upstream main station 1
The bit of pattern data 8 received from “a” is “0” →
When the data changes from “1” or “1” to “0”, the communication data 5 a and the pattern data 8 from the main station 1 a are changed.
Synchronizes its own synchronization clock with respect to. Thereafter, the synchronization is maintained by automatically correcting the synchronization deviation of the synchronization clock based on the data change of the received communication data 5a and pattern data 8. The slave station 1b receives the communication data 5a and the pattern data 8 sent from the upstream master station 1a using the synchronous clock. The slave station 1b transmits communication data 5 from its own station.
except when transmitting b, in synchronization with this synchronous clock,
The communication data 5a and the pattern data 8 received from the upstream master station 1a are constantly reproduced and relayed and transmitted to the downstream slave station 1c. When transmitting the communication data 5b from the own station, the data such as a part of the pattern data 8 received from the upstream main station 1a is switched to the communication data 5b of the own station and transmitted in synchronization with the synchronization clock. I do.

【0018】次に、その下流の従局1cも従局1bと同
様に、上流の従局1bより受信した通信データ5a、5
bおよびパターンデータ8により同期クロックの補正、
維持を行う。また自局から通信データ5cを送信すると
き以外は、上流の従局1bから受信した通信データ5
a、5bおよびパターンデータ8を、同期クロックに同
期して常時再生中継をすることにより下流の従局1dへ
送出する。この従局1bおよび従局1cと同様の動作が
従局1nまでの各局で行われる。これにより、当該デー
タ通信システム上の全ての従局1b、1c、1d、・・
・・、1nが常時データの受信を行うことになる。この
ように、各従局1b、1c、1d、・・・・、1nでは
受信データのデータ変化によって同期クロックを同期さ
せ、引き続きその同期クロックの同期を受信データのデ
ータ変化に基づいて随時修正しているため、常に同期が
維持されている。
Next, similarly to the slave station 1b, the downstream slave station 1c also receives communication data 5a, 5
b and the pattern data 8 to correct the synchronous clock,
Perform maintenance. Except when the communication data 5c is transmitted from the own station, the communication data 5 received from the upstream slave station 1b is not transmitted.
a, 5b and the pattern data 8 are transmitted to the downstream slave station 1d by constantly reproducing and synchronizing with the synchronous clock. The same operation as the slave station 1b and the slave station 1c is performed in each station up to the slave station 1n. As a result, all the slave stations 1b, 1c, 1d,.
.. 1n will always receive data. In this manner, the slave stations 1b, 1c, 1d,..., 1n synchronize the synchronization clock by the data change of the received data, and continuously correct the synchronization of the synchronous clock at any time based on the data change of the received data. Therefore, synchronization is always maintained.

【0019】なお、従来のデータ通信システムでは、必
要なデータのみを送信していたため、下流の受信側の局
ではデータを受信するまでは同期を合わせることができ
ず、上流の局から送られてくる通信データを正確に受信
するため、上流の局では通信データの前に、同期を合わ
せるのに必要なデータ変化分の同期用フラグを付加して
送信していた。しかしながら、この実施の形態1のデー
タ通信システムによれば、常時データを送出し続けるこ
とにより、従来のデータ通信システムのように送信する
通信データの前にわざわざ必要数の同期用フラグを付け
る必要がなく、所望の通信データを即出力することが可
能となり、通信にかかる時間を短縮することができる。
In the conventional data communication system, only necessary data is transmitted. Therefore, the downstream receiving station cannot synchronize until the data is received. In order to correctly receive incoming communication data, the upstream station has added a synchronization flag corresponding to a data change required for synchronization before transmitting the communication data. However, according to the data communication system of the first embodiment, by continuously transmitting data, it is necessary to attach the necessary number of synchronization flags before communication data to be transmitted as in the conventional data communication system. Thus, desired communication data can be output immediately, and the time required for communication can be reduced.

【0020】実施の形態2. 図2はこの発明の実施の形態2によるデータ通信システ
ムで用いられるフレーム同期回路を示すブロック構成図
であり、このフレーム同期回路は図1に示す通信制御部
7内に配置されて、送信する通信データのバイト単位で
の同期をとっている。なお、各局1a、1b、1c、・
・・・、1nから送出される通信データ5a、5b、5
c、・・・・、5nはここでは特に区別する必要がない
ので、以下の説明においては単に通信データ5と記す。
Embodiment 2 FIG. 2 is a block diagram showing a frame synchronization circuit used in the data communication system according to the second embodiment of the present invention. This frame synchronization circuit is arranged in the communication control unit 7 shown in FIG. Data is synchronized in byte units. Each station 1a, 1b, 1c,.
... Communication data 5a, 5b, 5 transmitted from 1n
.., 5n do not need to be particularly distinguished here, and will be simply referred to as communication data 5 in the following description.

【0021】図において、11は図示を省略した同期ク
ロック発生部が上流の局から受けたパターンデータ8に
基づいて生成した同期クロックを伝送する同期クロック
線であり、12は自局より送信する通信データ5を伝送
する送信データ線、13は上流の局より受信した通信デ
ータ5およびパターンデータ8を含む受信データを伝送
する受信データ線である。14は送信する通信データ5
の先頭に配置されたフラグの立ち下がりを検出する送信
データ立ち下がり検出部であり、15は受信データ線1
3を伝送されてくる上流局からの受信データ中のパター
ンデータ8の立ち下がりを検出する受信データ立ち下が
り検出部である。16はこれら送信データ立ち下がり検
出部14と受信データ立ち下がり検出部15の検出デー
タに従って、送信する通信データ5の先頭のフラグが立
ち下がってから、受信データ中のそれに最も近いパター
ンデータ8が立ち下がるまでの間、同期クロック線11
を伝送されてくる同期クロックをカウントすることによ
って、送信する通信データ5のフラグが受信データ中の
パターンデータ8より何ビット進んでいるかを検出し、
そのビット遅延量を認識する遅延検出部としてのクロッ
ク数カウント部であり、17はこのクロック数カウント
部16から出力される遅延ビット数が伝送される遅延ビ
ット数線である。
In the figure, reference numeral 11 denotes a synchronous clock line for transmitting a synchronous clock generated by a synchronous clock generator (not shown) based on pattern data 8 received from an upstream station. A transmission data line for transmitting data 5 and a reception data line 13 for transmitting communication data 5 and pattern data 8 received from an upstream station are received. 14 is communication data 5 to be transmitted
Is a transmission data fall detection unit for detecting the fall of a flag arranged at the top of the reception data line 1.
3 is a reception data fall detection unit that detects the fall of the pattern data 8 in the reception data from the upstream station that receives the data 3. In accordance with the detection data of the transmission data falling detecting unit 14 and the receiving data falling detecting unit 15, the pattern data 8 closest to the flag of the received data falls after the leading flag of the communication data 5 falls. Until it falls, the synchronous clock line 11
By detecting the number of bits of the flag of the communication data 5 to be transmitted ahead of the pattern data 8 in the received data,
A clock number counting unit as a delay detecting unit for recognizing the bit delay amount is provided. Reference numeral 17 denotes a delay bit number line to which the number of delay bits output from the clock number counting unit 16 is transmitted.

【0022】18は送信データ線12を伝送されてくる
自局より送信する通信データ5に対して、遅延なしから
7ビット遅延までの8種の遅延を与えるシフトレジスタ
を備え、遅延ビット数線17を介してクロック数カウン
ト部16より送られてくる遅延ビット数に応じてその遅
延量を選択することにより、送信する通信データ5を受
信データ線13上のパターンデータ8に同期させる送信
データ遅延部である。19は出力データをバイト単位の
区切りにおいて、通信データ送信時には受信データ線1
3上の受信データから送信データ遅延部18より出力さ
れる通信データ5に、通信データ送信終了時には送信デ
ータ遅延部18の出力データから受信データ線13上の
受信データにそれぞれ切り替える送信セレクト部であ
る。20はこの送信セレクト部19で切り替えられた出
力データを下流の局へ送出するために自局の送信部3に
伝送する出力データ線である。
Reference numeral 18 denotes a shift register for giving eight kinds of delays from no delay to 7-bit delay to the communication data 5 transmitted from the own station transmitted through the transmission data line 12, and a delay bit number line 17 is provided. The transmission data delay unit synchronizes the communication data 5 to be transmitted with the pattern data 8 on the reception data line 13 by selecting the delay amount according to the number of delay bits transmitted from the clock number counting unit 16 via the It is. Reference numeral 19 designates the output data at the byte unit break, and the reception data line 1 when transmitting the communication data.
3 is a transmission selection unit that switches from the received data on the communication data 5 output from the transmission data delay unit 18 to the communication data 5 output from the transmission data delay unit 18, and from the output data of the transmission data delay unit 18 to the reception data on the reception data line 13 when communication data transmission is completed. . Reference numeral 20 denotes an output data line for transmitting the output data switched by the transmission selection unit 19 to the transmission unit 3 of the own station in order to transmit the output data to a downstream station.

【0023】また、図3は上記フレーム同期回路の各部
の信号の時間関係を示すタイミングチャートであり、同
図(a)は受信データ線13上を伝送される受信デー
タ、同図(b)は送信データ線12上を伝送される送信
すべき通信データ、同図(c)は出力データ線20上を
伝送される下流の局への出力データをそれぞれ示してい
る。
FIGS. 3A and 3B are timing charts showing the time relationship of signals of the respective parts of the frame synchronization circuit. FIG. 3A shows received data transmitted on the received data line 13, and FIG. The communication data to be transmitted transmitted on the transmission data line 12 and the output data to the downstream station transmitted on the output data line 20 are shown in FIG.

【0024】次に動作について説明する。ここで、上記
実施の形態1において、最上流の主局1a以外の各従局
1b、1c、1d、・・・・、1nでは、上流の局より
の受信データを再生中継してそのまま下流の局へ出力し
ている。そのとき自局の通信データ5を送信しようとし
た場合、それまで再生中継していたパターンデータ8と
送信しようとする通信データ5とがバイト単位で同期し
ていないと、HDLC方式により通信異常となる。従っ
て、主局1a以外の従局1b、1c、1d、・・・・、
1nは、送信しようとする通信データ5を再生中継して
いるパターンデータ8とバイト単位で同期させてから出
力させる必要がある。そのため、ここでは、送信しよう
とする通信データ5を何ビット遅らせれば、再生中継す
るパターンデータ8とバイト単位で同期するかを調べ、
バイト単位の同期合わせを行うようにしている。
Next, the operation will be described. Here, in the first embodiment, each of the slave stations 1b, 1c, 1d,..., 1n other than the most upstream master station 1a reproduces and relays the received data from the upstream station and directly relays the received data from the downstream station. Output to At that time, if the communication data 5 of the own station is to be transmitted, if the pattern data 8 that has been reproduced and relayed up to that point and the communication data 5 to be transmitted are not synchronized in byte units, a communication error will occur due to the HDLC method. Become. Therefore, the slave stations 1b, 1c, 1d,... Other than the master station 1a
1n needs to be output after synchronizing the communication data 5 to be transmitted with the pattern data 8 being reproduced and relayed in byte units. For this reason, here, it is checked how many bits of the communication data 5 to be transmitted should be delayed to synchronize with the pattern data 8 to be reproduced and relayed in byte units.
Synchronization is performed in byte units.

【0025】すなわち、この実施の形態2のフレーム同
期回路においては、自局のデータ送信時に、送信データ
立ち下がり検出部14が送信する通信データ5の先頭に
配置されたフラグの立ち下がりを検出する。一方、受信
データ立ち下がり検出部15も受信データ中のパターン
データ8の立ち下がりを検出する。次にクロック数カウ
ント部16はそれら両者による検出結果に基づいて、通
信データ5の先頭のフラグが立ち下がってから、それに
最も近いパターンデータ8が立ち下がるまでの間、同期
クロックをカウントすることによって、送信する通信デ
ータ5が受信データ中のパターンデータ8より何ビット
進んでいるかを検出する。その検出結果は遅延ビット数
としてクロック数カウント部16より送信データ遅延部
18に通知される。送信データ遅延部18は自局より送
信する通信データ5に対して、遅延なしから7ビット遅
延までの8種の遅延を与えるシフトレジスタを備えてお
り、クロック数カウント部16の出力する遅延ビット数
に応じてその遅延量を選択し、送信する通信データ5に
選択した遅延量の遅延を与えて受信データ線13上のパ
ターンデータ8に同期させる。
That is, in the frame synchronization circuit according to the second embodiment, the transmission data falling detecting section 14 detects the falling of the flag arranged at the head of the communication data 5 to be transmitted at the time of data transmission of the own station. . On the other hand, the reception data fall detection unit 15 also detects the fall of the pattern data 8 in the reception data. Next, the clock number counting section 16 counts the synchronous clocks from the time when the first flag of the communication data 5 falls to the time when the closest pattern data 8 falls based on the detection results of the two. , And how many bits the transmitted communication data 5 is ahead of the pattern data 8 in the received data. The detection result is notified from the clock number counting unit 16 to the transmission data delay unit 18 as the number of delay bits. The transmission data delay unit 18 includes a shift register that gives eight kinds of delays from no delay to a 7-bit delay to the communication data 5 transmitted from the own station. The delay amount is selected in accordance with, and the communication data 5 to be transmitted is delayed by the selected delay amount to synchronize with the pattern data 8 on the reception data line 13.

【0026】ここで、具体例として、送信しようとする
通信データが2ビット遅らせることによって、再生中継
しているパターンデータ8とバイト単位で同期する場合
の動作について説明する。送信しようとしている通信デ
ータ5の先頭に配置されたフラグが立ち下がってから、
受信データ中のそれに最も近いパターンデータ8が立ち
下がるまでの間の同期クロックを、クロック数カウント
部16でカウントすることにより、再生中継中のパター
ンデータ8が送信する通信データ5のフラグより2ビッ
ト遅れていることがわかる。この遅延ビット数“2”は
クロック数カウント部16より送信データ遅延部18に
送られ、送信データ遅延部18ではその遅延ビット数
“2”に基づいて、遅延なしから7ビット遅延まで1ビ
ットずつ、8種の遅延が与えられた通信データ5の中か
ら、2ビット遅延が与えられた通信データ5を選択す
る。これにより、2ビット進んでいた送信すべき通信デ
ータ5に2ビットの遅延が与えられ、再生中継している
パターンデータ8に同期させることができる。
Here, as a specific example, an operation in the case where the communication data to be transmitted is delayed by 2 bits to synchronize with the pattern data 8 being reproduced and relayed in byte units will be described. After the flag placed at the head of the communication data 5 to be transmitted falls,
The number of synchronization clocks until the pattern data 8 closest to the falling edge of the received data falls is counted by the clock number counting unit 16, so that two bits are transmitted from the flag of the communication data 5 transmitted by the pattern data 8 being reproduced and relayed. It turns out that it is late. The number of delay bits “2” is sent from the clock number counting section 16 to the transmission data delay section 18, and the transmission data delay section 18, based on the number of delay bits “2”, has 1 bit from no delay to 7 bit delay. , The communication data 5 with a 2-bit delay is selected from the communication data 5 with a delay of 8 types. As a result, the communication data 5 to be transmitted, which has been advanced by 2 bits, is given a 2-bit delay, and can be synchronized with the pattern data 8 that is being reproduced and relayed.

【0027】このようにして、再生中継しているパター
ンデータ8に同期させた送信すべき通信データ5は、送
信データ遅延部18より送信セレクト部19に送られ、
出力データはこの送信セレクト部19において、再生中
継されている受信データから送信データ遅延部18の出
力する送信すべき通信データ5に切り替えられる。これ
により、下流の局に対してバイト単位の同期のずれのな
い通信データ5の送出が可能となり、通信異常を起すこ
ともなくなる。
In this manner, the communication data 5 to be transmitted synchronized with the pattern data 8 being reproduced and relayed is sent from the transmission data delay unit 18 to the transmission selection unit 19,
The output data is switched in the transmission selection unit 19 from the received and reproduced data to the communication data 5 to be transmitted, which is output from the transmission data delay unit 18. As a result, it is possible to transmit the communication data 5 to the downstream station without synchronization deviation in byte units, and it is possible to prevent a communication abnormality from occurring.

【0028】実施の形態3. 図4はこの発明の実施の形態3によるデータ通信システ
ムで用いられるフレーム同期回路を示すブロック構成図
であり、このフレーム同期回路は図1に示す通信制御部
7内に配置されて、通信データ送信完了時のパターンデ
ータ8のバイト単位での同期をとっている。なお、各局
1a、1b、1c、・・・・、1nから送出される通信
データ5a、5b、5c、・・・・、5nはここでも特
に区別する必要がないので、以下の説明においては単に
通信データ5と記す。
Embodiment 3 FIG. 4 is a block diagram showing a frame synchronization circuit used in the data communication system according to the third embodiment of the present invention. This frame synchronization circuit is arranged in communication control unit 7 shown in FIG. The pattern data 8 at the time of completion is synchronized in byte units. Note that the communication data 5a, 5b, 5c,..., 5n transmitted from the stations 1a, 1b, 1c,. Described as communication data 5.

【0029】図において、21は図示を省略した同期ク
ロック発生部が上流の局から受けたパターンデータ8に
基づいて生成した同期クロックを伝送する同期クロック
線であり、22は自局より送信するフレーム同期済の通
信データ5を伝送する送信データ線、23は上流の局よ
り受信した通信データ5およびパターンデータ8を含む
受信データを伝送する受信データ線である。24は送信
するフレーム同期済の通信データ5の末尾に配置された
フラグの立ち下がりを検出する送信データ立ち下がり検
出部であり、25は受信データ線23を伝送されてくる
上流局からの受信データ中のパターンデータ8の立ち下
がりを検出する受信データ立ち下がり検出部である。2
6はこれら送信データ立ち下がり検出部24と受信デー
タ立ち下がり検出部25の検出データに従って、受信デ
ータ中のパターンデータ8が立ち下がってから、送信す
る通信データ5の末尾のフラグが立ち下がるまでの間、
同期クロック線21を伝送されてくる同期クロックをカ
ウントすることによって、受信データ中のパターンデー
タ8がフレーム同期済の通信データ5のフラグより何ビ
ット進んでいるかを検出し、そのビット遅延量を認識す
る遅延検出部としてのクロック数カウント部であり、2
7はこのクロック数カウント部26から出力される遅延
ビット数が伝送される遅延ビット数線である。
In the figure, reference numeral 21 denotes a synchronous clock line for transmitting a synchronous clock generated by a synchronous clock generator (not shown) based on pattern data 8 received from an upstream station, and reference numeral 22 denotes a frame transmitted from the own station. A transmission data line for transmitting the synchronized communication data 5 and a reception data line 23 for transmitting the communication data 5 and the reception data including the pattern data 8 received from the upstream station. Reference numeral 24 denotes a transmission data fall detection unit that detects a fall of a flag arranged at the end of the frame-synchronized communication data 5 to be transmitted, and 25 denotes reception data from an upstream station transmitted through the reception data line 23. This is a reception data fall detection unit that detects the fall of the middle pattern data 8. 2
Reference numeral 6 denotes a period from when the pattern data 8 in the received data falls to when the last flag of the communication data 5 to be transmitted falls in accordance with the detection data of the transmission data fall detection unit 24 and the reception data fall detection unit 25. while,
By counting the number of synchronization clocks transmitted through the synchronization clock line 21, it is detected how many bits the pattern data 8 in the received data is ahead of the flag of the frame-synchronized communication data 5, and recognizes the bit delay amount. Clock count section as a delay detection section that performs
Reference numeral 7 denotes a delay bit number line through which the number of delay bits output from the clock number counting section 26 is transmitted.

【0030】28は受信データ線23を伝送されてくる
受信データに対して、遅延なしから7ビット遅延までの
8種の遅延を与えるシフトレジスタを備え、遅延ビット
数線27を介してクロック数カウント部26より送られ
てくる遅延ビット数に応じてその遅延量を選択すること
により、受信データ線23上を伝送されてくる受信デー
タを送信データ線22上のフレーム同期済の通信データ
5に同期させる受信データ遅延部である。29は出力デ
ータをバイト単位の区切りにおいて、通信データ送信時
には受信データ遅延部28にて遅延された受信データか
ら送信データ線22上のフレーム同期済の通信データ5
に、通信データ送信終了時には送信データ線22上のフ
レーム同期済の通信データ5から受信データ遅延部28
にて遅延された受信データにそれぞれ切り替える送信セ
レクト部である。30はこの送信セレクト部29で切り
替えられた出力データを下流の局へ送出するために自局
の送信部3に伝送する出力データ線である。
Reference numeral 28 denotes a shift register for giving eight kinds of delays from no delay to 7-bit delay to the received data transmitted through the received data line 23, and counts the number of clocks via the delay bit line 27. By selecting the amount of delay according to the number of delay bits sent from the unit 26, the reception data transmitted on the reception data line 23 is synchronized with the frame-synchronized communication data 5 on the transmission data line 22. This is a reception data delay unit that causes the data to be delayed. Reference numeral 29 denotes output data in units of bytes, which are used to transmit frame-synchronized communication data 5 on the transmission data line 22 from the reception data delayed by the reception data delay unit 28 during transmission of communication data.
When the transmission of communication data is completed, the reception data delay unit 28
And a transmission selection unit that switches to the reception data delayed by. Reference numeral 30 denotes an output data line for transmitting the output data switched by the transmission selection unit 29 to the transmission unit 3 of the own station in order to transmit the output data to a downstream station.

【0031】また、図5は、データ送信終了時のフレー
ム同期回路各部のタイミングチャートであり、同図
(a)は送信データ線22上を伝送されるフレーム同期
済の送信データ、同図(b)は受信データ線23上を伝
送される受信データ、同図(c)は出力データ線30上
を伝送される下流の局への出力データをそれぞれ示して
いる。
FIG. 5 is a timing chart of each part of the frame synchronization circuit at the end of data transmission. FIG. 5A shows frame-synchronized transmission data transmitted on the transmission data line 22, and FIG. ) Shows received data transmitted on the received data line 23, and FIG. 3C shows output data to the downstream station transmitted on the output data line 30, respectively.

【0032】次に動作について説明する。HDLC方式
ではデータに“1”が5個以上連続すると5個の“1”
について1個の“0”が挿入される。そのため通信デー
タ5の送信開始時にバイト単位の同期を合わせた場合で
も、当該通信データ5の送信完了時には必ずしもバイト
単位の同期がとれているとは限らない。従って、その後
上流の局からの受信データをそのまま再生中継すると、
バイト単位の同期がずれて通信異常を起こす可能性が出
てくる。そのため、通信データ5の送信前と同様に再生
中継しようとしているパターンデータ8や通信データ5
を、バイト単位で同期させてから再生中継する必要があ
る。そのため、ここでは、再生中継しようとするパター
ンデータ8を何ビット遅らせれば、送信する通信データ
5とバイト単位で同期するかを調べ、バイト単位の同期
合わせを行うようにしている。
Next, the operation will be described. In the HDLC system, when five or more “1” s are consecutive in data, five “1” s are generated.
Is inserted for each "0". Therefore, even when the synchronization in the byte unit is synchronized at the start of the transmission of the communication data 5, the synchronization in the byte unit is not always achieved when the transmission of the communication data 5 is completed. Therefore, if the received data from the upstream station is reproduced and relayed as it is,
There is a possibility that the synchronization in bytes may be out of sync and a communication error may occur. Therefore, the pattern data 8 and the communication data 5 to be reproduced and relayed in the same manner as before the transmission of the communication data 5
Must be synchronized in byte units and then regenerated and relayed. Therefore, here, it is determined how many bits the pattern data 8 to be reproduced and relayed should be delayed before synchronizing with the communication data 5 to be transmitted in byte units, and performing synchronization in byte units.

【0033】すなわち、この実施の形態3のフレーム同
期回路においては、自局のデータ送信時において、送信
データ立ち下がり検出部24が送信するフレーム同期済
の通信データ5の末尾に配置されたフラグの立ち下がり
を検出する。一方、受信データ立ち下がり検出部25も
受信データ中のパターンデータ8の立ち下がりを検出す
る。次にクロック数カウント部26はそれら両者の検出
結果に基づいて、パターンデータ8が立ち下がってか
ら、フレーム同期済の通信データ5の末尾のフラグが立
ち下がるまでの間、同期クロックをカウントすることに
よって、受信データ中のパターンデータ8が送信するフ
レーム同期済の通信データ5より何ビット進んでいるか
を検出する。その検出結果は遅延ビット数としてクロッ
ク数カウント部26より受信データ遅延部28に通知さ
れる。受信データ遅延部28は再生中継する受信データ
に対して、遅延なしから7ビット遅延までの8種の遅延
を与えるシフトレジスタを備え、クロック数カウント部
26より送られてくる遅延ビット数に応じてその遅延量
を選択し、再生中継する受信データに選択した遅延量の
遅延を与えて送信するフレーム同期済の通信データ5に
同期させる。
That is, in the frame synchronization circuit according to the third embodiment, when transmitting data of the own station, the flag arranged at the end of the frame-synchronized communication data 5 transmitted by the transmission data falling detecting unit 24 is transmitted. Detect falling edge. On the other hand, the reception data fall detection unit 25 also detects the fall of the pattern data 8 in the reception data. Next, the clock number counting section 26 counts the synchronous clock from the fall of the pattern data 8 to the fall of the tail flag of the communication data 5 with frame synchronization based on the detection results of both. Thus, how many bits the pattern data 8 in the received data is ahead of the frame-synchronized communication data 5 to be transmitted is detected. The detection result is notified from the clock number counting section 26 to the reception data delay section 28 as the number of delay bits. The reception data delay unit 28 includes a shift register that gives eight kinds of delays from no delay to a 7-bit delay to the reception data to be reproduced and relayed, according to the number of delay bits sent from the clock number counting unit 26. The delay amount is selected, the received data to be reproduced and relayed is delayed by the selected delay amount, and the received data is synchronized with the frame-synchronized communication data 5 to be transmitted.

【0034】ここで、具体例として、再生中継しようと
する受信データのパターンデータ8が3ビット遅れるこ
とによって、送信しようとしているフレーム同期済の通
信データ5とバイト単位で同期する場合の動作について
説明する。再生中継されるパターンデータ8が立ち下が
ってから、フレーム同期済の通信データ5の末尾のフラ
グが立ち下がるまでの間の同期クロックを、クロック数
カウント部26でカウントすることにより、送信する通
信データ5のフラグが再生中継中しようとしているパタ
ーンデータ8より3ビット遅れていることがわかる。こ
の遅延ビット数“3”はクロック数カウント部26より
受信データ遅延部28に送られ、受信データ遅延部28
ではその遅延ビット数“3”に基づいて、遅延なしから
7ビット遅延まで1ビットずつ、8種の遅延が与えられ
た受信データの中から、3ビット遅延が与えられたもの
を選択する。これにより、3ビット進んでいた再生中継
する受信データに3ビットの遅延が与えられ、送信しよ
うとするフレーム同期済の通信データ5に同期させるこ
とができる。
Here, as a specific example, the operation in the case where the pattern data 8 of the received data to be reproduced and relayed is delayed by 3 bits and synchronized with the frame-synchronized communication data 5 to be transmitted in byte units will be described. I do. The number of synchronization clocks from when the pattern data 8 to be reproduced and relayed falls to when the end flag of the frame-synchronized communication data 5 falls is counted by the clock number counting unit 26 so that the communication data to be transmitted is counted. It can be seen that the flag of No. 5 is delayed by 3 bits from the pattern data 8 to be reproduced and relayed. The number of delay bits “3” is sent from the clock number counting section 26 to the reception data delay section 28, and the reception data delay section 28
Then, based on the number of delay bits "3", the reception data to which a 3-bit delay is given is selected from the reception data to which eight kinds of delays have been given, one bit at a time from no delay to a 7-bit delay. As a result, the received data to be reproduced and relayed, which has been advanced by 3 bits, is given a 3-bit delay, and can be synchronized with the frame-synchronized communication data 5 to be transmitted.

【0035】このようにして、送信するフレーム同期済
の通信データ5に同期させた再生中継する受信データ
は、受信データ遅延部28より送信セレクト部29に送
られ、出力データはこの送信セレクト部29において、
送信するフレーム同期済の通信データ5から受信データ
遅延部28によって遅延された受信データに切り替えら
れる。これにより、下流の局に対してバイト単位の同期
のずれのないパターンデータ8の再生中継が可能とな
り、通信異常を起すこともなくなる。
Thus, the received data to be reproduced and relayed in synchronization with the frame-synchronized communication data 5 to be transmitted is sent from the received data delay unit 28 to the transmission selection unit 29, and the output data is transmitted to the transmission selection unit 29. At
The transmission data is switched from the frame-synchronized communication data 5 to the reception data delayed by the reception data delay unit 28. As a result, the pattern data 8 can be reproduced and relayed to the downstream station without synchronization in units of bytes, and a communication error does not occur.

【0036】実施の形態4. 図6はこの発明の実施の形態4によるデータ通信システ
ムで用いられるフレーム同期回路を示すブロック構成図
であり、このフレーム同期回路は実施の形態2の場合と
同様に、図1に示す通信制御部7内に配置されて送信す
る通信データのバイト単位での同期をとっている。な
お、この場合も通信データ5a、5b、5c、・・・
・、5nは特に区別する必要がないので、以下の説明に
おいては単に通信データ5と記す。
Embodiment 4 FIG. FIG. 6 is a block diagram showing a frame synchronization circuit used in the data communication system according to the fourth embodiment of the present invention. This frame synchronization circuit is, like the second embodiment, a communication control unit shown in FIG. 7 and synchronizes communication data to be transmitted in units of bytes. In this case, the communication data 5a, 5b, 5c,...
Since 5n does not need to be particularly distinguished, it is simply referred to as communication data 5 in the following description.

【0037】図において、31は図示を省略した同期ク
ロック発生部が上流の局から受けたパターンデータ8に
基づいて生成した同期クロックを伝送する同期クロック
線であり、32は自局より送信する通信データ5が全て
送信されたことを示す送信完了信号が伝送される送信完
了線、33は上流の局より受信した受信データを伝送す
る受信データ線である。34は上流の局より受信した受
信データのパターンデータ8を1ビット分遅延させる受
信データ遅延部であり、35はこの受信データ遅延部3
4によって1ビット遅延したパターンデータ8の立ち下
がりに基づいて、自局より送信する通信データ5の送信
タイミングを検出するデータ送信タイミング検出部、3
6はこのデータ送信タイミング検出部35から出力され
る送信タイミングが伝送される送信タイミング線であ
る。
In the figure, reference numeral 31 denotes a synchronous clock line for transmitting a synchronous clock generated by a synchronous clock generator (not shown) based on pattern data 8 received from an upstream station, and 32 denotes a communication transmitted from its own station. A transmission completion line for transmitting a transmission completion signal indicating that all data 5 has been transmitted, and a reception data line 33 for transmitting reception data received from an upstream station. Reference numeral 34 denotes a reception data delay unit for delaying the pattern data 8 of the reception data received from the upstream station by one bit, and 35 denotes the reception data delay unit 3.
4, a data transmission timing detection unit for detecting the transmission timing of the communication data 5 transmitted from the own station based on the falling edge of the pattern data 8 delayed by one bit.
Reference numeral 6 denotes a transmission timing line through which the transmission timing output from the data transmission timing detection unit 35 is transmitted.

【0038】37は通信制御部7内の図示を省略した中
央演算処理装置(以下、CPUという)よりCPUバス
を介して送られてくる送信すべき通信データ5を蓄積
し、データ送信タイミング検出部35からの送信タイミ
ングに従ってそれを出力するシフトレジスタであり、3
8はこのシフトレジスタ37の出力した通信データ5が
伝送される送信データ線である。39はこのシフトレジ
スタ37からの通信データ5と、上流の局より受信して
下流局へ再生中継する受信データのいずれか一方を出力
データとして選択する送信セレクト部であり、40はこ
の送信セレクト部39で選択された出力データを下流の
局へ送出するために自局の送信部3に伝送する出力デー
タ線である。
Reference numeral 37 stores communication data 5 to be transmitted transmitted from a central processing unit (hereinafter, referred to as a CPU) in the communication control unit 7 via a CPU bus (not shown). A shift register which outputs the shift register according to the transmission timing from
Reference numeral 8 denotes a transmission data line through which the communication data 5 output from the shift register 37 is transmitted. Reference numeral 39 denotes a transmission selection unit for selecting either communication data 5 from the shift register 37 or reception data received from an upstream station and reproduced and relayed to a downstream station as output data, and 40 is a transmission selection unit. An output data line for transmitting the output data selected at 39 to the transmitting unit 3 of the own station in order to transmit the output data to the downstream station.

【0039】次に動作について説明する。ここで、実施
の形態2でも説明したように、各従局1b、1c、1
d、・・・・、1nは、送信しようとする通信データ5
を再生中継しているパターンデータ8とバイト単位で同
期させてから出力させる必要がある。そのため、この実
施の形態4のフレーム同期回路は、送信する通信データ
5を蓄積し、データ送信タイミング検出部35からの送
信タイミングに従って、その蓄積している通信データ5
を順次送出するシフトレジスタ37を使用することによ
って、以下のように動作する。
Next, the operation will be described. Here, as described in the second embodiment, each of the slave stations 1b, 1c, 1
.., 1n are communication data 5 to be transmitted.
Must be output in synchronization with the pattern data 8 that is being reproduced and relayed in byte units. Therefore, the frame synchronization circuit according to the fourth embodiment stores the communication data 5 to be transmitted, and stores the stored communication data 5 in accordance with the transmission timing from the data transmission timing detection unit 35.
Are operated in the following manner by using the shift register 37 that sequentially sends out.

【0040】すなわち、この実施の形態4のフレーム同
期回路では、CPUバスを介して送られてくる送信すべ
き通信データ5はシフトレジスタ37に入力されてそこ
に蓄積される。受信データ遅延部34は再生中継されて
いるパターンデータ8を1ビット分遅延させてデータ送
信タイミング検出部35に送り、データ送信タイミング
検出部35はそのパターンデータ8の立ち下がり、すな
わちパターンデータの切り替わる点で送信タイミングを
生成し、それをシフトレジスタ37に送る。シフトレジ
スタ37はこの送信タイミングを受けると、蓄積してい
る通信データ5を順次送信データ線38に送出する。こ
れによって、シフトレジスタ37からは再生中継される
パターンデータ8に同期して送信する通信データ5が出
力されるようになる。当該局より送信する全ての通信デ
ータ5が送信されると、送信完了線32よりデータ送信
タイミング検出部35に送信完了信号が与えられ、デー
タ送信タイミング検出部35は送信タイミングの出力を
停止する。
That is, in the frame synchronization circuit according to the fourth embodiment, the communication data 5 to be transmitted, which is transmitted via the CPU bus, is input to the shift register 37 and stored therein. The reception data delay unit 34 delays the reproduced and relayed pattern data 8 by one bit and sends the delayed data to the data transmission timing detection unit 35. The data transmission timing detection unit 35 switches the fall of the pattern data 8, that is, the switching of the pattern data. At this point, a transmission timing is generated and sent to the shift register 37. Upon receiving the transmission timing, the shift register 37 sequentially sends out the stored communication data 5 to the transmission data line 38. Thus, the shift register 37 outputs the communication data 5 to be transmitted in synchronization with the pattern data 8 to be reproduced and relayed. When all the communication data 5 transmitted from the station are transmitted, a transmission completion signal is given to the data transmission timing detection unit 35 from the transmission completion line 32, and the data transmission timing detection unit 35 stops outputting the transmission timing.

【0041】これにより、下流の局に対して再生中継さ
れるパターンデータ8とバイト単位で同期のとれた通信
データ5の送出が可能となり、通信異常を起すこともな
くなる。なお、自局の通信データの送信より上流の局か
らの受信データの再生中継への切り替えは、実施の形態
3の場合と同様に行われる。
This makes it possible to transmit the communication data 5 synchronized with the pattern data 8 to be reproduced and relayed to the downstream station on a byte-by-byte basis, thereby preventing a communication error from occurring. The switching to the reproduction relay of the received data from the station upstream from the transmission of the communication data of the own station is performed in the same manner as in the third embodiment.

【0042】実施の形態5. 図7はこの発明の実施の形態5によるデータ通信システ
ムにて、ループ型通信路2の線切断時に作動するデータ
出力回路を示すブロック構成図であり、このデータ出力
回路は図1に示す通信制御部7内に配置されている。な
お、以下の説明においては、特に区別の必要がない通信
データ5a、5b、5c、・・・・、5nについては単
に通信データ5と記す。
Embodiment 5 FIG. FIG. 7 is a block diagram showing a data output circuit that operates when the line of the loop communication path 2 is disconnected in the data communication system according to the fifth embodiment of the present invention. It is arranged in the section 7. In the following description, the communication data 5a, 5b, 5c,...

【0043】図において、41は上流の局より受信した
パターンデータ8に基づいて同期クロックを発生する同
期クロック発生部であり、42はこの同期クロックとは
独立の自局の基本クロックを発生する基本クロック発生
部である。43は自局と上流の局とを接続しているルー
プ型通信路2の回線断を検出する回線切断検出回路であ
り、44はこの回線切断検出回路43にて回線断が検出
された場合、自局の動作クロックのタイミングを同期ク
ロック発生部41の発生する再生中継用の同期クロック
のタイミングから、基本クロック発生部42の発生する
基本クロックのタイミングに切り替えて、受信データの
再生中継を停止させる通信制御回路である。45は正常
時に再生中継する受信データと自局より送信する通信デ
ータ5をバイト単位で同期させる、実施の形態2および
実施の形態3で示したものと同等のフレーム同期回路で
あり、46は回線切断検出回路43にて回線断が検出さ
れた場合に、出力するデータをこのフレーム同期回路4
5からのデータより通信制御回路44からのデータに切
り替える送信セレクト部である。
In the figure, reference numeral 41 denotes a synchronous clock generator for generating a synchronous clock based on the pattern data 8 received from the upstream station, and reference numeral 42 denotes a basic clock for generating a basic clock of the own station independent of the synchronous clock. It is a clock generator. Reference numeral 43 denotes a line disconnection detection circuit for detecting a line disconnection of the loop communication path 2 connecting the own station and the upstream station. Reference numeral 44 denotes a case where the line disconnection detection circuit 43 detects a line disconnection. The timing of the operation clock of the own station is switched from the timing of the synchronous clock for reproduction relay generated by the synchronous clock generator 41 to the timing of the basic clock generated by the basic clock generator 42 to stop the reproduction relay of the received data. It is a communication control circuit. Reference numeral 45 denotes a frame synchronization circuit equivalent to that shown in the second and third embodiments for synchronizing the received data to be reproduced and relayed in a normal state and the communication data 5 transmitted from the own station in byte units. When the disconnection detection circuit 43 detects a line disconnection, the output data is transmitted to the frame synchronization circuit 4.
5 is a transmission selection unit that switches from data from 5 to data from the communication control circuit 44.

【0044】次に動作について説明する。図1に示した
データ通信システムにおいて回線断が起こると、当該回
線断が発生したループ型通信路2よりも下流の局では、
通信データ5やパターンデータ8の受信ができなくな
る。そのため、このパターンデータ8に基づいて同期ク
ロックを発生している同期クロック発生部41では、受
信データに同期した同期クロックが作れなくなって、回
線断が発生したループ型通信路2より下流の局でデータ
を送受信することができなくなる。そのため、この実施
の形態5のデータ出力回路は、回線断が発生したループ
型通信路2よりも下流の局でもデータの送受信を行える
ようにするため、以下の動作を行う。
Next, the operation will be described. When a line disconnection occurs in the data communication system shown in FIG. 1, a station located downstream of the loop communication path 2 in which the line disconnection has occurred,
Communication data 5 and pattern data 8 cannot be received. Therefore, the synchronous clock generator 41, which generates a synchronous clock based on the pattern data 8, cannot generate a synchronous clock synchronized with the received data, so that the synchronous clock generator 41 generates a synchronous clock at a station downstream of the loop communication path 2 where the line disconnection has occurred. You will not be able to send or receive data. Therefore, the data output circuit according to the fifth embodiment performs the following operation in order to enable data transmission / reception even at a station downstream of the loop communication path 2 in which the line disconnection has occurred.

【0045】すなわち、この実施の形態5によるデータ
出力回路においては、最上流の主局1a以外の各従局1
b、1c、1d、・・・・、1nでは、それらを接続し
ているループ型通信路2の回線断を回線切断検出回路4
3で監視している。今、従局1bと従局1cを接続して
いるループ型通信路2に回線断が発生したものとする。
従局1cの回線切断検出回路43は従局1bとの間のル
ープ型通信路2の回線断を検出すると、その旨を自局の
通信制御回路44と送信セレクト部46に通知する。回
線断の検出通知を受けた通信制御回路44は自局で使用
する動作クロックのタイミングを、この回線断によって
同期を維持することができなくなった同期クロック発生
部41からの同期クロックから、基本クロック発生部4
2からの自局発振の基本クロックに切り替える。そして
従局1bからの受信データの再生中継を停止して、自局
より送信する通信データ5をその基本クロックに同期し
て送出するとともに、通信データ5の送信を行わない期
間は常にパターンデータ8の出力を行う。また、送信セ
レクト部46は回線切断検出回路43より回線断の検出
通知を受けると、フレーム同期回路45からの再生中継
するパターンデータ8に同期したタイミングによる出力
データを、通信制御回路44からの基本クロックに同期
した自局のタイミングによる出力データに切り替える。
That is, in the data output circuit according to the fifth embodiment, each of the slave stations 1 other than the most upstream master station 1a.
b, 1c, 1d,..., 1n, the line disconnection detection circuit 4 detects the line disconnection of the loop communication path 2 connecting them.
Monitor at 3. Now, it is assumed that a line break has occurred in the loop communication path 2 connecting the slave station 1b and the slave station 1c.
When detecting the line disconnection of the loop communication path 2 with the slave station 1b, the line disconnection detection circuit 43 of the slave station 1c notifies the communication control circuit 44 and the transmission selection unit 46 of the own station thereof. The communication control circuit 44, which has received the notification of the detection of the line disconnection, changes the timing of the operation clock used in its own station from the synchronous clock from the synchronous clock generator 41 which cannot maintain the synchronization due to the line disconnection, to the basic clock. Generator 4
2. Switch to the base clock for local oscillation from 2. Then, reproduction and relay of the received data from the slave station 1b is stopped, the communication data 5 transmitted from the own station is transmitted in synchronization with the basic clock, and the pattern data 8 is always transmitted while the communication data 5 is not transmitted. Perform output. When the transmission selection unit 46 receives the line disconnection detection notification from the line disconnection detection circuit 43, the transmission select unit 46 outputs the output data at the timing synchronized with the pattern data 8 to be reproduced and relayed from the frame synchronization circuit 45, from the communication control circuit 44. Switching to output data at the timing of the own station synchronized with the clock.

【0046】これによって、回線断の発生したループ型
通信路2よりも下流の従局1c、1d、・・・・、1n
は、通常時と同じように同期クロックを維持することが
可能となる。従って、回線断を検出した従局1cにおい
て、その回線切断場所などを通知する通信データ5を作
成して送出すれば、その通信データ5を最上流の主局1
aまで伝送することが可能となる。
Thus, the slave stations 1c, 1d,..., 1n downstream of the loop communication path 2 in which the line disconnection has occurred.
Can maintain the synchronous clock as in the normal case. Therefore, if the slave station 1c that detects the line disconnection creates and sends out the communication data 5 for notifying the location of the line disconnection, the communication data 5 is transferred to the most upstream master station 1c.
a can be transmitted.

【0047】実施の形態6. 図8はこの発明の実施の形態6によるデータ通信システ
ムにて、連続して不良データが受信された際に作動する
データ出力回路を示すブロック構成図であり、このデー
タ出力回路も図1に示す通信制御部7内に配置されてい
る。なお、この場合も特に区別する必要がない通信デー
タ5a、5b、5c、・・・・、5nについては単に通
信データ5と記す。
Embodiment 6 FIG. FIG. 8 is a block diagram showing a data output circuit which operates when bad data is continuously received in the data communication system according to the sixth embodiment of the present invention. This data output circuit is also shown in FIG. It is arranged in the communication control unit 7. In this case, the communication data 5a, 5b, 5c,...

【0048】図において、41は同期クロック発生部、
42は基本クロック発生部、44は通信制御回路、45
はフレーム同期回路、46は送信セレクト部であり、こ
れらは図7に示した実施の形態5におけるそれらと同等
のものである。また、47は上流の局から自局の受信部
4に送られてきたデータを受信するデータ受信回路であ
り、48はこのデータ受信回路47にて受信されるデー
タを監視し、受信データ不良が一定時間以上継続して検
出された場合に、その旨を通信制御回路44と送信セレ
クト部46とに通知する受信データ不良検出回路であ
る。
In the figure, 41 is a synchronous clock generator,
42 is a basic clock generator, 44 is a communication control circuit, 45
Denotes a frame synchronization circuit, and 46 denotes a transmission selection unit, which are the same as those in the fifth embodiment shown in FIG. Reference numeral 47 denotes a data receiving circuit for receiving data sent from the upstream station to the receiving unit 4 of the own station, and 48 monitors the data received by the data receiving circuit 47, and detects a reception data failure. This is a reception data failure detection circuit that notifies the communication control circuit 44 and the transmission selection unit 46 of the detection when the detection is continuously performed for a predetermined time or more.

【0049】次に動作について説明する。ここで、図1
に示したデータ通信システムにおいて何らかの理由によ
り受信不良が発生し、通信データ5やパターンデータ8
が正常に受信できなくなると、それよりも下流の局でも
パターンデータ8を受信することができなくなる。上流
の局からのパターンデータ8が受信できなくなると、各
局では同期クロックを維持できなくなるため、データを
送受信することができなくなる。そのため、この実施の
形態6のデータ出力回路は、受信データ不良が発生した
局よりも下流の局でもデータの送受信を行えるようにす
るため、以下の動作を行う。
Next, the operation will be described. Here, FIG.
In the data communication system shown in FIG.
If can not be received normally, Kunar such can receive pattern data 8 in downstream stations than that. If the pattern data 8 cannot be received from the upstream station, each station cannot maintain the synchronous clock, so that data cannot be transmitted / received. Therefore, the data output circuit according to the sixth embodiment performs the following operation so that data can be transmitted and received at a station downstream of the station where the received data failure has occurred.

【0050】すなわち、この実施の形態6によるデータ
出力回路においては、受信データ不良検出回路48にて
データ受信回路47によるデータの受信状況を常に監視
しており、受信データ不良検出回路48はデータの受信
不良が一定時間以上続いたことを検出すると、回線異常
としてその旨を通信制御回路44と送信セレクト部46
に通知する。今、従局1cにおいて一定時間以上継続す
る受信データ不良が発生したものとする。従局1cの通
信制御回路44は受信データ不良検出回路48より受信
データ不良の通知を受けると、自局で使用する動作クロ
ックのタイミングを、この受信データ不良によって同期
を維持することができなくなった同期クロック発生部4
1からの同期クロックから、基本クロック発生部42か
らの自局発振の基本クロックに切り替える。そして従局
1bからの受信データの再生中継を停止して、自局より
送信する通信データ5をその基本クロックに同期して送
出するとともに、通信データ5の送信を行わない期間は
常にパターンデータ8の出力を行う。また、送信セレク
ト部46は回線切断検出回路43よりデータ受信不良の
通知を受けると、フレーム同期回路45からの再生中継
するパターンデータ8に同期したタイミングによる出力
データを、通信制御回路44からの基本クロックに同期
した自局のタイミングによる出力データに切り替える。
That is, in the data output circuit according to the sixth embodiment, the received data failure detection circuit 48 constantly monitors the data reception status of the data reception circuit 47, and the reception data failure detection circuit 48 When it is detected that the reception failure has continued for a certain period of time or more, the communication control circuit 44 and the transmission selection section 46 indicate that the line is abnormal.
Notify. Now, it is assumed that a reception data failure that has continued for a predetermined time or more has occurred in the slave station 1c. When receiving the notification of the reception data failure from the reception data failure detection circuit 48, the communication control circuit 44 of the slave station 1c sets the timing of the operation clock used in the own station to the synchronization that cannot maintain the synchronization due to the reception data failure. Clock generator 4
1 is switched to the base clock generated by the base clock generator 42 and oscillated from the local clock. Then, reproduction and relay of the received data from the slave station 1b is stopped, the communication data 5 transmitted from the own station is transmitted in synchronization with the basic clock, and the pattern data 8 is always transmitted while the communication data 5 is not transmitted. Perform output. Further, upon receiving the notification of the data reception failure from the line disconnection detection circuit 43, the transmission selection unit 46 outputs the output data at the timing synchronized with the pattern data 8 to be reproduced and relayed from the frame synchronization circuit 45 to the basic data from the communication control circuit 44. Switching to output data at the timing of the own station synchronized with the clock.

【0051】これにより、受信データ不良が発生した従
局1cよりも下流の従局1d、・・・・、1nは、通常
時と同様に同期クロックを維持することが可能となる。
従って、データ受信不良が発生した従局1cにおいて、
データの受信不良が発生した場所などを通知する通信デ
ータ5を作成して送出すれば、その通信データ5を最上
流の主局1aまで伝送することが可能となる。
Thus, the slave stations 1d,..., 1n downstream of the slave station 1c in which the reception data failure has occurred can maintain the synchronous clock as in the normal state.
Therefore, in the slave station 1c where the data reception failure has occurred,
If the communication data 5 for notifying the place where the data reception failure has occurred is created and transmitted, the communication data 5 can be transmitted to the most upstream main station 1a.

【0052】実施の形態7. なお、上記各実施の形態においては、最上流の主局1a
が通信データ5aの送信不要時において、常にHDLC
方式の通信フォーマットの先頭および末尾に配されたフ
ラグと同一パターンのパターンデータ8を送出し続ける
ものについて説明したが、通信データ送信不要時には、
HDLC方式において通信データ5aが送信されていな
いときに常時出力されている“1”の固定データを、ノ
ン・リターン・ツー・ゼロ・インバーテット(以下、N
RZIという)方式で符号化し、“1”と“0”とが交
番するデータに変換して連続的に送出するようにしても
よい。
Embodiment 7 FIG. In each of the above embodiments, the most upstream main station 1a
Is always in HDLC when transmission of communication data 5a is unnecessary.
The description has been given of the case where the pattern data 8 having the same pattern as the flag arranged at the beginning and end of the communication format of the system is continuously transmitted.
In the HDLC system, fixed data of "1" which is always output when the communication data 5a is not transmitted is converted to a non-return-to-zero inverted (hereinafter referred to as N
RZI), may be converted into data in which "1" and "0" alternate, and may be transmitted continuously.

【0053】図9はそのようなこの発明の実施の形態7
によるデータ通信システムで用いられるNRZI符号化
回路を示すブロック構成図であり、図10はそのNRZ
I符号化回路で符号化されたデータを通常のノン・リタ
ーン・ツー・ゼロ(以下、NRZという)方式による符
号に復号するNRZ復号回路を示すブロック構成図であ
る。図において、51はJ−Kフリップフロップであ
り、52〜54はDフリップフロップ、55は排他的論
理和回路、56はインバータである。
FIG. 9 shows such a seventh embodiment of the present invention.
FIG. 10 is a block diagram showing an NRZI encoding circuit used in a data communication system according to FIG.
FIG. 2 is a block diagram illustrating an NRZ decoding circuit that decodes data encoded by an I encoding circuit into a code based on a normal non-return-to-zero (hereinafter, referred to as NRZ) method. In the figure, 51 is a JK flip-flop, 52 to 54 are D flip-flops, 55 is an exclusive OR circuit, and 56 is an inverter.

【0054】次に動作について説明する。図1に示した
各局1a、1b、1c、・・・・、1nの内部では、信
号“1”でハイレベル(以下、Hという)、信号“0”
でローレベル(以下、Lという)となるNRZ符号にて
データが扱われている。最上位に位置する主局1aは通
信データ5aを下位の局へ送信する場合には、図9に示
したNRZI符号化回路を用いて、信号“1”で状態を
HからL、あるいはLからHに反転させ、信号“0”で
は状態をそのまま反転させないNRZI符号に変換して
送信する。すなわち、図9に示すJ−Kフリップフロッ
プ51の端子JおよびKにNRZ符号を入力すれば、N
RZ符号が“1”(H)であればクロックが到来する都
度、J−Kフリップフロップ51はその状態を反転さ
せ、NRZ符号が“0”(L)であればクロックが到来
しても、J−Kフリップフロップ51はそれまでの状態
を保持する。従って、J−Kフリップフロップ51の端
子Qからは入力されたNRZ符号がNRZI符号に変換
されて出力される。
Next, the operation will be described. In each of the stations 1a, 1b, 1c,..., 1n shown in FIG. 1, a signal "1" is at a high level (hereinafter, referred to as H) and a signal "0".
The data is handled by the NRZ code which becomes a low level (hereinafter, referred to as L). When transmitting the communication data 5a to a lower station, the master station 1a located at the highest level uses the NRZI encoding circuit shown in FIG. 9 to change the state from H to L or from L to L with a signal "1". The signal is inverted to H, and the signal “0” is converted into an NRZI code whose state is not inverted as it is and transmitted. That is, if an NRZ code is input to the terminals J and K of the JK flip-flop 51 shown in FIG.
If the RZ code is “1” (H), every time a clock arrives, the JK flip-flop 51 inverts its state, and if the NRZ code is “0” (L), even if the clock arrives, The JK flip-flop 51 holds the previous state. Therefore, the NRZ code input from the terminal Q of the JK flip-flop 51 is converted into an NRZI code and output.

【0055】ここで、図1に示したデータ通信システム
では、前述のようにHDLC方式による通信フォーマッ
トを使用してデータの通信が行われているため、最上位
の主局1aは通信データ5aを送信していないときには
その出力データは常時“1”となる。この通信データ5
aの非送信時に出力される“1”固定データも、図9に
示したNRZI符号化回路を介してループ型通信路2に
送出されているため、通信データ5が送信されていない
期間では、H→L→H→L→・・・・という具合に
“1”(H)と“0”(L)が交番するデータが連続し
て送出されることになる。
Here, in the data communication system shown in FIG. 1, since data communication is performed using the communication format of the HDLC system as described above, the highest-order master station 1a transmits the communication data 5a. When not transmitting, the output data is always "1". This communication data 5
The “1” fixed data output during non-transmission of “a” is also transmitted to the loop communication channel 2 via the NRZI encoding circuit shown in FIG. H → L → H → L →..., So that data in which “1” (H) and “0” (L) alternate are continuously transmitted.

【0056】このようなNRZI符号のデータを受信し
た下流の従局1bでは、この通信データ5が送信されて
いない“1”と“0”が交番する部分で、同期クロック
の補正、維持を行う。その後、従局1bは主局1aから
送られてきた通信データ5aを、図10に示したNRZ
復号回路を用いてNRZ符号に変換した後、内部に取り
込む。すなわち、NRZI符号による通信データ5aが
入力されると、NRZ復号回路はクロックに従ってその
第1ビットをDフリップフロップ52に保持させ、次の
クロックでそれをDフリップフロップ53に移して排他
的論理和回路55でそれらを比較し、その比較結果をD
フリップフロップ54に格納して、インバータ56で反
転したクロックを用いてその読み出しを行う。これによ
り、Dフリップフロップ54の端子Qからは、入力され
たNRZI符号がNRZ符号に復号されて出力される。
The downstream slave station 1b, which has received such NRZI code data, corrects and maintains the synchronous clock at a portion where "1" and "0" where the communication data 5 is not transmitted alternate. Thereafter, the slave station 1b transmits the communication data 5a sent from the master station 1a to the NRZ shown in FIG.
After converting to an NRZ code using a decoding circuit, it is taken in. That is, when the communication data 5a based on the NRZI code is input, the NRZ decoding circuit causes the D flip-flop 52 to hold the first bit in accordance with the clock, shifts it to the D flip-flop 53 at the next clock, and performs exclusive-OR They are compared in a circuit 55, and the comparison result is
The data stored in the flip-flop 54 is read out using the clock inverted by the inverter 56. Thus, the input NRZI code is decoded into an NRZ code from the terminal Q of the D flip-flop 54 and output.

【0057】これにより、最上流の主局1aにおいて、
通信データ5aの非送信時にパターンデータ8を送出し
続ける必要がなくなり、また所定パターンのパターンデ
ータ8が送出されていないので、下流の各従局1b、1
c、1d、・・・・、1nではビット同期さえ合ってい
れば特にバイト単位の同期をとる必要がなく、いつでも
自局の通信データ5b、5c、5d、・・・・、5nを
送信することが可能となる。なお、そのとき通信データ
5a、5b、5c、・・・・、5nに“0”が出力され
続けると、その間の出力データにレベルの変化がなくな
るため、クロックの同期修正が行えなくなるため、クロ
ック精度に応じて一度に連続して送信できるデータの数
を制限する必要がでてくる。
Thus, in the most upstream main station 1a,
When the communication data 5a is not transmitted, there is no need to continuously transmit the pattern data 8, and since the pattern data 8 of the predetermined pattern is not transmitted, each downstream slave station 1b, 1
.., 1n, it is not necessary to synchronize in byte units as long as the bit synchronization is achieved, and the communication data 5b, 5c, 5d,. It becomes possible. If "0" is continuously output to the communication data 5a, 5b, 5c,..., 5n at that time, the level of the output data during that time does not change, so that the clock synchronization cannot be corrected. It is necessary to limit the number of data that can be transmitted at one time according to the accuracy.

【0058】[0058]

【発明の効果】請求項1記載の発明によれば、主局より
通信データ送信不要時にフラグと同一パターンによるパ
ターンデータを常時送出し続け、他の従局はそのパター
ンデータに基づいて同期クロックを補正、維持させるよ
うに構成したので、通信データを送信する際に、当該通
信データの前にわざわざ必要数の同期用フラグを付加す
る必要がなくなって、通信データを即送信することが可
能となるため、通信にかかる時間を短縮できるデータ通
信システムが得られる効果がある。
According to the first aspect of the present invention, when communication data transmission is not required from the master station, pattern data having the same pattern as the flag is continuously transmitted, and the other slave stations correct the synchronous clock based on the pattern data. Since the communication data is transmitted, there is no need to add the necessary number of synchronization flags before the communication data, and the communication data can be transmitted immediately. Thus, there is an effect that a data communication system capable of shortening the time required for communication can be obtained.

【0059】請求項2記載の発明によれば、自局の送信
する通信データと再生中継するパターンデータの遅延ビ
ット数に従って、送信する通信データを再生中継するパ
ターンデータに同期させ、バイト単位の区切りにおいて
再生中継と通信データの送信との切り替えを行うように
構成したので、下流の局に対して通信データを、バイト
単位のずれがなく出力することが可能となり、通信異常
の発生を防止できるデータ通信システムが得られる効果
がある。
According to the second aspect of the present invention, the communication data to be transmitted is synchronized with the pattern data to be reproduced and relayed in accordance with the number of delay bits between the communication data transmitted from the own station and the pattern data to be reproduced and relayed, and the delimiter in byte units is provided. Is configured to switch between regenerative relay and transmission of communication data, so that communication data can be output to downstream stations without a byte-by-byte shift, and data that can prevent the occurrence of communication errors There is an effect that a communication system can be obtained.

【0060】請求項3記載の発明によれば、再生中継す
るパターンデータと自局の送信する通信データの遅延ビ
ット数に従って、再生中継するパターンデータを送信す
る通信データに同期させ、バイト単位の区切りにおいて
再生中継と通信データの送信との切り替えを行うように
構成したので、下流の局に対してパターンデータを、バ
イト単位のずれがなく再生中継することが可能となり、
通信異常の発生を防止できるデータ通信システムが得ら
れる効果がある。
According to the third aspect of the present invention, the pattern data to be reproduced and relayed is synchronized with the communication data to be transmitted in accordance with the number of delay bits of the pattern data to be reproduced and relayed and the communication data transmitted by the own station, and the data is divided in byte units. Since it is configured to perform switching between reproduction relay and transmission of communication data in, pattern data can be reproduced and relayed to a downstream station without deviation in byte units,
There is an effect that a data communication system capable of preventing occurrence of communication abnormality can be obtained.

【0061】請求項4記載の発明によれば、上流の局よ
り受信したパターンデータのバイト単位の区切りを検出
して、シフトレジスタに蓄積した通信データの送信タイ
ミングを与えるように構成したので、再生中継するパタ
ーンデータと送信する通信データとをバイト単位で同期
させることができ、通信異常の発生を防止できるデータ
通信システムが得られる効果がある。
According to the fourth aspect of the present invention, since a break in byte units of the pattern data received from the upstream station is detected and the transmission timing of the communication data stored in the shift register is given, the reproduction is performed. The pattern data to be relayed and the communication data to be transmitted can be synchronized on a byte-by-byte basis, and there is an effect that a data communication system capable of preventing occurrence of communication abnormality can be obtained.

【0062】請求項5記載の発明によれば、回線断を検
出した従局が、再生中継するパターンデータに基づく同
期クロックから自局発振の基本クロックに動作クロック
のタイミングを切り替えるとともに、受信データの再生
中継を停止するように構成したので、当該局より下流の
局は通常時と同じように同期クロックを維持することが
可能となって、回線切断場所などを知らせる通信データ
を最上流の主局に通知できるデータ通信システムが得ら
れる効果がある。
According to the fifth aspect of the present invention, the slave detecting the line disconnection switches the timing of the operation clock from the synchronous clock based on the pattern data to be reproduced and relayed to the base clock of the local oscillation and reproduces the received data. Since the relay is configured to be stopped, stations downstream from the station can maintain the synchronous clock in the same way as normal, and communication data that informs the line disconnection location etc. is sent to the most upstream main station. There is an effect that a data communication system capable of notification can be obtained.

【0063】請求項6記載の発明によれば、一定時間以
上受信データ不良が続いたことを検出した従局が、再生
中継するパターンデータに基づく同期クロックから自局
発振の基本クロックに動作クロックのタイミングを切り
替えるとともに、受信データの再生中継を停止するよう
に構成したので、当該局より下流の局は通常時と同じよ
うに同期クロックを維持することが可能となって、受信
データ不良の発生場所などを知らせる通信データを最上
流の主局に通知できるデータ通信システムが得られる効
果がある。
According to the sixth aspect of the present invention, the slave station detecting that the reception data failure has continued for a certain period of time or more detects the timing of the operation clock from the synchronization clock based on the pattern data to be reproduced and relayed to the base clock of its own oscillation. And the relay of received data is stopped, so that stations downstream from the station can maintain the synchronous clock in the same manner as in the normal case, such as the location where a received data defect occurs. There is an effect that a data communication system capable of notifying the most upstream master station of the communication data for notifying the user is obtained.

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

【図1】 この発明の実施の形態1によるデータ通信シ
ステムを示すブロック構成図である。
FIG. 1 is a block diagram showing a data communication system according to a first embodiment of the present invention.

【図2】 この発明の実施の形態2によるデータ通信シ
ステムで用いられるフレーム同期回路を示すブロック構
成図である。
FIG. 2 is a block diagram showing a frame synchronization circuit used in a data communication system according to a second embodiment of the present invention.

【図3】 上記実施の形態における各部の信号の時間関
係を示すタイミングチャートである。
FIG. 3 is a timing chart showing a time relationship between signals of respective units in the embodiment.

【図4】 この発明の実施の形態3によるデータ通信シ
ステムで用いられるフレーム同期回路を示すブロック構
成図である。
FIG. 4 is a block diagram showing a frame synchronization circuit used in a data communication system according to a third embodiment of the present invention.

【図5】 上記実施の形態における各部の信号の時間関
係を示すタイミングチャートである。
FIG. 5 is a timing chart showing a time relationship between signals of respective units in the embodiment.

【図6】 この発明の実施の形態4によるデータ通信シ
ステムで用いられるフレーム同期回路を示すブロック構
成図である。
FIG. 6 is a block diagram showing a frame synchronization circuit used in a data communication system according to a fourth embodiment of the present invention.

【図7】 この発明の実施の形態5によるデータ通信シ
ステムで用いられるデータ出力回路を示すブロック構成
図である。
FIG. 7 is a block diagram showing a data output circuit used in a data communication system according to a fifth embodiment of the present invention.

【図8】 この発明の実施の形態6によるデータ通信シ
ステムで用いられるデータ出力回路を示すブロック構成
図である。
FIG. 8 is a block diagram showing a data output circuit used in a data communication system according to a sixth embodiment of the present invention.

【図9】 この発明の実施の形態7によるデータ通信シ
ステムで用いられるNRZI符号化回路を示すブロック
構成図である。
FIG. 9 is a block diagram showing an NRZI encoding circuit used in a data communication system according to Embodiment 7 of the present invention.

【図10】 上記実施の形態によるデータ通信システム
で用いられるNRZ復号回路を示すブロック構成図であ
る。
FIG. 10 is a block diagram showing an NRZ decoding circuit used in the data communication system according to the embodiment.

【図11】 従来のデータ通信システムを示すブロック
構成図である。
FIG. 11 is a block diagram showing a conventional data communication system.

【符号の説明】[Explanation of symbols]

1a 局(主局)、1b、1c、1d、・・・・、1n
局(従局)、2 ループ型通信路、5、5a、5b、
・・・・、5n 通信データ、8 パターンデータ、1
6、26 クロック数カウント部(遅延検出部)、18
送信データ遅延部、19、29、39 送信セレクト
部、28 受信データ遅延部、35 データ送信タイミ
ング検出部、37 シフトレジスタ、43 回線切断検
出回路、44 通信制御回路、48 受信データ不良検
出回路。
1a station (main station), 1b, 1c, 1d,..., 1n
Station (slave station), 2 loop type communication path, 5, 5a, 5b,
.... 5n communication data, 8 pattern data, 1
6, 26 clock number counting section (delay detection section), 18
Transmission data delay section, 19, 29, 39 transmission selection section, 28 reception data delay section, 35 data transmission timing detection section, 37 shift register, 43 line disconnection detection circuit, 44 communication control circuit, 48 reception data failure detection circuit.

フロントページの続き (56)参考文献 特公 平4−54417(JP,B2) 「インターフェース 第17巻 第2 号」、CQ出版社、1992年2月、p. 154−155Continuation of the front page (56) References Japanese Patent Publication No. 4-54417 (JP, B2) "Interface Vol. 17, No. 2," CQ Publishing Company, February 1992, pp. 154-155

Claims (6)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 複数の局をループ型通信路にてループ状
に接続し、ハイレベル・データリング制御手順による通
信方式の通信フォーマットを使用して通信を行うデータ
通信システムにおいて、前記複数の局のうちの1つを、
再生中継を行わずに自局のタイミングで通信データを送
出するとともに、通信データ送信不要時においては、前
記ハイレベル・データリング制御手順における通信デー
タの先頭と末尾にあるフラグと同一パターンのパターン
データを常に送出し続ける主局とし、その他の前記局
を、前記主局より送出されるパターンデータに基づいて
同期クロックの補正、維持を行い、上流の局から受信し
たデータを再生中継して下流の局に伝送するとともに、
自局より通信データを送信する場合には、上流の局から
下流の局へ再生中継するデータを自局の通信データに切
り替えて送信する従局としたことを特徴とするデータ通
信システム。
1. A data communication system in which a plurality of stations are connected in a loop by a loop-type communication path and perform communication using a communication format of a communication method according to a high-level data ring control procedure. One of
The communication data is transmitted at the own station timing without performing the reproduction relay, and when the communication data transmission is unnecessary, the pattern data having the same pattern as the flags at the head and end of the communication data in the high-level data ring control procedure is used. As a main station that constantly transmits, and corrects and maintains the other stations based on the pattern data transmitted from the main station, and reproduces and relays the data received from the upstream station to the downstream station. While transmitting to the station,
A data communication system, wherein when transmitting communication data from the own station, the slave station switches data to be reproduced and relayed from an upstream station to a downstream station by switching to communication data of the own station and transmits the data.
【請求項2】 従局が、自局の送信する通信データの先
頭のフラグの立ち下がりから、上流の局より受信したパ
ターンデータの立ち下がりまでのビット遅延量を検出す
る遅延検出部と、前記遅延検出部の出力する遅延ビット
数に応じて、前記送信する通信データを前記上流の局よ
り受信して下流の局へ再生中継するパターンデータに同
期させる送信データ遅延部と、前記通信データの送信時
には、上流の局から下流の局へ再生中継するデータより
前記送信データ遅延部の出力データへの切り替えを、前
記通信データの送信終了時には、前記送信データ遅延部
の出力データより上流の局から下流の局へ再生中継する
データへの切り替えを、それぞれバイト単位の区切りに
おいて行う送信セレクト部とを備えたことを特徴とする
請求項1記載のデータ通信システム。
2. A delay detecting section for detecting a bit delay amount from a fall of a head flag of communication data transmitted by the slave station to a fall of pattern data received from an upstream station, and A transmission data delay unit that receives the communication data to be transmitted from the upstream station and synchronizes with the pattern data to be reproduced and relayed to the downstream station according to the number of delay bits output by the detection unit. Switching from the data reproduced and relayed from the upstream station to the downstream station to the output data of the transmission data delay unit, at the end of the transmission of the communication data, from the upstream station to the downstream of the output data of the transmission data delay unit. 2. The data selector according to claim 1, further comprising: a transmission selection unit for switching to data to be reproduced and relayed to a station at each byte unit. Communication system.
【請求項3】 従局が、上流の局より受信したパターン
データの立ち下がりから、自局の送信する通信データの
末尾のフラグの立ち下がりまでのビット遅延量を検出す
る遅延検出部と、前記遅延検出部の出力する遅延ビット
数に応じて、前記上流の局より受信して下流の局へ再生
中継するパターンデータを前記送信する通信データに同
期させる受信データ遅延部と、前記通信データの送信時
には、前記受信データ遅延部の出力データから前記送信
する通信データへの切り替えを、前記通信データの送信
終了時には、前記送信する通信データから前記送信デー
タ遅延部の出力データへの切り替えを、それぞれバイト
単位の区切りにおいて行う送信セレクト部とを備えたこ
とを特徴とする請求項1記載のデータ通信システム。
3. A delay detecting section for detecting a bit delay amount from a fall of pattern data received from an upstream station to a fall of a tail flag of communication data transmitted from the slave station, and According to the number of delay bits output by the detection unit, a reception data delay unit that synchronizes the pattern data received from the upstream station and reproduced and relayed to the downstream station with the communication data to be transmitted, and when transmitting the communication data, The switching from the output data of the reception data delay unit to the communication data to be transmitted and the switching of the communication data to be transmitted to the output data of the transmission data delay unit at the end of the transmission of the communication data are performed in byte units. 2. The data communication system according to claim 1, further comprising: a transmission selection unit that performs the operation at a break of the data.
【請求項4】 従局が、自局の送信する通信データを蓄
積するシフトレジスタと、上流の局より受信したパター
ンデータのバイト単位の区切りを検出し、前記シフトレ
ジスタに蓄積している通信データの送信タイミングを与
えるデータ送信タイミング検出部と、前記シフトレジス
タからの通信データと上流の局より受信して下流の局へ
再生中継する受信データの一方を選択し、出力データと
して送出する送信セレクト部とを備えたことを特徴とす
る請求項1記載のデータ通信システム。
4. A slave station detects a shift register for storing communication data transmitted by its own station, and a byte-based delimiter of pattern data received from an upstream station, and detects a shift of communication data stored in the shift register. A data transmission timing detection unit that gives a transmission timing, and a transmission selection unit that selects one of communication data from the shift register and reception data received from an upstream station and reproduced and relayed to a downstream station, and transmitted as output data. The data communication system according to claim 1, further comprising:
【請求項5】 従局が、上流の局との間の回線断を検出
する回線切断検出回路と、前記回線切断検出回路にて回
線断が検出されると、動作クロックのタイミングを、上
流の局から受信したパターンデータに基づく同期クロッ
クのタイミングから自局で発生する基本クロックのタイ
ミングに切り替え、前記上流の局からの受信データの下
流の局への再生中継を停止させる通信制御回路とを備え
たことを特徴とする請求項1記載のデータ通信システ
ム。
5. A slave station detects a line disconnection between the upstream station and a line disconnection detection circuit. When the line disconnection detection circuit detects a line disconnection, the slave station changes the operation clock timing to the upstream station. And a communication control circuit for switching from the timing of the synchronous clock based on the pattern data received from the timing of the base clock generated in the own station to the stop of the reproduction relay of the received data from the upstream station to the downstream station. The data communication system according to claim 1, wherein:
【請求項6】 従局が、自局において受信データ不良が
一定時間以上続いたことを検出する受信データ不良検出
回路と、前記受信データ不良検出回路にて一定時間以上
続いて受信データ不良が検出されると、動作クロックの
タイミングを、上流の局から受信したパターンデータに
基づく同期クロックのタイミングから自局で発生する基
本クロックのタイミングに切り替え、前記上流の局から
の受信データの下流の局への再生中継を停止させる通信
制御回路とを備えたことを特徴とする請求項1記載のデ
ータ通信システム。
6. A reception data failure detection circuit for detecting that a reception data failure has continued for a predetermined time or more in a slave station, and a reception data failure has been detected for a predetermined time or more in the reception data failure detection circuit. Then, the timing of the operation clock is switched from the timing of the synchronous clock based on the pattern data received from the upstream station to the timing of the basic clock generated in the own station, and the timing of the reception data from the upstream station is transferred to the downstream station. 2. The data communication system according to claim 1, further comprising a communication control circuit for stopping the reproduction relay.
JP26578395A 1995-10-13 1995-10-13 Data communication system Expired - Lifetime JP3187303B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP26578395A JP3187303B2 (en) 1995-10-13 1995-10-13 Data communication system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP26578395A JP3187303B2 (en) 1995-10-13 1995-10-13 Data communication system

Publications (2)

Publication Number Publication Date
JPH09107372A JPH09107372A (en) 1997-04-22
JP3187303B2 true JP3187303B2 (en) 2001-07-11

Family

ID=17421985

Family Applications (1)

Application Number Title Priority Date Filing Date
JP26578395A Expired - Lifetime JP3187303B2 (en) 1995-10-13 1995-10-13 Data communication system

Country Status (1)

Country Link
JP (1) JP3187303B2 (en)

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
「インターフェース 第17巻 第2号」、CQ出版社、1992年2月、p.154−155

Also Published As

Publication number Publication date
JPH09107372A (en) 1997-04-22

Similar Documents

Publication Publication Date Title
US4078228A (en) Loop data highway communication system
JP3187303B2 (en) Data communication system
EP0393952B1 (en) Apparatus and method for proper decoding in an encoder/decoder
JP4671867B2 (en) Railway signal system transmission circuit
JP4108675B2 (en) Data transfer apparatus and failure recovery method used for the data transfer apparatus
JPH0797761B2 (en) Optical transmission system
JPH11127221A (en) Alarm transfer circuit
JPH0320181B2 (en)
JP3039135B2 (en) Data relay device
JP2656345B2 (en) Digital signal transmission equipment
JP3267581B2 (en) Frame synchronization method and apparatus
JPH09331358A (en) Data communication system
KR100670041B1 (en) Fast Ethernet Receive Data Error Correction Circuit
JPH03112240A (en) Line fault detecting method
JPS6350221A (en) Radio communication system
JP2001086106A (en) Data transmitter and transmission system
JPH10154972A (en) Uninterruptible switching system
Schneider et al. A N+ 2 protection switching system for synchronous STM-1 signals and plesiochronous 140 Mbit/s signals by using two carrier technique
JPS63131743A (en) Reception timing switching control system
JPH01260958A (en) Optical repeater
JPH0389735A (en) Restorer
JPH08237273A (en) Fault monitor device for atm line
JPH0661989A (en) Synchronizing signal switching system
JPH0771143B2 (en) Failure notification method in digital exchange
JPH08331087A (en) Stuff synchronization circuit

Legal Events

Date Code Title Description
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080511

Year of fee payment: 7

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

Free format text: PAYMENT UNTIL: 20090511

Year of fee payment: 8

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

Free format text: PAYMENT UNTIL: 20100511

Year of fee payment: 9

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

Free format text: PAYMENT UNTIL: 20100511

Year of fee payment: 9

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

Free format text: PAYMENT UNTIL: 20110511

Year of fee payment: 10

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

Free format text: PAYMENT UNTIL: 20110511

Year of fee payment: 10

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

Free format text: PAYMENT UNTIL: 20120511

Year of fee payment: 11

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

Free format text: PAYMENT UNTIL: 20120511

Year of fee payment: 11

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

Free format text: PAYMENT UNTIL: 20130511

Year of fee payment: 12

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

Free format text: PAYMENT UNTIL: 20140511

Year of fee payment: 13

EXPY Cancellation because of completion of term