JP5200688B2 - COUNT DATA RECORDING DEVICE AND COUNT DATA RECORDING METHOD - Google Patents

COUNT DATA RECORDING DEVICE AND COUNT DATA RECORDING METHOD Download PDF

Info

Publication number
JP5200688B2
JP5200688B2 JP2008160756A JP2008160756A JP5200688B2 JP 5200688 B2 JP5200688 B2 JP 5200688B2 JP 2008160756 A JP2008160756 A JP 2008160756A JP 2008160756 A JP2008160756 A JP 2008160756A JP 5200688 B2 JP5200688 B2 JP 5200688B2
Authority
JP
Japan
Prior art keywords
count data
data
address
value
count
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2008160756A
Other languages
Japanese (ja)
Other versions
JP2010003074A (en
Inventor
整 脇出
好彦 吉崎
豪郎 前
靖文 内藤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Konica Minolta Business Technologies Inc
Original Assignee
Konica Minolta Business Technologies Inc
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 Konica Minolta Business Technologies Inc filed Critical Konica Minolta Business Technologies Inc
Priority to JP2008160756A priority Critical patent/JP5200688B2/en
Publication of JP2010003074A publication Critical patent/JP2010003074A/en
Application granted granted Critical
Publication of JP5200688B2 publication Critical patent/JP5200688B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

本発明は、メモリ等で構成される記憶領域へカウントデータを記録する装置、および、カウントデータ記録方法に関し、特に、該記憶領域に記録されたカウントデータにおいて生じた破損を検出し、当該検出にかかる破損したカウントデータを正常な状態へ修復するカウントデータ記録装置、および、記録方法に関する。   The present invention relates to an apparatus and a count data recording method for recording count data in a storage area composed of a memory or the like, and more particularly, to detect damage that has occurred in count data recorded in the storage area and to detect the damage. The present invention relates to a count data recording apparatus and a recording method for restoring such damaged count data to a normal state.

従来、データの記録および保持には、メモリが利用される。特に、長期にわたって、データをメモリ内に保持する用途には、不揮発性メモリが用いられる。ここで、不揮発性メモリとは、電源を供給しなくても記憶を保持するメモリの総称である。   Conventionally, a memory is used for recording and holding data. In particular, a nonvolatile memory is used for a purpose of holding data in the memory for a long period of time. Here, the non-volatile memory is a general term for memories that retain memory even when power is not supplied.

しかしながら、不揮発性メモリ(例えば、EEPROM(Electrically Erasable and Programmable Read Only Memory))は、一般に、データの書き込みに関する繰り返し耐性が小さい。例えば、不揮発性メモリの書き込み繰り返し耐性は、その種類によって様々だが、例えば、100万回程度である。   However, a non-volatile memory (for example, EEPROM (Electrically Erasable and Programmable Read Only Memory)) generally has low repetition resistance regarding data writing. For example, the repeated write endurance of the non-volatile memory varies depending on the type, but is, for example, about 1 million times.

特許文献1は、上記のような、書き込み繰り返し耐性が比較的小さいメモリへデータを書き込む方法、および、その装置を開示する。当該特許文献1においては、メモリのメモリアドレスを3つまとめて1組とし、当該1組を構成するメモリアドレスA、B、および、Cに対し、データの書き込みを循環的に、つまり、A→B→C→A→B→・・・、のように、実行することで、メモリの書き込み繰り返し耐性を超えた回数のデータ書き込みを可能とする。特許文献1の方法においては、上記循環的なデータの書き込みにおける「循環」を管理するため、各メモリアドレスについて、実データ部へのデータの書き込みが行われる毎に所定値が書き込まれるアクセス情報部が、実データを記録する実データ部と別に、設けられる。そして、特許文献1の方法においては、アクセス情報部に書き込まれた情報にもとづいて、次に、データが書き込まれるべきメモリアドレスが決定される。そうすることで、特許文献1は、メモリに対し、その書き込み繰り返し耐性を超えた回数のデータ書き込みを可能にする。   Patent Document 1 discloses a method and an apparatus for writing data into a memory having relatively low write repetition resistance as described above. In Patent Document 1, three memory addresses of a memory are grouped into one set, and data writing is cyclically performed on memory addresses A, B, and C constituting the set, that is, A → By executing as B → C → A → B →..., Data can be written a number of times that exceeds the memory write repetition resistance. In the method of Patent Document 1, in order to manage the “circulation” in the cyclic data writing, an access information section in which a predetermined value is written for each memory address every time data is written to the actual data section. Is provided separately from the actual data part for recording actual data. In the method of Patent Document 1, the memory address to which data is next written is determined based on the information written in the access information section. By doing so, Patent Document 1 enables data to be written to the memory a number of times that exceeds the write repetition resistance.

特許文献1が開示する発明は、当該発明が適用されるメモリに書き込まれるデータの内容について、特に、規定したり、あるいは、限定したりはしない。   The invention disclosed in Patent Document 1 does not particularly define or limit the contents of data written to a memory to which the invention is applied.

従来、特定のデータのみを記録する用途にメモリが用いられることもある。このような特定のデータの例としては、カウントデータがある。カウントデータとは、特定の値から所定値ずつインクリメントされて記録されることによって、何らかの回数をカウントするために用いられるデータである。(上記所定値が負の数であれば、カウントデータは、上記特定の値からデクリメントされつつ、順次、記録されるデータである。)カウントデータは、例えば、特定のデバイス(例えば、画像処理装置の感光体ユニット)が動作した回数を記録する用途に用いられる。   Conventionally, a memory is sometimes used for recording only specific data. An example of such specific data is count data. The count data is data used to count a certain number of times by being recorded by being incremented by a predetermined value from a specific value. (If the predetermined value is a negative number, the count data is data that is sequentially recorded while being decremented from the specific value.) The count data is, for example, a specific device (for example, an image processing apparatus). The photoconductor unit) is used for recording the number of operations.

このようなカウントデータを、書き込み繰り返し耐性が比較的小さいメモリに記録する場合には、以下に記すようにしてカウントデータをメモリへ記録し、また、データが破壊されたときにはその修復を行っている。   When such count data is recorded in a memory having a relatively low write repetition resistance, the count data is recorded in the memory as described below, and is repaired when the data is destroyed. .

例えば、メモリの1つのアドレスに対する書き込み繰り返し耐性が100万回であるメモリを用いて、300万回のカウントデータの書き込みを行う場合、3つのアドレスを用いて、3つのアドレスに対し、順次的に、カウントデータの書き込みを行う。カウントデータは、所定値ずつ増加(あるいは減少)するため、上記3つのアドレスには、所定値ずつ増加(あるいは減少)する3つの値が、記録される。   For example, when writing 3 million times of count data using a memory having a write repetition resistance of 1 million times with respect to one address of the memory, using three addresses, sequentially with respect to the three addresses. Write count data. Since the count data increases (or decreases) by a predetermined value, three values that increase (or decrease) by a predetermined value are recorded at the three addresses.

カウントデータには、所定値ずつ増加(あるいは減少)するという性質が備わっているため、記録されたカウントデータが破壊された場合であっても、破壊されていないカウントデータの値を用いて、当該値に所定値あるいは所定値の2倍の値を加算(あるいは減算)して得られる値を、破壊されたアドレスに書き込むことで、破壊されたカウントデータを修復することができる。   Since the count data has the property of increasing (or decreasing) by a predetermined value, even if the recorded count data is destroyed, the count data value that is not destroyed is used. By writing a value obtained by adding (or subtracting) a predetermined value or a value twice the predetermined value to the value to the destroyed address, the destroyed count data can be restored.

このように、メモリの1つのアドレスに対する書き込み繰り返し耐性が100万回であるメモリを用いる場合、3つのアドレスを用いることで300万回のカウントデータの書き込み、および、その修復が可能である。   As described above, when using a memory having a write repetition resistance of 1 million times with respect to one address of the memory, the count data can be written and repaired 3 million times by using three addresses.

上記例と少し異なり、メモリの1つのアドレスに対する書き込み繰り返し耐性が100万回であるメモリを用いて、350万回のカウントデータの書き込みを行う用途の場合、次のようにして、350万回のカウントデータの記録を実現している。   A little different from the above example, in the case of writing the count data of 3.5 million times using the memory having the write repetition resistance of 1 million times with respect to one address of the memory, the number of times of 3.5 million times is as follows. Count data recording is realized.

先ず、所定の回数(例えば、97万回)までは、先の別例と同様に、3つのアドレスに対し、順次的に、カウントデータの書き込みを行う。ここからは、先の別例とは異なり、上記3つのアドレスとは別の3つのアドレスに対し、順次的に、カウントデータの書き込みが開始される。   First, up to a predetermined number of times (for example, 970,000 times), the count data is sequentially written to the three addresses as in the other example. From here, unlike the other example described above, writing of count data is sequentially started to three addresses different from the above three addresses.

このような方法論によれば、350万回のカウントデータの書き込みを行うためには、カウントデータが書き込まれる6つのアドレスと、上記3つのアドレスそれぞれに対する書き込み回数を保持するための3つのアドレスと、上記3つのアドレス群および上記別の3つのアドレス群のいずれのアドレス群をカウントデータとして使用するかを示すデータが保持されるための1つのアドレスと、の総計10個のアドレスが必要になる。   According to such a methodology, in order to write count data for 3.5 million times, six addresses to which count data is written, three addresses for holding the number of times of writing for each of the three addresses, A total of ten addresses are required, one address for holding data indicating which of the three address groups and the other three address groups is used as count data.

理論上、350万回の書き込みがなされるカウントデータの記録は、100万回のデータ書き込みが可能なアドレスを4つ使えば足りる。にも拘わらず、上記従来例においては、10個のアドレスを用いて、カウントデータの記録(および破損されたカウントデータの修復)を行っていた。このことは、メモリの利用効率の観点から好ましいこととは言えない。
特開平10−247165号公報
Theoretically, the count data to be written 3.5 million times can be recorded by using four addresses that can be written 1 million times. Nevertheless, in the above conventional example, the count data is recorded (and the damaged count data is restored) using 10 addresses. This is not preferable from the viewpoint of memory utilization efficiency.
Japanese Patent Laid-Open No. 10-247165

上記従来の問題点を鑑み、本発明は、メモリの利用効率が向上され、かつ、破損を受けたカウントデータを修復できるカウントデータ記録装置を提供することを目的とする。   In view of the above-described conventional problems, an object of the present invention is to provide a count data recording apparatus capable of improving the use efficiency of a memory and repairing damaged count data.

本発明は、所定値から所定幅で単調に変化するカウント値をカウントデータとして記録装置に記録するカウントデータ記録装置であって、カウントデータを記憶する記憶部と、カウントデータを記憶部に書き込むデータ書込部と、カウントデータを記憶部から読み出すデータ読出部と、記憶部に記憶されたカウントデータの破損を検出し、該破損を修復するデータ修復部と、を有し、記憶部は、位置特定識別子によって特定され、カウントデータを記憶するカウントデータ記憶部を複数個と、カウントデータ記憶部のそれぞれと関連付けされ、第1値および第2値を示す2種類のデータから1つを択一的に記憶する極性情報データ記憶部をカウントデータ記憶部の個数と同数だけ備え、データ書込部は、複数個のカウントデータ記憶部のうちから所定の順序で循環的に1つのカウントデータ記憶部に対してカウントデータを書き込むカウントデータ書込部と、カウントデータ書込部がカウントデータを書き込んだカウントデータ記憶部と関連付けされた極性情報データ記憶部が記憶するデータの内容を、第1値と第2値との間で反転させる極性情報データ反転部と、を備え、データ修復部は、データ読出部が記憶部から読み出した、複数個のカウントデータ記憶部に記憶された複数のカウントデータについて、カウントデータの大きさで、カウントデータ記憶部の位置特定識別子を並べるカウントデータソート部と、カウントデータソート部が並べた位置特定識別子の順に沿って、互いに隣接するカウントデータ間の差分値を算出するカウントデータ差分算出部と、カウントデータソート部が並べた順に沿った位置特定識別子の並び方、カウントデータソート部が並べた順に沿ったカウントデータ間の差分値の並び方、および、カウントデータソート部が並べた順に沿った極性情報データの並び方、に基づいて、記憶部に記憶された複数のカウントデータの破損を検出して当該破損を修復する修復処理実行部と、を備える、カウントデータ記録装置である。   The present invention relates to a count data recording device that records a count value that changes monotonously from a predetermined value within a predetermined width as count data in a recording device, the storage unit storing count data, and the data that writes the count data to the storage unit A writing unit; a data reading unit that reads count data from the storage unit; and a data restoration unit that detects corruption of the count data stored in the storage unit and repairs the corruption. A plurality of count data storage units that are specified by the specific identifier and store count data are associated with each of the count data storage units, and one of two types of data indicating the first value and the second value is selected. There are as many polarity information data storage units as the number of count data storage units, and the data writing unit is a plurality of count data storage units. Count data writing unit that writes count data to one count data storage unit cyclically in a predetermined order, and polarity information data associated with the count data storage unit to which the count data writing unit has written the count data A polarity information data inverting unit for inverting the content of data stored in the storage unit between the first value and the second value, and the data restoration unit includes a plurality of data read units read from the storage unit by the data reading unit For the plurality of count data stored in the count data storage unit, the count data sorting unit that arranges the position specifying identifiers of the count data storage unit in the size of the count data, and the position specifying identifiers arranged by the count data sorting unit in this order A count data difference calculation unit that calculates a difference value between count data adjacent to each other, and count data Of the position identification identifiers in the order in which the count data are arranged, how to arrange the difference values between the count data in the order in which the count data sort unit is arranged, and the polarity information data in the order in which the count data sort unit is arranged A count data recording apparatus comprising: a repair processing execution unit that detects damage of a plurality of count data stored in a storage unit and repairs the damage based on the arrangement.

本発明においては、1つの位置特定識別子が特定するカウントデータ記憶部は、2つのメモリアドレスによって特定される2つの記憶領域を有し、カウントデータは、2つの記憶領域へ分割して記憶される、ことが好ましい。   In the present invention, the count data storage unit specified by one position specifying identifier has two storage areas specified by two memory addresses, and the count data is divided and stored in two storage areas. It is preferable.

本発明においては、所定値は、ゼロであり、所定幅は、プラス1である、ことが好ましい。   In the present invention, it is preferable that the predetermined value is zero and the predetermined width is plus one.

本発明においては、所定値は、ゼロを含まない自然数であり、所定幅は、マイナス1である、ことが好ましい。   In the present invention, it is preferable that the predetermined value is a natural number not including zero and the predetermined width is minus one.

本発明においては、カウントデータソート部は、カウントデータの大きさの降順で、カウントデータ記憶部の位置特定識別子を並べる、ことが好ましい。   In the present invention, the count data sorting unit preferably arranges the position identification identifiers of the count data storage unit in descending order of the size of the count data.

本発明においては、カウントデータソート部は、カウントデータの大きさの昇順で、カウントデータ記憶部の位置特定識別子を並べる、ことが好ましい。   In the present invention, the count data sorting unit preferably arranges the position identification identifiers of the count data storage unit in ascending order of the count data size.

本発明においては、修復処理実行部は、カウントデータソート部が並べた順に沿って並べた極性情報データにおいて、極性情報データの値が変化する箇所の数を求め、求めた変化する箇所の数に基づいて、記憶部に記憶された複数のカウントデータの破損を検出して当該破損を修復する、ことが好ましい。   In the present invention, the restoration processing execution unit obtains the number of locations where the value of the polarity information data changes in the polarity information data arranged in the order arranged by the count data sorting unit, and determines the number of the obtained changed portions. Based on this, it is preferable to detect the damage of a plurality of count data stored in the storage unit and repair the damage.

本発明によるカウントデータ記録装置およびカウントデータ記録方法は、メモリの利用効率に優れ、かつ、記録されたカウントデータが破損を受けた場合には、当該破損を修復し、正確なカウントデータに戻すことが可能である。   The count data recording apparatus and the count data recording method according to the present invention are excellent in memory utilization efficiency, and when the recorded count data is damaged, the damage is repaired and returned to accurate count data. Is possible.

本発明にかかるカウントデータ記録装置は、記憶装置の書き込み繰り返し耐性を超えてカウントデータを記録することが可能である。   The count data recording device according to the present invention is capable of recording count data exceeding the write repetition resistance of the storage device.

また、本発明にかかるカウントデータ記録装置は、カウントデータの破損を検出し、検出した破損を修復することが可能である。   In addition, the count data recording apparatus according to the present invention is capable of detecting breakage of count data and repairing the detected breakage.

<カウントデータ記録装置の構成>
図1は、本発明にかかる実施の形態によるカウントデータ記録装置を示す斜視図である。本実施の形態においては、カウントデータ記録装置は、デジタル複合機(MFP)1である。MFP1は、所謂、画像形成装置であり、画像形成のためにトナーカートリッジ3、および、感光体ユニット5を、内部に備える。
<Configuration of count data recording device>
FIG. 1 is a perspective view showing a count data recording apparatus according to an embodiment of the present invention. In the present embodiment, the count data recording apparatus is a digital multi-function peripheral (MFP) 1. The MFP 1 is a so-called image forming apparatus, and includes a toner cartridge 3 and a photoreceptor unit 5 for image formation.

図2は、感光体ユニット5の斜視図である。感光体ユニット5は、その使用回数をカウントするカウントデータを記録するための記憶装置7を備える。記憶装置7は、データ書き込みについて、記憶領域に繰り返し書き込むことができる回数が規定されており、規定された繰り返し回数を超えて、データを書き込むことは、データ記録の安定性を損なう。   FIG. 2 is a perspective view of the photoconductor unit 5. The photoconductor unit 5 includes a storage device 7 for recording count data for counting the number of times of use. In the storage device 7, the number of times data can be repeatedly written to the storage area is specified, and writing data beyond the specified number of repetitions impairs data recording stability.

図3は、本発明にかかる実施の形態によるカウントデータ記録装置であるMFP1のハードウェア構成を示すブロック図である。MFP1は、データ処理や装置全体の動作の制御をする中央処理装置(CPU)11、プログラムやデータを保持するランダム・アクセス・メモリ(RAM)13、プログラムやデータを保持するリード・オンリ・メモリ(ROM)15を備え、これらはデータバスにより接続され、MFP1内においてコンピュータを構成する。当該コンピュータは、カウントデータ記録用プログラムを実行することにより、カウントデータ記録装置として機能する。   FIG. 3 is a block diagram showing a hardware configuration of MFP 1 which is a count data recording apparatus according to the embodiment of the present invention. The MFP 1 includes a central processing unit (CPU) 11 that controls data processing and overall operation of the apparatus, a random access memory (RAM) 13 that stores programs and data, and a read-only memory (that stores programs and data). ROM) 15, which are connected by a data bus and constitute a computer in the MFP 1. The computer functions as a count data recording device by executing a count data recording program.

また、MFP1のコンピュータ21は、カウントデータを記録するための記憶装置7、各種デバイスとのデータ送受信をするためのI/OLSI17と接続される。I/OLSI17を介し、コンピュータ21は、出力デバイス19および入力デバイス21と接続される。   The computer 21 of the MFP 1 is connected to a storage device 7 for recording count data and an I / O LSI 17 for transmitting / receiving data to / from various devices. The computer 21 is connected to the output device 19 and the input device 21 via the I / O LSI 17.

