JPH022778A - Method for interfacing with cpu - Google Patents

Method for interfacing with cpu

Info

Publication number
JPH022778A
JPH022778A JP63149093A JP14909388A JPH022778A JP H022778 A JPH022778 A JP H022778A JP 63149093 A JP63149093 A JP 63149093A JP 14909388 A JP14909388 A JP 14909388A JP H022778 A JPH022778 A JP H022778A
Authority
JP
Japan
Prior art keywords
data
control circuit
write
cpu
line
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
JP63149093A
Other languages
Japanese (ja)
Inventor
Kyosuke Hashimoto
恭介 橋本
Makoto Muto
誠 武藤
Masato Miyahara
宮原 真人
Yuusaku Himono
檜物 雄作
Osamu Michihira
修 道平
Yuichi Ito
裕一 伊藤
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.)
Furukawa Electric Co Ltd
Mazda Motor Corp
Original Assignee
Furukawa Electric Co Ltd
Mazda Motor 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 Furukawa Electric Co Ltd, Mazda Motor Corp filed Critical Furukawa Electric Co Ltd
Priority to JP63149093A priority Critical patent/JPH022778A/en
Publication of JPH022778A publication Critical patent/JPH022778A/en
Pending legal-status Critical Current

Links

Landscapes

  • Communication Control (AREA)

Abstract

PURPOSE:To surely perform readout and write by initializing the internal address of a control circuit by outputting a control signal before and after the readout/write operation of information by a CPU, respectively, and outputting the normal/defective state of the readout/write on an information line synchronizing with the control signal by the control circuit. CONSTITUTION:At the time of performing the write, the CPU initializes the internal address of the control circuit 2 by setting a signal line 3 at low output 12, and outputting a negative pulse 13 to a signal line 4. and inputs the information 15 in unit of byte sequentially to a signal line 6 synchronizing with the negative pulse on a signal line 5. When the information 15 shows D7='1', the CPU waits the write. By the output of the last pulse 18, it is set as D7='1' synchronizing with the negative pulse on the signal line 4. When the signal D7 is set at '1', the regulated number (n) information 15 are written in order, and when it is D7='0', an operation is repeated from the negative pulse 13. By employing such constitution, the position of the information can be shown clearly, and no address line is required. Also, it is possible to surely perform the readout/write repeatedly by confirming the incompletion of the read/write. At the time of performing the readout from the control circuit 2, the readout/write can be surely performed almost similarly by setting a signal line 19 at high output 19.

Description

【発明の詳細な説明】 (産業上の利用分野) 本発明はCPUのインタフェース方法に関する。[Detailed description of the invention] (Industrial application field) The present invention relates to a CPU interface method.

(従来の技術) 第4図は従来のCPUのインタフェース方法におけるC
PUと制御回路との接続を示すブロック回路図であり、
第5図は第4図の各部のタイミングチャートである。C
PtJ31と外部との通信を制御する制御回路32とは
0本のアドレス線(A〜A 、) 33、データの読み
込みタイミング信号線34、及び8本のデータ線(D、
〜D、)35によって接続されている。制御回路32は
ROMにより構成され、多重伝送路に接続され外部との
通信を制御する。従来の通信方式におけるCPUのイン
タフェース方法では、CPU31は制御回路32に対し
アドレス線33にデータの位置つまりアドレスを示すア
ドレス信号を出力し、またデータの読み込みタイミング
信号線34にデータの読み込みタイミング信号である負
のクロックパルスを出力する。制御回路32はこの負の
クロックパルスに同期してデータ線35によりCPUI
へ第5図(a)で示されるアドレス信号を出力する。C
PU 1はデータ線35に出力されたこのアドレス信号
を受け取りその内部で処理する。このような動作が各デ
ータについて行なわれ、規定回数つまり2′1回繰り返
される。
(Prior art) Figure 4 shows C in a conventional CPU interface method.
It is a block circuit diagram showing the connection between the PU and the control circuit,
FIG. 5 is a timing chart of each part of FIG. 4. C
The control circuit 32 that controls communication between the PtJ 31 and the outside includes 0 address lines (A to A) 33, a data read timing signal line 34, and 8 data lines (D,
~D, ) 35. The control circuit 32 is composed of a ROM, is connected to multiple transmission lines, and controls communication with the outside. In the CPU interface method in the conventional communication system, the CPU 31 outputs an address signal indicating the data position, that is, the address, to the address line 33 to the control circuit 32, and also outputs a data read timing signal to the data read timing signal line 34. Outputs a certain negative clock pulse. The control circuit 32 synchronizes with this negative clock pulse by using the data line 35 to
The address signal shown in FIG. 5(a) is output to. C
PU 1 receives this address signal output to data line 35 and processes it internally. Such an operation is performed for each data and is repeated a prescribed number of times, that is, 2'1 times.

