JP2008234514A - Memory controller, flash memory system equipped with memory controller and method for controlling flash memory - Google Patents

Memory controller, flash memory system equipped with memory controller and method for controlling flash memory Download PDF

Info

Publication number
JP2008234514A
JP2008234514A JP2007075932A JP2007075932A JP2008234514A JP 2008234514 A JP2008234514 A JP 2008234514A JP 2007075932 A JP2007075932 A JP 2007075932A JP 2007075932 A JP2007075932 A JP 2007075932A JP 2008234514 A JP2008234514 A JP 2008234514A
Authority
JP
Japan
Prior art keywords
data
flash memory
output
signal
area
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.)
Granted
Application number
JP2007075932A
Other languages
Japanese (ja)
Other versions
JP4640366B2 (en
Inventor
Takuma Mitsunaga
琢真 光永
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.)
TDK Corp
Original Assignee
TDK Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by TDK Corp filed Critical TDK Corp
Priority to JP2007075932A priority Critical patent/JP4640366B2/en
Publication of JP2008234514A publication Critical patent/JP2008234514A/en
Application granted granted Critical
Publication of JP4640366B2 publication Critical patent/JP4640366B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To prevent user data or additional data from being written in a block status area in assigning an area in which the user data of one sector unit and the additional data are written to a region in which column addresses are continued, and writing the data in a flash memory. <P>SOLUTION: This method for controlling a flash memory comprises a process for storing the user data of one sector unit to be supplied from a host system side; a process for successively transferring the stored user data from the leading data to the flash memory; a process for transferring the additional data corresponding to the user data transferred to the flash memory; and a process for transferring the preliminarily set dummy data to the flash memory. The process for transferring the dummy data to the flash memory is executed only when the write-in destination of the data to be transferred to the flash memory is made to correspond to a block status storage area. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は、メモリコントローラ及びメモリコントローラを備えるフラッシュメモリシステム、並びにフラッシュメモリの制御方法に関する。   The present invention relates to a memory controller, a flash memory system including the memory controller, and a flash memory control method.

メモリカードやシリコンディスクなどの記憶媒体である半導体メモリとして、フラッシュメモリが多く用いられている。フラッシュメモリにはNOR型フラッシュメモリとNAND型フラッシュメモリがあり、特にNAND型フラッシュメモリは集積度に優れ、また書き込みに必要な動作電流が少ないなどの特長により大容量のメモリとして急成長をとげている。   A flash memory is often used as a semiconductor memory that is a storage medium such as a memory card or a silicon disk. There are two types of flash memory: NOR-type flash memory and NAND-type flash memory. NAND-type flash memory, in particular, is highly integrated and has a rapid growth as a large-capacity memory due to features such as low operating current required for writing Yes.

NAND型フラッシュメモリでは、これらのメモリセルを消去状態から書き込み状態に変化させる場合には、メモリセル単位で行うことができるが、メモリセルを書き込み状態から消去状態に変化させる場合には、メモリセル単位で行うことができず、所定数のメモリセルからなるブロック単位で一括消去することが行われる(ブロック消去)。   In the NAND flash memory, when these memory cells are changed from the erased state to the written state, it can be performed in units of memory cells. However, when the memory cells are changed from the written state to the erased state, the memory cells It cannot be performed in units, but is collectively erased in units of blocks composed of a predetermined number of memory cells (block erase).

また、所定数のメモリセルからなるブロック(物理ブロック)は、書き込み及び読み出しのアクセス処理単位である複数個のページで構成されている。例えば、1個の物理ブロックが32個のページで構成され、各ページが1セクタ(=512バイト)のユーザ領域と16バイトの冗長領域とによって構成されているフラッシュメモリや、1個の物理ブロックが64個のページで構成され、1個のページが4セクタ(=2048バイト)のユーザ領域と64バイトの冗長領域とによって構成されているフラッシュメモリがある。フラッシュメモリにデータを書き込むときは、フラッシュメモリ内のレジスタを介してメモリセルにデータが書き込まれ、フラッシュメモリからデータを読み出すときは、フラッシュメモリ内のレジスタを介してメモリセルからデータが読み出される。   Also, a block (physical block) made up of a predetermined number of memory cells is composed of a plurality of pages which are access processing units for writing and reading. For example, one physical block consists of 32 pages, and each page consists of a user area of 1 sector (= 512 bytes) and a redundant area of 16 bytes, or one physical block There is a flash memory in which 64 pages are configured, and one page is configured by a user area of 4 sectors (= 2048 bytes) and a redundant area of 64 bytes. When data is written to the flash memory, data is written to the memory cell via a register in the flash memory, and when data is read from the flash memory, data is read from the memory cell via a register within the flash memory.

従来、1個のページが複数セクタのユーザ領域で構成されているフラッシュメモリでは、例えば、図11に示したように各領域が割り当てられていた。図11において、25〜28はユーザ領域を512バイト毎に分割した第1〜第4セクタ領域を示し、これらの領域は512バイト単位のユーザデータを記憶するための領域として使用されていた。31〜34は第1〜第4セクタ領域に対応した第1〜第4付加データ領域(14バイトの領域)を示し、これらの領域はエラー・コレクション・コード(ECC)などの付加データを記憶するための領域として使用されていた。また、30は7バイトのヘッダ領域(HD)を示し、この領域は論理アドレス情報(論理ブロックと物理ブロックの対応関係を示す情報)などを記憶するための領域として使用されていた。また、35は1バイトのブロックステータス領域(BS)を示し、この領域は当該物理ブロックが不良ブロックであるか否かを示すブロックステータスを記憶するための領域として使用されていた。   Conventionally, in a flash memory in which one page is composed of user areas of a plurality of sectors, each area is allocated as shown in FIG. 11, for example. In FIG. 11, reference numerals 25 to 28 denote first to fourth sector areas obtained by dividing the user area every 512 bytes, and these areas are used as areas for storing user data in units of 512 bytes. Reference numerals 31 to 34 denote first to fourth additional data areas (14-byte areas) corresponding to the first to fourth sector areas, and these areas store additional data such as an error collection code (ECC). Had been used as an area for. Reference numeral 30 denotes a 7-byte header area (HD). This area is used as an area for storing logical address information (information indicating the correspondence between logical blocks and physical blocks). Reference numeral 35 denotes a 1-byte block status area (BS), which is used as an area for storing a block status indicating whether or not the physical block is a defective block.

512バイト単位のユーザデータの書き込みでは、ユーザデータの書き込みと、このユーザデータに対応するエラー・コレクション・コード(ECC)の書き込みが連続して行われ、読み出しでは、ユーザデータの読み出しと、このユーザデータに対応するエラー・コレクション・コード(ECC)の読み出しが連続して行われる。従って、図11に示したように各領域が割り当てられていた場合、第1セクタ領域25→第1付加データ領域31→第2セクタ領域26→第2付加データ領域32→第3セクタ領域27→第3付加データ領域33→第4セクタ領域28→第4付加データ領域34の順番で書き込み又は読み出しが行われる。この書き込み又は読み出しでは、書き込むデータ又は読み出すデータがユーザデータからエラー・コレクション・コード(ECC)に切り替わるとき又はエラー・コレクション・コード(ECC)からユーザデータに切り替わるときにカラムアドレスが不連続になるため、書き込み又は読み出しの処理が複雑になるという問題があった。   When writing user data in units of 512 bytes, writing user data and writing an error collection code (ECC) corresponding to the user data are performed continuously, and reading reads the user data and the user data. The error correction code (ECC) corresponding to the data is continuously read. Therefore, when each area is allocated as shown in FIG. 11, the first sector area 25 → the first additional data area 31 → the second sector area 26 → the second additional data area 32 → the third sector area 27 → Writing or reading is performed in the order of the third additional data area 33 → the fourth sector area 28 → the fourth additional data area 34. In this writing or reading, the column address becomes discontinuous when the data to be written or read is switched from user data to error collection code (ECC) or from error collection code (ECC) to user data. There has been a problem that the processing of writing or reading becomes complicated.

この問題を解決する技術が下記特許文献1に提案されている。特許文献1の技術では、1個のページが複数セクタのユーザ領域で構成されているフラッシュメモリにおいて、512バイト単位のユーザデータとその付加データをカラムアドレスが連続する領域に割り当て (特許文献1の図6参照)、上記問題を解決している。
特開2005−292925号公報
A technique for solving this problem is proposed in Patent Document 1 below. In the technique of Patent Document 1, 512 bytes of user data and its additional data are allocated to an area where column addresses are continuous in a flash memory in which one page is composed of user areas of a plurality of sectors (see Patent Document 1). The above-mentioned problem is solved.
JP 2005-292925 A

しかしながら、特許文献1に示した従来技術では、2048のカラムアドレスにブロックステータス領域(BS)35が割り当てられることが考慮されていなかった。一般的なフラッシュメモリでは、カラムアドレスが2048の領域は、初期不良ブロックを識別するためのブロックステータスが書き込まれる領域に割り当てられている。従って、カラムアドレスが2048の領域をブロックステータス領域(BS)35に割り当てれば、各物理ブロックのブロックステータス領域(BS)35からブロックステータスを読み出すことにより、その物理ブロックが初期不良ブロック、後発不良ブロック及び良品ブロックのいずれに該当するかを判断することができる。尚、初期不良ブロックのブロックステータスについては00h(16進数表示)が出荷前に書き込まれており、このブロックステータスは消去することができない。又、良品ブロックのブロックステータスは消去状態のFFh(16進数表示)であり、後発不良ブロックのブロックステータスについては、0Fh(16進数表示)やF0h(16進数表示)などが書き込まれる。特許文献1では、このようなことが考慮されていないため、良品ブロックのブロックステータス領域(BS)35にユーザデータなどが書き込まれてしまう。その結果、各物理ブロックのブロックステータス領域(BS)35から読み出したブロックステータスに基づいて、その物理ブロックが初期不良ブロック、後発不良ブロック及び良品ブロックのいずれに該当するかを判断することができなくなってしまう。   However, in the prior art disclosed in Patent Document 1, it is not considered that the block status area (BS) 35 is allocated to 2048 column addresses. In a general flash memory, an area with a column address of 2048 is assigned to an area in which a block status for identifying an initial defective block is written. Therefore, if an area with a column address of 2048 is assigned to the block status area (BS) 35, the physical status is read from the block status area (BS) 35 of each physical block. It can be determined whether the block corresponds to a non-defective block. As the block status of the initial defective block, 00h (hexadecimal display) is written before shipment, and this block status cannot be erased. The block status of the good block is FFh (hexadecimal number display) in the erased state, and 0Fh (hexadecimal number display), F0h (hexadecimal number display), etc. are written as the block status of the subsequent defective block. In Patent Document 1, since this is not taken into consideration, user data and the like are written in the block status area (BS) 35 of the non-defective block. As a result, based on the block status read from the block status area (BS) 35 of each physical block, it cannot be determined whether the physical block corresponds to an initial defective block, a subsequent defective block, or a non-defective block. End up.

本発明の目的は、512バイト単位のユーザデータと、そのエラー・コレクション・コード(ECC)を含む付加データが書き込まれる領域をカラムアドレスが連続する領域に割り当てたときに、ブロックステータス領域にユーザデータや付加データが書き込まれてしまうことを回避することができるメモリコントローラ及びメモリコントローラを備えるフラッシュメモリシステム、並びにフラッシュメモリの制御方法を提供することにある。   An object of the present invention is to assign user data in a block status area when an area in which additional data including 512-byte user data and error correction code (ECC) is written is assigned to an area where column addresses are continuous. And a flash memory system including the memory controller, and a flash memory control method capable of avoiding that additional data is written.

本発明のメモリコントローラは、ホストシステムからの要求に応じて、複数セクタのデータが記憶されるページを複数個含む物理ブロック単位で消去が行われるフラッシュメモリに対するアクセスを制御するメモリコントローラであって、前記ホストシステム側から供給される1セクタ単位のユーザデータを保持するデータ保持手段と、前記データ保持手段に保持されている前記ユーザデータを先頭データから順番に前記フラッシュメモリに転送するユーザデータ転送手段と、前記ユーザデータ転送手段により前記フラッシュメモリに転送される前記ユーザデータに対応する誤り訂正符号を含む付加データを前記フラッシュメモリに転送する付加データ転送手段と、予め設定されたダミーデータを前記フラッシュメモリに転送するダミーデータ転送手段と、前記ユーザデータ転送手段、前記付加データ転送手段及び前記ダミーデータ転送手段を択一的に動作させる制御手段とを備え、前記制御手段は、前記フラッシュメモリに転送されるデータの書き込み先がブロックステータスの記憶領域に対応するときにだけ前記ダミーデータ転送手段を動作させ、前記ユーザデータと該ユーザデータに対応する前記付加データは、前記ページ内の連続した領域に書き込まれることを特徴とする。
本発明のメモリコントローラは、更に、一定の周期でカウントアップされるカウンタ手段を備えることが好ましく、前記カウンタ手段は、前記ダミーデータが前記フラッシュメモリに転送される期間に係わるときに1周期分のカウントアップを停止し、前記ユーザデータ転送手段は、前記カウンタ手段から出力されるカウント値に基づいて、前記ユーザデータの先頭データから末尾データまでのデータの中から前記フラッシュメモリに転送するデータを決定することが好ましい。尚、前記カウンタ手段については、一定の周期でカウントダウンされる構成であっても実質的に同様の効果を得ることができる。
又、前記ダミーデータの論理値が、前記フラッシュメモリの消去状態の論理値に一致することが好ましい。
本発明のフラッシュメモリシステムは、上記メモリコントローラと、複数セクタのデータが記憶されるページを複数個含む物理ブロック単位で消去が行われるフラッシュメモリを備えることを特徴とする。
本発明のフラッシュメモリの制御方法は、ホストシステムからの要求に応じて、複数セクタのデータが記憶されるページを複数個含む物理ブロック単位で消去が行われるフラッシュメモリに対するアクセスを制御するフラッシュメモリの制御方法であって、前記ホストシステム側から供給される1セクタ単位のユーザデータを保持するデータ保持工程と、前記データ保持工程で保持される前記ユーザデータを先頭データから順番に前記フラッシュメモリに転送するユーザデータ転送工程と、前記ユーザデータ転送工程により前記フラッシュメモリに転送される前記ユーザデータに対応する誤り訂正符号を含む付加データを前記フラッシュメモリに転送する付加データ転送工程と、予め設定されたダミーデータを前記フラッシュメモリに転送するダミーデータ転送工程とを有し、前記ユーザデータ転送工程、前記付加データ転送工程及び前記ダミーデータ転送工程は択一的に実行され、前記ダミーデータ転送工程は、前記フラッシュメモリに転送されるデータの書き込み先がブロックステータスの記憶領域に対応するときにだけ実行され、前記ユーザデータと該ユーザデータに対応する前記付加データは、前記ページ内の連続した領域に書き込まれることを特徴とする。
前記ユーザデータ転送工程、前記付加データ転送工程及び前記ダミーデータ転送工程が、一定の周期でカウントアップ又はカウントダウンされるカウンタのカウント値に基づいて、択一的に実行されることが好ましい。
A memory controller of the present invention is a memory controller that controls access to a flash memory that is erased in units of physical blocks including a plurality of pages in which data of a plurality of sectors is stored in response to a request from a host system Data holding means for holding user data in units of one sector supplied from the host system side, and user data transfer means for transferring the user data held in the data holding means in order from the top data to the flash memory Additional data transfer means for transferring additional data including an error correction code corresponding to the user data transferred to the flash memory by the user data transfer means, and preset dummy data to the flash memory Dummy data transferred to memory Transfer means; and control means for selectively operating the user data transfer means, the additional data transfer means, and the dummy data transfer means, wherein the control means is a destination of data to be transferred to the flash memory The dummy data transfer means is operated only when corresponding to a block status storage area, and the user data and the additional data corresponding to the user data are written in a continuous area in the page. To do.
The memory controller of the present invention preferably further comprises counter means that counts up at a constant cycle, and the counter means is for one cycle when the dummy data is transferred to the flash memory. The count-up is stopped, and the user data transfer means determines data to be transferred to the flash memory from the data from the top data to the end data of the user data based on the count value output from the counter means. It is preferable to do. The counter means can obtain substantially the same effect even if it is configured to count down at a constant period.
Further, it is preferable that the logical value of the dummy data matches the logical value of the erase state of the flash memory.
A flash memory system according to the present invention includes the memory controller and a flash memory in which erasure is performed in units of physical blocks including a plurality of pages storing data of a plurality of sectors.
According to a flash memory control method of the present invention, a flash memory that controls access to a flash memory that is erased in units of physical blocks including a plurality of pages storing data of a plurality of sectors in response to a request from a host system. A control method, a data holding step for holding user data in units of one sector supplied from the host system side, and the user data held in the data holding step are transferred to the flash memory in order from the top data A user data transfer step, and an additional data transfer step for transferring additional data including an error correction code corresponding to the user data transferred to the flash memory by the user data transfer step to the flash memory, Transfer dummy data to the flash memory A dummy data transfer step, wherein the user data transfer step, the additional data transfer step, and the dummy data transfer step are alternatively executed, and the dummy data transfer step is a step of transferring data to be transferred to the flash memory. It is executed only when the write destination corresponds to a block status storage area, and the user data and the additional data corresponding to the user data are written in a continuous area in the page.
Preferably, the user data transfer step, the additional data transfer step, and the dummy data transfer step are alternatively executed based on a count value of a counter that is counted up or down at a constant cycle.

本発明によれば、初期不良ブロックのブロックステータスが書き込まれる領域に、ブロックステータス領域を割り当て、512バイト単位のユーザデータと、そのエラー・コレクション・コード(ECC)を含む付加データが書き込まれる領域をカラムアドレスが連続する領域に割り当てても、ブロックステータス領域にブロックステータス以外のデータが書き込まれてしまうことを回避することができる。   According to the present invention, the block status area is allocated to the area where the block status of the initial defective block is written, and the area where the additional data including 512-byte user data and its error collection code (ECC) is written. Even if the column addresses are assigned to consecutive areas, it is possible to avoid writing data other than the block status in the block status area.

次に、本発明を実施するための最良の形態を、図面を参照して具体的に説明する。   Next, the best mode for carrying out the present invention will be specifically described with reference to the drawings.

図1は、本発明の実施の形態であるフラッシュメモリシステムの概略構成を示すブロック図である。図1に示すように、フラッシュメモリシステム1は、フラッシュメモリ2と、それを制御するメモリコントローラ3で構成され、フラッシュメモリ2とメモリコントローラ3は内部バス14を介して接続されている。また、フラッシュメモリシステム1は、外部バス13を介してホストシステム4と接続される。   FIG. 1 is a block diagram showing a schematic configuration of a flash memory system according to an embodiment of the present invention. As shown in FIG. 1, the flash memory system 1 includes a flash memory 2 and a memory controller 3 that controls the flash memory 2, and the flash memory 2 and the memory controller 3 are connected via an internal bus 14. The flash memory system 1 is connected to the host system 4 via the external bus 13.

ホストシステム4は、ホストシステム4の全体の動作を制御するためのCPU(Central Processing Unit)と、フラッシュメモリシステム1との情報の授受を担うコンパニオンチップ等とから構成される。ホストシステム4は、例えば文字、音声、あるいは画像情報等の種々の情報を処理するパーソナルコンピュータやデジタルスチルカメラをはじめとする各種情報処理装置であってもよい。   The host system 4 is composed of a CPU (Central Processing Unit) for controlling the overall operation of the host system 4 and a companion chip for transferring information to and from the flash memory system 1. The host system 4 may be various information processing apparatuses such as a personal computer and a digital still camera that process various kinds of information such as characters, sounds, and image information.

フラッシュメモリ2は、NAND型フラッシュメモリであり、データを書き込むときは、メモリコントローラ3から入力されたデータが、内部のレジスタに保持された後、レジスタからメモリセルアレイに書き込まれる。一方、フラッシュメモリ2からデータを読み出すときは、メモリセルアレイからレジスタにデータが読み出された後、レジスタに読み出されたデータがメモリコントローラ3に転送される。   The flash memory 2 is a NAND flash memory. When data is written, data input from the memory controller 3 is held in an internal register and then written from the register to the memory cell array. On the other hand, when reading data from the flash memory 2, data is read from the memory cell array to the register, and then the data read to the register is transferred to the memory controller 3.