図4は、本発明の実施の形態によるカウントデータ記録装置にかかる機能を実現するためにMFP1が備える機能を表すブロック図である。コンピュータ21は、カウントデータ記録用プログラムを実行することにより、本図に示される機能を実現する。   FIG. 4 is a block diagram showing functions provided in MFP 1 for realizing the functions of the count data recording apparatus according to the embodiment of the present invention. The computer 21 implements the functions shown in the figure by executing a count data recording program.

コンピュータ21は、各機能ブロックを制御する制御部23、記憶装置7に対しデータを所定のアドレスに書き込むデータ書込部25、記憶装置7に記録されているカウントデータ等の破損を検出し、当該破損を修復するデータ修復部27、記憶装置7から所定のアドレスに記録されたデータを読み出すデータ読出部29、および、カウントデータ記録用プログラムの実行に必要な設定データを保持する設定データ保持部31を実現する。   The computer 21 detects damage to the control unit 23 that controls each functional block, the data writing unit 25 that writes data to the storage device 7 at a predetermined address, the count data recorded in the storage device 7, and the like. A data restoration unit 27 for repairing the damage, a data reading unit 29 for reading data recorded at a predetermined address from the storage device 7, and a setting data holding unit 31 for holding setting data necessary for executing the count data recording program To realize.

データ書込部25は、記憶装置7の所定のアドレスを有する記憶領域に、所定の形式でカウントデータを記録するカウントデータ書込部25a、および、記憶装置7の所定のアドレスを有する記憶領域に、所定の形式で極性情報データを記録する極性情報データ反転部25bを備える。   The data writing unit 25 has a count data writing unit 25a for recording count data in a predetermined format in a storage area having a predetermined address of the storage device 7, and a storage area having a predetermined address of the storage device 7. The polarity information data reversing unit 25b for recording the polarity information data in a predetermined format is provided.

カウントデータは、カウントデータ書込部25aによって、記憶装置7の、複数のアドレスで指定される複数の記憶領域を用いて、循環的に記録される。例えば、カウントデータは、アドレス[A]、アドレス[B]、アドレス[C]、アドレス[D]、アドレス[E]の5つのアドレスで指定される記憶領域を循環するようにして、記録される。アドレス[A]にカウントデータが記録された次の記録においては、アドレス[B]に対しカウントデータの記録が行われる。このようにして、順にアドレス[E]まで使用されると、次は、アドレス[A]にカウントデータが記録される。以下同様にして、所定数(N個)のアドレスについて、循環的に、カウントデータの記録が行われる。ここで、Nは、任意の自然数である。本発明は、Nの値について特に限定しない。但、繰り返し書き込み可能な回数がR[回](自然数)である記憶装置において、数Cminから数Cmaxまで、インクリメント幅S(負数Sは、そのSの絶対値がデクリメント幅を表す。)でカウントデータを記録する場合、少なくとも、(Cmax−Cmin+1)/S/R以上の自然数だけアドレスが必要である。記憶装置7の記憶領域の効率的使用の観点からは、(Cmax−Cmin+1)/S/R以上の最小の自然数が最も有利である。なお、1つのカウントデータが、1つのアドレスによって指定される記憶領域に記録できない場合、1つのカウントデータの記録に複数のアドレスを使用する必要が生じるが、その場合に最低限必要な、アドレスの数(N)については、当業者にとって明らかであろう。   The count data is cyclically recorded by the count data writing unit 25a using a plurality of storage areas specified by a plurality of addresses in the storage device 7. For example, the count data is recorded so as to circulate through the storage areas designated by the five addresses of address [A], address [B], address [C], address [D], and address [E]. . In the next recording in which the count data is recorded at the address [A], the count data is recorded at the address [B]. In this manner, when the address [E] is used in order, the count data is recorded at the address [A]. In the same manner, count data is recorded cyclically for a predetermined number (N) of addresses. Here, N is an arbitrary natural number. The present invention does not specifically limit the value of N. However, in a storage device in which the number of repetitive writings is R [times] (natural number), the number is incremented from a number Cmin to a number Cmax by an increment width S (the negative value S indicates the decrement width). When data is recorded, at least as many natural addresses as (Cmax−Cmin + 1) / S / R or more are required. From the viewpoint of efficient use of the storage area of the storage device 7, the smallest natural number equal to or greater than (Cmax−Cmin + 1) / S / R is most advantageous. If one count data cannot be recorded in the storage area specified by one address, it is necessary to use a plurality of addresses for recording one count data. The number (N) will be apparent to those skilled in the art.

極性情報データとは、カウントデータが記録されるアドレスと関連付けられ、カウントデータの破損および修復に用いられるデータである。極性情報データとカウントデータの関連付けは、設定データ保持部31に保持されればよい。この、極性情報データは、第1値および第2値(例えば「1」および「0」。)の2種類の値を取り得るデータであり、通常の、(つまり、データ破損の修復でない、)カウントデータの書き込みにおいて、極性情報データ反転部25bによって、当該書き込みがなされたアドレスと関連付けられた極性情報データが、第1値と第2値との間で、書き込み直前の値から反転するように変更されて記録される。1つの極性情報データは、1ビットの記憶領域に記録できる大きさにすることができる。極性情報データは、例えば、カウントデータが記録されるアドレスの記憶領域と同一の記憶領域の先頭Pビット(Pは1以上の整数。)を用いて記録すればよい。また、極性情報データは、カウントデータが記録されるアドレスの記憶領域とは別の記憶領域を用いて記録してもよい。但、カウントデータの記録と同一のアドレス内に極性情報データを記録するほうが、メモリ使用効率の観点から有利である。   The polarity information data is data that is associated with an address at which the count data is recorded and is used for damage and restoration of the count data. The association between the polarity information data and the count data may be held in the setting data holding unit 31. The polarity information data is data that can take two types of values, a first value and a second value (eg, “1” and “0”), and is normal (that is, not repairing data corruption). In writing the count data, the polarity information data reversing unit 25b reverses the polarity information data associated with the written address from the value immediately before the writing between the first value and the second value. Changed and recorded. One polarity information data can be sized to be recorded in a 1-bit storage area. The polarity information data may be recorded using, for example, the first P bit (P is an integer of 1 or more) in the same storage area as the storage area of the address where the count data is recorded. The polarity information data may be recorded using a storage area different from the storage area of the address where the count data is recorded. However, it is more advantageous from the viewpoint of memory usage efficiency to record the polarity information data in the same address as the count data.

データ修復部27は、データ読出部29が読み出した複数の所定のアドレスに記録されたカウントデータを所定の規則(降順または昇順)で並べ替え、並べ替えた結果を出力するカウントデータソート部27a、カウントデータソート部27aが並べ替えた複数のカウントデータについて互いに隣接するカウントデータ間の差分を算出するカウントデータ差分算出部27b、ならびに、カウントデータソート部27aがしたカウントデータの並べ替え、カウントデータ差分算出部27bが算出したカウントデータ差分値、および、各カウントデータ(のアドレス)と関連付けされた極性情報データに基づいて、カウントデータの破損を検出し検出された破損を修復する修復処理実行部27cを備える。   The data restoration unit 27 rearranges count data recorded at a plurality of predetermined addresses read by the data reading unit 29 according to a predetermined rule (descending order or ascending order), and outputs a result of the rearrangement. A count data difference calculation unit 27b that calculates a difference between adjacent count data for a plurality of count data rearranged by the count data sort unit 27a, and a count data rearrangement and a count data difference performed by the count data sort unit 27a Based on the count data difference value calculated by the calculation unit 27b and the polarity information data associated with each count data (address thereof), a repair processing execution unit 27c that detects the corruption of the count data and repairs the detected corruption. Is provided.

修復処理実行部27cは、データ破損の検出のための処理、および、検出されたデータ破損の修復のための処理、を実行する。   The repair processing execution unit 27c executes processing for detecting data corruption and processing for repairing detected data corruption.

データ破損の検出処理は、上記並べ替えされたカウントデータの並び方とそれらに関連付けられた極性情報データの並び方とそれらの上記カウントデータ差分値の並び方との組み合わせを、正常な(データ破損が含まれない)カウントデータを上記並べ替えした場合に起こり得る、カウントデータの並び方とそれらと関連付けられた極性情報データの並び方とデータ差分値の並び方との組み合わせと比較することで、データ破損の生じているカウントデータおよびそれと関連付けられた極性情報データを特定する。上記正常なカウントデータについて起こり得る組み合わせは、データ破損の検出処理を実行する前に、予め求めておき、装置に保持されている。上記起こり得る組み合わせの数は、カウントデータの記録に用いるアドレスの数によって変化するが、用いるアドレスの数によらず有限である。   In the data corruption detection process, a combination of the arrangement of the sorted count data, the arrangement of the polarity information data associated therewith, and the arrangement of the count data difference values is normal (including data corruption). No) Data corruption has occurred by comparing with the combination of the count data alignment method, the polarity information data alignment method and the data difference value alignment method, which can occur when the count data is rearranged as described above The count data and the polarity information data associated therewith are specified. The possible combinations of the normal count data are obtained in advance and held in the apparatus before executing the data corruption detection process. The number of possible combinations varies depending on the number of addresses used for recording count data, but is finite regardless of the number of addresses used.

データ破損の修復処理は、データ破損の検出処理が検出した破損を含むカウントデータについて、上記正常なカウントデータを上記並べ替えした場合に起こり得る、上記カウントデータと極性情報データとデータ差分値の並び方の組み合わせに基づいて、正常なカウントデータ値を求め、修復処理実行部27cがデータ修復の指示を出力し、当該指示にもとづいて、データ書込部25のカウントデータ書込部25aが、正常なカウントデータ値を該当する記憶領域に書き込むことによって行われる。このとき、当該修復にかかるカウントデータと関連付けられた極性情報データも修復の必要が有る場合、データ書込部25の極性情報データ反転部25bが、上記データ修復の指示に基づいて、修復されたカウントデータと関連付けられた極性情報データを反転させる。   The data corruption repair process is an arrangement of the count data, polarity information data, and data difference values that can occur when the normal count data is rearranged with respect to the count data including the damage detected by the data corruption detection process. Based on this combination, a normal count data value is obtained, and the repair processing execution unit 27c outputs a data repair instruction. Based on the instruction, the count data writing unit 25a of the data writing unit 25 This is done by writing the count data value to the corresponding storage area. At this time, if the polarity information data associated with the count data related to the restoration also needs to be restored, the polarity information data inversion unit 25b of the data writing unit 25 is restored based on the data restoration instruction. The polarity information data associated with the count data is inverted.

設定データ保持部31は、記憶装置7の、カウントデータを記録するために用意されている複数のアドレス、当該複数のアドレスに記録されるカウントデータそれぞれに関連付けて記録される極性情報データの記録されているアドレス、次回のカウントデータの記録においてカウントデータを記録するべきアドレス等を保持する。   The setting data holding unit 31 records a plurality of addresses prepared for recording count data in the storage device 7 and polarity information data recorded in association with the count data recorded at the plurality of addresses. The address to which the count data is to be recorded in the next count data recording.

<記憶装置7が保持するデータの構成>
図5は、記憶装置7において、1つのアドレスによって指定される記憶領域のデータ構成を示す図である。
<Configuration of data held in storage device 7>
FIG. 5 is a diagram illustrating a data configuration of a storage area designated by one address in the storage device 7.

アドレスとは、一般に、情報処理において、その処理の対象が存在する場所を規定する識別子である。本明細書においては、アドレスは、記憶装置7における記憶領域の位置の特定のために用いる識別子を含む。   In general, an address is an identifier that defines a place where a processing target exists in information processing. In the present specification, the address includes an identifier used for specifying the position of the storage area in the storage device 7.

1つのアドレス(アドレス[X])によって特定される記憶領域は、さらに極性情報データを保持する極性情報部33pと、カウントデータを保持するカウントデータ部33と、に区分される。   The storage area specified by one address (address [X]) is further divided into a polarity information section 33p that holds polarity information data and a count data section 33 that holds count data.

ここでは、1つのアドレスによって指定される記憶領域は、Mビット幅を有する。ここでMは、自然数である。本発明は、この自然数Mについて、特に限定しない。アドレス[X]によって指定される記憶領域は、極性情報データを記憶するための、Pビット幅を有する極性情報データ記憶部33pと、カウントデータを記憶するための、M−Pビット幅を有するカウントデータ記憶部33とで構成される。   Here, the storage area specified by one address has an M-bit width. Here, M is a natural number. In the present invention, the natural number M is not particularly limited. The storage area specified by the address [X] includes a polarity information data storage unit 33p having a P bit width for storing polarity information data, and a count having an MP bit width for storing count data. And a data storage unit 33.

なお、1つのカウントデータに関連付けて記憶される1つ極性情報データは、当該1つのカウントデータが記憶されるアドレスとは異なるアドレスに記憶されてもよい。   One polarity information data stored in association with one count data may be stored at an address different from an address at which the one count data is stored.

1つのアドレスによって特定される記憶位置の記憶容量が、1つのカウントデータを記憶するのに必要な記憶容量に満たない場合には、複数のアドレスによって特定される複数の記憶位置に、当該1つのカウントデータを分割して記憶すればよい。その場合、該複数の記憶位置に分割して記憶される1つのカウントデータに関連付けて1つの極性情報データを、任意のアドレスに記憶すればよい。このとき、該1つの極性情報データが記憶されるアドレスは、該極性情報データと関連付けられたカウントデータを記憶する複数の記憶位置のいずれかに含まれてよい。あるいは、該1つの極性情報データは、上記の複数の記憶位置とは別の記憶位置であってもよい。   If the storage capacity of the storage location specified by one address is less than the storage capacity necessary to store one count data, the one storage location specified by the plurality of addresses The count data may be divided and stored. In that case, one polarity information data may be stored at an arbitrary address in association with one count data that is divided and stored in the plurality of storage positions. At this time, the address at which the one polarity information data is stored may be included in any of a plurality of storage positions that store count data associated with the polarity information data. Alternatively, the one polarity information data may be a storage position different from the plurality of storage positions.

<カウントデータ記録動作>
図6は、本発明にかかる実施の形態によるカウントデータ記録装置(MFP1)がする、記憶装置7に対するカウントデータの記録の例を示す図である。
<Count data recording operation>
FIG. 6 is a diagram showing an example of count data recording to the storage device 7 by the count data recording apparatus (MFP 1) according to the embodiment of the present invention.

本例では、各カウントデータは、1つのアドレスが指定する記憶領域に記録される。各カウントデータと関連付けられた極性情報データは、カウントデータと同一のアドレスに記録される。また、本例では、カウントデータを記録するために設定されるアドレスは、5つに設定される。つまり、本例では、5つのアドレス([A]、[B]、[C]、[D]、[E])それぞれに、カウントデータと、極性情報データとが記録される。カウントデータの記録は、アドレスに関し、[A]→[B]→[C]→[D]→[E]→[A]→[B]→・・・の順に、循環的に行われる。   In this example, each count data is recorded in a storage area designated by one address. The polarity information data associated with each count data is recorded at the same address as the count data. In this example, five addresses are set for recording the count data. That is, in this example, count data and polarity information data are recorded in each of five addresses ([A], [B], [C], [D], [E]). Count data is cyclically recorded in the order of [A] → [B] → [C] → [D] → [E] → [A] → [B] →.

初期状態において、アドレス[A]、アドレス[B]、アドレス[C]、アドレス[D]、アドレス[E]、のカウントデータは、それぞれ、−4、−3、−2、−1、0である。これは、カウント値の開始値が1である場合の初期状態である。極性情報データは、全てのアドレスにおいて、0(第2値)である。初期状態において、極性情報データは、全てのアドレスにおいて、同一である必要がある。但、その値は、1(第1値)であってもかまわない。   In the initial state, the count data of address [A], address [B], address [C], address [D], and address [E] are −4, −3, −2, −1, and 0, respectively. is there. This is an initial state when the start value of the count value is 1. The polarity information data is 0 (second value) at all addresses. In the initial state, the polarity information data needs to be the same at all addresses. However, the value may be 1 (first value).

第1回目のカウントデータの書き込みは、アドレス[A]に対して行われる。カウント数「1」の行は、第1回目のカウントデータの書き込みが完了した時点の、各アドレスにおいて保持されるデータの値を示す。第1回目のカウントデータの書き込みにおいては、カウントデータ書込部25aが、アドレス[A]に、カウントデータ「1」を書き込み、極性情報データ反転部25bが、その極性情報データを反転させて「1」にする。   The first count data is written to the address [A]. The row of the count number “1” indicates the value of data held at each address when the first count data write is completed. In the first count data write, the count data writing unit 25a writes the count data “1” to the address [A], and the polarity information data inversion unit 25b inverts the polarity information data to “ 1 ”.

本例においては、以降、インクリメント幅「1」で、カウントデータの書き込みが行われる。   In this example, thereafter, the count data is written with the increment width “1”.

カウント数「5」が、アドレス[E]に対して書き込まれた次の書き込みでは、アドレス[A]にカウントデータ「6」が書き込まれ、極性情報データは、再度反転されることにより「0」に戻る。   In the next write in which the count number “5” is written to the address [E], the count data “6” is written to the address [A], and the polarity information data is inverted again to “0”. Return to.

以下同様にして、カウントデータは、5つのアドレスに対して、循環的に書き込まれて保持される。   Similarly, the count data is cyclically written and held for the five addresses.

<カウントデータ修復動作>
≪破損検出の原理≫
図7は、図6における各行(各カウント値)について、カウントデータの値の大きさで降順にアドレスを並べ替えたときのアドレスの並び方を示す図である。なお、インクリメント幅が負の数である場合、アドレスを、カウントデータの大きさの昇順に並べ替えることになる。いずれの場合も、破損検出の原理は、同一である。
<Count data restoration operation>
≪Principle of damage detection≫
FIG. 7 is a diagram illustrating how the addresses are arranged when the addresses are rearranged in descending order of the count data value for each row (each count value) in FIG. 6. When the increment width is a negative number, the addresses are rearranged in ascending order of the count data size. In any case, the principle of damage detection is the same.

例えば、カウント数「6」の場合を見れば、アドレスの並び方は、
[A]→[E]→[D]→[C]→[B]となり、その並び方において、
極性情報データの並び方は、
「0」→「1」→「1」→「1」→「1」となる。
For example, if the count number is “6”, the address arrangement is
[A] → [E] → [D] → [C] → [B].
How to arrange polarity information data
“0” → “1” → “1” → “1” → “1”.

また、例えば、カウント数「11」の場合を見れば、アドレスの並び方は、
[A]→[E]→[D]→[C]→[B]となるが、その並び方において、
極性情報データの並び方は、
「1」→「0」→「0」→「0」→「0」となる。
For example, if the count number is “11”, the address arrangement is
[A] → [E] → [D] → [C] → [B].
How to arrange polarity information data
“1” → “0” → “0” → “0” → “0”.

一般に、5つのアドレス([A][B][C][D][E])を用いてカウントデータを循環的に記録する場合、正常なカウントデータが記録されている状態でカウントデータの大きさの降順でアドレスを並び替えると、
[E]→[D]→[C]→[B]→[A]、
[A]→[E]→[D]→[C]→[B]、
[B]→[A]→[E]→[D]→[C]、
[C]→[B]→[A]→[E]→[D]、
[D]→[C]→[B]→[A]→[E]、の5通りが、カウント値順に現れる。
In general, when count data is cyclically recorded using five addresses ([A] [B] [C] [D] [E]), the size of the count data is large while normal count data is recorded. If you sort the addresses in descending order,
[E] → [D] → [C] → [B] → [A]
[A] → [E] → [D] → [C] → [B]
[B] → [A] → [E] → [D] → [C]
[C] → [B] → [A] → [E] → [D]
[D] → [C] → [B] → [A] → [E] appear in order of the count value.