(発明が解決しようとする課題) しかしながら、従来のCPUインタフェース方法では、
ノイズ等の影響によって第5図(b)の負のクロックパ
ルスが打ち消されて制御回路32に入力されなかった場
合には制御回路32がデータ線35にデータを出力しな
いために、CPUIが不定のデータを取り込んでしまい
その内部で誤った処理を行なってしまうという問題点が
あり、またデータの数に従ってアドレス線33の本数が
増加するという問題点がある。
(Problem to be solved by the invention) However, in the conventional CPU interface method,
If the negative clock pulse shown in FIG. 5(b) is canceled due to the influence of noise and is not input to the control circuit 32, the control circuit 32 does not output data to the data line 35, so the CPUI becomes unstable. There is a problem that data is taken in and erroneous processing is performed therein, and there is also a problem that the number of address lines 33 increases as the number of data increases.

本発明は、上記事情にNみてなされたものであり、CP
Uへの接線本数を増加させずにデータの読み取りあるい
は書き込みが確実にできるCPUのインタフェース方法
を提供することを目的とする。
The present invention has been made in view of the above circumstances, and is based on the CP
It is an object of the present invention to provide a CPU interface method that can reliably read or write data without increasing the number of tangents to U.

(課題を解決するための手段) 上記目的を達成するために、本発明によれば、CPUと
外部との通信を制御する制御回路との間で1バイト以上
のデータをバイト単位でデータ線を介して前記制御回路
から前記CPUヘデータを読み出し、前記CPUから前
記制御回路へデータを書き込むCPUのインタフェース
方法において、前記CPUが、データの読み出し/書き
込みの前後に夫々前記制御回路へ制御信号を出力して前
記データ線に人出力する前記データの位置を初期化し、
前記制御回路が、前記制御信号に同期して前記データ線
上に読み出し/書き込み結果の良否を示す信号及びデー
タの読み出し要求の有無を示す信号を出力するCPUの
インタフェース方法が提供される。
(Means for Solving the Problems) In order to achieve the above object, according to the present invention, one or more bytes of data are transferred in byte units between a CPU and a control circuit that controls communication with the outside. In the CPU interface method of reading data from the control circuit to the CPU and writing data from the CPU to the control circuit, the CPU outputs control signals to the control circuit before and after reading/writing data, respectively. initialize the position of the data to be output to the data line,
A CPU interface method is provided in which the control circuit outputs a signal indicating the quality of the read/write result and a signal indicating the presence or absence of a data read request onto the data line in synchronization with the control signal.

(作用) CPUがデータの読み出し/書き込み動作の前後に夫々
制御信号を制御回路へ出力して制御回路の内部アドレス
を初期化し、制御回路がこの制御信号に同期してデータ
線上に読み出し/書き込みの良否の状態を出力する。
(Function) The CPU outputs a control signal to the control circuit before and after a data read/write operation to initialize the internal address of the control circuit, and the control circuit performs read/write operations on the data line in synchronization with this control signal. Outputs pass/fail status.

(実施例) 以下、本発明の実施例を添付図面に基づいて詳細に説明
する。
(Example) Hereinafter, an example of the present invention will be described in detail based on the accompanying drawings.

