JP4352584B2 - Memory circuit device - Google Patents

Memory circuit device Download PDF

Info

Publication number
JP4352584B2
JP4352584B2 JP2000156903A JP2000156903A JP4352584B2 JP 4352584 B2 JP4352584 B2 JP 4352584B2 JP 2000156903 A JP2000156903 A JP 2000156903A JP 2000156903 A JP2000156903 A JP 2000156903A JP 4352584 B2 JP4352584 B2 JP 4352584B2
Authority
JP
Japan
Prior art keywords
data
circuit unit
cpu
information data
memory
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2000156903A
Other languages
Japanese (ja)
Other versions
JP2001337866A (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.)
Denso Corp
Original Assignee
Denso 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 Denso Corp filed Critical Denso Corp
Priority to JP2000156903A priority Critical patent/JP4352584B2/en
Publication of JP2001337866A publication Critical patent/JP2001337866A/en
Application granted granted Critical
Publication of JP4352584B2 publication Critical patent/JP4352584B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • For Increasing The Reliability Of Semiconductor Memories (AREA)
  • Detection And Correction Of Errors (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Description

【0001】
【発明の属する技術分野】
本発明は、CPUにより一定のデータバスサイズでアクセスが行われる記憶回路装置であって、記憶されているデータが読み出される場合に訂正可能な誤りを検出すると、その誤りの訂正を行う誤り訂正回路部を備えたものに関する。
【0002】
【従来の技術】
例えば、CPUがDRAMなどのメモリに記憶されているデータを読み出すメモリシステムにおいては、DRAMのメモリセルにα線が入射することによってランダムにエラー(所謂ソフトエラー)が発生する可能性がある。そこで、斯様なメモリシステムに高い信頼性が要求される場合には、ECC(Error Chcking and Correcting)回路を付加する場合がある。
【0003】
ECC回路は、CPUがメモリからデータを読み出す場合にそれらのデータビットの一定の組合せについて排他的論理和をとることで複数の検査データ(シンドロームビット)を生成する。生成されたシンドロームビットは、メモリの前記データと同じアドレスに記憶される。
【0004】
そして、CPUがメモリからデータ(情報データと称す)を読み出す場合には、該情報データに対応して生成された検査データも同時に読み出される。この時、ECC回路は、読み出された情報データと検査データからエラーコードを生成し、そのエラーコードの値に基づいて該情報データに誤りがあるか否かを検出する。そして、訂正可能である1ビット誤りを検出するとその誤りの訂正を行う。また、読み出したデータに2ビット以上の誤りが生じていることを検出することもできる。
【0005】
【発明が解決しようとする課題】
ところで、以上述べたようなECC機能をメモリシステムに付加する場合には、検査データを記憶させるためにメモリの容量を余分に必要とすることになる。例えば、16ビット(2バイト)の情報データバスサイズについて検査データが5ビットで生成される場合には、データバスサイズが32ビット(4バイト)になると検査データは6ビットで生成される。従って、容量の増加によってシステムが大型化し、コストアップしてしまうという問題があった。
【0006】
本発明は上記事情に鑑みてなされたものであり、その目的は、誤り訂正回路部を設ける場合に、記憶回路部の容量の増加を抑制することができる記憶回路装置を提供することにある。
【0007】
【課題を解決するための手段】
請求項1記載の記憶回路装置によれば、記憶回路部を、CPUがアクセスを行う場合のデータバスサイズに対して複数倍のバスサイズによってアクセスが行われるように構成し、この記憶回路部について誤り訂正を行う誤り訂正回路部を備える。そして、アクセス制御部は、CPUが記憶回路部より情報データを読み出そうとする場合に、そのデータを含む複数倍のバスサイズで記憶回路部より情報データを読み出し、それらの情報データからCPUが読み出そうとしているデータを選択してCPUのデータバス上に出力する。また、アクセス制御部は、誤り訂正回路部によるデータの訂正処理が完了するまで、CPUに対して出力するアクノリッジ信号のタイミングを遅延させる。
【0008】
即ち、誤り訂正回路部によって生成される検査データのビット数は、情報データ(実際に必要とされる、検査データ以外のデータを称す)のビット数が倍になると1ビット増加するため、同一の情報データ容量について生成される検査データのビット数は、書込み及び読み出しを行うデータバスサイズが増加する程トータルで減少する。
【0009】
例えば、情報データのバスサイズが1バイト(B)であり、ワード数をWとするとその容量はB×Wとなる。ここで、誤り訂正回路部が1バイトについて生成する検査データのビット数がsであるとすると、検査データに必要な容量は、s×Wとなる。そして、情報データのバスサイズを2バイト(xは自然数)とするとワード数はW/2となり、検査データに必要なビット数は“x”増加するので、検査データに必要な容量は(s+x)×W/2となる。
【0010】
この場合、分子にはWの係数にxが加算されるのに対して分母は2のx乗で増加するので、検査データに必要な容量は確実に減少する。従って、請求項1のように構成することにより、誤り訂正回路部を備えて記憶回路部に記憶される情報データに対する信頼性の向上を図る場合でも、記憶回路部に必要な容量を従来よりも減少させ、回路面積を縮小して全体を小型に構成することができ、製造コストを削減することが可能となる。
【0011】
請求項2記載の記憶回路装置によれば、アクセス制御部は、CPUが記憶回路部に情報データを新たに書き込もうとする場合には、CPUがデータバス上に出力する情報データを保持する。そして、記憶回路部のデータバスサイズに等しい情報データが保持されると、該情報データと誤り訂正回路部によって生成される検査データとを記憶回路部に記憶させる。
【0012】
即ち、CPUが、情報データが全く記憶されていない状態にある記憶回路部に対して情報データを新たに書き込もうとする場合、アクセス制御部は、CPUがデータバス上に出力する情報データを1アドレス毎に保持する。そして、記憶回路部のデータバスサイズに等しい情報データが保持されれば、誤り訂正回路部によって対応する検査データが生成されるので、CPUと記憶回路部とのデータバスサイズが異なる場合であっても、情報データと検査データとを記憶回路部に記憶させることができる。
【0013】
請求項3記載の記憶回路装置によれば、アクセス制御部は、CPUが記憶回路部に記憶されている情報データを書き直そうとする場合にリードモディファイライトサイクルを実行する。即ち、CPUが書き直そうとするデータ部分を含むアドレスを以て記憶回路部より情報データを一旦読み出し、CPUが出力したデータ部分を入れ替えることによって、誤り訂正回路部は必要なデータバスサイズに対する検査データを生成することができる。
【0014】
請求項4記載の記憶回路装置によれば、記憶回路部をフラッシュメモリで構成する。従来、誤り訂正機能はDRAMのようなメモリの信頼性を向上させるために付加されることが一般的である。フラッシュメモリは、近年、CPUのプログラムメモリとして使用される場合が多く、その場合、開発段階などにおいて比較的高い頻度で書き換えが行われる。すると、各セルトランジスタのしきい値電圧VT にばらつきが生じるおそれがあり、そのばらつきが生じることによってデータに誤りが発生する可能性が出てくる。従って、記憶回路部をフラッシュメモリで構成する場合にも誤り訂正回路部を付加することで、信頼性を向上させることが有効となる。
【0015】
請求項5記載の記憶回路装置によれば、記憶回路部と、誤り訂正回路部と、アクセス制御部とを同一の半導体基板上に形成する。即ち、誤り訂正回路部やアクセス制御部が記憶回路部と共に内蔵されたワンチップのICとして構成されるようになり、その外部において接続されるCPUは、記憶回路装置を通常のメモリと同様に扱うことが可能となる。従って、機能を付加したことによる回路面積の増大を極力抑制することができる。
【0016】
【発明の実施の形態】
以下、本発明の一実施例について図面を参照して説明する。図1は、記憶回路装置の電気的構成を示す機能ブロック図である。記憶回路装置1は、フラッシュメモリ(記憶回路部)2,ECC回路部(誤り訂正回路部)3,コントローラ (アクセス制御部)4,読出し用のバッファ(以下、Rバッファと称す,アクセス制御部)5U,5L及び書込み用のラッチ(以下、Wラッチと称す,アクセス制御部)6U,6Lを備えており、これらが同一の半導体基板上に形成されてワンチップのICとして構成されている。
【0017】
また、記憶回路装置1の外部にはCPU7が接続されている。CPU7のデータバスサイズは8ビットであり、その8ビットのデータバス(D7〜D0)が記憶回路装置1に接続されている。
【0018】
フラッシュメモリ2は、書き換え可能な不揮発性の記憶手段であり、ブロック単位でのデータ消去とページ単位でのデータの書き換みが可能となっている。フラッシュメモリ2の容量は、情報データの記憶領域として16ビット×64ワード構成の1kビットを有していると共に、情報データの値に基づいてECC回路部3により生成される5ビットの検査データの記憶領域として、5ビット×64ワード構成の320ビットを有している。また、フラッシュメモリ2は、CPUより出力されるアドレスに基づいて行列状に配置されているメモリセルを選択するための行選択回路2L及び列選択回路2Cを備えている。
【0019】
ここで、1kビットを8ビット(1バイト)×128ワード構成としてアドレスを割り付けるとA6〜A0(127〜0)の7ビットとなる。これに対して、フラッシュメモリ2のデータバスサイズは16ビット(2バイト)であるから、フラッシュメモリ2にはアドレスの上位6ビット(A6〜A1)が与えられている。
【0020】
尚、フラッシュメモリ2には、CPU7の制御プログラムが情報データとしてWラッチ6U,6Lを介してCPU7により予め書き込まれている。即ち、コントローラ4は、Wラッチ6U,6Lにラッチ信号やイネーブル信号を出力することで、CPU7がA0=0のアドレスに書き込む情報データを出力した場合には、その8ビットデータをWラッチ6Lによりラッチさせ、A0=1のアドレスに書き込む情報データを出力した場合には、その8ビットデータをWラッチ6Uによりラッチさせる。それから、これらのWラッチ6U,6LをイネーブルにしてECC回路部3に5ビットの検査用データを生成させて情報データと検査データとをフラッシュメモリ2に同時に書き込ませる。
そして、CPU7はフラッシュメモリ2に記憶されている制御プログラムを読み出して実行することで、図示しない外部装置の制御を行うようになっている。
【0021】
Rバッファ5U,5Lは、8ビット構成であり、CPU7がフラッシュメモリ2から情報データを読み出す場合に、CPU7の8ビットデータバス上に出力するデータを選択するために使用される(詳細は後述する)。即ち、Rバッファ5Uの入力側はフラッシュメモリ2の16ビットデータバスの上位側(D15〜D8)に接続されており、Rバッファ5Lの入力側は同データバスの下位側(D7〜D0)に接続されている。そして、Rバッファ5U,5Lの出力側は、CPU7の8ビットデータバス(D7〜D0)に接続されている。
【0022】
コントローラ4は、CPU7によってフラッシュメモリ2より情報データが読み出される場合に、その情報データと共に検査データをフラッシュメモリ2から読み出す。そして、ECC回路部3は、読み出された情報データと検査データからエラーコードを生成すると、該情報データに誤りがあるか否かを検出する。即ち、エラーコードの値が“0”であれば情報データに誤りはない。エラーコードが“0”以外であり、予め定義されているエラーコードと一致する場合は情報データに1ビットの誤り(1ビットエラー)が生じており、また、前記エラーコードと一致しない場合は情報データに2ビット以上の誤り(2ビットエラー)が生じていることになる。
【0023】
そして、ECC回路部3は、以上のようにして1ビットエラーを検出すると、その誤りの訂正処理(ビット値の反転)を行う。また、2ビットエラーについては検出のみが可能である。
【0024】
コントローラ4には、CPU7が出力するアドレスや各種の制御信号が与えられており、フラッシュメモリ2やECC回路部3に制御信号を出力したり、Rバッファ5U,5Lに対してイネーブル信号を出力する。また、CPU7が記憶回路装置1に対してリードサイクルを行った場合に、適当なタイミングでアクノリッジ信号(ACK)を出力するようになっている。
【0025】
また、コントローラ4には、ECC回路部3からの1ビットエラー検出信号ERR1が与えられており、情報データに1ビットエラーが検出された場合には、ECC回路部3によるデータの訂正処理が完了するまで、アクノリッジ信号の出力タイミングを遅延させるようになっている。
【0026】
次に、本実施例の作用について説明する。CPU7が、記憶回路装置1に対してリードサイクルを行う場合、そのサイクルは以下のように進行する。但し、実際に使用される全ての信号について言及しているわけではなく、本発明の要旨に係る部分についてのみ説明する。
【0027】
<情報データに誤りが無い場合>
▲1▼CPU7が、アドレスA6〜A0を出力してリードサイクルを開始すると、コントローラ4はそのアドレスをデコードして記憶回路装置1に対するリードアクセスであると判定する。そして、フラッシュメモリ2に読み出し制御信号(Chip Enable,Output Enable など)を出力する。
【0028】
▲2▼すると、フラッシュメモリ2からは、アドレスの上位6ビット(A6〜A1)が与えられて16ビットの情報データが読み出される。
▲3▼ECC回路部3は、フラッシュメモリ2から読み出された16ビットの情報データと5ビットの検査データとに基づいて誤り検出を行う。
【0029】
▲4▼コントローラ4は、ECC回路部3が所定期間内に1ビットエラー検出信号ERR1を出力しなければ、アドレスA0の値に応じてRバッファ5U,5Lの何れか一方にイネーブル信号を出力する。即ち、CPU7のアクセスアドレスが××××××0(バイナリ)であれば、Rバッファ5Lがイネーブルとなってフラッシュメモリ2のデータバスの下位側(D7〜D0)のデータがCPU7の8ビットデータバスに出力される。また、アクセスアドレスが××××××1であれば、Rバッファ5Uがイネーブルとなってフラッシュメモリ2のデータバスの上位側(D15〜D8)のデータがCPU7の8ビットデータバスに出力される。
【0030】
▲5▼続いて、コントローラ4は、CPU7に対してアクノリッジ信号を出力する。CPU7は、アクノリッジ信号を認識すると記憶回路装置1より読み出されたデータをラッチして読み込む。そして、アドレスの出力を停止してリードサイクルを終了する。
【0031】
<情報データに誤りがある場合>
▲1▼〜▲3▼までは、誤りが無い場合と同様であり、▲4▼において、ECC回路部3が所定期間内に1ビットエラー検出信号ERR1を出力する。それから、ECC回路部3は1ビットエラーが発生しているデータ値を訂正する。そして、コントローラ4は、▲5▼において、CPU7に対してアクノリッジ信号を出力するタイミングをECC回路部3が誤り訂正を行う時間分だけ遅延させて出力する。
【0032】
尚、以上において、ECC回路部3の動作は周知のものであり、誤り検出や誤り訂正のタイミングチャートなどは、ECC用ICのデータシートなどに開示されているものと代わることがない。
【0033】
ここで、フラッシュメモリ2において検査データを記憶させるために必要な容量は、ビット数5に対してワード数64であるから、5×64=320ビットである。また、従来のように、CPU7のデータバスサイズ8ビットに対して、記憶回路部のデータバスサイズを同一の8ビットとした場合には、ビット数4に対してワード数128であるから4×128=512ビットが必要である。
【0034】
従って、トータルでの容量削減率は、
(1024+320)/(1024+512)
=1344/1536=12.5(%)
となる。即ち、フラッシュメモリ2の容量は約12.5%削減されていることになる。
【0035】
以上のように本実施例によれば、フラッシュメモリ2を、CPU7のデータバスサイズ8ビットに対して16ビットでアクセスが行われるように構成し、コントローラ4は、CPU7がフラッシュメモリ2よりデータを読み出そうとする場合に、16ビットでフラッシュメモリ2よりデータを読み出し、それらのデータからCPU7が読み出そうとしているデータを選択してCPU7のデータバス上に出力するようにした。また、上記16ビットの情報データに対応する5ビットの検査データをもフラッシュメモリ2より読み出して、情報データに1ビットエラーが発生している場合にはECC回路部3に訂正させるようにした。
【0036】
従って、ECC回路部3を備えてフラッシュメモリ2に記憶される情報データに対する信頼性の向上を図る場合でも、フラッシュメモリ2に必要な容量を従来よりも減少させて、回路面積を縮小して全体を小型に構成することができ、製造コストを削減することが可能となる。また、フラッシュメモリ2に対して高い頻度で書込みが行われたり、或いは、大容量化の影響によって信頼性が低下するおそれがある場合に、ECC回路部3を付加することで、信頼性を向上させることが可能となる。
【0037】
また、本実施例によれば、コントローラ4は、CPU7がフラッシュメモリ2に情報データを予め書き込む場合に、CPU7がデータバス上に出力する情報データをWラッチ6U,6Lによって保持し、ECC回路部3によって生成される検査データと共にフラッシュメモリ2に記憶させるので、CPU7とフラッシュメモリ2とのデータバスサイズが異なる場合であっても、情報データと検査データとをフラッシュメモリ2に記憶させることができる。
【0038】
更に、本実施例によれば、記憶回路装置1を構成するフラッシュメモリ2,ECC回路部3,コントローラ4,Rバッファ5及びWラッチ6を同一の半導体基板上に形成したので、その外部に接続されるCPU7は、記憶回路装置1を通常のメモリと同様に扱うことが可能となる。そして、機能を付加したことによる回路面積の増大を極力抑制することができる。
【0039】
本発明は上記し且つ図面に記載した実施例にのみ限定されるものではなく、次のような変形または拡張が可能である。
CPU7と記憶回路装置1とを、同一の半導体基板上に形成することで、ワンチップの制御用LSIを構成しても良い。
記憶回路装置は、各構成部を同一の半導体基板上に形成するものに限らず、夫々をディスクリートのICで通常の回路基板(プリント基板など)上に構成しても良い。また、この時、記憶回路部がフラッシュメモリで構成され、ソケットなどを使用することでフラッシュメモリが回路基板より着脱可能に構成される場合には、フラッシュメモリに対する情報データ及び検査データの書込みをROMライタで行っても良い。その場合、書込み用のWラッチ6U,6Lに相当する構成は不要となる
【0040】
データバスサイズは上記実施例に限らず、例えば、CPU7のバスサイズが16ビットである場合に、フラッシュメモリ2のバスサイズを32ビットにするなどしても良い。
フラッシュメモリ2は、フラッシュメモリ2に限らず、EEPROMやDRAMでも良い。また、DRAMを用いた場合のように、CPUが記憶回路部のデータを書き直すことがある場合は、データの書込み時にはリードモディファイライトサイクルを行い16ビットデータを読み出して、その何れか一方の8ビットデータをCPUが出力したデータに入れ替えた状態で新たな検査データを生成し、記憶回路部に書き戻すようにすれば良い。
また、リードサイクル時に1ビットエラーを検出した場合にもリードモディファイライトサイクルを行うことで、訂正したデータ値を書き戻すようにしても良い。
ECC回路部3によって出力される1ビットエラーや2ビットエラーの検出信号をCPU7に与えて、これらのエラーが発生する頻度が一定以上に高くなった場合に、外部に報知する手段(例えば、LED)を設けて、記憶回路装置1、或いはフラッシュメモリ2またはそれに相当する記憶回路部の交換をユーザに促すようにしても良い。
【図面の簡単な説明】
【図1】本発明の一実施例であり、記憶回路装置の電気的構成を示す機能ブロック図
【符号の説明】
1は記憶回路装置、2はフラッシュメモリ(記憶回路部)、3はECC回路部(誤り訂正回路部)、4はコントローラ(アクセス制御部)、5U,5Lはバッファ(アクセス制御部)、6U,6Lはラッチ(アクセス制御部)、7はCPUを示す。
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a storage circuit device that is accessed by a CPU with a constant data bus size, and an error correction circuit that corrects an error when a correctable error is detected when the stored data is read. It relates to what has a part.
[0002]
[Prior art]
For example, in a memory system in which the CPU reads data stored in a memory such as a DRAM, there is a possibility that an error (so-called soft error) may randomly occur when α rays are incident on a memory cell of the DRAM. Therefore, when high reliability is required for such a memory system, an ECC (Error Chcking and Correcting) circuit may be added.
[0003]
When the CPU reads data from the memory, the ECC circuit generates a plurality of test data (syndrome bits) by taking an exclusive OR with respect to a certain combination of these data bits. The generated syndrome bits are stored at the same address as the data in the memory.
[0004]
When the CPU reads data (referred to as information data) from the memory, the inspection data generated corresponding to the information data is also read at the same time. At this time, the ECC circuit generates an error code from the read information data and inspection data, and detects whether or not there is an error in the information data based on the value of the error code. When a 1-bit error that can be corrected is detected, the error is corrected. It is also possible to detect that an error of 2 bits or more has occurred in the read data.
[0005]
[Problems to be solved by the invention]
By the way, when the ECC function as described above is added to the memory system, an extra memory capacity is required to store the inspection data. For example, when the inspection data is generated with 5 bits for the information data bus size of 16 bits (2 bytes), the inspection data is generated with 6 bits when the data bus size is 32 bits (4 bytes). Therefore, there is a problem that the system becomes larger due to the increase in capacity and the cost is increased.
[0006]
The present invention has been made in view of the above circumstances, and an object thereof is to provide a memory circuit device capable of suppressing an increase in the capacity of the memory circuit unit when an error correction circuit unit is provided.
[0007]
[Means for Solving the Problems]
According to the memory circuit device of the first aspect, the memory circuit unit is configured to be accessed with a bus size that is a multiple of the data bus size when the CPU accesses the memory circuit unit. An error correction circuit unit for performing error correction is provided. When the CPU tries to read the information data from the storage circuit unit, the access control unit reads the information data from the storage circuit unit with a multiple bus size including the data. The data to be read is selected and output on the data bus of the CPU. Further, the access control unit delays the timing of the acknowledge signal output to the CPU until the data correction processing by the error correction circuit unit is completed.
[0008]
That is, the number of bits of inspection data generated by the error correction circuit unit increases by one bit when the number of bits of information data (referred to as data other than inspection data actually required) is doubled. The number of bits of inspection data generated for the information data capacity decreases as the data bus size for writing and reading increases.
[0009]
For example, if the bus size of the information data is 1 byte (B) and the number of words is W, the capacity is B × W. Here, if the number of bits of inspection data generated by the error correction circuit unit for one byte is s, the capacity required for the inspection data is s × W. If the bus size of the information data is 2 x bytes (x is a natural number), the number of words becomes W / 2 x , and the number of bits required for the inspection data increases by “x”, so the capacity required for the inspection data is ( s + x) × W / 2 x .
[0010]
In this case, x is added to the coefficient of W in the numerator, whereas the denominator increases by 2 to the power of x, so that the capacity required for the inspection data is definitely reduced. Therefore, by configuring as in the first aspect, even when the error correction circuit unit is provided and the reliability of the information data stored in the storage circuit unit is improved, the capacity required for the storage circuit unit can be increased compared to the conventional case. Thus, the circuit area can be reduced and the whole can be made compact, and the manufacturing cost can be reduced.
[0011]
According to the memory circuit device of the second aspect, the access control unit holds the information data that the CPU outputs on the data bus when the CPU intends to newly write information data to the memory circuit unit. When information data equal to the data bus size of the storage circuit unit is held, the information data and the inspection data generated by the error correction circuit unit are stored in the storage circuit unit.
[0012]
That is, when the CPU tries to write new information data to the storage circuit unit in which no information data is stored, the access control unit reads the information data output by the CPU on the data bus by one address. Hold every time. If the information data equal to the data bus size of the storage circuit unit is held, the corresponding inspection data is generated by the error correction circuit unit, so that the data bus size between the CPU and the storage circuit unit is different. In addition, the information data and the inspection data can be stored in the storage circuit unit.
[0013]
According to the storage circuit device of the third aspect, the access control unit executes the read-modify-write cycle when the CPU tries to rewrite the information data stored in the storage circuit unit. That is, once the information data is read from the storage circuit unit with an address including the data portion to be rewritten by the CPU, and the data portion output by the CPU is replaced, the error correction circuit unit obtains the inspection data for the required data bus size. Can be generated.
[0014]
According to the memory circuit device of the fourth aspect, the memory circuit unit is constituted by the flash memory. Conventionally, an error correction function is generally added to improve the reliability of a memory such as a DRAM. In recent years, a flash memory is often used as a program memory of a CPU, and in that case, rewriting is performed at a relatively high frequency in a development stage or the like. Then, there is a possibility that the threshold voltage VT of each cell transistor may vary, and there is a possibility that an error occurs in the data due to the variation. Therefore, it is effective to improve the reliability by adding an error correction circuit unit even when the memory circuit unit is constituted by a flash memory.
[0015]
According to the memory circuit device of the fifth aspect, the memory circuit unit, the error correction circuit unit, and the access control unit are formed on the same semiconductor substrate. In other words, an error correction circuit unit and an access control unit are configured as a one-chip IC with a built-in memory circuit unit, and the CPU connected outside the memory handles the memory circuit device in the same way as a normal memory. It becomes possible. Therefore, an increase in circuit area due to the addition of the function can be suppressed as much as possible.
[0016]
DETAILED DESCRIPTION OF THE INVENTION
An embodiment of the present invention will be described below with reference to the drawings. FIG. 1 is a functional block diagram showing an electrical configuration of the memory circuit device. The memory circuit device 1 includes a flash memory (memory circuit unit) 2, an ECC circuit unit (error correction circuit unit) 3, a controller (access control unit) 4, a read buffer (hereinafter referred to as an R buffer, access control unit) 5U and 5L and write latches (hereinafter referred to as W latches, access control units) 6U and 6L are formed on the same semiconductor substrate and configured as a one-chip IC.
[0017]
A CPU 7 is connected to the outside of the memory circuit device 1. The data bus size of the CPU 7 is 8 bits, and the 8-bit data bus (D 7 to D 0) is connected to the memory circuit device 1.
[0018]
The flash memory 2 is a rewritable nonvolatile storage means that can erase data in units of blocks and rewrite data in units of pages. The capacity of the flash memory 2 has 1 k bits of 16 bits × 64 words as a storage area for information data, and 5 bits of test data generated by the ECC circuit unit 3 based on the value of the information data. The storage area has 320 bits of 5 bits × 64 words. The flash memory 2 includes a row selection circuit 2L and a column selection circuit 2C for selecting memory cells arranged in a matrix based on addresses output from the CPU.
[0019]
Here, if 1k bits are assigned as 8 bits (1 byte) .times.128 words, addresses are assigned to 7 bits A6 to A0 (127 to 0). On the other hand, since the data bus size of the flash memory 2 is 16 bits (2 bytes), the upper 6 bits (A6 to A1) of the address are given to the flash memory 2.
[0020]
In the flash memory 2, a control program for the CPU 7 is written in advance by the CPU 7 as information data through the W latches 6U and 6L. That is, the controller 4 outputs latch signals and enable signals to the W latches 6U and 6L, so that when the CPU 7 outputs information data to be written to the address of A0 = 0, the 8-bit data is output by the W latch 6L. When the information data written to the address of A0 = 1 is output, the 8-bit data is latched by the W latch 6U. Then, the W latches 6U and 6L are enabled to cause the ECC circuit unit 3 to generate 5-bit inspection data, and information data and inspection data are simultaneously written in the flash memory 2.
The CPU 7 reads and executes a control program stored in the flash memory 2 to control an external device (not shown).
[0021]
The R buffers 5U and 5L have an 8-bit configuration, and are used to select data to be output on the 8-bit data bus of the CPU 7 when the CPU 7 reads information data from the flash memory 2 (details will be described later). ). That is, the input side of the R buffer 5U is connected to the upper side (D15 to D8) of the 16-bit data bus of the flash memory 2, and the input side of the R buffer 5L is connected to the lower side (D7 to D0) of the data bus. It is connected. The output sides of the R buffers 5U and 5L are connected to the 8-bit data bus (D7 to D0) of the CPU 7.
[0022]
When the information data is read from the flash memory 2 by the CPU 7, the controller 4 reads the inspection data from the flash memory 2 together with the information data. Then, when the ECC circuit unit 3 generates an error code from the read information data and inspection data, the ECC circuit unit 3 detects whether or not there is an error in the information data. That is, if the value of the error code is “0”, there is no error in the information data. If the error code is other than “0” and matches a predefined error code, a 1-bit error (1 bit error) has occurred in the information data, and if it does not match the error code, the information An error of 2 bits or more (2-bit error) has occurred in the data.
[0023]
When the ECC circuit unit 3 detects a 1-bit error as described above, the ECC circuit unit 3 corrects the error (inverts the bit value). Further, only a 2-bit error can be detected.
[0024]
The controller 4 is provided with an address output by the CPU 7 and various control signals, and outputs a control signal to the flash memory 2 and the ECC circuit unit 3 and outputs an enable signal to the R buffers 5U and 5L. . Further, when the CPU 7 performs a read cycle for the memory circuit device 1, an acknowledge signal (ACK) is output at an appropriate timing.
[0025]
The controller 4 is given a 1-bit error detection signal ERR1 from the ECC circuit unit 3, and when a 1-bit error is detected in the information data, the data correction processing by the ECC circuit unit 3 is completed. Until this is done, the output timing of the acknowledge signal is delayed.
[0026]
Next, the operation of this embodiment will be described. When the CPU 7 performs a read cycle for the memory circuit device 1, the cycle proceeds as follows. However, not all signals actually used are mentioned, and only the part related to the gist of the present invention will be described.
[0027]
<When there is no error in the information data>
(1) When the CPU 7 outputs the addresses A6 to A0 and starts the read cycle, the controller 4 decodes the address and determines that it is a read access to the memory circuit device 1. Then, a read control signal (Chip Enable, Output Enable, etc.) is output to the flash memory 2.
[0028]
(2) Then, the upper 6 bits (A6 to A1) of the address are given from the flash memory 2, and 16-bit information data is read out.
(3) The ECC circuit section 3 performs error detection based on the 16-bit information data read from the flash memory 2 and the 5-bit test data.
[0029]
(4) If the ECC circuit unit 3 does not output the 1-bit error detection signal ERR1 within a predetermined period, the controller 4 outputs an enable signal to one of the R buffers 5U and 5L according to the value of the address A0. . That is, if the access address of the CPU 7 is XXXXXX (binary), the R buffer 5L is enabled, and the data on the lower side (D7 to D0) of the data bus of the flash memory 2 is 8 bits of the CPU7. Output to the data bus. If the access address is xxxxxxx, the R buffer 5U is enabled and the data on the upper side (D15 to D8) of the data bus of the flash memory 2 is output to the 8-bit data bus of the CPU 7. The
[0030]
(5) Subsequently, the controller 4 outputs an acknowledge signal to the CPU 7. When recognizing the acknowledge signal, the CPU 7 latches and reads the data read from the memory circuit device 1. Then, the address output is stopped and the read cycle is terminated.
[0031]
<If there is an error in the information data>
Steps {circle around (1)} to {circle around (3)} are the same as when there is no error, and at {circle around (4)}, the ECC circuit section 3 outputs a 1-bit error detection signal ERR1 within a predetermined period. Then, the ECC circuit unit 3 corrects the data value in which the 1-bit error has occurred. Then, in (5), the controller 4 delays the output timing of the acknowledge signal to the CPU 7 by the time for which the ECC circuit unit 3 performs error correction, and outputs the delayed signal.
[0032]
In the above description, the operation of the ECC circuit unit 3 is well known, and the timing chart for error detection and error correction does not replace that disclosed in the data sheet of the ECC IC.
[0033]
Here, the capacity required for storing the inspection data in the flash memory 2 is 5 × 64 = 320 bits because the number of words is 64 with respect to the number of bits 5. Further, when the data bus size of the storage circuit unit is set to the same 8 bits with respect to the data bus size of 8 bits of the CPU 7 as in the prior art, the number of words is 128 with respect to the number of bits of 4 × 4 ×. 128 = 512 bits are required.
[0034]
Therefore, the total capacity reduction rate is
(1024 + 320) / (1024 + 512)
= 1344/1536 = 12.5 (%)
It becomes. That is, the capacity of the flash memory 2 is reduced by about 12.5%.
[0035]
As described above, according to the present embodiment, the flash memory 2 is configured so that the data bus size of the CPU 7 is accessed in 16 bits, and the controller 4 is configured so that the CPU 7 receives data from the flash memory 2. When trying to read data, the data is read from the flash memory 2 with 16 bits, and the data that the CPU 7 is to read is selected from these data and output onto the data bus of the CPU 7. Further, the 5-bit inspection data corresponding to the 16-bit information data is also read from the flash memory 2, and when a 1-bit error occurs in the information data, the ECC circuit unit 3 corrects it.
[0036]
Therefore, even when the ECC circuit unit 3 is provided and the reliability of the information data stored in the flash memory 2 is improved, the capacity required for the flash memory 2 is reduced as compared with the conventional case, the circuit area is reduced, and the entire data is stored. It is possible to reduce the manufacturing cost. Further, when writing to the flash memory 2 is performed at a high frequency or there is a possibility that the reliability may be lowered due to the influence of the increase in capacity, the ECC circuit unit 3 is added to improve the reliability. It becomes possible to make it.
[0037]
Further, according to the present embodiment, when the CPU 7 writes information data in the flash memory 2 in advance, the controller 4 holds the information data output by the CPU 7 on the data bus by the W latches 6U and 6L, and the ECC circuit unit. 3 is stored in the flash memory 2 together with the inspection data generated by the CPU 3, the information data and the inspection data can be stored in the flash memory 2 even when the CPU 7 and the flash memory 2 have different data bus sizes. .
[0038]
Further, according to the present embodiment, the flash memory 2, the ECC circuit unit 3, the controller 4, the R buffer 5 and the W latch 6 constituting the memory circuit device 1 are formed on the same semiconductor substrate. The CPU 7 can handle the memory circuit device 1 in the same manner as a normal memory. And the increase in the circuit area by adding a function can be suppressed as much as possible.
[0039]
The present invention is not limited to the embodiments described above and illustrated in the drawings, and the following modifications or expansions are possible.
A one-chip control LSI may be configured by forming the CPU 7 and the memory circuit device 1 on the same semiconductor substrate.
The memory circuit device is not limited to one in which each component is formed on the same semiconductor substrate, and each may be configured on a normal circuit board (printed board or the like) with a discrete IC. At this time, if the storage circuit unit is configured by flash memory and the flash memory is configured to be detachable from the circuit board by using a socket or the like, writing of information data and inspection data to the flash memory is performed by a ROM. You may go with a writer. In this case, a configuration corresponding to the W latches 6U and 6L for writing is not necessary .
[0040]
The data bus size is not limited to the above embodiment. For example, when the bus size of the CPU 7 is 16 bits, the bus size of the flash memory 2 may be 32 bits.
The flash memory 2 is not limited to the flash memory 2 and may be an EEPROM or a DRAM. When the CPU rewrites the data in the memory circuit unit as in the case of using a DRAM, a read-modify-write cycle is performed at the time of data writing to read 16-bit data, and either one of the 8 bits is read. New inspection data may be generated in a state where the data is replaced with data output by the CPU and written back to the storage circuit unit.
Further, even when a 1-bit error is detected during the read cycle, the corrected data value may be written back by performing a read modify write cycle.
Means for notifying the outside when the frequency of occurrence of these errors exceeds a certain level by supplying a detection signal of 1-bit error or 2-bit error output by the ECC circuit unit 3 to the CPU 7 (for example, LED ) To prompt the user to replace the memory circuit device 1 or the flash memory 2 or the memory circuit unit corresponding thereto.
[Brief description of the drawings]
FIG. 1 is a functional block diagram showing an electrical configuration of a memory circuit device according to an embodiment of the present invention.
1 is a memory circuit device, 2 is a flash memory (memory circuit unit), 3 is an ECC circuit unit (error correction circuit unit), 4 is a controller (access control unit), 5U and 5L are buffers (access control units), 6U, 6L indicates a latch (access control unit), and 7 indicates a CPU.

