JPH10340221A - Flash memory device - Google Patents

Flash memory device

Info

Publication number
JPH10340221A
JPH10340221A JP14905497A JP14905497A JPH10340221A JP H10340221 A JPH10340221 A JP H10340221A JP 14905497 A JP14905497 A JP 14905497A JP 14905497 A JP14905497 A JP 14905497A JP H10340221 A JPH10340221 A JP H10340221A
Authority
JP
Japan
Prior art keywords
address
data
memory
bus
partial
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
JP14905497A
Other languages
Japanese (ja)
Inventor
Shuichi Isoda
修一 磯田
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.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial 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 Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP14905497A priority Critical patent/JPH10340221A/en
Publication of JPH10340221A publication Critical patent/JPH10340221A/en
Pending legal-status Critical Current

Links

Landscapes

  • Memory System (AREA)
  • Read Only Memory (AREA)

Abstract

(57)【要約】 【課題】 専用のソフトウェアを使用せずに、書き込み
を行い、通常のメモリと同様に扱うことができるフラッ
シュメモリ装置を提供する。 【解決手段】 アドレスバス1のアドレスを保持するア
ドレスレジスタ20と、データバス2のデータを保持す
るデータレジスタ20と、アドレスバス1のアドレスと
メモリ制御手段10が出力するアドレスとを選択するフ
ラッシュメモリアドレスセレクタ50と、フラッシュメ
モリアドレスセレクタ50が出力するアドレスをアドレ
ス入力とするフラッシュメモリ51と、フラッシュメモ
リ51とデータバス2とを接続するフラッシュメモリデ
ータバッファ52と、フラッシュメモリ51の書き込み
・消去を行う単位であるブロックと同じ大きさの記憶容
量を持つデータメモリ44を設け、これらをメモリ制御
手段10で制御する。
(57) [Summary] [PROBLEMS] To provide a flash memory device which can perform writing without using dedicated software and can be handled in the same manner as a normal memory. An address register holding an address of an address bus, a data register holding data of a data bus, and a flash memory for selecting an address of the address bus and an address output by a memory control means. An address selector 50, a flash memory 51 which receives an address output from the flash memory address selector 50 as an address input, a flash memory data buffer 52 which connects the flash memory 51 and the data bus 2, and performs writing / erasing of the flash memory 51. A data memory 44 having the same storage capacity as that of a block, which is a unit of operation, is provided, and these are controlled by the memory control means 10.

Description

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

【0001】[0001]

【発明の属する技術分野】本発明は、パーソナルコンピ
ュータや携帯情報端末などのメモリ装置に関するもので
ある。
[0001] 1. Field of the Invention [0002] The present invention relates to a memory device such as a personal computer and a portable information terminal.

【0002】[0002]

【従来の技術】従来パーソナルコンピュータや携帯情報
端末などの主記憶装置として一つの方法は、ダイナミッ
クRAMや、スタティックRAMを用い、電源が切断さ
れてもメモリ装置へは通電を継続し、データを保持して
いた。もう一つは、フラッシュRAMなどの不揮発性メ
モリを用いる方法があった。
2. Description of the Related Art Conventionally, one method as a main storage device of a personal computer or a portable information terminal uses a dynamic RAM or a static RAM. Was. Another method is to use a nonvolatile memory such as a flash RAM.

【0003】[0003]

【発明が解決しようとする課題】上記の従来の方法にお
ける第1の方法では、メモリに対して給電を続けなけれ
ばならないため、電池がなくなる前に充電や電池の交換
をしなければならなかった。しかるに、機器を使用しな
いときにも電池の消耗があるため、未使用の期間中に電
池が無くなりそのためデータが破壊される危険性を有し
ていた。また、電池の交換に対してもメモリに電源を供
給しなければならないため、小型の電池を内蔵するなど
の機構が必要であった。
In the first method of the above-mentioned conventional method, power must be continuously supplied to the memory, so that the battery must be charged or replaced before the battery runs out. . However, since the battery is consumed even when the device is not used, there is a danger that the battery is exhausted during the unused period and the data is destroyed. In addition, since power must be supplied to the memory even when the battery is replaced, a mechanism such as incorporating a small battery is required.

【0004】第2の方法では、電源を切断した状態での
メモリへの給電が必要ないため、第1の方法による危険
性は無くなったものの、フラッシュメモリの能力によっ
て、いくつかの制限があった。フラッシュメモリは、読
み出し速度は通常のメモリと遜色ないスピードがある
が、書き込みに時間が掛かり特殊なモードでの書き込み
操作を行う必要があった。この制限を回避するため基本
ソフトウェア(OS)がフラッシュメモリの管理を行う
などの専用のソフトウェアが必要であった。また加え
て、フラッシュメモリに対する書き込み時間が長いた
め、一般のメモリに対して性能が低下する問題点も有し
ていた。
In the second method, since it is not necessary to supply power to the memory while the power is turned off, the danger of the first method is eliminated, but there are some limitations due to the capability of the flash memory. . The flash memory has a read speed comparable to that of a normal memory, but requires a long time to write and requires a write operation in a special mode. In order to avoid this limitation, dedicated software such as a basic software (OS) for managing the flash memory is required. In addition, there is a problem that the performance is deteriorated with respect to a general memory because the writing time to the flash memory is long.

【0005】本発明はフラッシュメモリをパーソナルコ
ンピュータや携帯情報端末などの主記憶装置として使う
ための、上記問題点を解決するもので、専用のソフトウ
ェアを必要とせずに書き込みを行うことができるフラッ
シュメモリ装置を提供することを目的とする。加えて書
き込み時間による性能低下を少なくことができるフラッ
シュメモリ装置を提供することを目的とする。
[0005] The present invention solves the above-mentioned problems in using the flash memory as a main storage device of a personal computer, a portable information terminal, or the like, and can perform writing without requiring special software. It is intended to provide a device. In addition, it is an object of the present invention to provide a flash memory device which can reduce performance degradation due to writing time.

【0006】[0006]

【課題を解決するための手段】請求項1記載のフラッシ
ュメモリ装置は、複数個のメモリセルで構成されるブロ
ックを単位として書き込み・消去を行うフラッシュメモ
リ装置であって、全体の制御を行うメモリ制御手段と、
アドレスバスのアドレスを保持するアドレスレジスタ
と、データバスのデータを保持するデータレジスタと、
アドレスバスのアドレスとメモリ制御手段が出力するア
ドレスとを選択するフラッシュメモリアドレスセレクタ
と、フラッシュメモリアドレスセレクタが出力するアド
レスをアドレス入力とするフラッシュメモリと、フラッ
シュメモリとデータバスとを接続するフラッシュメモリ
データバッファと、フラッシュメモリの書き込み・消去
を行う単位であるブロックと同じ大きさの記憶容量を持
つデータメモリとを備え、メモリ制御手段は、データ読
み出し時において、フラッシュメモリアドレスセレクタ
を通してアドレスバスのアドレスをフラッシュメモリへ
供給させ、フラッシュメモリからアドレスバスのアドレ
スのデータを読み出させ、フラッシュメモリから読み出
されたデータをフラッシュメモリデータバッファを通し
てデータバスへ送り出させ、メモリ制御手段は、データ
書き込み時において、アドレスレジスタにアドレスバス
のアドレスを保持させるとともにデータレジスタにデー
タバスのデータを保持させ、アドレスレジスタに保持さ
せたアドレスからフラッシュメモリにおける書き込み・
消去を行うべきブロックのブロック番号を得、このブロ
ック番号のブロックに含まれるアドレスをフラッシュメ
モリアドレスセレクタを通してフラッシュメモリへ供給
することによりブロック番号で示されるブロックの全ア
ドレスのうちアドレスレジスタに保持させたアドレス以
外の各アドレスのデータをフラッシュメモリから読み出
させ、フラッシュメモリから読み出されたデータをデー
タメモリにおけるブロックの全アドレスのうちアドレス
レジスタに保持したアドレス以外の各アドレスに対応し
た位置に書き込ませ、データレジスタに保持させたデー
タをデータメモリにおけるアドレスレジスタに保持させ
たアドレスに対応した位置に書き込ませ、フラッシュメ
モリにおけるブロック番号のブロックのデータを消去さ
せ、フラッシュメモリにおけるブロック番号のブロック
に対してデータメモリのデータを書き込ませるようにし
たことを特徴とする。
According to a first aspect of the present invention, there is provided a flash memory device which performs writing / erasing in units of a block composed of a plurality of memory cells, wherein the entire memory is controlled. Control means;
An address register for holding the address of the address bus, a data register for holding the data of the data bus,
A flash memory address selector for selecting an address of an address bus and an address output by the memory control means, a flash memory for inputting an address output from the flash memory address selector as an address input, and a flash memory for connecting the flash memory and the data bus A data buffer and a data memory having the same storage capacity as a block which is a unit for performing writing / erasing of the flash memory are provided, and the memory control means at the time of data reading uses an address of an address bus through a flash memory address selector. To the flash memory, read the address data of the address bus from the flash memory, and send the data read from the flash memory to the data bus through the flash memory data buffer. Was issued, the memory control means, at the time of data writing, to hold the data of the data bus in the data register with and holds the address of the address bus to the address register, writes in the flash memory from the address is held in the address register
The block number of the block to be erased is obtained, and the address contained in the block of this block number is supplied to the flash memory through the flash memory address selector, so that the address register holds all the addresses of the block indicated by the block number. The data at each address other than the address is read from the flash memory, and the data read from the flash memory is written to a position corresponding to each address other than the address held in the address register among all addresses of the block in the data memory. Then, the data held in the data register is written to a position corresponding to the address held in the address register in the data memory, and the data of the block of the block number in the flash memory is erased, and the flash memory is erased. Characterized in that so as to write the data in the data memory to a block having the block number in the directory.

【0007】この構成によると、メモリ制御手段により
フラッシュメモリへの書き込みを制御するようにしたの
で、専用のソフトウェアを必要とせずに、フラッシュメ
モリに対する複雑なメモリ書き込み操作を簡単に行うこ
とができ、通常のメモリと同じように扱うことが可能で
ある。請求項2記載のフラッシュメモリ装置は、複数個
のメモリセルで構成されるブロックを単位として書き込
み・消去を行うフラッシュメモリ装置であって、全体の
制御を行うメモリ制御手段と、アドレスバスの第1部分
アドレスおよび第2部分アドレスからなるアドレスのう
ちの書き込み・消去を行うべきブロックのブロック番号
に対応した第1部分アドレスを保持するアドレスレジス
タと、アドレスレジスタが保持した第1部分アドレスと
アドレスバスのアドレスのうちの第1部分アドレスとを
比較する比較器と、アドレスバスのアドレスとメモリ制
御手段が出力するアドレスとを選択するフラッシュメモ
リアドレスセレクタと、フラッシュメモリアドレスセレ
クタが出力するアドレスをアドレス入力とするフラッシ
ュメモリと、フラッシュメモリとデータバスとを接続す
るフラッシュメモリデータバッファと、アドレスバスの
アドレスのうちの第2部分アドレスとメモリ制御手段が
出力する制御のためのアドレスとを選択するデータメモ
リアドレスセレクタと、フラッシュメモリの書き込み・
消去を行う単位であるブロックと同じ大きさの記憶容量
を持ち、データメモリアドレスセレクタが出力するアド
レスをアドレス入力としデータが書き込まれているアド
レスに対応してデータフラグがセットされるデータメモ
リと、データメモリとデータバスとを接続するデータメ
モリデータバッファとを備え、メモリ制御手段は、デー
タ読み出し時においてアドレスバスのアドレスとアドレ
スレジスタに保持されたアドレスとを比較器で比較さ
せ、比較器から不一致出力が発生したときには、フラッ
シュメモリアドレスセレクタを通してアドレスバスのア
ドレスをフラッシュメモリへ供給させ、フラッシュメモ
リからアドレスバスのアドレスのデータを読み出させ、
フラッシュメモリから読み出されたデータをフラッシュ
メモリデータバッファを通してデータバスへ送り出さ
せ、比較器から一致出力が発生したときには、データメ
モリアドレスセレクタを通してアドレスバスのアドレス
のうちの第2部分アドレスをデータメモリへ供給し、ア
ドレスバスのアドレスのうちの第2部分アドレスに対応
したデータフラグがデータメモリにセットされていると
きにはデータメモリからアドレスバスのアドレスのうち
の第2部分アドレスのデータを読み出させ、データメモ
リから読み出されたデータをデータメモリデータバッフ
ァを通してデータバスへ送り出させ、アドレスバスのア
ドレスのうちの第2部分アドレスに対応したデータフラ
グがデータメモリにセットされていないときにはフラッ
シュメモリアドレスセレクタを通してアドレスバスのア
ドレスをフラッシュメモリへ供給させ、フラッシュメモ
リからアドレスバスのアドレスのデータを読み出させ、
フラッシュメモリから読み出されたデータをフラッシュ
メモリデータバッファを通してデータバスへ送り出さ
せ、メモリ制御手段は、データ書き込み時において、電
源投入後一度もデータの書き込みを行っていないときに
は、アドレスバスのアドレスのうちの第1部分アドレス
をアドレスレジスタに書き込ませ、アドレスバスのアド
レスのうちの第2部分アドレスをデータメモリアドレス
セレクタを通してデータメモリへ与えることによりデー
タバスのデータをデータメモリデータバッファを通して
データメモリのアドレスバスのアドレスのうちの第2部
分アドレスに対応した位置に記憶させるとともに、アド
レスバスのアドレスのうちの第2部分アドレスに対応し
たデータフラグをセットさせ、メモリ制御手段は、デー
タ書き込み時において、電源投入後少なくとも一度デー
タの書き込みを行っていたときには、アドレスレジスタ
が保持した第1部分アドレスとアドレスバスの第1部分
アドレスとを比較器で比較させ、比較器から一致出力が
発生したときは、アドレスバスのアドレスのうちの第2
部分アドレスをデータメモリアドレスセレクタを通して
データメモリへ与えることによりデータバスのデータを
データメモリデータバッファを通してデータメモリのア
ドレスバスのアドレスのうちの第2部分アドレスに対応
した位置に記憶させるとともに、アドレスバスのアドレ
スのうちの第2部分アドレスに対応したデータフラグを
セットさせ、比較器から不一致出力が発生したときは、
アドレスレジスタが保持した第1部分アドレスに対応し
たブロックに含まれる各アドレスを順次共通にデータメ
モリアドレスセレクタおよびフラッシュメモリアドレス
セレクタをそれぞれ通してデータメモリおよびフラッシ
ュメモリへ共通に与えることにより、フラッシュメモリ
におけるアドレスバスのアドレスのうちの第1部分アド
レスに対応したブロックに含まれる各アドレスのうちデ
ータメモリでデータフラグがセットされていないアドレ
スについてのみデータをデータメモリに複写させ、フラ
ッシュメモリにおけるアドレスバスのアドレスのうちの
第1部分アドレスに対応したブロックのデータを消去
し、フラッシュメモリにおけるアドレスバスのアドレス
のうちの第1部分アドレスに対応したブロックにデータ
メモリのデータを書き込ませ、データメモリのデータフ
ラグのセットを取り消し、アドレスバスのアドレスのう
ちの第1部分アドレスをアドレスレジスタに書き込ま
せ、アドレスバスのアドレスのうちの第2部分アドレス
をデータメモリアドレスセレクタを通してデータメモリ
へ与えることによりデータバスのデータをデータメモリ
データバッファを通してデータメモリのアドレスバスの
アドレスのうちの第2部分アドレスに対応した位置に記
憶させるとともに、データメモリのアドレスバスのアド
レスのうちの第2部分アドレスに対応したデータフラグ
をセットさせるようにしたことを特徴とする。
According to this configuration, since writing to the flash memory is controlled by the memory control means, a complicated memory writing operation to the flash memory can be easily performed without requiring dedicated software, It can be handled in the same way as a normal memory. 3. A flash memory device according to claim 2, wherein the flash memory device performs writing / erasing in units of a block composed of a plurality of memory cells, and comprises a memory control means for controlling the whole and a first address bus. An address register for holding a first partial address corresponding to a block number of a block to be written / erased out of an address consisting of a partial address and a second partial address; and a first partial address and an address bus held by the address register. A comparator for comparing a first partial address among the addresses, a flash memory address selector for selecting an address on the address bus and an address output by the memory control means, and an address input for outputting an address output from the flash memory address selector. Flash memory and flash A flash memory data buffer for connecting the memory and the data bus, a data memory address selector for selecting a second partial address among the addresses on the address bus and an address for control output by the memory control means, writing·
A data memory having the same storage capacity as a block as a unit to be erased, and having an address output from a data memory address selector as an address input and a data flag being set corresponding to an address where data is written; A data memory data buffer for connecting the data memory and the data bus, wherein the memory control means causes the comparator to compare the address of the address bus with the address held in the address register when reading data, When an output occurs, the address of the address bus is supplied to the flash memory through the flash memory address selector, and the data of the address of the address bus is read from the flash memory.
The data read from the flash memory is sent out to the data bus through the flash memory data buffer, and when a match is generated from the comparator, the second partial address of the address bus address is transferred to the data memory through the data memory address selector. When the data flag corresponding to the second partial address of the address of the address bus is set in the data memory, the data of the second partial address of the address of the address bus is read from the data memory. The data read from the memory is sent to the data bus through the data memory data buffer. When the data flag corresponding to the second partial address of the address of the address bus is not set in the data memory, the flash memory address The address of the address bus is supplied to the flash memory through the selector, to read the data of the address of the address bus from the flash memory,
The data read from the flash memory is sent to the data bus through the flash memory data buffer, and at the time of data writing, when no data has been written after power-on, the memory control means Is written to an address register, and a second partial address of the address of the address bus is applied to the data memory through a data memory address selector, so that the data on the data bus is passed through a data memory data buffer to the address bus of the data memory. And a data flag corresponding to the second partial address of the address of the address bus is set, and the memory control means sets the data flag when writing the data. When data has been written at least once after power-on, the first partial address held by the address register is compared with the first partial address of the address bus by a comparator. , The second of the addresses on the address bus
By providing the partial address to the data memory through the data memory address selector, the data on the data bus is stored in the address corresponding to the second partial address among the addresses on the address bus of the data memory through the data memory data buffer, and When the data flag corresponding to the second partial address of the address is set, and a non-match output is generated from the comparator,
Each address included in the block corresponding to the first partial address held by the address register is sequentially and commonly applied to the data memory and the flash memory through the data memory address selector and the flash memory address selector, respectively. Of the addresses included in the block corresponding to the first partial address among the addresses of the address bus, only the address for which the data flag is not set in the data memory among the addresses included in the block is copied to the data memory, and the address of the address bus in the flash memory Of the block corresponding to the first partial address of the flash memory, and writes the data of the data memory to the block corresponding to the first partial address of the address of the address bus in the flash memory. To cancel the setting of the data flag of the data memory, write the first partial address of the address of the address bus to the address register, and store the second partial address of the address of the address bus through the data memory address selector. To store the data on the data bus through the data memory data buffer at the position corresponding to the second partial address of the address of the address bus of the data memory, and the second portion of the address of the address bus of the data memory. A data flag corresponding to an address is set.