第1図は本発明のCPUのインタフェース方法を説明す
るためのCPUIと制御回路2の接続を示すブロック回
路図であり、第2図はCPUIから制御回路2への書き
込みの際の各部のタイミングチャート、第3図は制御回
路2からCPUIへの読み出しの際の各部のタイミング
チャートである。CPUIと制御回路2とは読み出し/
書き込み信号(R/W)線3、制御信号(S RC,5
tatusRead C1ear)線4、読み出し/書
き込みクロック信号(RW P 、 Read Wri
 te Pu1se)線5、及びデータ線(D、〜D、
)6によって接続されている。
FIG. 1 is a block circuit diagram showing the connection between the CPUI and the control circuit 2 for explaining the CPU interface method of the present invention, and FIG. 2 is a timing chart of each part when writing from the CPUI to the control circuit 2. , FIG. 3 is a timing chart of each part during reading from the control circuit 2 to the CPUI. The CPUI and control circuit 2 are read/
Write signal (R/W) line 3, control signal (SRC, 5)
tatusRead C1ear) line 4, read/write clock signal (RWP, Read Wri
te Pulse) line 5, and data line (D, ~D,
)6.

まず、CPU 1から制御回路2ヘデータを書き込む際
には、cputは読み出し/書き込み信号線3を第2図
(a)の「低」出力12にする。その後、CPUIは制
御信号線4に第2図(b)の負のパルス13を出力し、
制御回路2の書き込まれるデータ領域の位置つまり内部
アドレスを初期化し、CPUIからデータ線6にバイト
単位で出力されるデータを最初のデータ#1から順に書
き込めるようにする。更に、CPUIは、負のパルス1
3に同期して制御回路2からデータ線6へ出力されるデ
ータ15を、例えばD?−rOJならば書き込み準WO
Kとし、D?=rlJならば書き込み準備NGとすれば
、データ15を入力しD7−「0」の時に読み出し/書
き込みクロック信号線5へ負のパルスを規定のバイト数
0回だけ出力し、読み出し/書き込みクロック信号線5
の負のパルスに同期してデータ線6ヘデータを第2図(
d)のようにデータ#1、データ#2、・・・・・・と
順に出力する。制御回路2はデータ線6に出力されたデ
ータを読み出し/書き込みクロック信号綿5の負のパル
スに同期して入力する。データは制御回路2のデータ領
域にデータ#1からデータ#nまで順序よく書き込まれ
る。データ15がD?−rlJの場合にはCPUIは書
き込みを待機する。
First, when writing data from the CPU 1 to the control circuit 2, cput sets the read/write signal line 3 to the "low" output 12 in FIG. 2(a). After that, the CPUI outputs the negative pulse 13 shown in FIG. 2(b) to the control signal line 4,
The position of the data area to be written in the control circuit 2, that is, the internal address, is initialized so that the data output from the CPUI to the data line 6 in byte units can be written in order from the first data #1. Furthermore, the CPUI is negative pulse 1
For example, the data 15 outputted from the control circuit 2 to the data line 6 in synchronization with D? - If it is rOJ, write quasi-WO
K and D? If =rlJ, then write preparation is NG, input data 15, output negative pulse to read/write clock signal line 5 for the specified number of bytes 0 times when D7 - "0", and read/write clock signal line 5
Data is transferred to data line 6 in synchronization with the negative pulse of Figure 2 (
Data #1, data #2, etc. are output in order as shown in d). The control circuit 2 inputs the data output to the data line 6 in synchronization with the negative pulse of the read/write clock signal 5. Data is written in the data area of the control circuit 2 in order from data #1 to data #n. Data 15 is D? -rlJ, the CPUI waits for writing.

CPUIから読み出し/書き込みクロック信号線5に第
2図(C)の最後のn番目のパルス18が出力されると
、制御信号線4の負のパルスに同期して制御回路2から
データ線6へ出力されるデータをD? = ’ I J
となるようにしておく。第2図(b)の負パルス18の
出力後に、CPUIは制御信号線4に再び第2図(b)
の負のパルス16を出力し、この負のパルス16に同期
して制御回路2からデータ線6へ出力される第2図(d
)の書き込みの良否を示す信号17がり、=’l」とな
っていれば、規定数nのデータが順序良く書き込まれて
いる。信号17がDq=’0」となっている場合には第
2図(b)の負のパルス13の出力から再び同し手順が
繰り返される。
When the last n-th pulse 18 in FIG. 2(C) is output from the CPU to the read/write clock signal line 5, the pulse is output from the control circuit 2 to the data line 6 in synchronization with the negative pulse of the control signal line 4. Is the output data D? = ' I J
Set it so that After outputting the negative pulse 18 shown in FIG. 2(b), the CPU connects the control signal line 4 again to the control signal line 4 shown in FIG. 2(b).
2 (d), which is output from the control circuit 2 to the data line 6 in synchronization with this negative pulse 16.
), if the signal 17 indicating the quality of writing is ='l', the prescribed number n of data has been written in good order. When the signal 17 is Dq='0'', the same procedure is repeated again from the output of the negative pulse 13 in FIG. 2(b).