Claims (5)

CPUにより一定のデータバスサイズでアクセスが行われる記憶回路装置であって、
前記データバスサイズの複数倍のバスサイズによってアクセスが行われるように構成される記憶回路部と、
この記憶回路部に記憶されている情報データが読み出される場合には、該情報データに対応して生成され記憶されている検査データを同時に読み出して前記情報データに誤りがあるか否かを検出し、訂正可能な誤りを検出するとその誤りの訂正を行う誤り訂正回路部と、
前記CPUが前記記憶回路部より情報データを読み出そうとする場合に、前記情報データを含む複数倍のバスサイズで該記憶回路部より情報データを読み出し、それらのデータから前記CPUが読み出そうとしている情報データを選択して前記CPUのデータバス上に出力するように制御するアクセス制御部とを備え
前記アクセス制御部は、誤り訂正回路部によるデータの訂正処理が完了するまで、前記CPUに対して出力するアクノリッジ信号のタイミングを遅延させることを特徴とする記憶回路装置。
A storage circuit device that is accessed by a CPU with a constant data bus size,
A storage circuit configured to be accessed with a bus size that is a multiple of the data bus size;
When the information data stored in the storage circuit unit is read, the inspection data generated and stored corresponding to the information data is simultaneously read to detect whether the information data has an error. An error correction circuit unit that corrects the error when a correctable error is detected;
When the CPU tries to read information data from the storage circuit unit, the CPU reads the information data from the storage circuit unit with a multiple bus size including the information data, and the CPU reads from the data. An access control unit that controls to select and output information data to be output on the data bus of the CPU ,
The access control unit delays the timing of an acknowledge signal output to the CPU until data correction processing by the error correction circuit unit is completed .
前記アクセス制御部は、前記CPUが前記記憶回路部に情報データを新たに書き込もうとする場合には、前記CPUがデータバス上に出力する情報データを保持し、前記記憶回路部のデータバスサイズに等しい情報データが保持されると、該情報データと前記誤り訂正回路部によって生成される検査データとを前記記憶回路部に記憶させることを特徴とする請求項1記載の記憶回路装置。The access control unit holds information data that the CPU outputs on the data bus when the CPU intends to newly write information data to the storage circuit unit, and sets the data bus size of the storage circuit unit. 2. The storage circuit device according to claim 1, wherein when the same information data is held, the information circuit and the inspection data generated by the error correction circuit unit are stored in the storage circuit unit. 前記アクセス制御部は、前記CPUが前記記憶回路部に記憶されている情報データを書き直そうとする場合に、前記記憶回路部に対してリードモディファイライトサイクルを実行することを特徴とする請求項1または2記載の記憶回路装置。The access control unit, when the CPU tries to rewrite information data stored in the storage circuit unit, executes a read-modify-write cycle for the storage circuit unit. 3. The memory circuit device according to 1 or 2. 前記記憶回路部は、フラッシュメモリで構成されていることを特徴とする請求項1乃至3の何れかに記載の記憶回路装置。The memory circuit device according to claim 1, wherein the memory circuit unit includes a flash memory. 前記記憶回路部と、前記誤り訂正回路部と、前記アクセス制御部とを同一の半導体基板上に形成したことを特徴とする請求項1乃至4の何れかに記載の記憶回路装置。5. The memory circuit device according to claim 1, wherein the memory circuit unit, the error correction circuit unit, and the access control unit are formed on the same semiconductor substrate.
JP2000156903A 2000-05-26 2000-05-26 Memory circuit device Expired - Fee Related JP4352584B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2000156903A JP4352584B2 (en) 2000-05-26 2000-05-26 Memory circuit device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2000156903A JP4352584B2 (en) 2000-05-26 2000-05-26 Memory circuit device