メモリコントローラ3は、マイクロプロセッサ6と、ホスト・インターフェース・ブロック7と、ワークエリア8と、バッファ9と、フラッシュメモリ・インターフェース・ブロック10と、ECC(エラー・コレクション・コード)ブロック11と、ROM(Read Only Memory)12とから構成される。これらの機能ブロックによって構成されるメモリコントローラ3は、一つの半導体チップ上に集積されている。   The memory controller 3 includes a microprocessor 6, a host interface block 7, a work area 8, a buffer 9, a flash memory interface block 10, an ECC (error collection code) block 11, and a ROM ( Read Only Memory) 12. The memory controller 3 constituted by these functional blocks is integrated on one semiconductor chip.

マイクロプロセッサ6は、メモリコントローラ3を構成する各機能ブロック全体の動作を制御するための機能ブロックである。   The microprocessor 6 is a functional block for controlling the operation of the entire functional blocks constituting the memory controller 3.

ホスト・インターフェース・ブロック7は、ホストシステム4との間で、外部バス13を介して、データ、アドレス、ステータス、外部コマンド等の情報の授受を行う。ホストシステム4よりフラッシュメモリシステム1に供給されるデータ等は、ホスト・インターフェース・ブロック7を入口としてメモリコントローラ3の内部(例えば、バッファ9)に取り込まれる。フラッシュメモリシステム1からホストシステム4に供給されるデータ等は、ホスト・インターフェース・ブロック7を出口としてホストシステム4に供給される。   The host interface block 7 exchanges information such as data, addresses, statuses, and external commands with the host system 4 via the external bus 13. Data or the like supplied from the host system 4 to the flash memory system 1 is taken into the memory controller 3 (for example, the buffer 9) through the host interface block 7 as an entrance. Data or the like supplied from the flash memory system 1 to the host system 4 is supplied to the host system 4 through the host interface block 7 as an exit.

フラッシュメモリ・インターフェース・ブロック10は、内部バス14を介して、フラッシュメモリ2とデータ、アドレス、ステータス、内部コマンド等の情報の授受を行う。ここで、フラッシュメモリ2は、コマンド・ラッチ・イネーブル(CLE)、アドレス・ラッチ・イネーブル(ALE)、ライト・イネーブル(WE)、リード・イネーブル(RE)、チップ・イネーブル(CE)等の制御信号端子を備えている。これらの制御信号端子に入力される信号は、フラッシュメモリ2の入出力バス(I/O)に入出力される情報に応じて制御される。   The flash memory interface block 10 exchanges information such as data, address, status, and internal command with the flash memory 2 via the internal bus 14. Here, the flash memory 2 has control signals such as a command latch enable (CLE), an address latch enable (ALE), a write enable (WE), a read enable (RE), and a chip enable (CE). It has a terminal. Signals input to these control signal terminals are controlled in accordance with information input / output to / from the input / output bus (I / O) of the flash memory 2.

尚、「内部コマンド」とは、メモリコントローラ3がフラッシュメモリ2を制御するためのコマンドであり、ホストシステム4からメモリコントローラ3に与えられるコマンドを「外部コマンド」と言う。   The “internal command” is a command for the memory controller 3 to control the flash memory 2, and a command given from the host system 4 to the memory controller 3 is called an “external command”.

ホスト・インターフェース・ブロック7及びフラッシュメモリ・インターフェース・ブロック10には各種レジスタが備わる。ホスト・インターフェース・ブロック7のレジスタにはホストシステム4から与えられるアドレス、外部コマンド等の情報が書き込まれる。また、フラッシュメモリ・インターフェース・ブロック10のレジスタには、ホスト・インターフェース・ブロック7に書き込まれた情報に基づいて、フラッシュメモリ2内のアクセス対象領域を指示する情報が書き込まれる。   The host interface block 7 and the flash memory interface block 10 are provided with various registers. Information such as an address and an external command given from the host system 4 is written in the register of the host interface block 7. Also, information indicating an access target area in the flash memory 2 is written in the register of the flash memory interface block 10 based on the information written in the host interface block 7.

ホストシステム4側のアドレス空間は、セクタ(512バイト)単位で分割した領域に付けた通番であるLBA(Logical Block Address)で管理されている。メモリコントローラ3の内部では、複数個のセクタをまとめた論理ブロックが構成され、各論理ブロックに対応するデータは、その論理ブロックに割り当てられた1個又は複数個の物理ブロックに書き込まれる。従って、メモリコントローラ3は、論理ブロックと物理ブロックの対応関係を管理している。   The address space on the host system 4 side is managed by an LBA (Logical Block Address) which is a serial number assigned to an area divided in units of sectors (512 bytes). Inside the memory controller 3, a logical block is formed by collecting a plurality of sectors, and data corresponding to each logical block is written in one or a plurality of physical blocks assigned to the logical block. Therefore, the memory controller 3 manages the correspondence between logical blocks and physical blocks.

ワークエリア8は、マイクロプロセッサ6によるフラッシュメモリ2の制御に必要なデータが一時的に保持される作業領域であり、複数のSRAM(Static Random Access Memory)セルによって構成される。例えば、物理ブロックと論理ブロックとの対応関係を管理するためのアドレス変換テーブルは、このワークエリア8上に作成される。   The work area 8 is a work area in which data necessary for controlling the flash memory 2 by the microprocessor 6 is temporarily stored, and is composed of a plurality of SRAM (Static Random Access Memory) cells. For example, an address conversion table for managing the correspondence between physical blocks and logical blocks is created on this work area 8.

バッファ9は、フラッシュメモリ2から読み出されたデータ及びフラッシュメモリ2に書き込むべきデータを一時的に保持するバッファである。すなわち、フラッシュメモリ2から読み出されたデータは、ホストシステム4が受け取り可能な状態となるまでバッファ9に保持され、フラッシュメモリ2に書き込むべきデータは、フラッシュメモリ2が書き込み可能な状態となるまでバッファ9に保持される。   The buffer 9 is a buffer that temporarily holds data read from the flash memory 2 and data to be written to the flash memory 2. That is, data read from the flash memory 2 is held in the buffer 9 until the host system 4 can receive the data, and data to be written to the flash memory 2 is stored until the flash memory 2 becomes writable. It is held in the buffer 9.

ECCブロック11は、フラッシュメモリ2に書き込むデータに対応するエラー・コレクション・コードを生成するとともに、読み出しデータに対応するエラー・コレクション・コードに基づいて、読み出しデータに含まれる誤りを検出・訂正する。   The ECC block 11 generates an error collection code corresponding to the data to be written to the flash memory 2 and detects and corrects an error included in the read data based on the error collection code corresponding to the read data.

ROM12は、不揮発性の記憶素子であり、プログラム等を記憶している。マイクロプロセッサ6は、ROM12に記憶されているプログラムを読み込むことで、各種処理を実行している。また、ROM12は、各種処理等を定義したコマンドセットで構成さたシーケンスコマンドも記憶しており、フラッシュメモリ・インターフェース・ブロック10は、このシーケンスコマンドに従って、フラッシュメモリ2とデータ、アドレス、ステータス、内部コマンド等の情報の授受を行う。   The ROM 12 is a nonvolatile storage element and stores a program and the like. The microprocessor 6 executes various processes by reading a program stored in the ROM 12. The ROM 12 also stores a sequence command configured by a command set that defines various processes and the like. The flash memory interface block 10 follows the flash memory 2 and data, address, status, internal, in accordance with the sequence command. Send and receive information such as commands.

次に、本実施の形態のフラッシュメモリ2におけるアドレス空間の構造を、図2を参照して説明する。   Next, the structure of the address space in the flash memory 2 of the present embodiment will be described with reference to FIG.

本実施の形態で用いたフラッシュメモリ2のアドレス空間は、ブロック0〜ブロック4095からなる4096個の物理ブロックで構成されている。各物理ブロックは、ページ0〜ページ63からなる64個のページで構成されている。更に、各ページは、2112バイトの領域で構成されている。   The address space of the flash memory 2 used in the present embodiment is composed of 4096 physical blocks composed of block 0 to block 4095. Each physical block is composed of 64 pages including page 0 to page 63. Furthermore, each page is composed of an area of 2112 bytes.

ここで、フラッシュメモリ2が有する4096個の物理ブロックに付けた通番が、物理ブロックを特定するための物理ブロックアドレス(PBA)である。フラッシュメモリ2が有する4096個の物理ブロックに含まれる全てのページ、つまり、262144個のページに付けた通番が、フラッシュメモリ2に与えるロウアドレス(0〜262143)に対応する。つまり、ロウアドレスにより、書き込み又は読み出しの対象のページが特定される。また、各ページ内の領域には、図2に示したように、ビットb0〜b7からなる8ビットを1バイトとした、0〜2111のカラムアドレスが割り当てられている。   Here, the serial numbers assigned to the 4096 physical blocks of the flash memory 2 are physical block addresses (PBA) for specifying the physical blocks. All the pages included in 4096 physical blocks of the flash memory 2, that is, serial numbers assigned to 262144 pages correspond to row addresses (0 to 262143) given to the flash memory 2. That is, the page to be written or read is specified by the row address. Further, as shown in FIG. 2, column addresses 0 to 2111 are assigned to the areas in each page, with 8 bits consisting of bits b0 to b7 as 1 byte.

更に、ページの構造について、図3を参照して説明する。   Further, the page structure will be described with reference to FIG.

本実施の形態では、0〜2111のカラムアドレスが割り当てられている2112バイトの領域を、従来のようにユーザ領域と冗長領域に分離せずに使用している。カラムアドレスが0〜6の7バイトの領域には、ヘッダ領域(HD)30が割り当てられている。カラムアドレスが7〜518の512バイトの領域には、第1セクタ領域25が割り当てられている。カラムアドレスが519〜532の14バイトの領域には、第1付加データ領域31が割り当てられている。カラムアドレスが533〜1044の512バイトの領域には、第2セクタ領域26が割り当てられている。カラムアドレスが1045〜1058の14バイトの領域には、第2付加データ領域32が割り当てられている。カラムアドレスが1059〜1570の512バイトの領域には、第3セクタ領域27が割り当てられている。カラムアドレスが1571〜1584の14バイトの領域には、第3付加データ領域33が割り当てられている。カラムアドレスが2048のブロックステータス領域(BS)35を挟んだ、カラムアドレスが1585〜2047の領域と2049〜2097の領域には、第4セクタ領域28が割り当てられている。つまり、第4セクタ領域28に割り当てられた512バイトの領域は、ブロックステータス領域(BS)35を挟んで2つの領域28a、28bに分割されている。カラムアドレスが2098〜2111の14バイトの領域には、第4付加データ領域34が割り当てられている。   In the present embodiment, a 2112-byte area to which column addresses 0 to 2111 are assigned is used without being separated into a user area and a redundant area as in the prior art. A header area (HD) 30 is allocated to a 7-byte area having column addresses 0 to 6. A first sector area 25 is allocated to an area of 512 bytes with column addresses 7 to 518. A first additional data area 31 is assigned to a 14-byte area having column addresses 519 to 532. A second sector area 26 is allocated to an area of 512 bytes with column addresses 533 to 1044. A second additional data area 32 is allocated to a 14-byte area having column addresses 1045 to 1058. A third sector area 27 is allocated to an area of 512 bytes with column addresses 1059 to 1570. A third additional data area 33 is allocated to a 14-byte area having column addresses 1571 to 1584. The fourth sector area 28 is allocated to the area of column addresses 1585 to 2047 and the area of 2049 to 2097 across the block status area (BS) 35 having a column address of 2048. That is, the 512-byte area allocated to the fourth sector area 28 is divided into two areas 28a and 28b with the block status area (BS) 35 interposed therebetween. A fourth additional data area 34 is allocated to a 14-byte area having column addresses 2098 to 2111.

第1セクタ領域25、第2セクタ領域26、第3セクタ領域27及び第4セクタ領域28は、ホストシステム4から与えられる1セクタ(512バイト)単位のユーザデータが記憶される。第1付加データ領域31、第2付加データ領域32、第3付加データ領域33及び第4付加データ領域34はエラー・コレクション・コード(ECC)を含む付加データが記憶される。ここで、第1付加データ領域31には第1セクタ領域25に対応する付加データが記憶され、第2付加データ領域32には第2セクタ領域26に対応する付加データが記憶され、第3付加データ領域33には第3セクタ領域27に対応する付加データが記憶され、第4付加データ領域34には第4セクタ領域28に対応する付加データが記憶される。
ブロックステータス領域(BS)35に記憶されるブロックステータスと、ヘッダ領域(HD)30に記憶される論理アドレス情報等の管理情報は、物理ブロックに含まれる63個のページに共通な情報であり、このブロックステータスと管理情報は、通常は物理ブロックの先頭ページにだけ書き込まれる。
The first sector area 25, the second sector area 26, the third sector area 27, and the fourth sector area 28 store user data in units of one sector (512 bytes) given from the host system 4. In the first additional data area 31, the second additional data area 32, the third additional data area 33, and the fourth additional data area 34, additional data including an error correction code (ECC) is stored. Here, the additional data corresponding to the first sector area 25 is stored in the first additional data area 31, the additional data corresponding to the second sector area 26 is stored in the second additional data area 32, and the third additional data area 31 is stored. Additional data corresponding to the third sector area 27 is stored in the data area 33, and additional data corresponding to the fourth sector area 28 is stored in the fourth additional data area 34.
Management information such as block status stored in the block status area (BS) 35 and logical address information stored in the header area (HD) 30 is information common to 63 pages included in the physical block, The block status and management information are usually written only on the first page of the physical block.

ブロックステータス領域(BS)35に記憶されるブロックステータスは、当該ページが属する物理ブロックが不良か否かを示す情報であり、初期不良ブロックのブロックステータス領域(BS)35には、出荷前に00h(16進数表示)が書き込まれており、このブロックステータスは消去することができない。又、良品ブロックのブロックステータスは消去状態のFFh(16進数表示)であり、後発不良ブロックのブロックステータスについては、0Fh(16進数表示)やF0h(16進数表示)などが書き込まれる。   The block status stored in the block status area (BS) 35 is information indicating whether or not the physical block to which the page belongs is defective. The block status area (BS) 35 of the initial defective block contains 00h before shipment. (Hexadecimal notation) is written and this block status cannot be erased. The block status of the good block is FFh (hexadecimal number display) in the erased state, and 0Fh (hexadecimal number display), F0h (hexadecimal number display), etc. are written as the block status of the subsequent defective block.

上記エラー・コレクション・コード(ECC)は、ホストシステム4から与えられるユーザデータに基づいてECCブロック11で生成される情報であり、フラッシュメモリ2から読み出されるユーザデータに含まれる誤りの検出、訂正に用いられる。例えば、第1セクタ領域25に書き込まれるユーザデータに基づいて生成されるエラー・コレクション・コード(ECC)は、第1付加データ領域31に記憶され、第1セクタ領域25から読み出されるユーザデータに含まれる誤りは、第1付加データ領域31に記憶されているエラー・コレクション・コード(ECC)に基づいて検出、訂正される。尚、エラー・コレクション・コード(ECC)のデータ量は誤りの訂正能力に応じて適宜設定することがでできる。   The error collection code (ECC) is information generated by the ECC block 11 based on user data given from the host system 4, and is used to detect and correct errors contained in user data read from the flash memory 2. Used. For example, an error collection code (ECC) generated based on user data written in the first sector area 25 is stored in the first additional data area 31 and included in the user data read from the first sector area 25. The detected error is detected and corrected based on the error collection code (ECC) stored in the first additional data area 31. Note that the data amount of the error collection code (ECC) can be appropriately set according to the error correction capability.

論理アドレス情報は、ユーザデータが記憶されている物理ブロックと対応関係にある論理ブロックを特定するための情報である。ユーザデータが格納されていない物理ブロックについては、そのブロックの冗長領域に、論理アドレス情報は格納されていない。したがって、冗長領域に論理アドレス情報が格納されているか否かにより、その冗長領域が含まれている物理ブロックに有効なデータが格納されているか否かを判断することができる。つまり、冗長領域に論理アドレス情報が格納されていないとき、その物理ブロックには、有効なデータが格納されていないと判断する。   The logical address information is information for specifying a logical block corresponding to a physical block in which user data is stored. For a physical block in which user data is not stored, logical address information is not stored in the redundant area of the block. Therefore, whether or not valid data is stored in the physical block including the redundant area can be determined based on whether or not the logical address information is stored in the redundant area. That is, when logical address information is not stored in the redundant area, it is determined that valid data is not stored in the physical block.

論理ブロックは、ホストシステム4側のアドレス空間における、複数セクタの領域をまとめたものであり、1個の論理ブロックに含まれる領域は、1個の物理ブロックに含まれる記憶領域となるように設定される。ここで、ホストシステム4側のアドレス空間は、セクタ(512バイト)単位で分割した領域に付けた通番であるLBA(Logical Block Address)で管理されている。又、複数セクタの領域をまとめた論理ブロックに付けた通番を論理ブロック番号(LBN)と呼んでいる。   A logical block is a collection of areas of a plurality of sectors in the address space on the host system 4 side, and an area included in one logical block is set to be a storage area included in one physical block. Is done. Here, the address space on the host system 4 side is managed by an LBA (Logical Block Address) which is a serial number assigned to an area divided in units of sectors (512 bytes). A serial number assigned to a logical block in which areas of a plurality of sectors are collected is called a logical block number (LBN).

尚、論理ブロックと物理ブロックとの対応関係は通常、アドレス変換テーブルによって管理され、このアドレス変換テーブルを用いて論理ブロック番号(LBN)が物理ブロックアドレス(PBA)に変換される。又、このアドレス変換テーブルは、ヘッダ領域(HD)30に記憶される論理アドレス情報に基づいて作成される。   The correspondence relationship between the logical block and the physical block is usually managed by an address conversion table, and the logical block number (LBN) is converted into a physical block address (PBA) using this address conversion table. The address conversion table is created based on logical address information stored in the header area (HD) 30.

次に、ホストシステム4からLBAで指定されるアクセス領域と、フラッシュメモリ2内のページ及び第1セクタ領域25〜第4セクタ領域28との対応関係について説明する。本実施の形態では、1個の論理ブロックに対して1個の物理ブロックを割り当てているため、1個の論理ブロックには256セクタの領域が含まれる。従って、ホストシステム4から指定されたLBAの下位8ビットを除いた上位ビットが論理ブロック番号(LBN)に対応する。この論理ブロック番号(LBN)は、アドレス変換テーブルに基づいて物理ブロックアドレス(PBA)に変換される。ホストシステム4から指定されたLBAの下位8ビットのうち、上位6ビット(0〜63)は物理ブロックに含まれるページ0〜ページ63を特定する番号になり、下位2ビットは各ページに含まれる第1セクタ領域25〜第4セクタ領域28を特定する番号になる。   Next, the correspondence relationship between the access area specified by the LBA from the host system 4 and the pages in the flash memory 2 and the first sector area 25 to the fourth sector area 28 will be described. In this embodiment, since one physical block is assigned to one logical block, one logical block includes an area of 256 sectors. Accordingly, the upper bits excluding the lower 8 bits of the LBA designated from the host system 4 correspond to the logical block number (LBN). This logical block number (LBN) is converted into a physical block address (PBA) based on the address conversion table. Of the lower 8 bits of the LBA specified by the host system 4, the upper 6 bits (0 to 63) are numbers that specify page 0 to page 63 included in the physical block, and the lower 2 bits are included in each page. The numbers specify the first sector area 25 to the fourth sector area 28.

上記のような対応関係により、フラッシュメモリ2にアクセスするときに与えるロウアドレスは、アドレス変換テーブルに基づいて求められた物理ブロックアドレス(PBA)の下位側に、LBAの下位側から数えて8ビット目から3ビット目までの6ビット(0〜63)を連結することにより求められる。又、フラッシュメモリ2にアクセスするときに与えるカラムアドレスは、LBAの下位2ビットに基づいて特定される。つまり、LBAの下位2ビットが0(2進数表示:00b)のときは、第1セクタ領域25の先頭のカラムアドレスである7が、LBAの下位2ビットが1(2進数表示:01b)のときは、第2セクタ領域26の先頭のカラムアドレスである533が、LBAの下位2ビットが2(2進数表示:10b)のときは、第3セクタ領域27の先頭のカラムアドレスである1059が、LBAの下位2ビットが3(2進数表示:11b)のときは、第4セクタ領域28の先頭のカラムアドレスである1585がフラッシュメモリ2にアクセスするときに与えられる。   Due to the above correspondence, the row address given when accessing the flash memory 2 is 8 bits counted from the lower side of the LBA to the lower side of the physical block address (PBA) obtained based on the address conversion table. It is obtained by concatenating 6 bits (0 to 63) from the first to the third bit. The column address given when accessing the flash memory 2 is specified based on the lower 2 bits of the LBA. That is, when the lower 2 bits of the LBA are 0 (binary number display: 00b), the first column address of the first sector area 25 is 7, but the lower 2 bits of the LBA is 1 (binary number display: 01b). Is 533, which is the first column address of the second sector area 26, and 1059, which is the first column address of the third sector area 27, when the lower 2 bits of the LBA are 2 (binary number: 10b). When the lower 2 bits of the LBA are 3 (binary representation: 11b), 1585, which is the first column address of the fourth sector area 28, is given when the flash memory 2 is accessed.

