[go: up one dir, main page]

JP2000196630A - Multiplex communication system - Google Patents

Multiplex communication system

Info

Publication number
JP2000196630A
JP2000196630A JP10366304A JP36630498A JP2000196630A JP 2000196630 A JP2000196630 A JP 2000196630A JP 10366304 A JP10366304 A JP 10366304A JP 36630498 A JP36630498 A JP 36630498A JP 2000196630 A JP2000196630 A JP 2000196630A
Authority
JP
Japan
Prior art keywords
input
output
setting
station unit
ports
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP10366304A
Other languages
Japanese (ja)
Inventor
Yoshinori Sato
義則 佐藤
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.)
Nissan Motor Co Ltd
Original Assignee
Nissan Motor Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nissan Motor Co Ltd filed Critical Nissan Motor Co Ltd
Priority to JP10366304A priority Critical patent/JP2000196630A/en
Publication of JP2000196630A publication Critical patent/JP2000196630A/en
Pending legal-status Critical Current

Links

Landscapes

  • Small-Scale Networks (AREA)

Abstract

PROBLEM TO BE SOLVED: To provide a multiplex communication system capable of reducing a communication format necessary to input output setting and quickly starting a device operation when the device is started. SOLUTION: A master station unit 101 transmits input output setting data to a slave station unit 102 through a communication line 105. The input output setting data consists of an output setting frame which has a bit width equal to the number of output ports and is composed of codes specifying either of two available modes, an input setting frame which has a bit width equal to the number of input ports and is composed of codes specifying either of two available modes and a communication pause period provided between the output and input setting frames. The slave station unit having received the input output setting data defines input-output ports of the bit width of the output setting frame as output ports among input-output ports, defines input output ports of the bit width of the input setting frame as input ports and decides either of two modes existing in inputs and output for every bit in accordance with the content of the output and input setting frames.

Description

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

【0001】[0001]

【発明の属する技術分野】本発明は、親局ユニットと子
局ユニットとの間で、通信線を介して多重通信を行なう
多重通信装置に関し、特に車両内における各種スイッチ
の操作信号や各種アクチュエータの駆動信号等を伝送す
るのに好適な多重通信装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a multiplex communication device for performing multiplex communication between a master unit and a slave unit via a communication line, and more particularly to an operation signal of various switches and various actuators in a vehicle. The present invention relates to a multiplex communication device suitable for transmitting a drive signal and the like.

【0002】[0002]

【従来の技術】車両等において、各種スイッチの操作信
号や各種アクチュエータの駆動信号等を伝送するには、
以前は必要な個所同士を配線で接続することが一般的で
あったが、最近は親局ユニットと子局ユニットとの間
で、通信線を介して多重通信を行なうことによって信号
の伝送を行なう装置が用いられ始めている。このような
多重通信装置においては、一つの子局ユニットに複数の
出力ポート(各種アクチュエータへの駆動信号等を出
力)と複数の入力ポート(スイッチの操作信号やセンサ
からの信号等を入力)とを備え、それぞれの出力ポート
や入力ポートを介して信号の入出力を行なうようになっ
ている。
2. Description of the Related Art To transmit operation signals of various switches and drive signals of various actuators in a vehicle or the like,
In the past, it was common to connect necessary parts with wiring. Recently, however, signal transmission is performed by performing multiplex communication between a master station unit and a slave station unit via a communication line. Equipment is beginning to be used. In such a multiplex communication device, a plurality of output ports (output drive signals to various actuators) and a plurality of input ports (input of switch operation signals, signals from sensors, etc.) are provided to one slave station unit. And input / output signals via respective output ports and input ports.

【0003】上記のような構成においては、各入出力ポ
ートを予め出力用か入力用かに設定しておく必要があ
る。従来は各子局ユニットのそれぞれの入出力ポートで
ハード的に設定するのが一般的であった。しかし、ハー
ド的に設定する場合には、各入出力ポートに接続する各
負荷や各スイッチの位置に応じて、各子局ユニットごと
にハードを設定しなければならないので工数と費用がか
かり、また変更する際にも手間がかかる、という問題が
あった。
In the above configuration, it is necessary to set each input / output port for output or input in advance. In the past, it has been common practice to make hardware settings at each input / output port of each slave station unit. However, in the case of hardware setting, it is necessary to set hardware for each slave unit according to the position of each load and each switch connected to each input / output port. There has been a problem that it takes time to change.

【0004】上記の問題を解決するため、本出願人は、
通常の通信動作開始前(電源投入時等)に親局ユニット
からの通信によって各子局ユニットの各入出力ポートの
入力、出力の設定を行なう多重通信装置を既に出願(特
願平10−282222号未公開)している。このよう
な装置において、親局ユニットからの入出力設定データ
は例えば図5に示すような通信フォーマットで送信する
ことが考えられる。
[0004] In order to solve the above problems, the present applicant has
A multiplex communication apparatus for setting the input and output of each input / output port of each slave station unit by communication from the master station unit before starting a normal communication operation (when power is turned on, etc.) has already been filed (Japanese Patent Application No. 10-282222). Issue unpublished). In such an apparatus, the input / output setting data from the master station unit may be transmitted in a communication format as shown in FIG. 5, for example.