Publications (2)

Publication Number Publication Date
JP2001337866A JP2001337866A (en) 2001-12-07
JP4352584B2 true JP4352584B2 (en) 2009-10-28

Family

ID=18661615

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2000156903A Expired - Fee Related JP4352584B2 (en) 2000-05-26 2000-05-26 Memory circuit device

Country Status (1)

Country Link
JP (1) JP4352584B2 (en)

Also Published As

Publication number Publication date
JP2001337866A (en) 2001-12-07

Similar Documents

Publication Publication Date Title
US7299400B2 (en) Error correction circuit
US8954818B2 (en) Error detection and correction scheme for a memory device
US6917547B2 (en) Non-volatile semiconductor memory device
US6931582B2 (en) Memory card and memory controller
JP3982639B2 (en) Method for reading data from a memory having multi-level cells
JP4734033B2 (en) Storage device
US8122303B2 (en) Data structure for flash memory and data reading/writing method thereof
JP2006107710A (en) Integrated circuit memory device, by which existence of program error due to power failure is detectable, and its method
JP2012137994A (en) Memory system and controlling method thereof
JP2004095029A (en) Nonvolatile memory and method for writing to the same
US20080072119A1 (en) Allowable bit errors per sector in memory devices
US10782920B2 (en) Data access method, memory storage apparatus and memory control circuit unit
US9721665B2 (en) Data writing method and system
JP4357305B2 (en) External storage device
JP2006221334A (en) Memory controller, flash memory system, and control method for flash memory
JP4352584B2 (en) Memory circuit device
KR20070024249A (en) Nand type flash memory for recording bad block information
JP2012155818A (en) Semiconductor integrated circuit
JP2006127441A (en) Memory controller, flash memory system and method for controlling flash memory
JP2001014226A (en) Prom with built-in ecc

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20060711

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20081225

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090106

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20090126

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20090707

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20090720

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

Free format text: PAYMENT UNTIL: 20120807

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20130807

Year of fee payment: 4

LAPS Cancellation because of no payment of annual fees