次に、フラッシュメモリ2の1個のページに4セクタのユーザデータを書き込む動作を、図4を参照して説明する。   Next, an operation of writing user data of 4 sectors in one page of the flash memory 2 will be described with reference to FIG.

図4(a)はヘッダ領域(HD)30に管理情報を書き込む必要のあるページの場合の書き込み動作であり、t1〜t5の期間にフラッシュメモリ2の入出力バス(I/O)に入力されるコマンド、アドレス及びデータを示している。   FIG. 4A shows a write operation in the case of a page in which management information needs to be written to the header area (HD) 30. The page is input to the input / output bus (I / O) of the flash memory 2 during the period from t1 to t5. Command, address and data.

t1〜t2の期間:
インプットコマンド(IC)が入出力バス(I/O)に入力される。
Period from t1 to t2:
An input command (IC) is input to the input / output bus (I / O).

t2〜t3の期間:
アドレス(AD)が入出力バス(I/O)に入力される。ここでは、書き込み先のページに対応するロウアドレスとヘッダ領域(HD)30の先頭(図3に示した(1))のカラムアドレスである0が入力される。
Period from t2 to t3:
An address (AD) is input to the input / output bus (I / O). Here, the row address corresponding to the page to be written and 0, which is the column address of the header area (HD) 30 ((1) shown in FIG. 3), are input.

t3〜t4の期間:
ロウアドレスで指定されたページに書き込まれるデータ(DT)が入出力バス(I/O)に入力され、ライト・イネーブル(WE)の端子に入力される信号レベルが遷移(ロー・レベルからハイ・レベルへの遷移)するタイミングでフラッシュメモリ2内のレジスタに保持される。入力されたデータ(DT)に対応するカラムアドレスは、ライト・イネーブル(WE)の端子に入力される信号レベルの遷移(ロー・レベルからハイ・レベルへの遷移)に合わせてカウントアップされる(次のカラムアドレスに切り替わる)。このデータ(DT)の入力では、管理情報、ユーザデータ又は付加データが、ライト・イネーブル(WE)の端子に入力される信号レベルの遷移(ロー・レベルからハイ・レベルへの遷移)に合わせて、カラムアドレスの順番で入力される。尚、カラムアドレスが2048に対応するときには、ダミーデータとしてFFh(16進数表示)が入力される。つまり、管理情報、ユーザデータ又は付加データに対応する2111バイトのデータと、カラムアドレスが2048のときに入力されるダミーデータがカラムアドレスの順番で入力される。
Period from t3 to t4:
Data (DT) written to the page specified by the row address is input to the input / output bus (I / O), and the signal level input to the write enable (WE) terminal changes (from low level to high Held in the register in the flash memory 2 at the timing of transition to level). The column address corresponding to the input data (DT) is counted up in accordance with the transition of signal level (transition from low level to high level) input to the terminal of write enable (WE) ( Switch to next column address). In this data (DT) input, management information, user data, or additional data is synchronized with the signal level transition (low level to high level) input to the write enable (WE) terminal. Are entered in the order of column addresses. When the column address corresponds to 2048, FFh (hexadecimal notation) is input as dummy data. That is, 2111 bytes of data corresponding to management information, user data, or additional data, and dummy data input when the column address is 2048 are input in the order of column addresses.

t4〜t5の期間:
プログラムコマンド(PC)が入出力バス(I/O)に入力される。このプログラムコマンド(PC)に応答して、入出力バス(I/O)に入力され、フラッシュメモリ2内のレジスタに保持されたデータ(DT)が、メモリセルアレイに書き込まれる。この書き込みでは、t2〜t3の期間に入力されたロウアドレスで指定されたページに、レジスタに保持されているデータ(DT)が書き込まれる。
Period from t4 to t5:
A program command (PC) is input to the input / output bus (I / O). In response to the program command (PC), data (DT) that is input to the input / output bus (I / O) and held in the register in the flash memory 2 is written into the memory cell array. In this writing, data (DT) held in the register is written to the page specified by the row address input during the period from t2 to t3.

また、図4(b)はヘッダ領域(HD)30に管理情報を書き込む必要がないページの場合の書き込み動作であり、t11〜t15の期間にフラッシュメモリ2の入出力バス(I/O)に入力されるコマンド、アドレス及びデータを示している。   FIG. 4B shows a write operation in the case of a page that does not require management information to be written in the header area (HD) 30. The write operation is performed on the input / output bus (I / O) of the flash memory 2 during the period from t11 to t15. It shows the command, address and data to be input.

t11〜t12の期間:
インプットコマンド(IC)が入出力バス(I/O)に入力される。
Period from t11 to t12:
An input command (IC) is input to the input / output bus (I / O).

t12〜t13の期間:
アドレス(AD)が入出力バス(I/O)に入力される。ここでは、書き込み先のページに対応するロウアドレスと第1セクタ領域25の先頭(図3に示した(2))のカラムアドレスである7が入力される。
Period from t12 to t13:
An address (AD) is input to the input / output bus (I / O). Here, the row address corresponding to the page to be written and 7 which is the column address of the head of the first sector area 25 ((2) shown in FIG. 3) are input.

t13〜t14の期間:
ロウアドレスで指定されたページに書き込まれるデータ(DT)が入出力バス(I/O)に入力され、ライト・イネーブル(WE)の端子に入力される信号レベルが遷移(ロー・レベルからハイ・レベルへの遷移)するタイミングでフラッシュメモリ2内のレジスタに保持される。入力されたデータ(DT)に対応するカラムアドレスは、ライト・イネーブル(WE)の端子に入力される信号レベルの遷移(ロー・レベルからハイ・レベルへの遷移)に合わせてカウントアップされる(次のカラムアドレスに切り替わる)。このデータ(DT)の入力では、ユーザデータ又は付加データが、ライト・イネーブル(WE)の端子に入力される信号レベルの遷移(ロー・レベルからハイ・レベルへの遷移)に合わせて、カラムアドレスの順番で入力される。尚、カラムアドレスが2048に対応するときには、ダミーデータとしてFFh(16進数表示)が入力される。つまり、ユーザデータ又は付加データに対応する2104バイトのデータと、カラムアドレスが2048のときに入力されるダミーデータがカラムアドレスの順番で入力される。この期間に入力されたデータ(DT)はフラッシュメモリ2内のレジスタに保持されるが、データ(DT)が保持されないカラムアドレスが0〜6に対応する領域には、FFh(16進数表示)が保持される。
Period from t13 to t14:
Data (DT) written to the page specified by the row address is input to the input / output bus (I / O), and the signal level input to the write enable (WE) terminal changes (from low level to high level). Held in the register in the flash memory 2 at the timing of transition to level). The column address corresponding to the input data (DT) is counted up in accordance with the transition of the signal level (transition from low level to high level) input to the terminal of write enable (WE) ( Switch to next column address). In the input of this data (DT), the user data or additional data is sent to the column address in accordance with the signal level transition (transition from low level to high level) input to the write enable (WE) terminal. Are entered in the order. When the column address corresponds to 2048, FFh (hexadecimal notation) is input as dummy data. That is, 2104 bytes of data corresponding to user data or additional data and dummy data input when the column address is 2048 are input in the order of column addresses. Data (DT) input during this period is held in a register in the flash memory 2, but FFh (hexadecimal notation) is displayed in an area corresponding to column addresses 0 to 6 where no data (DT) is held. Retained.

t14〜t15の期間:
プログラムコマンド(PC)が入出力バス(I/O)に入力される。このプログラムコマンド(PC)に応答して、入出力バス(I/O)に入力され、フラッシュメモリ2内のレジスタに保持されたデータ(DT)が、メモリセルアレイに書き込まれる。この書き込みでは、t12〜t13の期間に入力されたロウアドレスで指定されたページに、レジスタに保持されているデータ(DT)が書き込まれる。
Period from t14 to t15:
A program command (PC) is input to the input / output bus (I / O). In response to the program command (PC), data (DT) that is input to the input / output bus (I / O) and held in the register in the flash memory 2 is written into the memory cell array. In this writing, data (DT) held in the register is written to the page specified by the row address input during the period from t12 to t13.

尚、第2セクタ領域26、第3セクタ領域27又は第4セクタ領域28から書き込みを開始するときは、第2セクタ領域26、第3セクタ領域27又は第4セクタ領域28の先頭のカラムアドレスがアドレス(AD)として入力される。又、書き込むユーザデータが4セクタ未満(1〜3セクタ)の場合には、書き込むセクタ分のユーザデータと、そのユーザデータに対応する付加データがデータ(DT)として入力される。   When writing is started from the second sector area 26, the third sector area 27, or the fourth sector area 28, the top column address of the second sector area 26, the third sector area 27, or the fourth sector area 28 is It is input as an address (AD). When the user data to be written is less than 4 sectors (1 to 3 sectors), user data for the sector to be written and additional data corresponding to the user data are input as data (DT).

また、インプットコマンド(IC)、及びプログラムコマンド(PC)が入出力バス(I/O)に入力されている期間は、コマンド・ラッチ・イネーブル(CLE)の端子にハイ・レベルの信号が入力され、アドレス・ラッチ・イネーブル(ALE)の端子にロー・レベルの信号が入力される。アドレス(AD)が入出力バス(I/O)に入力されている期間は、コマンド・ラッチ・イネーブル(CLE)の端子にロー・レベルの信号が入力され、アドレス・ラッチ・イネーブル(ALE)の端子にハイ・レベルの信号が入力される。データ(DT)が入出力バス(I/O)に入力されている期間は、コマンド・ラッチ・イネーブル(CLE)の端子にロー・レベルの信号が入力され、アドレス・ラッチ・イネーブル(ALE)の端子にロー・レベルの信号が入力される。インプットコマンド(IC)、プログラムコマンド(PC)及びアドレス(AD)が入出力バス(I/O)に入力されている期間に、ライト・イネーブル(WE)の端子に入力される信号をハイ・レベルからロー・レベルに遷移させることにより、インプットコマンド(IC)、プログラムコマンド(PC)及びアドレス(AD)がフラッシュメモリに取り込まれる。   Further, during the period when the input command (IC) and the program command (PC) are input to the input / output bus (I / O), a high level signal is input to the command latch enable (CLE) terminal. The low level signal is input to the address latch enable (ALE) terminal. While the address (AD) is being input to the input / output bus (I / O), a low level signal is input to the command latch enable (CLE) terminal, and the address latch enable (ALE) A high level signal is input to the terminal. During the period when data (DT) is input to the input / output bus (I / O), a low level signal is input to the terminal of the command latch enable (CLE), and the address latch enable (ALE) A low level signal is input to the terminal. During the period when the input command (IC), program command (PC) and address (AD) are input to the input / output bus (I / O), the signal input to the write enable (WE) terminal is set to high level. The input command (IC), program command (PC), and address (AD) are taken into the flash memory by making the transition from low to low.

次に、フラッシュメモリ2の1個のページから4セクタのユーザデータを読み出す動作を、図5を参照して説明する。尚、ユーザデータの読み出しでは、通常、ヘッダ領域(HD)30に記憶されている管理情報は読み出されない。   Next, an operation of reading user data of 4 sectors from one page of the flash memory 2 will be described with reference to FIG. Note that in the reading of user data, the management information stored in the header area (HD) 30 is not normally read.

図5は、t21〜t25の期間にフラッシュメモリ2の入出力バス(I/O)に入力されるコマンド及びアドレスと入出力バス(I/O)から出力されるデータを示している。   FIG. 5 shows commands and addresses input to the input / output bus (I / O) of the flash memory 2 and data output from the input / output bus (I / O) during the period from t21 to t25.

t21〜t22の期間:
リードコマンド(RC)が入出力バス(I/O)に入力される。
Period from t21 to t22:
A read command (RC) is input to the input / output bus (I / O).

t22〜t23の期間:
アドレス(AD)が入出力バス(I/O)に入力される。ここでは、読み出すページに対応するロウアドレスと第1セクタ領域25の先頭(図3に示した(2))のカラムアドレスである7が入力される。
Period from t22 to t23:
An address (AD) is input to the input / output bus (I / O). Here, the row address corresponding to the page to be read and 7 which is the column address of the head of the first sector area 25 ((2) shown in FIG. 3) are input.

t23〜t24の期間:
フラッシュメモリ2内のメモリセルアレイに記憶されているデータがレジスタに読み出される。この読み出しでは、t22〜t23の期間に入力されたロウアドレスで指定されたページに記憶されているデータがレジスタに読み出される。
Period from t23 to t24:
Data stored in the memory cell array in the flash memory 2 is read to the register. In this reading, the data stored in the page specified by the row address input during the period from t22 to t23 is read to the register.

t24〜t25の期間:
リード・イネーブル(RE)の端子に入力される信号レベルを、ハイ・レベルとロー・レベルに交互に遷移させることより、フラッシュメモリ2内のレジスタに保持されているデータが入出力バス(I/O)から出力される。入出力バス(I/O)から出力されるデータ(DT)のカラムアドレスは、t22〜t23の期間に入力されたカラムアドレスから始まり、リード・イネーブル(RE)の端子に入力される信号レベルの遷移に合わせてカウントアップされる(次のカラムアドレスに切り替わる)。
Period from t24 to t25:
By alternately changing the signal level input to the read enable (RE) terminal between the high level and the low level, the data held in the register in the flash memory 2 is transferred to the input / output bus (I / O). The column address of the data (DT) output from the input / output bus (I / O) starts from the column address input during the period t22 to t23 and has the signal level input to the read enable (RE) terminal. Counts up in accordance with the transition (switches to the next column address).

入出力バス(I/O)から出力されるユーザデータ(第1セクタ領域25、第2セクタ領域26、第3セクタ領域27又は第4セクタ領域28から読み出されたユーザデータ)は、バッファ9に保持される。尚、第4セクタ領域28aと第4セクタ領域28bに挟まれたブロックステータス領域(BS)35から読み出されたブロックステータスについては、バッファ9に保持されないように制御される。   User data (user data read from the first sector area 25, the second sector area 26, the third sector area 27, or the fourth sector area 28) output from the input / output bus (I / O) is stored in the buffer 9 Retained. The block status read from the block status area (BS) 35 sandwiched between the fourth sector area 28a and the fourth sector area 28b is controlled not to be held in the buffer 9.

尚、リードコマンド(RC)が入出力バス(I/O)に入力されている期間は、コマンド・ラッチ・イネーブル(CLE)の端子にハイ・レベルの信号が入力され、アドレス・ラッチ・イネーブル(ALE)の端子にロー・レベルの信号が入力される。アドレス(AD)が入出力バス(I/O)に入力されている期間は、コマンド・ラッチ・イネーブル(CLE)の端子にロー・レベルの信号が入力され、アドレス・ラッチ・イネーブル(ALE)の端子にハイ・レベルの信号が入力される。リードコマンド(RC)、及びアドレス(AD)が入出力バス(I/O)に入力されている期間に、ライト・イネーブル(WE)の端子に入力される信号をロー・レベルからハイ・レベルに遷移させることにより、リードコマンド(RC)、及びアドレス(AD)がフラッシュメモリに取り込まれる。   During the period when the read command (RC) is input to the input / output bus (I / O), a high level signal is input to the terminal of the command latch enable (CLE), and the address latch enable ( A low level signal is input to the ALE terminal. While the address (AD) is being input to the input / output bus (I / O), a low level signal is input to the command latch enable (CLE) terminal, and the address latch enable (ALE) A high level signal is input to the terminal. While the read command (RC) and the address (AD) are input to the input / output bus (I / O), the signal input to the write enable (WE) terminal is changed from the low level to the high level. By making the transition, the read command (RC) and the address (AD) are taken into the flash memory.

次に、第4セクタ領域28に対するユーザデータの書き込みで、第4セクタ領域28aに書き込むユーザデータと第4セクタ領域28bに書き込むユーザデータとの間にブロックステータス領域(BS)35に書き込むダミーデータを挿入する書き込み動作について図6、図7を参照して説明する。第1セクタ領域25〜第3セクタ領域27に対するユーザデータの書き込み動作についても図8を参照して説明する。   Next, when writing user data to the fourth sector area 28, dummy data to be written to the block status area (BS) 35 is written between the user data to be written to the fourth sector area 28a and the user data to be written to the fourth sector area 28b. The writing operation to be inserted will be described with reference to FIGS. The user data write operation to the first sector area 25 to the third sector area 27 will also be described with reference to FIG.

図6は、フラッシュメモリ2にユーザデータ及び付加データを転送するための回路だけを示している。この回路は、フラッシュメモリ・インターフェース・ブロック10に含まれている。   FIG. 6 shows only a circuit for transferring user data and additional data to the flash memory 2. This circuit is included in the flash memory interface block 10.

このフラッシュメモリ2にユーザデータ及び付加データを転送するための回路は、シーケンサ制御回路45、アドレスカウンタ46、JK−F/F(JKフリップ・フロップ)47、AND回路49〜53、比較回路54、55、セレクタ42、43、D−F/F(Dフリップ・フロップ)57から構成されている。   A circuit for transferring user data and additional data to the flash memory 2 includes a sequencer control circuit 45, an address counter 46, a JK-F / F (JK flip-flop) 47, AND circuits 49 to 53, a comparison circuit 54, 55, selectors 42 and 43, and DF / F (D flip-flop) 57.

バッファ9は、第1セクタ領域25〜第4セクタ領域28に書き込むユーザデータ又は第1セクタ領域25〜第4セクタ領域28から読み出したユーザデータを保持する第1バッファ21−1、第2バッファ21−2と、第1付加データ領域31〜第4付加データ領域34に書き込む付加データを保持する第1レジスタ16−1、第2レジスタ16−2から構成されている。尚、第1付加データ領域31〜第4付加データ領域34に書き込む付加データに含まれるエラー・コレクション・コード(ECC)については、ECCブロック11からフラッシュメモリ2に供給される。 The buffer 9 includes a first buffer 21 −1 and a second buffer 21 that hold user data to be written in the first sector area 25 to the fourth sector area 28 or user data read from the first sector area 25 to the fourth sector area 28. -2, the first register 216-1 which holds the additional data to be written to the first additional data area 31 to the fourth additional data area 34, and a second register 16 -2. The error correction code (ECC) included in the additional data to be written in the first additional data area 31 to the fourth additional data area 34 is supplied from the ECC block 11 to the flash memory 2.

シーケンサ制御回路45、アドレスカウンタ46、JK−F/F47、D−F/F57には共通にクロック信号(CLK)が入力されている。   A clock signal (CLK) is commonly input to the sequencer control circuit 45, the address counter 46, the JK-F / F 47, and the DF / F 57.

シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)はAND回路50、51のそれぞれ一方の入力端子に入力され、更にAND回路52の正論理側の入力端子に入力されている。また、シーケンサ制御回路45から出力されるスキップ・セレクト信号(SKP_SEL)はAND回路49の一方の入力端子に入力されている。   The address / incremental signal (AD_INC) output from the sequencer control circuit 45 is input to one input terminal of each of the AND circuits 50 and 51, and further input to the input terminal on the positive logic side of the AND circuit 52. The skip / select signal (SKP_SEL) output from the sequencer control circuit 45 is input to one input terminal of the AND circuit 49.

AND回路49の出力信号(SKIP2)はAND回路52の負論理側の入力端子に入力されている。また、AND回路52の出力信号(CNT_EN)はアドレスカウンタ46のイネーブル端子(EN)に入力されている。   The output signal (SKIP2) of the AND circuit 49 is input to the input terminal on the negative logic side of the AND circuit 52. The output signal (CNT_EN) of the AND circuit 52 is input to the enable terminal (EN) of the address counter 46.

アドレスカウンタ46の出力信号(10ビットのアドレス信号(ADR))は、比較回路54、55、及びバッファ9に入力されている。また、比較回路54の出力信号はAND回路50の他方の入力端子に入力されている。また、比較回路55の出力信号はAND回路51の他方の入力端子に入力され、更にAND回路53の正論理側の入力端子に入力されている。   An output signal of the address counter 46 (10-bit address signal (ADR)) is input to the comparison circuits 54 and 55 and the buffer 9. The output signal of the comparison circuit 54 is input to the other input terminal of the AND circuit 50. The output signal of the comparison circuit 55 is input to the other input terminal of the AND circuit 51, and further input to the input terminal on the positive logic side of the AND circuit 53.