【0005】図5において、通信フォーマットは、送信
の開始を示す符号であるSOM(Start Of Message)、
データの種類を示すコマンドフレームCOM(COMman
d)、送信先の子局ユニットアドレスを示すアドレスフ
レームADR(ADdRess)に続いて、入出力ポートのう
ち出力ポートとしたいビット幅を示す出力幅設定フレー
ム、各ポートのモードを指定するモード設定フレームを
備えている。このモード設定フレームでは、ハイサイド
駆動あるいはプルアップ抵抗接続を“1”、ローサイド
駆動あるいはプルダウン抵抗接続“0”で指定する(詳
細は発明の実施の形態で説明)。なお、AP(Address
Parity)はCOMフレームとADRフレームに対するパ
リティ、DP(Data Parity)はDataフレーム対す
るパリティ、EOM(End Of Message)は通信の終了を
示す符号である。
[0005] In FIG. 5, the communication format is SOM (Start Of Message) which is a code indicating the start of transmission,
Command frame COM (COMman
d), following an address frame ADR (ADdRess) indicating the address of the slave unit of the transmission destination, an output width setting frame indicating a bit width desired to be set as an output port among the input / output ports, and a mode setting frame specifying the mode of each port It has. In this mode setting frame, the high-side drive or pull-up resistor connection is designated by “1” and the low-side drive or pull-down resistor connection is designated by “0” (details will be described in the embodiments of the invention). Note that the AP (Address
(Parity) is the parity for the COM frame and the ADR frame, DP (Data Parity) is the parity for the Data frame, and EOM (End Of Message) is a code indicating the end of communication.

【0006】図5では、8ビットの入出力ポート(入力
と出力の合計が8個)を有する子局ユニットの場合を想
定しているため、出力幅設定フレームは0〜8を表現す
るために必要な4ビット、モード設定フレームは各ポー
ト毎に1ビットで計8ビットを設け、それぞれ下位から
送信するものとしている。例えば、8ビットの入出力ポ
ートのうち3ビットを出力、残り5ビットを入力とした
い場合は、出力幅設定フレームに“3”すなわち001
1を下位から順に送信する。また、出力としたポートを
下位から順にローサイド駆動、ローサイド駆動、ハイサ
イド駆動とし、入力としたポートを下位から順にプルダ
ウン、プルアップ、プルダウン、プルアップ、プルアッ
プとする場合には、モード設定フレームには0、0、
1、0、1、0、1、1の順に送信する。
In FIG. 5, since it is assumed that the slave unit has an 8-bit input / output port (the total number of inputs and outputs is eight), the output width setting frame is used to represent 0-8. A necessary 4 bits and a mode setting frame are provided for a total of 8 bits, one bit for each port, and transmitted from the lower order. For example, when it is desired to output 3 bits and input the remaining 5 bits of the 8-bit input / output port, “3”, that is, 001 is set in the output width setting frame.
1 are transmitted from the lower order. If the output ports are set to low-side drive, low-side drive, and high-side drive in order from the bottom, and the input ports are set to pull-down, pull-up, pull-down, pull-up, and pull-up in order from the bottom, the mode setting frame Contains 0, 0,
The transmission is performed in the order of 1, 0, 1, 0, 1, 1.

【0007】上記の信号を受信した子局ユニットは、出
力幅設定フレームの値“3”に基づき、下位3ビットを
“1”残りを“0”にセットし、モード設定フレームの
値をモード設定レジスタに保持する。これにより子局ユ
ニットの8ビットの入出力ポートは所望の機能を持った
出力用あるいは入力用として動作させることが可能にな
り、それ以後、親局ユニットからの送信データによる子
局ユニットの負荷駆動や、子局ユニットからの送信デー
タによる親局ユニットへの入力状態の通知を行なうこと
ができる。なお、図5から判るように、入出力の設定に
要するデータ長は、8ビット入出力を持つ子局ユニット
1ノード当たり12ビット(4+8=12)である。
The slave unit which has received the above signal sets the lower 3 bits to "1" and the rest to "0" based on the value "3" of the output width setting frame, and sets the value of the mode setting frame to the mode. Hold in a register. As a result, the 8-bit input / output port of the slave unit can be operated for output or input with a desired function, and thereafter, the load drive of the slave unit by the transmission data from the master unit is performed. Also, it is possible to notify the input state to the master station unit by the transmission data from the slave station unit. As can be seen from FIG. 5, the data length required for the input / output setting is 12 bits (4 + 8 = 12) per node of the slave unit having 8 bits input / output.

【0008】上記先行出願の多重通信装置によれば、親
局ユニットのプログラムによって各入出力ポートの入
力、出力の設定を任意に変更できる。そのため子局ユニ
ットとして同じ構成の基板を用い、各子局ユニットに接
続される負荷やスイッチの編成に応じて親局ユニットの
プログラムを設定することにより、同じ基板を用いて任
意の編成が可能になると共に、組立て後に変更すること
も容易になるので、費用を低減することが出来る。
According to the multiplex communication device of the above-mentioned prior application, the setting of input and output of each input / output port can be arbitrarily changed by the program of the master station unit. Therefore, by using a board of the same configuration as a slave station unit and setting the program of the master station unit according to the organization of the load and switch connected to each slave station unit, arbitrary organization can be performed using the same board. In addition, the cost can be reduced because it is easy to change after assembly.

【0009】[0009]

【発明が解決しようとする課題】前記本出願人の先行出
願による多重通信装置においては、装置の起動時に親局
ユニットから各子局ユニットに対して、入出力ポートの
設定のために入出力設定データを送信し、各子局ユニッ
トのレジスタに書き込みを行なう必要があるが、入出力
の設定に要するデータ長は、例えば8ビット入出力を持
つ子局ユニットの場合には12ビットを必要とする。そ
のため子局ユニットの増加や入出力ポート数が増加する
と、通信による入出力設定に要する時間が大きくなるた
め装置起動時に初期設定に要する時間が長くなる、とい
う問題があった。
In the multiplex communication apparatus according to the prior application filed by the applicant of the present invention, the input / output setting for setting the input / output port from the master unit to each slave unit is performed at the time of starting the apparatus. It is necessary to transmit data and write to the register of each slave station unit, but the data length required for input / output setting requires, for example, 12 bits in the case of a slave unit having 8-bit input / output. . Therefore, when the number of slave station units and the number of input / output ports increase, the time required for the input / output setting by communication increases, so that there is a problem that the time required for the initial setting at the time of starting the apparatus becomes longer.

【0010】本発明は、上記のごとき従来技術の問題を
解決するためになされたものであり、入出力設定に要す
る通信フォーマットを短くし、装置の起動時に速やかに
機器の動作を開始することの出来る多重通信装置を提供
することを目的とする。
SUMMARY OF THE INVENTION The present invention has been made to solve the problems of the prior art as described above. It is an object of the present invention to shorten the communication format required for input / output settings, and to start the operation of the device immediately when the device is started. It is an object of the present invention to provide a multiplex communication device that can perform the multiplex communication.

【0011】[0011]

【課題を解決するための手段】上記の目的を達成するた
め、本発明においては、特許請求の範囲に記載するよう
に構成している。すなわち請求項1に記載の発明におい
ては、親局ユニットと複数の入出力ポートを有する子局
ユニットとが通信線を介して接続され、前記親局ユニッ
トが前記通信線上に出力する駆動信号を前記子局ユニッ
トが受信し、前記子局ユニットにおいて出力に設定され
た前記入出力ポートに接続された負荷(例えばモータや
ランプ等)を前記駆動信号によって制御し、前記子局ユ
ニットにおいて入力に設定された前記入出力ポートに接
続された信号発生手段(例えばスイッチやセンサ等)か
らの信号を前記子局ユニットが通信線上に出力し、それ
を前記親局ユニットが受信する多重通信装置において、
前記子局ユニットの入出力ポートは、入力もしくは出力
の選択が可能であり、かつ、入力および出力にはそれぞ
れに2つのモードが存在し、通常の通信動作開始前(例
えば電源投入時)に、前記親局ユニットから前記子局ユ
ニットへ入出力ポート設定用の入出力設定データを送信
することにより、前記子局ユニットの各入出力ポートを
入力もしくは出力のどちらかに設定し、前記入出力設定
データは、出力ポート数に対応したビット幅を持ちビッ
ト毎に前記2つのモードのうちいずれかを指定する符号
から成る出力設定フレームと、入力ポート数に対応した
ビット幅を持ちビット毎に前記2つのモードのうちいず
れかを指定する符号から成る入力設定フレームと、前記
出力設定フレームと前記入力設定フレームの間に設けら
れた通信休止期間と、を有するものであり、前記入出力
設定データを受信した前記子局ユニットは、前記入出力
ポートのうち、前記出力設定フレームのビット幅分を出
力ポートとし、前記入力設定フレームのビット幅分を入
力ポートとし、前記出力設定フレームおよび前記入力設
定フレームの内容に応じて、入力および出力のそれぞれ
に存在する前記2つのモードのうちいずれかをビット毎
に決定するように構成している。
Means for Solving the Problems In order to achieve the above object, the present invention is configured as described in the claims. That is, in the invention according to claim 1, a master station unit and a slave station unit having a plurality of input / output ports are connected via a communication line, and the master station unit outputs a drive signal output on the communication line. The slave unit receives and controls a load (e.g., a motor or a lamp) connected to the input / output port set as an output in the slave unit by the drive signal, and is set as an input in the slave unit. The slave station unit outputs a signal from a signal generating means (for example, a switch or a sensor) connected to the input / output port to a communication line, and the master station unit receives the signal.
The input / output of the slave station unit can be selected for input or output, and there are two modes for input and output, respectively. Before starting normal communication operation (for example, at power-on), By transmitting input / output setting data for input / output port setting from the master station unit to the slave station unit, each input / output port of the slave station unit is set to either input or output, and the input / output setting is performed. The data consists of an output setting frame having a bit width corresponding to the number of output ports and consisting of a code designating one of the two modes for each bit, and an output setting frame having a bit width corresponding to the number of input ports for each bit. An input setting frame consisting of a code designating one of the two modes, and a communication pause period provided between the output setting frame and the input setting frame The slave station unit that has received the input / output setting data sets the bit width of the output setting frame as an output port among the input / output ports, and sets the bit width of the input setting frame as the output port. An input port is configured so that one of the two modes existing in each of the input and output is determined for each bit in accordance with the output setting frame and the contents of the input setting frame.

【0012】上記のように構成したことにより、出力設
定フレームと入力設定フレームを合わせたデータ全体の
長さは、入出力ポートの総数と同じビット数で済み、そ
れに1ビット分の通信休止期間が加わるだけなので、従
来よりも入出力設定データの長さを大幅に短くすること
が出来る。
With the above configuration, the total length of data including the output setting frame and the input setting frame is the same as the number of bits of the total number of input / output ports, and the communication suspension period for one bit is reduced. Since it is only added, the length of the input / output setting data can be significantly reduced as compared with the related art.

【0013】また、上記の子局ユニットにおける入力ポ
ートに存在する2つのモードとは、例えば請求項2に記
載のごとく、プルアップ抵抗接続とプルダウン抵抗接続
である。
The two modes existing at the input port of the slave station unit are, for example, a pull-up resistor connection and a pull-down resistor connection.

【0014】また、上記子局ユニットにおける出力ポー
トに存在する前記2つのモードとは、例えば請求項3に
記載のごとく、ハイサイド駆動とローサイド駆動であ
る。
The two modes present at the output port of the slave station unit are, for example, high-side drive and low-side drive.

【0015】[0015]

【発明の効果】本発明によれば、短いフォーマットで入
出力設定を行なうことが可能となり、より短い時間で装
置起動時の入出力設定を完了することができる、という
効果が得られる。
According to the present invention, the input / output setting can be performed in a short format, and the effect that the input / output setting at the time of starting the apparatus can be completed in a shorter time can be obtained.

【0016】[0016]

【発明の実施の形態】図1は、本発明の一実施の形態を
示すブロック図である。図1において、親局ユニット1
01と複数の子局ユニット102〜104が通信線10
5で接続されている。各子局ユニット102〜104は
複数(この場合は8個)の入出力ポート119〜126
を備え、各ポートにはモータ127、ランプ128〜1
29等の負荷や、スイッチ130〜134等の信号発生
手段が接続されている。なお、上記の構成は入出力ポー
トが8個の場合を例示したものであり、他の数でも勿論
可能である。例えば入出力ポートが16個の場合には8
ビットを16ビットに変更すればよい。また、スイッチ
の代わりにセンサを用いる場合もある。
FIG. 1 is a block diagram showing an embodiment of the present invention. In FIG. 1, a master station unit 1
01 and a plurality of slave units 102 to 104
5 is connected. Each of the slave station units 102 to 104 has a plurality (eight in this case) of input / output ports 119 to 126.
Motor 127, lamps 128-1
Loads such as 29 and signal generating means such as switches 130 to 134 are connected. Note that the above configuration exemplifies the case where the number of input / output ports is eight, and other numbers are of course possible. For example, if there are 16 input / output ports, 8
The bit may be changed to 16 bits. In some cases, a sensor is used instead of a switch.

【0017】以下、子局ユニットについては子局ユニッ
ト102を例として説明するが、各子局ユニットの基本
構成は同じである。ただし、各入出力ポートの入力用と
出力用の設定は各子局ユニット毎に任意に設定出来る。
子局ユニット102は、親局ユニット101からのデー
タを受信する受信回路106、受信データに基づいて入
出力ポート119〜129を入力あるいは出力に切り替
えるDDR(Data Direction Register)110、モー
ドを決定するモード設定レジスタ109、負荷のON/
OFFを決定する出力データレジスタ108を備え、こ
れら各レジスタにより入力、出力および各種モードの選
択が可能な入出力回路111〜118を各ポート毎に備
えている。
Hereinafter, the slave unit will be described by taking the slave unit 102 as an example, but the basic configuration of each slave unit is the same. However, input and output settings of each input / output port can be set arbitrarily for each slave unit.
The slave station unit 102 includes a receiving circuit 106 for receiving data from the master station unit 101, a DDR (Data Direction Register) 110 for switching input / output ports 119 to 129 to input or output based on the received data, and a mode for determining a mode. Setting register 109, load ON /
An output data register 108 for determining OFF is provided, and input / output circuits 111 to 118 capable of selecting input, output and various modes are provided for each port.

【0018】上記の各レジスタは装置起動時(電源投入
時)に一旦、全ビット“0”に初期化される。DDR1
10の出力は“1”が出力指定、“0”が入力指定を表
し、対応するビットが“1”となっているポートは、N
OTゲート146、NANDゲート137、ANDゲー
ト138の作用により、トランジスタ141、142が
双方OFFとなるので、プルアップ抵抗143、プルダ
ウン抵抗144が切り離される。したがって当該ポート
は出力用に指定される。また、“0”となっているポー
トは、NOTゲート145、NANDゲート135、A
NDゲート136の作用により出力トランジスタ13
9、140の駆動が禁止される。したがって当該ポート
は入力用に指定される。
Each of the above registers is initialized to all bits "0" once when the apparatus is started (when power is turned on). DDR1
As for the output of 10, “1” indicates the output designation, “0” indicates the input designation, and the port whose corresponding bit is “1” is N
The transistors 141 and 142 are both turned off by the operation of the OT gate 146, the NAND gate 137, and the AND gate 138, so that the pull-up resistor 143 and the pull-down resistor 144 are disconnected. Therefore, the port is designated for output. The ports that are “0” are NOT gate 145, NAND gate 135, and A
The output transistor 13 is operated by the function of the ND gate 136.
9 and 140 are prohibited. Therefore, the port is designated for input.

【0019】DDR110によって出力指定されている
ポートは、モード設定レジスタ109の出力が“1”の
ときは、NANDゲート135、ANDゲート136の
作用により電源側出力トランジスタ139によるハイサ
イド駆動(ポート側が電源に接続されて高電位となる)
が選択され、“0”のときはGND側出力トランジスタ
1側によるローサイド駆動(ポート側が接地されて負荷
側が高電位となる)が選択される。
When the output of the mode setting register 109 is "1", the port specified by the DDR 110 is driven by the power supply side output transistor 139 by the operation of the NAND gate 135 and the AND gate 136 (the port side is driven by the power supply). Connected to a high potential)
Is selected, and when "0", low-side drive by the GND-side output transistor 1 side (the port side is grounded and the load side becomes high potential) is selected.