【0008】この構成によると、メモリ制御手段により
フラッシュメモリへの書き込みを制御するようにしたの
で、専用のソフトウェアを必要とせずに、フラッシュメ
モリに対する複雑なメモリ書き込み操作を簡単に行うこ
とができ、通常のメモリと同じように扱うことが可能で
ある。しかも、同一ブロックに対する連続した書き込み
に対して一度の書き込みで完了し書き込み時間が短縮で
きる。
According to this configuration, since writing to the flash memory is controlled by the memory control means, a complicated memory writing operation to the flash memory can be easily performed without requiring dedicated software. It can be handled in the same way as a normal memory. In addition, continuous writing to the same block is completed by one writing, and the writing time can be reduced.

【0009】請求項3記載のフラッシュメモリ装置は、
複数個のメモリセルで構成されるブロックを単位として
書き込み・消去を行うフラッシュメモリ装置であって、
全体の制御を行うメモリ制御手段と、アドレスバスの第
1部分アドレス,第2部分アドレスおよび第3部分アド
レスからなるアドレスのうちの書き込み・消去を行うべ
きブロックのブロック番号に対応した第2部分アドレス
とメモリ制御手段が出力するアドレスとを選択するアド
レスタグメモリアドレスセレクタと、アドレスタグメモ
リアドレスセレクタから出力されるアドレスをアドレス
入力としデータが書き込まれているアドレスに対応して
アドレスタグフラグがセットされるアドレスタグメモリ
と、アドレスタグメモリとアドレスバスとを接続してア
ドレスバスの第1部分アドレスをアドレスタグメモリへ
データ入力として供給するアドレスタグメモリデータバ
ッファと、アドレスバスのアドレスのうちの第2部分ア
ドレスをアドレス入力としてアドレスタグメモリから読
み出されるアドレスとアドレスバスのアドレスのうちの
第1部分アドレスとを比較する比較器と、アドレスバス
のアドレスとメモリ制御手段が出力するアドレスとを選
択するフラッシュメモリアドレスセレクタと、フラッシ
ュメモリアドレスセレクタから出力されるアドレスをア
ドレス入力とするフラッシュメモリと、フラッシュメモ
リとデータバスとを接続するフラッシュメモリデータバ
ッファと、アドレスバスのアドレスのうちの第2部分ア
ドレスおよび第3部分アドレスとメモリ制御手段が出力
する制御のためのアドレスとを選択するデータメモリア
ドレスセレクタと、フラッシュメモリの書き込み・消去
の単位であるブロックの第2部分アドレスのアドレス空
間の大きさに相当する個数分と同じ容量を持ち、データ
メモリアドレスセレクタが出力するアドレスをアドレス
入力としデータが書き込まれているアドレスに対応して
データフラグがセットされるデータメモリと、データメ
モリとデータバスとを接続するデータメモリデータバッ
ファとを備え、メモリ制御手段は、データ読み出し時に
おいてアドレスバスのアドレスのうちの第1部分アドレ
スとアドレスバスのアドレスのうちの第2部分アドレス
をアドレスタグメモリアドレスセレクタを通しアドレス
入力としてアドレスタグメモリから読み出させたデータ
とを比較器で比較させ、比較器から不一致出力が発生し
たときには、フラッシュメモリアドレスセレクタを通し
てアドレスバスのアドレスをフラッシュメモリへ供給さ
せ、フラッシュメモリからアドレスバスのアドレスのデ
ータを読み出させ、フラッシュメモリから読み出された
データをフラッシュメモリデータバッファを通してデー
タバスへ送り出させ、比較器から一致出力が発生したと
きには、データメモリアドレスセレクタを通してアドレ
スバスのアドレスのうちの第2部分アドレスおよび第3
部分アドレスをデータメモリへ供給し、アドレスバスの
アドレスのうちの第2部分アドレスおよび第3部分アド
レスに対応したデータフラグがデータメモリにセットさ
れているときにはデータメモリからアドレスバスのアド
レスのうちの第2部分アドレスおよび第3部分アドレス
のデータを読み出させ、データメモリから読み出された
データをデータメモリデータバッファを通してデータバ
スへ送り出させ、アドレスバスのアドレスのうちの第2
部分アドレスおよび第3部分アドレスに対応したデータ
フラグがデータメモリにセットされていないときにはフ
ラッシュメモリアドレスセレクタを通してアドレスバス
のアドレスをフラッシュメモリへ供給させ、フラッシュ
メモリからアドレスバスのアドレスのデータを読み出さ
せ、フラッシュメモリから読み出されたデータをフラッ
シュメモリデータバッファを通してデータバスへ送り出
させ、メモリ制御手段は、データ書き込み時において、
アドレスタグメモリの全てのアドレスへの書き込みを完
了する前には、アドレスバスのアドレスのうちの第2部
分アドレスをアドレスタグメモリアドレスセレクタを通
しアドレス入力とするとともにアドレスバスのアドレス
のうちの第1部分アドレスをデータ入力としてアドレス
タグメモリに書き込みを行わせるとともに、アドレスタ
グメモリにおけるデータ書き込みを行ったアドレスに対
応するアドレスタグフラグをセットさせ、アドレスバス
のアドレスのうちの第2部分アドレスおよび第3部分ア
ドレスをデータメモリアドレスセレクタを通してデータ
メモリへ与えることによりデータバスのデータをデータ
メモリデータバッファを通してデータメモリのアドレス
バスのアドレスのうちの第2部分アドレスおよび第3部
分アドレスに対応した位置に記憶させるとともに、デー
タメモリにおけるアドレスバスのアドレスのうちの第2
部分アドレスおよび第3部分アドレスに対応したデータ
フラグをセットさせ、メモリ制御手段は、データ書き込
み時において、アドレスタグメモリの全てのアドレスへ
の書き込みが完了してアドレスタグメモリの全てのアド
レス対応したアドレスタグフラグがすべてセットされた
後には、アドレスバスのアドレスのうちの第1部分アド
レスとアドレスバスのアドレスのうちの第2部分アドレ
スをアドレス入力としてアドレスタグメモリから読み出
させたデータとを比較器で比較させ、比較器から一致出
力が発生したときには、アドレスバスのアドレスのうち
の第2部分アドレスおよび第3部分アドレスをデータメ
モリアドレスセレクタを通してデータメモリへ与えるこ
とによりデータバスのデータをデータメモリデータバッ
ファを通してデータメモリのアドレスバスのアドレスの
うちの第2部分アドレスおよび第3部分アドレスに対応
した位置に記憶させるとともに、データメモリのアドレ
スバスのアドレスのうちの第2部分アドレスおよび第3
部分アドレスに対応したデータフラグをセットさせ、比
較器から不一致出力が発生したときには、アドレスタグ
メモリの全てのアドレスとそれらのアドレスに記憶させ
たデータとによってそれぞれ決まる複数組の第1部分ア
ドレスおよび第2部分アドレスに対応した個数のブロッ
クに含まれる各アドレスを順次共通にデータメモリアド
レスセレクタおよびフラッシュメモリアドレスセレクタ
をそれぞれ通してデータメモリおよびフラッシュメモリ
へ共通に与えることにより、フラッシュメモリにおける
アドレスバスのアドレスのうちの複数組の第1部分アド
レスおよび第2部分アドレスに対応した個数のブロック
に含まれる各アドレスのうちデータメモリでデータフラ
グがセットされていないアドレスについてのみデータを
データメモリに複写させ、アドレスタグメモリの全ての
アドレスとそれらのアドレスに記憶させたデータとによ
ってそれぞれ決まる複数組の第1部分アドレスおよび第
2部分アドレスに対応したブロックのデータを消去し、
フラッシュメモリにおけるアドレスバスのアドレスのう
ちの複数組の第1部分アドレスおよび第2部分アドレス
に対応したブロックにデータメモリのデータを書き込ま
せ、データメモリのデータフラグのセットを取り消し、
アドレスタグメモリの全てのアドレスへの書き込みを完
了するまで、アドレスバスのアドレスのうちの第2部分
アドレスをアドレスタグメモリアドレスセレクタを通し
アドレス入力とするとともにアドレスバスのアドレスの
うちの第1部分アドレスをデータ入力としてアドレスタ
グメモリに書き込みを行わせるとともに、アドレスタグ
メモリにおけるデータ書き込みを行ったアドレスに対応
するアドレスタグフラグをセットさせ、アドレスバスの
アドレスのうちの第2部分アドレスおよび第3部分アド
レスをデータメモリアドレスセレクタを通してデータメ
モリへ与えることによりデータバスのデータをデータメ
モリデータバッファを通してデータメモリのアドレスバ
スのアドレスのうちの第2部分アドレスおよび第3部分
アドレスに対応した位置に記憶させるとともに、データ
メモリにおけるアドレスバスのアドレスのうちの第2部
分アドレスおよび第3部分アドレスに対応したデータフ
ラグをセットさせるようにしたことを特徴とする。
[0009] A flash memory device according to claim 3 is
A flash memory device that performs writing / erasing in units of a block composed of a plurality of memory cells,
Memory control means for controlling the whole; and a second partial address corresponding to a block number of a block to be written / erased among addresses composed of a first partial address, a second partial address and a third partial address of an address bus. And an address tag memory address selector for selecting an address output from the memory control means, an address output from the address tag memory address selector being an address input, and an address tag flag being set corresponding to an address where data is written. An address tag memory, an address tag memory data buffer for connecting the address tag memory to the address bus and supplying a first partial address of the address bus as a data input to the address tag memory, and a second address bus address of the address bus. Address partial address A comparator for comparing the address read from the address tag memory with the first partial address among the addresses on the address bus; a flash memory address selector for selecting an address on the address bus and an address output by the memory control means; A flash memory having an address input from an address output from a flash memory address selector, a flash memory data buffer connecting the flash memory and a data bus, and a second partial address and a third partial address of addresses on the address bus. And a data memory address selector for selecting an address for control output by the memory control means, and a number corresponding to the size of the address space of the second partial address of the block which is a unit of writing / erasing of the flash memory. the same A data memory having an amount, an address output from a data memory address selector being an address input, and a data flag being set corresponding to an address to which data is written, and a data memory data buffer connecting the data memory and the data bus The memory control means receives the first partial address of the addresses of the address bus and the second partial address of the addresses of the address bus through the address tag memory address selector and inputs the address to the address tag memory when reading data. A comparator compares the data read from the flash memory with the data read out from the flash memory. When a non-match output is generated from the comparator, the address on the address bus is supplied to the flash memory through the flash memory address selector. The data read from the flash memory is sent out to the data bus through the flash memory data buffer, and when a match output is generated from the comparator, the data of the address on the address bus is passed through the data memory address selector. Two part address and third
The partial address is supplied to the data memory, and when the data flags corresponding to the second partial address and the third partial address of the addresses on the address bus are set in the data memory, the data memory transfers the partial address from the address on the address bus. The data of the two-part address and the third partial address are read, and the data read from the data memory is sent to the data bus through the data memory data buffer.
When the data flag corresponding to the partial address and the third partial address is not set in the data memory, the address of the address bus is supplied to the flash memory through the flash memory address selector, and the data of the address of the address bus is read from the flash memory. The data read from the flash memory is sent out to the data bus through the flash memory data buffer, and the memory control means
Before the writing to all the addresses of the address tag memory is completed, the second partial address of the addresses on the address bus is used as an address input through the address tag memory address selector, and the first of the addresses on the address bus is input. Using the partial address as the data input, the address tag memory is written, and the address tag flag corresponding to the address where the data was written in the address tag memory is set. By providing the partial address to the data memory through the data memory address selector, the data on the data bus corresponds to the second partial address and the third partial address among the addresses on the address bus of the data memory through the data memory data buffer. It was together is stored in the position, the second of the address of the address bus in the data memory
The data flags corresponding to the partial address and the third partial address are set, and at the time of data writing, the memory control means completes writing to all addresses of the address tag memory and completes the address corresponding to all addresses of the address tag memory. After all the tag flags have been set, the comparator reads the first partial address of the address bus address and the second partial address of the address bus address from the address tag memory as an address input. When a match output is generated from the comparator, the second partial address and the third partial address of the addresses on the address bus are supplied to the data memory through the data memory address selector, thereby transferring the data on the data bus to the data memory data. Data through buffer Together is stored in the second partial address, and a third partial address in the address bus the address of the memory to the corresponding position, the second partial address in the address bus the address of the data memory and the third
When a data flag corresponding to the partial address is set and a non-match output is generated from the comparator, a plurality of sets of the first partial address and the second partial address determined by all the addresses of the address tag memory and the data stored at those addresses, respectively. The addresses included in the blocks corresponding to the two partial addresses are sequentially and commonly applied to the data memory and the flash memory through the data memory address selector and the flash memory address selector, respectively, so that the address of the address bus in the flash memory is provided. Of the addresses included in the blocks corresponding to the plurality of sets of the first partial address and the second partial address, only the addresses for which the data flag is not set in the data memory are copied to the data memory. It is not to erase the data of all the addresses and blocks corresponding to a plurality of sets of first partial address and a second partial address determined respectively by the data stored in those addresses of the address tag memory,
Causing the data of the data memory to be written to blocks corresponding to a plurality of sets of the first partial address and the second partial address among the addresses of the address bus in the flash memory, canceling the setting of the data flag of the data memory,
Until writing to all the addresses of the address tag memory is completed, the second partial address of the address bus is used as an address input through the address tag memory address selector, and the first partial address of the address bus address is input. Is written as data input to the address tag memory, and the address tag flag corresponding to the address at which the data was written in the address tag memory is set, and the second partial address and the third partial address of the addresses on the address bus are set. To the data memory through the data memory address selector, the data on the data bus corresponds to the second partial address and the third partial address of the addresses on the address bus of the data memory through the data memory data buffer. Together is stored in the position, characterized in that so as to set the data flag corresponding to the second partial address, and a third partial address of the address of the address bus in the data memory.

【0010】この構成によると、メモリ制御手段により
フラッシュメモリへの書き込みを制御するようにしたの
で、専用のソフトウェアを必要とせずに、フラッシュメ
モリに対する複雑なメモリ書き込み操作を簡単に行うこ
とができ、通常のメモリと同じように扱うことが可能で
ある。しかも、複数個のブロックに対する連続した書き
込みに対して一度の書き込みで完了し書き込み時間をい
っそう短縮できる。
According to this configuration, since writing to the flash memory is controlled by the memory control means, a complicated memory writing operation to the flash memory can be easily performed without requiring special software. It can be handled in the same way as a normal memory. In addition, continuous writing to a plurality of blocks is completed by one writing, and the writing time can be further reduced.

【0011】[0011]