AND回路50の出力信号(J_IN)はJK_F/F47のJ端子に入力されている。また、AND回路51の出力信号(K_IN)はJK_F/F47のK端子に入力されている。また、JK_F/F47のQ出力信号(SKIP1)はAND回路53の負論理側の入力端子、及びAND回路49の他方の入力端子に入力されている。   The output signal (J_IN) of the AND circuit 50 is input to the J terminal of JK_F / F47. The output signal (K_IN) of the AND circuit 51 is input to the K terminal of JK_F / F47. The Q output signal (SKIP1) of JK_F / F47 is input to the negative logic side input terminal of the AND circuit 53 and the other input terminal of the AND circuit 49.

AND回路53が出力する信号(SEL1)は選択信号としてセレクタ43に入力されている。また、セレクタ42の出力信号(D_OUT1)はセレクタ43の一方の入力側に入力されている。また、セレクタ43の他方の入力側にはダミーデータとしてFFh(16進数表示)が入力されている。また、セレクタ43の出力信号(D_OUT2)はD_F/F57に入力されている。また、D_F/F57の出力信号(D_OUT3)はフラッシュメモリ2に入力されている。従って、AND回路53が出力する選択信号(SEL1)に基づいて、セレクタ42の出力信号(D_OUT1)又はダミーデータ(FFh)が、D_F/F57を介してフラッシュメモリ2に入力される。また、フラッシュメモリ2のライト・イネーブル(WE)の端子には、シーケンサ制御回路45から出力されるライト・イネーブル信号(WE_IN)が入力されている。   A signal (SEL1) output from the AND circuit 53 is input to the selector 43 as a selection signal. The output signal (D_OUT1) of the selector 42 is input to one input side of the selector 43. Further, FFh (hexadecimal notation) is input as dummy data to the other input side of the selector 43. The output signal (D_OUT2) of the selector 43 is input to D_F / F57. The output signal (D_OUT3) of D_F / F57 is input to the flash memory 2. Therefore, based on the selection signal (SEL1) output from the AND circuit 53, the output signal (D_OUT1) of the selector 42 or dummy data (FFh) is input to the flash memory 2 via the D_F / F57. A write enable signal (WE_IN) output from the sequencer control circuit 45 is input to the write enable (WE) terminal of the flash memory 2.

セレクタ42にはバッファ9の出力信号(D_OUT0)と、ECCブロック11の出力信号(D_OUT4)が入力されており、シーケンサ制御回路45から出力される選択信号(SEL2)に基づいて、バッファ9の出力信号(D_OUT0)又はECCブロック11の出力信号(D_OUT4)が、セレクタ42の出力信号(D_OUT1)としてセレクタ43に入力される。尚、バッファ9の出力信号(D_OUT0)はECCブロック11にも入力され、ECCブロック11は入力された信号(第1セクタ領域25〜第4セクタ領域28に書き込むユーザデータに対応する信号)に基づいて生成したエラー・コレクション・コード(ECC)を出力信号(D_OUT4)として出力する。   The selector 42 receives the output signal (D_OUT0) of the buffer 9 and the output signal (D_OUT4) of the ECC block 11, and outputs the output of the buffer 9 based on the selection signal (SEL2) output from the sequencer control circuit 45. The signal (D_OUT0) or the output signal (D_OUT4) of the ECC block 11 is input to the selector 43 as the output signal (D_OUT1) of the selector 42. The output signal (D_OUT0) of the buffer 9 is also input to the ECC block 11, and the ECC block 11 is based on the input signal (signal corresponding to user data to be written in the first sector area 25 to the fourth sector area 28). The error correction code (ECC) generated in this way is output as an output signal (D_OUT4).

上記シーケンサ制御回路45は、クロック信号(CLK)に同期してアドレス・インクリメンタル信号(AD_INC)、スキップ・セレクト信号(SKP_SEL)、ライト・イネーブル信号(WE_IN)、選択信号(SEL2)を出力することにより、フラッシュメモリ・インターフェース・ブロック10全体の動作を制御する。   The sequencer control circuit 45 outputs an address / incremental signal (AD_INC), a skip / select signal (SKP_SEL), a write enable signal (WE_IN), and a selection signal (SEL2) in synchronization with the clock signal (CLK). The operation of the entire flash memory interface block 10 is controlled.

アドレスカウンタ46はクロック信号CLKに同期してカウントアップする10ビットのカウンタであり、0〜525のカウント値をアドレス信号(ADR)として出力する。カウント値が525になったときは、「0」にリセットされる。
カウント値が0〜511の期間:
バッファ9が、アドレス信号(ADR)が示すカウント値に基づいて特定される第1バッファ21−1又は第2バッファ21−2内のユーザデータを、出力信号(D_OUT0)として出力する。
The address counter 46 is a 10-bit counter that counts up in synchronization with the clock signal CLK, and outputs a count value of 0 to 525 as an address signal (ADR). When the count value reaches 525, it is reset to “0”.
Period when the count value is 0 to 511:
Buffer 9 outputs the user data of the first buffer 21 -1 or second buffer 21 within -2 specified based on the count value indicating the address signal (ADR) is, as the output signal (D_OUT0).

カウント値が512〜521の期間:
ECCブロック11が、カウント値が0〜511の期間にバッファ9から出力された出力信号(D_OUT0)に基づいて生成されたエラー・コレクション・コード(ECC)を出力信号(D_OUT4)として出力する。
Period in which the count value is 512 to 521:
The ECC block 11 outputs, as an output signal (D_OUT4), an error correction code (ECC) generated based on the output signal (D_OUT0) output from the buffer 9 during the period where the count value is 0 to 511.

カウント値が522〜525の期間:
バッファ9が、アドレス信号(ADR)が示すカウント値に基づいて特定される第1レジスタ16−1又は第2レジスタ16−2内の付加データを、出力信号(D_OUT0)として出力する。
Period in which the count value is 522 to 525:
Buffer 9 outputs the additional data of the first register 216-1 and the second register 16 in -2 specified based on the count value indicating the address signal (ADR) is, as the output signal (D_OUT0).

セレクタ42は、上記シーケンサ制御回路45から出力される選択信号(SEL2)に基づいて、カウント値が0〜511の期間及びカウント値が522〜525の期間については、バッファ9の出力信号(D_OUT0)を出力信号(D_OUT1)として出力し、カウント値が512〜521の期間については、ECCブロック11の出力信号(D_OUT4)を出力信号(D_OUT1)として出力する。ここで、セレクタ42は、ロー・レベル(以下「0」と表記する)の選択信号(SEL2)が与えられたときにECCブロック11の出力信号(D_OUT4)を出力信号(D_OUT1)として出力し、セレクタ42は、ハイ・レベル(以下「1」と表記する)の選択信号(SEL2)が与えられたときにバッファ9の出力信号(D_OUT0)を出力信号(D_OUT1)として出力する。   Based on the selection signal (SEL2) output from the sequencer control circuit 45, the selector 42 outputs the output signal (D_OUT0) of the buffer 9 for the period from 0 to 511 and the period from 522 to 525. Is output as the output signal (D_OUT1), and the output signal (D_OUT4) of the ECC block 11 is output as the output signal (D_OUT1) during the period in which the count value is 512 to 521. Here, the selector 42 outputs the output signal (D_OUT4) of the ECC block 11 as an output signal (D_OUT1) when a selection signal (SEL2) of a low level (hereinafter referred to as “0”) is given. The selector 42 outputs the output signal (D_OUT0) of the buffer 9 as an output signal (D_OUT1) when a selection signal (SEL2) of a high level (hereinafter referred to as “1”) is given.

ホストシステム4から与えられたユーザデータは、フラッシュメモリ2側へのデータ出力が先に終了した側のバッファ(第1バッファ21−1又は第2バッファ21−2)に取り込まれ、先にユーザデータが取り込まれた側のバッファ(第1バッファ21−1又は第2バッファ21−2)に保持されているユーザデータが先にフラッシュメモリ2側に出力される。従って、通常の書き込み動作では、ホストシステム4から与えられるユーザデータの入力先は、第1バッファ21−1と第2バッファ21−2が交互に選択され、フラッシュメモリ2側に出力されるユーザデータの出力元も第1バッファ21−1と第2バッファ21−2が交互に選択される。 The user data given from the host system 4 is taken into the buffer (first buffer 21-1 or second buffer 21-2 ) on the side where the data output to the flash memory 2 has been finished first, and the user data is given first. The user data held in the buffer (the first buffer 21-1 or the second buffer 21-2 ) from which the data is taken in is first output to the flash memory 2 side. Accordingly, in a normal write operation, the user data input from the host system 4 is selected as the first buffer 21-1 and the second buffer 21-2 alternately, and the user data output to the flash memory 2 side is selected. The first buffer 21-1 and the second buffer 21-2 are also alternately selected as output sources.

比較回路54はアドレスカウンタ46が出力するアドレス信号(ADR)が示すカウント値が461に一致したとき「1」を出力する。また、比較回路55はアドレスカウンタ46が出力するアドレス信号(ADR)が示すカウント値が462に一致したとき「1」を出力する。   The comparison circuit 54 outputs “1” when the count value indicated by the address signal (ADR) output from the address counter 46 matches 461. The comparison circuit 55 outputs “1” when the count value indicated by the address signal (ADR) output from the address counter 46 matches 462.

JK_F/F47は、エッジトリガJKフリップフロップ回路であり、J入力が「1」、K入力が「0」の状態で、クロック信号(CLK)が立ち上がる(「0」から「1」に遷移する)と、Q出力が「1」となり、J入力が「0」、K入力が「1」の状態で、クロック信号(CLK)が立ち上がる(「0」から「1」に遷移する)と、Q出力が「0」となる。   JK_F / F47 is an edge trigger JK flip-flop circuit. When the J input is “1” and the K input is “0”, the clock signal (CLK) rises (changes from “0” to “1”). When the Q output becomes “1”, the J input is “0”, and the K input is “1”, the clock signal (CLK) rises (changes from “0” to “1”). Becomes “0”.

セレクタ43は、選択信号(SEL1)が「0」のときセレクタ42から出力される出力信号(D_OUT1)を選択し、選択信号(SEL1)が「1」のときダミーデータ(FFh)の信号を選択する。   The selector 43 selects the output signal (D_OUT1) output from the selector 42 when the selection signal (SEL1) is “0”, and selects the dummy data (FFh) signal when the selection signal (SEL1) is “1”. To do.

D_F/F57は、入力信号を1クロック分遅延させるためのDフリップフロップ回路であり、セレクタ43の出力信号(D_OUT2)を1クロック分だけ遅らせた出力信号(D_OUT3)を出力する。このD_F/F57は、ライト・イネーブル信号(WE_IN)の立ち上がり(「0」から「1」への遷移)における出力信号(D_OUT3)を安定させるために用いられている。   D_F / F 57 is a D flip-flop circuit for delaying the input signal by one clock, and outputs an output signal (D_OUT3) obtained by delaying the output signal (D_OUT2) of the selector 43 by one clock. The D_F / F 57 is used to stabilize the output signal (D_OUT3) at the rising edge (transition from “0” to “1”) of the write enable signal (WE_IN).

次に、第4セクタ領域28に対する書き込み動作と第1セクタ領域25〜第3セクタ領域27に対する書き込み動作の違いについて、図7、図8を参照して詳細に説明する。   Next, the difference between the write operation to the fourth sector area 28 and the write operation to the first sector area 25 to the third sector area 27 will be described in detail with reference to FIGS.

以下の説明における書き込み動作は、図4(a)のt3〜t4の期間又は図4(b)のt13〜t14の期間に実行される動作であり、カラムアドレスが7〜2111の領域に書き込むデータをD_F/F57の出力信号(D_OUT3)としてフラッシュメモリ2に与える動作に対応する。この書き込み動作は、第1セクタ領域25と第1付加データ領域31に対応するカラムアドレスが7〜532の領域に書き込むデータを出力する動作と、第2セクタ領域26と第2付加データ領域32に対応するカラムアドレスが533〜1058の領域に書き込むデータを出力する動作と、第3セクタ領域27と第3付加データ領域33に対応するカラムアドレスが1059〜1584の領域に書き込むデータを出力する動作と、第4セクタ領域28と第4付加データ領域34に対応するカラムアドレスが1585〜2111の領域(ブロックステータス領域(BS)35が含まれている)に書き込むデータを出力する動作で構成されている。   The write operation in the following description is an operation executed during the period from t3 to t4 in FIG. 4A or the period from t13 to t14 in FIG. 4B, and data to be written in the region having a column address of 7 to 2111. To the flash memory 2 as an output signal (D_OUT3) of D_F / F57. This write operation includes an operation of outputting data to be written to an area having column addresses 7 to 532 corresponding to the first sector area 25 and the first additional data area 31, and an operation to the second sector area 26 and the second additional data area 32. An operation of outputting data to be written in the area having the corresponding column address of 533 to 1058, and an operation of outputting data to be written in the area of the column address corresponding to the third sector area 27 and the third additional data area 33 are 1059 to 1584. , And the fourth sector area 28 and the fourth additional data area 34 are configured to output data to be written in an area (including the block status area (BS) 35) whose column addresses correspond to 1585 to 2111. .

図7は、カラムアドレスが1585〜2111の領域に書き込むデータを出力する動作において、ダミーデータ(FFh)がD_F/F57の出力信号(D_OUT3)として出力されるタイミングを示している。図8は、カラムアドレスが1585〜2111の領域に書き込むデータを出力する動作と比較するために、カラムアドレスが7〜532の領域、カラムアドレスが533〜1058の領域又はカラムアドレスが1059〜1584の領域に書き込むデータを出力する動作を示している。尚、カラムアドレスが1585〜2111の領域に書き込むデータを出力する動作を行っているときは、シーケンサ制御回路45からスキップ・セレクト信号(SKP_SEL)として「1」が出力され、カラムアドレスが7〜532の領域、カラムアドレスが533〜1058の領域又はカラムアドレスが1059〜1584の領域に書き込むデータを出力する動作を行っているときは、シーケンサ制御回路45からスキップ・セレクト信号(SKP_SEL)として「0」が出力される。   FIG. 7 shows the timing at which the dummy data (FFh) is output as the output signal (D_OUT3) of the D_F / F 57 in the operation of outputting the data to be written in the area of the column address 1585-2111. FIG. 8 shows an example in which the column address is 7 to 532, the column address is 533 to 1058, or the column address is 1059 to 1584 for comparison with the operation of outputting data to be written to the area whose column address is 1585 to 2111. An operation of outputting data to be written to the area is shown. When the operation of outputting the data to be written in the area of the column address 1585 to 2111 is performed, “1” is output from the sequencer control circuit 45 as the skip / select signal (SKP_SEL), and the column address is 7 to 532. When the operation for outputting the data to be written to the above-mentioned area, the area where the column address is 533 to 1058 or the area where the column address is 1059 to 1584 is being performed, “0” is sent from the sequencer control circuit 45 as the skip select signal (SKP_SEL). Is output.

図7において、CLKは、シーケンサ制御回路45とアドレスカウンタ46とJK−F/F47とD−F/F57に入力されるクロック信号を表している。AD_INCは、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号を表している。このアドレス・インクリメンタル信号は、クロック信号を2分周した信号となっている。ADRは、アドレスカウンタ46から出力されるカウント値を示すアドレス信号である。J_INは、JK−F/F47のJ端子に入力されるAND回路50の出力信号を表している。K_INは、JK−F/F47のK端子に入力されるAND回路51の出力信号を表している。   In FIG. 7, CLK represents a clock signal input to the sequencer control circuit 45, the address counter 46, the JK-F / F 47, and the DF / F 57. AD_INC represents an address / incremental signal output from the sequencer control circuit 45. The address / incremental signal is a signal obtained by dividing the clock signal by two. ADR is an address signal indicating a count value output from the address counter 46. J_IN represents the output signal of the AND circuit 50 input to the J terminal of JK-F / F47. K_IN represents an output signal of the AND circuit 51 input to the K terminal of JK-F / F47.

SKIP1&2は、JK−F/F47のQ出力信号(SKIP1)及びAND回路49の出力信号(SKIP2)を示している。つまり、図7の場合、シーケンサ制御回路45からスキップ・セレクト信号(SKP_SEL)として「1」が出力されているので、JK−F/F47のQ出力信号(SKIP1)がそのままAND回路49の出力信号(SKIP2)となる。CNT_ENは、アドレスカウンタ46のイネーブル端子(EN)に入力されるAND回路52の出力信号を表している。   SKIP1 & 2 indicates the Q output signal (SKIP1) of the JK-F / F47 and the output signal (SKIP2) of the AND circuit 49. That is, in the case of FIG. 7, since “1” is output as the skip / select signal (SKP_SEL) from the sequencer control circuit 45, the Q output signal (SKIP1) of the JK-F / F 47 is directly output from the AND circuit 49. (SKIP2). CNT_EN represents an output signal of the AND circuit 52 that is input to the enable terminal (EN) of the address counter 46.

SEL1は、AND回路53の出力する選択信号を表している。このAND回路53の出力信号は選択信号としてセレクタ43に入力される。D_OUT1は、セレクタ42から出力される出力信号を表している。D_OUT2は、セレクタ43から出力される出力信号を表している。D_OUT3は、D_F/F57から出力される出力信号を表している。WE_INは、シーケンサ制御回路45から出力されるライト・イネーブル信号を表している。このライト・イネーブル信号は、フラッシュメモリ2のライト・イネーブル(WE)の端子に入力される。   SEL1 represents a selection signal output from the AND circuit 53. The output signal of the AND circuit 53 is input to the selector 43 as a selection signal. D_OUT1 represents an output signal output from the selector 42. D_OUT2 represents an output signal output from the selector 43. D_OUT3 represents an output signal output from D_F / F57. WE_IN represents a write enable signal output from the sequencer control circuit 45. This write enable signal is input to the write enable (WE) terminal of the flash memory 2.

次に図6と図7を参照して、第4セクタ領域28aに書き込むユーザデータと第4セクタ領域28bに書き込むユーザデータとの間に、ブロックステータス領域(BS)35に書き込むダミーデータ(FFh)を挿入する動作を説明する。尚、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値は、第4セクタ領域28の先頭に対応するカラムアドレスが1585の領域に書き込むユーザデータがバッファ9から出力されるときに0からカウントが開始される。   Next, referring to FIGS. 6 and 7, dummy data (FFh) to be written to the block status area (BS) 35 between the user data to be written to the fourth sector area 28a and the user data to be written to the fourth sector area 28b. The operation of inserting the will be described. Note that the count value indicated by the address signal (ADR) output from the address counter 46 is 0 when the user data to be written to the area whose column address corresponding to the head of the fourth sector area 28 is 1585 is output from the buffer 9. Counting starts from

アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値は、イネーブル端子(EN)に入力される信号が「1」の期間に、クロック信号(CLK)が立ち上がる(「0」から「1」に遷移する)とカウントアップされる。AND回路49の出力信号(SKIP2)が「0」の期間、イネーブル端子(EN)には、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)がそのまま入力される。従って、AND回路49の出力信号(SKIP2)が「0」の期間、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値は、アドレス・インクリメンタル信号(AD_INC)の周期でカウントアップされる。   The count value indicated by the address signal (ADR) output from the address counter 46 is such that the clock signal (CLK) rises (“0” to “1” during the period when the signal input to the enable terminal (EN) is “1”. ”) And count up. While the output signal (SKIP2) of the AND circuit 49 is “0”, the address / incremental signal (AD_INC) output from the sequencer control circuit 45 is directly input to the enable terminal (EN). Therefore, during the period when the output signal (SKIP2) of the AND circuit 49 is “0”, the count value indicated by the address signal (ADR) output from the address counter 46 is counted up in the cycle of the address / incremental signal (AD_INC). .

アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が0〜511の期間と522〜525の期間は、シーケンサ制御回路45から出力される選択信号(SEL2)が「1」になり、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が512〜521の期間は、シーケンサ制御回路45から出力される選択信号(SEL2)が「0」になる。従って、カウント値が0〜511の期間は、第1バッファ21−1又は第2バッファ21−2に保持されているユーザデータがバッファ9の出力信号(D_OUT0)として出力され、この出力信号(D_OUT0)がセレクタ42の出力信号(D_OUT1)としてそのまま出力される。 The selection signal (SEL2) output from the sequencer control circuit 45 becomes “1” during the period in which the count value indicated by the address signal (ADR) output from the address counter 46 is 0 to 511 and 522 to 525, While the count value indicated by the address signal (ADR) output from the address counter 46 is 512 to 521, the selection signal (SEL2) output from the sequencer control circuit 45 is “0”. Therefore, the period of the count value is 0 to 511, the user data held in the first buffer 21 -1 or second buffer 21 -2 is output as an output signal of the buffer 9 (D_OUT0), the output signal (D_OUT0 ) As an output signal (D_OUT1) of the selector 42.