【0020】また、DDR110によって入力指定され
ているポートは、モード設定レジスタ109の出力が
“1”のときは、NANDゲート137、ANDゲート
138の作用により電源側トランジスタ141がON
し、プルアップ抵抗143が接続される。“0”のとき
はGND側トランジスタ142がONし、プルダウン抵
抗144が接続される。上記のように、負荷やスイッチ
等の特性や使用状態に対応して、ハイサイド駆動または
ローサイド駆動、或いはプルアップ抵抗接続またはプル
ダウン抵抗接続に自由に設定することが出来る。
When the output of the mode setting register 109 is "1", the power supply side transistor 141 of the port specified by the DDR 110 is turned on by the operation of the NAND gate 137 and the AND gate 138.
Then, a pull-up resistor 143 is connected. When it is “0”, the GND-side transistor 142 is turned on, and the pull-down resistor 144 is connected. As described above, high-side driving or low-side driving, pull-up resistor connection, or pull-down resistor connection can be freely set according to the characteristics and use state of the load, switch, and the like.

【0021】DDR110によって出力指定されたポー
トは、出力データレジスタ108に格納された親局ユニ
ット101からの負荷駆動データに応じて、モード設定
レジスタ109で指定された方式にて負荷駆動を行な
う。また、DDR110によって入力指定されたポート
の状態は、入力データとして送信回路107を介して親
局ユニット101に送信される。
The port whose output is designated by the DDR 110 performs a load drive in the mode designated by the mode setting register 109 in accordance with the load drive data from the master station unit 101 stored in the output data register 108. Further, the status of the port designated by the DDR 110 is transmitted to the master station unit 101 via the transmission circuit 107 as input data.