【発明の実施の形態】以下、本発明のフラッシュメモリ
装置の実施の形態について、図を用いて詳細に説明す
る。 (第1の実施の形態;請求項1に対応)図1は本発明の
第1の実施の形態におけるフラッシュメモリ装置の構成
を示すブロック図である。図1において、1はアドレス
バス、2はデータバス、3は制御信号入力、4は制御信
号出力、10はメモリ制御手段、20はアドレスレジス
タ、40はデータレジスタ、44はデータメモリ、50
はフラッシュメモリアドレスセレクタ、51はフラッシ
ュメモリ、52はフラッシュメモリデータバッファであ
る。
DESCRIPTION OF THE PREFERRED EMBODIMENTS Embodiments of a flash memory device according to the present invention will be described below in detail with reference to the drawings. (First Embodiment; Corresponding to Claim 1) FIG. 1 is a block diagram showing a configuration of a flash memory device according to a first embodiment of the present invention. In FIG. 1, 1 is an address bus, 2 is a data bus, 3 is a control signal input, 4 is a control signal output, 10 is a memory control means, 20 is an address register, 40 is a data register, 44 is a data memory, and 50 is a data memory.
Is a flash memory address selector, 51 is a flash memory, and 52 is a flash memory data buffer.

【0012】このフラッシュメモリ装置は、複数個のメ
モリセルで構成されるブロックを単位として書き込み・
消去を行うものである。この中で、メモリ制御手段10
は全体の制御を行う、アドレスレジスタ20はアドレス
バス1のアドレスを保持する。データレジスタ40はデ
ータバス2のデータを保持する。フラッシュメモリアド
レスセレクタ50はアドレスバス1のアドレスとメモリ
制御手段10が出力するアドレスとを選択する。フラッ
シュメモリ51はフラッシュメモリアドレスセレクタ5
0が出力するアドレスをアドレス入力とする。フラッシ
ュメモリデータバッファ52はフラッシュメモリ51と
データバス2とを接続する。データメモリ44はフラッ
シュメモリ51の書き込み・消去を行う単位であるブロ
ックと同じ大きさの記憶容量を持つ。
In this flash memory device, writing / writing is performed in units of blocks composed of a plurality of memory cells.
This is for erasing. Among them, the memory control means 10
Performs overall control. The address register 20 holds the address of the address bus 1. The data register 40 holds data on the data bus 2. The flash memory address selector 50 selects an address on the address bus 1 and an address output from the memory control means 10. The flash memory 51 is a flash memory address selector 5
An address output by 0 is an address input. The flash memory data buffer 52 connects the flash memory 51 and the data bus 2. The data memory 44 has the same storage capacity as a block which is a unit for performing writing / erasing of the flash memory 51.

【0013】ここで、メモリ制御手段10は、データ読
み出し時において、フラッシュメモリアドレスセレクタ
50を通してアドレスバス1のアドレスをフラッシュメ
モリ51へ供給させ、フラッシュメモリ51からアドレ
スバス1のアドレスのデータを読み出させ、フラッシュ
メモリ51から読み出されたデータをフラッシュメモリ
データバッファ52を通してデータバス2へ送り出させ
る。また、メモリ制御手段10は、データ書き込み時に
おいて、アドレスレジスタ20にアドレスバス1のアド
レスを保持させるとともにデータレジスタ40にデータ
バス2のデータを保持させ、アドレスレジスタ20に保
持させたアドレスからフラッシュメモリ51における書
き込み・消去を行うべきブロックのブロック番号を得、
このブロック番号のブロックに含まれるアドレスをフラ
ッシュメモリアドレスセレクタ50を通してフラッシュ
メモリ51へ供給することによりブロック番号で示され
るブロックの全アドレスのうちアドレスレジスタ20に
保持させたアドレス以外の各アドレスのデータをフラッ
シュメモリ51から読み出させ、フラッシュメモリ51
から読み出されたデータをデータメモリ44におけるブ
ロックの全アドレスのうちアドレスレジスタ20に保持
したアドレス以外の各アドレスに対応した位置に書き込
ませ、データレジスタ40に保持させたデータをデータ
メモリ44におけるアドレスレジスタ20に保持させた
アドレスに対応した位置に書き込ませ、フラッシュメモ
リ51におけるブロック番号のブロックのデータを消去
させ、フラッシュメモリ51におけるブロック番号のブ
ロックに対してデータメモリ44のデータを書き込ませ
るようにしている。
At the time of data reading, the memory control means 10 supplies the address of the address bus 1 to the flash memory 51 through the flash memory address selector 50, and reads the data of the address of the address bus 1 from the flash memory 51. Then, the data read from the flash memory 51 is sent to the data bus 2 through the flash memory data buffer 52. The memory control means 10 causes the address register 20 to hold the address of the address bus 1 and the data register 40 to hold the data of the data bus 2 at the time of writing data. Obtain the block number of the block to be written / erased at 51,
By supplying the address contained in the block of the block number to the flash memory 51 through the flash memory address selector 50, the data of each address other than the address held in the address register 20 among all the addresses of the block indicated by the block number is obtained. The flash memory 51 is read from the flash memory 51.
Out of all the addresses of the block in the data memory 44, corresponding to each address other than the address held in the address register 20, and write the data held in the data register 40 to the address in the data memory 44. The data in the block with the block number in the flash memory 51 is erased, and the data in the data memory 44 is written into the block with the block number in the flash memory 51, by writing the data in the position corresponding to the address held in the register 20. ing.

【0014】以下、図1を参照しながら、この実施の形
態の動作を読み出し、書き込み、書き込み途中の読み出
しもしくは書き込みに分けて説明する。本図面におい
て、破線は制御のための信号を示している。まず、読み
出しについて説明する。読み出し時はアドレスバス1の
アドレス信号はフラッシュメモリアドレスセレクタ50
を通りフラッシュメモリ51に加えられる。フラッシュ
メモリ51は加えられたアドレスのデータを出力し、フ
ラッシュメモリデータバッファ52を通してデータバス
2にデータを出力する。メモリ制御手段10はフラッシ
ュメモリアドレスセレクタ50の選択方向、フラッシュ
メモリデータバッファ52を制御する。この場合は単純
なメモリ読み出しになる。
Hereinafter, the operation of this embodiment will be described with reference to FIG. 1 separately for reading, writing, reading or writing during writing. In the drawing, broken lines indicate signals for control. First, reading will be described. At the time of reading, the address signal of the address bus 1 is set to the flash memory address selector 50.
And is added to the flash memory 51. The flash memory 51 outputs the data at the added address, and outputs the data to the data bus 2 through the flash memory data buffer 52. The memory control means 10 controls the selection direction of the flash memory address selector 50 and the flash memory data buffer 52. In this case, simple memory reading is performed.

【0015】続いて、書き込みについて説明する。書き
込みは4つの段階に分解できる。第1はアドレスレジス
タ20およびデータレジスタ40に要求された書き込み
アドレスおよびデータを保持する段階である。メモリ制
御手段10は、アドレスレジスタ20とデータレジスタ
40を制御し、それぞれアドレスバス1とデータバス2
の内容を保持させる。メモリ装置としての外部に対する
動作はこれで完了することが可能である。したがって、
マイクロコンピュータなどのメモリ装置を利用する側か
ら、単純なメモリとして見える。
Next, writing will be described. Writing can be broken down into four stages. The first step is to hold the write address and data requested by the address register 20 and the data register 40. The memory control means 10 controls the address register 20 and the data register 40, and controls the address bus 1 and the data bus 2 respectively.
To keep the contents of The operation to the outside as a memory device can now be completed. Therefore,
From the viewpoint of using a memory device such as a microcomputer, the memory device appears as a simple memory.

【0016】第2の段階は、フラッシュメモリ51にお
ける書き換えるブロックのデータをデータメモリ44に
移す段階である。メモリ制御手段10はフラッシュメモ
リアドレスセレクタ50を制御し、メモリ制御手段10
が出力する信号を通すようにする。メモリ制御手段10
は、アドレスレジスタ20が保持するアドレスから書き
換えるブロックの番号を得る。メモリ制御手段10は、
フラッシュメモリアドレスセレクタを通して逐次アドレ
スをフラッシュメモリ51に与えることにより、得たブ
ロック番号のフラッシュメモリ51のデータを順次読み
出し、データメモリ44に格納する。アドレスレジスタ
20のアドレスに相当するデータメモリ44にはデータ
レジスタ40の内容を格納する。これで、フラッシュメ
モリ51にあった以前のデータと新たに書き換えるデー
タがデータメモリ44に保持された。
The second stage is a stage in which the data of the block to be rewritten in the flash memory 51 is transferred to the data memory 44. The memory control means 10 controls the flash memory address selector 50,
Let the output signal pass. Memory control means 10
Obtains the number of the block to be rewritten from the address held by the address register 20. The memory control means 10
The sequential address is given to the flash memory 51 through the flash memory address selector, so that the data of the flash memory 51 of the obtained block number is sequentially read and stored in the data memory 44. The data memory 44 corresponding to the address of the address register 20 stores the contents of the data register 40. Thus, the data previously stored in the flash memory 51 and the data to be newly rewritten are held in the data memory 44.

【0017】第3の段階は、フラッシュメモリ51の書
き換えるべきブロックの消去を行う段階である。これは
メモリ制御手段10がフラッシュメモリ51に対してコ
マンドを書き込むことで行える。フラッシュメモリアド
レスセレクタ50の制御は第2の段階と同じである。第
4の段階は、新しいデータをフラッシュメモリ51に対
して書き込む段階である。これも第3段階と同じよう
に、メモリ制御手段10がフラッシュメモリ51に対し
てコマンドを書き込むことで行える。このようにして、
書き換えるデータが含まれるブロックを新しい内容に置
き換えることができる。
The third step is a step of erasing a block of the flash memory 51 to be rewritten. This can be performed by the memory control means 10 writing a command to the flash memory 51. The control of the flash memory address selector 50 is the same as in the second stage. The fourth step is a step of writing new data to the flash memory 51. This can also be performed by the memory control means 10 writing a command to the flash memory 51, as in the third stage. In this way,
The block containing the data to be rewritten can be replaced with new content.

【0018】ここで、一般的なフラッシュメモリの制御
方法について説明を加えておく。フラッシュメモリは、
内容の消去や書き換えができる。内容の消去や書き換え
を行うには、フラッシュメモリの特定アドレスに特定の
データを書くことでメモリチップが消去モードや書き込
みモードに入る。特定のアドレスに特定のデータを書く
ことを、コマンドを書き込むと表現している。消去モー
ドや書き込みモードに入ると、フラッシュメモリはRO
Mとしては見えず、入出力装置のように見え、メモリ制
御手段と情報交換を行いながら、指定された処理を実行
する。
Here, a general flash memory control method will be described. Flash memory is
The contents can be deleted or rewritten. To erase or rewrite the contents, the memory chip enters an erase mode or a write mode by writing specific data to a specific address of the flash memory. Writing specific data to a specific address is referred to as writing a command. When entering the erase mode or write mode, the flash memory
It does not appear as M, but looks like an input / output device, and executes specified processing while exchanging information with the memory control means.

【0019】つぎに、書き込み途中の読み出しもしくは
書き込みについて説明する。書き込み途中は外部からの
メモリアクセスに対して応答できないので、制御信号出
力4でメモリアクセスに対する応答を待たせる。書き込
みが完了し次第読み出し、または書き込み動作を開始
し、メモリアクセスの応答を完了させる。電源切断を行
う前にアドレスレジスタ20とデータレジスタ40に残
っているデータをフラッシュメモリ51に対して書き込
まなければならない。書き込みの手順は上で説明したも
のと同一である。
Next, reading or writing during writing will be described. Since a response to an external memory access cannot be made during writing, a response to the memory access is made to wait by the control signal output 4. As soon as the writing is completed, the reading or writing operation is started to complete the memory access response. The data remaining in the address register 20 and the data register 40 must be written to the flash memory 51 before the power is turned off. The writing procedure is the same as that described above.

【0020】以上のように、この実施の形態によれば、
アドレスレジスタ20、データレジスタ40、フラッシ
ュメモリアドレスセレクタ51およびデータメモリ44
を設け、メモリ制御手段10によりフラッシュメモリ5
1への書き込みを制御するようにしたので、専用のソフ
トウェアを必要とせずに、フラッシュメモリ51に対す
る複雑なメモリ書き込み操作を簡単に行うことができ、
通常のメモリと同じように扱うことが可能である。した
がって、フラッシュメモリ51を意識することなくアク
セスが可能で、その結果一般のメモリを対象に作成され
たソフトウェアをそのまま稼動させることができる。
As described above, according to this embodiment,
Address register 20, data register 40, flash memory address selector 51, and data memory 44
Is provided, and the flash memory 5 is
1 is controlled, so that a complicated memory write operation to the flash memory 51 can be easily performed without requiring dedicated software,
It can be handled in the same way as a normal memory. Therefore, access is possible without being conscious of the flash memory 51, and as a result, software created for a general memory can be operated as it is.

【0021】(第2の実施の形態;請求項2に対応)図
2は本発明の第2の実施の形態におけるフラッシュメモ
リ装置の構成を示すブロック図である。図2において、
1はアドレスバス、2はデータバス、3は制御信号入
力、4は制御信号出力、11はメモリ制御手段、20は
アドレスレジスタ、30は比較器、41はデータメモリ
アドレスセレクタ、42はデータメモリ、43はデータ
メモリデータバッファ、50はフラッシュメモリアドレ
スセレクタ、51はフラッシュメモリ、52はフラッシ
ュメモリデータバッファである。
(Second Embodiment: Corresponding to Claim 2) FIG. 2 is a block diagram showing a configuration of a flash memory device according to a second embodiment of the present invention. In FIG.
1 is an address bus, 2 is a data bus, 3 is a control signal input, 4 is a control signal output, 11 is a memory control means, 20 is an address register, 30 is a comparator, 41 is a data memory address selector, 42 is a data memory, 43 is a data memory data buffer, 50 is a flash memory address selector, 51 is a flash memory, and 52 is a flash memory data buffer.

【0022】図4は、データメモリ42のデータビット
構成を示す概略図である。図4において、60はデータ
部、61はデータフラグ部である。まず最初に、データ
メモリ42について説明を加える。データメモリ42は
フラッシュメモリ51の1つのブロックと同じアドレス
空間を持っている。データメモリ42の構成を、図4を
参照しながら説明する。データメモリ42はデータ部6
0とデータフラグ部61から構成されている。データ部
60はフラッシュメモリ51の更新すべきデータを格納
し、アドレスバス1およびデータバス2によって、また
はメモリ制御手段11によって読み出し書き込みが可能
である。データフラグ部61はデータがセットされてい
ることを示し、メモリ制御手段11によってのみ読み出
し書き込みが可能である。また、アドレスバス1および
データバス2から書き込みを行うと、対応するアドレス
のデータフラグ部61がセットされる。なお、電源投入
後データフラグ部61は全てセットされていない状態と
する。
FIG. 4 is a schematic diagram showing a data bit configuration of the data memory 42. In FIG. 4, reference numeral 60 denotes a data portion, and 61 denotes a data flag portion. First, the data memory 42 will be described. The data memory 42 has the same address space as one block of the flash memory 51. The configuration of the data memory 42 will be described with reference to FIG. The data memory 42 stores the data section 6
0 and a data flag section 61. The data section 60 stores data to be updated in the flash memory 51 and can be read and written by the address bus 1 and the data bus 2 or by the memory control means 11. The data flag unit 61 indicates that data is set, and can be read and written only by the memory control unit 11. When writing is performed from the address bus 1 and the data bus 2, the data flag section 61 of the corresponding address is set. It is assumed that all the data flag units 61 are not set after the power is turned on.

【0023】つぎに、フラッシュメモリ装置について説
明する。このフラッシュメモリ装置は、複数個のメモリ
セルで構成されるブロックを単位として書き込み・消去
を行うものである。この中で、メモリ制御手段11は全
体の制御を行う。アドレスレジスタ20はアドレスバス
1の第1部分アドレス(上位アドレス)および第2部分
アドレス(下位アドレス)からなるアドレスのうちの書
き込み・消去を行うべきブロックのブロック番号に対応
した第1部分アドレスを保持する。比較器30はアドレ
スレジスタ20が保持した第1部分アドレスとアドレス
バス1のアドレスのうちの第1部分アドレスとを比較す
る。フラッシュメモリアドレスセレクタ50はアドレス
バス1のアドレスとメモリ制御手段11が出力するアド
レスとを選択する。フラッシュメモリ51はフラッシュ
メモリアドレスセレクタ50が出力するアドレスをアド
レス入力とする。フラッシュメモリデータバッファ52
はフラッシュメモリ51とデータバス2とを接続する。
データメモリアドレスセレクタ41はアドレスバス1の
アドレスのうちの第2部分アドレスとメモリ制御手段1
1が出力する制御のためのアドレスとを選択する。デー
タメモリ42はフラッシュメモリ51の書き込み・消去
を行う単位であるブロックと同じ大きさの記憶容量を持
ち、データメモリアドレスセレクタ41が出力するアド
レスをアドレス入力としデータが書き込まれているアド
レスに対応してデータフラグがセットされる。データメ
モリデータバッファ43はデータメモリ42とデータバ
ス2とを接続する。
Next, the flash memory device will be described. This flash memory device performs writing / erasing in units of a block composed of a plurality of memory cells. In this, the memory control means 11 performs overall control. The address register 20 holds a first partial address corresponding to a block number of a block to be written / erased among addresses composed of a first partial address (upper address) and a second partial address (lower address) of the address bus 1. I do. The comparator 30 compares the first partial address held by the address register 20 with the first partial address of the addresses on the address bus 1. The flash memory address selector 50 selects an address on the address bus 1 and an address output from the memory control means 11. The flash memory 51 receives an address output from the flash memory address selector 50 as an address input. Flash memory data buffer 52
Connects the flash memory 51 and the data bus 2.
The data memory address selector 41 stores the second partial address of the addresses on the address bus 1 and the memory control means 1
1 selects an address for control output. The data memory 42 has the same storage capacity as a block which is a unit of writing / erasing of the flash memory 51, and corresponds to an address to which data is written by using an address output from the data memory address selector 41 as an address input. The data flag is set. The data memory data buffer 43 connects the data memory 42 and the data bus 2.