以下、t41〜t46の期間について詳細に説明する。   Hereinafter, the period from t41 to t46 will be described in detail.

t41の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が459から460にカウントアップされる。これに応答して、セレクタ42の出力信号(D_OUT1)が、第1バッファ21−1又は第2バッファ21−2に保持されているカウント値460に対応するユーザデータに切り替わる。AND回路53が出力する選択信号(SEL1)は「0」なので、セレクタ42の出力信号(D_OUT1)が、そのままセレクタ43の出力信号(D_OUT2)として出力される。尚、D_F/F57から出力される出力信号(D_OUT3)は、セレクタ43の出力信号(D_OUT2)より1クロック分遅延しているため、この時点では、未だカウント値459に対応するユーザデータが出力信号(D_OUT3)として出力されている。従って、ライト・イネーブル信号(WE_IN)の立ち上がり(「0」から「1」への遷移)で、カウント値459に対応するユーザデータがフラッシュメモリ2に取り込まれる。
At time t41:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 459 to 460. In response, the output signal of the selector 42 (D_OUT1) is switched to the user data corresponding to the count value 460 stored in the first buffer 21 -1 or second buffer 21 -2. Since the selection signal (SEL1) output from the AND circuit 53 is “0”, the output signal (D_OUT1) of the selector 42 is output as it is as the output signal (D_OUT2) of the selector 43. Since the output signal (D_OUT3) output from the D_F / F 57 is delayed by one clock from the output signal (D_OUT2) of the selector 43, the user data corresponding to the count value 459 is still output at this time. It is output as (D_OUT3). Therefore, user data corresponding to the count value 459 is taken into the flash memory 2 at the rising edge of the write enable signal (WE_IN) (transition from “0” to “1”).

t42の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が460から461にカウントアップされる。これに応答して、セレクタ42の出力信号(D_OUT1)が、第1バッファ21−1又は第2バッファ21−2に保持されているカウント値461に対応するユーザデータに切り替わる。AND回路53が出力する選択信号(SEL1)は「0」なので、セレクタ42の出力信号(D_OUT1)が、そのままセレクタ43の出力信号(D_OUT2)として出力される。尚、D_F/F57から出力される出力信号(D_OUT3)は、セレクタ43の出力信号(D_OUT2)より1クロック分遅延しているため、この時点では、未だカウント値460に対応するユーザデータが出力信号(D_OUT3)として出力されている。従って、ライト・イネーブル信号(WE_IN)の立ち上がり(「0」から「1」への遷移)で、カウント値460に対応するユーザデータがフラッシュメモリ2に取り込まれる。
At time t42:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 460 to 461. In response, the output signal of the selector 42 (D_OUT1) is switched to the user data corresponding to the count value 461 stored in the first buffer 21 -1 or second buffer 21 -2. Since the selection signal (SEL1) output from the AND circuit 53 is “0”, the output signal (D_OUT1) of the selector 42 is output as it is as the output signal (D_OUT2) of the selector 43. Since the output signal (D_OUT3) output from the D_F / F 57 is delayed by one clock from the output signal (D_OUT2) of the selector 43, the user data corresponding to the count value 460 is still output at this time. It is output as (D_OUT3). Therefore, user data corresponding to the count value 460 is taken into the flash memory 2 at the rising edge of the write enable signal (WE_IN) (transition from “0” to “1”).

尚、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が461になることにより、比較回路54の出力信号が「1」になる。この比較回路54の出力信号が「0」に戻るまで、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)が、そのままAND回路50の出力信号(J_IN)として出力されようになる。一方、比較回路55の出力信号は「0」なので、AND回路51の出力信号(K_IN)は「0」のままになっている。   Note that when the count value indicated by the address signal (ADR) output from the address counter 46 becomes 461, the output signal of the comparison circuit 54 becomes “1”. Until the output signal of the comparison circuit 54 returns to “0”, the address / incremental signal (AD_INC) output from the sequencer control circuit 45 is output as it is as the output signal (J_IN) of the AND circuit 50. On the other hand, since the output signal of the comparison circuit 55 is “0”, the output signal (K_IN) of the AND circuit 51 remains “0”.

t43の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が461から462にカウントアップされる。これに応答して、セレクタ42の出力信号(D_OUT1)が、第1バッファ21−1又は第2バッファ21−2に保持されているカウント値462に対応するユーザデータに切り替わる。AND回路53が出力する選択信号(SEL1)は「0」なので、セレクタ42の出力信号(D_OUT1)が、そのままセレクタ43の出力信号(D_OUT2)として出力される。尚、D_F/F57から出力される出力信号(D_OUT3)は、セレクタ43の出力信号(D_OUT2)より1クロック分遅延しているため、この時点では、未だカウント値461に対応するユーザデータが出力信号(D_OUT3)として出力されている。従って、ライト・イネーブル信号(WE_IN)の立ち上がり(「0」から「1」への遷移)で、カウント値461に対応するユーザデータがフラッシュメモリ2に取り込まれる。
At time t43:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 461 to 462. In response, the output signal of the selector 42 (D_OUT1) is switched to the user data corresponding to the count value 462 stored in the first buffer 21 -1 or second buffer 21 -2. Since the selection signal (SEL1) output from the AND circuit 53 is “0”, the output signal (D_OUT1) of the selector 42 is output as it is as the output signal (D_OUT2) of the selector 43. Since the output signal (D_OUT3) output from the D_F / F 57 is delayed by one clock from the output signal (D_OUT2) of the selector 43, the user data corresponding to the count value 461 is still output at this time. It is output as (D_OUT3). Therefore, user data corresponding to the count value 461 is taken into the flash memory 2 at the rising edge of the write enable signal (WE_IN) (transition from “0” to “1”).

AND回路50は、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)を、そのまま出力信号(J_IN)として出力しているので、この時点では、出力信号(J_IN)が「1」になっている。一方、AND回路51の出力信号(K_IN)は「0」なので、JK−F/F47のQ端子から出力されるQ出力信号(SKIP1)は、クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、「0」から「1」に遷移する。また、シーケンサ制御回路45から出力されているスキップ・セレクト信号(SKP_SEL)が「1」なので、AND回路49の出力信号(SKIP2)も「0」から「1」に遷移する。   Since the AND circuit 50 outputs the address / incremental signal (AD_INC) output from the sequencer control circuit 45 as it is as the output signal (J_IN), the output signal (J_IN) becomes “1” at this time. ing. On the other hand, since the output signal (K_IN) of the AND circuit 51 is “0”, the Q output signal (SKIP1) output from the Q terminal of the JK-F / F47 is the rising edge of the clock signal (CLK) (from “0” to “ Transition from “0” to “1”. Since the skip / select signal (SKP_SEL) output from the sequencer control circuit 45 is “1”, the output signal (SKIP2) of the AND circuit 49 also changes from “0” to “1”.

尚、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が462になることにより、比較回路55の出力信号が「1」になる。この比較回路55の出力信号が「0」に戻るまで、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)が、そのままAND回路51の出力信号(K_IN)として出力されるようになる。一方、比較回路54の出力信号は「0」に戻るで、AND回路50の出力信号(J_IN)は「0」になる。   Note that when the count value indicated by the address signal (ADR) output from the address counter 46 becomes 462, the output signal of the comparison circuit 55 becomes “1”. Until the output signal of the comparison circuit 55 returns to “0”, the address / incremental signal (AD_INC) output from the sequencer control circuit 45 is output as it is as the output signal (K_IN) of the AND circuit 51. On the other hand, the output signal of the comparison circuit 54 returns to “0”, and the output signal (J_IN) of the AND circuit 50 becomes “0”.

t44の時点:
AND回路49の出力信号(SKIP2)が「1」の期間は、AND回路52の出力信号(CNT_EN)が「0」なので、クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)でアドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値はカウントアップされない。従って、比較回路55の出力信号も「1」のまま維持される。又、セレクタ42の出力信号(D_OUT1)は、第1バッファ21−1又は第2バッファ21−2に保持されているカウント値462に対応するユーザデータの出力が維持される。
At time t44:
Since the output signal (CNT_EN) of the AND circuit 52 is “0” during the period when the output signal (SKIP2) of the AND circuit 49 is “1”, the rising edge of the clock signal (CLK) (the transition from “0” to “1”) ), The count value indicated by the address signal (ADR) output from the address counter 46 is not counted up. Accordingly, the output signal of the comparison circuit 55 is also maintained at “1”. The output signal of the selector 42 (D_OUT1), the output of the user data is maintained corresponding to the count value 462 stored in the first buffer 21 -1 or second buffer 21 -2.

AND回路51は、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)を、そのまま出力信号(K_IN)として出力しているので、この時点では、出力信号(K_IN)が「1」になっている。一方、AND回路50の出力信号(J_IN)は「0」なので、JK−F/F47のQ端子から出力されるQ出力信号(SKIP1)は、クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で「1」から「0」に遷移する。このQ出力信号(SKIP1)が「1」から「0」に遷移することにより、AND回路49の出力信号(SKIP2)も「1」から「0」に遷移する。又、比較回路55の出力信号が「1」なので、AND回路53が出力する選択信号(SEL1)が「0」から「1」に遷移する。   Since the AND circuit 51 outputs the address / incremental signal (AD_INC) output from the sequencer control circuit 45 as it is as the output signal (K_IN), the output signal (K_IN) becomes “1” at this time. ing. On the other hand, since the output signal (J_IN) of the AND circuit 50 is “0”, the Q output signal (SKIP1) output from the Q terminal of the JK-F / F47 is the rising edge of the clock signal (CLK) (from “0” to “ Transition from “1” to “0”. When the Q output signal (SKIP1) transitions from “1” to “0”, the output signal (SKIP2) of the AND circuit 49 also transitions from “1” to “0”. Further, since the output signal of the comparison circuit 55 is “1”, the selection signal (SEL1) output from the AND circuit 53 transits from “0” to “1”.

AND回路53が出力する選択信号(SEL1)が「1」になるので、セレクタ43の出力信号(D_OUT2)が、セレクタ42の出力信号(D_OUT1)からダミーデータ(FFh)に切り替わる。尚、D_F/F57から出力される出力信号(D_OUT3)は、この時点では、未だカウント値462に対応するユーザデータなので、ライト・イネーブル信号(WE_IN)の立ち上がり(「0」から「1」への遷移)で、カウント値462に対応するユーザデータがフラッシュメモリ2に取り込まれる。   Since the selection signal (SEL1) output from the AND circuit 53 is “1”, the output signal (D_OUT2) of the selector 43 is switched from the output signal (D_OUT1) of the selector 42 to dummy data (FFh). Note that the output signal (D_OUT3) output from the D_F / F 57 is still user data corresponding to the count value 462 at this time, and therefore, the rising edge of the write enable signal (WE_IN) (from “0” to “1”). (Transition), user data corresponding to the count value 462 is taken into the flash memory 2.

AND回路49の出力信号(SKIP2)が「0」に戻るため、アドレスカウンタ46のイネーブル端子(EN)に、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)が、AND回路52の出力信号(CNT_EN)として、そのまま入力されるようになる。   Since the output signal (SKIP2) of the AND circuit 49 returns to “0”, the address / incremental signal (AD_INC) output from the sequencer control circuit 45 is output to the enable terminal (EN) of the address counter 46. The signal (CNT_EN) is input as it is.

t45の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が462から463にカウントアップされる。これに応答して、セレクタ42の出力信号(D_OUT1)が、第1バッファ21−1又は第2バッファ21−2に保持されているカウント値463に対応するユーザデータに切り替わる。
At time t45:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 462 to 463. In response, the output signal of the selector 42 (D_OUT1) is switched to the user data corresponding to the count value 463 stored in the first buffer 21 -1 or second buffer 21 -2.

アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が462から463になるので、比較回路55の出力信号が「0」になり、AND回路53が出力する選択信号(SEL1)も「0」になる。又、AND回路53が出力する選択信号(SEL1)が「0」になるので、セレクタ43の出力信号(D_OUT2)が、ダミーデータ(FFh)からセレクタ42の出力信号(D_OUT1)に切り替わる。尚、D_F/F57から出力される出力信号(D_OUT3)は、この時点では、未だダミーデータ(FFh)なので、ライト・イネーブル信号(WE_IN)の立ち上がり(「0」から「1」への遷移)で、ダミーデータ(FFh)がフラッシュメモリ2に取り込まれる。   Since the count value indicated by the address signal (ADR) output from the address counter 46 is changed from 462 to 463, the output signal of the comparison circuit 55 is “0”, and the selection signal (SEL1) output from the AND circuit 53 is also “ 0 ”. Further, since the selection signal (SEL1) output from the AND circuit 53 is “0”, the output signal (D_OUT2) of the selector 43 is switched from the dummy data (FFh) to the output signal (D_OUT1) of the selector 42. Note that the output signal (D_OUT3) output from the D_F / F 57 is still dummy data (FFh) at this time, so at the rising edge of the write enable signal (WE_IN) (transition from “0” to “1”). The dummy data (FFh) is taken into the flash memory 2.

t46の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が463から464にカウントアップされる。これに応答して、セレクタ42の出力信号(D_OUT1)が、第1バッファ21−1又は第2バッファ21−2に保持されているカウント値464に対応するユーザデータに切り替わる。AND回路53が出力する選択信号(SEL1)は「0」なので、セレクタ42の出力信号(D_OUT1)が、そのままセレクタ43の出力信号(D_OUT2)として出力される。尚、D_F/F57から出力される出力信号(D_OUT3)は、セレクタ43の出力信号(D_OUT2)より1クロック分遅延しているため、この時点では、未だカウント値463に対応するユーザデータが出力信号(D_OUT3)として出力されている。従って、ライト・イネーブル信号(WE_IN)の立ち上がり(「0」から「1」への遷移)で、カウント値463に対応するユーザデータがフラッシュメモリ2に取り込まれる。
At time t46:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 463 to 464. In response, the output signal of the selector 42 (D_OUT1) is switched to the user data corresponding to the count value 464 stored in the first buffer 21 -1 or second buffer 21 -2. Since the selection signal (SEL1) output from the AND circuit 53 is “0”, the output signal (D_OUT1) of the selector 42 is output as it is as the output signal (D_OUT2) of the selector 43. Since the output signal (D_OUT3) output from the D_F / F 57 is delayed by one clock from the output signal (D_OUT2) of the selector 43, the user data corresponding to the count value 463 is still output at this time. It is output as (D_OUT3). Therefore, user data corresponding to the count value 463 is taken into the flash memory 2 at the rising edge of the write enable signal (WE_IN) (transition from “0” to “1”).

上述のように、第4セクタ領域28に対するユーザデータの書き込みでは、シーケンサ制御回路45からスキップ・セレクト信号(SKP_SEL)として「1」が出力されている。スキップ・セレクト信号(SKP_SEL)が「1」の場合、第4セクタ領域28aの末尾に書き込むユーザデータ(第1バッファ21−1又は第2バッファ21−2に保持されているカウント値462に対応するユーザデータ)と第4セクタ領域28bの先頭に書き込むユーザデータ(第1バッファ21−1又は第2バッファ21−2に保持されているカウント値463に対応するユーザデータ)との間にブロックステータス領域(BS)35に書き込むダミーデータ(FFh)が挿入される。尚、ブロックステータス領域(BS)35に書き込まれるダミーデータはFFh(16進数表示)なので、ブロックステータス領域(BS)35に記憶されているブロックステータスは変更されない。 As described above, “1” is output from the sequencer control circuit 45 as the skip / select signal (SKP_SEL) in writing user data to the fourth sector area 28. If the skip select signal (SKP_SEL) is "1", corresponding to the user data (first buffer 21 -1 or the second count value 462 stored in the buffer 21 -2 written at the end of the fourth sector region 28a Block status area between the user data) and user data to be written at the head of the fourth sector area 28b (user data corresponding to the count value 463 held in the first buffer 21-1 or the second buffer 21-2 ) Dummy data (FFh) to be written in (BS) 35 is inserted. Since the dummy data written in the block status area (BS) 35 is FFh (hexadecimal notation), the block status stored in the block status area (BS) 35 is not changed.

次に、シーケンサ制御回路45からスキップ・セレクト信号(SKP_SEL)として「0」が出力されている場合の動作、つまり、カラムアドレスが7〜532の領域、カラムアドレスが533〜1058の領域又はカラムアドレスが1059〜1584の領域に書き込むデータを出力する場合の動作について図8を参照して説明する。   Next, the operation when “0” is output as the skip / select signal (SKP_SEL) from the sequencer control circuit 45, that is, the region where the column address is 7 to 532, the region where the column address is 533 to 1058, or the column address Will be described with reference to FIG. 8 when the data to be written in the areas 1059 to 1584 is output.

カラムアドレスが7〜532の領域、カラムアドレスが533〜1058の領域及びカラムアドレスが1059〜1584の領域に書き込むデータを出力する動作は、同様の動作である。ここで、カラムアドレスが7〜532の領域に書き込むデータを出力する場合は、第1セクタ領域25の先頭に対応するカラムアドレスが7の領域に書き込むユーザデータがバッファ9から出力されるときに、アドレスカウンタ46のカウントが0から開始され、カラムアドレスが533〜1058の領域に書き込むデータを出力する場合は、第2セクタ領域26の先頭に対応するカラムアドレスが533の領域に書き込むユーザデータがバッファ9から出力されるときに、アドレスカウンタ46のカウントが0から開始され、カラムアドレスが1059〜1584の領域に書き込むデータを出力する場合は、第3セクタ領域27の先頭に対応するカラムアドレスが1059の領域に書き込むユーザデータがバッファ9から出力されるときに、アドレスカウンタ46のカウントが0から開始される。   The operation for outputting the data to be written to the region having the column address of 7 to 532, the region having the column address of 533 to 1058, and the region having the column address of 1059 to 1584 is the same operation. Here, when outputting data to be written to an area having a column address of 7 to 532, when user data to be written to an area having a column address of 7 corresponding to the head of the first sector area 25 is output from the buffer 9, When the address counter 46 starts counting from 0 and outputs data to be written in the area of the column addresses 533 to 1058, the user data to be written in the area of the column address 533 corresponding to the head of the second sector area 26 is buffered. 9, when the address counter 46 starts counting from 0 and outputs data to be written in the area of column addresses 1059 to 1584, the column address corresponding to the head of the third sector area 27 is 1059. When user data to be written to the area is output from the buffer 9 Count of the address counter 46 is started from zero.

スキップ・セレクト信号(SKP_SEL)が「1」の場合と同様に、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値は、イネーブル端子(EN)に入力される信号が「1」の期間に、クロック信号(CLK)が立ち上がる(「0」から「1」に遷移する)とカウントアップされる。尚、スキップ・セレクト信号(SKP_SEL)として「0」が出力されている場合、AND回路49の出力信号(SKIP2)は常に「0」なので、イネーブル端子(EN)には、常にシーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)がそのまま入力される。従って、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値は、アドレス・インクリメンタル信号(AD_INC)の周期で常にカウントアップされる。   As in the case where the skip / select signal (SKP_SEL) is “1”, the count value indicated by the address signal (ADR) output from the address counter 46 is “1” as the signal input to the enable terminal (EN). When the clock signal (CLK) rises (changes from “0” to “1”) during the period, it is counted up. When “0” is output as the skip / select signal (SKP_SEL), the output signal (SKIP2) of the AND circuit 49 is always “0”, so that the enable terminal (EN) is always connected to the enable terminal (EN) from the sequencer control circuit 45. The output address / incremental signal (AD_INC) is input as it is. Accordingly, the count value indicated by the address signal (ADR) output from the address counter 46 is always counted up in the cycle of the address / incremental signal (AD_INC).

アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が0〜511の期間と522〜525の期間は、シーケンサ制御回路45から出力される選択信号(SEL2)が「1」になり、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が512〜521の期間は、シーケンサ制御回路45から出力される選択信号(SEL2)が「0」になる。従って、カウント値が0〜511の期間は、第1バッファ21−1又は第2バッファ21−2に保持されているユーザデータがバッファ9の出力信号(D_OUT0)として出力され、この出力信号(D_OUT0)がセレクタ42の出力信号(D_OUT1)としてそのまま出力される。 The selection signal (SEL2) output from the sequencer control circuit 45 becomes “1” during the period in which the count value indicated by the address signal (ADR) output from the address counter 46 is 0 to 511 and 522 to 525, While the count value indicated by the address signal (ADR) output from the address counter 46 is 512 to 521, the selection signal (SEL2) output from the sequencer control circuit 45 is “0”. Therefore, the period of the count value is 0 to 511, the user data held in the first buffer 21 -1 or second buffer 21 -2 is output as an output signal of the buffer 9 (D_OUT0), the output signal (D_OUT0 ) As an output signal (D_OUT1) of the selector 42.

以下、シーケンサ制御回路45から出力されるスキップ・セレクト信号(SKP_SEL)が「1」の場合と異なるt53〜t55の期間についてだけ、詳細に説明する。   Hereinafter, only the period t53 to t55 different from the case where the skip / select signal (SKP_SEL) output from the sequencer control circuit 45 is “1” will be described in detail.

t53の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が461から462にカウントアップされる。これに応答して、セレクタ42の出力信号(D_OUT1)が、第1バッファ21−1又は第2バッファ21−2に保持されているカウント値462に対応するユーザデータに切り替わる。AND回路53が出力する選択信号(SEL1)は「0」なので、セレクタ42の出力信号(D_OUT1)が、そのままセレクタ43の出力信号(D_OUT2)として出力される。尚、D_F/F57から出力される出力信号(D_OUT3)は、セレクタ43の出力信号(D_OUT2)より1クロック分遅延しているため、この時点では、未だカウント値461に対応するユーザデータが出力信号(D_OUT3)として出力されている。従って、ライト・イネーブル信号(WE_IN)の立ち上がり(「0」から「1」への遷移)で、カウント値461に対応するユーザデータがフラッシュメモリ2に取り込まれる。
At time t53:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 461 to 462. In response, the output signal of the selector 42 (D_OUT1) is switched to the user data corresponding to the count value 462 stored in the first buffer 21 -1 or second buffer 21 -2. Since the selection signal (SEL1) output from the AND circuit 53 is “0”, the output signal (D_OUT1) of the selector 42 is output as it is as the output signal (D_OUT2) of the selector 43. Since the output signal (D_OUT3) output from the D_F / F 57 is delayed by one clock from the output signal (D_OUT2) of the selector 43, the user data corresponding to the count value 461 is still output at this time. It is output as (D_OUT3). Therefore, user data corresponding to the count value 461 is taken into the flash memory 2 at the rising edge of the write enable signal (WE_IN) (transition from “0” to “1”).

この時点での比較回路54の出力信号は「1」なので、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)は、そのままAND回路50の出力信号(J_IN)として出力されている。従って、この時点でのAND回路50の出力信号(J_IN)は「1」になっている。一方、比較回路55の出力信号は「0」なので、AND回路51の出力信号(K_IN)は「0」になっている。   Since the output signal of the comparison circuit 54 at this time is “1”, the address / incremental signal (AD_INC) output from the sequencer control circuit 45 is output as it is as the output signal (J_IN) of the AND circuit 50. Therefore, the output signal (J_IN) of the AND circuit 50 at this time is “1”. On the other hand, since the output signal of the comparison circuit 55 is “0”, the output signal (K_IN) of the AND circuit 51 is “0”.

JK−F/F47のJ端子に入力されているAND回路50の出力信号(J_IN)が「1」で、K端子に入力されているAND回路51の出力信号(K_IN)が「0」なので、JK−F/F47のQ端子から出力されるQ出力信号(SKIP1)は、クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で「0」から「1」に遷移する。但し、シーケンサ制御回路45から出力されているスキップ・セレクト信号(SKP_SEL)が「0」なので、AND回路49の出力信号(SKIP2)は「0」のままで変化しない。   Since the output signal (J_IN) of the AND circuit 50 input to the J terminal of the JK-F / F47 is “1” and the output signal (K_IN) of the AND circuit 51 input to the K terminal is “0”, The Q output signal (SKIP1) output from the Q terminal of the JK-F / F47 transitions from “0” to “1” at the rising edge of the clock signal (CLK) (transition from “0” to “1”). . However, since the skip / select signal (SKP_SEL) output from the sequencer control circuit 45 is “0”, the output signal (SKIP2) of the AND circuit 49 remains “0” and does not change.

尚、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が462になるため、比較回路55の出力信号が「1」になる。この比較回路55の出力信号が「0」に戻るまで、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)が、そのままAND回路51の出力信号(J_IN)として出力されるようになる。一方、比較回路54の出力信号は「0」になるので、AND回路50の出力信号(K_IN)は「0」になる。   Since the count value indicated by the address signal (ADR) output from the address counter 46 is 462, the output signal of the comparison circuit 55 is “1”. Until the output signal of the comparison circuit 55 returns to “0”, the address / incremental signal (AD_INC) output from the sequencer control circuit 45 is output as it is as the output signal (J_IN) of the AND circuit 51. On the other hand, since the output signal of the comparison circuit 54 is “0”, the output signal (K_IN) of the AND circuit 50 is “0”.

t54の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が462から463にカウントアップされる。これに応答して、セレクタ42の出力信号(D_OUT1)が、第1バッファ21−1又は第2バッファ21−2に保持されているカウント値463に対応するユーザデータに切り替わる。
At time t54:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 462 to 463. In response, the output signal of the selector 42 (D_OUT1) is switched to the user data corresponding to the count value 463 stored in the first buffer 21 -1 or second buffer 21 -2.

AND回路51は、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)を、そのまま出力信号(K_IN)として出力しているので、この時点では、出力信号(K_IN)が「1」になっている。一方、AND回路50の出力信号(J_IN)は「0」なので、JK−F/F47のQ端子から出力されるQ出力信号(SKIP1)は、クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で「1」から「0」に遷移する。シーケンサ制御回路45から出力されているスキップ・セレクト信号(SKP_SEL)が「0」なので、出力信号(SKIP1)が「1」から「0」に遷移しても、AND回路49の出力信号(SKIP2)は「0」のままで変化しない。又、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が463になることにより、比較回路55の出力信号が「0」になるので、出力信号(SKIP1)が「1」から「0」に遷移しても、AND回路53が出力する選択信号(SEL1)は「0」のままで変化しない。   Since the AND circuit 51 outputs the address / incremental signal (AD_INC) output from the sequencer control circuit 45 as it is as the output signal (K_IN), the output signal (K_IN) becomes “1” at this time. ing. On the other hand, since the output signal (J_IN) of the AND circuit 50 is “0”, the Q output signal (SKIP1) output from the Q terminal of the JK-F / F47 is the rising edge of the clock signal (CLK) (from “0” to “ Transition from “1” to “0”. Since the skip / select signal (SKP_SEL) output from the sequencer control circuit 45 is “0”, even if the output signal (SKIP1) transitions from “1” to “0”, the output signal (SKIP2) of the AND circuit 49 Remains “0” and does not change. Further, since the count value indicated by the address signal (ADR) output from the address counter 46 becomes 463, the output signal of the comparison circuit 55 becomes “0”, so the output signal (SKIP1) changes from “1” to “ Even when transitioning to “0”, the selection signal (SEL1) output from the AND circuit 53 remains “0” and does not change.

AND回路53が出力する選択信号(SEL1)は「0」のままで変化しないので、セレクタ42の出力信号(D_OUT1)が、セレクタ43の出力信号(D_OUT2)として出力され続け、ダミーデータは出力されない。尚、D_F/F57から出力される出力信号(D_OUT3)は、セレクタ43の出力信号(D_OUT2)より1クロック分遅延しているため、この時点では、未だカウント値462に対応するユーザデータが出力信号(D_OUT3)として出力されている。従って、ライト・イネーブル信号(WE_IN)の立ち上がり(「0」から「1」への遷移)で、カウント値462に対応するユーザデータがフラッシュメモリ2に取り込まれる。   Since the selection signal (SEL1) output from the AND circuit 53 remains “0” and does not change, the output signal (D_OUT1) of the selector 42 continues to be output as the output signal (D_OUT2) of the selector 43, and no dummy data is output. . Since the output signal (D_OUT3) output from the D_F / F 57 is delayed by one clock from the output signal (D_OUT2) of the selector 43, the user data corresponding to the count value 462 is still output at this time. It is output as (D_OUT3). Therefore, user data corresponding to the count value 462 is taken into the flash memory 2 at the rising edge of the write enable signal (WE_IN) (transition from “0” to “1”).

t55の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が463から464にカウントアップされる。これに応答して、セレクタ42の出力信号(D_OUT1)が、第1バッファ21−1又は第2バッファ21−2に保持されているカウント値464に対応するユーザデータに切り替わる。AND回路53が出力する選択信号(SEL1)は「0」なので、セレクタ42の出力信号(D_OUT1)が、そのままセレクタ43の出力信号(D_OUT2)として出力される。尚、D_F/F57から出力される出力信号(D_OUT3)は、セレクタ43の出力信号(D_OUT2)より1クロック分遅延しているため、この時点では、未だカウント値463に対応するユーザデータが出力信号(D_OUT3)として出力されている。従って、ライト・イネーブル信号(WE_IN)の立ち上がり(「0」から「1」への遷移)で、カウント値463に対応するユーザデータがフラッシュメモリ2に取り込まれる。
At time t55:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 463 to 464. In response, the output signal of the selector 42 (D_OUT1) is switched to the user data corresponding to the count value 464 stored in the first buffer 21 -1 or second buffer 21 -2. Since the selection signal (SEL1) output from the AND circuit 53 is “0”, the output signal (D_OUT1) of the selector 42 is output as it is as the output signal (D_OUT2) of the selector 43. Since the output signal (D_OUT3) output from the D_F / F 57 is delayed by one clock from the output signal (D_OUT2) of the selector 43, the user data corresponding to the count value 463 is still output at this time. It is output as (D_OUT3). Therefore, user data corresponding to the count value 463 is taken into the flash memory 2 at the rising edge of the write enable signal (WE_IN) (transition from “0” to “1”).

上述のように、シーケンサ制御回路45から出力されているスキップ・セレクト信号(SKP_SEL)が「0」の場合、第1バッファ21−1又は第2バッファ21−2に保持されているカウント値462に対応するユーザデータと第1バッファ21−1又は第2バッファ21−2に保持されているカウント値463に対応するユーザデータとの間にダミーデータ(FFh)は挿入されない。従って、スキップ・セレクト信号(SKP_SEL)を「0」にすることにより、カラムアドレスが7〜532の領域、カラムアドレスが533〜1058の領域又はカラムアドレスが1059〜1584の領域に書き込むデータの出力を行うことができる。 As described above, when the skip select signal output from the sequencer control circuit 45 (SKP_SEL) is "0", the count value 462 stored in the first buffer 21 -1 or second buffer 21 -2 dummy data (FFh) between corresponding user data and the user data corresponding to the first buffer 21 -1 or the second count value 463 stored in the buffer 21 -2 not inserted. Accordingly, by setting the skip / select signal (SKP_SEL) to “0”, the output of the data to be written to the area of column address 7 to 532, the column address of 533 to 1058, or the area of column address 1059 to 1584 is output. It can be carried out.

次に、第4セクタ領域28とブロックステータス領域(BS)35を含むカラムアドレスが1585〜2097の領域から読み出したデータを、第1バッファ21−1又は第2バッファ21−2に保持する動作について、図9及び図10を参照して説明する。この動作では、第4セクタ領域28から読み出されたデータだけが第1バッファ21−1又は第2バッファ21−2に保持され、ブロックステータス領域(BS)35から読み出されたデータは、第1バッファ21−1又は第2バッファ21−2に保持されない。 Next, the operation of the column address including the fourth sector region 28 and the block status area (BS) 35 is the data read out from the area of 1585 to 2097, held in the first buffer 21 -1 or second buffer 21 -2 This will be described with reference to FIGS. In this operation, only the data read from the fourth sector region 28 is held in the first buffer 21 -1 or second buffer 21 -2, the data read out from the block status area (BS) 35, a It is not held in the first buffer 21-1 or the second buffer 21-2 .

図9は、フラッシュメモリ2から読み出したデータを、バッファ9とECCブロック11に転送するための回路だけを示している。この回路は、フラッシュメモリ・インターフェース・ブロック10に含まれており、図6に示したフラッシュメモリ2にデータを転送するための回路と一部の回路を共用している。   FIG. 9 shows only a circuit for transferring data read from the flash memory 2 to the buffer 9 and the ECC block 11. This circuit is included in the flash memory interface block 10 and shares part of the circuit with the circuit for transferring data to the flash memory 2 shown in FIG.

このフラッシュメモリ2から読み出したデータを、バッファ9とECCブロック11に転送するための回路は、シーケンサ制御回路45、アドレスカウンタ46、JK−F/F(JKフリップ・フロップ)47、AND回路49〜53、58、比較回路54、55、D−F/F59から構成されている。尚、図9において図6と同じ符号のものは同じものを示している。又、図6の回路は、書き込みで動作の説明で必要な部分だけを示し、図9の回路は、読み出し動作で動作の説明で必要な部分だけを示している。   A circuit for transferring the data read from the flash memory 2 to the buffer 9 and the ECC block 11 includes a sequencer control circuit 45, an address counter 46, a JK-F / F (JK flip-flop) 47, and AND circuits 49- 53, 58, comparison circuits 54 and 55, and DF / F 59. In FIG. 9, the same reference numerals as those in FIG. 6 denote the same components. Further, the circuit of FIG. 6 shows only a part necessary for the explanation of the operation by writing, and the circuit of FIG. 9 shows only a part necessary for the explanation of the operation by the reading operation.

以下、図6に示されていない回路、信号等について説明する。シーケンサ制御回路45から出力されるリード・イネーブル信号(RE_IN)は、フラッシュメモリ2のリード・イネーブル(RE)の端子に入力され、バッファ・ライト・イネーブル信号(BF_WE1)は、AND回路58の正論理側の入力端子に入力されている。AND回路58の負論理側の入力端子には、AND回路53から出力される選択信号(SEL1)が入力されている。AND回路58から出力されるバッファ・ライト・イネーブル信号(BF_WE2)は、バッファ9に入力され、このバッファ・ライト・イネーブル信号(BF_WE2)はバッファ9のライト・イネーブル信号となる。   Hereinafter, circuits, signals, and the like not shown in FIG. 6 will be described. The read enable signal (RE_IN) output from the sequencer control circuit 45 is input to the read enable (RE) terminal of the flash memory 2, and the buffer write enable signal (BF_WE1) is the positive logic of the AND circuit 58. Is input to the input terminal. The selection signal (SEL 1) output from the AND circuit 53 is input to the negative logic side input terminal of the AND circuit 58. The buffer write enable signal (BF_WE2) output from the AND circuit 58 is input to the buffer 9, and this buffer write enable signal (BF_WE2) becomes a write enable signal for the buffer 9.

D−F/F59は、イネーブル端子(EN)を備えたDフリップフロップであり、このイネーブル端子(EN)には、AND回路52から出力される出力信号(CNT_EN)入力されている。D−F/F59は、イネーブル端子(EN)に入力されている信号が「1」の期間に、クロック信号(CLK)が立ち上がる(「0」から「1」に遷移する)と、出力信号(D_IN2)が入力端子に入力されている信号(フラッシュメモリ2から出力されているデータ信号(D_IN1))に切り替わる。つまり、シーケンサ制御回路45から出力されるリード・イネーブル信号(RE_IN)に基づいてフラッシュメモリ2から出力されたデータ信号(D_IN1)は、D−F/F59でタイミング調整され、出力信号(D_IN2)としてバッファ9及びECCブロック11に入力される。   The D-F / F 59 is a D flip-flop having an enable terminal (EN), and an output signal (CNT_EN) output from the AND circuit 52 is input to the enable terminal (EN). When the clock signal (CLK) rises (changes from “0” to “1”) while the signal input to the enable terminal (EN) is “1”, the DF / F 59 outputs an output signal ( D_IN2) is switched to the signal input to the input terminal (data signal (D_IN1) output from the flash memory 2). That is, the timing of the data signal (D_IN1) output from the flash memory 2 based on the read enable signal (RE_IN) output from the sequencer control circuit 45 is adjusted by the DF / F 59 and is output as the output signal (D_IN2). The data is input to the buffer 9 and the ECC block 11.

D−F/F59から出力される出力信号(D_IN2)に対応するデータは、バッファ・ライト・イネーブル信号(BF_WE2)の立ち上がり(「0」から「1」への遷移)で、バッファ9に取り込まれる。バッファ9に取り込まれたデータは、アドレスカウンタ46が出力するアドレス信号(ADR)が示すカウント値により特定される第1バッファ21−1又は第2バッファ21−2内の領域に保持される。 Data corresponding to the output signal (D_IN2) output from the DF / F 59 is taken into the buffer 9 at the rising edge of the buffer write enable signal (BF_WE2) (transition from “0” to “1”). . The data fetched into the buffer 9 is held in an area in the first buffer 21-1 or the second buffer 21-2 specified by the count value indicated by the address signal (ADR) output from the address counter 46.

次に図9と図10を参照して、カラムアドレスが1585〜2097の領域から読み出したデータのうち、第4セクタ領域28から読み出したデータだけを第1バッファ21−1又は第2バッファ21−2に保持する動作について説明する。 Next, FIG. 9 and with reference to FIG. 10, out of the data column address is read out from the area of 1585 to 2097, only the data read from the fourth sector region 28 first buffer 21 -1 or second buffer 21 - 2 will be described.

以下の説明における読み出し動作は、図5のt24〜t25の期間に実行される動作の一部である。尚、第4セクタ領域28から読み出されたデータは、バッファ9とECCブロック11に取り込まれ、ECCブロック11には、更に、第4付加データ領域34から読み出されたエラー・コレクション・コード(ECC)が取り込まれる。ECCブロック11は、第4セクタ領域28から読み出されたデータ及び第4付加データ領域34から読み出されたエラー・コレクション・コード(ECC)に基づいて、第1バッファ21−1又は第2バッファ21−2に保持されているデータに含まれる誤りを訂正するが、以下の説明では、第4セクタ領域28から読み出したデータを第1バッファ21−1又は第2バッファ21−2に保持する動作についてだけ説明する。 The read operation in the following description is a part of the operation executed in the period from t24 to t25 in FIG. The data read from the fourth sector area 28 is taken into the buffer 9 and the ECC block 11, and the error correction code (read from the fourth additional data area 34) is further stored in the ECC block 11. ECC) is captured. Based on the data read from the fourth sector area 28 and the error collection code (ECC) read from the fourth additional data area 34, the ECC block 11 is either the first buffer 21-1 or the second buffer. correcting errors included in the data held in the 21 -2, but the following description, the operation for holding the data read out from the fourth sector region 28 in the first buffer 21 -1 or second buffer 21 -2 I will explain only.

図10は、ブロックステータス領域(BS)35から読み出されたデータに対応するデータ信号(D_IN1)が出力されている期間の近傍における各信号を示している。尚、この動作では、シーケンサ制御回路45から出力されるスキップ・セレクト信号(SKP_SEL)が「1」になっている。   FIG. 10 shows each signal in the vicinity of the period in which the data signal (D_IN1) corresponding to the data read from the block status area (BS) 35 is output. In this operation, the skip / select signal (SKP_SEL) output from the sequencer control circuit 45 is “1”.

図10において、クロック信号(CLK)、アドレス・インクリメンタル信号(AD_INC)、アドレス信号(ADR)、出力信号(J_IN)、出力信号(K_IN)、出力信号(SKIP1)、出力信号(SKIP2)、出力信号(CNT_EN)、選択信号(SEL1)は、図7と同じ信号を示している。   In FIG. 10, a clock signal (CLK), an address / incremental signal (AD_INC), an address signal (ADR), an output signal (J_IN), an output signal (K_IN), an output signal (SKIP1), an output signal (SKIP2), and an output signal (CNT_EN) and the selection signal (SEL1) indicate the same signals as in FIG.

BF_WE1は、シーケンサ制御回路45から出力されるバッファ・ライト・イネーブル信号を表している。BF_WE2は、AND回路58から出力されるバッファ・ライト・イネーブル信号を表している。AND回路58は、選択信号(SEL1)が「0」の期間、シーケンサ制御回路45から出力されるバッファ・ライト・イネーブル信号(BF_WE1)を、そのままバッファ・ライト・イネーブル信号(BF_WE2)として出力する。尚、選択信号(SEL1)が「1」の期間は、バッファ・ライト・イネーブル信号(BF_WE2)が「0」になる。   BF_WE1 represents a buffer write enable signal output from the sequencer control circuit 45. BF_WE2 represents a buffer write enable signal output from the AND circuit 58. The AND circuit 58 outputs the buffer write enable signal (BF_WE1) output from the sequencer control circuit 45 as it is as the buffer write enable signal (BF_WE2) while the selection signal (SEL1) is “0”. During the period when the selection signal (SEL1) is “1”, the buffer write enable signal (BF_WE2) is “0”.