【0022】以下、入出力設定時の送信フォーマットに
ついて説明する。図2は、入出力設定時における親局ユ
ニット101からの送信フォーマットの一実施の形態を
示す図である。図2において、通信フォーマットは、送
信の開始を示す符号であるSOM(Start Of Messag
e)、データの種類を示すコマンドフレームCOM(COM
mand)、送信先の子局ユニットアドレスを示すアドレス
フレームADR(ADdRess)、COMフレームとADR
フレームに対するパリティであるAP(Address Parit
y)、Dataフレーム対するパリティであるDP(Dat
a Parity)、通信の終了を示す符号EOM(End Of Mes
sage)を備えている。そして送信開始符号SOM、コマ
ンドフレームCOM、送信先アドレスADR、パリティ
APに続いて、出力設定フレーム、入力設定フレームを
送信する。また、出力設定フレームと入力設定フレーム
の間には通信休止期間(図2では“休止”と表示)を設
ける。この通信休止期間は、通信線をデータ通信を行な
っていない場合と同様の状態にする。例えば、データ通
信を行なっていない間、通信線をGNDレベルにする装
置においては、通信休止期間もGNDレベルとし、特定
の振幅を持つパルスを出し続ける装置においては、通信
休止期間として同じパルスを挿入する。ただし、このよ
うな多重通信装置では、所定時間通信線上にデータがな
いことを検知した場合は、受信を終了することが一般的
であるから、このような場合には通信休止期間を受信終
了の検知時間あるいはパルス数よりも短くしなければな
らない。
The transmission format at the time of input / output setting will be described below. FIG. 2 is a diagram showing an embodiment of a transmission format from the master station unit 101 at the time of input / output setting. In FIG. 2, the communication format is SOM (Start Of Message) which is a code indicating the start of transmission.
e), a command frame COM (COM indicating the type of data)
mand), an address frame ADR (ADdRess) indicating the address of the slave unit of the transmission destination, a COM frame and an ADR
AP (Address Parit) which is the parity for the frame
y), DP (Dat which is a parity for the Data frame)
a Parity), a code EOM (End Of Mes) indicating the end of communication
sage). Then, following the transmission start code SOM, the command frame COM, the destination address ADR, and the parity AP, an output setting frame and an input setting frame are transmitted. In addition, a communication suspension period (in FIG. 2, indicated as “pause”) is provided between the output setting frame and the input setting frame. During this communication suspension period, the communication line is set in the same state as when no data communication is performed. For example, in a device that sets the communication line to the GND level while data communication is not being performed, the communication pause period is also set to the GND level, and in a device that continuously emits a pulse having a specific amplitude, the same pulse is inserted as the communication pause period. I do. However, in such a multiplex communication device, if it is detected that there is no data on the communication line for a predetermined time, the reception is generally terminated. Must be shorter than the detection time or the number of pulses.

