JPS6226738B2 - - Google Patents

Info

Publication number
JPS6226738B2
JPS6226738B2 JP56177406A JP17740681A JPS6226738B2 JP S6226738 B2 JPS6226738 B2 JP S6226738B2 JP 56177406 A JP56177406 A JP 56177406A JP 17740681 A JP17740681 A JP 17740681A JP S6226738 B2 JPS6226738 B2 JP S6226738B2
Authority
JP
Japan
Prior art keywords
signal
memory
terminal
cpu
gate circuit
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
Application number
JP56177406A
Other languages
Japanese (ja)
Other versions
JPS5880200A (en
Inventor
Hirohisa Mizuhara
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 JP56177406A priority Critical patent/JPS5880200A/en
Publication of JPS5880200A publication Critical patent/JPS5880200A/en
Publication of JPS6226738B2 publication Critical patent/JPS6226738B2/ja
Granted legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring

Description

【発明の詳細な説明】 この発明は、マイクロコンピユータの異常動
作、すなわち暴走時に、そのメモリ回路のメモリ
の内容が破壊されないようメモリの保護を行うメ
モリ保護回路に関するものである。
DETAILED DESCRIPTION OF THE INVENTION The present invention relates to a memory protection circuit that protects a memory so that the contents of the memory circuit are not destroyed when a microcomputer malfunctions or goes out of control.

従来のマイクロコンピユータシステムの要部の
概念図は第1図に示すようなものである。この図
において、1はCPU(中央処理装置)で、アド
レスバス2、データバス3、メモリリード信号
(以下、MEMR信号と称す)4、メモリライト信
号(以下、MEMW信号と称す)5、入出力リー
ド信号(以下、I/QR信号と称す)6、入出力
ライト信号(以下、I/QW信号と称す)7等の
信号を出力し、書込み読出し可能なメモリ8(以
下、RAMメモリと称す)と図のように接続され
ている。9は前記RAMメモリ8のチツプセレク
ト信号(以下、CS信号と称す)で、RAMメモリ
ICが複数個存在する場合に、アドレスバス2の
上位ビツトをデコード(図示せず)してセレクト
する信号である。RAMメモリ8の読出しは、ア
ドレスバス2とCS信号9により該当するメモリ
アドレスを選択し、MEMR信号4を出力する
と、該当メモリアドレスのデータがデータバス3
に出力されてくる。これをCPU1に読み取るこ
とにより行われる。RAMメモリ8の書込みは、
アドレスバス2とCS信号9により該当するメモ
リアドレスを選択し、CPU1よりデータバス3
にデータを出力し、MEMW信号5を出力する
と、データバス3上のデータが該当メモリアドレ
スのメモリに書き込まれることにより行われる。
A conceptual diagram of the main parts of a conventional microcomputer system is shown in FIG. In this figure, 1 is a CPU (central processing unit), address bus 2, data bus 3, memory read signal (hereinafter referred to as MEMR signal) 4, memory write signal (hereinafter referred to as MEMW signal) 5, input/output A read/write memory 8 (hereinafter referred to as RAM memory) that outputs signals such as a read signal (hereinafter referred to as I/QR signal) 6 and an input/output write signal (hereinafter referred to as I/QW signal) 7, etc. and are connected as shown in the figure. 9 is a chip select signal (hereinafter referred to as CS signal) for the RAM memory 8;
This is a signal that decodes (not shown) the upper bits of the address bus 2 and selects them when a plurality of ICs are present. To read the RAM memory 8, select the corresponding memory address using the address bus 2 and the CS signal 9, and output the MEMR signal 4, and the data at the corresponding memory address will be transferred to the data bus 3.
will be output. This is done by reading this into the CPU1. Writing to RAM memory 8 is
The corresponding memory address is selected using address bus 2 and CS signal 9, and data bus 3 is selected from CPU 1.
When data is output to the MEMW signal 5 and the MEMW signal 5 is output, the data on the data bus 3 is written to the memory at the corresponding memory address.

しかるに、上記従来の構成では、CPU1が異
常動作、すなわち暴走動作を起こした場合、前記
メモリ書込み動作により意図しないアドレスに、
意図しないデータが勝手に書き込まれて、メモリ
内容が破壊されてしまう。
However, in the above-mentioned conventional configuration, when the CPU 1 causes an abnormal operation, that is, a runaway operation, the memory write operation writes data to an unintended address.
Unintended data is written without permission and the memory contents are destroyed.

演算や制御のための定数を、RAMメモリ8に
書き込んで、これに基づき演算制御を行うマイク
ロコンピユータシステムで、かかる暴走を生じる
と、復旧時にあらためて定数を書き込まないと再
運転ができないため、復旧手順が非常に煩雑であ
つた。ましてやそのシステムが大規模である場合
は、定数の点数も数百点以上に及ぶことが多く、
再設定に要する時間も相当長時間にわたることが
多かつた。
If such a runaway occurs in a microcomputer system that writes constants for calculations and control into the RAM memory 8 and performs calculation control based on these, it will not be possible to restart the operation unless the constants are written again at the time of recovery, so the recovery procedure was extremely complicated. Furthermore, if the system is large-scale, the number of constant points often reaches several hundred points or more.
The time required for resetting was often quite long.

この発明は、かかる欠点にかんがみてなされた
もので、CPUが暴走を生じても、定数を書き込
むRAMメモリのデータが破壊されないよう構成
されたメモリ保護回路を提供することを目的とす
る。以下、この発明について説明する。
The present invention has been made in view of these drawbacks, and it is an object of the present invention to provide a memory protection circuit configured so that data in a RAM memory in which constants are written will not be destroyed even if the CPU goes out of control. This invention will be explained below.

第2図はこの発明の一実施例を示すもので、イ
ンテル8085A系のマイクロコンピユータシステム
における概略回路図である。この図において、1
0は定数を設定し記憶するRAMメモリである。
これは、CPU(図示せず)とアドレスバス1
1、データバス12、MEMR信号13と接続さ
れ、MEMW信号14はゲート回路15を介して
接続される。このゲート回路15はDフリツプフ
ロツプ16の出力(Q)に接続され、Dフリツプ
フロツプ16のD端子は、運転/設定スイツチ1
7とインバータ回路18に接続される。運転/設
定スイツチ17は、ONのとき設定モード、OFF
のとき運転モードである。また、Dフリツプフロ
ツプ16のT端子は、CPU1のアドレスラツチ
イネイブル信号(以下、ALE信号と称す)19
に接続される。
FIG. 2 shows one embodiment of the present invention, and is a schematic circuit diagram of an Intel 8085A series microcomputer system. In this figure, 1
0 is a RAM memory for setting and storing constants.
This includes the CPU (not shown) and address bus 1.
1, a data bus 12, and a MEMR signal 13, and a MEMW signal 14 is connected via a gate circuit 15. This gate circuit 15 is connected to the output (Q) of the D flip-flop 16, and the D terminal of the D flip-flop 16 is connected to the operation/setting switch 1.
7 and an inverter circuit 18. The operation/setting switch 17 is set to setting mode when ON, and OFF.
It is in operation mode when . Further, the T terminal of the D flip-flop 16 is connected to the address latch enable signal (hereinafter referred to as ALE signal) 19 of the CPU 1.
connected to.

定数の設定を行う際には、運転/設定スイツチ
17を設定モード、すなわちONにする。する
と、Dフリツプフロツプ16のD端子は“H”レ
ベルとなるため、ALE信号19によりT端子が
トリガされると、その出力Qは“H”レベルとな
り、ゲート回路15は開状態となる。ここで定数
を記憶するメモリアドレスをアドレスバス11に
出力し、記憶したN定数のデータをデータバス1
2に出力してMEMW信号14を出力すると、こ
の出力信号はゲート回路15を通過してRAMメ
モリ10に到達し、前記データを該当するアドレ
スに書き込む。ALE信号19は命令のマシンサ
イクルの先頭にある信号であるため、前記の動作
手順を円滑に行うことができる。
When setting constants, the operation/setting switch 17 is set to the setting mode, that is, turned ON. Then, the D terminal of the D flip-flop 16 becomes "H" level, so when the T terminal is triggered by the ALE signal 19, its output Q becomes "H" level, and the gate circuit 15 becomes open. Here, the memory address for storing the constant is output to the address bus 11, and the data of the stored N constants is output to the data bus 11.
2 and outputs the MEMW signal 14, this output signal passes through the gate circuit 15 and reaches the RAM memory 10, where the data is written to the corresponding address. Since the ALE signal 19 is a signal at the beginning of the instruction machine cycle, the above-described operation procedure can be performed smoothly.

この場合、命令の最初の信号であるALE信号
19により運転/設定スイツチ17の状態をラツ
チし、これによりゲート回路15を開状態にする
ので、CPUの動作中に運転/設定スイツチ17
を切り換えると、切り換えた時のスイツチ動作は
有効ではなく、切り換えた状態から最初に来る
ALE信号19でその状態がフリツプフロツプ1
6でラツチされ、それ以降切り換えた状態が有効
になる。このため、中途半端なメモリ書込み信号
が出力されることがない。
In this case, the state of the run/setting switch 17 is latched by the ALE signal 19, which is the first signal of the command, and the gate circuit 15 is thereby opened.
If you switch, the switch operation at the time of switching will not be valid, but will start from the switched state.
ALE signal 19 indicates the state of flip-flop 1.
It is latched at 6, and the switched state becomes valid from then on. Therefore, a half-finished memory write signal is never output.

設定動作を行わないときは、運転/設定スイツ
チ17を運転モード、すなわちOFFとする。す
るとDフリツプフロツプ16のD端子は“L”レ
ベルとなるため、ALE信号19によりT端子が
トリガされると、その出力Qは“L”レベルとな
り、ゲート回路15は閉状態となる。したがつ
て、MEMW信号14はゲート回路15で阻止さ
れて、RAMメモリ10に到達しない。このた
め、データの書込みはできない。しかしながら、
MEMR信号13には、かかる回路は設けられて
いないために、運転/設定スイツチ17のモード
にかかわりなく自由に読出しが行える。
When the setting operation is not performed, the operation/setting switch 17 is set to the operation mode, that is, OFF. Then, the D terminal of the D flip-flop 16 becomes "L" level, so when the T terminal is triggered by the ALE signal 19, its output Q becomes "L" level, and the gate circuit 15 is closed. Therefore, the MEMW signal 14 is blocked by the gate circuit 15 and does not reach the RAM memory 10. Therefore, data cannot be written. however,
Since the MEMR signal 13 is not provided with such a circuit, it can be read freely regardless of the mode of the operation/setting switch 17.

ここで、運転モードのときにCPUが暴走する
と、MEMW信号14は前記のようにゲート回路
15で阻止されるから、意図しないアドレスに、
意図しないデータが書き込まれてメモリ内容にい
たることはない。
Here, if the CPU goes out of control during the operation mode, the MEMW signal 14 is blocked by the gate circuit 15 as described above, so that it is sent to an unintended address.
Unintended data will not be written to the memory contents.

もちろん、設定モードのときにCPUが暴走し
た場合は、MEMW信号14がゲート回路15を
通過するから、この場合はメモリ内容が破壊され
ることがあるが、通常、定数をひんぱんに設定変
更することは少なく、したがつて、設定中に
CPUが暴走する確率は極めて少ない。したがつ
て、暴走によりメモリ内容が破壊される確率は、
従来に比して極めて少なくなる。
Of course, if the CPU goes out of control while in the setting mode, the MEMW signal 14 will pass through the gate circuit 15, so in this case the memory contents may be destroyed, but normally the constant settings should be changed frequently. is small and therefore during configuration
The probability that the CPU will run out of control is extremely low. Therefore, the probability that memory contents will be destroyed due to runaway is:
This is significantly less than before.

なお、この発明は、インテル8085系、モトロー
ラ6800系、RCACD1800系等の他のマイクロコン
ピユータシステムでも同様に行うことが可能であ
る。
Note that the present invention can be similarly carried out with other microcomputer systems such as the Intel 8085 series, Motorola 6800 series, and RCACD1800 series.

以上詳細に説明したように、この発明は、設定
可能信号の発生手段と、前記設定可能信号の印加
により開きメモ書込み信号を通過させるゲート回
路と、前記メモリ書込み信号がメモリ書込み端子
に加えられたとき、書込み可能となる読出し書込
み可能メモリとで構成したので、メモリに記憶し
た定数データが、CPUの暴走により破壊される
確率を極めて少なくでき、従来の欠点を大幅に除
去できる効果を有するものである。
As described above in detail, the present invention includes a settable signal generating means, a gate circuit that opens upon application of the settable signal and allows a memo write signal to pass through, and a gate circuit that allows the memory write signal to be applied to a memory write terminal. Since it is constructed with a read/write memory that can be written to when the CPU is running, the probability that the constant data stored in the memory will be destroyed due to CPU runaway is extremely reduced, and the drawbacks of the conventional technology can be largely eliminated. be.

そして、設定可能信号の発生手段を、運転/設
定スイツチと、この運転/設定スイツチがD入力
端子に接続され、CPUのアドレスラツチイネイ
ブル信号がT端子に接続され、Q端子がゲート回
路に接続されるDフリツプフロツプとで構成した
ので、CPUの動作中に運転/設定スイツチを切
り換えても、切り換えた時のスイツチ動作は有効
でなく、それ以降切り換えた状態が有効になり、
そのため中途半端なメモリ書込み信号が出力され
ることがない利点がある。
The means for generating the settable signal is connected to a run/setting switch, this running/setting switch is connected to the D input terminal, the CPU's address latch enable signal is connected to the T terminal, and the Q terminal is connected to the gate circuit. Since the CPU is configured with a D flip-flop, even if the operation/setting switch is switched while the CPU is operating, the switch operation at the time of switching will not be valid, and the switched state will become effective from then on.
Therefore, there is an advantage that a half-finished memory write signal is not output.

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

第1図は従来のマイクロコンピユータシステム
の主要部の概念図、第2図はこの発明の一実施例
の概略回路図である。 図中、10はRAMメモリ、11はアドレスバ
ス、12はデータバス、13はMEMR信号、1
4はMEMW信号、15はゲート回路、16はD
フリツプフロツプ、17は運転/設定スイツチ、
18はインバータ回路、19はALE信号であ
る。
FIG. 1 is a conceptual diagram of the main parts of a conventional microcomputer system, and FIG. 2 is a schematic circuit diagram of an embodiment of the present invention. In the figure, 10 is a RAM memory, 11 is an address bus, 12 is a data bus, 13 is an MEMR signal, 1
4 is MEMW signal, 15 is gate circuit, 16 is D
Flip-flop, 17 is operation/setting switch,
18 is an inverter circuit, and 19 is an ALE signal.

Claims (1)

【特許請求の範囲】[Claims] 1 設定可能信号の発生手段と、前記設定可能信
号の印加により開きメモリ書込み信号を通過させ
るゲート回路と、前記メモリ書込み信号がメモリ
書込み端子に加えられたとき、書込み可能となる
読出し書込み可能メモリとからなり、さらに、前
記設定可能信号の発生手段を、運転/設定スイツ
チと、この運転/設定スイツチがD入力端子に接
続され、CPUのアドレスラツチイネイブル信号
がT端子に接続され、Q端子がゲート回路に接続
されるDフリツプフロツプとで構成したことを特
徴とするメモリ保護回路。
1 A means for generating a settable signal, a gate circuit that opens upon application of the settable signal and allows a memory write signal to pass through, and a readable and writable memory that becomes writable when the memory write signal is applied to a memory write terminal. Further, the generating means for the settable signal is connected to a run/setting switch, the run/setting switch is connected to the D input terminal, the address latch enable signal of the CPU is connected to the T terminal, and the Q terminal is connected to the D input terminal. A memory protection circuit comprising a D flip-flop connected to a gate circuit.
JP56177406A 1981-11-04 1981-11-04 Memory protecting circuit Granted JPS5880200A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP56177406A JPS5880200A (en) 1981-11-04 1981-11-04 Memory protecting circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP56177406A JPS5880200A (en) 1981-11-04 1981-11-04 Memory protecting circuit

Publications (2)

Publication Number Publication Date
JPS5880200A JPS5880200A (en) 1983-05-14
JPS6226738B2 true JPS6226738B2 (en) 1987-06-10

Family

ID=16030369

Family Applications (1)

Application Number Title Priority Date Filing Date
JP56177406A Granted JPS5880200A (en) 1981-11-04 1981-11-04 Memory protecting circuit

Country Status (1)

Country Link
JP (1) JPS5880200A (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6266301U (en) * 1985-10-14 1987-04-24
JPS62138258U (en) * 1986-02-26 1987-08-31

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5297032U (en) * 1976-01-19 1977-07-20
JPS5379417A (en) * 1976-12-24 1978-07-13 Nec Corp Protection system for memory content

Also Published As

Publication number Publication date
JPS5880200A (en) 1983-05-14

Similar Documents

Publication Publication Date Title
JPS6122828B2 (en)
GB888732A (en)
US4460972A (en) Single chip microcomputer selectively operable in response to instructions stored on the computer chip or in response to instructions stored external to the chip
JPS61182160A (en) Data processing device
US4649476A (en) Microcomputer having an internal address mapper
JPS6042966B2 (en) data processing system
JPS6226738B2 (en)
JPS6362778B2 (en)
JPS595496A (en) Memory protect system
JPS62286143A (en) Semiconductor memory device
JPH01232452A (en) One-chip processor
JPH0227596A (en) Semiconductor memory
JPS6140652A (en) Method and circuit for write protection of memory
JPS60193046A (en) Detecting system for instruction exception
JP2619671B2 (en) Memory control circuit
JPS6117474Y2 (en)
JPS60112148A (en) Memory device
JPS6320631A (en) Register selecting system
JPH06139084A (en) Information processor
JPS6280744A (en) Control circuit for ram
JPH064469A (en) Input/output device control system
JPS63156261A (en) Decision system for memory access condition
JPS62160555A (en) Storage protecting device of storage circuit
JPH03273349A (en) Access control system
JPH0512175A (en) Peripheral controller