RE_INは、シーケンサ制御回路45から出力されるリード・イネーブル信号を表している。D_IN1は、フラッシュメモリ2から出力されるデータ信号を表している。フラッシュメモリ2から出力されるデータ信号(D_IN1)に対応するデータは、リード・イネーブル信号(RE_IN)の立ち下がり(「1」から「0」への遷移)に応答して切り替わる。ここで、tdは、リード・イネーブル信号(RE_IN)の立ち下がり(「1」から「0」への遷移)から、データ信号(D_IN1)として出力されるデータが切り替わるまでの遅延時間を表している)。D_IN2は、D−F/F59から出力される出力信号を表している。尚、アドレス・インクリメンタル信号(AD_INC)とリード・イネーブル信号(RE_IN)は、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が0のときに、D−F/F59から出力される出力信号(D_IN2)が第4セクタ領域28の先頭領域(カラムアドレスが1585の領域)から読み出されたデータに対応するように、シーケンサ制御回路45によって制御されている。   RE_IN represents a read enable signal output from the sequencer control circuit 45. D_IN 1 represents a data signal output from the flash memory 2. Data corresponding to the data signal (D_IN1) output from the flash memory 2 is switched in response to the fall of the read enable signal (RE_IN) (transition from “1” to “0”). Here, td represents a delay time from the fall of the read enable signal (RE_IN) (transition from “1” to “0”) until the data output as the data signal (D_IN1) is switched. ). D_IN2 represents an output signal output from the DF / F 59. The address incremental signal (AD_INC) and the read enable signal (RE_IN) are output from the DF / F 59 when the count value indicated by the address signal (ADR) output from the address counter 46 is 0. The output signal (D_IN2) is controlled by the sequencer control circuit 45 so as to correspond to the data read from the head area (area where the column address is 1585) of the fourth sector area 28.

t61の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が459から460にカウントアップされ、D−F/F59から出力される出力信号(D_IN2)は、この時点でのデータ信号(D_IN1)に対応するデータに切り替わる。つまり、アドレス信号(ADR)が示すカウント値のカウントアップに同期して、D−F/F59から出力される出力信号(D_IN2)は、次のデータに切り替わる。ここでは、カウント値459に対応するデータ(D_459)からカウント値460に対応するデータ(D_460)に切り替わる。
At time t61:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 459 to 460, and DF / The output signal (D_IN2) output from F59 is switched to data corresponding to the data signal (D_IN1) at this time. In other words, the output signal (D_IN2) output from the DF / F 59 is switched to the next data in synchronization with the count up indicated by the address signal (ADR). Here, the data (D_459) corresponding to the count value 459 is switched to the data (D_460) corresponding to the count value 460.

t61〜t61’の期間:
リード・イネーブル信号(RE_IN)の立ち下がり(「1」から「0」への遷移)に応答して、フラッシュメモリ2から出力されているデータ信号(D_IN1)に対応するデータは次のデータに切り替わる。ここでは、カウント値460に対応するデータ(D_460)からカウント値461に対応するデータ(D_461)に切り替わる。
Period from t61 to t61 ′:
In response to the fall of the read enable signal (RE_IN) (transition from “1” to “0”), the data corresponding to the data signal (D_IN1) output from the flash memory 2 is switched to the next data. . Here, the data (D_460) corresponding to the count value 460 is switched to the data (D_461) corresponding to the count value 461.

t61’の時点:
バッファ・ライト・イネーブル信号(BF_WE2)の立ち上がり(「0」から「1」への遷移)で、D−F/F59から出力されている出力信号(D_IN2)に対応するデータ(D_460)がバッファ9に取り込まれ、第1バッファ21−1又は第2バッファ21−2のカウント値460に対応する領域に保持される。
At time t61 ':
Data (D_460) corresponding to the output signal (D_IN2) output from the DF / F 59 at the rising edge of the buffer write enable signal (BF_WE2) (transition from “0” to “1”) is stored in the buffer 9. And held in the area corresponding to the count value 460 of the first buffer 21-1 or the second buffer 21-2 .

t62の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が460から461にカウントアップされ、D−F/F59から出力される出力信号(D_IN2)は、この時点でのデータ信号(D_IN1)に対応するデータに切り替わる。ここでは、カウント値460に対応するデータ(D_460)からカウント値461に対応するデータ(D_461)に切り替わる。
At time t62:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 460 to 461, and DF / The output signal (D_IN2) output from F59 is switched to data corresponding to the data signal (D_IN1) at this time. Here, the data (D_460) corresponding to the count value 460 is switched to the data (D_461) corresponding to the count value 461.

尚、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が461になることにより、比較回路54の出力信号が「1」になる。この比較回路54の出力信号が「0」に戻るまで、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)が、そのままAND回路50の出力信号(J_IN)として出力されようになる。一方、比較回路55の出力信号は「0」なので、AND回路51の出力信号(K_IN)は「0」のままになっている。   Note that when the count value indicated by the address signal (ADR) output from the address counter 46 becomes 461, the output signal of the comparison circuit 54 becomes “1”. Until the output signal of the comparison circuit 54 returns to “0”, the address / incremental signal (AD_INC) output from the sequencer control circuit 45 is output as it is as the output signal (J_IN) of the AND circuit 50. On the other hand, since the output signal of the comparison circuit 55 is “0”, the output signal (K_IN) of the AND circuit 51 remains “0”.

t62〜t62’の期間:
リード・イネーブル信号(RE_IN)の立ち下がり(「1」から「0」への遷移)に応答して、フラッシュメモリ2から出力されているデータ信号(D_IN1)に対応するデータは次のデータに切り替わる。ここでは、カウント値461に対応するデータ(D_461)からカウント値462に対応するデータ(D_462)に切り替わる。
Period from t62 to t62 ′:
In response to the fall of the read enable signal (RE_IN) (transition from “1” to “0”), the data corresponding to the data signal (D_IN1) output from the flash memory 2 is switched to the next data. . Here, the data (D_461) corresponding to the count value 461 is switched to the data (D_462) corresponding to the count value 462.

t62’の時点:
バッファ・ライト・イネーブル信号(BF_WE2)の立ち上がり(「0」から「1」への遷移)で、D−F/F59から出力される出力信号(D_IN2)に対応するデータ(D_461)がバッファ9に取り込まれ、第1バッファ21−1又は第2バッファ21−2のカウント値461に対応する領域に保持される。
At time t62 ':
Data (D_461) corresponding to the output signal (D_IN2) output from the DF / F 59 is input to the buffer 9 at the rising edge of the buffer write enable signal (BF_WE2) (transition from “0” to “1”). captured and held in a region corresponding to the count value 461 of the first buffer 21 -1 or second buffer 21 -2.

t63の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が461から462にカウントアップされ、D−F/F59から出力される出力信号(D_IN2)は、この時点でのデータ信号(D_IN1)に対応するデータに切り替わる。ここでは、カウント値461に対応するデータ(D_461)からカウント値462に対応するデータ(D_462)に切り替わる。
At time t63:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 461 to 462, and DF / The output signal (D_IN2) output from F59 is switched to data corresponding to the data signal (D_IN1) at this time. Here, the data (D_461) corresponding to the count value 461 is switched to the data (D_462) corresponding to the count value 462.

AND回路50は、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)を、そのまま出力信号(J_IN)として出力しているので、この時点では、出力信号(J_IN)が「1」になっている。一方、AND回路51の出力信号(K_IN)は「0」なので、JK−F/F47のQ端子から出力されるQ出力信号(SKIP1)は、クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で「0」から「1」に遷移する。また、シーケンサ制御回路45から出力されているスキップ・セレクト信号(SKP_SEL)が「1」なので、AND回路49の出力信号(SKIP2)も「0」から「1」に遷移する。   Since the AND circuit 50 outputs the address / incremental signal (AD_INC) output from the sequencer control circuit 45 as an output signal (J_IN) as it is, the output signal (J_IN) becomes “1” at this time. ing. On the other hand, since the output signal (K_IN) of the AND circuit 51 is “0”, the Q output signal (SKIP1) output from the Q terminal of the JK-F / F47 is the rising edge of the clock signal (CLK) (from “0” to “ Transition from “0” to “1”. Since the skip / select signal (SKP_SEL) output from the sequencer control circuit 45 is “1”, the output signal (SKIP2) of the AND circuit 49 also changes from “0” to “1”.

尚、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が462になることにより、比較回路55の出力信号が「1」になる。この比較回路55の出力信号が「0」に戻るまで、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)が、そのままAND回路51の出力信号(K_IN)として出力されるようになる。一方、比較回路54の出力信号は「0」に戻るで、AND回路50の出力信号(J_IN)は「0」になる。   Note that when the count value indicated by the address signal (ADR) output from the address counter 46 becomes 462, the output signal of the comparison circuit 55 becomes “1”. Until the output signal of the comparison circuit 55 returns to “0”, the address / incremental signal (AD_INC) output from the sequencer control circuit 45 is output as it is as the output signal (K_IN) of the AND circuit 51. On the other hand, the output signal of the comparison circuit 54 returns to “0”, and the output signal (J_IN) of the AND circuit 50 becomes “0”.

t63〜t63’の期間:
リード・イネーブル信号(RE_IN)の立ち下がり(「1」から「0」への遷移)に応答して、フラッシュメモリ2から出力されるデータ信号(D_IN1)に対応するデータは次のデータに切り替わる。ここでは、カウント値462に対応するデータ(D_462)からブロックステータス領域(BS)35から読み出されたデータに切り替わる。
Period from t63 to t63 ′:
In response to the fall of the read enable signal (RE_IN) (transition from “1” to “0”), the data corresponding to the data signal (D_IN1) output from the flash memory 2 is switched to the next data. Here, the data (D_462) corresponding to the count value 462 is switched to the data read from the block status area (BS) 35.

t63’の時点:
バッファ・ライト・イネーブル信号(BF_WE2)の立ち上がり(「0」から「1」への遷移)で、D−F/F59から出力されている出力信号(D_IN2)に対応するデータ(D_462)がバッファ9に取り込まれ、第1バッファ21−1又は第2バッファ21−2のカウント値462に対応する領域に保持される。
At time t63 ':
Data (D_462) corresponding to the output signal (D_IN2) output from the DF / F 59 at the rising edge of the buffer write enable signal (BF_WE2) (transition from “0” to “1”) is buffer 9. incorporated into and held in a region corresponding to the count value 462 of the first buffer 21 -1 or second buffer 21 -2.

t64の時点:
AND回路49の出力信号(SKIP2)が「1」の期間は、AND回路52の出力信号(CNT_EN)が「0」なので、クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値はカウントアップされない。従って、比較回路55の出力信号も「1」のまま維持される。
At time t64:
Since the output signal (CNT_EN) of the AND circuit 52 is “0” during the period when the output signal (SKIP2) of the AND circuit 49 is “1”, the rising edge of the clock signal (CLK) (the transition from “0” to “1”) ), The count value indicated by the address signal (ADR) output from the address counter 46 is not counted up. Accordingly, the output signal of the comparison circuit 55 is also maintained at “1”.