【0023】図2における出力設定フレームと入力設定
フレームは、前記図5に示した従来例とは異なる。すな
わち、出力設定フレームは出力用に指定すべき入出力ポ
ートの数に対応したビット幅を持ち、かつ各ビットが出
力ポートのモードを指定する符号から成り、入力設定フ
レームは入力用に指定すべき入出力ポートの数に対応し
たビット幅を持ち、かつ各ビットが入力ポートのモード
を指定する符号から成る。
The output setting frame and the input setting frame in FIG. 2 are different from the conventional example shown in FIG. That is, the output setting frame has a bit width corresponding to the number of input / output ports to be designated for output, and each bit consists of a code for designating the mode of the output port, and the input setting frame should be designated for input. It has a bit width corresponding to the number of input / output ports, and each bit is composed of a code designating the mode of the input port.

【0024】したがって出力設定フレームと入力設定フ
レームの長さは出力用と入力用とのビット数に応じて変
化(全体の長さは一定)し、出力設定フレームと入力設
定フレームとの間に通信休止期間が入ることになる。す
なわち、通信休止期間の位置は、出力用と入力用の境界
に位置し、入出力ポートの出力用と入力用の配分によっ
てフオーマツトの先頭(APの直後)からの末尾(DP
の直前)まで変化することになる。
Therefore, the lengths of the output setting frame and the input setting frame change (the entire length is constant) according to the number of bits for output and for input, and communication between the output setting frame and the input setting frame is performed. A pause will be entered. That is, the position of the communication suspension period is located on the boundary between output and input, and the end (DP) from the beginning of the format (immediately after the AP) according to the distribution of output and input of the input / output ports.
Until immediately before).