【0024】ここで、メモリ制御手段12は、データ読
み出し時においてアドレスバス1のアドレスとアドレス
レジスタ20に保持されたアドレスとを比較器30で比
較させる。比較器30から不一致出力が発生したときに
は、フラッシュメモリアドレスセレクタ50を通してア
ドレスバス1のアドレスをフラッシュメモリ51へ供給
させ、フラッシュメモリ51からアドレスバス1のアド
レスのデータを読み出させ、フラッシュメモリ51から
読み出されたデータをフラッシュメモリデータバッファ
52を通してデータバス2へ送り出させる。
Here, the memory control means 12 causes the comparator 30 to compare the address of the address bus 1 with the address held in the address register 20 when reading data. When a mismatch output is generated from the comparator 30, the address of the address bus 1 is supplied to the flash memory 51 through the flash memory address selector 50, and the data of the address of the address bus 1 is read from the flash memory 51. The read data is sent to the data bus 2 through the flash memory data buffer 52.

【0025】また、比較器30から一致出力が発生した
ときには、データメモリアドレスセレクタ41を通して
アドレスバス1のアドレスのうちの第2部分アドレスを
データメモリ42へ供給し、アドレスバス1のアドレス
のうちの第2部分アドレスに対応したデータフラグがデ
ータメモリ42にセットされているときにはデータメモ
リ42からアドレスバス1のアドレスのうちの第2部分
アドレスのデータを読み出させ、データメモリ42から
読み出されたデータをデータメモリデータバッファ43
を通してデータバス2へ送り出させ、アドレスバス1の
アドレスのうちの第2部分アドレスに対応したデータフ
ラグがデータメモリ42にセットされていないときには
フラッシュメモリアドレスセレクタ50を通してアドレ
スバス1のアドレスをフラッシュメモリ51へ供給さ
せ、フラッシュメモリ51からアドレスバス1のアドレ
スのデータを読み出させ、フラッシュメモリ51から読
み出されたデータをフラッシュメモリデータバッファ5
2を通してデータバス2へ送り出させる。
When a coincidence output is generated from the comparator 30, the second partial address of the addresses on the address bus 1 is supplied to the data memory 42 through the data memory address selector 41, and the When the data flag corresponding to the second partial address is set in the data memory 42, the data of the second partial address among the addresses on the address bus 1 is read from the data memory 42, and the data read from the data memory 42 is read. Data is stored in the data memory data buffer 43
When the data flag corresponding to the second partial address of the addresses on the address bus 1 is not set in the data memory 42, the address on the address bus 1 is passed through the flash memory address selector 50. To read the data at the address of the address bus 1 from the flash memory 51 and transfer the data read from the flash memory 51 to the flash memory data buffer 5.
2 to the data bus 2.

【0026】また、メモリ制御手段11は、データ書き
込み時において、電源投入後一度もデータの書き込みを
行っていないときには、アドレスバス1のアドレスのう
ちの第1部分アドレスをアドレスレジスタ20に書き込
ませ、アドレスバス1のアドレスのうちの第2部分アド
レスをデータメモリアドレスセレクタ41を通してデー
タメモリ42へ与えることによりデータバス1のデータ
をデータメモリデータバッファ43を通してデータメモ
リ42のアドレスバス1のアドレスのうちの第2部分ア
ドレスに対応した位置に記憶させるとともに、アドレス
バス1のアドレスのうちの第2部分アドレスに対応した
データフラグをセットさせる。
The memory control means 11 causes the address register 20 to write the first partial address of the address on the address bus 1 when data has not been written at all after power-on at the time of data writing. By providing the second partial address of the address of the address bus 1 to the data memory 42 through the data memory address selector 41, the data of the data bus 1 is passed through the data memory data buffer 43 to the address of the address bus 1 of the data memory 42. The data is stored at the position corresponding to the second partial address, and the data flag corresponding to the second partial address among the addresses on the address bus 1 is set.

【0027】また、メモリ制御手段11は、データ書き
込み時において、電源投入後少なくとも一度データの書
き込みを行っていたときには、アドレスレジスタ20が
保持した第1部分アドレスとアドレスバス1の第1部分
アドレスとを比較器30で比較させる。この場合におい
て、比較器30から一致出力が発生したときは、アドレ
スバス1のアドレスのうちの第2部分アドレスをデータ
メモリアドレスセレクタ41を通してデータメモリ42
へ与えることによりデータバス2のデータをデータメモ
リデータバッファ43を通してデータメモリ42のアド
レスバス1のアドレスのうちの第2部分アドレスに対応
した位置に記憶させるとともに、アドレスバス1のアド
レスのうちの第2部分アドレスに対応したデータフラグ
をセットさせる。
When writing data at least once after power-on at the time of data writing, the memory control means 11 reads the first partial address held by the address register 20 and the first partial address of the address bus 1. Are compared by the comparator 30. In this case, when a match output is generated from the comparator 30, the second partial address of the address on the address bus 1 is transferred to the data memory 42 through the data memory address selector 41.
To store the data on the data bus 2 through the data memory data buffer 43 at a position corresponding to the second partial address of the addresses on the address bus 1 of the data memory 42, The data flag corresponding to the two-part address is set.

【0028】また、比較器30から不一致出力が発生し
たときは、アドレスレジスタ20が保持した第1部分ア
ドレスに対応したブロックに含まれる各アドレスを順次
共通にデータメモリアドレスセレクタ41およびフラッ
シュメモリアドレスセレクタ50をそれぞれ通してデー
タメモリ42およびフラッシュメモリ51へ共通に与え
ることにより、フラッシュメモリ51におけるアドレス
バスのアドレスのうちの第1部分アドレスに対応したブ
ロックに含まれる各アドレスのうちデータメモリ42で
データフラグがセットされていないアドレスについての
みデータをデータメモリ42に複写させ、フラッシュメ
モリ51におけるアドレスバス1のアドレスのうちの第
1部分アドレスに対応したブロックのデータを消去し、
フラッシュメモリ51におけるアドレスバス1のアドレ
スのうちの第1部分アドレスに対応したブロックにデー
タメモリ42のデータを書き込ませ、データメモリ42
のデータフラグのセットを取り消し、アドレスバス1の
アドレスのうちの第1部分アドレスをアドレスレジスタ
20に書き込ませ、アドレスバス1のアドレスのうちの
第2部分アドレスをデータメモリアドレスセレクタ41
を通してデータメモリ42へ与えることによりデータバ
ス2のデータをデータメモリデータバッファ43を通し
てデータメモリ42のアドレスバス1のアドレスのうち
の第2部分アドレスに対応した位置に記憶させるととも
に、データメモリ42のアドレスバス1のアドレスのう
ちの第2部分アドレスに対応したデータフラグをセット
させるようにしている。
When a non-coincidence output is generated from the comparator 30, each address included in the block corresponding to the first partial address held by the address register 20 is sequentially and commonly shared by the data memory address selector 41 and the flash memory address selector. 50, the data is supplied to the data memory 42 and the flash memory 51 in common, so that the data memory 42 of the addresses included in the block corresponding to the first partial address among the addresses of the address bus in the flash memory 51 Data is copied to the data memory 42 only for the address for which the flag is not set, and the data of the block corresponding to the first partial address of the addresses on the address bus 1 in the flash memory 51 is erased.
The data of the data memory 42 is written to the block corresponding to the first partial address of the addresses of the address bus 1 in the flash memory 51, and the data memory 42
, The first partial address of the address on the address bus 1 is written to the address register 20, and the second partial address of the address on the address bus 1 is replaced with the data memory address selector 41.
The data of the data bus 2 is stored in a position corresponding to the second partial address of the addresses of the address bus 1 of the data memory 42 through the data memory data buffer 43. The data flag corresponding to the second partial address among the addresses of the bus 1 is set.

【0029】以下、フラッシュメモリ装置の動作につい
て詳しく説明する。電源投入後まだ一度もフラッシュメ
モリ装置にデータを書いていない場合においては、まず
書き込みのあったアドレスのブロック番号、つまり、ア
ドレスバス1のアドレスのうちの第1部分アドレスがア
ドレスレジスタ20に書き込まれる。それと同時に、デ
ータメモリ42のデータ部60には、アドレスバス1の
アドレスのうちの第2部分アドレスに対応するアドレス
にデータが書き込まれ、データフラグ部61がセットさ
れる。この時点ではフラッシュメモリ51に対して書き
込み動作は行わない。
Hereinafter, the operation of the flash memory device will be described in detail. If data has not yet been written to the flash memory device even after power-on, the block number of the address to which the data has been written, that is, the first partial address of the address on the address bus 1 is written to the address register 20. . At the same time, data is written to the data portion 60 of the data memory 42 at an address corresponding to the second partial address of the addresses on the address bus 1, and the data flag portion 61 is set. At this point, no write operation is performed on the flash memory 51.

【0030】図2を参照しながらこの実施の形態の動作
を読み出しと書き込みに分けて説明する。最初に、読み
出しについて説明する。読み出しは2つの状態がある。
アドレスレジスタ20には、過去に書き込みがあったブ
ロック番号が保持してある。2つの状態は、過去に書き
込みを行ったブロックからの読み出しか、過去に書き込
みを行っていないブロックからの読み出しかによって決
定される。
The operation of this embodiment will be described separately for reading and writing with reference to FIG. First, reading will be described. Reading has two states.
The address register 20 holds the number of the block that has been written in the past. The two states are determined by reading from a block to which writing has been performed in the past or reading from a block to which writing has not been performed in the past.

【0031】過去に書き込みを行ったことがないブロッ
クからの読み出しの場合には、比較器30からアドレス
の不一致を示す不一致信号が出力される。この場合、読
み出し時はアドレスバス1のアドレスはフラッシュメモ
リアドレスセレクタ50を通りフラッシュメモリ51に
加えられる。フラッシュメモリ51は加えられたアドレ
スのデータを出力し、フラッシュメモリデータバッファ
52を通してデータバス2にデータを出力する。メモリ
制御手段11はフラッシュメモリアドレスセレクタ50
の選択方向、フラッシュメモリデータバッファ52を制
御する。この場合は単純なメモリ読み出しになる。
In the case of reading from a block to which writing has not been performed in the past, the comparator 30 outputs a mismatch signal indicating an address mismatch. In this case, at the time of reading, the address on the address bus 1 is applied to the flash memory 51 through the flash memory address selector 50. The flash memory 51 outputs the data at the added address, and outputs the data to the data bus 2 through the flash memory data buffer 52. The memory control means 11 includes a flash memory address selector 50
, The flash memory data buffer 52 is controlled. In this case, simple memory reading is performed.

【0032】書き込みを行ったブロックから読み出す場
合には、比較器30から一致したことを示す一致信号が
出力される。この場合、データメモリ42へアドレスバ
ス1のアドレスがデータメモリアドレスセレクタ41を
通して加えられる。データメモリ42のデータフラグ部
61(図4)から書き込みがあったことを示す信号が得
られると、データメモリ42のデータ部60の出力がデ
ータメモリデータバッファ43を通してデータバス2に
出力される。すなわち、過去にデータメモリ42に書い
たデータはデータメモリ42から読み出すことになる。
データメモリ42のデータフラグ部61(図4)から書
き込みがなかったことを示す信号が得られると、アドレ
スバス1のアドレスはフラッシュメモリアドレスセレク
タ50を通りフラッシュメモリ51に加えられる。フラ
ッシュメモリ51は加えられたアドレスのデータを出力
し、フラッシュメモリデータバッファ52を通してデー
タバス2にデータを出力する。この場合はフラッシュメ
モリ51からデータを読み出したことになる。
When reading from the written block, the comparator 30 outputs a coincidence signal indicating the coincidence. In this case, the address of the address bus 1 is added to the data memory 42 through the data memory address selector 41. When a signal indicating that writing has been performed is obtained from the data flag section 61 (FIG. 4) of the data memory 42, the output of the data section 60 of the data memory 42 is output to the data bus 2 through the data memory data buffer 43. That is, data written in the data memory 42 in the past is read from the data memory 42.
When a signal indicating that writing has not been performed is obtained from the data flag section 61 (FIG. 4) of the data memory 42, the address on the address bus 1 is applied to the flash memory 51 through the flash memory address selector 50. The flash memory 51 outputs the data at the added address, and outputs the data to the data bus 2 through the flash memory data buffer 52. In this case, data has been read from the flash memory 51.

【0033】つぎに、データの書き込みについて説明す
る。書き込みは大きく3つの動作に分解できる。1つ目
は電源投入後まだ一度もフラッシュメモリ装置にデータ
を書いていない場合である。2つ目は最近書き込んだブ
ロックと同じブロックに対する書き込みを行う場合で、
3つ目は最近書き込んだブロックと違ったブロックに対
する書き込みを行う場合である。
Next, data writing will be described. Writing can be roughly divided into three operations. The first case is that data has not yet been written to the flash memory device even after power-on. The second is when writing to the same block as the block that was recently written.
The third is a case where writing is performed on a block different from the recently written block.

【0034】最近書き込んだブロックと同じブロックに
対する書き込みを行う場合、アドレスバス1から与えら
れるアドレスとアドレスレジスタ20の内容とが比較器
30で比較されたときに、比較器30からは一致したこ
とを示す一致信号が出力され、これがメモリ制御手段1
1に与えられ、制御方法が決定される。その他は、先に
説明した、電源投入後まだ一度もフラッシュメモリ装置
にデータを書いていない場合と同じである。
When writing to the same block as the block which has been written recently, when the address supplied from the address bus 1 and the content of the address register 20 are compared by the comparator 30, it is determined that the address matches. Is output, and this is the memory control means 1
1 to determine the control method. The other points are the same as those described above in which data has not been written to the flash memory device even once after the power is turned on.

【0035】最近書き込んだブロックと違ったブロック
に対する書き込みを行う場合は、アドレスバス1から与
えられるアドレスとアドレスレジスタ20の内容が比較
器30で比較されたときに、比較器30からは一致しな
いことを示す不一致信号が出力され、これがメモリ制御
手段11に与えられ、制御方法が決定される。この場合
は、フラッシュメモリ51に対して書き込みを行う。書
き込み動作は5つの段階に分解される。
When writing to a block different from the recently written block, when the address supplied from the address bus 1 and the contents of the address register 20 are compared by the comparator 30, the comparator 30 does not agree. Are output to the memory control means 11 to determine the control method. In this case, writing is performed on the flash memory 51. The write operation is broken down into five stages.

【0036】第1番目は、フラッシュメモリ51の内容
をデータメモリ42にコピーする。メモリ制御手段11
は、フラッシュメモリ51とデータメモリ42に対して
アドレスを順次変更しながら以下の操作を行う。まずデ
ータメモリ42を読み出し、データフラグ部61がセッ
トされていれば、書き込みが起こっていることを示すの
で、次のアドレスへ進める。データフラグ部61がセッ
トされていなければ、フラッシュメモリ51を読み出
し、データメモリ42のデータ部60に読み出したデー
タを書き込む。以上でデータメモリ42にはフラッシュ
メモリ51を更新すべきデータが準備できたことにな
る。
First, the contents of the flash memory 51 are copied to the data memory 42. Memory control means 11
Performs the following operations while sequentially changing the addresses of the flash memory 51 and the data memory 42. First, the data memory 42 is read, and if the data flag section 61 is set, it indicates that writing has occurred, and the process proceeds to the next address. If the data flag section 61 has not been set, the flash memory 51 is read, and the read data is written to the data section 60 of the data memory 42. Thus, the data for updating the flash memory 51 is ready in the data memory 42.

【0037】第2の段階は、フラッシュメモリ51の消
去、第3の段階はフラッシュメモリ51に対する書き込
みで、これは第1の実施の形態で説明した第3段階と第
4段階と同じである。第4の段階はデータメモリ42の
データフラグ部61の消去である。メモリ制御手段11
はデータメモリ42のデータフラグ部61に対してデー
タがセットされていない状態を書き込む。
The second stage is erasing of the flash memory 51, and the third stage is writing to the flash memory 51, which is the same as the third and fourth stages described in the first embodiment. The fourth stage is the erasure of the data flag section 61 of the data memory 42. Memory control means 11
Writes a state in which no data is set in the data flag section 61 of the data memory 42.