各並び方について、極性情報データの並び方は、2通り現れる。
例えば、
[B]→[A]→[E]→[D]→[C]の順にアドレスが並ぶときは(例えば、カウント値「12」やカウント値「17」のときは)、極性情報データの並び方は、
「1」→「1」→「0」→「0」→「0」、または、
「0」→「0」→「1」→「1」→「1」、の2通りが交代的に現れる。
For each arrangement, two types of arrangement of polarity information data appear.
For example,
When the addresses are arranged in the order of [B] → [A] → [E] → [D] → [C] (for example, when the count value is “12” or the count value “17”), how to arrange the polarity information data Is
"1"->"1"->"0"->"0"->"0" or
Two patterns of “0” → “0” → “1” → “1” → “1” appear alternately.

ここでは、アドレスの並び方[B]→[A]→[E]→[D]→[C]について例示したが、他の並び方についても同様のことがいえる。   Here, the address arrangement method [B] → [A] → [E] → [D] → [C] is illustrated, but the same can be said for other arrangement methods.

つまり、アドレスをN個用いて、循環的にカウントデータを書き込むと、正常なカウントデータが記録されている状況では、カウントデータの大きさでアドレスを並び替えた場合、アドレスの並び方は、N通り存在する。そして、各アドレスの並び方について、極性情報データの並び方は、常に、2通り存在するから、正常なカウントデータが記録されている状況では、アドレスの並び方と極性情報データの並び方との組み合わせは、2×N通り存在する。   In other words, when count data is written cyclically using N addresses, in a situation where normal count data is recorded, when the addresses are rearranged according to the size of the count data, there are N ways to arrange the addresses. Exists. Since there are always two types of arrangement of the polarity information data with respect to the arrangement of each address, in the situation where normal count data is recorded, the combination of the arrangement of the address and the arrangement of the polarity information data is 2 × N ways exist.

次に、図8を参照し、アドレスをカウントデータの降順に並べ替えたときに隣接するアドレスに記録されたカウントデータ間の差分値について考察する。   Next, a difference value between count data recorded at adjacent addresses when addresses are rearranged in descending order of the count data will be considered with reference to FIG.

図8は、正常なカウントデータが記録されている状況における、アドレスをカウントデータの降順に並べ替えたときに隣接するアドレスに記録されたカウントデータ間の差分値を示す図である。このように、正常なカウントデータが記録され続ける限り、アドレスをカウントデータの降順に並べ替えたときに隣接するアドレスに記録されたカウントデータ間の差分値は、全て、常に、インクリメント幅(本例における「1」)と一致する。   FIG. 8 is a diagram illustrating a difference value between count data recorded at adjacent addresses when addresses are rearranged in descending order of the count data in a situation where normal count data is recorded. As described above, as long as normal count data continues to be recorded, the difference values between the count data recorded in the adjacent addresses when the addresses are rearranged in descending order of the count data are always increment widths (this example "1") in the above.

図9は、アドレスをカウントデータの降順で並べ替えた時に起こり得るアドレスの並び方の一覧である。このように、起こり得る、アドレスの並び方は、5通り(N通り)である。   FIG. 9 is a list of address arrangements that can occur when the addresses are rearranged in descending order of the count data. As described above, there are five possible ways of arranging addresses (N ways).

図10は、アドレスをカウントデータの降順で並べ替えた時に起こり得る、各アドレスと関連付けられた極性情報データの並び方の一覧である。このように、起こり得る、極性情報データの並び方は、10通り(2×N通り)である。   FIG. 10 is a list of how to arrange the polarity information data associated with each address that can occur when the addresses are rearranged in descending order of the count data. Thus, there are 10 possible ways of arranging the polarity information data (2 × N).

また、アドレスの並び方(図9)と、極性情報データの並び方(図10)とは、相互に関連して現れる。   Further, the arrangement of addresses (FIG. 9) and the arrangement of polarity information data (FIG. 10) appear in relation to each other.

図11は、アドレスの並び方(「アドレス組み合わせ」)と、その並び方において起こり得る極性情報の並び方(「極性情報組み合わせ」)についてまとめた表である。このように、起こり得る『「アドレス組み合わせ」と「極性情報組み合わせ」との組み合わせ』は、2×N通り存在する。   FIG. 11 is a table summarizing the arrangement of addresses (“address combinations”) and the arrangement of polarity information that can occur in the arrangement (“polarity information combinations”). In this way, there are 2 × N possible combinations of “address combinations” and “polarity information combinations”.

≪破損検出処理および破損修復処理の流れ≫
これより、図12、図13、図14AおよびB、図15AおよびB、図16AおよびB、図17AおよびB、図18AおよびBを参照し、破損検出処理および破損修復処理について説明する。
図12は、カウントデータ破損の検出および修復のメインフローのフローチャートである。
図13は、図12においてステップS201としたカウントデータ修復処理選択処理のフローチャートである。
図14AおよびBないし図18AおよびBは、それぞれ、図13において、ステップS301a、ステップS301b、ステップS301c、ステップS301d、ステップS301e、とした、カウントデータ修復処理A、カウントデータ修復処理B、カウントデータ修復処理C、カウントデータ修復処理D、カウントデータ修復処理E、のフローチャートである。
≪Flow of damage detection processing and damage repair processing≫
With reference to FIGS. 12, 13, 14A and B, FIGS. 15A and B, FIGS. 16A and B, FIGS. 17A and B, and FIGS. 18A and B, the damage detection process and the damage repair process will be described.
FIG. 12 is a flowchart of the main flow of detection and repair of count data corruption.
FIG. 13 is a flowchart of the count data restoration process selection process in step S201 in FIG.
FIGS. 14A and B to FIGS. 18A and 18B are respectively a count data restoration process A, a count data restoration process B, and a count data restoration, which are step S301a, step S301b, step S301c, step S301d, and step S301e in FIG. 10 is a flowchart of a process C, a count data repair process D, and a count data repair process E.

先ず、図12を参照する。   First, referring to FIG.

ステップS101において、カウントデータ記録装置(MFP1)のカウントデータソート部27aは、アドレスを、各アドレスに記録されているカウントデータの値の降順に、並び替えする。   In step S101, the count data sorting unit 27a of the count data recording apparatus (MFP 1) rearranges the addresses in descending order of the count data values recorded at the respective addresses.

ステップS103において、カウントデータ差分算出部27bは、ステップS101で並び替えされたアドレスの並び方において隣接し合うアドレスに記録されたカウントデータ間の差分を算出する。   In step S103, the count data difference calculation unit 27b calculates the difference between the count data recorded in the adjacent addresses in the arrangement of the addresses rearranged in step S101.

ステップS105において、修復処理実行部27cは、各アドレスに関連付けられた極性情報データをステップS101で並び替えされたアドレスの並び方に沿って見た場合に隣接した極性情報データ値間で変化が生じている箇所の数を求める。つまり、上記した並び方において隣接した極性情報データにおいてその値が、第1値から第2値へ(「1」から「0」へ)、および、第2値から第1値へ(「0」から「1」へ)変化している箇所の数を求める。   In step S105, the restoration processing execution unit 27c changes between adjacent polarity information data values when the polarity information data associated with each address is viewed along the arrangement of the addresses rearranged in step S101. Find the number of locations. That is, in the polarity information data adjacent in the above-described arrangement, the value is changed from the first value to the second value (from “1” to “0”) and from the second value to the first value (from “0”). To “1”) Find the number of locations that have changed.

ステップS107において、修復処理実行部27cは、ステップS105で求めた極性情報データ値変化回数にもとづき、以降の処理を分岐させる。極性情報データ値変化回数が、0回の場合(ステップS107における「極性情報変化回数0回」)、処理は、ステップS109へ移行する。極性情報データ値変化回数が、1回の場合(ステップS107における「極性情報変化回数1回」)、処理は、ステップS201へ移行する。極性情報データ値変化回数が、2回以上の場合(ステップS107における「極性情報変化回数2回以上」)、処理は、ステップS111へ移行する。   In step S107, the repair processing execution unit 27c branches the subsequent processing based on the number of changes in the polarity information data value obtained in step S105. If the polarity information data value change count is 0 (“polarity information change count 0” in step S107), the process proceeds to step S109. If the polarity information data value change count is 1 (“polarity information change count 1” in step S107), the process proceeds to step S201. If the polarity information data value change count is 2 or more (“polarity information change count is 2 or more” in step S107), the process proceeds to step S111.

{極性情報データ値変化回数が0回の場合の処理}
ステップS109において、修復処理実行部27cは、カウントデータ値間差分値が全て1(インクリメント幅S)であり、かつ、ステップS101で並び替えられたアドレスの並び方が、アドレス組み合わせGr.[5](図9参照。)であるか、否か、について判定する。
カウントデータ値間差分値が全て1(インクリメント幅S)であり、かつ、ステップS101で並び替えられたアドレスの並び方が、アドレス組み合わせGr.[5](図9参照。)である場合(ステップS109における「YES」)、処理は、終了する。つまり、データ破損は生じていないと判断され、破損検出処理は終了される。
1(インクリメント幅S)でないカウントデータ値間差分値が存在する場合、および、ステップS101で並び替えられたアドレスの並び方が、アドレス組み合わせGr.[5](図9参照。)でない場合のいずれかに該当する場合(ステップS109における「NO」)、処理は、ステップS301e(カウントデータ修復処理E(詳細は図18AおよびB))へ移行する。
{Processing when the polarity information data value change count is 0}
In step S109, the restoration processing execution unit 27c determines that the difference between the count data values is all 1 (increment width S), and that the address rearranged in step S101 is the address combination Gr. [5] It is determined whether or not (see FIG. 9).
The difference values between the count data values are all 1 (increment width S), and the arrangement of the addresses rearranged in step S101 is the address combination Gr. If it is [5] (see FIG. 9) (“YES” in step S109), the process ends. That is, it is determined that no data is damaged, and the damage detection process is terminated.
If there is a difference value between count data values other than 1 (increment width S), and the arrangement of the addresses rearranged in step S101 is the address combination Gr. [5] If any of the cases (see FIG. 9) does not apply (“NO” in step S109), the process proceeds to step S301e (count data restoration process E (details are FIGS. 18A and 18B)). .

{極性情報データ値変化回数が1回の場合の処理}
処理は、ステップS201(カウントデータ修復処理選択処理)へ移行する。カウントデータ修復処理選択処理ステップS201については、後で図13を参照して詳述する。
{Processing when the polarity information data value change count is 1}
The process proceeds to step S201 (count data restoration process selection process). The count data restoration process selection process step S201 will be described in detail later with reference to FIG.

{極性情報データ値変化回数が2回の場合の処理}
ステップS111において、修復処理実行部27cは、カウントデータ値間差分値が全て1(インクリメント幅S)である場合、ならびに、ステップS101で並び替えられたアドレスの並び方が、アドレス組み合わせGr.[1]、[2]、[3]、[4]、および、[5](図9参照。)のいずれかである場合、のいずれかに該当するか、否か、について判定する。
カウントデータ値間差分値が全て1(インクリメント幅S)である場合、ならびに、ステップS101で並び替えられたアドレスの並び方が、アドレス組み合わせGr.[1]、[2]、[3]、[4]、および、[5](図9参照。)のいずれかである場合、のいずれかに該当する場合(ステップS111における「YES」)、処理は、ステップS201(カウントデータ修復処理選択処理)へ移行する。
1(インクリメント幅S)でないカウントデータ値間差分値が存在し、かつ、ステップS101で並び替えられたアドレスの並び方が、アドレス組み合わせGr.[1]、[2]、[3]、[4]、および、[5](図9参照。)のいずれにも該当しない場合(ステップS111における「NO」)、処理は、ステップS113へ移行する。
{Processing when the polarity information data value change count is 2}
In step S111, the repair processing execution unit 27c determines that the address combination Gr. Is different when the difference values between the count data values are all 1 (increment width S) and the arrangement of the addresses rearranged in step S101. If it is any one of [1], [2], [3], [4], and [5] (see FIG. 9), it is determined whether or not any of them is applicable.
When all the difference values between the count data values are 1 (increment width S), and the arrangement of the addresses rearranged in step S101 is the address combination Gr. If any of [1], [2], [3], [4], and [5] (see FIG. 9) is true (“YES” in step S111), The process proceeds to step S201 (count data restoration process selection process).
1 (increment width S) and there is a difference value between count data values, and the arrangement of the addresses rearranged in step S101 is the address combination Gr. If none of [1], [2], [3], [4], and [5] (see FIG. 9) applies (“NO” in step S111), the process proceeds to step S113. To do.

ステップS113において、修復処理実行部27cは、正しく修復できないデータ破損が生じていると判断し、その旨を示唆する情報を出力し、処理を終了する。   In step S113, the repair processing execution unit 27c determines that data corruption that cannot be repaired correctly has occurred, outputs information indicating that, and ends the processing.

{カウントデータ修復処理選択処理の流れ(ステップS201詳細)}
これより、図13を参照し、カウントデータ修復処理選択処理(図12におけるステップS201)について説明する。カウントデータ修復処理選択処理は、修復処理実行部27cが行うデータ破損検出のための処理の一部である。
{Flow of Count Data Repair Process Selection Process (Details of Step S201)}
The count data restoration process selection process (step S201 in FIG. 12) will now be described with reference to FIG. The count data restoration process selection process is a part of the process for detecting data corruption performed by the restoration process execution unit 27c.

ステップS203において、修復処理実行部27cは、ステップS101で並び替えられたアドレスの並び方が、アドレス組み合わせGr.[1]、[2]、[3]、[4]、および、[5](図9参照。)のいずれかに該当するか、否か、判定する。
ステップS101で並び替えられたアドレスの並び方が、アドレス組み合わせGr.[1]、[2]、[3]、[4]、および、[5](図9参照。)のいずれかに該当する、と判定した場合(ステップS203における「YES」)、処理は、ステップS205へ移行する。
ステップS101で並び替えられたアドレスの並び方が、アドレス組み合わせGr.[1]、[2]、[3]、[4]、および、[5](図9参照。)のいずれにも該当しない、と判定した場合(ステップS203における「NO」)、処理は、ステップS209へ移行する。
In step S203, the repair processing execution unit 27c determines that the address arrangement in step S101 is the address combination Gr. It is determined whether or not any of [1], [2], [3], [4], and [5] (see FIG. 9) is satisfied.
The arrangement of the addresses rearranged in step S101 is the address combination Gr. When it is determined that any one of [1], [2], [3], [4], and [5] (see FIG. 9) is satisfied (“YES” in step S203), the process is as follows. The process proceeds to step S205.
The arrangement of the addresses rearranged in step S101 is the address combination Gr. When it is determined that none of [1], [2], [3], [4], and [5] (see FIG. 9) is applicable (“NO” in step S203), The process proceeds to step S209.

ステップS205において、修復処理実行部27cは、カウントデータ値間差分値が全て1(インクリメント幅S)であるか、否か、について判定する。
カウントデータ値間差分値が全て1(インクリメント幅S)である、と判定した場合(ステップS205における「YES」)、カウントデータ修復処理選択処理は終了し、メインフロー(図12)へ戻る。
1(インクリメント幅S)でないカウントデータ値間差分値が存在する、と判定した場合(ステップS205における「NO」)、処理は、ステップS207へ移行する。
In step S205, the restoration processing execution unit 27c determines whether or not all the difference values between the count data values are 1 (increment width S).
When it is determined that the difference values between the count data values are all 1 (increment width S) (“YES” in step S205), the count data restoration process selection process ends, and the process returns to the main flow (FIG. 12).
When it is determined that there is a difference value between count data values that is not 1 (increment width S) (“NO” in step S205), the process proceeds to step S207.

ステップS207において、修復処理実行部27cは、ステップS101で並び替えられたアドレスの並び方にもとづき、以降の処理を分岐させる。
該並び方が、アドレス組み合わせGr.[1](図9参照。)である場合、処理は、ステップS301a(カウントデータ修復処理A)へ移行する。
該並び方が、アドレス組み合わせGr.[2](図9参照。)である場合、処理は、ステップS301b(カウントデータ修復処理B)へ移行する。
該並び方が、アドレス組み合わせGr.[3](図9参照。)である場合、処理は、ステップS301c(カウントデータ修復処理C)へ移行する。
該並び方が、アドレス組み合わせGr.[4](図9参照。)である場合、処理は、ステップS301d(カウントデータ修復処理D)へ移行する。
該並び方が、アドレス組み合わせGr.[5](図9参照。)である場合、処理は、ステップS301e(カウントデータ修復処理E)へ移行する。
カウントデータ修復処理A、B、C、D、E(ステップS301a、b、c、d、e)の詳細については、それぞれ、図14AおよびB、図15AおよびB、図16AおよびB、図17AおよびB、図18AおよびBを参照し、後述する。
In step S207, the repair processing execution unit 27c branches the subsequent processing based on the arrangement of the addresses rearranged in step S101.
The arrangement is the address combination Gr. If [1] (see FIG. 9), the process proceeds to step S301a (count data restoration process A).
The arrangement is the address combination Gr. If [2] (see FIG. 9), the process proceeds to step S301b (count data restoration process B).
The arrangement is the address combination Gr. If [3] (see FIG. 9), the process proceeds to step S301c (count data restoration process C).
The arrangement is the address combination Gr. If [4] (see FIG. 9), the process proceeds to step S301d (count data restoration process D).
The arrangement is the address combination Gr. If [5] (see FIG. 9), the process proceeds to step S301e (count data restoration process E).
14A and B, FIGS. 15A and B, FIGS. 16A and B, FIGS. 17A and 17B, respectively, for details of the count data restoration processes A, B, C, D, and E (steps S301a, b, c, d, and e). B, described below with reference to FIGS. 18A and B.

次に、処理が、ステップS203から、ステップS209へ移行した後の処理について説明する。   Next, a process after the process moves from step S203 to step S209 will be described.

ステップS209において、修復処理実行部27cは、アドレス[A]、[B]、[C]、[D]、[E]に記録されているカウントデータのなかで、最大のカウントデータを保持しているアドレスを求める。具体的には、ステップS101で並び替えられたアドレスの並びの先頭にあるアドレスを特定する。(インクリメント幅が、負数の場合には、最小のカウントデータを保持しているアドレスを求める。)   In step S209, the repair processing execution unit 27c holds the maximum count data among the count data recorded at the addresses [A], [B], [C], [D], and [E]. Ask for an address. Specifically, the address at the head of the list of addresses rearranged in step S101 is specified. (If the increment width is a negative number, the address holding the minimum count data is obtained.)

ステップS211において、修復処理実行部27cは、ステップS209で求めた最大のカウントデータを保持するアドレスにもとづいて、以降の処理を分岐させる。
該アドレスが、アドレス[A]である場合、処理は、ステップS301a(カウントデータ修復処理A)へ移行する。
該アドレスが、アドレス[B]である場合、処理は、ステップS301b(カウントデータ修復処理B)へ移行する。
該アドレスが、アドレス[C]である場合、処理は、ステップS301c(カウントデータ修復処理C)へ移行する。
該アドレスが、アドレス[D]である場合、処理は、ステップS301d(カウントデータ修復処理D)へ移行する。
該アドレスが、アドレス[E]である場合、処理は、ステップS301e(カウントデータ修復処理E)へ移行する。
カウントデータ修復処理A、B、C、D、E(ステップS301a、b、c、d、e)の詳細については、それぞれ、図14AおよびB、図15AおよびB、図16AおよびB、図17AおよびB、図18AおよびBを参照し、以下に説明する。
In step S211, the repair processing execution unit 27c branches the subsequent processing based on the address holding the maximum count data obtained in step S209.
If the address is address [A], the process proceeds to step S301a (count data restoration process A).
If the address is address [B], the process proceeds to step S301b (count data restoration process B).
If the address is address [C], the process proceeds to step S301c (count data restoration process C).
If the address is address [D], the process proceeds to step S301d (count data restoration process D).
If the address is address [E], the process proceeds to step S301e (count data restoration process E).
14A and B, FIGS. 15A and B, FIGS. 16A and B, FIGS. 17A and 17B, respectively, for details of the count data restoration processes A, B, C, D, and E (steps S301a, b, c, d, and e). B, with reference to FIGS. 18A and B, is described below.