【0025】また、出力設定フレーム中の各ビットは、
出力ポートに対するモード指定を示しており、“1”が
ハイサイド駆動、“0”がローサイド駆動を示す。ま
た、入力設定フレーム中の各ビットは、入力ポートに対
するモード指定を示しており、“1”がプルアップ抵抗
接続、“0”がプルダウン抵抗接続を示す。
Each bit in the output setting frame is
The mode designation for the output port indicates that "1" indicates high-side drive and "0" indicates low-side drive. Each bit in the input setting frame indicates the mode designation for the input port, where "1" indicates a pull-up resistor connection and "0" indicates a pull-down resistor connection.

【0026】以下、作用を説明する。装置の起動時に
は、親局ユニット101は各子局ユニット102〜10
4に対して、図2に示したフォーマットで入出力設定デ
ータを送信する。これを受信した予局ユニット102
は、出力設定フレームの開始以降、通信休止期間を検出
するまでのビット数をカウントし、そのカウント数に基
づいてDDR110をセットする。図2の例において
は、出力設定フレームのビット幅は3ビットであるた
め、DDR110の下位3ビットに“1”、残りのビッ
トに“0”がセットされ、子局ユニット102の入出力
ポート119〜126のうち下位3ビット(119〜1
21)が出力用、残り(122〜126)が入力用とし
て設定される。
The operation will be described below. When the apparatus is started, the master station unit 101 is connected to each of the slave station units 102 to 10.
4, the input / output setting data is transmitted in the format shown in FIG. Pre-station unit 102 that has received this
Counts the number of bits from the start of the output setting frame until the communication suspension period is detected, and sets the DDR 110 based on the counted number. In the example of FIG. 2, since the bit width of the output setting frame is 3 bits, "1" is set in the lower 3 bits of the DDR 110 and "0" is set in the remaining bits, and the input / output port 119 of the slave unit 102 is set. To 126, the lower three bits (119 to 1)
21) is set for output, and the rest (122 to 126) are set for input.

【0027】また、出力設定フレーム中の各ビットは、
出力ポートに対するモード指定を示しており、“1”が
ハイサイド駆動、“0”がローサイド駆動を示す。例え
ば図1のように、下位から順にローサイド駆動、ローサ
イド駆動、ハイサイド駆動とする場合には、図2の出力
設定フレームに示すように下位から順に0、0、1とな
る。
Each bit in the output setting frame is
The mode designation for the output port indicates that "1" indicates high-side drive and "0" indicates low-side drive. For example, as shown in FIG. 1, when low-side driving, low-side driving, and high-side driving are performed in order from the lower order, 0, 0, and 1 are set in the lower order as shown in the output setting frame in FIG.

【0028】また、入力設定フレーム中の各ビットは、
入力ポートに対するモード指定を示しており、“1”が
プルアップ抵抗接続、“0”がプルダウン抵抗接続を示
す。例えば図1のように、下位から順にプルダウン、プ
ルアップ、プルダウン、プルアップ、プルアップとする
場合には、図2の入力設定フレームに示すように、下位
から順に0、1、0、1、1となる。子局ユニット10
2は、受信した出力設定フレームのデータと入力設定フ
レームのデータを、それぞれモード設定レジスタの下
位、上位にセットする。
Each bit in the input setting frame is
A mode designation for an input port is shown, where "1" indicates a pull-up resistor connection and "0" indicates a pull-down resistor connection. For example, as shown in FIG. 1, when pull-down, pull-up, pull-down, pull-up, and pull-up are performed in order from the bottom, 0, 1, 0, 1,. It becomes 1. Slave unit 10
2 sets the received data of the output setting frame and the data of the input setting frame to the lower and upper bits of the mode setting register, respectively.

【0029】上記のように、図2の通信フォーマットに
よれば、図1のような出力用と入力用の設定を行なう場
合に、「0、0、1、休止、0、1、0、1、1」のデ
ータを送受信すればよい。すなわち、出力設定フレーム
と入力設定フレームを合わせたデータ全体の長さは、入
出力ポートの総数と同じビット数で済み、それに1ビッ
ト分の通信休止期間が加わるだけなので、従来よりも入
出力設定データの長さを大幅に短くすることが出来る。
例えば、上記のように8ビット入出力を持つ子局ユニッ
トの場合には1つの子局ユニットあたり9ビットであ
る。それに対して図5に示した従来例で同じ8ビット入
出力を持つ子局ユニットの場合には12ビットが必要で
あり、本発明の方が短いフォーマットで入出力の初期設
定が出来ることなる。
As described above, according to the communication format of FIG. 2, when setting for output and input as shown in FIG. 1, "0, 0, 1, pause, 0, 1, 0, 1" is performed. , 1 ”may be transmitted and received. That is, the total length of the data including the output setting frame and the input setting frame is only the same number of bits as the total number of input / output ports, and only a 1-bit communication suspension period is added thereto. Data length can be significantly reduced.
For example, in the case of a slave unit having 8-bit input / output as described above, one slave unit has 9 bits. On the other hand, in the case of the slave unit having the same 8-bit input / output in the conventional example shown in FIG. 5, 12 bits are required, and the input / output can be initialized in a shorter format in the present invention.

