JPS613528A - Error correction circuit - Google Patents

Error correction circuit

Info

Publication number
JPS613528A
JPS613528A JP12290384A JP12290384A JPS613528A JP S613528 A JPS613528 A JP S613528A JP 12290384 A JP12290384 A JP 12290384A JP 12290384 A JP12290384 A JP 12290384A JP S613528 A JPS613528 A JP S613528A
Authority
JP
Japan
Prior art keywords
code
syndrome
circuit
error
memory
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP12290384A
Other languages
Japanese (ja)
Inventor
Sumio Mori
森 澄夫
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.)
Fujifilm Holdings Corp
Original Assignee
Fuji Photo Film Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fuji Photo Film Co Ltd filed Critical Fuji Photo Film Co Ltd
Priority to JP12290384A priority Critical patent/JPS613528A/en
Publication of JPS613528A publication Critical patent/JPS613528A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To simplify the system constitution by adopting the hardware constitution to a code generation and syndrome operation having many repetitive processings and constituted with a simple circuit and adopting the software constitution for error pattern and error position calculation becoming complicated in the hardware constitution. CONSTITUTION:A digital information word group is arranged in a matrix, an error check bit is given in row and column directions and a circuit correcting an error is provided with circuits 57, 58 generating an error check bit, syndrome calculation circuit 59 and a memory 510 storing a bit and a calculation syndrome. Further, the 2nd memory 515 storing the 1st and 2nd programs executing a syndrome, code generating circuits 57, 58, a syndrome calculation circuit 59 and the 3rd memory 517 storing a program controlling the 1st memory are provided. Thus, the control of each memory is executed by microprocessors 516, 517, the hardware and software constitution are adopted to simplify the system.

Description

【発明の詳細な説明】[Detailed description of the invention]