AND回路51は、シーケンサ制御回路45から出力されるアドレス・インクリメンタル信号(AD_INC)を、そのまま出力信号(K_IN)として出力しているので、この時点では、出力信号(K_IN)が「1」になっている。一方、AND回路50の出力信号(J_IN)は「0」なので、JK−F/F47のQ端子から出力されるQ出力信号(SKIP1)は、クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、「1」から「0」に遷移する。このQ出力信号(SKIP1)が「1」から「0」に遷移することにより、AND回路49の出力信号(SKIP2)も「1」から「0」に遷移する。又、比較回路55の出力信号が「1」なので、AND回路53が出力する選択信号(SEL1)が「0」から「1」に遷移する。   Since the AND circuit 51 outputs the address / incremental signal (AD_INC) output from the sequencer control circuit 45 as it is as the output signal (K_IN), the output signal (K_IN) becomes “1” at this time. ing. On the other hand, since the output signal (J_IN) of the AND circuit 50 is “0”, the Q output signal (SKIP1) output from the Q terminal of the JK-F / F47 is the rising edge of the clock signal (CLK) (from “0” to “ Transition from “1” to “0”. When the Q output signal (SKIP1) transitions from “1” to “0”, the output signal (SKIP2) of the AND circuit 49 also transitions from “1” to “0”. Further, since the output signal of the comparison circuit 55 is “1”, the selection signal (SEL1) output from the AND circuit 53 transits from “0” to “1”.

AND回路52の出力信号(CNT_EN)が「0」なので、クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、D−F/F59から出力される出力信号(D_IN2)は、この時点でのデータ信号(D_IN1)に対応するデータに切り替わらない。つまり、D−F/F59から出力される出力信号(D_IN2)は、カウント値462に対応するデータ(D_462)からブロックステータス領域(BS)35から読み出されたデータに切り替わらない。   Since the output signal (CNT_EN) of the AND circuit 52 is “0”, the output signal (D_IN2) output from the DF / F 59 at the rising edge of the clock signal (CLK) (transition from “0” to “1”). Does not switch to data corresponding to the data signal (D_IN1) at this time. That is, the output signal (D_IN2) output from the DF / F 59 does not switch from the data (D_462) corresponding to the count value 462 to the data read from the block status area (BS) 35.

t64〜t64’の期間:
リード・イネーブル信号(RE_IN)の立ち下がり(「1」から「0」への遷移)に応答して、フラッシュメモリ2から出力されるデータ信号(D_IN1)に対応するデータは次のデータに切り替わる。ここでは、ブロックステータス領域(BS)35から読み出されたデータから、カウント値463に対応するデータ(D_463)に切り替わる。
Period from t64 to t64 ′:
In response to the fall of the read enable signal (RE_IN) (transition from “1” to “0”), the data corresponding to the data signal (D_IN1) output from the flash memory 2 is switched to the next data. Here, the data read from the block status area (BS) 35 is switched to data (D_463) corresponding to the count value 463.

t64’の時点:
選択信号(SEL1)が「1」の期間は、バッファ・ライト・イネーブル信号(BF_WE2)が「0」なので、D−F/F59から出力されている出力信号(D_IN2)に対応するデータ(D_462)はバッファ9に取り込まれない。
At time t64 ′:
Since the buffer write enable signal (BF_WE2) is “0” during the period when the selection signal (SEL1) is “1”, the data (D_462) corresponding to the output signal (D_IN2) output from the DF / F 59 Is not taken into the buffer 9.

t65の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が462から463にカウントアップされ、D−F/F59から出力される出力信号(D_IN2)は、この時点でのデータ信号(D_IN1)に対応するデータに切り替わる。ここでは、カウント値462に対応するデータ(D_462)からカウント値463に対応するデータ(D_463)に切り替わる。
At time t65:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 462 to 463, and D−F / The output signal (D_IN2) output from F59 is switched to data corresponding to the data signal (D_IN1) at this time. Here, the data (D_462) corresponding to the count value 462 is switched to the data (D_463) corresponding to the count value 463.

アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が462から463になるので、比較回路55の出力信号が「0」になり、AND回路53が出力する選択信号(SEL1)も「0」になる。又、AND回路53が出力する選択信号(SEL1)が「0」になるので、シーケンサ制御回路45から出力されるバッファ・ライト・イネーブル信号(BF_WE1)が、そのままバッファ・ライト・イネーブル信号(BF_WE2)として出力されるようになる。   Since the count value indicated by the address signal (ADR) output from the address counter 46 is changed from 462 to 463, the output signal of the comparison circuit 55 is “0”, and the selection signal (SEL1) output from the AND circuit 53 is also “ 0 ”. Since the selection signal (SEL1) output from the AND circuit 53 is “0”, the buffer write enable signal (BF_WE1) output from the sequencer control circuit 45 is used as it is as the buffer write enable signal (BF_WE2). Will be output as.

t65〜t65’の期間:
リード・イネーブル信号(RE_IN)の立ち下がり(「1」から「0」への遷移)に応答して、フラッシュメモリ2から出力されるデータ信号(D_IN1)に対応するデータは次のデータに切り替わる。ここでは、カウント値463に対応するデータ(D_463)からカウント値464に対応するデータ(D_464)に切り替わる。
Period from t65 to t65 ′:
In response to the fall of the read enable signal (RE_IN) (transition from “1” to “0”), the data corresponding to the data signal (D_IN1) output from the flash memory 2 is switched to the next data. Here, the data (D_463) corresponding to the count value 463 is switched to the data (D_464) corresponding to the count value 464.

t65’の時点:
バッファ・ライト・イネーブル信号(BF_WE2)の立ち上がり(「0」から「1」への遷移)で、D−F/F59から出力されている出力信号(D_IN2)に対応するデータ(D_463)がバッファ9に取り込まれ、第1バッファ21−1又は第2バッファ21−2のカウント値463に対応する領域に保持される。
At time t65 ':
Data (D_463) corresponding to the output signal (D_IN2) output from the DF / F 59 at the rising edge of the buffer write enable signal (BF_WE2) (transition from “0” to “1”) is stored in the buffer 9. And held in the area corresponding to the count value 463 of the first buffer 21-1 or the second buffer 21-2 .

t66の時点:
クロック信号(CLK)の立ち上がり(「0」から「1」への遷移)で、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値が463から464にカウントアップされ、D−F/F59から出力される出力信号(D_IN2)は、この時点でのデータ信号(D_IN1)に対応するデータに切り替わる。ここでは、カウント値463に対応するデータ(D_463)からカウント値464に対応するデータ(D_464)に切り替わる。
At time t66:
At the rising edge of the clock signal (CLK) (transition from “0” to “1”), the count value indicated by the address signal (ADR) output from the address counter 46 is counted up from 463 to 464, and DF / The output signal (D_IN2) output from F59 is switched to data corresponding to the data signal (D_IN1) at this time. Here, the data (D_463) corresponding to the count value 463 is switched to the data (D_464) corresponding to the count value 464.

t66〜t66’の期間:
リード・イネーブル信号(RE_IN)の立ち下がり(「1」から「0」への遷移)に応答して、フラッシュメモリ2から出力されているデータ信号(D_IN1)に対応するデータは次のデータに切り替わる。ここでは、カウント値464に対応するデータ(D_464)からカウント値465に対応するデータ(D_465)に切り替わる。
Period from t66 to t66 ′:
In response to the fall of the read enable signal (RE_IN) (transition from “1” to “0”), the data corresponding to the data signal (D_IN1) output from the flash memory 2 is switched to the next data. . Here, the data (D_464) corresponding to the count value 464 is switched to the data (D_465) corresponding to the count value 465.

t66’の時点:
バッファ・ライト・イネーブル信号(BF_WE2)の立ち上がり(「0」から「1」への遷移)で、D−F/F59から出力されている出力信号(D_IN2)に対応するデータ(D_460)がバッファ9に取り込まれ、第1バッファ21−1又は第2バッファ21−2のカウント値464に対応する領域に保持される。
At time t66 ′:
Data (D_460) corresponding to the output signal (D_IN2) output from the DF / F 59 at the rising edge of the buffer write enable signal (BF_WE2) (transition from “0” to “1”) is stored in the buffer 9. incorporated into and held in a region corresponding to the count value 464 of the first buffer 21 -1 or second buffer 21 -2.

上述のように、第4セクタ領域28とブロックステータス領域(BS)35を含む領域からのデータの読み出しでは、シーケンサ制御回路45からスキップ・セレクト信号(SKP_SEL)として「1」が出力されているため、JK−F/F47のQ端子から出力されるQ出力信号(SKIP1)が「1」の期間(t63〜t64の期間)は、AND回路49の出力信号(SKIP2)が「1」になる。AND回路49の出力信号(SKIP2)が「0」の期間は、AND回路52から出力される出力信号(CNT_EN)も「0」なので、D−F/F59から出力される出力信号(D_IN2)は、カウント値462に対応するデータ(D_462)からブロックステータス領域(BS)35から読み出されたデータに切り替わらない。又、AND回路49の出力信号(SKIP2)が「0」の期間は、アドレスカウンタ46から出力されるアドレス信号(ADR)が示すカウント値もカウントアップされない。従って、第1バッファ21−1又は第2バッファ21−2のカウント値0〜511に対応する領域には、第4セクタ領域28から読み出されたデータだけがカラムアドレスの順番で保持される。 As described above, when data is read from the area including the fourth sector area 28 and the block status area (BS) 35, the sequencer control circuit 45 outputs “1” as the skip select signal (SKP_SEL). The output signal (SKIP2) of the AND circuit 49 is “1” during the period (period t63 to t64) in which the Q output signal (SKIP1) output from the Q terminal of the JK-F / F47 is “1”. Since the output signal (CNT_EN) output from the AND circuit 52 is also “0” during the period when the output signal (SKIP2) of the AND circuit 49 is “0”, the output signal (D_IN2) output from the DF / F 59 is The data (D_462) corresponding to the count value 462 is not switched to the data read from the block status area (BS) 35. Further, during the period when the output signal (SKIP2) of the AND circuit 49 is “0”, the count value indicated by the address signal (ADR) output from the address counter 46 is not counted up. Therefore, in the region corresponding to the count value 0 to 511 of the first buffer 21 -1 or second buffer 21 -2, only the data read from the fourth sector region 28 is held in the order of the column address.

第1セクタ領域25、第2セクタ領域26及び第3セクタ領域27からのデータの読み出しでは、シーケンサ制御回路45からスキップ・セレクト信号(SKP_SEL)として「0」が出力されているため、AND回路49の出力信号(SKIP2)及びAND回路53が出力する選択信号(SEL1)は「0」のままで変化しない。従って、第1セクタ領域25、第2セクタ領域26及び第3セクタ領域27の各領域から読み出されたデータは、第1バッファ21−1又は第2バッファ21−2のカウント値0〜511に対応する領域にカラムアドレスの順番で保持される。 When reading data from the first sector area 25, the second sector area 26, and the third sector area 27, the sequencer control circuit 45 outputs “0” as the skip / select signal (SKP_SEL). Output signal (SKIP2) and the selection signal (SEL1) output from the AND circuit 53 remain "0" and do not change. Accordingly, the first sector region 25, data read from each area of the second sector region 26 and the third sector region 27, the count value 0 to 511 of the first buffer 21 -1 or second buffer 21 -2 Stored in the corresponding area in the order of column addresses.

以上の説明では、1個のページに4セクタのユーザデータが記憶される構成のフラッシュメモリ2を例として説明したが、1個のページに複数セクタのユーザデータが記憶される構成であれば、1個のページに記憶されるユーザデータのセクタ数が限定されることはない。例えば、個のページに記憶されるユーザデータのセクタ数は、8セクタであってもよい。   In the above description, the flash memory 2 having a configuration in which user data of 4 sectors is stored in one page has been described as an example. However, if user data of a plurality of sectors is stored in one page, The number of sectors of user data stored in one page is not limited. For example, the number of sectors of user data stored in each page may be eight sectors.

又、ブロックステータス領域(BS)35を挟んで2つの領域に分割されるセクタ領域(ユーザデータが記憶される領域)におけるブロックステータス領域(BS)35の位置についても限定されることはない。つまり、本実施の形態では、カウント値462に対応するユーザデータを書き込む領域とカウント値463に対応するユーザデータを書き込む領域の間にブロックステータス領域(BS)35があったが、このブロックステータス領域(BS)35の位置が変わって同様に実施することができる。例えば、カウント値397に対応するユーザデータを書き込む領域とカウント値398に対応するユーザデータを書き込む領域の間にブロックステータス領域(BS)35があった場合は、比較回路54の出力信号が「1」になるカウント値を398に設定し、比較回路55の出力信号が「1」になるカウント値を399に設定すればよい。   Further, the position of the block status area (BS) 35 in the sector area (area where user data is stored) divided into two areas with the block status area (BS) 35 interposed therebetween is not limited. In other words, in the present embodiment, there is a block status area (BS) 35 between the area in which user data corresponding to the count value 462 is written and the area in which user data corresponding to the count value 463 is written. The position of (BS) 35 is changed, and the same operation can be performed. For example, if there is a block status area (BS) 35 between the area where user data corresponding to the count value 397 is written and the area where user data corresponding to the count value 398 is written, the output signal of the comparison circuit 54 is “1”. Is set to 398, and the count value at which the output signal of the comparison circuit 55 is “1” may be set to 399.

又、本実施の形態では、カウントアップ動作をするアドレスカウンタ46を用いたが、比較回路54及び比較回路55の出力信号が「1」になるカウント値、アドレスカウンタ46のカウント値と第1バッファ21−1及び第2バッファ21−2内の領域との対応関係等を適宜設定すれば、アドレスカウンタ46はカウントダウン動作するものであってもよい。 In this embodiment, the address counter 46 that performs a count-up operation is used. However, the count value at which the output signals of the comparison circuit 54 and the comparison circuit 55 become “1”, the count value of the address counter 46 and the first buffer The address counter 46 may perform a count-down operation as long as the correspondence relationship with the areas in the 21-1 and the second buffer 21-2 is appropriately set.

本発明の実施の形態であるフラッシュメモリシステムの概略構成を示すブロック図である。1 is a block diagram showing a schematic configuration of a flash memory system according to an embodiment of the present invention. 本発明の実施の形態で使用されるフラッシュメモリの、アドレス空間の構成について説明する図である。It is a figure explaining the structure of the address space of the flash memory used by embodiment of this invention. 本発明の実施の形態におけるページの構成(記憶領域の割当て)を概略的に示す図である。It is a figure which shows roughly the structure (allocation of a storage area) of the page in embodiment of this invention. フラッシュメモリの1ページ分の書き込み動作を説明する図である。It is a figure explaining the write-in operation for 1 page of flash memory. フラッシュメモリの1ページ分の読み出し動作を説明する図である。It is a figure explaining the read-out operation for 1 page of flash memory. 本発明の実施の形態であるフラッシュメモリ・インターフェース・ブロック10内のデータ書き込みに関わる構成を示す図である。It is a figure which shows the structure in connection with the data writing in the flash memory interface block 10 which is embodiment of this invention. 本発明の実施の形態におけるデータ書き込み動作で、ブロックステータス領域(BS)近傍における第4セクタ領域の書き込み動作を説明する図である。It is a figure explaining the write-in operation | movement of the 4th sector area | region in the block status area | region (BS) vicinity by the data write operation in embodiment of this invention. 本発明の実施の形態におけるデータ書き込み動作で、第1〜第3セクタ領域の書き込み動作を説明する図である。It is a figure explaining the write-in operation | movement of the 1st-3rd sector area | region in the data write-in operation in embodiment of this invention. 本発明の実施の形態であるフラッシュメモリ・インターフェース・ブロック10内のデータ読み出しに関わる構成を示す図である。It is a figure which shows the structure regarding the data reading in the flash memory interface block 10 which is embodiment of this invention. 本発明の実施の形態におけるデータ読み出し動作で、ブロックステータス部(BS)近傍における第4セクタ領域のデータ読み出し動作を説明する図である。It is a figure explaining the data read-out operation | movement of the 4th sector area | region in the block status part (BS) vicinity by the data read-out operation | movement in embodiment of this invention. 従来技術におけるページの構成(記憶領域の割当て)を概略的に示す図である。It is a figure which shows schematically the structure of a page (storage area allocation) in a prior art.

符号の説明Explanation of symbols

1・・・フラッシュメモリシステム
2・・・フラッシュメモリ
3・・・メモリコントローラ
4・・・ホストシステム
6・・・マイクロプロセッサ(動作指示出力手段)
7・・・ホスト・インターフェース・ブロック
8・・・ワークエリア
9・・・バッファ(データ保持手段)
10・・・フラッシュメモリ・インターフェース・ブロック(データ入出力手段)
11・・・ECC(エラー・コレクション・コード)ブロック
12・・・ROM
13・・・外部バス
14・・・内部バス
15・・・チップセレクト信号線
16−1〜16−2・・・第1〜第2レジスタ
21−1〜21−2・・・第1〜第2バッファ、
25・・・第1セクタ領域
26・・・第2セクタ領域
27・・・第3セクタ領域
28・・・第4セクタ領域
30・・・ヘッダ領域(HD)
31・・・第1付加データ領域
32・・・第2付加データ領域
33・・・第3付加データ領域
34・・・第4付加データ領域
35・・・ブロックステータス領域(BS)
38・・・「第4セクタ+BS」(第4セクタとブロックステータス部(BS)を併せた領域)
42、43・・・セレクタ
45・・・シーケンサ制御回路
46・・・アドレスカウンタ
47・・・JK−F/F(JKフリップ・フロップ)
49〜53、58・・・AND回路
54、55・・・比較回路
57、59・・・D−F/F(Dフリップ・フロップ)
DESCRIPTION OF SYMBOLS 1 ... Flash memory system 2 ... Flash memory 3 ... Memory controller 4 ... Host system 6 ... Microprocessor (operation instruction output means)
7 ... Host interface block 8 ... Work area 9 ... Buffer (data holding means)
10 ... Flash memory interface block (data input / output means)
11 ... ECC (error collection code) block 12 ... ROM
13 ... external bus 14 ... internal bus 15 ... chip select signal lines 16 -1 to 16 -2 ... first to the second register 21 -1 to 21 -2 ... first to 2 buffers,
25 ... 1st sector area 26 ... 2nd sector area 27 ... 3rd sector area 28 ... 4th sector area 30 ... header area (HD)
31 ... 1st additional data area 32 ... 2nd additional data area 33 ... 3rd additional data area 34 ... 4th additional data area 35 ... Block status area (BS)
38... “4th sector + BS” (area combining the 4th sector and the block status part (BS))
42, 43 ... selector 45 ... sequencer control circuit 46 ... address counter 47 ... JK-F / F (JK flip-flop)
49-53, 58 ... AND circuits 54, 55 ... comparison circuits 57, 59 ... DF / F (D flip-flop)

Claims (6)

ホストシステムからの要求に応じて、複数セクタのデータが記憶されるページを複数個含む物理ブロック単位で消去が行われるフラッシュメモリに対するアクセスを制御するメモリコントローラであって、
前記ホストシステム側から供給される1セクタ単位のユーザデータを保持するデータ保持手段と、
前記データ保持手段に保持されている前記ユーザデータを先頭データから順番に前記フラッシュメモリに転送するユーザデータ転送手段と、
前記ユーザデータ転送手段により前記フラッシュメモリに転送される前記ユーザデータに対応する誤り訂正符号を含む付加データを前記フラッシュメモリに転送する付加データ転送手段と、
予め設定されたダミーデータを前記フラッシュメモリに転送するダミーデータ転送手段と、
前記ユーザデータ転送手段、前記付加データ転送手段及び前記ダミーデータ転送手段を択一的に動作させる制御手段とを備え、
前記制御手段は、前記フラッシュメモリに転送されるデータの書き込み先がブロックステータスの記憶領域に対応するときにだけ前記ダミーデータ転送手段を動作させ、
前記ユーザデータと該ユーザデータに対応する前記付加データは、前記ページ内の連続した領域に書き込まれることを特徴とするメモリコントローラ。
A memory controller that controls access to a flash memory that is erased in physical block units including a plurality of pages in which data of a plurality of sectors is stored in response to a request from a host system,
Data holding means for holding user data in units of one sector supplied from the host system side;
User data transfer means for transferring the user data held in the data holding means to the flash memory in order from the top data;
Additional data transfer means for transferring additional data including an error correction code corresponding to the user data transferred to the flash memory by the user data transfer means to the flash memory;
Dummy data transfer means for transferring preset dummy data to the flash memory;
Control means for selectively operating the user data transfer means, the additional data transfer means, and the dummy data transfer means,
The control means operates the dummy data transfer means only when a write destination of data transferred to the flash memory corresponds to a block status storage area,
The memory controller, wherein the user data and the additional data corresponding to the user data are written in a continuous area in the page.
一定の周期でカウントアップされるカウンタ手段を備え、
前記カウンタ手段は、前記ダミーデータが前記フラッシュメモリに転送される期間に係わるときに1周期分のカウントアップを停止し、
前記ユーザデータ転送手段は、前記カウンタ手段から出力されるカウント値に基づいて、前記ユーザデータの先頭データから末尾データまでのデータの中から前記フラッシュメモリに転送するデータを決定することを特徴とする請求項1に記載のメモリコントローラ。
Provided with a counter means that counts up at a constant cycle,
The counter means stops counting up for one period when the dummy data is transferred to the flash memory.
The user data transfer means determines data to be transferred to the flash memory from data from the top data to the tail data of the user data based on the count value output from the counter means. The memory controller according to claim 1.
前記ダミーデータの論理値が、前記フラッシュメモリの消去状態の論理値に一致することを特徴とする請求項1又は2に記載のメモリコントローラ。 3. The memory controller according to claim 1, wherein a logical value of the dummy data matches a logical value of an erased state of the flash memory. 複数セクタのデータが記憶されるページを複数個含む物理ブロック単位で消去が行われるフラッシュメモリと、請求項1乃至3のいずれか1項に記載のメモリコントローラを備えることを特徴とするフラッシュメモリシステム。   A flash memory system comprising: a flash memory that is erased in units of physical blocks including a plurality of pages in which data of a plurality of sectors is stored; and a memory controller according to claim 1. . ホストシステムからの要求に応じて、複数セクタのデータが記憶されるページを複数個含む物理ブロック単位で消去が行われるフラッシュメモリに対するアクセスを制御するフラッシュメモリの制御方法であって、
前記ホストシステム側から供給される1セクタ単位のユーザデータを保持するデータ保持工程と、
前記データ保持工程で保持される前記ユーザデータを先頭データから順番に前記フラッシュメモリに転送するユーザデータ転送工程と、
前記ユーザデータ転送工程により前記フラッシュメモリに転送される前記ユーザデータに対応する誤り訂正符号を含む付加データを前記フラッシュメモリに転送する付加データ転送工程と、
予め設定されたダミーデータを前記フラッシュメモリに転送するダミーデータ転送工程とを有し、
前記ユーザデータ転送工程、前記付加データ転送工程及び前記ダミーデータ転送工程は択一的に実行され、
前記ダミーデータ転送工程は、前記フラッシュメモリに転送されるデータの書き込み先がブロックステータスの記憶領域に対応するときにだけ実行され、
前記ユーザデータと該ユーザデータに対応する前記付加データは、前記ページ内の連続した領域に書き込まれることを特徴とするフラッシュメモリの制御方法。
In accordance with a request from a host system, a flash memory control method for controlling access to a flash memory that is erased in units of physical blocks including a plurality of pages in which data of a plurality of sectors is stored,
A data holding step for holding user data in units of one sector supplied from the host system side;
A user data transfer step of transferring the user data held in the data holding step to the flash memory in order from the top data;
An additional data transfer step of transferring additional data including an error correction code corresponding to the user data transferred to the flash memory by the user data transfer step to the flash memory;
A dummy data transfer step of transferring preset dummy data to the flash memory,
The user data transfer step, the additional data transfer step and the dummy data transfer step are alternatively executed,
The dummy data transfer step is executed only when a write destination of data transferred to the flash memory corresponds to a block status storage area,
The flash memory control method, wherein the user data and the additional data corresponding to the user data are written in a continuous area in the page.
前記ユーザデータ転送工程、前記付加データ転送工程及び前記ダミーデータ転送工程が、一定の周期でカウントアップされるカウンタのカウント値に基づいて、択一的に実行されることを特徴とする請求項5に記載のフラッシュメモリの制御方法。 6. The user data transfer step, the additional data transfer step, and the dummy data transfer step are alternatively executed based on a count value of a counter that is counted up at a constant period. The control method of the flash memory as described in 2.
JP2007075932A 2007-03-23 2007-03-23 MEMORY CONTROLLER, FLASH MEMORY SYSTEM HAVING MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD Expired - Fee Related JP4640366B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007075932A JP4640366B2 (en) 2007-03-23 2007-03-23 MEMORY CONTROLLER, FLASH MEMORY SYSTEM HAVING MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007075932A JP4640366B2 (en) 2007-03-23 2007-03-23 MEMORY CONTROLLER, FLASH MEMORY SYSTEM HAVING MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD

Publications (2)

Publication Number Publication Date
JP2008234514A true JP2008234514A (en) 2008-10-02
JP4640366B2 JP4640366B2 (en) 2011-03-02

Family

ID=39907182

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007075932A Expired - Fee Related JP4640366B2 (en) 2007-03-23 2007-03-23 MEMORY CONTROLLER, FLASH MEMORY SYSTEM HAVING MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD

Country Status (1)

Country Link
JP (1) JP4640366B2 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011018222A (en) * 2009-07-09 2011-01-27 Toshiba Corp Device and method for interleave control and memory system
JP2013050938A (en) * 2011-08-01 2013-03-14 Toshiba Corp Memory device

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2003216483A (en) * 2002-01-21 2003-07-31 Fujitsu Ltd Memory controller and memory system unit
JP2004342126A (en) * 1998-02-25 2004-12-02 Lexar Media Inc Increasing memory performance in flash memory device by simultaneously writing sectors to multiple devices
JP2005251219A (en) * 1997-03-31 2005-09-15 Lexar Media Inc Moving sector in block in flash memory
JP2006004367A (en) * 2004-06-21 2006-01-05 Toshiba Corp Memory card and semiconductor device
JP2006079434A (en) * 2004-09-10 2006-03-23 Tokyo Electron Device Ltd Storage device, memory management method and program

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005251219A (en) * 1997-03-31 2005-09-15 Lexar Media Inc Moving sector in block in flash memory
JP2004342126A (en) * 1998-02-25 2004-12-02 Lexar Media Inc Increasing memory performance in flash memory device by simultaneously writing sectors to multiple devices
JP2003216483A (en) * 2002-01-21 2003-07-31 Fujitsu Ltd Memory controller and memory system unit
JP2006004367A (en) * 2004-06-21 2006-01-05 Toshiba Corp Memory card and semiconductor device
JP2006079434A (en) * 2004-09-10 2006-03-23 Tokyo Electron Device Ltd Storage device, memory management method and program

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011018222A (en) * 2009-07-09 2011-01-27 Toshiba Corp Device and method for interleave control and memory system
JP4643729B2 (en) * 2009-07-09 2011-03-02 株式会社東芝 Interleave control device, interleave control method, and memory system
US8145858B2 (en) 2009-07-09 2012-03-27 Kabushiki Kaisha Toshiba Interleave control device, interleave control method, and memory system
JP2013050938A (en) * 2011-08-01 2013-03-14 Toshiba Corp Memory device
US9183143B2 (en) 2011-08-01 2015-11-10 Kabushiki Kaisha Toshiba Memory device that specifies a size of a segment of write data

Also Published As

Publication number Publication date
JP4640366B2 (en) 2011-03-02

Similar Documents

Publication Publication Date Title
US10049005B2 (en) Flash memory control apparatus utilizing buffer to temporarily storing valid data stored in storage plane, and control system and control method thereof
EP1769331B1 (en) Storage device and host apparatus
KR101425957B1 (en) Ecc control circuit and multi channel memory system icluding the same
US6434658B1 (en) Memory device operable with a small-capacity buffer memory and having a flash memory
US8904086B2 (en) Flash memory storage system and controller and data writing method thereof
US8510502B2 (en) Data writing method, and memory controller and memory storage apparatus using the same
JP4171749B2 (en) Memory controller and flash memory system
US9176865B2 (en) Data writing method, memory controller, and memory storage device
JP2005196764A (en) Flash memory system capable of inputting/outputting sector-by-sector data at random
US9177656B2 (en) Data writing method, memory storage device and memory controlling circuit unit
US20150161042A1 (en) Memory management method, memory controlling circuit unit, and memory storage device
US20130332653A1 (en) Memory management method, and memory controller and memory storage device using the same
JP4254932B2 (en) Memory controller and flash memory system
EP3057100B1 (en) Memory device and operating method of same
JP4640366B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM HAVING MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
US9146861B2 (en) Memory address management method, memory controller and memory storage device
US20180335942A1 (en) Data reading method, memory control circuit unit and memory storage device
US8423819B2 (en) Data storage device, controller, and data access method for a downgrade memory
JP4849637B2 (en) Memory card and memory controller
US9710374B2 (en) Data writing method, memory controller and memory storage device
JP4641338B2 (en) Nonvolatile semiconductor memory device and system
JP4655034B2 (en) Memory controller, flash memory system, and flash memory control method
JP4241741B2 (en) Memory controller and flash memory system
JP4697146B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM HAVING MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
JP4273106B2 (en) Memory controller, flash memory system, and flash memory control method

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20101025

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20101102

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20101115

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

Ref document number: 4640366

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20131210

Year of fee payment: 3

LAPS Cancellation because of no payment of annual fees