【0038】第5の段階はアドレスレジスタ20、デー
タメモリ42に対して書き込み情報を保持する。書き込
みのあったアドレスのブロック番号がアドレスレジスタ
20に書き込まれる。それと同時に、データメモリ42
には対応するアドレスにデータがデータ部60に書き込
まれ、データフラグ部61がセットされる。なお、第1
の実施の形態とは異なり、フラッシュメモリ51に対す
る書き込みを行っている間、制御信号出力4によってア
クセスを待たせているので、フラッシュメモリ51に書
き込みを行っている間に読み出しや書き込みの要求が来
ることはない。
In the fifth stage, write information is held in the address register 20 and the data memory 42. The block number of the written address is written to the address register 20. At the same time, the data memory 42
Is written into the data section 60 at the corresponding address, and the data flag section 61 is set. The first
Unlike the embodiment, while the writing to the flash memory 51 is being performed, the access is made to wait by the control signal output 4, so that the reading or writing request comes during the writing to the flash memory 51. Never.

【0039】以上のように、この実施の形態によれば、
アドレスレジスタ20、比較器30、データメモリアド
レスセレクタ41、データメモリ42、データメモリデ
ータバッファ43およびフラッシュメモリアドレスセレ
クタ51を設け、メモリ制御手段11によりフラッシュ
メモリ51への書き込みを制御するようにしたので、専
用のソフトウェアを必要とせずに、フラッシュメモリ5
1に対する複雑なメモリ書き込み操作を簡単に行うこと
ができ、通常のメモリと同じように扱うことが可能であ
る。したがって、フラッシュメモリ51を意識すること
なくアクセスが可能で、その結果一般のメモリを対象に
作成されたソフトウェアをそのまま稼動させることがで
きる。加えて、同一のブロックに対する連続した書き込
みでは、フラッシュメモリ51に対する書き込みが起こ
らず、別なブロックに対する書き込みで初めて書き込み
が起こるので、同一ブロックに対する連続した書き込み
に対して一度の書き込みで完了し、したがって書き込み
回数を少なくでき、書き込みによるアクセス制限時間が
減少し、フラッシュメモリ51を使用することによる性
能低下が比較的少なくできる。
As described above, according to this embodiment,
The address register 20, the comparator 30, the data memory address selector 41, the data memory 42, the data memory data buffer 43, and the flash memory address selector 51 are provided, and the writing to the flash memory 51 is controlled by the memory control means 11. Flash memory 5 without special software
1 can easily perform a complicated memory write operation, and can be handled in the same manner as a normal memory. Therefore, access is possible without being conscious of the flash memory 51, and as a result, software created for a general memory can be operated as it is. In addition, in continuous writing to the same block, writing to the flash memory 51 does not occur, and writing occurs for the first time in writing to another block. Therefore, continuous writing to the same block is completed by one writing, and The number of times of writing can be reduced, the access restriction time by writing can be reduced, and the performance degradation due to the use of the flash memory 51 can be relatively reduced.

【0040】なお、アドレスレジスタとデータレジスタ
とを1組追加すれば、第1の実施の形態と同様にフラッ
シュメモリ51への書き込みが起こるバスからの書き込
みに対しても、バスを待たせないようにできる。また、
データメモリアドレスセレクタ41とデータメモリ42
とデータメモリデータバッファ43は、図6に示すよう
な2系統のアドレス端子AD1,AD2とこのアドレス
端子AD1,AD2にそれぞれ対応した2系統のデータ
端子DT1,DT2を有するデュアルポートメモリ45
で置き換えることができる。具体的には、データメモリ
アドレスセレクタ41の2つの入力端子とデュアルポー
トメモリ45の2つのアドレス端子AD1,AD2とが
対応し、データメモリ42の出力端子とデュアルポート
メモリ45の一方のデータ端子DT1とが対応し、デー
タメモリデータバッファ43の出力端子とデュアルポー
トメモリ45の他方のデータ端子DT2とが対応する。
If a set of an address register and a data register is added, the bus does not wait for writing from the bus in which writing to the flash memory 51 occurs, as in the first embodiment. Can be. Also,
Data memory address selector 41 and data memory 42
The data buffer 43 includes a dual port memory 45 having two address terminals AD1 and AD2 as shown in FIG. 6 and two data terminals DT1 and DT2 corresponding to the address terminals AD1 and AD2, respectively.
Can be replaced by Specifically, two input terminals of the data memory address selector 41 correspond to two address terminals AD1 and AD2 of the dual port memory 45, and an output terminal of the data memory 42 and one data terminal DT1 of the dual port memory 45. Corresponds to the output terminal of the data memory data buffer 43 and the other data terminal DT2 of the dual port memory 45.

【0041】(第3の実施の形態)図3は本発明の第3
の実施の形態におけるフラッシュメモリ装置の構成を示
すブロック図である。図3において、1はアドレスバ
ス、2はデータバス、3は制御信号入力、4は制御信号
出力、12はメモリ制御手段、21はアドレスタグメモ
リアドレスセレクタ、22はアドレスタグメモリ、23
はアドレスタグメモリデータバッファ、30は比較器、
41はデータメモリアドレスセレクタ、42はデータメ
モリ、43はデータメモリデータバッファ、50はフラ
ッシュメモリアドレスセレクタ、51はフラッシュメモ
リ、52はフラッシュメモリデータバッファである。
(Third Embodiment) FIG. 3 shows a third embodiment of the present invention.
FIG. 3 is a block diagram showing a configuration of a flash memory device according to the embodiment. 3, 1 is an address bus, 2 is a data bus, 3 is a control signal input, 4 is a control signal output, 12 is a memory control means, 21 is an address tag memory address selector, 22 is an address tag memory, 23
Is an address tag memory data buffer, 30 is a comparator,
41 is a data memory address selector, 42 is a data memory, 43 is a data memory data buffer, 50 is a flash memory address selector, 51 is a flash memory, and 52 is a flash memory data buffer.

【0042】図5(a)はフラッシュメモリ装置のアド
レスのビット構成を示し、図5(b)はアドレスタグメ
モリ22のビット構成を示す。図5(a)のフラッシュ
メモリ装置のアドレスのビット構成において、図の左側
は上位桁側を示している。全体は3つの部分(第1部分
アドレス(例えば上位アドレス)、第2部分アドレス
(例えば中位アドレス)、第3部分アドレス(例えば下
位アドレス))に分割でき、下位の桁(第3部分アドレ
ス)はフラッシュメモリ51のブロックアドレス空間に
相当する部分である。例えば、ブロックの大きさが25
6アドレスであれば、8ビットがこれに該当する。次の
部分(第2部分アドレス)はアドレスタグメモリ22の
アドレスに加えられる部分である。この部分と先ほどの
ブロックアドレスに相当する部分がデータメモリ42の
アドレスに加えられる。アドレスの残る部分(第1部分
アドレス)はアドレスタグメモリ22のデータに加えら
れる。
FIG. 5A shows the bit configuration of the address of the flash memory device, and FIG. 5B shows the bit configuration of the address tag memory 22. In the bit configuration of the address of the flash memory device in FIG. 5A, the left side of the figure shows the upper digit side. The whole can be divided into three parts (first partial address (for example, upper address), second partial address (for example, middle address), and third partial address (for example, lower address)), and lower digits (third partial address) Is a portion corresponding to the block address space of the flash memory 51. For example, if the block size is 25
If there are six addresses, eight bits correspond to this. The next part (second partial address) is a part added to the address of the address tag memory 22. This part and a part corresponding to the above block address are added to the address of the data memory 42. The remaining portion of the address (first partial address) is added to the data in the address tag memory 22.

【0043】図5(b)のアドレスタグメモリ22のデ
ータのビット構成において、62は図5(a)の最上位
部(第1部分アドレス)がデータ(データメモリ42に
格納してあるデータのブロック番号の一部)に加えられ
たもので、アドレスタグ部と呼び、フラッシュメモリ5
1に対して書き込みを行った時点である条件に従って書
き込まれる。この部分はメモリ制御手段12が読み出し
および書き込みを行うことができ、アドレスバス1およ
びデータバス2からの読み出し、書き込みはできない。
63はアドレスタグフラグ部で、フラッシュメモリ51
に対して書き込みを行った時点である条件に従って書き
込まれ、アドレスタグ部62が有効であることを示して
おり、アドレスタグ部62に対して書き込みが起こった
ならばセットされる。この部分はメモリ制御手段12が
読み出し、書き込みを行うことができ、アドレスバス1
およびデータバス2からの読み出し、書き込みはできな
い。
In the bit configuration of the data in the address tag memory 22 shown in FIG. 5B, reference numeral 62 denotes the data (data stored in the data memory 42) in the uppermost part (first partial address) of FIG. (Part of the block number), which is called an address tag section.
1 is written in accordance with a condition at the time of writing. This portion can be read and written by the memory control means 12, and cannot be read and written from the address bus 1 and the data bus 2.
63 is an address tag flag section,
Is written in accordance with the condition at the time of writing to the address tag unit 62, indicating that the address tag unit 62 is valid, and is set when writing to the address tag unit 62 occurs. This part can be read and written by the memory control means 12, and the address bus 1
In addition, reading and writing from the data bus 2 cannot be performed.

【0044】つぎに、フラッシュメモリ装置について説
明する。このフラッシュメモリ装置は、複数個のメモリ
セルで構成されるブロックを単位として書き込み・消去
を行うものである。この中で、メモリ制御手段12は全
体の制御を行う。アドレスタグメモリアドレスセレクタ
21はアドレスバス1の第1部分アドレス,第2部分ア
ドレスおよび第3部分アドレスからなるアドレスのうち
の書き込み・消去を行うべきブロックのブロック番号に
対応した第2部分アドレスとメモリ制御手段12が出力
するアドレスとを選択する。アドレスタグメモリ22は
アドレスタグメモリアドレスセレクタ21から出力され
るアドレスをアドレス入力としデータが書き込まれてい
るアドレスに対応してアドレスタグフラグがセットされ
る。アドレスタグメモリデータバッファ23はアドレス
タグメモリ22とアドレスバス1とを接続してアドレス
バス1の第1部分アドレスをアドレスタグメモリ22へ
データ入力として供給する。比較器30はアドレスバス
1のアドレスのうちの第2部分アドレスをアドレス入力
としてアドレスタグメモリ22から読み出されるアドレ
スとアドレスバス1のアドレスのうちの第1部分アドレ
スとを比較する。フラッシュメモリアドレスセレクタ5
0はアドレスバス1のアドレスとメモリ制御手段12が
出力するアドレスとを選択する。フラッシュメモリ51
はフラッシュメモリアドレスセレクタ50から出力され
るアドレスをアドレス入力とする。フラッシュメモリデ
ータバッファ52はフラッシュメモリ51とデータバス
2とを接続する。データメモリアドレスセレクタ41は
アドレスバス1のアドレスのうちの第2部分アドレスお
よび第3部分アドレスとメモリ制御手段12が出力する
制御のためのアドレスとを選択する。データメモリ42
はフラッシュメモリ51の書き込み・消去の単位である
ブロックの第2部分アドレスのアドレス空間の大きさに
相当する個数分と同じ容量を持ち、データメモリアドレ
スセレクタ41が出力するアドレスをアドレス入力とし
データが書き込まれているアドレスに対応してデータフ
ラグがセットされる。データメモリデータバッファ43
はデータメモリ42とデータバス2とを接続する。
Next, the flash memory device will be described. This flash memory device performs writing / erasing in units of a block composed of a plurality of memory cells. In this, the memory control means 12 performs overall control. The address tag memory address selector 21 stores a second partial address corresponding to a block number of a block to be written / erased out of an address consisting of a first partial address, a second partial address, and a third partial address of the address bus 1 and a memory. An address output by the control means 12 is selected. The address tag memory 22 receives the address output from the address tag memory address selector 21 as an address input, and sets an address tag flag corresponding to the address where data is written. The address tag memory data buffer 23 connects the address tag memory 22 and the address bus 1 and supplies a first partial address of the address bus 1 to the address tag memory 22 as a data input. The comparator 30 compares the address read from the address tag memory 22 with the first partial address of the address bus 1 using the second partial address of the address bus 1 as an address input. Flash memory address selector 5
0 selects an address on the address bus 1 and an address output from the memory control means 12. Flash memory 51
Uses the address output from the flash memory address selector 50 as an address input. The flash memory data buffer 52 connects the flash memory 51 and the data bus 2. The data memory address selector 41 selects a second partial address and a third partial address of the addresses on the address bus 1 and an address for control output from the memory control means 12. Data memory 42
Has the same capacity as the number corresponding to the size of the address space of the second partial address of the block, which is the unit of writing / erasing of the flash memory 51. A data flag is set corresponding to the address where the data is written. Data memory data buffer 43
Connects the data memory 42 and the data bus 2.

【0045】上記のメモリ制御手段12は、データ読み
出し時においてアドレスバス1のアドレスのうちの第1
部分アドレスとアドレスバス1のアドレスのうちの第2
部分アドレスをアドレスタグメモリアドレスセレクタ2
1を通しアドレス入力としてアドレスタグメモリ22か
ら読み出させたデータとを比較器30で比較させる。こ
の場合において、比較器30から不一致出力が発生した
ときには、フラッシュメモリアドレスセレクタ50を通
してアドレスバス1のアドレスをフラッシュメモリ51
へ供給させ、フラッシュメモリ51からアドレスバス1
のアドレスのデータを読み出させ、フラッシュメモリ5
1から読み出されたデータをフラッシュメモリデータバ
ッファ52を通してデータバス2へ送り出させる。
The above-mentioned memory control means 12 controls the first of the addresses on the address bus 1 when reading data.
The second of the partial address and the address of the address bus 1
Partial address is assigned to address tag memory address selector
The comparator 30 compares the data read from the address tag memory 22 as the address input through 1 with the comparator 30. In this case, when a mismatch output is generated from the comparator 30, the address of the address bus 1 is transferred to the flash memory 51 through the flash memory address selector 50.
To the address bus 1 from the flash memory 51.
Of the flash memory 5
The data read from 1 is sent to the data bus 2 through the flash memory data buffer 52.

【0046】また、比較器30から一致出力が発生した
ときには、データメモリアドレスセレクタ41を通して
アドレスバス1のアドレスのうちの第2部分アドレスお
よび第3部分アドレスをデータメモリ42へ供給し、ア
ドレスバス1のアドレスのうちの第2部分アドレスおよ
び第3部分アドレスに対応したデータフラグがデータメ
モリ42にセットされているときにはデータメモリ42
からアドレスバス1のアドレスのうちの第2部分アドレ
スおよび第3部分アドレスのデータを読み出させ、デー
タメモリ42から読み出されたデータをデータメモリデ
ータバッファ43を通してデータバス2へ送り出させ
る。一方、アドレスバス1のアドレスのうちの第2部分
アドレスおよび第3部分アドレスに対応したデータフラ
グがデータメモリ42にセットされていないときにはフ
ラッシュメモリアドレスセレクタ50を通してアドレス
バス1のアドレスをフラッシュメモリ51へ供給させ、
フラッシュメモリ51からアドレスバス1のアドレスの
データを読み出させ、フラッシュメモリ51から読み出
されたデータをフラッシュメモリデータバッファ52を
通してデータバス2へ送り出させる。
When a coincidence output is generated from the comparator 30, the second partial address and the third partial address of the addresses on the address bus 1 are supplied to the data memory 42 through the data memory address selector 41. Are set in the data memory 42 when the data flags corresponding to the second partial address and the third partial address of the
, The data of the second partial address and the third partial address of the addresses of the address bus 1 are read, and the data read from the data memory 42 is sent to the data bus 2 through the data memory data buffer 43. On the other hand, when the data flags corresponding to the second partial address and the third partial address of the addresses on the address bus 1 are not set in the data memory 42, the address on the address bus 1 is transferred to the flash memory 51 through the flash memory address selector 50. Supply
The data at the address of the address bus 1 is read from the flash memory 51, and the data read from the flash memory 51 is sent to the data bus 2 through the flash memory data buffer 52.

【0047】また、メモリ制御手段12は、データ書き
込み時において、アドレスタグメモリ22の全てのアド
レスへの書き込みを完了する前には、アドレスバス1の
アドレスのうちの第2部分アドレスをアドレスタグメモ
リアドレスセレクタ21を通しアドレス入力とするとと
もにアドレスバス1のアドレスのうちの第1部分アドレ
スをデータ入力としてアドレスタグメモリ22に書き込
みを行わせるとともに、アドレスタグメモリ22におけ
るデータ書き込みを行ったアドレスに対応するアドレス
タグフラグをセットさせ、アドレスバス1のアドレスの
うちの第2部分アドレスおよび第3部分アドレスをデー
タメモリアドレスセレクタ41を通してデータメモリ4
2へ与えることにより、データバス2のデータをデータ
メモリデータバッファ43を通してデータメモリ42の
アドレスバス1のアドレスのうちの第2部分アドレスお
よび第3部分アドレスに対応した位置に記憶させるとと
もに、データメモリ42におけるアドレスバス1のアド
レスのうちの第2部分アドレスおよび第3部分アドレス
に対応したデータフラグをセットさせる。
Further, at the time of writing data, the memory control means 12 writes the second partial address of the address on the address bus 1 to the address tag memory before completing writing to all the addresses of the address tag memory 22. The address input is made through the address selector 21 and the first partial address of the address on the address bus 1 is written as data input to the address tag memory 22 to write the data. And the second partial address and the third partial address of the addresses on the address bus 1 are passed through the data memory address selector 41 to the data memory 4.
2 to store the data on the data bus 2 through the data memory data buffer 43 at the positions corresponding to the second and third partial addresses of the addresses on the address bus 1 of the data memory 42, The data flag corresponding to the second partial address and the third partial address among the addresses on the address bus 1 at 42 is set.