【0030】図3は、図2に示した送信フォーマットの
具体的な例を示す図であり、PWM符号による多重通信
に適用した例を示す。図3においては、1ビット当たり
のパルス幅の大小によりデータ“1”、“0”を表し、
通信線上にデータを出力しない場合は通信線をGNDレ
ベルとする。従って、出力設定フレームと入力設定フレ
ームの間の通信休止期間も同様に1ビット期間のあいだ
GNDレベルとしている。また、パリティAP、DPは
奇数パリティを例示している。
FIG. 3 is a diagram showing a specific example of the transmission format shown in FIG. 2, and shows an example applied to multiplex communication using a PWM code. In FIG. 3, data "1" and "0" are represented by the magnitude of the pulse width per bit,
When data is not output on the communication line, the communication line is set to the GND level. Therefore, the communication suspension period between the output setting frame and the input setting frame is also set to the GND level for one bit period. Parities AP and DP exemplify odd parity.

【0031】図4は、図2に示した送信フォーマットの
具体的な他の例を示す図であり、クロック重畳符号によ
る多重通信に適用した例を示す。図4においては、1ビ
ット当たりのパルス振幅の大小によりデータ“1”、
“0”を表し、通信線上にデータを出力しない場合はデ
ータ用のパルスとは異なる第3の振幅のパルスを送信し
続ける。従って、出力設定フレームと入力設定フレーム
の間の通信休止期間は第3の振幅を持つパルスで表現し
ている。また、パリティAP、DPは奇数パリティを例
示している。
FIG. 4 is a diagram showing another specific example of the transmission format shown in FIG. 2, showing an example applied to multiplex communication using a clock superimposed code. In FIG. 4, data "1",
When “0” is indicated and data is not output on the communication line, a pulse having a third amplitude different from the data pulse is continuously transmitted. Therefore, the communication pause period between the output setting frame and the input setting frame is represented by a pulse having the third amplitude. Parities AP and DP exemplify odd parity.

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

【図1】本発明の一実施の形態を示すブロック図。FIG. 1 is a block diagram showing one embodiment of the present invention.

【図2】入出力設定時における親局ユニット101から
の送信フォーマットの一実施の形態を示す図。
FIG. 2 is a diagram showing an embodiment of a transmission format from a master station unit 101 at the time of input / output setting.

【図3】図2に示した送信フォーマットの具体的な例を
示す図であり、PWM符号による多重通信に適用した
例。
FIG. 3 is a diagram showing a specific example of the transmission format shown in FIG. 2, which is applied to multiplex communication using a PWM code.

【図4】図2に示した送信フォーマットの具体的な他の
例を示す図であり、クロック重畳符号による多重通信に
適用した例。
FIG. 4 is a diagram showing another specific example of the transmission format shown in FIG. 2, which is applied to multiplex communication using a clock superimposition code.

【図5】本発明の先行技術における入出力設定データの
通信フォーマットの一例を示す図。
FIG. 5 is a diagram showing an example of a communication format of input / output setting data in the prior art of the present invention.

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