一方、CPUIが制御回路2からデータを読み出す際に
は、CPUIは読み出し/3き込み信号線3を第3図(
a)の「高J出力19にする。その後、CPU 1は制
御信号線4に第3図(b)の負のパルス20を出力し、
制御回路2から読み出すデータの内部アドレスを初期化
し制御回路2からデータ線6に出力されるデータを最初
のデータ#1から順に書き込めるようにする。更に、C
PU1ば第3図(b)の負のパルス20に同期して制御
回路2からデータ線6へ出力されるデータ22を、例え
ば、Db = ’ O」ならばデータの読み出し要求「
存」とし、D6=’l」ならばデータの読み出し要求「
無」とすれば、データ22を人力しDb = ’ 0 
」の時に読み出し/書き込みクロック信号線5へ負のパ
ルスを規定のバイト数つまりn回だけ出力し、制御回路
2は読み出し/書き込みクロック信号線5の負のパルス
に同期してデータ線6ヘデータを順にデータ#1、デー
タ#2、・・・・・・と出力する。CPUIはデータ線
6に出力されたデータを読み出し/書き込みクロック信
号線5の負のパルスに同期して入力する。データはCP
UIに順序良く読み込まれる。データ#lが、D6=’
lJの時はCPUIは読み出しを待機する。
On the other hand, when the CPUI reads data from the control circuit 2, the CPUI connects the read/3 write signal line 3 as shown in FIG.
a) "High J output 19. After that, the CPU 1 outputs the negative pulse 20 shown in FIG. 3(b) to the control signal line 4,
The internal address of the data read from the control circuit 2 is initialized so that the data output from the control circuit 2 to the data line 6 can be written in order from the first data #1. Furthermore, C
The PU1 receives the data 22 outputted from the control circuit 2 to the data line 6 in synchronization with the negative pulse 20 in FIG.
If D6 = 'l', the data read request is '
If "No", manually input data 22 and get Db = ' 0
”, a negative pulse is output to the read/write clock signal line 5 for a specified number of bytes, that is, n times, and the control circuit 2 outputs data to the data line 6 in synchronization with the negative pulse of the read/write clock signal line 5. Data #1, data #2, etc. are output in order. The CPUI inputs the data output to the data line 6 in synchronization with the negative pulse of the read/write clock signal line 5. Data is CP
Loaded into the UI in an orderly manner. Data #l is D6='
At lJ, the CPUI waits for reading.