【0048】さらに、メモリ制御手段12は、データ書
き込み時において、アドレスタグメモリ22の全てのア
ドレスへの書き込みが完了してアドレスタグメモリ22
の全てのアドレス対応したアドレスタグフラグがすべて
セットされた後には、アドレスバス1のアドレスのうち
の第1部分アドレスとアドレスバス1のアドレスのうち
の第2部分アドレスをアドレス入力としてアドレスタグ
メモリ22から読み出させたデータとを比較器30で比
較させる。
Further, at the time of data writing, the memory control means 12 completes writing to all addresses of the address tag memory 22 and
After all the address tag flags corresponding to all the addresses of the address bus 1 are set, the address tag memory 22 receives the first partial address of the address of the address bus 1 and the second partial address of the address of the address bus 1 as an address input. Is compared with the data read from the.

【0049】この場合において、比較器30から一致出
力が発生したときには、アドレスバス1のアドレスのう
ちの第2部分アドレスおよび第3部分アドレスをデータ
メモリアドレスセレクタ41を通してデータメモリ42
へ与えることにより、データバス2のデータをデータメ
モリデータバッファ43を通してデータメモリ42のア
ドレスバス1のアドレスのうちの第2部分アドレスおよ
び第3部分アドレスに対応した位置に記憶させるととも
に、データメモリ42のアドレスバス1のアドレスのう
ちの第2部分アドレスおよび第3部分アドレスに対応し
たデータフラグをセットさせる。
In this case, when a coincidence output is generated from the comparator 30, the second partial address and the third partial address of the addresses on the address bus 1 are transferred to the data memory 42 through the data memory address selector 41.
To store the data on the data bus 2 through the data memory data buffer 43 at a position corresponding to the second partial address and the third partial address of the addresses on the address bus 1 of the data memory 42, and The data flag corresponding to the second partial address and the third partial address among the addresses on the address bus 1 is set.

【0050】また、比較器30から不一致出力が発生し
たときには、アドレスタグメモリ22の全てのアドレス
とそれらのアドレスに記憶させたデータとによってそれ
ぞれ決まる複数組の第1部分アドレスおよび第2部分ア
ドレスに対応した個数のブロックに含まれる各アドレス
を順次共通にデータメモリアドレスセレクタ41および
フラッシュメモリアドレスセレクタ50をそれぞれ通し
てデータメモリ42およびフラッシュメモリ51へ共通
に与えることにより、フラッシュメモリ51におけるア
ドレスバス1のアドレスのうちの複数組の第1部分アド
レスおよび第2部分アドレスに対応した個数のブロック
に含まれる各アドレスのうちデータメモリ42でデータ
フラグがセットされていないアドレスについてのみデー
タをデータメモリ42に複写させる。つづいて、アドレ
スタグメモリ22の全てのアドレスとそれらのアドレス
に記憶させたデータとによってそれぞれ決まる複数組の
第1部分アドレスおよび第2部分アドレスに対応したブ
ロックのデータを消去する。つづいて、フラッシュメモ
リ51におけるアドレスバス1のアドレスのうちの複数
組の第1部分アドレスおよび第2部分アドレスに対応し
たブロックにデータメモリ42のデータを書き込ませ
る。つづいて、データメモリ42のデータフラグのセッ
トを取り消す。つづいてアドレスタグメモリ22の全て
のアドレスへの書き込みを完了するまで、アドレスバス
1のアドレスのうちの第2部分アドレスをアドレスタグ
メモリアドレスセレクタ21を通しアドレス入力とする
とともにアドレスバス1のアドレスのうちの第1部分ア
ドレスをデータ入力としてアドレスタグメモリ22に書
き込みを行わせるとともに、アドレスタグメモリ22に
おけるデータ書き込みを行ったアドレスに対応するアド
レスタグフラグをセットさせる。また、アドレスバス1
のアドレスのうちの第2部分アドレスおよび第3部分ア
ドレスをデータメモリアドレスセレクタ41を通してデ
ータメモリ42へ与えることにより、データバス2のデ
ータをデータメモリデータバッファ43を通してデータ
メモリ42のアドレスバス1のアドレスのうちの第2部
分アドレスおよび第3部分アドレスに対応した位置に記
憶させるとともに、データメモリ42におけるアドレス
バス1のアドレスのうちの第2部分アドレスおよび第3
部分アドレスに対応したデータフラグをセットさせる。
When a non-coincidence output is generated from the comparator 30, a plurality of sets of the first partial address and the second partial address respectively determined by all the addresses of the address tag memory 22 and the data stored at those addresses are set. Each address included in the corresponding number of blocks is sequentially and commonly applied to the data memory 42 and the flash memory 51 through the data memory address selector 41 and the flash memory address selector 50, respectively. Out of the addresses included in the blocks corresponding to the plurality of sets of the first partial address and the second partial address out of the plurality of addresses, only the addresses for which the data flag is not set in the data memory 42 are stored in the data memory. To be copied to 2. Subsequently, the data of the blocks corresponding to a plurality of sets of the first partial address and the second partial address respectively determined by all the addresses of the address tag memory 22 and the data stored in those addresses are erased. Subsequently, the data of the data memory 42 is written to blocks corresponding to a plurality of sets of the first partial address and the second partial address among the addresses of the address bus 1 in the flash memory 51. Subsequently, the setting of the data flag in the data memory 42 is canceled. Then, until the writing to all the addresses of the address tag memory 22 is completed, the second partial address of the addresses on the address bus 1 is used as the address input through the address tag memory address selector 21 and the address of the address on the address bus 1 is input. The first part of the addresses is used as a data input to write to the address tag memory 22, and the address tag flag corresponding to the address in the address tag memory 22 at which the data is written is set. Address bus 1
Are given to the data memory 42 through the data memory address selector 41 to transfer the data of the data bus 2 to the address of the address bus 1 of the data memory 42 through the data memory data buffer 43. Among the addresses of the address bus 1 in the data memory 42 and the third partial address and the third partial address.
The data flag corresponding to the partial address is set.

【0051】この実施の形態における基本的な動作は、
第2の実施の形態に近いので、その差がある部分のみを
さらに詳しく説明する。大きな差はアドレスレジスタ2
0に代えて、アドレスタグメモリアドレスセレクタ21
とアドレスタグメモリ22とアドレスタグメモリデータ
バッファ23を用いる点と、その容量に対応してデータ
メモリ42の容量を増やした点である。これにより複数
のブロックに対して、書き込んだデータを保持でき、第
2の実施の形態に比べ、フラッシュメモリ51への書き
込みをより減らすことができる。
The basic operation in this embodiment is as follows.
Since it is close to the second embodiment, only the difference will be described in more detail. The big difference is the address register 2
0, the address tag memory address selector 21
And the use of the address tag memory 22 and the address tag memory data buffer 23, and the capacity of the data memory 42 is increased corresponding to the capacity. As a result, the written data can be held in a plurality of blocks, and the number of writes to the flash memory 51 can be reduced as compared with the second embodiment.

【0052】読み出しでは、アドレスタグメモリ22に
は過去に書き込みを行ったブロックが記録してある。過
去に書き込みが起こっていないブロックに対する読み出
しのときには、比較器30が不一致信号を発し、これを
受けメモリ制御手段12はアドレスバス1、フラッシュ
メモリアドレスセレクタ50、フラッシュメモリ51、
フラッシュメモリデータバッファ52、データバス2の
経路を作る。これはフラッシュメモリ51からの直接の
読み出しになる。
In reading, blocks to which writing has been performed in the past are recorded in the address tag memory 22. At the time of reading from a block in which writing has not occurred in the past, the comparator 30 generates a mismatch signal.
A path for the flash memory data buffer 52 and the data bus 2 is created. This is a direct read from the flash memory 51.

【0053】過去に書き込みが起こったブロックに対す
る読み出しのときには、比較器30が一致信号を発し、
これを受けメモリ制御手段12はアドレスバス1、デー
タメモリアドレスセレクタ41、データメモリ42の経
路と、アドレスバス1、フラッシュメモリアドレスセレ
クタ50、フラッシュメモリ51の経路の合わせて2つ
の経路がまず作られる。ここで、データメモリ42のデ
ータフラグ部61から過去に書き込みがあったことを示
す信号が得られれば、データメモリデータバッファ4
3、データバス2の経路を作り、過去の書き込みを行っ
た内容を出力する。一方、データメモリ42のデータフ
ラグ部61から過去に書き込みがなかったことを示す信
号が得られれば、フラッシュメモリデータバッファ5
2、データバス2の経路を作り、フラッシュメモリ51
の内容を出力する。
When reading from a block in which writing has occurred in the past, the comparator 30 issues a coincidence signal,
In response to this, the memory control means 12 first makes two paths including the paths of the address bus 1, the data memory address selector 41 and the data memory 42 and the paths of the address bus 1, the flash memory address selector 50 and the flash memory 51. . Here, if a signal indicating that data has been written in the past is obtained from the data flag unit 61 of the data memory 42, the data memory data buffer 4
3. Create a path for the data bus 2 and output the contents of the past write. On the other hand, if a signal indicating that writing has not been performed in the past is obtained from the data flag unit 61 of the data memory 42, the flash memory data buffer 5
2. Make a path for the data bus 2 and use the flash memory 51
Output the contents of

【0054】書き込みで、比較器30から一致したこと
を示す信号が得られたならば、過去に書き込みを行った
ブロックであるので、データメモリアドレスセレクタ4
1、データメモリ42の経路で書き込んだ内容をデータ
メモリ42に格納する。比較器30から不一致を示す信
号が得られたならば、フラッシュメモリ51に対する書
き込みを行う。この部分は第2の実施の形態と同じであ
る。フラッシュメモリ51に対する書き込みが完了した
なら、アドレスタグメモリ22、データメモリ42の更
新を行う。
If a signal indicating the coincidence is obtained from the comparator 30 in the writing, the data memory address selector 4
1. The contents written along the path of the data memory 42 are stored in the data memory 42. When a signal indicating a mismatch is obtained from the comparator 30, writing to the flash memory 51 is performed. This part is the same as in the second embodiment. When the writing to the flash memory 51 is completed, the address tag memory 22 and the data memory 42 are updated.

【0055】以上のようにこの実施の形態によれば、ア
ドレスタグメモリアドレスセレクタ21、アドレスタグ
メモリ22、アドレスタグメモリデータバッファ23、
比較器30、データメモリアドレスセレクタ41、デー
タメモリ42、データメモリデータバッファ43および
フラッシュメモリアドレスセレクタ51を設け、メモリ
制御手段12によりフラッシュメモリ51への書き込み
を制御するようにしたので、専用のソフトウェアを必要
とせずに、フラッシュメモリ51に対する複雑なメモリ
書き込み操作を簡単に行うことができ、通常のメモリと
同じように扱うことが可能である。したがって、フラッ
シュメモリ51を意識することなくアクセスが可能で、
その結果一般のメモリを対象に作成されたソフトウェア
をそのまま稼動させることができる。加えて、複数のブ
ロックに対する連続した書き込みでは、フラッシュメモ
リ51に対する書き込みが起こらず、上記複数のブロッ
ク以外の別のブロックに対する書き込みで初めて複数の
ブロックの書き込みが起こるので、複数個のブロックに
対する連続した書き込みに対して一度の書き込みで完了
し書き込み時間をいっそう短縮できる。したがって、書
き込み回数をいっそう少なくでき、書き込みによるアク
セス制限時間がいっそう減少し、フラッシュメモリ51
を使用することによる性能低下をより一層少なくでき
る。
As described above, according to this embodiment, the address tag memory address selector 21, the address tag memory 22, the address tag memory data buffer 23,
The comparator 30, the data memory address selector 41, the data memory 42, the data memory data buffer 43, and the flash memory address selector 51 are provided, and the writing to the flash memory 51 is controlled by the memory control means 12. , A complicated memory write operation to the flash memory 51 can be easily performed, and can be handled in the same manner as a normal memory. Therefore, access is possible without being conscious of the flash memory 51,
As a result, software created for a general memory can be operated as it is. In addition, in continuous writing to a plurality of blocks, writing to the flash memory 51 does not occur, and writing to a plurality of blocks occurs for the first time in writing to another block other than the plurality of blocks. The writing is completed by one writing, and the writing time can be further reduced. Therefore, the number of times of writing can be further reduced, and the access restriction time by writing is further reduced.
Can be further reduced by the use of a.

【0056】なお、アドレスタグメモリアドレスセレク
タ21とアドレスタグメモリ22とアドレスタグメモリ
データバッファ23に代えて、図7に示すような2系統
のアドレス端子AD1,AD2とこのアドレス端子AD
1,AD2に対応した2系統のデータ端子DT1,DT
2を有するデュアルポートRAM24を利用することも
できる。具体的には、アドレスタグメモリアドレスセレ
クタ21の2つの入力端子とデュアルポートRAM24
の2つのアドレス端子AD1,AD2とが対応し、アド
レスタグメモリ22の出力端子とデュアルポートRAM
24の一方のデータ端子DT1と対応している。なお、
デュアルポートRAM24の他方のデータ端子DT2
はデュアルポートRAM24のアドレス端子AD2に接
続されている。
Instead of the address tag memory address selector 21, the address tag memory 22, and the address tag memory data buffer 23, two address terminals AD1 and AD2 as shown in FIG.
1, AD2, two systems of data terminals DT1, DT
A dual port RAM 24 having two RAMs can also be used. Specifically, two input terminals of the address tag memory address selector 21 and the dual port RAM 24
Address terminals AD1 and AD2 correspond to the output terminal of the address tag memory 22 and the dual port RAM.
It corresponds to one of the 24 data terminals DT1. In addition,
The other data terminal DT2 of the dual port RAM 24
Is connected to the address terminal AD2 of the dual port RAM 24.

【0057】また、図5(a)にはアドレス空間のビッ
ト構成の配置順序を並べ替えることが可能で、また、ビ
ットを連続して分割する必要も無い。第2の実施の形態
で触れたように、アドレスレジスタ、データレジスタを
アドレスメモリアドレスセレクタ、データメモリアドレ
スセレクタの前に置くことによって、書き込み動作の初
期にバスを開放することも可能である。
In FIG. 5A, the arrangement order of the bit configuration in the address space can be rearranged, and there is no need to continuously divide the bits. As mentioned in the second embodiment, it is possible to open the bus at the beginning of the write operation by placing the address register and the data register before the address memory address selector and the data memory address selector.

【0058】[0058]

【発明の効果】請求項1記載のフラッシュメモリ装置に
よれば、メモリ制御手段によりフラッシュメモリへの書
き込みを制御するようにしたので、専用のソフトウェア
を必要とせずに、フラッシュメモリに対する複雑なメモ
リ書き込み操作を簡単に行うことができ、通常のメモリ
と同じように扱うことが可能である。したがって、一般
のメモリを使用したこれまでのパソコンや携帯情報端末
のソフトがそのまま利用でき、加えてフラッシュメモリ
を使用することによる性能低下を少なくでき、なおかつ
電池が無くなることによる危険性が無いメモリ装置が実
現でき、実用上非常に有利である。
According to the flash memory device of the first aspect, since writing to the flash memory is controlled by the memory control means, complicated memory writing to the flash memory can be performed without requiring dedicated software. The operation can be performed easily, and it can be handled in the same way as a normal memory. Therefore, a memory device that can use the software of a conventional personal computer or personal digital assistant using a general memory as it is, can reduce the performance degradation due to the use of the flash memory, and has no danger due to the loss of the battery Can be realized, which is very advantageous in practice.