101…親局ユニット 102〜10
4…子局ユニット 105…通信線 106…受信
回路 107…送信回路 108…出力
データレジスタ 109…モード設定レジスタ 110…DD
R 111〜118…入出力回路 119〜12
6…入出力ポート 127…モータ 128〜12
9…ランプ 130〜134…スイッチ 135…NA
NDゲート 136…ANDゲート 137…NA
NDゲート 138…ANDゲート 139、14
0…出力トランジスタ 141、142…トランジスタ 143…プル
アップ抵抗 144…プルダウン抵抗 145、14
6…NOTゲート
101: master station unit 102-10
4 slave unit 105 communication line 106 receiving circuit 107 transmitting circuit 108 output data register 109 mode setting register 110 DD
R 111-118 ... I / O circuit 119-12
6 ... I / O port 127 ... Motor 128-12
9 Lamp 130-134 Switch 135 NA
ND gate 136 ... AND gate 137 ... NA
ND gate 138 ... AND gate 139, 14
0: output transistor 141, 142 ... transistor 143 ... pull-up resistor 144 ... pull-down resistor 145, 14
6… NOT gate

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】親局ユニットと複数の入出力ポートを有す
る子局ユニットとが通信線を介して接続され、前記親局
ユニットが前記通信線上に出力する駆動信号を前記子局
ユニットが受信し、前記子局ユニットにおいて出力に設
定された前記入出力ポートに接続された負荷を前記駆動
信号によって制御し、前記子局ユニットにおいて入力に
設定された前記入出力ポートに接続された信号発生手段
からの信号を前記子局ユニットが通信線上に出力し、そ
れを前記親局ユニットが受信する多重通信装置におい
て、 前記子局ユニットの入出力ポートは、入力もしくは出力
の選択が可能であり、かつ、入力および出力にはそれぞ
れに2つのモードが存在し、 通常の通信動作開始前に、前記親局ユニットから前記子
局ユニットへ入出力ポート設定用の入出力設定データを
送信することにより、前記子局ユニットの各入出力ポー
トを入力もしくは出力のどちらかに設定し、 前記入出力設定データは、出力ポート数に対応したビッ
ト幅を持ちビット毎に前記2つのモードのうちいずれか
を指定する符号から成る出力設定フレームと、入力ポー
ト数に対応したビット幅を持ちビット毎に前記2つのモ
ードのうちいずれかを指定する符号から成る入力設定フ
レームと、前記出力設定フレームと前記入力設定フレー
ムの間に設けられた通信休止期間と、を有するものであ
り、 前記入出力設定データを受信した前記子局ユニットは、
前記入出力ポートのうち、前記出力設定フレームのビッ
ト幅分を出力ポートとし、前記入力設定フレームのビッ
ト幅分を入力ポートとし、前記出力設定フレームおよび
前記入力設定フレームの内容に応じて、入力および出力
のそれぞれに存在する前記2つのモードのうちいずれか
をビット毎に決定するように構成したことを特徴とする
多重通信装置。
A master unit and a slave unit having a plurality of input / output ports are connected via a communication line, and the slave unit receives a drive signal output from the master unit on the communication line. The load connected to the input / output port set to output in the slave station unit is controlled by the drive signal, and the signal generation means connected to the input / output port set to input in the slave station unit. In the multiplex communication apparatus in which the slave station unit outputs a signal on a communication line and the master station unit receives the signal, the input / output port of the slave station unit can select input or output, and There are two modes for input and output, respectively. Before starting normal communication operation, input / output for input / output port setting from the master station unit to the slave station unit. By transmitting setting data, each input / output port of the slave unit is set to either input or output. The input / output setting data has a bit width corresponding to the number of output ports, and the input / output setting data is set to 2 bits per bit. An output setting frame including a code specifying one of the two modes, an input setting frame including a code having a bit width corresponding to the number of input ports and specifying one of the two modes for each bit; And a communication suspension period provided between the output setting frame and the input setting frame, wherein the slave unit receiving the input / output setting data,
Among the input / output ports, the output setting frame has a bit width equivalent to the output port, the input setting frame has the bit width corresponding to the input port, and the input and output setting frames and the input setting frame have the same contents. A multiplex communication apparatus characterized in that one of the two modes present in each output is determined for each bit.
【請求項2】前記子局ユニットにおける入力ポートに存
在する前記2つのモードは、プルアップ抵抗接続とプル
ダウン抵抗接続であることを特徴とする請求項1に記載
の多重通信装置。
2. The multiplex communication apparatus according to claim 1, wherein the two modes present at the input ports of the slave station unit are a pull-up resistor connection and a pull-down resistor connection.
【請求項3】前記子局ユニットにおける出力ポートに存
在する前記2つのモードは、ハイサイド駆動とローサイ
ド駆動であることを特徴とする請求項1に記載の多重通
信装置。
3. The multiplex communication apparatus according to claim 1, wherein said two modes present at an output port of said slave unit are a high-side drive and a low-side drive.
JP10366304A 1998-12-24 1998-12-24 Multiplex communication system Pending JP2000196630A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP10366304A JP2000196630A (en) 1998-12-24 1998-12-24 Multiplex communication system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP10366304A JP2000196630A (en) 1998-12-24 1998-12-24 Multiplex communication system

Publications (1)

Publication Number Publication Date
JP2000196630A true JP2000196630A (en) 2000-07-14

Family

ID=18486449

Family Applications (1)

Application Number Title Priority Date Filing Date
JP10366304A Pending JP2000196630A (en) 1998-12-24 1998-12-24 Multiplex communication system

Country Status (1)

Country Link
JP (1) JP2000196630A (en)

Similar Documents

Publication Publication Date Title
US5202593A (en) Bi-directional bus repeater
JPH0322072A (en) Data processor having external control multiple/non-multiple address-bus and data output bus
KR20090131020A (en) Semiconductor memory device and its on die termination circuit
JPS6239580B2 (en)
CA2336385A1 (en) Improved inter-device serial bus protocol
JP2000196630A (en) Multiplex communication system
US5834949A (en) Bus driver failure detection system
US8082377B2 (en) Data transmission and reception system, master device, and slave device
US4404556A (en) Bit expansion circuit
JPH0771091B2 (en) Bus drive circuit
JP2578144B2 (en) Parallel data port selection method and device
US5996039A (en) Apparatus and method for implementing a tri-state signal driver
JP2751857B2 (en) Semiconductor device
WO2020012928A1 (en) In-vehicle electronic control device
US7301375B2 (en) Off-chip driver circuit and data output circuit using the same
KR910008729A (en) A semiconductor memory device including a plurality of address inputs distributed around the periphery
KR910000875B1 (en) A method and an apparatus for transfering serial data without addressing of i/o modules in programmable logic controller
KR100661712B1 (en) Automotive data communication circuit
KR100430235B1 (en) Data transmission control circuit between system board and sub board
JP2008009519A (en) Data transfer circuit
JPH0346637Y2 (en)
KR19980014826U (en) Driving device of digital output board
JP2000339063A (en) Communication equipment
JP4687819B2 (en) Data transmission device with post-charge logic
KR19990004551A (en) Data path device of semiconductor memory device