{カウントデータ修復処理A(ステップS301a)}
図14AおよびBは、カウントデータ修復処理A(図13におけるステップS301a)の処理の詳細を示すフローチャートである。カウントデータ修復処理Aは、主として修復処理実行部27cが行う処理である。ただし、カウントデータの修復(正しいカウントデータの書き込み)は、修復処理実行部27cの出力に基づいてデータ書込部25が行う。
{Count data restoration processing A (step S301a)}
14A and 14B are flowcharts showing details of the count data restoration process A (step S301a in FIG. 13). The count data restoration process A is a process mainly performed by the restoration process execution unit 27c. However, the count data is restored (the correct count data is written) by the data writing unit 25 based on the output of the restoration processing execution unit 27c.

ステップS303aにおいて、修復処理実行部27cは、アドレス[A]の極性情報データ(表現に正確を期すならば、アドレス[A]に関連付けられた極性情報データ)が、「1」(第1値)であるか、否かについて判定する。
アドレス[A]の極性情報データが、「1」(第1値)である場合(ステップS303aにおける「YES」)、処理は、ステップS305aへ移行する。
アドレス[A]の極性情報データが、「1」(第1値)でない場合(ステップS303aにおける「NO」)、処理は、ステップS331aへ移行する。
In step S303a, the restoration processing execution unit 27c sets the polarity information data of the address [A] (or the polarity information data associated with the address [A], if accurate) to “1” (first value). Whether or not.
When the polarity information data of the address [A] is “1” (first value) (“YES” in step S303a), the process proceeds to step S305a.
When the polarity information data of the address [A] is not “1” (first value) (“NO” in step S303a), the process proceeds to step S331a.

ステップS305aにおいて、修復処理実行部27cは、現在記録されている全てのカウントデータが正常であるなら、ステップS101で並び替えられたアドレスの並び方は、アドレス組み合わせGr.[1](図9)に一致し、かつ、ステップS101で並び替えられたアドレスの並び方に沿って見た極性情報データの並び方は、極性情報組み合わせGr.[1](図10)に一致する、と認識する。
修復処理実行部27cは、以下の処理においては、アドレス組み合わせGr.[1](図9)および極性情報組み合わせGr.[1](図10)に従ってカウントデータの修復を行う。
In step S305a, if all the count data currently recorded is normal, the repair processing execution unit 27c determines how the addresses rearranged in step S101 are address combinations Gr. [1] (FIG. 9) and the arrangement of the polarity information data viewed along the arrangement of the addresses rearranged in step S101 is the polarity information combination Gr. [1] It is recognized that it matches (FIG. 10).
The repair process execution unit 27c performs the address combination Gr. [1] (FIG. 9) and polarity information combination Gr. [1] The count data is restored according to FIG.