【0059】請求項2記載のフラッシュメモリ装置によ
れば、メモリ制御手段によりフラッシュメモリへの書き
込みを制御するようにしたので、専用のソフトウェアを
必要とせずに、フラッシュメモリに対する複雑なメモリ
書き込み操作を簡単に行うことができ、通常のメモリと
同じように扱うことが可能である。しかも、同一ブロッ
クに対する連続した書き込みに対して一度の書き込みで
完了し書き込み時間が短縮できる。したがって、一般の
メモリを使用したこれまでのパソコンや携帯情報端末の
ソフトがそのまま利用でき、加えてフラッシュメモリを
使用することによる性能低下を少なくでき、なおかつ電
池が無くなることによる危険性が無いメモリ装置が実現
でき、実用上非常に有利である。請求項3記載のフラッ
シュメモリ装置によれば、メモリ制御手段によりフラッ
シュメモリへの書き込みを制御するようにしたので、専
用のソフトウェアを必要とせずに、フラッシュメモリに
対する複雑なメモリ書き込み操作を簡単に行うことがで
き、通常のメモリと同じように扱うことが可能である。
しかも、複数個のブロックに対する連続した書き込みに
対して一度の書き込みで完了し書き込み時間をいっそう
短縮できる。したがって、一般のメモリを使用したこれ
までのパソコンや携帯情報端末のソフトがそのまま利用
でき、加えてフラッシュメモリを使用することによる性
能低下を少なくでき、なおかつ電池が無くなることによ
る危険性が無いメモリ装置が実現でき、実用上非常に有
利である。
According to the flash memory device of the present invention, since writing to the flash memory is controlled by the memory control means, a complicated memory writing operation to the flash memory can be performed without requiring dedicated software. It can be done easily and can be handled like a normal memory. In addition, continuous writing to the same block is completed by one writing, and the writing time can be reduced. Therefore, a memory device that can use the software of a conventional personal computer or personal digital assistant using a general memory as it is, can reduce the performance degradation due to the use of the flash memory, and has no danger due to the loss of the battery Can be realized, which is very advantageous in practice. According to the flash memory device of the third aspect, since writing to the flash memory is controlled by the memory control means, a complicated memory writing operation to the flash memory can be easily performed without requiring dedicated software. And can be treated like normal memory.
In addition, continuous writing to a plurality of blocks is completed by one writing, and the writing time can be further reduced. Therefore, a memory device that can use the software of a conventional personal computer or personal digital assistant using a general memory as it is, can reduce the performance degradation due to the use of the flash memory, and has no danger due to the loss of the battery Can be realized, which is very advantageous in practice.

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

【図1】本発明の第1の実施の形態におけるフラッシュ
メモリ装置の構成を示すブロック図である。
FIG. 1 is a block diagram showing a configuration of a flash memory device according to a first embodiment of the present invention.

【図2】本発明の第2の実施の形態におけるフラッシュ
メモリ装置の構成を示すブロック図である。
FIG. 2 is a block diagram showing a configuration of a flash memory device according to a second embodiment of the present invention.

【図3】本発明の第3の実施の形態におけるフラッシュ
メモリ装置の構成を示すブロック図である。
FIG. 3 is a block diagram showing a configuration of a flash memory device according to a third embodiment of the present invention.

【図4】データメモリのデータのビット構成を示す概略
図である。
FIG. 4 is a schematic diagram showing a bit configuration of data in a data memory.

【図5】アドレスタグメモリのデータのビット構成を示
す概略略図である。
FIG. 5 is a schematic diagram showing a bit configuration of data of an address tag memory.

【図6】データメモリアドレスセレクタ、データメモリ
およびデータメモリデータバッファからデュアルポート
メモリへの置き換えを説明するための概略図である。
FIG. 6 is a schematic diagram for explaining replacement of a data memory address selector, a data memory, and a data memory data buffer with a dual port memory;

【図7】アドレスタグメモリアドレスセレクタ、アドレ
スタグメモリおよびアドレスタグメモリデータバッファ
からデュアルポートメモリへの置き換えを説明するため
の概略図である。
FIG. 7 is a schematic diagram for explaining replacement of an address tag memory address selector, an address tag memory, and an address tag memory data buffer with a dual-port memory;

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