CPLI 1から読み出し/書き込みクロック信号線5
へ第3図(C)の最後のn番目の負のパルス25が出力
されると制御信号線4の負のパルスに同期して制御回路
2からデータ線6へ出力されるデータをD6=rlJと
なるようにしておく。第33 (c)の負のパルス25
の出力後に、CPUIは制御信号線4に再び第3図(b
)の負のパルス23を出力する。この負のパルス23に
同期して制御回路2からデータ線6へ出力されるデータ
の読み出し要求信号24がD6=’lJとなっていれば
、規定数のデータが順序良く読み出されている。読み出
し要求信号24がDb=”0」となっていれば再び第3
図(b)の負のパルス20から同じ手順が操り返される
CPLI 1 to read/write clock signal line 5
When the last n-th negative pulse 25 in FIG. 3(C) is output, the data output from the control circuit 2 to the data line 6 in synchronization with the negative pulse of the control signal line 4 is D6=rlJ. Set it so that 33rd (c) negative pulse 25
After the output of , the CPU returns the control signal line 4 to the
) outputs a negative pulse 23. If the data read request signal 24 outputted from the control circuit 2 to the data line 6 in synchronization with this negative pulse 23 is D6='lJ, the specified number of data has been read out in good order. If the read request signal 24 is Db="0", the third
The same procedure is repeated starting from negative pulse 20 in Figure (b).

(発明の効果) 以上説明したように、本発明によれば、CPUと外部と
の通信を制御する制御回路との間で1バイト以上のデー
タをバイト単位でデータ線を介して前記制御回路から前
記CPUヘデータを読み出し、前記CPUから前記制御
回路へデータを書き込むCPUのインタフェース方法に
おいて、前記CPUが、データの読み出し/書き込みの
前後に夫々前記制御回路へ制御信号を出力して前記デー
タ線に人出力する前記データの位置を初期化し、前記制
御回路が、前記制御信号に同期して前記データ線上に読
み出し/書き込み結果の良否を示す信号及びデータの読
み出し要求の有無を示す信号を出力することにより、読
み出し/書き込みを行う際に必ずデータの順序つまりア
ドレスが初期化され、そのため順序通りにデータの読み
出し/書き込みを行なえばデータの位置は明確になり、
その結果アドレス線が不要となり、そのため接続点の数
を残少でき、CPUのボート数及び制御回路の端子数を
節約でき、また、読み出し/書き込みの完了あるいは未
完了を確認できることから未完了の場合には再読み出し
/再書き込みを行なうことにより読み出し/書き込みを
確実にできるという効果が得られる。
(Effects of the Invention) As explained above, according to the present invention, data of one byte or more is transmitted between the CPU and the control circuit that controls communication with the outside via the data line from the control circuit. In the CPU interface method of reading data to the CPU and writing data from the CPU to the control circuit, the CPU outputs a control signal to the control circuit before and after reading/writing data, and connects the data line to the control circuit. The position of the data to be output is initialized, and the control circuit outputs a signal indicating the quality of the read/write result and a signal indicating the presence or absence of a data read request on the data line in synchronization with the control signal. , when reading/writing, the data order, that is, the address, is always initialized, so if you read/write data in the correct order, the location of the data will be clear.
As a result, address lines are no longer required, so the number of connection points can be reduced, the number of CPU ports and the number of control circuit terminals can be saved, and since it is possible to confirm whether a read/write is completed or not, it is possible to confirm whether the read/write is completed or not. By performing rereading/rewriting, it is possible to obtain the effect that reading/writing can be performed reliably.

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

第1図は本発明のCPUのインタフェース方法を説明す
るためのCPUIと制御回路2の接続を示すブロック回
路図、第2図は第1図のCPUIから制御回路2への書
き込みの際の各部のタイミングチャート、第3図は第1
図の制御回路2からCPUへの読み出しの際の各部のタ
イミングチャ−ト、第4図は従来のCPUのインタフェ
ース方法におけるCPUと制御回路との接続を示すブロ
ック回路図、第5図は第4図の各部のタイミングチャー
トである。 1.31・・・cpu、2.32・・・制御回路、3・
・・読み出し/書き込み信号線、4・・・制御信号線、
5・・・読み出し/書き込みクロック信号線、6,35
・・・データ線、33・・・アドレス線、34・・・デ
ータの読み込みタイミング信号線。
FIG. 1 is a block circuit diagram showing the connection between the CPUI and the control circuit 2 to explain the CPU interface method of the present invention, and FIG. Timing chart, Figure 3 is the 1st
A timing chart of each part when reading data from the control circuit 2 to the CPU shown in the figure, FIG. 4 is a block circuit diagram showing the connection between the CPU and the control circuit in the conventional CPU interface method, and FIG. It is a timing chart of each part of a figure. 1.31...cpu, 2.32...control circuit, 3.
...Read/write signal line, 4...Control signal line,
5... Read/write clock signal line, 6, 35
...Data line, 33...Address line, 34...Data read timing signal line.