ステップS307aにおいて、修復処理実行部27cは、現在アドレス[A]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S307a, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [A] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS309aにおいて、修復処理実行部27cは、ステップS307aで求めた修復用カウントデータ(アドレス[A]のカウントデータから1を引いた値)と、現在アドレス[E]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[E]に関連付けられた極性情報データの値が0(第2値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS305aに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[1](図9)、および、極性情報組み合わせGr.[1](図10)に従う、との認識にもとづく。
ステップS307aで求めた修復用カウントデータ(アドレス[A]のカウントデータから1を引いた値)と、現在アドレス[E]に記録されているカウントデータの値とが一致し、かつ、アドレス[E]に関連付けられた極性情報データの値が0(第2値)である、と判定された場合(ステップS309aにおける「YES」)、処理は、ステップS313aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[E]に記録されたカウントデータおよびアドレス[E]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[E]に記録されているカウントデータの値とが一致しないか、または、アドレス[E]に関連付けられた極性情報データの値が0(第2値)でない、場合(ステップS309aにおける「NO」)、処理は、ステップS311aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[E]に記録されたカウントデータおよびアドレス[E]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S309a, the repair processing execution unit 27c includes the repair count data obtained in step S307a (the value obtained by subtracting 1 from the count data of the address [A]) and the count data recorded at the current address [E]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [E] is 0 (second value).
As described in the explanation regarding step S305a, if the data is normal, the determination regarding the above two items in this step is based on the address combination Gr. [1] (FIG. 9) and polarity information combination Gr. [1] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S307a (the value obtained by subtracting 1 from the count data at the address [A]) matches the count data value currently recorded at the address [E], and the address [E ] Is determined to be 0 (second value) (“YES” in step S309a), the process proceeds to step S313a. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [E] and the polarity information data associated with the address [E] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [E], or the value of the polarity information data associated with the address [E] is not 0 (second value), In the case (“NO” in step S309a), the process proceeds to step S311a. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [E] and the polarity information data associated with the address [E] need to be repaired.

ステップS311aにおいて、修復処理実行部27cは、アドレス[E]のカウントデータの値を、ステップS307aで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[E]の極性情報データを、「0」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25aに、アドレス[E]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[E]に関連付けられた極性情報データが「0」になるように、適宜動作させる。
In step S311a, the repair process execution unit 27c outputs an instruction to change the count data value of the address [E] to the repair count data value obtained in step S307a. In addition, an instruction to set the polarity information data of the address [E] to “0” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25a to write the value of the restoration count data to the count data storage unit 33 of the address [E], and the polarity information data inversion unit 25b. Then, the polarity information data associated with the address [E] is appropriately operated so as to become “0”.

ステップS313aにおいて、修復処理実行部27cは、現在アドレス[E]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S313a, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [E] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS315aにおいて、修復処理実行部27cは、ステップS313aで求めた修復用カウントデータ(アドレス[E]のカウントデータから1を引いた値)と、現在アドレス[D]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[D]に関連付けられた極性情報データの値が0(第2値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS305aに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[1](図9)、および、極性情報組み合わせGr.[1](図10)に従う、との認識にもとづく。
ステップS313aで求めた修復用カウントデータ(アドレス[E]のカウントデータから1を引いた値)と、現在アドレス[D]に記録されているカウントデータの値とが一致し、かつ、アドレス[D]に関連付けられた極性情報データの値が0(第2値)である、と判定された場合(ステップS315aにおける「YES」)、処理は、ステップS313aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[D]に記録されたカウントデータおよびアドレス[D]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[D]に記録されているカウントデータの値とが一致しないか、または、アドレス[D]に関連付けられた極性情報データの値が0(第2値)でない、場合(ステップS315aにおける「NO」)、処理は、ステップS317aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[D]に記録されたカウントデータおよびアドレス[D]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S315a, the repair processing execution unit 27c includes the repair count data obtained in step S313a (the value obtained by subtracting 1 from the count data of the address [E]) and the count data recorded at the current address [D]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [D] is 0 (second value).
As described in the explanation regarding step S305a, if the data is normal, the determination regarding the above two items in this step is based on the address combination Gr. [1] (FIG. 9) and polarity information combination Gr. [1] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S313a (a value obtained by subtracting 1 from the count data at the address [E]) matches the value of the count data currently recorded at the address [D], and the address [D ] Is determined to be 0 (second value) (“YES” in step S315a), the process proceeds to step S313a. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [D] and the polarity information data associated with the address [D] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [D], or the value of the polarity information data associated with the address [D] is not 0 (second value), In the case (“NO” in step S315a), the process proceeds to step S317a. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [D] and the polarity information data associated with the address [D] need to be repaired.

ステップS317aにおいて、修復処理実行部27cは、アドレス[D]のカウントデータの値を、ステップS313aで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[D]の極性情報データを、「0」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25aに、アドレス[D]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[D]に関連付けられた極性情報データが「0」になるように、適宜動作させる。
In step S317a, the repair processing execution unit 27c outputs an instruction to change the count data value of the address [D] to the repair count data value obtained in step S313a. Also, an instruction to set the polarity information data of the address [D] to “0” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25a to write the value of the restoration count data to the count data storage unit 33 of the address [D], and the polarity information data inversion unit 25b. The polarity information data associated with the address [D] is appropriately operated so as to become “0”.

ステップS319aにおいて、修復処理実行部27cは、現在アドレス[D]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S319a, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [D] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS321aにおいて、修復処理実行部27cは、ステップS319aで求めた修復用カウントデータ(アドレス[D]のカウントデータから1を引いた値)と、現在アドレス[C]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[C]に関連付けられた極性情報データの値が0(第2値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS305aに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[1](図9)、および、極性情報組み合わせGr.[1](図10)に従う、との認識にもとづく。
ステップS319aで求めた修復用カウントデータ(アドレス[D]のカウントデータから1を引いた値)と、現在アドレス[C]に記録されているカウントデータの値とが一致し、かつ、アドレス[C]に関連付けられた極性情報データの値が0(第2値)である、と判定された場合(ステップS321aにおける「YES」)、処理は、ステップS313aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[C]に記録されたカウントデータおよびアドレス[C]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[C]に記録されているカウントデータの値とが一致しないか、または、アドレス[C]に関連付けられた極性情報データの値が0(第2値)でない、場合(ステップS321aにおける「NO」)、処理は、ステップS321aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[C]に記録されたカウントデータおよびアドレス[C]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S321a, the repair processing execution unit 27c includes the repair count data obtained in step S319a (a value obtained by subtracting 1 from the count data of the address [D]) and the count data recorded at the current address [C]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [C] is 0 (second value).
As described in the explanation regarding step S305a, if the data is normal, the determination regarding the above two items in this step is based on the address combination Gr. [1] (FIG. 9) and polarity information combination Gr. [1] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S319a (a value obtained by subtracting 1 from the count data of the address [D]) matches the value of the count data currently recorded at the address [C], and the address [C ] Is determined to be 0 (second value) (“YES” in step S321a), the process proceeds to step S313a. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [C] and the polarity information data associated with the address [C] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [C], or the value of the polarity information data associated with the address [C] is not 0 (second value). In the case (“NO” in step S321a), the process proceeds to step S321a. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [C] and the polarity information data associated with the address [C] need to be repaired.

ステップS323aにおいて、修復処理実行部27cは、アドレス[C]のカウントデータの値を、ステップS319aで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[C]の極性情報データを、「0」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25aに、アドレス[C]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[C]に関連付けられた極性情報データが「0」になるように、適宜動作させる。
In step S323a, the repair process execution unit 27c outputs an instruction to change the count data value of the address [C] to the repair count data value obtained in step S319a. In addition, an instruction to set the polarity information data of the address [C] to “0” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25a to write the value of the restoration count data to the count data storage unit 33 at the address [C], and the polarity information data inversion unit 25b. Then, the polarity information data associated with the address [C] is appropriately operated so as to become “0”.

ステップS325aにおいて、修復処理実行部27cは、現在アドレス[C]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S325a, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [C] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS327aにおいて、修復処理実行部27cは、ステップS325aで求めた修復用カウントデータ(アドレス[C]のカウントデータから1を引いた値)と、現在アドレス[B]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[B]に関連付けられた極性情報データの値が0(第2値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS305aに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[1](図9)、および、極性情報組み合わせGr.[1](図10)に従う、との認識にもとづく。
ステップS325aで求めた修復用カウントデータ(アドレス[C]のカウントデータから1を引いた値)と、現在アドレス[B]に記録されているカウントデータの値とが一致し、かつ、アドレス[B]に関連付けられた極性情報データの値が0(第2値)である、と判定された場合(ステップS327aにおける「YES」)、処理は、ステップS313aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[B]に記録されたカウントデータおよびアドレス[B]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[B]に記録されているカウントデータの値とが一致しないか、または、アドレス[B]に関連付けられた極性情報データの値が0(第2値)でない、場合(ステップS327aにおける「NO」)、処理は、ステップS329aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[B]に記録されたカウントデータおよびアドレス[B]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S327a, the repair processing execution unit 27c includes the repair count data obtained in step S325a (a value obtained by subtracting 1 from the count data of the address [C]) and the count data recorded at the current address [B]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [B] is 0 (second value).
As described in the explanation regarding step S305a, if the data is normal, the determination regarding the above two items in this step is based on the address combination Gr. [1] (FIG. 9) and polarity information combination Gr. [1] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S325a (a value obtained by subtracting 1 from the count data at the address [C]) matches the value of the count data currently recorded at the address [B], and the address [B ] Is determined to be 0 (second value) (“YES” in step S327a), the process proceeds to step S313a. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [B] and the polarity information data associated with the address [B] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [B], or the value of the polarity information data associated with the address [B] is not 0 (second value), In the case (“NO” in step S327a), the process proceeds to step S329a. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [B] and the polarity information data associated with the address [B] need to be repaired.

ステップS329aにおいて、修復処理実行部27cは、アドレス[B]のカウントデータの値を、ステップS325aで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[B]の極性情報データを、「0」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25aに、アドレス[B]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[B]に関連付けられた極性情報データが「0」になるように、適宜動作させる。
In step S329a, the repair processing execution unit 27c outputs an instruction to change the count data value of the address [B] to the repair count data value obtained in step S325a. Also, an instruction to set the polarity information data of the address [B] to “0” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25a to write the value of the restoration count data to the count data storage unit 33 at the address [B], and the polarity information data inversion unit 25b. Then, the polarity information data associated with the address [B] is appropriately operated so as to be “0”.

次に、処理が、ステップS303aから、ステップS331aへ移行した後の処理について説明する。   Next, a process after the process moves from step S303a to step S331a will be described.

ステップS331aにおいて、修復処理実行部27cは、現在記録されている全てのカウントデータが正常であるなら、ステップS101で並び替えられたアドレスの並び方は、アドレス組み合わせGr.[1](図9)に一致し、かつ、ステップS101で並び替えられたアドレスの並び方に沿って見た極性情報データの並び方は、極性情報組み合わせGr.[2](図10)に一致する、と認識する。
修復処理実行部27cは、以下の処理においては、アドレス組み合わせGr.[1](図9)および極性情報組み合わせGr.[2](図10)に従ってカウントデータの修復を行う。
In step S331a, if all the count data currently recorded is normal, the repair processing execution unit 27c determines whether the addresses rearranged in step S101 are address combinations Gr. [1] (FIG. 9) and the arrangement of the polarity information data viewed along the arrangement of the addresses rearranged in step S101 is the polarity information combination Gr. [2] Recognize that it matches (FIG. 10).
The repair process execution unit 27c performs the address combination Gr. [1] (FIG. 9) and polarity information combination Gr. [2] The count data is restored according to FIG.

ステップS333aにおいて、修復処理実行部27cは、現在アドレス[A]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S333a, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [A] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS335aにおいて、修復処理実行部27cは、ステップS333aで求めた修復用カウントデータ(アドレス[A]のカウントデータから1を引いた値)と、現在アドレス[E]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[E]に関連付けられた極性情報データの値が1(第1値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS331aに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[1](図9)、および、極性情報組み合わせGr.[2](図10)に従う、との認識にもとづく。
ステップS333aで求めた修復用カウントデータ(アドレス[A]のカウントデータから1を引いた値)と、現在アドレス[E]に記録されているカウントデータの値とが一致し、かつ、アドレス[E]に関連付けられた極性情報データの値が1(第1値)である、と判定された場合(ステップS335aにおける「YES」)、処理は、ステップS339aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[E]に記録されたカウントデータおよびアドレス[E]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[E]に記録されているカウントデータの値とが一致しないか、または、アドレス[E]に関連付けられた極性情報データの値が1(第1値)でない、場合(ステップS335aにおける「NO」)、処理は、ステップS337aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[E]に記録されたカウントデータおよびアドレス[E]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S335a, the repair processing execution unit 27c includes the repair count data obtained in step S333a (the value obtained by subtracting 1 from the count data of the address [A]) and the count data recorded at the current address [E]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [E] is 1 (first value).
As described in the description of step S331a, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [1] (FIG. 9) and polarity information combination Gr. [2] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S333a (a value obtained by subtracting 1 from the count data at the address [A]) matches the value of the count data currently recorded at the address [E], and the address [E ] Is determined to be 1 (first value) (“YES” in step S335a), the process proceeds to step S339a. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [E] and the polarity information data associated with the address [E] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [E], or the value of the polarity information data associated with the address [E] is not 1 (first value), In the case (“NO” in step S335a), the process proceeds to step S337a. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [E] and the polarity information data associated with the address [E] need to be repaired.

ステップS337aにおいて、修復処理実行部27cは、アドレス[E]のカウントデータの値を、ステップS333aで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[E]の極性情報データを、「1」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25aに、アドレス[E]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[E]に関連付けられた極性情報データが「1」になるように、適宜動作させる。
In step S337a, the repair processing execution unit 27c outputs an instruction to change the count data value of the address [E] to the repair count data value obtained in step S333a. In addition, an instruction to set the polarity information data of the address [E] to “1” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25a to write the value of the restoration count data to the count data storage unit 33 of the address [E], and the polarity information data inversion unit 25b. Then, the polarity information data associated with the address [E] is appropriately operated so as to be “1”.

ステップS339aにおいて、修復処理実行部27cは、現在アドレス[E]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S339a, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [E] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS341aにおいて、修復処理実行部27cは、ステップS339aで求めた修復用カウントデータ(アドレス[E]のカウントデータから1を引いた値)と、現在アドレス[D]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[D]に関連付けられた極性情報データの値が1(第1値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS331aに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[1](図9)、および、極性情報組み合わせGr.[2](図10)に従う、との認識にもとづく。
ステップS339aで求めた修復用カウントデータ(アドレス[E]のカウントデータから1を引いた値)と、現在アドレス[D]に記録されているカウントデータの値とが一致し、かつ、アドレス[D]に関連付けられた極性情報データの値が1(第1値)である、と判定された場合(ステップS341aにおける「YES」)、処理は、ステップS339aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[D]に記録されたカウントデータおよびアドレス[D]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[D]に記録されているカウントデータの値とが一致しないか、または、アドレス[D]に関連付けられた極性情報データの値が1(第1値)でない、場合(ステップS341aにおける「NO」)、処理は、ステップS343aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[D]に記録されたカウントデータおよびアドレス[D]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S341a, the repair processing execution unit 27c includes the repair count data obtained in step S339a (the value obtained by subtracting 1 from the count data of the address [E]) and the count data recorded at the current address [D]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [D] is 1 (first value).
As described in the description of step S331a, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [1] (FIG. 9) and polarity information combination Gr. [2] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S339a (a value obtained by subtracting 1 from the count data at the address [E]) matches the value of the count data currently recorded at the address [D], and the address [D ] Is determined to be 1 (first value) (“YES” in step S341a), the process proceeds to step S339a. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [D] and the polarity information data associated with the address [D] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [D], or the value of the polarity information data associated with the address [D] is not 1 (first value), In the case (“NO” in step S341a), the process proceeds to step S343a. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [D] and the polarity information data associated with the address [D] need to be repaired.

ステップS343aにおいて、修復処理実行部27cは、アドレス[D]のカウントデータの値を、ステップS339aで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[D]の極性情報データを、「1」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25aに、アドレス[D]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[D]に関連付けられた極性情報データが「1」になるように、適宜動作させる。
In step S343a, the repair process execution unit 27c outputs an instruction to change the count data value of the address [D] to the repair count data value obtained in step S339a. In addition, an instruction to set the polarity information data of the address [D] to “1” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25a to write the value of the restoration count data to the count data storage unit 33 of the address [D], and the polarity information data inversion unit 25b. Then, the polarity information data associated with the address [D] is appropriately operated so as to be “1”.

ステップS345aにおいて、修復処理実行部27cは、現在アドレス[D]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S345a, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [D] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS347aにおいて、修復処理実行部27cは、ステップS345aで求めた修復用カウントデータ(アドレス[D]のカウントデータから1を引いた値)と、現在アドレス[C]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[C]に関連付けられた極性情報データの値が1(第1値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS331aに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[1](図9)、および、極性情報組み合わせGr.[2](図10)に従う、との認識にもとづく。
ステップS345aで求めた修復用カウントデータ(アドレス[D]のカウントデータから1を引いた値)と、現在アドレス[C]に記録されているカウントデータの値とが一致し、かつ、アドレス[C]に関連付けられた極性情報データの値が1(第1値)である、と判定された場合(ステップS347aにおける「YES」)、処理は、ステップS339aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[C]に記録されたカウントデータおよびアドレス[C]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[C]に記録されているカウントデータの値とが一致しないか、または、アドレス[C]に関連付けられた極性情報データの値が1(第1値)でない、場合(ステップS347aにおける「NO」)、処理は、ステップS347aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[C]に記録されたカウントデータおよびアドレス[C]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S347a, the repair processing execution unit 27c includes the repair count data obtained in step S345a (the value obtained by subtracting 1 from the count data of the address [D]) and the count data recorded at the current address [C]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [C] is 1 (first value).
As described in the description of step S331a, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [1] (FIG. 9) and polarity information combination Gr. [2] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S345a (a value obtained by subtracting 1 from the count data of the address [D]) matches the value of the count data recorded at the current address [C], and the address [C ] Is determined to be 1 (first value) (“YES” in step S347a), the process proceeds to step S339a. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [C] and the polarity information data associated with the address [C] do not need to be repaired.
The count data for restoration and the value of the count data currently recorded at the address [C] do not match, or the value of the polarity information data associated with the address [C] is not 1 (first value), If so ("NO" in step S347a), the process proceeds to step S347a. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [C] and the polarity information data associated with the address [C] need to be repaired.

ステップS349aにおいて、修復処理実行部27cは、アドレス[C]のカウントデータの値を、ステップS345aで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[C]の極性情報データを、「1」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25aに、アドレス[C]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[C]に関連付けられた極性情報データが「1」になるように、適宜動作させる。
In step S349a, the repair process execution unit 27c outputs an instruction to change the count data value of the address [C] to the repair count data value obtained in step S345a. Also, an instruction to set the polarity information data of the address [C] to “1” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25a to write the value of the restoration count data to the count data storage unit 33 at the address [C], and the polarity information data inversion unit 25b. The polarity information data associated with the address [C] is appropriately operated so as to be “1”.

ステップS351aにおいて、修復処理実行部27cは、現在アドレス[C]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S351a, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [C] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS353aにおいて、修復処理実行部27cは、ステップS351aで求めた修復用カウントデータ(アドレス[C]のカウントデータから1を引いた値)と、現在アドレス[B]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[B]に関連付けられた極性情報データの値が1(第1値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS331aに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[1](図9)、および、極性情報組み合わせGr.[2](図10)に従う、との認識にもとづく。
ステップS351aで求めた修復用カウントデータ(アドレス[C]のカウントデータから1を引いた値)と、現在アドレス[B]に記録されているカウントデータの値とが一致し、かつ、アドレス[B]に関連付けられた極性情報データの値が1(第1値)である、と判定された場合(ステップS353aにおける「YES」)、処理は、ステップS339aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[B]に記録されたカウントデータおよびアドレス[B]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[B]に記録されているカウントデータの値とが一致しないか、または、アドレス[B]に関連付けられた極性情報データの値が1(第1値)でない、場合(ステップS353aにおける「NO」)、処理は、ステップS355aへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[B]に記録されたカウントデータおよびアドレス[B]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S353a, the repair processing execution unit 27c includes the repair count data obtained in step S351a (the value obtained by subtracting 1 from the count data of the address [C]) and the count data recorded at the current address [B]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [B] is 1 (first value).
As described in the description of step S331a, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [1] (FIG. 9) and polarity information combination Gr. [2] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S351a (the value obtained by subtracting 1 from the count data at the address [C]) matches the value of the count data recorded at the current address [B], and the address [B ] Is determined to be 1 (first value) (“YES” in step S353a), the process proceeds to step S339a. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [B] and the polarity information data associated with the address [B] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [B], or the value of the polarity information data associated with the address [B] is not 1 (first value), In the case (“NO” in step S353a), the process proceeds to step S355a. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [B] and the polarity information data associated with the address [B] need to be repaired.

ステップS355aにおいて、修復処理実行部27cは、アドレス[B]のカウントデータの値を、ステップS351aで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[B]の極性情報データを、「1」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25aに、アドレス[B]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[B]に関連付けられた極性情報データが「1」になるように、適宜動作させる。
In step S355a, the repair process execution unit 27c outputs an instruction to change the count data value of the address [B] to the repair count data value obtained in step S351a. Also, an instruction to set the polarity information data of the address [B] to “1” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25a to write the value of the restoration count data to the count data storage unit 33 at the address [B], and the polarity information data inversion unit 25b. The polarity information data associated with the address [B] is appropriately operated so as to be “1”.

このように、カウントデータ修復処理Aにおいては、アドレス[A]のカウントデータおよびアドレス[A]に関連付けられた極性情報データを基準として、アドレス[E]、アドレス[D]、アドレス[C]、アドレス[B]のカウントデータの値、ならびに、それらアドレスに関連付けられた極性情報データの値が、アドレス組み合わせGr.[1](図9)ならびに極性情報組み合わせGr.[1]もしくは極性情報組み合わせGr.[2](図10)に一致するように、カウントデータの値および極性情報データの値を修正する。   In this way, in the count data restoration process A, the address [E], the address [D], the address [C], the address [A], and the polarity information data associated with the address [A] are used as a reference. The value of the count data of the address [B] and the value of the polarity information data associated with these addresses are stored in the address combination Gr. [1] (FIG. 9) and polarity information combination Gr. [1] or polarity information combination Gr. [2] The value of the count data and the value of the polarity information data are corrected so as to coincide with (2) (FIG. 10).

{カウントデータ修復処理B(ステップS301b)}
図15AおよびBは、カウントデータ修復処理B(図13におけるステップS301b)の処理の詳細を示すフローチャートである。カウントデータ修復処理Bは、主として修復処理実行部27cが行う処理である。ただし、カウントデータの修復(正しいカウントデータの書き込み)は、修復処理実行部27cの出力に基づいてデータ書込部25が行う。
{Count data restoration process B (step S301b)}
15A and 15B are flowcharts showing details of the count data restoration process B (step S301b in FIG. 13). The count data restoration process B is a process mainly performed by the restoration process execution unit 27c. However, the count data is restored (the correct count data is written) by the data writing unit 25 based on the output of the restoration processing execution unit 27c.

ステップS303bにおいて、修復処理実行部27cは、アドレス[B]の極性情報データ(表現に正確を期すならば、アドレス[B]に関連付けられた極性情報データ)が、「1」(第1値)であるか、否かについて判定する。
アドレス[B]の極性情報データが、「1」(第1値)である場合(ステップS303bにおける「YES」)、処理は、ステップS305bへ移行する。
アドレス[B]の極性情報データが、「1」(第1値)でない場合(ステップS303bにおける「NO」)、処理は、ステップS331bへ移行する。
In step S303b, the restoration processing execution unit 27c sets the polarity information data of the address [B] (or the polarity information data associated with the address [B] if the expression is accurate) to “1” (first value). Whether or not.
When the polarity information data of the address [B] is “1” (first value) (“YES” in step S303b), the process proceeds to step S305b.
When the polarity information data of the address [B] is not “1” (first value) (“NO” in step S303b), the process proceeds to step S331b.

ステップS305bにおいて、修復処理実行部27cは、現在記録されている全てのカウントデータが正常であるなら、ステップS101で並び替えられたアドレスの並び方は、アドレス組み合わせGr.[2](図9)に一致し、かつ、ステップS101で並び替えられたアドレスの並び方に沿って見た極性情報データの並び方は、極性情報組み合わせGr.[3](図10)に一致する、と認識する。
修復処理実行部27cは、以下の処理においては、アドレス組み合わせGr.[2](図9)および極性情報組み合わせGr.[3](図10)に従ってカウントデータの修復を行う。
In step S305b, if all the currently recorded count data is normal, the repair processing execution unit 27c determines whether the addresses rearranged in step S101 are address combinations Gr. [2] (FIG. 9) and the arrangement of the polarity information data viewed along the arrangement of the addresses rearranged in step S101 is the polarity information combination Gr. [3] Recognize that it matches (FIG. 10).
The repair process execution unit 27c performs the address combination Gr. [2] (FIG. 9) and polarity information combination Gr. [3] The count data is restored according to FIG.

ステップS307bにおいて、修復処理実行部27cは、現在アドレス[B]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S307b, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [B] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS309bにおいて、修復処理実行部27cは、ステップS307bで求めた修復用カウントデータ(アドレス[B]のカウントデータから1を引いた値)と、現在アドレス[A]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[A]に関連付けられた極性情報データの値が1(第1値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS305bに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[2](図9)、および、極性情報組み合わせGr.[3](図10)に従う、との認識にもとづく。
ステップS307bで求めた修復用カウントデータ(アドレス[B]のカウントデータから1を引いた値)と、現在アドレス[A]に記録されているカウントデータの値とが一致し、かつ、アドレス[A]に関連付けられた極性情報データの値が1(第1値)である、と判定された場合(ステップS309bにおける「YES」)、処理は、ステップS313bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[A]に記録されたカウントデータおよびアドレス[A]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[A]に記録されているカウントデータの値とが一致しないか、または、アドレス[A]に関連付けられた極性情報データの値が1(第1値)でない、場合(ステップS309bにおける「NO」)、処理は、ステップS311bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[A]に記録されたカウントデータおよびアドレス[A]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S309b, the repair processing execution unit 27c includes the repair count data obtained in step S307b (the value obtained by subtracting 1 from the count data of the address [B]) and the count data recorded at the current address [A]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [A] is 1 (first value).
As described in the description of step S305b, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [2] (FIG. 9) and polarity information combination Gr. [3] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S307b (a value obtained by subtracting 1 from the count data of the address [B]) matches the value of the count data currently recorded at the address [A], and the address [A ] Is determined to be 1 (first value) (“YES” in step S309b), the process proceeds to step S313b. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [A] and the polarity information data associated with the address [A] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [A], or the value of the polarity information data associated with the address [A] is not 1 (first value), In the case (“NO” in step S309b), the process proceeds to step S311b. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [A] and the polarity information data associated with the address [A] need to be repaired.

ステップS311bにおいて、修復処理実行部27cは、アドレス[A]のカウントデータの値を、ステップS307bで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[A]の極性情報データを、「1」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25bに、アドレス[A]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[A]に関連付けられた極性情報データが「1」になるように、適宜動作させる。
In step S311b, the repair processing execution unit 27c outputs an instruction to change the count data value of the address [A] to the repair count data value obtained in step S307b. Also, an instruction to set the polarity information data of the address [A] to “1” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25b to write the value of the restoration count data to the count data storage unit 33 at the address [A], and the polarity information data inversion unit 25b. Then, the polarity information data associated with the address [A] is appropriately operated so as to be “1”.

ステップS313bにおいて、修復処理実行部27cは、現在アドレス[A]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S313b, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [A] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS315bにおいて、修復処理実行部27cは、ステップS313bで求めた修復用カウントデータ(アドレス[A]のカウントデータから1を引いた値)と、現在アドレス[E]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[E]に関連付けられた極性情報データの値が0(第2値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS305bに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[2](図9)、および、極性情報組み合わせGr.[3](図10)に従う、との認識にもとづく。
ステップS313bで求めた修復用カウントデータ(アドレス[A]のカウントデータから1を引いた値)と、現在アドレス[E]に記録されているカウントデータの値とが一致し、かつ、アドレス[E]に関連付けられた極性情報データの値が0(第2値)である、と判定された場合(ステップS315bにおける「YES」)、処理は、ステップS313bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[E]に記録されたカウントデータおよびアドレス[E]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[E]に記録されているカウントデータの値とが一致しないか、または、アドレス[E]に関連付けられた極性情報データの値が0(第2値)でない、場合(ステップS315bにおける「NO」)、処理は、ステップS317bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[E]に記録されたカウントデータおよびアドレス[E]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S315b, the repair processing execution unit 27c includes the repair count data obtained in step S313b (a value obtained by subtracting 1 from the count data of the address [A]) and the count data recorded at the current address [E]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [E] is 0 (second value).
As described in the description of step S305b, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [2] (FIG. 9) and polarity information combination Gr. [3] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S313b (a value obtained by subtracting 1 from the count data at the address [A]) matches the value of the count data currently recorded at the address [E], and the address [E ] Is determined to be 0 (second value) (“YES” in step S315b), the process proceeds to step S313b. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [E] and the polarity information data associated with the address [E] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [E], or the value of the polarity information data associated with the address [E] is not 0 (second value), In the case (“NO” in step S315b), the process proceeds to step S317b. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [E] and the polarity information data associated with the address [E] need to be repaired.

ステップS317bにおいて、修復処理実行部27cは、アドレス[E]のカウントデータの値を、ステップS313bで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[E]の極性情報データを、「0」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25bに、アドレス[E]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[E]に関連付けられた極性情報データが「0」になるように、適宜動作させる。
In step S317b, the repair processing execution unit 27c outputs an instruction to change the count data value of the address [E] to the repair count data value obtained in step S313b. In addition, an instruction to set the polarity information data of the address [E] to “0” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25b to write the value of the restoration count data to the count data storage unit 33 of the address [E], and the polarity information data inversion unit 25b. Then, the polarity information data associated with the address [E] is appropriately operated so as to become “0”.

ステップS319bにおいて、修復処理実行部27cは、現在アドレス[E]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S319b, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [E] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS321bにおいて、修復処理実行部27cは、ステップS319bで求めた修復用カウントデータ(アドレス[E]のカウントデータから1を引いた値)と、現在アドレス[D]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[D]に関連付けられた極性情報データの値が0(第2値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS305bに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[2](図9)、および、極性情報組み合わせGr.[3](図10)に従う、との認識にもとづく。
ステップS319bで求めた修復用カウントデータ(アドレス[E]のカウントデータから1を引いた値)と、現在アドレス[D]に記録されているカウントデータの値とが一致し、かつ、アドレス[D]に関連付けられた極性情報データの値が0(第2値)である、と判定された場合(ステップS321bにおける「YES」)、処理は、ステップS313bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[D]に記録されたカウントデータおよびアドレス[D]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[D]に記録されているカウントデータの値とが一致しないか、または、アドレス[D]に関連付けられた極性情報データの値が0(第2値)でない、場合(ステップS321bにおける「NO」)、処理は、ステップS321bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[D]に記録されたカウントデータおよびアドレス[D]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S321b, the repair processing execution unit 27c includes the repair count data obtained in step S319b (the value obtained by subtracting 1 from the count data of the address [E]) and the count data recorded at the current address [D]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [D] is 0 (second value).
As described in the description of step S305b, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [2] (FIG. 9) and polarity information combination Gr. [3] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S319b (a value obtained by subtracting 1 from the count data at the address [E]) matches the value of the count data currently recorded at the address [D], and the address [D ] Is determined to be 0 (second value) (“YES” in step S321b), the process proceeds to step S313b. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [D] and the polarity information data associated with the address [D] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [D], or the value of the polarity information data associated with the address [D] is not 0 (second value), In the case (“NO” in step S321b), the process proceeds to step S321b. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [D] and the polarity information data associated with the address [D] need to be repaired.

ステップS323bにおいて、修復処理実行部27cは、アドレス[D]のカウントデータの値を、ステップS319bで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[D]の極性情報データを、「0」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25bに、アドレス[D]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[D]に関連付けられた極性情報データが「0」になるように、適宜動作させる。
In step S323b, the repair processing execution unit 27c outputs an instruction to change the count data value of the address [D] to the repair count data value obtained in step S319b. Also, an instruction to set the polarity information data of the address [D] to “0” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25b to write the value of the restoration count data to the count data storage unit 33 of the address [D], and the polarity information data inversion unit 25b. The polarity information data associated with the address [D] is appropriately operated so as to become “0”.

ステップS325bにおいて、修復処理実行部27cは、現在アドレス[D]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S325b, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [D] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS327bにおいて、修復処理実行部27cは、ステップS325bで求めた修復用カウントデータ(アドレス[D]のカウントデータから1を引いた値)と、現在アドレス[C]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[C]に関連付けられた極性情報データの値が0(第2値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS305bに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[2](図9)、および、極性情報組み合わせGr.[3](図10)に従う、との認識にもとづく。
ステップS325bで求めた修復用カウントデータ(アドレス[D]のカウントデータから1を引いた値)と、現在アドレス[C]に記録されているカウントデータの値とが一致し、かつ、アドレス[C]に関連付けられた極性情報データの値が0(第2値)である、と判定された場合(ステップS327bにおける「YES」)、処理は、ステップS313bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[C]に記録されたカウントデータおよびアドレス[C]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[C]に記録されているカウントデータの値とが一致しないか、または、アドレス[C]に関連付けられた極性情報データの値が0(第2値)でない、場合(ステップS327bにおける「NO」)、処理は、ステップS329bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[C]に記録されたカウントデータおよびアドレス[C]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S327b, the repair processing execution unit 27c includes the repair count data obtained in step S325b (the value obtained by subtracting 1 from the count data of the address [D]) and the count data recorded at the current address [C]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [C] is 0 (second value).
As described in the description of step S305b, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [2] (FIG. 9) and polarity information combination Gr. [3] Based on the recognition that it complies with (FIG. 10).
The restoration count data obtained in step S325b (the value obtained by subtracting 1 from the count data at the address [D]) matches the value of the count data currently recorded at the address [C], and the address [C ] Is determined to be 0 (second value) (“YES” in step S327b), the process proceeds to step S313b. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [C] and the polarity information data associated with the address [C] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [C], or the value of the polarity information data associated with the address [C] is not 0 (second value). In the case (“NO” in step S327b), the process proceeds to step S329b. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [C] and the polarity information data associated with the address [C] need to be repaired.

ステップS329bにおいて、修復処理実行部27cは、アドレス[C]のカウントデータの値を、ステップS325bで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[C]の極性情報データを、「0」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25bに、アドレス[C]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[C]に関連付けられた極性情報データが「0」になるように、適宜動作させる。
In step S329b, the repair processing execution unit 27c outputs an instruction to change the count data value of the address [C] to the repair count data value obtained in step S325b. In addition, an instruction to set the polarity information data of the address [C] to “0” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25b to write the value of the restoration count data to the count data storage unit 33 at the address [C], and the polarity information data inversion unit 25b. Then, the polarity information data associated with the address [C] is appropriately operated so as to become “0”.

次に、処理が、ステップS303bから、ステップS331bへ移行した後の処理について説明する。   Next, the process after the process moves from step S303b to step S331b will be described.

ステップS331bにおいて、修復処理実行部27cは、現在記録されている全てのカウントデータが正常であるなら、ステップS101で並び替えられたアドレスの並び方は、アドレス組み合わせGr.[2](図9)に一致し、かつ、ステップS101で並び替えられたアドレスの並び方に沿って見た極性情報データの並び方は、極性情報組み合わせGr.[4](図10)に一致する、と認識する。
修復処理実行部27cは、以下の処理においては、アドレス組み合わせGr.[2](図9)および極性情報組み合わせGr.[4](図10)に従ってカウントデータの修復を行う。
In step S331b, if all the count data currently recorded is normal, the repair processing execution unit 27c determines how the addresses rearranged in step S101 are address combinations Gr. [2] (FIG. 9) and the arrangement of the polarity information data viewed along the arrangement of the addresses rearranged in step S101 is the polarity information combination Gr. [4] Recognize that it matches (FIG. 10).
The repair process execution unit 27c performs the address combination Gr. [2] (FIG. 9) and polarity information combination Gr. [4] The count data is restored according to FIG.

ステップS333bにおいて、修復処理実行部27cは、現在アドレス[B]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S333b, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [B] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS335bにおいて、修復処理実行部27cは、ステップS333bで求めた修復用カウントデータ(アドレス[B]のカウントデータから1を引いた値)と、現在アドレス[A]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[A]に関連付けられた極性情報データの値が0(第2値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS331bに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[2](図9)、および、極性情報組み合わせGr.[4](図10)に従う、との認識にもとづく。
ステップS333bで求めた修復用カウントデータ(アドレス[B]のカウントデータから1を引いた値)と、現在アドレス[A]に記録されているカウントデータの値とが一致し、かつ、アドレス[A]に関連付けられた極性情報データの値が0(第2値)である、と判定された場合(ステップS335bにおける「YES」)、処理は、ステップS339bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[A]に記録されたカウントデータおよびアドレス[A]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[A]に記録されているカウントデータの値とが一致しないか、または、アドレス[A]に関連付けられた極性情報データの値が0(第2値)でない、場合(ステップS335bにおける「NO」)、処理は、ステップS337bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[A]に記録されたカウントデータおよびアドレス[A]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S335b, the repair processing execution unit 27c includes the repair count data obtained in step S333b (the value obtained by subtracting 1 from the count data of the address [B]) and the count data recorded at the current address [A]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [A] is 0 (second value).
As described in the explanation regarding step S331b, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [2] (FIG. 9) and polarity information combination Gr. [4] Based on the recognition of following (FIG. 10).
The restoration count data obtained in step S333b (the value obtained by subtracting 1 from the count data at the address [B]) matches the value of the count data currently recorded at the address [A], and the address [A ] Is determined to be 0 (second value) (“YES” in step S335b), the process proceeds to step S339b. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [A] and the polarity information data associated with the address [A] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [A], or the value of the polarity information data associated with the address [A] is not 0 (second value), If so ("NO" in step S335b), the process proceeds to step S337b. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [A] and the polarity information data associated with the address [A] need to be repaired.

ステップS337bにおいて、修復処理実行部27cは、アドレス[A]のカウントデータの値を、ステップS333bで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[A]の極性情報データを、「0」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25bに、アドレス[A]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[A]に関連付けられた極性情報データが「0」になるように、適宜動作させる。
In step S337b, the repair processing execution unit 27c outputs an instruction to change the count data value of the address [A] to the repair count data value obtained in step S333b. Also, an instruction to set the polarity information data of the address [A] to “0” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25b to write the value of the restoration count data to the count data storage unit 33 at the address [A], and the polarity information data inversion unit 25b. The polarity information data associated with the address [A] is appropriately operated so as to become “0”.

ステップS339bにおいて、修復処理実行部27cは、現在アドレス[A]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S339b, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [A] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS341bにおいて、修復処理実行部27cは、ステップS339bで求めた修復用カウントデータ(アドレス[A]のカウントデータから1を引いた値)と、現在アドレス[E]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[E]に関連付けられた極性情報データの値が1(第1値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS331bに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[2](図9)、および、極性情報組み合わせGr.[4](図10)に従う、との認識にもとづく。
ステップS339bで求めた修復用カウントデータ(アドレス[A]のカウントデータから1を引いた値)と、現在アドレス[E]に記録されているカウントデータの値とが一致し、かつ、アドレス[E]に関連付けられた極性情報データの値が1(第1値)である、と判定された場合(ステップS341bにおける「YES」)、処理は、ステップS339bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[E]に記録されたカウントデータおよびアドレス[E]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[E]に記録されているカウントデータの値とが一致しないか、または、アドレス[E]に関連付けられた極性情報データの値が1(第1値)でない、場合(ステップS341bにおける「NO」)、処理は、ステップS343bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[E]に記録されたカウントデータおよびアドレス[E]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S341b, the repair processing execution unit 27c includes the repair count data obtained in step S339b (the value obtained by subtracting 1 from the count data of the address [A]) and the count data recorded at the current address [E]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [E] is 1 (first value).
As described in the explanation regarding step S331b, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [2] (FIG. 9) and polarity information combination Gr. [4] Based on the recognition of following (FIG. 10).
The restoration count data obtained in step S339b (a value obtained by subtracting 1 from the count data of the address [A]) matches the value of the count data currently recorded at the address [E], and the address [E ] Is determined to be 1 (first value) (“YES” in step S341b), the process proceeds to step S339b. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [E] and the polarity information data associated with the address [E] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [E], or the value of the polarity information data associated with the address [E] is not 1 (first value), In the case (“NO” in step S341b), the process proceeds to step S343b. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [E] and the polarity information data associated with the address [E] need to be repaired.

ステップS343bにおいて、修復処理実行部27cは、アドレス[E]のカウントデータの値を、ステップS339bで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[E]の極性情報データを、「1」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25bに、アドレス[E]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[E]に関連付けられた極性情報データが「1」になるように、適宜動作させる。
In step S343b, the repair processing execution unit 27c outputs an instruction to change the count data value of the address [E] to the repair count data value obtained in step S339b. In addition, an instruction to set the polarity information data of the address [E] to “1” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25b to write the value of the restoration count data to the count data storage unit 33 of the address [E], and the polarity information data inversion unit 25b. Then, the polarity information data associated with the address [E] is appropriately operated so as to be “1”.

ステップS345bにおいて、修復処理実行部27cは、現在アドレス[E]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S345b, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [E] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS347bにおいて、修復処理実行部27cは、ステップS345bで求めた修復用カウントデータ(アドレス[E]のカウントデータから1を引いた値)と、現在アドレス[D]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[D]に関連付けられた極性情報データの値が1(第1値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS331bに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[2](図9)、および、極性情報組み合わせGr.[4](図10)に従う、との認識にもとづく。
ステップS345bで求めた修復用カウントデータ(アドレス[E]のカウントデータから1を引いた値)と、現在アドレス[D]に記録されているカウントデータの値とが一致し、かつ、アドレス[D]に関連付けられた極性情報データの値が1(第1値)である、と判定された場合(ステップS347bにおける「YES」)、処理は、ステップS339bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[D]に記録されたカウントデータおよびアドレス[D]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[D]に記録されているカウントデータの値とが一致しないか、または、アドレス[D]に関連付けられた極性情報データの値が1(第1値)でない、場合(ステップS347bにおける「NO」)、処理は、ステップS347bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[D]に記録されたカウントデータおよびアドレス[D]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S347b, the repair processing execution unit 27c includes the repair count data obtained in step S345b (a value obtained by subtracting 1 from the count data of the address [E]) and the count data recorded at the current address [D]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [D] is 1 (first value).
As described in the explanation regarding step S331b, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [2] (FIG. 9) and polarity information combination Gr. [4] Based on the recognition of following (FIG. 10).
The restoration count data obtained in step S345b (the value obtained by subtracting 1 from the count data at the address [E]) matches the value of the count data currently recorded at the address [D], and the address [D ] Is determined to be 1 (first value) (“YES” in step S347b), the process proceeds to step S339b. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [D] and the polarity information data associated with the address [D] do not need to be repaired.
The restoration count data does not match the value of the count data currently recorded at the address [D], or the value of the polarity information data associated with the address [D] is not 1 (first value), In the case (“NO” in step S347b), the process proceeds to step S347b. That is, in this case, the repair process execution unit 27c determines that the count data recorded at the address [D] and the polarity information data associated with the address [D] need to be repaired.

ステップS349bにおいて、修復処理実行部27cは、アドレス[D]のカウントデータの値を、ステップS345bで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[D]の極性情報データを、「1」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25bに、アドレス[D]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[D]に関連付けられた極性情報データが「1」になるように、適宜動作させる。
In step S349b, the repair processing execution unit 27c outputs an instruction to change the count data value of the address [D] to the repair count data value obtained in step S345b. In addition, an instruction to set the polarity information data of the address [D] to “1” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25b to write the value of the restoration count data to the count data storage unit 33 of the address [D], and the polarity information data inversion unit 25b. Then, the polarity information data associated with the address [D] is appropriately operated so as to be “1”.

ステップS351bにおいて、修復処理実行部27cは、現在アドレス[D]に記録されているカウントデータの値から1を引いた(インクリメント幅Sで減算した)値を求め、それを、現在の「修復用カウントデータ」とする。   In step S351b, the restoration processing execution unit 27c obtains a value obtained by subtracting 1 from the value of the count data recorded at the current address [D] (subtracted by the increment width S), and obtains the value “current for restoration”. Count data ”.

ステップS353bにおいて、修復処理実行部27cは、ステップS351bで求めた修復用カウントデータ(アドレス[D]のカウントデータから1を引いた値)と、現在アドレス[C]に記録されているカウントデータの値とを比較し、一致するか、否かを判定するとともに、アドレス[C]に関連付けられた極性情報データの値が1(第1値)であるか、否かを判定する。
本ステップにおける上記2つの事項に関する判断は、ステップS331bに関する説明の段において述べたように、データが正常であれば、そのデータの並び方は、アドレス組み合わせGr.[2](図9)、および、極性情報組み合わせGr.[4](図10)に従う、との認識にもとづく。
ステップS351bで求めた修復用カウントデータ(アドレス[D]のカウントデータから1を引いた値)と、現在アドレス[C]に記録されているカウントデータの値とが一致し、かつ、アドレス[C]に関連付けられた極性情報データの値が1(第1値)である、と判定された場合(ステップS353bにおける「YES」)、処理は、ステップS339bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[C]に記録されたカウントデータおよびアドレス[C]に関連付けられた極性情報データは、修復する必要がないと、判断する。
修復用カウントデータと、現在アドレス[C]に記録されているカウントデータの値とが一致しないか、または、アドレス[C]に関連付けられた極性情報データの値が1(第1値)でない、場合(ステップS353bにおける「NO」)、処理は、ステップS355bへ移行する。つまり、この場合に修復処理実行部27cは、アドレス[C]に記録されたカウントデータおよびアドレス[C]に関連付けられた極性情報データは、修復する必要があると、判断する。
In step S353b, the repair processing execution unit 27c includes the repair count data obtained in step S351b (a value obtained by subtracting 1 from the count data of the address [D]) and the count data recorded at the current address [C]. The values are compared to determine whether or not they match, and it is determined whether or not the value of the polarity information data associated with the address [C] is 1 (first value).
As described in the explanation regarding step S331b, the determination regarding the above two items in this step is performed when the data is normal, the arrangement of the data is determined by the address combination Gr. [2] (FIG. 9) and polarity information combination Gr. [4] Based on the recognition of following (FIG. 10).
The restoration count data obtained in step S351b (a value obtained by subtracting 1 from the count data of the address [D]) matches the value of the count data recorded at the current address [C], and the address [C ] Is determined to be 1 (first value) (“YES” in step S353b), the process proceeds to step S339b. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [C] and the polarity information data associated with the address [C] do not need to be repaired.
The count data for restoration and the value of the count data currently recorded at the address [C] do not match, or the value of the polarity information data associated with the address [C] is not 1 (first value), In the case (“NO” in step S353b), the process proceeds to step S355b. That is, in this case, the repair processing execution unit 27c determines that the count data recorded at the address [C] and the polarity information data associated with the address [C] need to be repaired.

ステップS355bにおいて、修復処理実行部27cは、アドレス[C]のカウントデータの値を、ステップS351bで求めた修復用カウントデータの値に変更する指示を出力する。また、アドレス[C]の極性情報データを、「1」にする指示を出力する。
当該指示にもとづいて、データ書込部25は、カウントデータ書込部25bに、アドレス[C]のカウントデータ記憶部33へ修復用カウントデータの値を書き込ませ、また、極性情報データ反転部25bに、アドレス[C]に関連付けられた極性情報データが「1」になるように、適宜動作させる。
In step S355b, the repair process execution unit 27c outputs an instruction to change the count data value of the address [C] to the repair count data value obtained in step S351b. Also, an instruction to set the polarity information data of the address [C] to “1” is output.
Based on the instruction, the data writing unit 25 causes the count data writing unit 25b to write the value of the restoration count data to the count data storage unit 33 at the address [C], and the polarity information data inversion unit 25b. The polarity information data associated with the address [C] is appropriately operated so as to be “1”.

このように、カウントデータ修復処理Bにおいては、アドレス[B]のカウントデータおよびアドレス[B]に関連付けられた極性情報データを基準として、アドレス[A]、アドレス[E]、アドレス[D]、アドレス[C]のカウントデータの値、ならびに、それらアドレスに関連付けられた極性情報データの値が、アドレス組み合わせGr.[2](図9)ならびに極性情報組み合わせGr.[3]もしくは極性情報組み合わせGr.[4](図10)に一致するように、カウントデータの値および極性情報データの値を修正する。   Thus, in the count data restoration process B, the address [A], the address [E], the address [D], the address [B], and the polarity information data associated with the address [B] are used as a reference. The value of the count data of the address [C] and the value of the polarity information data associated with these addresses are stored in the address combination Gr. [2] (FIG. 9) and polarity information combination Gr. [3] or polarity information combination Gr. [4] The value of the count data and the value of the polarity information data are corrected so as to coincide with (FIG. 10).

{カウントデータ修復処理C(ステップS301c)}
図16AおよびBは、カウントデータ修復処理C(図13におけるステップS301c)の処理の詳細を示すフローチャートである。カウントデータ修復処理Cは、主として修復処理実行部27cが行う処理である。ただし、カウントデータの修復(正しいカウントデータの書き込み)は、修復処理実行部27cの出力に基づいてデータ書込部25が行う。
{Count data restoration process C (step S301c)}
16A and 16B are flowcharts showing details of the count data restoration process C (step S301c in FIG. 13). The count data restoration process C is a process mainly performed by the restoration process execution unit 27c. However, the count data is restored (the correct count data is written) by the data writing unit 25 based on the output of the restoration processing execution unit 27c.

カウントデータ修復処理AおよびB(図14AおよびBならびに図15AおよびB)と同様に、カウントデータ修復処理Cにおいては、アドレス[C]のカウントデータおよびアドレス[C]に関連付けられた極性情報データを基準として、アドレス[B]、アドレス[A]、アドレス[E]、アドレス[D]のカウントデータの値、ならびに、それらアドレスに関連付けられた極性情報データの値が、アドレス組み合わせGr.[3](図9)ならびに極性情報組み合わせGr.[5]もしくは極性情報組み合わせGr.[6](図10)に一致するように、カウントデータの値および極性情報データの値を修正する。   Similar to the count data restoration processing A and B (FIGS. 14A and B and FIGS. 15A and B), in the count data restoration processing C, the count data at the address [C] and the polarity information data associated with the address [C] are stored. As a reference, the value of the count data of the address [B], the address [A], the address [E], and the address [D], and the value of the polarity information data associated with these addresses are represented by the address combination Gr. [3] (FIG. 9) and polarity information combination Gr. [5] or polarity information combination Gr. [6] The value of the count data and the value of the polarity information data are corrected so as to coincide with FIG.

{カウントデータ修復処理D(ステップS301d)}
図17は、カウントデータ修復処理D(図13におけるステップS301d)の処理の詳細を示すフローチャートである。カウントデータ修復処理Dは、主として修復処理実行部27cが行う処理である。ただし、カウントデータの修復(正しいカウントデータの書き込み)は、修復処理実行部27cの出力に基づいてデータ書込部25が行う。
{Count data restoration processing D (step S301d)}
FIG. 17 is a flowchart showing details of the count data restoration process D (step S301d in FIG. 13). The count data restoration process D is a process mainly performed by the restoration process execution unit 27c. However, the count data is restored (the correct count data is written) by the data writing unit 25 based on the output of the restoration processing execution unit 27c.

カウントデータ修復処理A、B、およびC(図14AおよびB、図15AおよびB、ならびに、図16AおよびB)と同様に、カウントデータ修復処理Dにおいては、アドレス[D]のカウントデータおよびアドレス[D]に関連付けられた極性情報データを基準として、アドレス[C]、アドレス[B]、アドレス[A]、アドレス[E]のカウントデータの値、ならびに、それらアドレスに関連付けられた極性情報データの値が、アドレス組み合わせGr.[4](図9)ならびに極性情報組み合わせGr.[7]もしくは極性情報組み合わせGr.[8](図10)に一致するように、カウントデータの値および極性情報データの値を修正する。   Similarly to the count data restoration processing A, B, and C (FIGS. 14A and B, FIGS. 15A and B, and FIGS. 16A and B), in the count data restoration processing D, the count data and the address [ D] with reference to the polarity information data associated with D], the count data values of address [C], address [B], address [A], and address [E], and the polarity information data associated with these addresses. The value is the address combination Gr. [4] (FIG. 9) and polarity information combination Gr. [7] or polarity information combination Gr. [8] The value of the count data and the value of the polarity information data are corrected so as to match (FIG. 10).

{カウントデータ修復処理E(ステップS301e)}
図18AおよびBは、カウントデータ修復処理E(図13におけるステップS301e)の処理の詳細を示すフローチャートである。カウントデータ修復処理Eは、主として修復処理実行部27cが行う処理である。ただし、カウントデータの修復(正しいカウントデータの書き込み)は、修復処理実行部27cの出力に基づいてデータ書込部25が行う。
{Count data restoration processing E (step S301e)}
18A and 18B are flowcharts showing details of the count data restoration process E (step S301e in FIG. 13). The count data restoration process E is a process mainly performed by the restoration process execution unit 27c. However, the count data is restored (the correct count data is written) by the data writing unit 25 based on the output of the restoration processing execution unit 27c.

カウントデータ修復処理A、B、C、およびD(図14AおよびB、図15AおよびB、図16AおよびB、ならびに、図17AおよびB)と同様に、カウントデータ修復処理Eにおいては、アドレス[E]のカウントデータおよびアドレス[E]に関連付けられた極性情報データを基準として、アドレス[D]、アドレス[C]、アドレス[B]、アドレス[A]のカウントデータの値、ならびに、それらアドレスに関連付けられた極性情報データの値が、アドレス組み合わせGr.[5](図9)ならびに極性情報組み合わせGr.[9]もしくは極性情報組み合わせGr.[10](図10)に一致するように、カウントデータの値および極性情報データの値を修正する。   Similar to the count data restoration processing A, B, C, and D (FIGS. 14A and B, FIGS. 15A and B, FIGS. 16A and B, and FIGS. 17A and B), the count data restoration processing E uses the address [E ] And the polarity information data associated with the address [E] as a reference, the count data values of the address [D], the address [C], the address [B], the address [A], and the addresses The value of the associated polarity information data is the address combination Gr. [5] (FIG. 9) and polarity information combination Gr. [9] or polarity information combination Gr. [10] The value of the count data and the value of the polarity information data are corrected so as to coincide with FIG.

≪カウントデータ破損の検出および修復の具体例≫
これより、上で述べたカウントデータ破損の検出および修復について、具体例を示す。
≪Specific example of detection and repair of count data corruption≫
A specific example will now be given for detection and repair of count data corruption described above.

{具体例1}
図19は、具体例1におけるカウントデータの値、および、極性情報データの値の一覧である。
{Specific Example 1}
FIG. 19 is a list of count data values and polarity information data values in the first specific example.

ステップS101(図12)に示したように、カウントデータソート部27aは、カウントデータの大きさでアドレスを並べ替える。   As shown in step S101 (FIG. 12), the count data sorting unit 27a rearranges the addresses according to the size of the count data.

図20は、並べ替えられたアドレスの並び方、ならびに、各アドレスに記録されているカウントデータの値および各アドレスに関連付けられた極性情報データの値の一覧である。   FIG. 20 is a list of the rearranged addresses, the count data values recorded at the addresses, and the polarity information data values associated with the addresses.

ステップS103(図12)に示したように、カウントデータ差分算出部27bは、ステップS101で並べ替えられたアドレスの並び方に沿って、隣接するカウントデータの値の間の差分値を算出する。   As shown in step S103 (FIG. 12), the count data difference calculation unit 27b calculates a difference value between adjacent count data values along the arrangement of the addresses rearranged in step S101.

図21は、算出されたカウントデータ差分値の一覧である。   FIG. 21 is a list of calculated count data difference values.

ステップS105(図12)に示したように、修復処理実行部27cは、各アドレスに関連付けられた極性情報データをステップS101で並び替えされたアドレスの並び方に沿って見た場合に隣接した極性情報データ値間で変化が生じている箇所の数を求める。具体例1においては、変化箇所数は、0である(図20参照。)。   As shown in step S105 (FIG. 12), the restoration processing execution unit 27c uses adjacent polarity information when the polarity information data associated with each address is viewed along the arrangement of the addresses rearranged in step S101. Find the number of locations where there is a change between data values. In the first specific example, the number of change points is 0 (see FIG. 20).

従って、処理は、ステップS109(図12)へ移行する。ステップS109においては、カウントデータ差分値が全て0でないことより、データの破損が存在すると判定され、処理は、ステップS301eへ移行する。   Therefore, the process proceeds to step S109 (FIG. 12). In step S109, since all the count data difference values are not 0, it is determined that there is data corruption, and the process proceeds to step S301e.

ステップS303e(図18AおよびB)において、アドレス[E]の極性情報データの値に基づく判定が行われ、該判定の結果により、処理はステップS305eへ移行する。   In step S303e (FIGS. 18A and 18B), a determination is made based on the value of the polarity information data of the address [E], and the process proceeds to step S305e depending on the result of the determination.

ステップS305e(図18AおよびB)に示したように、これ以降、修復処理実行部27cは、アドレス[E]のカウントデータおよびアドレス[E]に関連付けられた極性情報データを基準として、アドレス組み合わせGr.[5](図9)および極性情報組み合わせGr.[9](図10)に従って、カウントデータの値および極性情報データの値を修正する。   As shown in step S305e (FIGS. 18A and 18B), thereafter, the restoration processing execution unit 27c uses the address combination Gr based on the count data of the address [E] and the polarity information data associated with the address [E]. . [5] (FIG. 9) and polarity information combination Gr. [9] The value of the count data and the value of the polarity information data are corrected according to FIG.

図22は、アドレス[D]に対する破損検出および破損修復の結果を示す図である。   FIG. 22 is a diagram illustrating the results of damage detection and damage repair for address [D].

ステップS307eないしステップS311e(図18AおよびB)に示したようにして、アドレス[D]のカウントデータの値が、24に修正される。   As shown in steps S307e to S311e (FIGS. 18A and 18B), the count data value of the address [D] is corrected to 24.

図23は、アドレス[C]に対する破損検出および破損修復の結果を示す図である。   FIG. 23 is a diagram showing the results of damage detection and damage repair for address [C].

ステップS313eないしステップS317e(図18AおよびB)に示したようにして、アドレス[C]のカウントデータの値が、23に修正される。   As shown in steps S313e to S317e (FIGS. 18A and 18B), the count data value of the address [C] is corrected to 23.

図24は、アドレス[B]に対する破損検出および破損修復の結果を示す図である。   FIG. 24 is a diagram showing the results of damage detection and damage repair for address [B].

ステップS319eないしステップS321e(図18AおよびB)に示したようにして、アドレス[B]は、修正不要であると判断される。   As shown in steps S319e to S321e (FIGS. 18A and 18B), it is determined that the address [B] does not need to be corrected.

図25は、アドレス[A]に対する破損検出および破損修復の結果を示す図である。   FIG. 25 is a diagram showing the results of damage detection and damage repair for address [A].

ステップS323eないしステップS327e(図18AおよびB)に示したようにして、アドレス[A]のカウントデータの値が、21に修正され、カウントデータ修復処理は終了する。   As shown in steps S323e to S327e (FIGS. 18A and 18B), the value of the count data at the address [A] is corrected to 21, and the count data restoration process ends.

{具体例2}
図26は、具体例2におけるカウントデータの値、および、極性情報データの値の一覧である。
{Specific Example 2}
FIG. 26 is a list of count data values and polarity information data values in the second specific example.

ステップS101(図12)に示したように、カウントデータソート部27aは、カウントデータの大きさでアドレスを並べ替える。   As shown in step S101 (FIG. 12), the count data sorting unit 27a rearranges the addresses according to the size of the count data.

図27は、並べ替えられたアドレスの並び方、ならびに、各アドレスに記録されているカウントデータの値および各アドレスに関連付けられた極性情報データの値の一覧である。   FIG. 27 is a list of how the rearranged addresses are arranged, the value of count data recorded at each address, and the value of polarity information data associated with each address.

ステップS103(図12)に示したように、カウントデータ差分算出部27bは、ステップS101で並べ替えられたアドレスの並び方に沿って、隣接するカウントデータの値の間の差分値を算出する。   As shown in step S103 (FIG. 12), the count data difference calculation unit 27b calculates a difference value between adjacent count data values along the arrangement of the addresses rearranged in step S101.

図28は、算出されたカウントデータ差分値の一覧である。   FIG. 28 is a list of calculated count data difference values.

ステップS105(図12)に示したように、修復処理実行部27cは、各アドレスに関連付けられた極性情報データをステップS101で並び替えされたアドレスの並び方に沿って見た場合に隣接した極性情報データ値間で変化が生じている箇所の数を求める。具体例2においては、変化箇所数は、1である(図27参照。)。   As shown in step S105 (FIG. 12), the restoration processing execution unit 27c uses adjacent polarity information when the polarity information data associated with each address is viewed along the arrangement of the addresses rearranged in step S101. Find the number of locations where there is a change between data values. In the specific example 2, the number of change points is 1 (see FIG. 27).

従って、処理は、ステップS201(図12)へ移行する。ステップS201(図12および図13)においては、アドレスの並び方(図27)が、アドレス組み合わせGr.[3](図9)と一致し、かつ、カウントデータ間の差分値(図28)が、全て1ではないから、処理は、ステップS301cへ移行する。   Therefore, the process proceeds to step S201 (FIG. 12). In step S201 (FIGS. 12 and 13), the address arrangement (FIG. 27) is the address combination Gr. [3] Since it matches (FIG. 9) and the difference values between the count data (FIG. 28) are not all 1, the process proceeds to step S301c.

ステップS303c(図16AおよびB)において、アドレス[C]の極性情報データの値に基づく判定が行われ、該判定の結果により、処理はステップS305cへ移行する。   In step S303c (FIGS. 16A and 16B), a determination is made based on the value of the polarity information data of the address [C], and the process proceeds to step S305c depending on the result of the determination.

ステップS305c(図16AおよびB)に示したように、これ以降、修復処理実行部27cは、アドレス[C]のカウントデータおよびアドレス[C]に関連付けられた極性情報データを基準として、アドレス組み合わせGr.[3](図9)および極性情報組み合わせGr.[5](図10)に従って、カウントデータの値および極性情報データの値を修正する。   As shown in step S305c (FIGS. 16A and 16B), thereafter, the restoration processing execution unit 27c uses the address combination Gr based on the count data of the address [C] and the polarity information data associated with the address [C]. . [3] (FIG. 9) and polarity information combination Gr. [5] The value of the count data and the value of the polarity information data are corrected according to (FIG. 10).

図29は、アドレス[B]に対する破損検出および破損修復の結果を示す図である。   FIG. 29 is a diagram showing the results of damage detection and damage repair for address [B].

ステップS307cないしステップS311c(図16AおよびB)に示したようにして、アドレス[C]は、修正不要であると判断される。   As shown in steps S307c to S311c (FIGS. 16A and 16B), it is determined that the address [C] does not need to be corrected.

図30は、アドレス[A]に対する破損検出および破損修復の結果を示す図である。   FIG. 30 is a diagram showing the results of damage detection and damage repair for address [A].

ステップS313cないしステップS317c(図16AおよびB)に示したようにして、アドレス[A]のカウントデータの値が、52に修正される。   As shown in steps S313c to S317c (FIGS. 16A and 16B), the count data value of the address [A] is corrected to 52.

図31は、アドレス[E]に対する破損検出および破損修復の結果を示す図である。   FIG. 31 is a diagram showing the results of damage detection and damage repair for address [E].

ステップS319cないしステップS321c(図16AおよびB)に示したようにして、アドレス[E]のカウントデータの値が、51に修正され、加えて、アドレス[E]に関連付けられた極性情報データの値が0に反転される。   As shown in steps S319c to S321c (FIGS. 16A and B), the count data value of the address [E] is corrected to 51, and in addition, the value of the polarity information data associated with the address [E] Is inverted to 0.

図32は、アドレス[D]に対する破損検出および破損修復の結果を示す図である。   FIG. 32 is a diagram showing the results of damage detection and damage repair for address [D].

ステップS323cないしステップS327c(図16AおよびB)に示したようにして、アドレス[D]のカウントデータの値が、50に修正され、カウントデータ修復処理は終了する。   As shown in steps S323c to S327c (FIGS. 16A and B), the value of the count data at the address [D] is corrected to 50, and the count data restoration process is completed.

{具体例3}
具体例3は、2つのアドレスで指定される記憶領域を用いてカウントデータを記録するカウントデータの記録形態について、説明する。
{Specific Example 3}
Specific Example 3 describes a count data recording form in which count data is recorded using a storage area specified by two addresses.

図33は、記憶装置7において、2つのアドレスによって指定される記憶領域のデータ構成を示す図である。   FIG. 33 is a diagram illustrating a data configuration of a storage area specified by two addresses in the storage device 7.

2つのアドレス(アドレス[X1]とアドレス[X2])で特定される記憶領域は、さらに極性情報データを保持する極性情報部33pと、カウントデータの上位ビットを保持するカウントデータ上位部分記憶部33uと、カウントデータの下位ビットを保持するカウントデータ下位部分記憶部33lと、に区分される。極性情報データ記憶部33pは、Pビットのビット幅を有し、カウントデータ上位部分記憶部33uは、M−Pビットのビット幅を有し、カウントデータ下位部分記憶部33lは、Mビットのビット幅を有する。   The storage area specified by the two addresses (address [X1] and address [X2]) further includes a polarity information section 33p that holds polarity information data and a count data upper partial storage section 33u that holds upper bits of count data. And a count data lower part storage unit 33l that holds lower bits of count data. The polarity information data storage unit 33p has a bit width of P bits, the count data upper part storage unit 33u has a bit width of MP bits, and the count data lower part storage unit 33l has M bit bits. Have a width.

図34は、具体例3におけるカウントデータ下位部分の値およびカウントデータ上位部分の値ならびに極性情報データの値の一覧である。   FIG. 34 is a list of values of the lower part of count data, values of the upper part of count data, and values of polarity information data in specific example 3.

図35は、具体例3におけるカウントデータの値、および、極性情報データの値の一覧である。このように、各カウントデータの値は、2つのアドレスに記憶されたデータを組み合わせて1つのカウントデータとして取り扱い、各カウントデータの値に(各2つずつのアドレスに)1つの極性情報データが関連付けられている。   FIG. 35 is a list of count data values and polarity information data values in the third specific example. In this way, the value of each count data is handled as one count data by combining the data stored at two addresses, and one polarity information data is assigned to each count data value (for each two addresses). Associated.

ステップS101(図12)に示したように、カウントデータソート部27aは、カウントデータの大きさでアドレスを並べ替える。   As shown in step S101 (FIG. 12), the count data sorting unit 27a rearranges the addresses according to the size of the count data.

図36は、並べ替えられた統合アドレスの並び方、ならびに、各統合アドレスに記録されているカウントデータの値および各統合アドレスに関連付けられた極性情報データの値の一覧である。ここでは、1つのカウントデータを構成するデータが保持される2つのアドレスを纏めて統合アドレスと称する。   FIG. 36 is a list of rearranged integrated addresses, a list of count data values recorded in each integrated address, and polarity information data values associated with each integrated address. Here, two addresses at which data constituting one count data is held are collectively referred to as an integrated address.

ステップS103(図12)に示したように、カウントデータ差分算出部27bは、ステップS101で並べ替えられた統合アドレスの並び方に沿って、隣接するカウントデータの値の間の差分値を算出する。   As shown in step S103 (FIG. 12), the count data difference calculation unit 27b calculates a difference value between adjacent count data values along the arrangement of the integrated addresses rearranged in step S101.

図37は、算出されたカウントデータ差分値の一覧である。   FIG. 37 is a list of calculated count data difference values.

ステップS105(図12)に示したように、修復処理実行部27cは、各統合アドレスに関連付けられた極性情報データをステップS101で並び替えされた統合アドレスの並び方に沿って見た場合に隣接した極性情報データ値間で変化が生じている箇所の数を求める。具体例3においては、変化箇所数は、3である(図36参照。)。   As shown in step S105 (FIG. 12), the restoration processing execution unit 27c is adjacent when the polarity information data associated with each integrated address is viewed along the arrangement of the integrated addresses rearranged in step S101. Find the number of locations where there is a change between the polarity information data values. In the specific example 3, the number of change points is 3 (see FIG. 36).

従って、処理は、ステップS111(図12)へ移行する。ステップS111においては、カウントデータ間差分値が全て1であることから、ステップS201(図12および図13)へ移行する。ステップS201においては、アドレスの並び方(図36)が、アドレス組み合わせGr.[1]〜[5](図9)のいずれとも一致せず、かつ、最も大きなカウントデータが記録されている統合アドレスが[B]であるから、処理は、ステップS301bへ移行する。   Therefore, the process proceeds to step S111 (FIG. 12). In step S111, since all the difference values between the count data are 1, the process proceeds to step S201 (FIGS. 12 and 13). In step S201, the address arrangement method (FIG. 36) is the address combination Gr. Since the integrated address where [1] to [5] (FIG. 9) does not match and the largest count data is recorded is [B], the process proceeds to step S301b.

ステップS303b(図15AおよびB)において、アドレス[B]の極性情報データの値に基づく判定が行われ、該判定の結果により、処理はステップS305bへ移行する。   In step S303b (FIGS. 15A and 15B), a determination is made based on the value of the polarity information data at address [B], and the process proceeds to step S305b depending on the result of the determination.

ステップS305b(図15AおよびB)に示したように、これ以降、修復処理実行部27cは、アドレス[B]のカウントデータおよびアドレス[B]に関連付けられた極性情報データを基準として、アドレス組み合わせGr.[2](図9)および極性情報組み合わせGr.[3](図10)に従って、カウントデータの値および極性情報データの値を修正する。   As shown in step S305b (FIGS. 15A and 15B), thereafter, the restoration processing execution unit 27c uses the address combination Gr based on the count data of the address [B] and the polarity information data associated with the address [B]. . [2] (FIG. 9) and polarity information combination Gr. [3] Correct the count data value and the polarity information data value according to FIG.

図38は、アドレス[A]に対する破損検出および破損修復の結果を示す図である。   FIG. 38 is a diagram showing the results of damage detection and damage repair for address [A].

ステップS307bないしステップS311b(図15AおよびB)に示したようにして、統合アドレス[A]のカウントデータの値が、65536に修正され、加えて、統合アドレス[A]に関連付けられた極性情報データの値が1に反転される。   As shown in steps S307b to S311b (FIGS. 15A and 15B), the count data value of the integrated address [A] is corrected to 65536, and in addition, the polarity information data associated with the integrated address [A] Is inverted to 1.

図39は、アドレス[E]に対する破損検出および破損修復の結果を示す図である。   FIG. 39 is a diagram showing the results of damage detection and damage repair for address [E].

ステップS313bないしステップS317b(図15AおよびB)に示したようにして、アドレス[E]のカウントデータの値が、65535に修正される。   As shown in steps S313b to S317b (FIGS. 15A and 15B), the count data value of the address [E] is corrected to 65535.

図40は、アドレス[D]に対する破損検出および破損修復の結果を示す図である。   FIG. 40 is a diagram showing the results of damage detection and damage repair for address [D].

ステップS319bないしステップS321b(図15AおよびB)に示したようにして、アドレス[D]のカウントデータの値が、65534に修正され、加えて、アドレス[D]に関連付けられた極性情報データの値が0に反転される。   As shown in steps S319b to S321b (FIGS. 15A and 15B), the count data value of the address [D] is corrected to 65534, and in addition, the value of the polarity information data associated with the address [D] Is inverted to 0.

図41は、アドレス[C]に対する破損検出および破損修復の結果を示す図である。   FIG. 41 is a diagram showing the results of damage detection and damage repair for address [C].

ステップS323bないしステップS327b(図15AおよびB)に示したようにして、アドレス[C]のカウントデータの値が、65533に修正され、カウントデータ修復処理は終了する。   As shown in steps S323b to S327b (FIGS. 15A and 15B), the value of the count data at the address [C] is corrected to 65533, and the count data restoration process ends.

{具体例4}
図42は、具体例4におけるカウントデータの値、および、極性情報データの値の一覧である。本具体例4は、カウントデータの破損が、修復不可能な場合の例である。この場合、修復処理実行部27cは、修復処理を実行せずに、カウントデータの異常を通知する出力を行って、処理を終了する。
{Specific Example 4}
FIG. 42 is a list of count data values and polarity information data values in the fourth specific example. The fourth specific example is an example in the case where the damage of the count data cannot be repaired. In this case, the repair process execution unit 27c performs an output notifying the abnormality of the count data without executing the repair process, and ends the process.

ステップS101(図12)に示したように、カウントデータソート部27aは、カウントデータの大きさでアドレスを並べ替える。   As shown in step S101 (FIG. 12), the count data sorting unit 27a rearranges the addresses according to the size of the count data.

図43は、並べ替えられたアドレスの並び方、ならびに、各アドレスに記録されているカウントデータの値および各アドレスに関連付けられた極性情報データの値の一覧である。   FIG. 43 is a list of rearranged addresses, count data values recorded at each address, and polarity information data values associated with each address.

ステップS103(図12)に示したように、カウントデータ差分算出部27bは、ステップS101で並べ替えられたアドレスの並び方に沿って、隣接するカウントデータの値の間の差分値を算出する。   As shown in step S103 (FIG. 12), the count data difference calculation unit 27b calculates a difference value between adjacent count data values along the arrangement of the addresses rearranged in step S101.

図44は、算出されたカウントデータ差分値の一覧である。   FIG. 44 is a list of calculated count data difference values.

ステップS105(図12)に示したように、修復処理実行部27cは、各アドレスに関連付けられた極性情報データをステップS101で並び替えされたアドレスの並び方に沿って見た場合に隣接した極性情報データ値間で変化が生じている箇所の数を求める。具体例4においては、変化箇所数は、4である(図43参照。)。   As shown in step S105 (FIG. 12), the restoration processing execution unit 27c uses adjacent polarity information when the polarity information data associated with each address is viewed along the arrangement of the addresses rearranged in step S101. Find the number of locations where there is a change between data values. In the fourth specific example, the number of change points is four (see FIG. 43).

従って、処理は、ステップS111(図12)へ移行する。ステップS111においては、1でないカウントデータ間差分値が存在し、アドレスの並び方(図36)が、アドレス組み合わせGr.[1]〜[5](図9)のいずれとも一致しないから、処理は、ステップS113へ移行する。   Therefore, the process proceeds to step S111 (FIG. 12). In step S111, there is a difference value between count data other than 1, and the arrangement of addresses (FIG. 36) is an address combination Gr. Since it does not match any of [1] to [5] (FIG. 9), the process proceeds to step S113.

ステップS113において、修復処理実行部27cは、正しく修復できないデータ破損が生じていると判断し、その旨を示唆する情報を出力し、処理を終了する。   In step S113, the repair processing execution unit 27c determines that data corruption that cannot be repaired correctly has occurred, outputs information indicating that, and ends the processing.

<まとめ>
以上、本発明にかかるカウントデータ記録装置について、カウントデータの記録に用いるアドレスを5個として説明した。だが、本発明は、5個以外の個数のアドレスをもちいてカウントデータを記録することも可能である。その場合も、カウントデータの記録の方法、カウントデータの破損の検出の方法、カウントデータの破損の修復の方法は、上で述べた方法と同様にすればよい。当業者にとってその具体的態様は、上で述べた5個のアドレスをもちいた場合の説明から明らかであろう。
<Summary>
The count data recording apparatus according to the present invention has been described above assuming that five addresses are used for recording count data. However, according to the present invention, count data can be recorded using addresses other than five. In this case, the count data recording method, the count data corruption detection method, and the count data corruption repair method may be the same as described above. The specific embodiment will be apparent to those skilled in the art from the description in the case of using the five addresses described above.

本発明において、カウントデータを記憶する記憶装置7は、特に限定されない。記憶装置7は、例えば、EEPROMである。   In the present invention, the storage device 7 for storing count data is not particularly limited. The storage device 7 is, for example, an EEPROM.

記憶装置7においては、極性情報データを記録することなしに、通常のデータ記録を行うマスクエリアを設けてよい。
マスクエリアとは、カウントデータを記憶するための記憶領域とは別の記憶領域であって、極性情報データと関連付けされない記憶領域を指す。
記憶装置のマスクエリアにおいては、極性情報データの反転を伴わない、データの書き込みがなされる。このように、本発明においては、記憶装置は、カウントデータを、極性情報データと関連付けて記憶するための記憶領域と、通常のデータの読み出しおよび書き込みのための記憶領域を備えることができ、記憶装置内の記憶領域を余すところなしに、効率的に利用することも可能である。本発明においては、マスクエリアは、記憶装置内にアドレスを単位として設定可能である。
The storage device 7 may be provided with a mask area for performing normal data recording without recording polarity information data.
The mask area refers to a storage area that is different from the storage area for storing the count data and that is not associated with the polarity information data.
In the mask area of the storage device, data is written without reversing the polarity information data. Thus, in the present invention, the storage device can include a storage area for storing count data in association with polarity information data, and a storage area for reading and writing normal data. It is also possible to efficiently use the storage area in the apparatus without leaving any space. In the present invention, the mask area can be set in the storage device in units of addresses.

本発明は、記憶装置を用いたカウントデータの記録を行う装置に関する。本発明は、特に、記憶装置の繰り返し書き込み可能な回数を超えてカウントデータの記録を行う上で有用である。   The present invention relates to an apparatus for recording count data using a storage device. The present invention is particularly useful for recording count data beyond the number of times that the storage device can be repeatedly written.

本発明の実施の形態によるカウントデータ記録装置(MFP1)の斜視図1 is a perspective view of a count data recording apparatus (MFP 1) according to an embodiment of the present invention. 感光体ユニット5の斜視図Perspective view of the photoreceptor unit 5 MFP1のハードウェア構成を示すブロック図Block diagram showing the hardware configuration of MFP 1 MFP1の機能的構成を示すブロック図Block diagram showing the functional configuration of the MFP 1 記憶装置7の、1つのアドレスで指定される記憶領域のデータ構成図Data configuration diagram of storage area specified by one address of storage device 7 カウントデータの記録の例図Example of count data recording カウントデータの値の大きさで降順に並べ替えたアドレスの並び方の図Illustration of how addresses are arranged in descending order according to the size of the count data value 正常なカウントデータについて、その値の降順で並べたときのカウントデータ間の差分値を示す図The figure which shows the difference value between count data when arranging normal count data in descending order of the value アドレスをカウントデータの降順で並べ替えた時に起こり得るアドレスの並び方の一覧List of possible address arrangements when addresses are sorted in descending order of count data アドレスをカウントデータの降順で並べ替えた時に起こり得る各アドレスと関連付けられた極性情報データの並び方の一覧List of how the polarity information data is associated with each address that can occur when the addresses are sorted in descending order of the count data アドレス組み合わせと、極性情報組み合わせとの組み合わせを示す図Diagram showing combinations of address combinations and polarity information combinations カウントデータ破損の検出および修復のメインフローのフローチャートFlow chart of main flow of detection and repair of count data corruption カウントデータ修復処理選択処理のフローチャートFlow chart of count data restoration process selection process カウントデータ修復処理選択処理のフローチャートFlow chart of count data restoration process selection process カウントデータ修復処理AのフローチャートFlow chart of count data restoration processing A カウントデータ修復処理AのフローチャートFlow chart of count data restoration processing A カウントデータ修復処理BのフローチャートFlow chart of count data restoration process B カウントデータ修復処理BのフローチャートFlow chart of count data restoration process B カウントデータ修復処理CのフローチャートFlow chart of count data restoration process C カウントデータ修復処理CのフローチャートFlow chart of count data restoration process C カウントデータ修復処理DのフローチャートFlow chart of count data restoration process D カウントデータ修復処理DのフローチャートFlow chart of count data restoration process D カウントデータ修復処理EのフローチャートFlow chart of count data restoration processing E カウントデータ修復処理EのフローチャートFlow chart of count data restoration processing E カウントデータ修復処理具体例1における修復処理前のカウントデータおよび極性情報データの表Table of count data and polarity information data before repair processing in count data repair processing example 1 並び替えられたカウントデータおよび極性情報データの表Sorted count data and polarity information data table カウントデータ差分値の表Count data difference table カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing カウントデータ修復処理具体例2における修復処理前のカウントデータおよび極性情報データの表Table of count data and polarity information data before repair processing in count data repair processing example 2 並び替えられたカウントデータおよび極性情報データの表Sorted count data and polarity information data table カウントデータ差分値の表Count data difference table カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing 記憶装置7の、2つのアドレスで指定される記憶領域のデータ構成図Data structure diagram of storage area specified by two addresses of storage device 7 カウントデータ修復処理具体例3における修復処理前のカウントデータおよび極性情報データの表Table of count data and polarity information data before the repair process in the specific example 3 of the count data repair process カウントデータ修復処理具体例3における修復処理前のカウントデータおよび極性情報データの表Table of count data and polarity information data before the repair process in the specific example 3 of the count data repair process 並び替えられたカウントデータおよび極性情報データの表Sorted count data and polarity information data table カウントデータ差分値の表Count data difference table カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing カウントデータ修復処理の過程を示す図The figure which shows the process of count data restoration processing カウントデータ修復処理具体例4における修復処理前のカウントデータおよび極性情報データの表Table of count data and polarity information data before repair processing in count data repair processing example 4 並び替えられたカウントデータおよび極性情報データの表Sorted count data and polarity information data table カウントデータ差分値の表Count data difference table

符号の説明Explanation of symbols

1・・・ カウントデータ記録装置(デジタル複合機)
3・・・ トナーカートリッジ
5・・・ 感光体ユニット
7・・・ 記憶装置
11・・・ 中央処理装置
13・・・ ランダム・アクセス・メモリ
15・・・ リード・オンリ・メモリ
17・・・ I/O LSI
19o・・ 出力デバイス
19i・・ 入力デバイス
21・・・ コンピュータ
23・・・ 制御部
25・・・ データ書込部
25a・・ カウントデータ書込部
25b・・ 極性情報データ反転部
27・・・ データ修復部
27a・・ カウントデータソート部
27b・・ カウントデータ差分算出部
27c・・ 修復処理実行部
29・・・ データ読出部
31・・・ 設定データ保持部
33・・・ カウントデータ記憶部
33l・・ カウントデータ下位部分記憶部
33p・・ 極性情報データ記憶部
33u・・ カウントデータ上位部分記憶部
1 ... Count data recording device (digital multifunction device)
DESCRIPTION OF SYMBOLS 3 ... Toner cartridge 5 ... Photoconductor unit 7 ... Storage device 11 ... Central processing unit 13 ... Random access memory 15 ... Read only memory 17 ... I / O LSI
19o ... Output device 19i ... Input device 21 ... Computer 23 ... Control unit 25 ... Data writing unit 25a ... Count data writing unit 25b ... Polarity information data reversing unit 27 ... Data Repair unit 27a ... Count data sort unit 27b ... Count data difference calculation unit 27c ... Repair processing execution unit 29 ... Data read unit 31 ... Setting data holding unit 33 ... Count data storage unit 33l ... Count data lower part storage unit 33p... Polarity information data storage unit 33u .. Count data upper part storage unit

Claims (7)

所定値から所定幅で単調に変化するカウント値をカウントデータとして記録装置に記録するカウントデータ記録装置であって、
前記カウントデータを記憶する記憶部と、
前記カウントデータを前記記憶部に書き込むデータ書込部と、
前記カウントデータを前記記憶部から読み出すデータ読出部と、
前記記憶部に記憶されたカウントデータの破損を検出し、該破損を修復するデータ修復部と、を有し、
前記記憶部は、
位置特定識別子によって特定され、カウントデータを記憶するカウントデータ記憶部を複数個と、前記カウントデータ記憶部のそれぞれと関連付けされ、第1値および第2値を示す2種類のデータから1つを択一的に記憶する極性情報データ記憶部を前記カウントデータ記憶部の個数と同数だけ備え、
前記データ書込部は、
前記複数個のカウントデータ記憶部のうちから所定の順序で循環的に1つのカウントデータ記憶部に対して前記カウントデータを書き込むカウントデータ書込部と、前記カウントデータ書込部がカウントデータを書き込んだカウントデータ記憶部と関連付けされた極性情報データ記憶部が記憶するデータの内容を、前記第1値と第2値との間で反転させる極性情報データ反転部と、を備え、
前記データ修復部は、
前記データ読出部が前記記憶部から読み出した、前記複数個のカウントデータ記憶部に記憶された複数のカウントデータについて、カウントデータの大きさで、カウントデータ記憶部の位置特定識別子を並べるカウントデータソート部と、
前記カウントデータソート部が並べた位置特定識別子の順に沿って、互いに隣接するカウントデータ間の差分値を算出するカウントデータ差分算出部と、
前記カウントデータソート部が並べた順に沿った位置特定識別子の並び方、前記カウントデータソート部が並べた順に沿った前記カウントデータ間の差分値の並び方、および、前記カウントデータソート部が並べた順に沿った前記極性情報データの並び方、に基づいて、前記記憶部に記憶された複数のカウントデータの破損を検出して当該破損を修復する修復処理実行部と、を備える、カウントデータ記録装置。
A count data recording device that records a count value monotonously changing from a predetermined value at a predetermined width as count data in a recording device,
A storage unit for storing the count data;
A data writing unit for writing the count data to the storage unit;
A data reading unit for reading the count data from the storage unit;
A data restoration unit that detects corruption of the count data stored in the storage unit and repairs the corruption;
The storage unit
A plurality of count data storage units that are specified by the position specifying identifier and store count data are associated with each of the count data storage units, and one of two types of data indicating the first value and the second value is selected. The number of polarity information data storage units to be stored in the same number as the number of count data storage units,
The data writing unit
A count data writing unit that writes the count data to one count data storage unit cyclically in a predetermined order from the plurality of count data storage units, and the count data writing unit writes the count data A polarity information data inversion unit for inverting the content of data stored in the polarity information data storage unit associated with the count data storage unit between the first value and the second value,
The data restoration unit
Count data sort in which the position identification identifiers of the count data storage unit are arranged according to the size of the count data with respect to the plurality of count data stored in the plurality of count data storage units read from the storage unit by the data reading unit And
A count data difference calculating unit that calculates a difference value between count data adjacent to each other along the order of the position identification identifiers arranged by the count data sorting unit
According to the order in which the position identification identifiers are arranged in the order in which the count data sort unit is arranged, the way in which the difference values between the count data are arranged in the order in which the count data sort unit is arranged, A count data recording apparatus comprising: a repair processing execution unit that detects damage of a plurality of count data stored in the storage unit and repairs the damage based on the arrangement of the polarity information data.
1つの前記位置特定識別子が特定する前記カウントデータ記憶部は、2つのメモリアドレスによって特定される2つの記憶領域を有し、前記カウントデータは、前記2つの記憶領域へ分割して記憶される、請求項1に記載のカウントデータ記録装置。   The count data storage unit specified by one position specifying identifier has two storage areas specified by two memory addresses, and the count data is divided and stored into the two storage areas. The count data recording device according to claim 1. 前記所定値は、ゼロであり、前記所定幅は、プラス1である、請求項2に記載のカウントデータ記録装置。   The count data recording apparatus according to claim 2, wherein the predetermined value is zero and the predetermined width is plus one. 前記所定値は、ゼロを含まない自然数であり、前記所定幅は、マイナス1である、請求項2に記載のカウントデータ記録装置。   The count data recording apparatus according to claim 2, wherein the predetermined value is a natural number not including zero, and the predetermined width is minus one. 前記カウントデータソート部は、カウントデータの大きさの降順で、カウントデータ記憶部の位置特定識別子を並べる、請求項3に記載のカウントデータ記録装置。   The count data recording device according to claim 3, wherein the count data sorting unit arranges the position specifying identifiers of the count data storage unit in descending order of the size of the count data. 前記カウントデータソート部は、カウントデータの大きさの昇順で、カウントデータ記憶部の位置特定識別子を並べる、請求項4に記載のカウントデータ記録装置。   The count data recording device according to claim 4, wherein the count data sorting unit arranges the position identification identifiers of the count data storage unit in ascending order of the size of the count data. 前記修復処理実行部は、前記カウントデータソート部が並べた順に沿って並べた前記極性情報データにおいて、極性情報データの値が変化する箇所の数を求め、求めた変化する箇所の数に基づいて、前記記憶部に記憶された複数のカウントデータの破損を検出して当該破損を修復する、請求項1に記載のカウントデータ記録装置。   The restoration processing execution unit obtains the number of places where the value of the polarity information data changes in the polarity information data arranged in the order arranged by the count data sorting unit, and based on the obtained number of changed parts The count data recording device according to claim 1, wherein the count data recording device according to claim 1, wherein the count data stored in the storage unit is detected to be damaged and repaired.
JP2008160756A 2008-06-19 2008-06-19 COUNT DATA RECORDING DEVICE AND COUNT DATA RECORDING METHOD Expired - Fee Related JP5200688B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2008160756A JP5200688B2 (en) 2008-06-19 2008-06-19 COUNT DATA RECORDING DEVICE AND COUNT DATA RECORDING METHOD

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2008160756A JP5200688B2 (en) 2008-06-19 2008-06-19 COUNT DATA RECORDING DEVICE AND COUNT DATA RECORDING METHOD

Publications (2)

Publication Number Publication Date
JP2010003074A JP2010003074A (en) 2010-01-07
JP5200688B2 true JP5200688B2 (en) 2013-06-05

Family

ID=41584754

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2008160756A Expired - Fee Related JP5200688B2 (en) 2008-06-19 2008-06-19 COUNT DATA RECORDING DEVICE AND COUNT DATA RECORDING METHOD

Country Status (1)

Country Link
JP (1) JP5200688B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105095423B (en) * 2015-07-15 2018-10-09 北京奇虎科技有限公司 Enumeration data wiring method and device

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2603005B2 (en) * 1991-04-19 1997-04-23 株式会社ピーエフユー Counter using non-volatile memory
JPH11328037A (en) * 1998-05-20 1999-11-30 Toshiba Tec Corp Count value preservation device
JP2000339232A (en) * 1999-05-31 2000-12-08 Oki Data Corp Method for writing count value into nonvolatile memory
JP3947643B2 (en) * 1999-12-21 2007-07-25 株式会社ジェイテクト Data control device
JP2002229865A (en) * 2001-02-05 2002-08-16 Sony Corp Count data preserving method in electric apparatus and electric apparatus
US6792065B2 (en) * 2003-01-21 2004-09-14 Atmel Corporation Method for counting beyond endurance limitations of non-volatile memories
JP2008077135A (en) * 2006-09-19 2008-04-03 Denso Corp Arithmetic processing device and counter value operation method

Also Published As

Publication number Publication date
JP2010003074A (en) 2010-01-07

Similar Documents

Publication Publication Date Title
JP4357304B2 (en) External storage device
US20180101302A1 (en) Data Storage Device and Data Writing Method Thereof
JP2007087464A (en) Storage medium reproducing apparatus, storage medium reproducing method, and storage medium reproducing program
WO2007000862A1 (en) Memory controller, nonvolatile storage device, nonvolatile storage system, and data writing method
JP7020989B2 (en) Non-volatile storage device, memory control device, and memory control method
JP2009282923A (en) Semiconductor storage device and nonvolatile memory
CN110504002B (en) Hard disk data consistency test method and device
CN106802837A (en) A kind of method and device for updating error detection and correction ECC code
TW201833937A (en) Data storage device and block releasing method thereof
CN104658609B (en) The method and system that error correcting code for storage system is distributed
JP5200688B2 (en) COUNT DATA RECORDING DEVICE AND COUNT DATA RECORDING METHOD
JP2006004367A (en) Memory card and semiconductor device
JP4235646B2 (en) Memory controller and flash memory system
US10338984B2 (en) Storage control apparatus, storage apparatus, and storage control method
JP5915490B2 (en) Electronic control unit
JP4501881B2 (en) Memory controller and flash memory system
JP5335779B2 (en) Semiconductor recording device
JP4153535B2 (en) MEMORY CONTROLLER, FLASH MEMORY SYSTEM PROVIDED WITH MEMORY CONTROLLER, AND FLASH MEMORY CONTROL METHOD
US10318416B2 (en) Method and system for implementing a non-volatile counter using non-volatile memory
CN109087676B (en) Programming method and device of nonvolatile memory
US9021184B2 (en) Flash memory device
CN107705817A (en) Utilize the coding/decoding method, device and data-storage system of flash memory channel characteristic
JP4582078B2 (en) Memory controller, flash memory system, and flash memory control method
US9104596B2 (en) Memory system
TWI404076B (en) Memory devices and data read method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20110121

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: 20130115

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20130128

R150 Certificate of patent or registration of utility model

Ref document number: 5200688

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20160222

Year of fee payment: 3

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313111

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

LAPS Cancellation because of no payment of annual fees