1 アドレスバス 2 データバス 3 制御信号入力 4 制御信号出力 10 メモリ制御手段 11 メモリ制御手段 12 メモリ制御手段 20 アドレスレジスタ 21 アドレスタグメモリアドレスセレクタ 22 アドレスタグメモリ 23 アドレスタグメモリデータバッファ 30 比較器 40 データレジスタ 41 データメモリアドレスセレクタ 42 データメモリ 43 データメモリデータバッファ 44 データメモリ 50 フラッシュメモリアドレスセレクタ 51 フラッシュメモリ 52 フラッシュメモリデータバッファ 60 データ部 61 データフラグ部 62 アドレスタグ部 63 アドレスタグフラグ部 DESCRIPTION OF SYMBOLS 1 Address bus 2 Data bus 3 Control signal input 4 Control signal output 10 Memory control means 11 Memory control means 12 Memory control means 20 Address register 21 Address tag memory address selector 22 Address tag memory 23 Address tag memory data buffer 30 Comparator 40 Data Register 41 Data memory address selector 42 Data memory 43 Data memory data buffer 44 Data memory 50 Flash memory address selector 51 Flash memory 52 Flash memory data buffer 60 Data section 61 Data flag section 62 Address tag section 63 Address tag flag section

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】 複数個のメモリセルで構成されるブロッ
クを単位として書き込み・消去を行うフラッシュメモリ
装置であって、 全体の制御を行うメモリ制御手段と、アドレスバスのア
ドレスを保持するアドレスレジスタと、データバスのデ
ータを保持するデータレジスタと、前記アドレスバスの
アドレスと前記メモリ制御手段が出力するアドレスとを
選択するフラッシュメモリアドレスセレクタと、前記フ
ラッシュメモリアドレスセレクタが出力するアドレスを
アドレス入力とするフラッシュメモリと、前記フラッシ
ュメモリと前記データバスとを接続するフラッシュメモ
リデータバッファと、前記フラッシュメモリの書き込み
・消去を行う単位であるブロックと同じ大きさの記憶容
量を持つデータメモリとを備え、 前記メモリ制御手段は、データ読み出し時において、前
記フラッシュメモリアドレスセレクタを通して前記アド
レスバスのアドレスを前記フラッシュメモリへ供給さ
せ、前記フラッシュメモリから前記アドレスバスのアド
レスのデータを読み出させ、前記フラッシュメモリから
読み出されたデータを前記フラッシュメモリデータバッ
ファを通して前記データバスへ送り出させ、 前記メモリ制御手段は、データ書き込み時において、前
記アドレスレジスタに前記アドレスバスのアドレスを保
持させるとともに前記データレジスタに前記データバス
のデータを保持させ、前記アドレスレジスタに保持させ
たアドレスから前記フラッシュメモリにおける書き込み
・消去を行うべきブロックのブロック番号を得、このブ
ロック番号のブロックに含まれるアドレスを前記フラッ
シュメモリアドレスセレクタを通して前記フラッシュメ
モリへ供給することにより前記ブロック番号で示される
ブロックの全アドレスのうち前記アドレスレジスタに保
持させたアドレス以外の各アドレスのデータを前記フラ
ッシュメモリから読み出させ、前記フラッシュメモリか
ら読み出されたデータを前記データメモリにおける前記
ブロックの全アドレスのうち前記アドレスレジスタに保
持したアドレス以外の各アドレスに対応した位置に書き
込ませ、前記データレジスタに保持させたデータを前記
データメモリにおける前記アドレスレジスタに保持させ
たアドレスに対応した位置に書き込ませ、前記フラッシ
ュメモリにおける前記ブロック番号のブロックのデータ
を消去させ、前記フラッシュメモリにおける前記ブロッ
ク番号のブロックに対して前記データメモリのデータを
書き込ませるようにしたことを特徴とするフラッシュメ
モリ装置。
1. A flash memory device for performing writing / erasing in units of a block composed of a plurality of memory cells, comprising: a memory control means for controlling the whole; an address register for holding an address of an address bus; A data register for holding data on a data bus, a flash memory address selector for selecting an address of the address bus and an address output by the memory control means, and an address output by the flash memory address selector as an address input. A flash memory, a flash memory data buffer connecting the flash memory and the data bus, and a data memory having the same storage capacity as a block which is a unit for performing writing / erasing of the flash memory, The memory control means When reading data, the address of the address bus is supplied to the flash memory through the flash memory address selector, the data of the address of the address bus is read from the flash memory, and the data read from the flash memory is read. Through the flash memory data buffer to the data bus.The memory control means causes the address register to hold the address of the address bus and the data register to hold the data of the data bus when writing data. Obtains a block number of a block to be written / erased in the flash memory from the address held in the address register, and writes an address included in the block of the block number into the flash memory. The data of each address other than the address held in the address register among all the addresses of the block indicated by the block number is read from the flash memory by supplying the data to the flash memory through a flash memory address selector. The data read from the memory is written in a position corresponding to each address other than the address held in the address register among all addresses of the block in the data memory, and the data held in the data register is written in the data memory. At the position corresponding to the address held in the address register, erase the data of the block of the block number in the flash memory, and delete the block of the block number in the flash memory. Flash memory device is characterized in that so as to write the data of the data memory for.
【請求項2】 複数個のメモリセルで構成されるブロッ
クを単位として書き込み・消去を行うフラッシュメモリ
装置であって、 全体の制御を行うメモリ制御手段と、アドレスバスの第
1部分アドレスおよび第2部分アドレスからなるアドレ
スのうちの書き込み・消去を行うべきブロックのブロッ
ク番号に対応した第1部分アドレスを保持するアドレス
レジスタと、前記アドレスレジスタが保持した第1部分
アドレスと前記アドレスバスのアドレスのうちの第1部
分アドレスとを比較する比較器と、前記アドレスバスの
アドレスと前記メモリ制御手段が出力するアドレスとを
選択するフラッシュメモリアドレスセレクタと、前記フ
ラッシュメモリアドレスセレクタが出力するアドレスを
アドレス入力とするフラッシュメモリと、前記フラッシ
ュメモリと前記データバスとを接続するフラッシュメモ
リデータバッファと、前記アドレスバスのアドレスのう
ちの第2部分アドレスと前記メモリ制御手段が出力する
制御のためのアドレスとを選択するデータメモリアドレ
スセレクタと、前記フラッシュメモリの書き込み・消去
を行う単位であるブロックと同じ大きさの記憶容量を持
ち、前記データメモリアドレスセレクタが出力するアド
レスをアドレス入力としデータが書き込まれているアド
レスに対応してデータフラグがセットされるデータメモ
リと、前記データメモリと前記データバスとを接続する
データメモリデータバッファとを備え、 前記メモリ制御手段は、データ読み出し時において前記
アドレスバスのアドレスと前記アドレスレジスタに保持
されたアドレスとを前記比較器で比較させ、 前記比較器から不一致出力が発生したときには、前記フ
ラッシュメモリアドレスセレクタを通して前記アドレス
バスのアドレスを前記フラッシュメモリへ供給させ、前
記フラッシュメモリから前記アドレスバスのアドレスの
データを読み出させ、前記フラッシュメモリから読み出
されたデータを前記フラッシュメモリデータバッファを
通して前記データバスへ送り出させ、 前記比較器から一致出力が発生したときには、前記デー
タメモリアドレスセレクタを通して前記アドレスバスの
アドレスのうちの第2部分アドレスを前記データメモリ
へ供給し、前記アドレスバスのアドレスのうちの第2部
分アドレスに対応したデータフラグが前記データメモリ
にセットされているときには前記データメモリから前記
アドレスバスのアドレスのうちの第2部分アドレスのデ
ータを読み出させ、前記データメモリから読み出された
データを前記データメモリデータバッファを通して前記
データバスへ送り出させ、前記アドレスバスのアドレス
のうちの第2部分アドレスに対応したデータフラグが前
記データメモリにセットされていないときには前記フラ
ッシュメモリアドレスセレクタを通して前記アドレスバ
スのアドレスを前記フラッシュメモリへ供給させ、前記
フラッシュメモリから前記アドレスバスのアドレスのデ
ータを読み出させ、前記フラッシュメモリから読み出さ
れたデータを前記フラッシュメモリデータバッファを通
して前記データバスへ送り出させ、 前記メモリ制御手段は、データ書き込み時において、電
源投入後一度もデータの書き込みを行っていないときに
は、前記アドレスバスのアドレスのうちの第1部分アド
レスを前記アドレスレジスタに書き込ませ、前記アドレ
スバスのアドレスのうちの第2部分アドレスを前記デー
タメモリアドレスセレクタを通して前記データメモリへ
与えることにより前記データバスのデータを前記データ
メモリデータバッファを通して前記データメモリの前記
アドレスバスのアドレスのうちの第2部分アドレスに対
応した位置に記憶させるとともに、前記アドレスバスの
アドレスのうちの第2部分アドレスに対応したデータフ
ラグをセットさせ、 前記メモリ制御手段は、データ書き込み時において、電
源投入後少なくとも一度データの書き込みを行っていた
ときには、前記アドレスレジスタが保持した第1部分ア
ドレスと前記アドレスバスの第1部分アドレスとを前記
比較器で比較させ、 前記比較器から一致出力が発生したときは、前記アドレ
スバスのアドレスのうちの第2部分アドレスを前記デー
タメモリアドレスセレクタを通して前記データメモリへ
与えることにより前記データバスのデータを前記データ
メモリデータバッファを通して前記データメモリの前記
アドレスバスのアドレスのうちの第2部分アドレスに対
応した位置に記憶させるとともに、前記アドレスバスの
アドレスのうちの第2部分アドレスに対応したデータフ
ラグをセットさせ、 前記比較器から不一致出力が発生したときは、前記アド
レスレジスタが保持した第1部分アドレスに対応したブ
ロックに含まれる各アドレスを順次共通に前記データメ
モリアドレスセレクタおよびフラッシュメモリアドレス
セレクタをそれぞれ通して前記データメモリおよび前記
フラッシュメモリへ共通に与えることにより、前記フラ
ッシュメモリにおける前記アドレスバスのアドレスのう
ちの第1部分アドレスに対応したブロックに含まれる各
アドレスのうち前記データメモリでデータフラグがセッ
トされていないアドレスについてのみデータを前記デー
タメモリに複写させ、前記フラッシュメモリにおける前
記アドレスバスのアドレスのうちの第1部分アドレスに
対応したブロックのデータを消去し、前記フラッシュメ
モリにおける前記アドレスバスのアドレスのうちの第1
部分アドレスに対応したブロックに前記データメモリの
データを書き込ませ、前記データメモリのデータフラグ
のセットを取り消し、前記アドレスバスのアドレスのう
ちの第1部分アドレスを前記アドレスレジスタに書き込
ませ、前記アドレスバスのアドレスのうちの第2部分ア
ドレスを前記データメモリアドレスセレクタを通して前
記データメモリへ与えることにより前記データバスのデ
ータを前記データメモリデータバッファを通して前記デ
ータメモリの前記アドレスバスのアドレスのうちの第2
部分アドレスに対応した位置に記憶させるとともに、前
記データメモリの前記アドレスバスのアドレスのうちの
第2部分アドレスに対応したデータフラグをセットさせ
るようにしたことを特徴とするフラッシュメモリ装置。
2. A flash memory device for performing writing / erasing in units of a block composed of a plurality of memory cells, comprising: a memory control means for controlling the whole; a first partial address and a second address on an address bus. An address register for holding a first partial address corresponding to a block number of a block to be written / erased among addresses composed of partial addresses; and a first partial address held by the address register and an address of the address bus. A flash memory address selector for selecting an address on the address bus and an address output from the memory control means; and an address input for outputting an address output from the flash memory address selector. Flash memory and the flash A flash memory data buffer for connecting a memory and the data bus, a data memory address selector for selecting a second partial address of the addresses on the address bus and an address for control output by the memory control means, The flash memory has the same storage capacity as a block which is a unit for performing writing / erasing, and an address output from the data memory address selector is used as an address input, and a data flag is set corresponding to an address where data is written. A data memory to be set, and a data memory data buffer for connecting the data memory and the data bus, wherein the memory control unit is configured to control the address of the address bus and the address held in the address register when reading data. With the above comparator When a mismatch output is generated from the comparator, the address of the address bus is supplied to the flash memory through the flash memory address selector, and the data of the address of the address bus is read from the flash memory. The data read from the memory is sent to the data bus through the flash memory data buffer. When a match output is generated from the comparator, the second partial address of the address on the address bus is passed through the data memory address selector. Is supplied to the data memory, and when the data flag corresponding to the second partial address of the addresses on the address bus is set in the data memory, the address of the address on the address bus is read from the data memory. The data of the second partial address is read out, and the data read out from the data memory is sent out to the data bus through the data memory data buffer, and the data corresponding to the second partial address among the addresses of the address bus is read. When the data flag is not set in the data memory, the address of the address bus is supplied to the flash memory through the flash memory address selector, and the data of the address of the address bus is read from the flash memory. The data read out from the flash memory is sent out to the data bus through the flash memory data buffer, and at the time of data writing, when no data has been written after power-on, A first partial address of the address bus is written to the address register, and a second partial address of the address bus is provided to the data memory through the data memory address selector, thereby providing data on the data bus. Through the data memory data buffer at a position corresponding to a second partial address of the address of the address bus of the data memory, and a data flag corresponding to a second partial address of the address of the address bus is stored. The memory control means, at the time of data writing, when data has been written at least once after power-on, the first partial address held by the address register and the first partial address of the address bus are compared with each other. Comparator When a match output is generated from the comparator, a second partial address of the address on the address bus is supplied to the data memory through the data memory address selector, thereby transferring the data on the data bus to the data memory. Storing the data in the data memory at a position corresponding to a second partial address of the addresses of the address bus through the data buffer, and setting a data flag corresponding to a second partial address of the addresses of the address bus; When a mismatch output is generated from the comparator, each address included in the block corresponding to the first partial address held by the address register is sequentially and commonly passed through the data memory address selector and the flash memory address selector, respectively. The data flag is not set in the data memory among the addresses included in the block corresponding to the first partial address of the addresses of the address bus in the flash memory by commonly providing the data to the memory and the flash memory. Only the data of the address is copied to the data memory, the data of the block corresponding to the first partial address of the address of the address bus in the flash memory is erased, and the data of the address of the address bus in the flash memory is deleted. First
Causing the data of the data memory to be written to a block corresponding to the partial address, canceling the setting of a data flag of the data memory, and writing the first partial address of the addresses of the address bus to the address register; Of the address bus of the data memory through the data memory data buffer by providing a second partial address among the addresses of the data memory to the data memory through the data memory address selector.
A flash memory device which is stored at a position corresponding to a partial address and sets a data flag corresponding to a second partial address of the addresses on the address bus of the data memory.
【請求項3】 複数個のメモリセルで構成されるブロッ
クを単位として書き込み・消去を行うフラッシュメモリ
装置であって、 全体の制御を行うメモリ制御手段と、アドレスバスの第
1部分アドレス,第2部分アドレスおよび第3部分アド
レスからなるアドレスのうちの書き込み・消去を行うべ
きブロックのブロック番号に対応した第2部分アドレス
と前記メモリ制御手段が出力するアドレスとを選択する
アドレスタグメモリアドレスセレクタと、前記アドレス
タグメモリアドレスセレクタから出力されるアドレスを
アドレス入力としデータが書き込まれているアドレスに
対応してアドレスタグフラグがセットされるアドレスタ
グメモリと、前記アドレスタグメモリと前記アドレスバ
スとを接続して前記アドレスバスの第1部分アドレスを
前記アドレスタグメモリへデータ入力として供給するア
ドレスタグメモリデータバッファと、前記アドレスバス
のアドレスのうちの第2部分アドレスをアドレス入力と
して前記アドレスタグメモリから読み出されるアドレス
と前記アドレスバスのアドレスのうちの第1部分アドレ
スとを比較する比較器と、前記アドレスバスのアドレス
と前記メモリ制御手段が出力するアドレスとを選択する
フラッシュメモリアドレスセレクタと、前記フラッシュ
メモリアドレスセレクタから出力されるアドレスをアド
レス入力とするフラッシュメモリと、前記フラッシュメ
モリと前記データバスとを接続するフラッシュメモリデ
ータバッファと、前記アドレスバスのアドレスのうちの
第2部分アドレスおよび第3部分アドレスと前記メモリ
制御手段が出力する制御のためのアドレスとを選択する
データメモリアドレスセレクタと、前記フラッシュメモ
リの書き込み・消去の単位であるブロックの前記第2部
分アドレスのアドレス空間の大きさに相当する個数分と
同じ容量を持ち、前記データメモリアドレスセレクタが
出力するアドレスをアドレス入力としデータが書き込ま
れているアドレスに対応してデータフラグがセットされ
るデータメモリと、前記データメモリと前記データバス
とを接続するデータメモリデータバッファとを備え、 前記メモリ制御手段は、データ読み出し時において前記
アドレスバスのアドレスのうちの第1部分アドレスと前
記アドレスバスのアドレスのうちの第2部分アドレスを
前記アドレスタグメモリアドレスセレクタを通しアドレ
ス入力として前記アドレスタグメモリから読み出させた
データとを前記比較器で比較させ、 前記比較器から不一致出力が発生したときには、前記フ
ラッシュメモリアドレスセレクタを通して前記アドレス
バスのアドレスを前記フラッシュメモリへ供給させ、前
記フラッシュメモリから前記アドレスバスのアドレスの
データを読み出させ、前記フラッシュメモリから読み出
されたデータを前記フラッシュメモリデータバッファを
通して前記データバスへ送り出させ、 前記比較器から一致出力が発生したときには、前記デー
タメモリアドレスセレクタを通して前記アドレスバスの
アドレスのうちの第2部分アドレスおよび第3部分アド
レスを前記データメモリへ供給し、前記アドレスバスの
アドレスのうちの第2部分アドレスおよび第3部分アド
レスに対応したデータフラグが前記データメモリにセッ
トされているときには前記データメモリから前記アドレ
スバスのアドレスのうちの第2部分アドレスおよび第3
部分アドレスのデータを読み出させ、前記データメモリ
から読み出されたデータを前記データメモリデータバッ
ファを通して前記データバスへ送り出させ、前記アドレ
スバスのアドレスのうちの第2部分アドレスおよび第3
部分アドレスに対応したデータフラグが前記データメモ
リにセットされていないときには前記フラッシュメモリ
アドレスセレクタを通して前記アドレスバスのアドレス
を前記フラッシュメモリへ供給させ、前記フラッシュメ
モリから前記アドレスバスのアドレスのデータを読み出
させ、前記フラッシュメモリから読み出されたデータを
前記フラッシュメモリデータバッファを通して前記デー
タバスへ送り出させ、 前記メモリ制御手段は、データ書き込み時において、前
記アドレスタグメモリの全てのアドレスへの書き込みを
完了する前には、前記アドレスバスのアドレスのうちの
第2部分アドレスを前記アドレスタグメモリアドレスセ
レクタを通しアドレス入力とするとともに前記アドレス
バスのアドレスのうちの第1部分アドレスをデータ入力
として前記アドレスタグメモリに書き込みを行わせると
ともに、前記アドレスタグメモリにおけるデータ書き込
みを行ったアドレスに対応するアドレスタグフラグをセ
ットさせ、前記アドレスバスのアドレスのうちの第2部
分アドレスおよび第3部分アドレスを前記データメモリ
アドレスセレクタを通して前記データメモリへ与えるこ
とにより前記データバスのデータを前記データメモリデ
ータバッファを通して前記データメモリの前記アドレス
バスのアドレスのうちの第2部分アドレスおよび第3部
分アドレスに対応した位置に記憶させるとともに、前記
データメモリにおける前記アドレスバスのアドレスのう
ちの第2部分アドレスおよび第3部分アドレスに対応し
たデータフラグをセットさせ、 前記メモリ制御手段は、データ書き込み時において、前
記アドレスタグメモリの全てのアドレスへの書き込みが
完了して前記アドレスタグメモリの全てのアドレス対応
したアドレスタグフラグがすべてセットされた後には、
前記アドレスバスのアドレスのうちの第1部分アドレス
と前記アドレスバスのアドレスのうちの第2部分アドレ
スをアドレス入力として前記アドレスタグメモリから読
み出させたデータとを前記比較器で比較させ、 前記比較器から一致出力が発生したときには、前記アド
レスバスのアドレスのうちの第2部分アドレスおよび第
3部分アドレスを前記データメモリアドレスセレクタを
通して前記データメモリへ与えることにより前記データ
バスのデータを前記データメモリデータバッファを通し
て前記データメモリの前記アドレスバスのアドレスのう
ちの第2部分アドレスおよび第3部分アドレスに対応し
た位置に記憶させるとともに、前記データメモリの前記
アドレスバスのアドレスのうちの第2部分アドレスおよ
び第3部分アドレスに対応したデータフラグをセットさ
せ、 前記比較器から不一致出力が発生したときには、前記ア
ドレスタグメモリの全てのアドレスとそれらのアドレス
に記憶させたデータとによってそれぞれ決まる複数組の
第1部分アドレスおよび第2部分アドレスに対応した個
数のブロックに含まれる各アドレスを順次共通に前記デ
ータメモリアドレスセレクタおよびフラッシュメモリア
ドレスセレクタをそれぞれ通して前記データメモリおよ
び前記フラッシュメモリへ共通に与えることにより、前
記フラッシュメモリにおける前記アドレスバスのアドレ
スのうちの複数組の第1部分アドレスおよび第2部分ア
ドレスに対応した個数のブロックに含まれる各アドレス
のうち前記データメモリでデータフラグがセットされて
いないアドレスについてのみデータを前記データメモリ
に複写させ、前記アドレスタグメモリの全てのアドレス
とそれらのアドレスに記憶させたデータとによってそれ
ぞれ決まる複数組の第1部分アドレスおよび第2部分ア
ドレスに対応したブロックのデータを消去し、前記フラ
ッシュメモリにおける前記アドレスバスのアドレスのう
ちの複数組の第1部分アドレスおよび第2部分アドレス
に対応したブロックに前記データメモリのデータを書き
込ませ、前記データメモリのデータフラグのセットを取
り消し、前記アドレスタグメモリの全てのアドレスへの
書き込みを完了するまで、前記アドレスバスのアドレス
のうちの第2部分アドレスを前記アドレスタグメモリア
ドレスセレクタを通しアドレス入力とするとともに前記
アドレスバスのアドレスのうちの第1部分アドレスをデ
ータ入力として前記アドレスタグメモリに書き込みを行
わせるとともに、前記アドレスタグメモリにおけるデー
タ書き込みを行ったアドレスに対応するアドレスタグフ
ラグをセットさせ、前記アドレスバスのアドレスのうち
の第2部分アドレスおよび第3部分アドレスを前記デー
タメモリアドレスセレクタを通して前記データメモリへ
与えることにより前記データバスのデータを前記データ
メモリデータバッファを通して前記データメモリの前記
アドレスバスのアドレスのうちの第2部分アドレスおよ
び第3部分アドレスに対応した位置に記憶させるととも
に、前記データメモリにおける前記アドレスバスのアド
レスのうちの第2部分アドレスおよび第3部分アドレス
に対応したデータフラグをセットさせるようにしたこと
を特徴とするフラッシュメモリ装置。
3. A flash memory device for performing writing / erasing in units of a block composed of a plurality of memory cells, comprising: a memory control means for controlling the whole; a first partial address of an address bus; An address tag memory address selector for selecting a second partial address corresponding to a block number of a block to be written / erased among addresses composed of a partial address and a third partial address and an address output by the memory control means; An address tag memory in which an address output from the address tag memory address selector is set as an address input and an address tag flag is set corresponding to an address where data is written, and the address tag memory and the address bus are connected. Before the first partial address of the address bus. An address tag memory data buffer to be supplied to the address tag memory as a data input; and an address read out from the address tag memory using the second partial address of the addresses of the address bus as an address input and a second address of the address bus address. A comparator for comparing one partial address; a flash memory address selector for selecting an address on the address bus and an address output by the memory control means; and an address output from the flash memory address selector as an address input. A flash memory, a flash memory data buffer for connecting the flash memory and the data bus, a second partial address and a third partial address of the addresses on the address bus, and a control for outputting the data from the memory control means. A data memory address selector for selecting an address for control, and the same capacity as the number corresponding to the size of the address space of the second partial address of the block which is a unit of writing / erasing of the flash memory, An address output from the data memory address selector as an address input, a data memory in which a data flag is set corresponding to an address in which data is written, a data memory data buffer connecting the data memory and the data bus, The memory control means, at the time of data reading, uses a first partial address of the address of the address bus and a second partial address of the address of the address bus as an address input through the address tag memory address selector. From the address tag memory The read data is compared with the comparator. When a mismatch output is generated from the comparator, the address of the address bus is supplied to the flash memory through the flash memory address selector, and the address is output from the flash memory. The data of the address of the bus is read, the data read from the flash memory is sent to the data bus through the flash memory data buffer, and when a match output is generated from the comparator, the data is output through the data memory address selector. A second partial address and a third partial address of the addresses of the address bus are supplied to the data memory, and a data flag corresponding to the second partial address and the third partial address of the addresses of the address bus is stored in the data memory. The second partial address, and a third of the address of said address bus from said data memory when it is set in the memory
Causing the data of the partial address to be read, sending the data read from the data memory to the data bus through the data memory data buffer, and selecting a second partial address and a third of the addresses of the address bus.
When the data flag corresponding to the partial address is not set in the data memory, the address of the address bus is supplied to the flash memory through the flash memory address selector, and the data of the address of the address bus is read from the flash memory. And causing the data read from the flash memory to be sent out to the data bus through the flash memory data buffer. At the time of data writing, the memory control means completes writing to all addresses of the address tag memory. In the prior art, a second partial address of the addresses on the address bus is used as an address input through the address tag memory address selector, and a first partial address of the addresses on the address bus is used as data. As an input, the address tag memory is written, and an address tag flag corresponding to the address at which data is written in the address tag memory is set, and a second partial address and a third partial address of the addresses of the address bus are set. By providing an address to the data memory through the data memory address selector, the data on the data bus corresponds to a second partial address and a third partial address of the address on the address bus of the data memory through the data memory data buffer. And setting a data flag corresponding to a second partial address and a third partial address of the addresses of the address bus in the data memory. At the time of writing, after writing to all addresses of the address tag memory is completed and all address tag flags corresponding to all addresses of the address tag memory are set,
The comparator compares data read from the address tag memory with a first partial address of the addresses of the address bus and a second partial address of the addresses of the address bus as an address input. When a match output is generated from the data bus, the data on the data bus is supplied to the data memory by providing the second partial address and the third partial address of the addresses on the address bus to the data memory through the data memory address selector. The data is stored in a position corresponding to a second partial address and a third partial address of the addresses of the address bus of the data memory through a buffer, and the second partial address and the second of the addresses of the address bus of the data memory are stored. Supports three-part addresses When a non-coincidence output is generated from the comparator, a plurality of sets of a first partial address and a second partial address respectively determined by all the addresses of the address tag memory and the data stored at those addresses are set. By sequentially giving each address included in the blocks corresponding to the addresses to the data memory and the flash memory in common through the data memory address selector and the flash memory address selector, respectively, the address in the flash memory is obtained. Only the addresses of the buses where the data flag is not set in the data memory among the addresses included in the blocks corresponding to the plurality of sets of the first partial address and the second partial address among the addresses of the bus are forwarded. A plurality of sets of the first partial address and the second partial address corresponding to all the addresses in the address tag memory and the data stored in the addresses, and erase the data in the blocks corresponding to the plurality of sets, Causing the data of the data memory to be written to blocks corresponding to a plurality of sets of the first partial address and the second partial address of the addresses of the address bus in the flash memory, canceling a data flag set of the data memory, Until the writing to all the addresses of the address tag memory is completed, the second partial address of the addresses on the address bus is used as an address input through the address tag memory address selector, and the second partial address of the addresses on the address bus is input. One-part address data As an input, the address tag memory is written, and an address tag flag corresponding to the address at which data is written in the address tag memory is set, and a second partial address and a third partial address of the addresses of the address bus are set. By providing an address to the data memory through the data memory address selector, the data on the data bus corresponds to a second partial address and a third partial address of the address on the address bus of the data memory through the data memory data buffer. And a data flag corresponding to a second partial address and a third partial address of the addresses of the address bus in the data memory. Yumemori apparatus.
JP14905497A 1997-06-06 1997-06-06 Flash memory device Pending JPH10340221A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP14905497A JPH10340221A (en) 1997-06-06 1997-06-06 Flash memory device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP14905497A JPH10340221A (en) 1997-06-06 1997-06-06 Flash memory device

Publications (1)

Publication Number Publication Date
JPH10340221A true JPH10340221A (en) 1998-12-22

Family

ID=15466662

Family Applications (1)

Application Number Title Priority Date Filing Date
JP14905497A Pending JPH10340221A (en) 1997-06-06 1997-06-06 Flash memory device

Country Status (1)

Country Link
JP (1) JPH10340221A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002222120A (en) * 2001-01-26 2002-08-09 Sony Corp Memory access management device and management method

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002222120A (en) * 2001-01-26 2002-08-09 Sony Corp Memory access management device and management method

Similar Documents

Publication Publication Date Title
US6154808A (en) Method and apparatus for controlling data erase operations of a non-volatile memory device
US6040997A (en) Flash memory leveling architecture having no external latch
US5524230A (en) External information storage system with a semiconductor memory
US7937523B2 (en) Memory system with nonvolatile semiconductor memory
US5303198A (en) Method of recording data in memory card having EEPROM and memory card system using the same
US7388792B2 (en) Memory management device and memory device
JP3905037B2 (en) Memory controller, flash memory system, and flash memory control method
US6944060B2 (en) Non-volatile storage device and control method thereof
JP2000067574A (en) Semiconductor storage device
JPWO2002052416A1 (en) Flash memory system
JPH08263361A (en) Flash memory card
KR20050079210A (en) Memory card and semiconductor device
US6073207A (en) Microcomputer comprising flash EEPROM
JP2001243110A (en) Memory controller, flash memory system and access method to flash memory
US20050268026A1 (en) Memory card, semiconductor device, and method of controlling semiconductor memory
JP2003076605A (en) Semiconductor memory device equipped with block erase type nonvolatile memory and method of writing / reading data therefrom
JPH09171486A (en) PC card
JPH10340221A (en) Flash memory device
JP4316824B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
JP2584119B2 (en) Data recording method in memory card and memory card system
JP2000306389A (en) Storage device using nonvolatile semiconductor memory
JP2003122630A (en) Memory controller, flash memory system having memory controller, and method for controlling flash memory
JP3190421B2 (en) IC memory card system
JP2000285092A (en) Microcomputer
JPH01155599A (en) Memory device