[発明の技術分野] 本発明は、ガロア体GF(2” )の上で行う誤り訂正
方式に関し、特に内符号及び外符号をもつ二重の符号化
構造によって誤り訂正を行う方式に関するものである。 [従来技術と問題点] 誤り訂正符号化方式の中で最も訂正能力の高い方式とし
てリードソロモン(Reed Solomon)符号化
方式がよく知られている。この方式はガロア体cF(q
)の上の符号であり、q=2とすればガロア基礎体CF
(2)から導かれる層次の拡大体CF(2” )によっ
て符号化されるものである。 ここでカロア体について簡単に説明しておく。 今、1次の既約多項式P(り=0を満たす仮想的な根α
を考えるとき、q= 211個の異なる元(0,1,α
、α2.・・・α驚Q) はガロア体CF(2)の拡大体CF(2” )を構成す
る。 このとき (!隻 −り−(!−0)(冨w−t−1)はGF(2
” )の全ての元を根にもつが、このガロア体から0次
を除いた残りの元 (1,α、α2.・・・α%Q) は(、%4 =l)の元であり、(X%4−1)は巡回
多項式になる。このように0F(2” )はGF(2)
の上の1次の既約多項式P(菫)を法とする多項式環に
なっている。ここで、αは原始元と呼ばれ、(iF(2
)の上のm次の既約多項式がGF(2” )の原始元を
根として持てば、この既約多項式は原始多項式と呼ばれ
る。 (、v+  −1)は元 (1、α、α2 、・・・α村 ) を全て根にもつから次式で表わせる。 (,14−1)=υX−αi )         (
+)1m。 今、原始多項式p(りの根をαとすれば、CF(2請)
の元は、線形結合 (a、1l−1−−’ 4p・−+Bl!+ flo 
)で表わすことができ、したがって0F(2” )は0
F(2)の上のベクトル (am−+  s・・at  +aO)で表現できる。 一方、GF(2” )から0元を除いた−  元  (
!、α、 C2、・・・0粒 )は位数(2”−1)の
巡回群をなし、これらは原始元αのべき乗で表現するこ
とができる。 以上の原理を用いれば、任意の情報語Uに誤りが生じた
□ときに、その誤りを訂正もしくは検出できる符号間距
離dに符号語Cを生成することが可能となる。 符号間距離dは符号語ベクトルCI、CJの対応する位
置にある成分のうち互いに異なる成分の数であって、C
1,CJ間のハミング距離と呼ばれる。誤り訂正および
検出能力はこの距離によって決まる。この距離dが大き
い程、高い確率で2要因C1,CJを区別することがで
きる。つまり、C1,Cjが誤りによって生じるバラツ
キの範囲tを定め、受信語C′がC1,CJのいずれか
の範囲に入れば符号語が正しい符号語であると推定する
ことができCi、Cjの距離が十分離れていればその推
定値は真の値に近づくことになる。 一般に、 d≧2t+1のときにt個のシンボルの誤り
訂正、 2を個までの誤り検出が可能となる。 以上の原理を用いてガロア体CF(28)の上での誤り
訂正について説明する。 まず符号語C(x)を生成することについて述べる。 情報語U(1)、生成多項式〇(り 、符号長n、情報
長にとすれば、符号語C(りは すなわち、 C(りは、υ(り・ !rにをG(りで割
ってその余剰R(りを付加すればよい。 今、符号間距離をd=4とした場合について、生成多項
式を次式で与えるものとすれば。 C(x)=六(トαi)・(x−IM!−α)(!−α
2)”=x3+a””x2−’+alQqx+a3(t
sod’、  C8+  a’  +  C3+  C
2+1)   (3)このときR(りを求める具体的回
路例は第1図に示すようになる。 ここで、1はCF(2)の上の情報語u4 のベクトル
al=(a71・・・、ao)を格納したレジスタであ
り、このレジスタ1に情報語ulは(Oh−+、1jh
−ユ、・・・J 、Uo 、0,09O)のシーケンス
で入力される。 2−0〜2−7.3−0〜3−7.4−0〜4−7は5
od2の加算、すなわちエクスクル−シブオフ回路、5
〜7は8ビツトのレジスタであり、各エクスクル−シブ
オフ回路群2−0〜2−7.3−0〜3−7.4−0ん
4−7の出力ぞれ乗算する係数乗算器であり、これはR
OMまたはPLA(プログラマブル・ロジック・アレイ
)を用いて容易に実現できる。 エクスクル−シブオフ回路2−0〜2−7.3−0〜3
−7.4−0〜4−7では、それぞれ、レジスタ1,5
.8の内容(al)、 (ro )、(rt )と係数
乗算器8,9.10の出力(rz ・α3)、(r2拳
αAQ )、(rz 、 αIQ9)との排他的論理和
を求める。 たとえば、定数α191にrzの値として(rz) =
 a”3が入っている場合の乗算は、次のマトリックス
演算によって行なわれる。 第1図から余病多項式は R(x)=r、、、 x2+r1.x+ r6として求
めることができる。 次に、複号化において検査行列Hを定義すれば。 誤り訂正・検出のためのシンドロームSは次式によって
与えられる。 ここで、Ceは誤りを含んだ符号語ベクトル、Eは誤り
ベクトルを示す。 ここで)l@C=0であるから、シンドロームSki通
信系の雑音系列のみによって決まることが分かる。 検査行列Hは、上記生成多項式〇(x)に対応して3個
の検査語をもつ場合には、 となる。シンドロームSを求める具体的回路は例えば第
2図のように構成される。ここで11は受信符号語Cj
のベクトル(a?、・・・、ao)を格納するレジスタ
であり、受信符号語岨Cfは(Cn−1”IW’ ・・
・Cs +C’o、)のシーケンスでレジスタ11に入
力される。 12−D〜12−7はエクスクル−シブオ
フ回路であり、その出力を8ビツトレジスタに格納する
。14はレジスタ13の内容(r)にαノ を乗算する
係数乗算器である。エクスクル−シブオフ回路12−0
〜12−7ではレジスタ11の内容(a7.・・・、a
o)と係数乗算器14の出力(r・α))との排他的論
理和を求める。 シンドロームS、はレジスタ13上に求まるCI=O。 l、2)。本例ではシンドロームは3個しか存在しない
から、一般には1個の誤り訂正しかできないが、今、何
らかの手段で受信符号語C’(i)の誤り位置が既知で
あるとすれば、この場合に限って3個の誤りまで訂正す
ることができる。 今、受信符号群(α−1+Cに2.・・・C; 、Go
 )の中で3個所の誤り位置をLJ+k、誤りパターン
を@1゜ej +I!にとすれば が与えられる。W4り位置が既知であるとすれば、誤り
パターンは次式から得られる。 したがって、 CB −C’l +el C,−C,+@j CI(−c′に+lik によって3個所までの誤りが訂正できる。誤り位置が未
知の場合は(8)式からは誤り位置iおよび誤りパター
ンe1だけを求めることができる。 第3図は符号化構造を示すもので、行方向に情報語(■
h−+−Us +UO)と検査語の(Pt 、Po )
で内符号を構成し1列方向に情報語(υv−1・・Us
 、Uo )と検査語(P2 、Pt 、Po )で外
符号を構成する。 内符号および外符号に対して生成多項式〇(りは で与えるものとする。 このとき、行方向および列方向に対して、符号語C(り
は、 で与えられる。復糎化においては、まず内符号によって
各行毎に符号語(υ1.−1・・・ul、υ。、Pl、
Po )の内、1語の誤り訂正を行い、ここで訂正でき
なかった各行にはエラーフラッグを付しておき、次に外
符号によってエラーフラッグのついた各行のアドレスを
誤り位置として各列毎に3個までの誤り訂正を行う。 内符号においてシンドロームSは次式で与えられる。 符号語C(菫)の中の誤り位置なi、誤りパターンをe
l とすれば、 S6 *el 、Sl−a’−e5 、 a’ −81
−/So  (11)となり、原始元αのべき乗iが誤
り位置であり、Sが誤りパターンとなる。したがって C1=CI+J から誤りは訂正される。 ここで、(!j□ −0,Sl #0)−(So″R,
Os Ss −0)および(i)n−1)のときは、そ
の行の符号語には2個以上の誤りがあったことになり、
訂正不能としてその行に対してエラーフラッグをつける
。各行の誤り訂正が終了した後、次は外符号によって各
列毎に3個までの誤り訂正を行う、この場合、誤り位置
1+J+’は内符号によって訂正できなかった行アドレ
スとして既に与えられているので、各列毎の誤りパター
ンei +eJ +ekを式(7)から算出すればよい
、外符号のシンドロームは式(5)によって与えられる
。 次に式(?) 、(11)における演算の一般的規則に
ついて述べる。 αi+αjは元αlおよびαjをベクトル表現したとき
の嘗od2の加算であり、エクスクル−シブオア回路で
実現できる。一方、αtgは元αのべき乗’+jのmo
d255における加減算であり、10進数の加減算回路
で実現できるが、 Ami+j≧255のときには A=A−255 A=i−j(0のときには A=255−A とする必要がある。また、αI、αjのいずれか一方が
0元のときは、 αtt3ヨ0 としなければならない。 シンドロームso 、s、 J!および誤り位置1.j
。 には演算内容によって夫々ベクトル変換、べき乗ベクト
ルに変換して法2の加算を行ない、α1゜αjは++J
のベクトルなべき乗に変換して法255の加算を行う。 以上のように、式(2)および(5)のような符号語生
成およびシンドロームの計算は繰返し処理が多いものの
回路構成は簡単であるハ式(8)のような誤りパターン
および誤り位置の算出については、原始元αのべき乗で
計算する必要のある演算を回路上で実現することは回路
規模および処理シーケンスの点でかなり複雑になること
が分かる。したがって、これらすべての演算を/1−ド
で実現するのでは、回路全体の構成が複雑になり、他方
、これらの演算をすべてソフトで実現するのでは、繰返
し処理の多い演算によって全体としての処理速度が低下
する。
[Technical Field of the Invention] The present invention relates to an error correction method performed on a Galois field GF(2''), and particularly relates to a method for error correction using a double encoding structure having an inner code and an outer code. [Prior art and problems] The Reed Solomon coding method is well known as a method with the highest correction ability among error correction coding methods.This method uses a Galois field cF(q
), and if q=2, the Galois fundamental field CF
It is encoded by the layer-order extension field CF(2'') derived from (2). Here, we will briefly explain the Calois field. The virtual root α that satisfies
When considering q = 211 different elements (0, 1, α
, α2. ...α surprise Q) constitutes the extension field CF(2”) of the Galois field CF(2). In this case, (!ship -ri-(!-0)(touw-t-1) is GF( 2
”), but the remaining elements (1, α, α2...α%Q) after removing the 0th order from this Galois field are elements of (, %4 = l). , (X%4-1) becomes a cyclic polynomial. In this way, 0F(2”) becomes GF(2)
It is a polynomial ring modulo the first-order irreducible polynomial P (violet) over . Here, α is called a primitive element, (iF(2
) is called a primitive polynomial if it has a primitive element of GF(2") as a root. (, v+ -1) has the element (1, α, α2, ... α village ) as roots, so it can be expressed by the following formula: (,14-1)=υX-αi ) (
+) 1m. Now, if the root of the primitive polynomial p(ri is α), then CF(2 lines)
The elements of are linear combinations (a, 1l-1--' 4p・-+Bl!+ flo
), so 0F(2”) is 0
It can be expressed as a vector (am-+ s...at +aO) on F(2). On the other hand, − Yuan (
! , α, C2, ...0 grains) form a cyclic group of order (2"-1), and these can be expressed as powers of the primitive element α. Using the above principle, any information can be When an error occurs in word U, it is possible to generate code word C at an inter-code distance d that allows the error to be corrected or detected. The inter-code distance d is the corresponding position of code word vectors CI and CJ. The number of mutually different components among the components in C
1. It is called the Hamming distance between CJ. Error correction and detection capabilities depend on this distance. The larger the distance d, the higher the probability that the two factors C1 and CJ can be distinguished. In other words, if C1 and Cj define the range t of variation caused by errors, and the received word C' falls within the range of either C1 or CJ, it can be estimated that the codeword is correct; If the distance is sufficiently far, the estimated value will be close to the true value. Generally, when d≧2t+1, error correction of t symbols and up to 2 error detection are possible. Error correction on the Galois field CF (28) will be explained using the above principle. First, generation of code word C(x) will be described. If we take the information word U(1), the generator polynomial 〇(ri), the code length n, and the information length, then the code word C(ri is C(ri, υ(ri, !r divided by G(ri). Then, add the surplus R(ri). Now, when the intersymbol distance is d=4, let us give the generator polynomial as the following formula: C(x)=6(tαi)・( x-IM!-α)(!-α
2)"=x3+a""x2-'+alQqx+a3(t
sod', C8+ a' + C3+ C
2+1) (3) In this case, a concrete example of a circuit for calculating R(ri) is shown in FIG. 1. Here, 1 is the vector al of the information word u4 on CF(2) = (a71... , ao), and the information word ul in this register 1 is (Oh-+, 1jh
-U, . . . J, Uo, 0,09O). 2-0~2-7.3-0~3-7.4-0~4-7 is 5
od2 addition, i.e. exclusive off circuit, 5
7 is an 8-bit register, and is a coefficient multiplier that multiplies the outputs of the exclusive off circuit groups 2-0 to 2-7.3-0 to 3-7.4-0 and 4-7. , this is R
It can be easily realized using OM or PLA (programmable logic array). Exclusive off circuit 2-0~2-7.3-0~3
-7.4-0 to 4-7, registers 1 and 5, respectively.
.. Find the exclusive OR of the contents (al), (ro), (rt) of 8 and the outputs of coefficient multipliers 8, 9.10 (rz ・α3), (r2 fist αAQ), (rz, αIQ9) . For example, if the constant α191 is the value of rz (rz) =
Multiplication when a”3 is included is performed by the following matrix operation. From Fig. 1, the residual disease polynomial can be found as R(x) = r, , x2 + r1.x + r6. Next, If we define the parity check matrix H in decoding, the syndrome S for error correction/detection is given by the following equation. Here, Ce is a codeword vector containing an error, and E is an error vector. Here, )l@C=0, so it can be seen that the syndrome Ski is determined only by the noise sequence of the communication system.When the check matrix H has three check words corresponding to the above generator polynomial 〇(x), , A concrete circuit for determining the syndrome S is configured as shown in Fig. 2, for example.Here, 11 is the received code word Cj
This is a register that stores the vector (a?,...,ao) of the received code word Cf is (Cn-1"IW'...
・Cs +C'o,) is input to the register 11 in the sequence. 12-D to 12-7 are exclusive off circuits whose outputs are stored in 8-bit registers. 14 is a coefficient multiplier that multiplies the contents (r) of the register 13 by α. Exclusive off circuit 12-0
~12-7, the contents of register 11 (a7..., a
o) and the output (r·α)) of the coefficient multiplier 14 is calculated. Syndrome S is found on register 13 as CI=O. l, 2). In this example, there are only three syndromes, so generally only one error can be corrected, but if the error position of the received code word C'(i) is known by some means, then in this case Only three errors can be corrected. Now, the received code group (α-1+C to 2...C; , Go
), the three error positions are LJ+k, and the error pattern is @1゜ej +I! If it is given, it will be given. If the position of W4 is known, the error pattern can be obtained from the following equation. Therefore, CB -C'l +el C, -C, +@j CI (up to three errors can be corrected by adding +lik to -c'. If the error position is unknown, from equation (8), error position i and Only the error pattern e1 can be found. Figure 3 shows the encoding structure, with information words (■
h−+−Us +UO) and the test word (Pt, Po)
constitutes an inner code, and information words (υv-1...Us
, Uo) and check words (P2, Pt, Po) constitute an outer code. The generator polynomial 〇(riha) is given for the inner code and the outer code. At this time, in the row direction and the column direction, the code word C (riha is given by Code words (υ1.-1...ul, υ., Pl,
(Po), one word error is corrected, an error flag is attached to each line that could not be corrected, and then the address of each line with an error flag is set as the error position by the outer code for each column. Correct up to three errors. In the inner code, the syndrome S is given by the following equation. The error position in the code word C (violet) is i, and the error pattern is e.
If l, S6 *el, Sl-a'-e5, a'-81
−/So (11), the power i of the primitive element α is the error position, and S is the error pattern. Therefore, the error is corrected from C1=CI+J. Here, (!j□ −0, Sl #0)−(So″R,
Os Ss -0) and (i)n-1), it means that there are two or more errors in the code word in that row,
An error flag is attached to the line as uncorrectable. After error correction for each row is completed, up to three errors are corrected for each column using the outer code. In this case, error position 1+J+' has already been given as the row address that could not be corrected using the inner code. Therefore, the error pattern ei +eJ +ek for each column can be calculated from equation (7), and the syndrome of the outer code is given by equation (5). Next, the general rules for operations in equations (?) and (11) will be described. αi+αj is an addition of od2 when the elements αl and αj are expressed as vectors, and can be realized by an exclusive OR circuit. On the other hand, αtg is the power of element α' + mo of j
This is addition/subtraction in d255, and can be realized with a decimal addition/subtraction circuit, but when Ami+j≧255, A=A-255 A=i-j (when 0, A=255-A. Also, αI, When either αj is 0 element, αtt3yo0 must be set.Syndrome so, s, J! and error position 1.j
. Depending on the calculation content, vector conversion and exponentiation vector conversion are performed, and modulo 2 addition is performed, and α1゜αj is ++J
is converted to a vector power and the modulo 255 addition is performed. As described above, although code word generation and syndrome calculations as in equations (2) and (5) involve a lot of repetitive processing, the circuit configuration is simple. Regarding this, it can be seen that implementing on a circuit an operation that needs to be calculated using a power of the primitive element α becomes quite complicated in terms of circuit scale and processing sequence. Therefore, if all these calculations are implemented using /1- code, the overall circuit configuration will become complicated. On the other hand, if all these calculations are implemented using software, the overall processing will be complicated due to the many repetitive operations. Speed decreases.

【発明の目的】[Purpose of the invention]

そこで、本発明では、誤りパターンおよび誤り位置の演
算のような複雑な処理を必要とする頻度は符号生成やシ
ンドローム算出に比べてきわめて
Therefore, in the present invention, the frequency of requiring complicated processing such as calculation of error patterns and error positions is extremely low compared to code generation and syndrome calculation.

【発明の構成】[Structure of the invention]

かかる目的を達成するために、本発明では繰返し処理が
多く、゛かつ論理回路とレジスタだけで比較的簡単に構
成できる符号語生成およびシンドローム演算はハードの
回路で構成し1元のべき乗で演算する必要のある誤りパ
ターンおよび誤り位置の算出はマイクロプロセッサのプ
ログラム上で処理するように適切に構成する。 7 すなわち、本発明は、情報語群の行または列方向に内符
号を、列または行方向に外符号を割当てるように構成さ
れた符号語群のうち、内符号で第1の誤り訂正を行ない
、その内符号で訂正できなかった誤りについて外符号で
訂正するように構成した誤り訂正回路において、前記内
符号および前記外符号に対する符号語を生成する回路と
、全内符号および前記外符号に対するシンドロームを演
算するシンドローム算出回路と、前記生成された符号語
および前記算出されたシンドロームを一時記憶する第1
メモリと、前記内符号における誤りパターン位置検出お
よび誤り訂正の処理を前記算出された内符号のシンドロ
ームに従って実行する第1プログラム、および前記外符
号における誤りパターンおよび誤り訂正を前記算出され
た外符号のシンドロームに従って実行する第2プログラ
ムを格納した第2メモリと、前記符号生成回路、前記シ
ンドローム演算回路および前記第1メモリを制御するプ
ログラムを格納した第3メモリと、前記第1.第2およ
び第3メモリを制御し、前記符号語生成回路および前記
シンドローム算出回路の制御および前記第1および第2
プログラムの実行の制御を行うマイクロプロセッサとを
具えたことを特徴とする。 [発明の実施例1 以下に図面を参照して本発明の実施例について詳細に説
明する。 第4図は本発明による誤り訂正回路の一実施例を示すシ
ステム構成図である。ここで、51,53゜55.51
1はスリーステートのバスドライバ、およびパストラン
シーバであり、 52,54,518はラッチ回路、5
8はアンドゲートである。57は行方向検、査語生成回
路、58は列方向検査語生成回路、59はシンドローム
回路であり、それぞれ、後述する第7図、第6図、第5
図に示すようにハードの形態で構成することができる。 51Oはバッファメモリ、5!2および513はマルチ
プレクサ、514はカウンタである。515は検査語生
成回路57.58およびシンドローム回路58を含むハ
ードの各部に対する制御信号を発生するためのマイクロ
コードを書き込んであるROM(リードオンメモリ)で
ある、51Bは本発明における誤り訂正回路全体の制御
および誤りパターンと誤り位置の算出を行うプログラム
を実行するマイクロプロセッサ、517はそのプログラ
ム、すなわち式(7)および(11)の演算手順を格納
したROMである。!iはCPUバス、51111はコ
マンド・ステータス信号ラインである。 まず、式(8)の符号語生成を行うハードの回路の構成
例を説明する。 マイクロプロセッサ516がコマンド・ステータス信号
ライン519を経て外部装置(図示せず)から符号語生
成コマンドをバストランシーバ−51を介して受けとる
と、システム全体は符号語生成モードにセットされ、外
部装置からのデータ(no〜D7 )はクロックCK2
によってラッチ回路52へ取り込まれる。 このデータはバスドライバ55を介してバッファメモリ
510に供給され、マルチプレクサ513からのアドレ
ス制御信号ADCによって指定されたアドレスに順次書
き込まれる。一方、同じデータはアンドゲート5Bを介
して行方向の剰余多項式Rs (りにおける検査語(P
l+PO)を算出するため検査語生成回路57へ入力さ
れる0行方向のデータ(Oh−+ 、・・・u工、■0
)が入力される間、ラッチ回路52およびバスドライバ
55のアウトプットイネーブル信号爾および■は低レベ
ル状態、アンドゲート56のゲート信号CGは高レベル
状態にあるh個のデータが、入力完了、すなわちデニタ
u0を入力し終ると、0EI3 、OF2 、は高レベ
ル、ゲート信号CGは低レベル状態になる。 検査語生成回路57ヘデータ(Uh +・・・u、 +
UOrO90)を入力したとき、検査語(Pl、Po 
)が検査語発生回路57の、第7図示のラッチ回路57
06.5705上に求まる。この検査語(Pl、Po 
)はADC信号で指定されたバッファメモリ510のア
ドレスに書き込まれる。 以上の操作を行番号(マー1.マー2.・・・マ鳳、マ
0)全てについて行なう。 以上によって行方向の符号語生成が完了したならば、次
に列方向の符号語生成を行なうためのADC信号で指定
されたバッファメモリ510のアドレスから列番号(k
−1)のデータ(Uv 、 = Ut 。 Uo)を順次読み出しバスドライバー54およびアンド
ゲート56を介して列方向の剰余多項式RV (重)に
おける検査語(Pt 、Ps 、Po )を算出するた
めの検査語生成回路58へ入力する。この間、ラッチ回
路54のmlは低レベル、ラッチ回路52、バスドライ
バ53,55 、アンドゲート5BのOH2、OH2。 OF2 、CGは高レベル状態にあり、V個のデータの
入力完了すなわちデータマ0を入力し終ると、顛は高レ
ベル、CGは低レベル状態になり、検査語生成回路58
にデータ(Uv−+、−,U+ 、Uo 、0.0.0
)を入力したとき、検査語(Pt 、Pt 、Po )
が第8図示の検査語生成回路58のラッチ回路5809
.5808,5807上に求まる。この検査語(Pt 
、Pt 、Po )は^DC信号で指定されたバッファ
メモリ510のアドレスに書き込まれる。 以上の操作は列番号(h−1,h−2,・・・、1.O
,および内符号検査列)すべてについて行なわれ、以上
によって第3図に示す符号語がバッファメモリ510上
に配列される。 次に、マイクロプロセッサ51Bはパストランシーバ−
51を介して外部装置とハンドシェークな行ない、バッ
ファメモリ510上に形成された符号語をADC信号で
アドレスしながら各行毎にデータ(Uh−+、 ・・・
、Ut 、Uo +Pt *’O)をバスドライバー5
3およびラッチ回路54を介して外部装置へ転送する。 このとき顛、顛は低レベルOE2.OE9は高レベル状
態にある。 以上によってバッファメモリ510上のデータ(h+2
) (マ÷3)個すべてを転送し終ったときに符号語生
成モードは終了する。 次に式(11)および式(7)の誤り訂正のハード処理
について述べる。マイクロプロセッサ516が外部装置
から誤り訂正コマンドをパストランシーバ−51を介し
て受けとると、システム全体は誤り訂正モードにセット
され、外部装置からのデータ(Do〜Dt )はクロッ
クCK2によってラッチ回路52へ取り込まれる。この
データはバスドライバ55を介してバッファメモリ51
0のADC信号で指定されたアドレスに順次に書き込ま
れる。 一方、同じデータ(no〜D7)は式(lO)にしたが
って行方向のシンドローム(S+ 、SO)を算出する
ためにシンドローム回路59にも入力される0行方向の
データ(Ilh−+、 ”’、U+ 、Uo +P1 
、po )が′入力サレル間、OH2,OH2ハ低しベ
ル、m、tyrt、ccハ高レベル状態にある。 最後のデータPOを入力し終ると、シンドローム(St
 、So )はシンドローム回路58の第5図示のラッ
チ回路5908,599?上に求まるので、この(Sl
。 So)ラバラフアメモリ510のADC信号で指定され
たアドレスに書き込む。 以上の操作は行番号(マー1.マー2.・・・、l、0
および外符号検査性)すべてについて行なわれる。 次に列方向のシンドロームを行うため、ADC信号で指
定されたバッファメモリ510のアドレスから列番号(
h−1) (7)データ(Uv−+、・・・、IJ+ 
、Do +P2 。 P、 +PO)を順次読み出し、ラッチ回路54を介し
て式(5)にしたがって列方向のシンドローム(S2゜
St 、5(1)を算出するためにシンドローム回路5
9に入力する0列方向のデータ(Uv−+、 −、IJ
+ 、00 、P2゜Pl 、po ) カ入力すレル
fill、ots、otz、ots、ccハmレベル、
田は低レベル状態にある。 列方向の最後のデータPを入力し終るとシンドローム(
S2 +SI +SO)は第5図のラッチ回路59゜0
11.5908.590?上に求まる。このシンドロー
ム(S2 +SI +SO)はバッファメモリ510の
AlIC信号で指定されたアドレスに書き込まれる。 以上の操作は列番号(h−1,h−2,・・・1.0お
よび内符号検査列)すべてについて行なわれる。 以上によって第3図に示した符号語構成における各行お
よび列のシンドロームの算出が終了すると、バッファメ
モリ510の使用権はマイクロプロセッサ−518側の
CPUパス518に対して与えられ、誤り位置および誤
りパターンのソフトによる演算処理に入る。 このためには、双方向パストランシーバ511のアウト
プットイネーブル信号OE[lを低レベル状態にする。 マイクロプロセッサ516はまず行方向の誤り訂正を行
うために、各行毎にアドレス信号Add rで指定され
たバッファメモリ510のアドレスから該当行のシンド
ロームC5+ 、So )をパストランシーバ−511
より取出し、ベクトル表現されているシンドローム(S
l、So )をべき乗表現α11゜α10に変換し、式
(11)によってαl=α11斗計算することによって
該当行の誤り位置i(−璽1−閣。)を特定する。この
特定された誤り位置iをアドレス信号Add rとなし
て、バッファメモリ510に供給し、その該当アドレス
から符号語Ciを読み取り、そのC!と誤りバタ・−ン
を示すSoとの排他的論理和をとってその結果をバッフ
ァメモリ510の同一アドレスへ書き込む、これによっ
て、該当行の1語を訂正したことになる。 本実施例では行方向に1語しか訂正できないので、2語
以上の誤りに対しては、各行毎に、マイクロプロセッサ
51Bは(So ”0.St ”−= Q)。 (S6 # 0. Sl =0) 、(i)h−1+2
)いずれかの条件を満すときに、その該当行に対してエ
ラーフラッグとして該当行を記憶しておく。 第3図のすべての行について上記処理を完了したならば
、マイクロプロセッサ51Eiは次に列方向の誤り訂正
を行う、まずマイクロプロセッサ518は各列単位にア
ドレス信号Addrで指定されたバッファメモリ510
のアドレスから該当月のシンドローム(Sz、St J
O)をパストランシーバ−511を介して取り出し、上
述と同様にベクトル表現のべき乗表現への変換またはそ
の逆変換を行いながら、式(7)の誤りパターンを計算
する。 ここで(j、j、k)は上記によってエラーフラッグと
して記憶されている訂正不能な誤り行のアドレスであっ
て、これらの行が4個所以上に存在すると、もはや列方
向には訂正できないことになり、第3図の符号語全体が
訂正不能状態となり、マイクロプロセッサ516はこの
検出によってパストランシーバ−51を介してこの状態
を外部装置に知らせる。 誤り行が3個所以下ならばそのすべてが訂正可能になり
、誤り位置(i、j、k)はαのべき乗表現でα1 、
αj 、α を示している。 式(7)によって誤りパターンが計算されると、マイク
ロプロセッサ51Bは誤り行(i、j、k)をアドレス
としてアドレス信号Addrに与え、そのアドレスのデ
ータ’Ci + Cj * C’ kをバッファメモリ
510から読み出し、 ei 、8J+l!にとの排他
的論理和をとってそれぞれの結果をバッファメモリ51
0の上記と同一アドレスへ書き込む0以上の処理で、該
当月の31sまでの誤り訂正が完了したことになる。 第3図のすべての列について上記処理を終了したならば
、マイクロプロセッサ518はパストランシーバ−51
を介して外部装置とハンドシェークを行い、バッファメ
モリ510上に形成された誤り訂正後の符号語のうち、
情報語だけをADC信号でアドレスしながら各行毎にデ
ータ(υh−1,・・・UI。 tlo)をパストランシーバ−53およびラッチ回路5
4を介して外部装置へ転送する。 以上マイクロプロセッサ51Bにおける処理はプログラ
ムROM517で与えられ、またベクトル表現およびべ
き乗表現間の変換は、0F(2B )の場合、それぞれ
255バイトのテーブルをあらかじめ作っておくことに
よって、モのテーブル参照だけで変換を実行できる。ま
た、式(7)、(11)の処理は10進数の加算命令と
論理演算命令だけで実現できるので、比較的処理時間の
速い命令だけで実現できる。 なお、前述の検査語発生回路57および58およびシン
ドローム回路53によって求められた検査語p2.p1
.p、およびシンドロームS、 、S、 、Soは制御
信号SHV、PV 、PH、OF3.OF2,0E5(
第5〜第7図)の状態に応じて1つのレジスタの内容が
バッファメモリ51Gへ書き込まれるようになる。 SEL 1およびsgL3億号は双方向パストランシー
バ511および51の方向制御を行う、 SEL2信号
はマルチプレクサ512および513のラインセレクト
を行う。 SADは、ROW 515のスタートアドレスに対応し
てカウンタ514に供給されるカウント初期値、口はロ
ード信号、WRI、R[+1およびl1lR2,RD2
は、それぞれ、Add r信号およびADC信号に対応
するライト信号、リード信号であり、それら信号のいず
れかの組をSEL2信号により選択してマルチプレクサ
512よりライト信号i、リード信号韮として取り出し
、バッファメモリ510に加える。 外部装置とバッファメモリ5!0との間のデータ転送お
よび符号語生・成、シンドローム演算などの回路制御信
号およびバッファメモリ510のアドレス制御を行うA
DC信号はマイクロコードR[1M515にあらかじめ
設定してあり、マイクロプロセッサ51Bからのコマン
ドによってカウンター514が動作を開始すると、それ
に伴ってABCおよび制御信号がROM515から発生
され、ラッチ回路518を介して上述の回路制御を行う
。 (以下余白) シンドローム回路58は第5図のように構成することが
でき、ここで5901.5902.5903は、例えば
、第8図に示すように構成される演算回路、 5130
4〜5909はラッチ回路、5810〜5812はナン
トゲートであル、 IJc、IJSはラッfWJ路59
04〜5909へ+7) クロック、汎はラッチ回路5
804〜580Bへのクリア信号、SHVはシンドロー
ム演算処理モード指定信号、OE3〜OE5はアウトプ
ットイネーブル信号であり、これら各種信号はROM5
15からラッチ回路518を介して供給される。 上述の演算回路、例え°ば5803は第8図あようにエ
クスクル−シブオア回路71〜84を配置して、データ
 Go/−C,とラッチ回路5808からの出力P20
〜P27とによって第2図においてベクトル(r)=ベ
クトル(9+ベクトル(α1.α2)の演算を行い、そ
の結果を再びラッチ回路590Bに入力する。この回路
の演算を数式で示すと次の例のようになる。 α的  a2cl”aQり♂す$ヶ10べき乗表現他の
演算回路5301および5802も同様に構成すること
ができる。 列方向検査語発生回路58は第6図のように構成するこ
とができ、ここで、5801〜5803は上述の演算回
路5303と同様にエクスクル−シブオフ回路で構成す
ることができる演算回路である。 5804〜5808
はラッチ回路、5810〜5812はナントゲートであ
るa  pvは列方向の検査語発生処理モードの指定信
号であり、ROM515からラッチ回路518を介し行
方向の検査語発生回路57は第7図のように構成するこ
とができ、ここで、5701および5702は上述の演
算回路5803と同様にエクスクル−シブオフ回路で構
成することのできる演算回路である。 5703〜570Bはラッチ回路、5707および57
08はナントゲートである。Pは行方向の検査語発生処
理モードの指定信号であり、ROM515からラッチ回
路518を介して供給される。 マイクロプロセッサ51Bでの以上のような各種処理の
制御手順は例えば第8図のように定められる。まずステ
ップSOにおいて、ベクトル表現およびべき乗表現間の
変換のための参照テーブルを作テップS2では外部装置
からのコマンドによってカウンタ514に符号生成また
はシンドローム演算のためのマイクロコードについての
スタートアドレスのカウント値をプリロードする。この
状態で、スタートコマンドが入来すると、ステップS3
ではデータ(no ” Dt )の入力を行い、符号生
成またはシンドローム演算を第5図示のハード構成の回
路で実行する。ステップS4では、ROM515からの
マイクロコードを監視しており、それにより演算終了が
判断されると、ステップS4からステップS5に進む。 このステップS5ではそれまでにハード構成の回路で実
行された処理が符号生成であるか、あるいはシンドロー
ム演算であるかを終了したマイクロコードから判断する
。 ステップS5において符号生成と判断されたときには、
ステップSBに進み、ここで、バッファメモリ510の
内容、すなわち符号生成されているデータを外部へ転送
するための処理のマイクロコードについてのスタートア
ドレスに対応するカウント値をカウンタ514にプリロ
ードする。 ついで、スタートコマンドが入来すると、ステップS7
ではかかるデータ読出しをバッファメモリ510に指令
する0次のステップS8において、バッファメモリ5!
0内に格納されている符号生成データは読み出されて外
部に転送される。ステップS8では、その転送が終了し
たか否かをマイクロコードを監視して判断している。 以上によって1ブロツクの処理が完了し再びステップS
lに戻って同様の処理を繰り返す。 他方、ステップS5において、シンドローム演算と判断
されたときには、ステップSitに進み、ここで第5図
示のハード構成によって演算を実行してすでにバッファ
メモリ510に格納されているシンドロームを読み出す
0次のステップS12においては、このシンドロームに
基づいて(11)式の演算を行い、さらにステップS1
3において、バッファメモリ510内のデータの行方向
の誤りを訂正する。ステップS14では、訂正不能な行
のアドレスにエラーフラッグをつける。 以上のステップSll〜S14の処理を行数だけ繰返し
実行する。 次に、ステップS15において、バッファメモリ510
からシンドロームを読み出して、ステップ91Bにおい
て(7)式の演算を行う、さらに、ステップSt?では
、バッファメモリ510内のデータの列方向の誤りを訂
正する。 このステップS15〜S17の処理を列数だけ繰り返し
実行する。 ついで、ステップS6に進み、上述したようなバッファ
メモリ510からのデータ読出しと外部への転送とを行
う、この場合には、転送されるデータは誤り訂正のなさ
れたデータである。
In order to achieve such an objective, in the present invention, the codeword generation and syndrome operations, which involve a lot of repetitive processing and can be configured relatively easily using only logic circuits and registers, are configured using hard circuits and are operated using powers of one element. The calculation of necessary error patterns and error positions is appropriately configured to be processed on a microprocessor program. 7 In other words, the present invention performs the first error correction on the inner code of a code word group configured to allocate an inner code in the row or column direction and an outer code in the column or row direction of the information word group. , an error correction circuit configured to correct errors that cannot be corrected with the inner code using the outer code, a circuit for generating code words for the inner code and the outer code, and a syndrome for the inner code and the outer code. a syndrome calculation circuit that calculates a syndrome, and a first syndrome calculation circuit that temporarily stores the generated code word and the calculated syndrome.
a memory; a first program for detecting error pattern positions and correcting errors in the inner code according to syndromes of the calculated inner code; and detecting error patterns and correcting errors in the outer code; a second memory that stores a second program to be executed according to the syndrome; a third memory that stores a program that controls the code generation circuit, the syndrome calculation circuit, and the first memory; controls the second and third memories, controls the code word generation circuit and the syndrome calculation circuit, and controls the first and second memories;
It is characterized by comprising a microprocessor that controls program execution. [Embodiment 1 of the Invention] Examples of the present invention will be described in detail below with reference to the drawings. FIG. 4 is a system configuration diagram showing an embodiment of the error correction circuit according to the present invention. Here, 51,53°55.51
1 is a three-state bus driver and a pass transceiver; 52, 54, and 518 are latch circuits;
8 is an and gate. 57 is a row direction check word generation circuit, 58 is a column direction check word generation circuit, and 59 is a syndrome circuit, which will be described later in FIGS.
As shown in the figure, it can be configured in the form of hardware. 51O is a buffer memory, 5!2 and 513 are multiplexers, and 514 is a counter. 515 is a ROM (read-on memory) in which microcodes for generating control signals for each part of the hardware including the check word generation circuits 57 and 58 and the syndrome circuit 58 are written, and 51B is the entire error correction circuit in the present invention. A microprocessor 517 executes a program for controlling and calculating error patterns and error positions, and 517 is a ROM that stores the program, that is, the calculation procedure of equations (7) and (11). ! i is a CPU bus, and 51111 is a command/status signal line. First, a configuration example of a hardware circuit that generates the code word of equation (8) will be described. When the microprocessor 516 receives a codeword generation command from an external device (not shown) via the bus transceiver 51 via the command/status signal line 519, the entire system is set to codeword generation mode and the command from the external device is set to the codeword generation mode. Data (no~D7) is clock CK2
is taken into the latch circuit 52 by. This data is supplied to the buffer memory 510 via the bus driver 55 and sequentially written to addresses designated by the address control signal ADC from the multiplexer 513. On the other hand, the same data is passed through the AND gate 5B to the remainder polynomial Rs (test word (P
Data in the direction of the 0th row (Oh-+,...U, ■0) is input to the check word generation circuit 57 in order to calculate
) is being input, the output enable signals 〈 and 〉 of the latch circuit 52 and the bus driver 55 are in a low level state, and the gate signal CG of the AND gate 56 is in a high level state. When the input of the digital signal u0 is completed, 0EI3 and OF2 become high level, and the gate signal CG becomes low level. Data to the test word generation circuit 57 (Uh +...u, +
When inputting the test word (Pl, Po
) is the latch circuit 57 shown in FIG.
It is found on 06.5705. This test word (Pl, Po
) is written to the address of the buffer memory 510 specified by the ADC signal. The above operation is performed for all row numbers (ma 1, ma 2, . . . mao, ma 0). When the code word generation in the row direction is completed as described above, the column number (k
-1) The data (Uv, = Ut. Uo) are sequentially read out via the bus driver 54 and the AND gate 56 to calculate the check words (Pt, Ps, Po) in the column-direction remainder polynomial RV (multiple). It is input to the test word generation circuit 58. During this time, ml of the latch circuit 54 is at a low level, and the latch circuit 52, bus drivers 53 and 55, and OH2 and OH2 of the AND gate 5B. OF2 and CG are in a high level state, and when the input of V pieces of data is completed, that is, data mark 0 has been input, the frame becomes a high level and CG becomes a low level state, and the check word generation circuit 58
data (Uv-+, -, U+, Uo, 0.0.0
), the test word (Pt, Pt, Po)
is the latch circuit 5809 of the check word generation circuit 58 shown in FIG.
.. It is found on 5808 and 5807. This test word (Pt
, Pt, Po) are written to the address of the buffer memory 510 specified by the ^DC signal. The above operations are performed using column numbers (h-1, h-2, ..., 1.O
, and inner code check sequences), and the code words shown in FIG. 3 are arranged on the buffer memory 510. Next, the microprocessor 51B converts the path transceiver
Handshaking is performed with an external device via the buffer memory 51, and data (Uh-+, . . .
, Ut , Uo +Pt *'O) as bus driver 5
3 and the latch circuit 54 to an external device. At this time, the number is low level OE2. OE9 is in a high level state. As a result of the above, the data (h+2) on the buffer memory 510
) The code word generation mode ends when all (ma ÷ 3) pieces have been transferred. Next, hardware processing for error correction in equations (11) and (7) will be described. When the microprocessor 516 receives an error correction command from an external device via the path transceiver 51, the entire system is set to the error correction mode, and data (Do to Dt) from the external device is taken into the latch circuit 52 by the clock CK2. It will be done. This data is transferred to the buffer memory 51 via the bus driver 55.
They are sequentially written to the addresses specified by the ADC signal of 0. On the other hand, the same data (no~D7) is data in the 0 row direction (Ilh-+, ``' , U+ , Uo +P1
, po ) are at input level, OH2, OH2 are low, m, tyrt, cc are at high level. After entering the last data PO, the syndrome (St
, So) are the latch circuits 5908, 599? of the syndrome circuit 58 shown in FIG. Since it is found above, this (Sl
. So) Write to the address specified by the ADC signal of the rubber rear memory 510. The above operations are performed using the line numbers (Mar 1. Mar 2..., l, 0)
and outer code checking). Next, in order to perform the syndrome in the column direction, the column number (
h-1) (7) Data (Uv-+, ..., IJ+
, Do +P2. P, +PO) are sequentially read out, and the syndrome circuit 5 is used to calculate the column direction syndrome (S2°St, 5(1)) according to equation (5) via the latch circuit 54.
Data in the 0 column direction input to 9 (Uv-+, -, IJ
+, 00, P2゜Pl, po) Power input level fill, ots, otz, ots, cc hum level,
The rice field is in a low level state. After inputting the last data P in the column direction, the syndrome (
S2 +SI +SO) is the latch circuit 59°0 in Figure 5.
11.5908.590? Find above. This syndrome (S2 +SI +SO) is written to the address specified by the AlIC signal in the buffer memory 510. The above operations are performed for all column numbers (h-1, h-2, . . . 1.0 and inner code check columns). When the syndromes for each row and column in the code word structure shown in FIG. The software begins calculation processing. To do this, the output enable signal OE[l of the bidirectional path transceiver 511 is brought to a low level state. First, in order to perform error correction in the row direction, the microprocessor 516 transmits the syndrome C5+, So) of the corresponding row from the address of the buffer memory 510 specified by the address signal Addr for each row to the pass transceiver 511.
The syndrome (S
l, So) into a power expression α11°α10, and calculate αl=α11to using equation (11), thereby specifying the error position i (-Sho1-Kaku.) in the corresponding line. This identified error position i is made into an address signal Add r and is supplied to the buffer memory 510, the code word Ci is read from the corresponding address, and the C! and So indicating the error pattern, and write the result to the same address in the buffer memory 510, thereby correcting one word in the corresponding line. In this embodiment, only one word can be corrected in the row direction, so for errors of two or more words, the microprocessor 51B corrects (So "0.St"-=Q) for each row. (S6 #0. Sl =0), (i) h-1+2
) When any of the conditions is satisfied, the corresponding line is stored as an error flag for the corresponding line. After completing the above processing for all the rows in FIG. 3, the microprocessor 51Ei next performs error correction in the column direction.
Syndrome (Sz, St J
O) is taken out via the path transceiver 511, and the error pattern of equation (7) is calculated while converting the vector expression to the power expression or vice versa as described above. Here, (j, j, k) is the address of an uncorrectable error row stored as an error flag as described above, and if these rows exist in four or more locations, it is no longer possible to correct them in the column direction. Thus, the entire code word of FIG. 3 is in an uncorrectable state, and upon this detection, microprocessor 516 notifies external equipment of this state via path transceiver 51. If there are three or less error lines, all of them can be corrected, and the error position (i, j, k) is expressed as a power of α, α1,
αj and α are shown. When the error pattern is calculated according to equation (7), the microprocessor 51B gives the error row (i, j, k) as an address to the address signal Addr, and stores the data 'Ci + Cj * C' k at that address in the buffer memory. Read from 510, ei, 8J+l! Exclusive OR is performed and each result is stored in the buffer memory 51.
By writing 0 or more to the same address as above, error correction up to 31s of the month is completed. After completing the above processing for all columns in FIG.
Among the error-corrected code words formed on the buffer memory 510 by handshaking with an external device via the
Addressing only the information word with the ADC signal, data (υh-1,...UI.tlo) is passed for each row to the transceiver 53 and the latch circuit 5.
4 to an external device. The processing in the microprocessor 51B is given by the program ROM 517, and the conversion between vector representation and exponentiation representation is possible by creating tables of 255 bytes each in advance in the case of 0F (2B), and by simply referencing the Can perform conversions. Further, since the processing of equations (7) and (11) can be realized using only decimal number addition instructions and logical operation instructions, it can be realized only with instructions that have a relatively fast processing time. Note that the test word p2. p1
.. p, and syndromes S, , S, , So are controlled by control signals SHV, PV, PH, OF3. OF2,0E5(
The contents of one register are written to the buffer memory 51G depending on the state shown in FIGS. 5 to 7). The SEL1 and sgL300 signals provide direction control for bidirectional path transceivers 511 and 51; the SEL2 signal provides line selection for multiplexers 512 and 513. SAD is the count initial value supplied to the counter 514 corresponding to the start address of ROW 515, and the input is the load signal, WRI, R[+1 and l1lR2, RD2
are a write signal and a read signal corresponding to the Add r signal and the ADC signal, respectively, and any set of these signals is selected by the SEL2 signal and taken out from the multiplexer 512 as a write signal i and a read signal dwarf, and is sent to the buffer memory. Add to 510. A that controls circuit control signals such as data transfer between external devices and the buffer memory 5!0, code word generation, syndrome calculation, etc., and address control of the buffer memory 510;
The DC signal is preset in the microcode R[1M515, and when the counter 514 starts operating in response to a command from the microprocessor 51B, ABC and control signals are generated from the ROM 515 and transmitted through the latch circuit 518 to the above-mentioned signals. performs circuit control. (Left space below) The syndrome circuit 58 can be configured as shown in FIG. 5, where 5901, 5902, and 5903 are arithmetic circuits configured as shown in FIG.
4 to 5909 are latch circuits, 5810 to 5812 are Nant gates, IJc and IJS are latch circuits, and IJc and IJS are latch circuits.
04 to 5909 +7) Clock, general is latch circuit 5
Clear signals to 804 to 580B, SHV are syndrome calculation processing mode designation signals, OE3 to OE5 are output enable signals, and these various signals are stored in ROM5.
15 through a latch circuit 518. The above-mentioned arithmetic circuit, for example 5803, has exclusive OR circuits 71 to 84 arranged as shown in FIG.
~P27, the calculation of vector (r)=vector (9+vector (α1.α2)) is performed in FIG. The other arithmetic circuits 5301 and 5802 can be similarly configured. The column-direction check word generation circuit 58 is configured as shown in FIG. Here, 5801 to 5803 are arithmetic circuits that can be configured with exclusive off circuits like the above-mentioned arithmetic circuit 5303. 5804 to 5808
is a latch circuit, 5810 to 5812 are Nant gates, a pv is a designation signal for the column direction check word generation processing mode, and the row direction check word generation circuit 57 is connected from the ROM 515 via the latch circuit 518 as shown in FIG. Here, 5701 and 5702 are arithmetic circuits that can be constructed from exclusive off circuits like the above-mentioned arithmetic circuit 5803. 5703-570B are latch circuits, 5707 and 57
08 is Nantes Gate. P is a designation signal for the check word generation processing mode in the row direction, and is supplied from the ROM 515 via the latch circuit 518. The control procedure for the various processes described above in the microprocessor 51B is determined, for example, as shown in FIG. First, in step SO, a reference table for conversion between vector expression and power expression is created. In step S2, a count value of the start address for the microcode for code generation or syndrome calculation is input to the counter 514 by a command from an external device. Preload. In this state, when a start command is received, step S3
Then, data (no "Dt) is input, and code generation or syndrome calculation is executed by the circuit with the hardware configuration shown in FIG. If it is determined, the process proceeds from step S4 to step S5. In step S5, it is determined from the completed microcode whether the processing executed by the hardware circuit until then is code generation or syndrome operation. When it is determined in step S5 that code generation is required,
Proceeding to step SB, the counter 514 is preloaded with the contents of the buffer memory 510, that is, the count value corresponding to the start address of the microcode of the process for transferring the code-generated data to the outside. Then, when a start command is received, step S7
Then, in the 0th order step S8 in which the buffer memory 510 is instructed to read such data, the buffer memory 5!
The code generation data stored in 0 is read out and transferred to the outside. In step S8, the microcode is monitored to determine whether the transfer has been completed. With the above steps, processing for one block is completed and step S is performed again.
Return to step 1 and repeat the same process. On the other hand, when it is determined in step S5 that it is a syndrome calculation, the process proceeds to step Sit, where the calculation is executed by the hardware configuration shown in FIG. 5 and the syndrome already stored in the buffer memory 510 is read out. In step S1, the equation (11) is calculated based on this syndrome, and step S1
3, errors in the data in the buffer memory 510 in the row direction are corrected. In step S14, an error flag is attached to the address of the uncorrectable row. The above steps Sll to S14 are repeatedly executed for the number of rows. Next, in step S15, the buffer memory 510
The syndrome is read out from , and the calculation of equation (7) is performed in step 91B.Furthermore, in step St? Now, errors in the data in the buffer memory 510 in the column direction are corrected. The processing of steps S15 to S17 is repeated for the number of columns. Next, the process proceeds to step S6, where data is read from the buffer memory 510 and transferred to the outside as described above. In this case, the transferred data is error-corrected data.

【発明の効果】【Effect of the invention】

以上のように、本発明によれば、繰返し処理が多くかつ
簡単な回路で構成できる符号生成およびシンドローム演
算はハード構成で処理し、繰返し処理が少なくかつハー
ド構成では複雑になる誤りパターンおよび誤り位置の算
出はソフトで実行するようにしたので、システムの構成
を簡単化し、したがってコストを低下させることができ
る。 また、本発明では、誤り位置や誤りパターンをマイクロ
プロセッサでソフト的に処理するので、処理速度は、全
体のシステムをハード構成とする度は、通常はさほど高
くないので、全体的平均でみれば、処理速度はさほど低
下せず、実用上は何らの支障もなく、装置コストの低下
の利点の方が総合的効果としては大きい。
As described above, according to the present invention, code generation and syndrome calculations that require a lot of repetitive processing and can be configured with a simple circuit are processed by a hardware configuration, and error patterns and error positions that require few repetitive processes and are complicated in a hardware configuration are processed. Since the calculation of is executed by software, the system configuration can be simplified and the cost can be reduced. In addition, in the present invention, error positions and error patterns are processed by software using a microprocessor, so the processing speed is usually not very high if the overall system has a hardware configuration. However, the processing speed does not decrease much, there is no practical problem, and the overall effect is greater than the reduction in device cost.

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

第1図は生成多項式の余剰を算出する回路の一例を示す
回路図、 第2図はシンドロームを算出する回路の一例を示す回路
図、 第3図は情報語の符号化構造を示す線図、第4図は本発
明誤り訂正回路の一実施例を示すブロック線図。 第5図はそのシンドローム算出回路の一実施例を示すブ
ロック線図、 第6図は行方向の符号語生成回路の一実施例を示すブロ
ック線図、 第7図は列方向の符号語生成回路の一実施例を示すブロ
ック線図、 第8図は第5図中の演算回路の具体例を示す回路図、 第9図は本発明誤り訂正回路における制御の一連の手順
を示すフローチャートである。 51.53,55,511・・・スリーステートのバス
ドライバ(トランシーバ)、 52.54,518・・・ラッチ回路、56・・・アン
ドゲート、 57・・・行方向検査語生成回路、 58・・・列方向検査語生成回路、 58・・・シンドローム回路、 510・・・バッファメモリ、 512.513・・・マルチプレクサ、514・・・カ
ウンタ、 515・・・ROM、 51B・・・マイクロプロセッサ、 519・・・コマンドeステータス信号ライン。 V2 f
Figure 1 is a circuit diagram showing an example of a circuit that calculates the surplus of a generator polynomial, Figure 2 is a circuit diagram showing an example of a circuit that calculates syndromes, Figure 3 is a diagram showing the encoding structure of information words, FIG. 4 is a block diagram showing one embodiment of the error correction circuit of the present invention. FIG. 5 is a block diagram showing an embodiment of the syndrome calculation circuit, FIG. 6 is a block diagram showing an embodiment of the code word generation circuit in the row direction, and FIG. 7 is the code word generation circuit in the column direction. FIG. 8 is a circuit diagram showing a specific example of the arithmetic circuit in FIG. 5; FIG. 9 is a flowchart showing a series of control procedures in the error correction circuit of the present invention. 51. 53, 55, 511... Three-state bus driver (transceiver), 52. 54, 518... Latch circuit, 56... AND gate, 57... Row direction check word generation circuit, 58. ... Column direction check word generation circuit, 58 ... Syndrome circuit, 510 ... Buffer memory, 512.513 ... Multiplexer, 514 ... Counter, 515 ... ROM, 51B ... Microprocessor, 519...Command e status signal line. V2 f

Claims (1)

【特許請求の範囲】 情報語群の行または列方向に内符号を、列または行方向
に外符号を割当てるように構成された符号語群のうち、
内符号で第1の誤り訂正を行ない、その内符号で訂正で
きなかった誤りについて外符号で訂正するように構成し
た誤り訂正回路において、 前記内符号および前記外符号に対する符号語を生成する
回路と、前記内符号および前記外符号に対するシンドロ
ームを演算するシンドローム算出回路と、前記生成され
た符号語および前記算出されたシンドロームを一時記憶
する第1メモリと、前記内符号における誤りパターンお
よび位置検出および誤り訂正の処理を前記算出された内
符号のシンドロームに従って実行する第1プログラム、
および前記外符号における誤りパターンおよび誤り訂正
の処理を前記算出された外符号のシンドロームに従って
実行する第2プログラムを格納した第2メモリと、前記
符号生成回路、前記シンドローム演算回路および前記第
1メモリを制御するプログラムを格納した第3メモリと
、前記第1、第2および第3メモリを制御し、前記符号
語生成回路および前記シンドローム算出回路の制御およ
び前記第1および第2プログラムの実行の制御を行うマ
イクロプロセッサとを具えたことを特徴とする誤り訂正
回路。
[Scope of Claims] Among a code word group configured to assign an inner code in the row or column direction and an outer code in the column or row direction of the information word group,
An error correction circuit configured to perform first error correction on an inner code and correct errors that cannot be corrected on the inner code using an outer code, comprising: a circuit for generating code words for the inner code and the outer code; , a syndrome calculation circuit that calculates a syndrome for the inner code and the outer code, a first memory that temporarily stores the generated code word and the calculated syndrome, and error pattern and position detection and error in the inner code. a first program that executes a correction process according to the calculated inner code syndrome;
and a second memory storing a second program for executing error pattern and error correction processing in the outer code according to the calculated syndrome of the outer code, the code generation circuit, the syndrome calculation circuit, and the first memory. A third memory storing a program to be controlled, and the first, second and third memories, and controlling the code word generation circuit and the syndrome calculation circuit and the execution of the first and second programs. An error correction circuit characterized in that it comprises a microprocessor that performs the error correction.
JP12290384A 1984-06-16 1984-06-16 Error correction circuit Pending JPS613528A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP12290384A JPS613528A (en) 1984-06-16 1984-06-16 Error correction circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP12290384A JPS613528A (en) 1984-06-16 1984-06-16 Error correction circuit

Publications (1)

Publication Number Publication Date
JPS613528A true JPS613528A (en) 1986-01-09

Family

ID=14847461

Family Applications (1)

Application Number Title Priority Date Filing Date
JP12290384A Pending JPS613528A (en) 1984-06-16 1984-06-16 Error correction circuit

Country Status (1)

Country Link
JP (1) JPS613528A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH04297164A (en) * 1990-03-05 1992-10-21 Nec Corp Error correction system

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH04297164A (en) * 1990-03-05 1992-10-21 Nec Corp Error correction system

Similar Documents

Publication Publication Date Title
JP5768022B2 (en) Memory controller, storage device, error correction device, and error correction method
US5563896A (en) Error correction processor and an error correcting method
EP0114938A2 (en) On-the-fly multibyte error correction
US10635528B2 (en) Memory controller and method of controlling memory controller
JPH11507754A (en) Dedicated ALU architecture for 10-bit read-Solomon error correction module
JP2001175542A (en) Recording and reproducing device and semiconductor memory
JPH10207726A (en) Semiconductor disk device
US6772385B2 (en) Error-correcting device and decoder enabling fast error correction with reduced circuit scale
US5805617A (en) Apparatus for computing error correction syndromes
JPH0452556B2 (en)
JPH08255111A (en) Error correcting and detecting circuit and semiconductor storage device
JP5353655B2 (en) Error detection / correction code generation circuit and control method thereof
JP2009259113A (en) Nonvolatile memory management device
JP2005086683A (en) Error decoding circuit, data bus control method, and data bus system
JP3239522B2 (en) Data loss correction method and circuit
JPS613528A (en) Error correction circuit
JP3743915B2 (en) Spotty byte error correction / detection method and apparatus
JP5398764B2 (en) Memory system and memory controller
JP2008112522A (en) Device and method for detecting error
JP3139499B2 (en) Error correction processor
JP2005216477A (en) Method and device for decoding dvd using selective po correction
JPH10322226A (en) Reed solomon decoding method
JPH0385923A (en) Crc arithmetic system
JP2665268B2 (en) Step-by-step decoding method and decoder for cyclic code
JPS6217256B2 (en)