Claims (1)

【特許請求の範囲】[Claims] CPUと外部との通信を制御する制御回路との間で1バ
イト以上のデータをバイト単位でデータ線を介して前記
制御回路から前記CPUへデータを読み出し、前記CP
Uから前記制御回路へデータを書き込むCPUのインタ
フェース方法において、前記CPUが、データの読み出
し/書き込みの前後に夫々前記制御回路へ制御信号を出
力して前記データ線に入出力する前記データの位置を初
期化し、前記制御回路が、前記制御信号に同期して前記
データ線上に読み出し/書き込み結果の良否を示す信号
及びデータの読み出し要求の有無を示す信号を出力する
ことを特徴とするCPUのインタフェース方法。
Between a control circuit that controls communication between the CPU and the outside, data of one or more bytes is read from the control circuit to the CPU via a data line in byte units, and the data is read out from the control circuit to the CPU via a data line.
In the CPU interface method for writing data from U to the control circuit, the CPU outputs a control signal to the control circuit before and after reading/writing data to determine the position of the data to be input/output to the data line. A method for interfacing a CPU, characterized in that the control circuit outputs a signal indicating the quality of the read/write result and a signal indicating the presence or absence of a data read request on the data line in synchronization with the control signal. .
JP63149093A 1988-06-16 1988-06-16 Method for interfacing with cpu Pending JPH022778A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP63149093A JPH022778A (en) 1988-06-16 1988-06-16 Method for interfacing with cpu

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP63149093A JPH022778A (en) 1988-06-16 1988-06-16 Method for interfacing with cpu

Publications (1)

Publication Number Publication Date
JPH022778A true JPH022778A (en) 1990-01-08

Family

ID=15467543

Family Applications (1)

Application Number Title Priority Date Filing Date
JP63149093A Pending JPH022778A (en) 1988-06-16 1988-06-16 Method for interfacing with cpu

Country Status (1)

Country Link
JP (1) JPH022778A (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS59205849A (en) * 1983-05-09 1984-11-21 Mitsubishi Electric Corp Data transfer system
JPS62260242A (en) * 1986-05-07 1987-11-12 Matsushita Electric Ind Co Ltd Large capacity memory device for continuous data

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS59205849A (en) * 1983-05-09 1984-11-21 Mitsubishi Electric Corp Data transfer system
JPS62260242A (en) * 1986-05-07 1987-11-12 Matsushita Electric Ind Co Ltd Large capacity memory device for continuous data

Similar Documents

Publication Publication Date Title
JPH0331928A (en) Frame converting circuit
JPH022778A (en) Method for interfacing with cpu
JPS63228856A (en) Communication controller
JPS63269233A (en) Error detecting and correcting circuit
JPS583246B2 (en) data processing system
JPS6093855A (en) Data transmission equipment
JPH01187660A (en) Interface diagnosing system for peripheral equipment
JPS62232034A (en) Firmware loading system
JPH0216829A (en) Data reception control system
JPH01158554A (en) Data processing system providing dma device
JPS6273362A (en) Demand transfer circuit
JPH0289300A (en) Semiconductor memory element
JPS6282846A (en) Tracing system for line data
JPH01191966A (en) Data processing system
JPS58222356A (en) Trace device
JPH02250453A (en) Data receiver
JPH05110584A (en) Transmitting system for path trace information in optical synchronous communication
JPS63187943A (en) Communication control equipment
JPH0423034A (en) Data comparison circuit
JPS5916067A (en) Data checking system
JPS5887612A (en) Controlling and diagnosing device for input and output
JPH08335175A (en) Writing / reading method for shared memory
JPS6379140A (en) Digital integrated circuit
JPS6027056B2 (en) Chaining check method
JPS61131048A (en) Memory access controlling system