JPS61287335A - Parity generation circuit - Google Patents

Parity generation circuit

Info

Publication number
JPS61287335A
JPS61287335A JP12876485A JP12876485A JPS61287335A JP S61287335 A JPS61287335 A JP S61287335A JP 12876485 A JP12876485 A JP 12876485A JP 12876485 A JP12876485 A JP 12876485A JP S61287335 A JPS61287335 A JP S61287335A
Authority
JP
Japan
Prior art keywords
circuit
parity
data
output
level
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
JP12876485A
Other languages
Japanese (ja)
Inventor
Tsukasa Miyawaki
宮脇 司
Jiro Hirahara
平原 治郎
Akito Abe
昭人 阿部
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.)
Toshiba Corp
Original Assignee
Toshiba Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Toshiba Corp filed Critical Toshiba Corp
Priority to JP12876485A priority Critical patent/JPS61287335A/en
Publication of JPS61287335A publication Critical patent/JPS61287335A/en
Pending legal-status Critical Current

Links

Landscapes

  • Error Detection And Correction (AREA)

Abstract

PURPOSE:To realize a parity generation circuit at serial data transfer with a simple circuit by using a binary counter so as to count a one level of a serial data to an input circuit thereby forming a parity bit of the serial data. CONSTITUTION:A binary counter circuit 60 generating a parity bit from a serial transmission/reception data and a parity level selection circuit 80 selecting the level of the parity bit generated by the circuit 60 in an even number parity or an odd number parity are provided. Since the output of a data latch circuit 68 is inverted at each input of '1' level as a serial data STD, the output of the circuit 60 is an even number parity corresponding to the serial data STD. The output from the circuit 60 is outputted at the original level via a transfer gas 83 at the selection of the even number parity by the parity level selection circuit 80 and outputted via a transfer gate 82 after being inverted by an invert er 81 at the selection of odd number parity and outputted via a transfer gate 85 in the timing of a control signal T.

Description

【発明の詳細な説明】 [発明の技術分野] この発明はシリアルにデータを転送するシリアル転送回
路に係り、特にこの転送データからパリティ−ビットを
生成するパリティ−生成回路に関する。
DETAILED DESCRIPTION OF THE INVENTION [Technical Field of the Invention] The present invention relates to a serial transfer circuit that serially transfers data, and more particularly to a parity generation circuit that generates parity bits from this transfer data.

[発明の技術的背景] データ転送の際に転送経路の途中でデータに誤りが発生
した場合にこの誤りデータの検出、訂正を行なうため、
データにパリティ−ビットを付加して転送することが一
般に行われている。
[Technical Background of the Invention] In order to detect and correct the erroneous data when an error occurs in the data during data transfer during the transfer route,
It is common practice to add a parity bit to data and transfer it.

第4図はこのような用途に用いられる従来のパリティ−
生成回路の構成を示す。このパリティ−生成回路は転送
データが8ビツトの場合のものであり、この8くットの
データDoないしD7がそれぞれ2ビツトずつ4個の各
排他的論理和回路(イクスクルーシブ・オア回路)11
ないし14に供給され、このうち2個の排他的論理和回
路11および12の出力が排他的論理和回路15に、残
りの2個の排他的論理和回路13および14の出力が排
他的論理和回路16にそれぞれ供給され、さらに上記2
個の排他的論理和回路15および16の出力が排他的論
理和回路17に供給され、この排他的論理和回路17の
出力は奇数パリティ−(○DD)、偶数パリティ−(E
VEN)を選択するための制御信号0/Eとともに排他
的論理和回路18に供給される。
Figure 4 shows the conventional parity used for such applications.
The configuration of the generation circuit is shown. This parity generation circuit is for the case where the transfer data is 8 bits, and the 8 bits of data Do to D7 are converted into 4 exclusive OR circuits (exclusive OR circuits) of 2 bits each. 11
The outputs of two exclusive OR circuits 11 and 12 are supplied to exclusive OR circuit 15, and the outputs of the remaining two exclusive OR circuits 13 and 14 are supplied to exclusive OR circuits 11 and 14. are supplied to the circuit 16 respectively, and further the above 2
The outputs of the exclusive OR circuits 15 and 16 are supplied to the exclusive OR circuit 17, and the outputs of the exclusive OR circuit 17 are for odd parity (○DD) and even parity (E
VEN) is supplied to the exclusive OR circuit 18 together with a control signal 0/E for selecting the signal 0/E.

そして、この排他的論理和回路18の出力がパリティ−
生成タイミング信号Tによりスイッチ制御されるトラン
スファゲート19を介して、奇数パリティ−もしくは偶
数パリティ−PARとして出力される。
Then, the output of this exclusive OR circuit 18 is a parity signal.
It is outputted as odd parity or even parity PAR through a transfer gate 19 whose switch is controlled by the generation timing signal T.

第5図は上記従来のパリティ−生成回路を、シリアルデ
ータの送信を行なうシリアルデータ送信回路に使用した
場合の構成を示す回路図である。
FIG. 5 is a circuit diagram showing a configuration in which the conventional parity generation circuit described above is used in a serial data transmission circuit for transmitting serial data.

このシリアルデータ送信回路には送信データのビット数
に対応した数の送信バッファ20が多段接続されており
、CPU等から内部バスを介して出力される例えば8ビ
ツトの送信データTDOないしTD7が各送信バッファ
20内のインバータ21に並列に供給される。このイン
バータ21の出力は、上記CPU等の内部バスから各送
信バッファ20に各送信データを取込むための、りOツ
ク信号CLKに同期した制御信号IBによりスイッチ制
御されるトランスファゲート22を介して各インバータ
23に供給されている。これら各インバータ23の出力
は上記第4図に示すように構成されたパリティ−/′ 生成回路30に前記データDoないしD7として並列に
供給されるとともに、各送信バッファ20内のインバー
タ24に供給されている。これら各インバータ24の出
力は、反転クロック信号nによりスイッチ制御されるト
ランスファゲート25を介して上記各インバータ23の
入力側に帰還されている。
This serial data transmission circuit is connected in multiple stages with transmission buffers 20 whose number corresponds to the number of bits of the transmission data, and for example, 8-bit transmission data TDO to TD7 outputted from the CPU etc. via an internal bus are sent to each transmission buffer. It is supplied in parallel to the inverter 21 in the buffer 20. The output of this inverter 21 is sent via a transfer gate 22 which is switch-controlled by a control signal IB synchronized with the output clock signal CLK, in order to take in each transmission data from the internal bus of the CPU or the like to each transmission buffer 20. It is supplied to each inverter 23. The outputs of these inverters 23 are supplied in parallel as the data Do to D7 to the parity -/' generation circuit 30 configured as shown in FIG. ing. The output of each of these inverters 24 is fed back to the input side of each of the inverters 23 via a transfer gate 25 whose switch is controlled by an inverted clock signal n.

すなわち、各送信バッファ20内ではインバータ23.
24とトランスファゲート25とで正帰還回路形式のデ
ータラッチ回路が構成されている。そしてそのデータラ
ッチ点である回路点26にはクロック信号CLK同期の
シフトパルス信号SPによりスイッチ制御されるトラン
スファゲート27および上記反転りOツク信号CLKに
よりスイッチ制御されるトランスファゲート28が直列
に接続されており、下位ビットの送信バッファ20内の
上記トランスファゲート28の一端が上位ビットの送信
バッファ20内の回路点26に接続され、最上位ビット
、すなわちデータTD7が供給される送信バッファ20
内の上記トランスファゲート28の一端には上記パリテ
ィ−生成回路30から出力される奇数もしくは偶数のパ
リティ−ビットが供給されるようになっている。
That is, within each transmission buffer 20, an inverter 23.
24 and the transfer gate 25 constitute a data latch circuit in the form of a positive feedback circuit. A transfer gate 27 whose switch is controlled by a shift pulse signal SP synchronized with the clock signal CLK and a transfer gate 28 whose switch is controlled by the inverted OFF signal CLK are connected in series to the circuit point 26 which is the data latch point. One end of the transfer gate 28 in the transmission buffer 20 for lower bits is connected to the circuit point 26 in the transmission buffer 20 for upper bits, and the transmission buffer 20 is supplied with the most significant bit, that is, data TD7.
Odd or even parity bits outputted from the parity generating circuit 30 are supplied to one end of the transfer gate 28 in the parity generating circuit 30.

このシリアルデータ送信回路では、クロック信号CLK
同期の制御信号IBによりトランスファゲート22が開
かれると、8ピツトの送信データTDOないしTD7が
各送信バッラア20内の回路点26に取り込まれる。こ
のデータはその後、各インバータ23を介して前記デー
タDoないしD7としてパリティ−生成回路30に並列
に供給される。
In this serial data transmission circuit, the clock signal CLK
When the transfer gate 22 is opened by the synchronization control signal IB, eight pits of transmission data TDO to TD7 are taken into the circuit point 26 in each transmission buffer 20. This data is then supplied in parallel to the parity generation circuit 30 via each inverter 23 as the data Do to D7.

パリティ−生成回路30はこれらのデータDOないしD
7からパリティ−を生成し、最上位ビットの送信バッフ
ァ20に出力する。他方、各送信バッファ20内ではト
ランスファゲート25が反転クロック信号CLKにより
開かれ、前記したデータラッチ回路により各1ビツトの
入力データがラッチされる。その後は、各送信バッファ
20内のラッチデータがシフトパルス信号SPおよび反
転クロック信号CLKにより、各送信バッファ20内の
トランスファゲート28.27を介して下位ビットの送
信バッファ20に転送され、最下位ビットの送信バッフ
ァ20からシリアル送信データSTDとして1ビツトず
つ順次出力される。このとき、このデータSTDの末尾
に上記パリティ−生成回路30で生成されたパリティ−
ビットが付加されることになる。
The parity generation circuit 30 generates these data DO to D.
7 to generate parity and output it to the transmission buffer 20 of the most significant bit. On the other hand, in each transmission buffer 20, the transfer gate 25 is opened by the inverted clock signal CLK, and each 1-bit input data is latched by the data latch circuit described above. Thereafter, the latch data in each transmission buffer 20 is transferred to the lower bit transmission buffer 20 via the transfer gate 28, 27 in each transmission buffer 20 by the shift pulse signal SP and inverted clock signal CLK, and The data is sequentially output one bit at a time from the transmission buffer 20 as serial transmission data STD. At this time, the parity generated by the parity generation circuit 30 is added to the end of this data STD.
bits will be added.

第6図は上記従来のパリティ−生成回路をシリアルデー
タの受信を行なうシリアルデータ受信回路に使用した場
合の構成を示す回路図である。このシリアルデータ受信
回路には受信データのビット数に対応した数の受信バッ
ファ40が多段接続されている。これら各受信バッファ
40それぞれは同様に構成されている。すなわち、この
受信バッファ40には、前記第5図の送信バッファ20
と同様に、インバータ41.42および反転クロック信
号CLKでスイッチ制御されるトランス77ゲート43
からなり回路点44をデータラッチ点とする正帰還回路
形式のデータラッチ回路が設けられている。そして上記
回路点44にはシフトパルス信号SPによりスイッチ制
御されるトランスファゲート45および反転クロック信
号CLKによりスイッチ制御されるトランスファゲート
46が直列に接続されている。
FIG. 6 is a circuit diagram showing a configuration in which the conventional parity generating circuit described above is used in a serial data receiving circuit for receiving serial data. This serial data receiving circuit has multiple receiving buffers 40 connected in a number corresponding to the number of bits of received data. Each of these reception buffers 40 is configured similarly. That is, this reception buffer 40 includes the transmission buffer 20 of FIG.
Similarly, the transformer 77 gate 43 is switch-controlled by the inverters 41 and 42 and the inverted clock signal CLK.
A data latch circuit in the form of a positive feedback circuit with circuit point 44 as a data latch point is provided. A transfer gate 45 whose switch is controlled by the shift pulse signal SP and a transfer gate 46 whose switch is controlled by the inverted clock signal CLK are connected in series to the circuit point 44.

そして上記各インバータ41の出力は前記第4−に示す
ように構成されたパリティ−生成回路30に前記データ
DoないしD7として並列に供給され、さらに上記イン
バータ41の出力はアンドゲート47の一方入力端にも
供給されている。この各アンドゲート47の他方入力端
には各受信バッファ40から受信データを出力させるた
めのクロック信号CLK同期の制御信号Blが供給され
、受信された8ビツトのデータXDOないしXD7がこ
れら各アンドゲート47から出力されるようになってい
る。
The outputs of the inverters 41 are supplied in parallel to the parity generation circuit 30 configured as shown in the fourth section as the data Do to D7, and the outputs of the inverters 41 are fed to one input terminal of an AND gate 47. is also supplied. A control signal Bl synchronized with a clock signal CLK for outputting received data from each receiving buffer 40 is supplied to the other input terminal of each AND gate 47, and the received 8-bit data XDO to XD7 is input to each of these AND gates. 47.

また下位ビットの受信バッファ40内の上記トランスフ
ァゲート46の一端には上位ビットの受信バッファ40
内の回路点44が接続され、最上位ビットの受信バッフ
ァ40内の上記トランス77ゲート46の一端には前記
第5図のシリアルデータ受信回路に入力されるシリアル
データSTDが供給される。
Further, one end of the transfer gate 46 in the lower bit receiving buffer 40 is connected to the upper bit receiving buffer 40.
The serial data STD input to the serial data receiving circuit of FIG. 5 is supplied to one end of the transformer 77 gate 46 in the receiving buffer 40 of the most significant bit.

さらにこのシリアルデータSTDの末尾に付加された受
信パリティ−PARが、上記パリティ−生成回路30で
生成されたパリティ−とともにパリティ−比較回路50
に供給され、ここで両パリティ−の一致、不一致が検出
されてパリティ−チェックが行われるようになっている
Furthermore, the reception parity PAR added to the end of this serial data STD is sent to the parity comparison circuit 50 along with the parity generated by the parity generation circuit 30.
Here, a match or mismatch between the two parities is detected and a parity check is performed.

このシリアルデータ受信回路では、反転クロック信号C
LKおよびシフトパルス信号SPによりトランスフ1ゲ
ート46.45が開かれ、シリアルデータSTDが受信
バッファ40内の回路点44に順次取り込まれ、かつ各
インバータ41を介してパリティ−生成回路30に並列
に供給される。その後、トランスファゲート43が開か
れてそれぞれ1ビツトのデータが各受信バッファ40で
ラッチされる。その間にパリティ−生成回路30はこれ
らのラッチデータからパリティ−ビットを生成して比較
回路50に出力する。他方、シリアルデータSTDの末
尾に付加された受信パリティ−PARが比較回路50に
供給されると、この比較回路50は両パリティ−を比較
してパリティ−エラーチェックを行なう。
In this serial data receiving circuit, the inverted clock signal C
The transfer 1 gate 46.45 is opened by LK and the shift pulse signal SP, and the serial data STD is sequentially fetched into the circuit point 44 in the reception buffer 40, and is supplied in parallel to the parity generation circuit 30 via each inverter 41. be done. Thereafter, transfer gates 43 are opened and one bit of data is latched in each receive buffer 40. Meanwhile, the parity generation circuit 30 generates parity bits from these latch data and outputs them to the comparison circuit 50. On the other hand, when the received parity PAR added to the end of the serial data STD is supplied to the comparison circuit 50, the comparison circuit 50 compares both parities and performs a parity error check.

そしてこのエラーチェックの結果、受信データXDoな
いしXD7に誤りがあれば、図示しない回路でこれが訂
正される。
As a result of this error check, if there is an error in the received data XDo to XD7, the error is corrected by a circuit not shown.

[背景技術の問題点] ところで、上記したような従来のシリアルデータ送受信
回路ではパリティ−ビット生成のために送受信データを
パラレルにパリティ−生成回路30に取り込むため、こ
のパリティ−生成回路30は第4図に示すように、必然
的に大きな回路構成となってしまう。それに加えて、シ
リアルデータ転送回路で使用されるパリティ−ビットは
、生成されると直ぐに、送信時では送信バッファ20に
、受信時では比較回路50にそれぞれ取り込まれるため
、パリティ−生成回路30の使用頻度は極めて低く、回
路的に無駄である。
[Problems with the Background Art] Incidentally, in the conventional serial data transmitting/receiving circuit as described above, transmitting/receiving data is taken in parallel to the parity generating circuit 30 for parity bit generation. As shown in the figure, this inevitably results in a large circuit configuration. In addition, the parity bit used in the serial data transfer circuit is immediately taken into the transmission buffer 20 at the time of transmission and into the comparison circuit 50 at the time of reception, so that the parity generation circuit 30 is not used. The frequency is extremely low and it is wasteful in terms of circuitry.

[発明の目的コ この発明は上記のような事情を考慮してなされたもので
ありその目的は、従来、使用頻度の削に大きな回路構成
を必要とするシリアルデータ転送時におけるパリティ−
生成回路を極めて簡単な回路で実現することにある。
[Purpose of the Invention] This invention was made in consideration of the above circumstances, and its purpose is to improve parity during serial data transfer, which conventionally requires a large circuit configuration to reduce the frequency of use.
The goal is to realize a generation circuit with an extremely simple circuit.

[発明の概要] 上記目的を達成するためこの発明にあっては、シリアル
データが供給され、このデータの一方レベルの入力回数
をバイナリカウンタでカウントすることにより、シリア
ルデータのパリティ−ビットを形成するようにしている
[Summary of the Invention] In order to achieve the above object, in this invention, serial data is supplied, and a parity bit of the serial data is formed by counting the number of inputs of one level of this data with a binary counter. That's what I do.

[発明の実施例] 以下、図面を参照してこの発明の一実施例を説明する。[Embodiments of the invention] Hereinafter, one embodiment of the present invention will be described with reference to the drawings.

第1図はこの発明に係るパリティ−生成回路の構成を示
す回路図である。このパリティ−生成回路は、シリアル
な送受信データからパリティ−ビットを生成するバイナ
リカウンタ回路60と、このバイナリカウンタ回路60
で生成されるパリティ−ビットのレベルを偶数パリティ
−もしくは奇数パリティ−に応じて選択するパリティ−
レベル選択回路80とで構成されている。
FIG. 1 is a circuit diagram showing the configuration of a parity generation circuit according to the present invention. This parity generation circuit includes a binary counter circuit 60 that generates parity bits from serial transmitted and received data, and a binary counter circuit 60 that generates parity bits from serial transmitted and received data.
Parity generated by selecting the bit level according to even parity or odd parity
It is composed of a level selection circuit 80.

上記バイナリカウンタ回路60は、直列接続された2個
のインバータ61と62およびインバータ62の出力端
とインバータ61の入力端との間に挿入されたトランス
ファゲート63とからなる正帰還回路形式のデータラッ
チ回路64、同様に2個のインバータ65と66I5よ
びトランスファゲート67からなるデータラッチ回路6
8、上記一方のデータラッチ回路64と他方のデータラ
ッチ回路68との間に挿入されたトランスファゲート6
9、上記他方のデータラッチ回路68の初段のインバー
タ65の出力端と一方のデータラッチ回路64の初段の
インバータ61の入力端との間に挿入されたトランスフ
ァゲート70、上記他方のデータラッチ回路68の初段
のインバータ61の入力端とアース電位Vss印加点(
論理“″0″レベルの点)との間に挿入されたトランス
77ゲート71、送信もしくは受信用のシリアルデータ
SToおよびこのデータをサンプリングするためのサン
プリング信号SMPが入力されるアンドゲート72、こ
のアンドゲート72の出力を反転するインバータ73で
構成されている。
The binary counter circuit 60 is a data latch in the form of a positive feedback circuit consisting of two series-connected inverters 61 and 62 and a transfer gate 63 inserted between the output terminal of the inverter 62 and the input terminal of the inverter 61. A data latch circuit 6 consisting of a circuit 64, two inverters 65 and 66I5, and a transfer gate 67.
8. Transfer gate 6 inserted between the one data latch circuit 64 and the other data latch circuit 68
9. Transfer gate 70 inserted between the output terminal of the first-stage inverter 65 of the other data latch circuit 68 and the input terminal of the first-stage inverter 61 of one data latch circuit 64; the other data latch circuit 68; The input terminal of the first stage inverter 61 and the ground potential Vss application point (
a transformer 77 inserted between the logic "0" level point), a gate 71, an AND gate 72 to which serial data STo for transmission or reception and a sampling signal SMP for sampling this data are input; It is composed of an inverter 73 that inverts the output of the gate 72.

そして上記トランスファゲート63と69は上記アンド
ゲート72の出力で、トランスファゲート67と70は
インバータ73の出力でそれぞれスイッチ制御されるよ
うになっており、さらに上記トランスファゲート71は
各データの送、受信開始時毎に、図示しない制御回路か
ら出力されるリセット制御信号R8でスイッチ制御され
るようになっている。
The transfer gates 63 and 69 are switch-controlled by the output of the AND gate 72, and the transfer gates 67 and 70 are controlled by the output of the inverter 73. Furthermore, the transfer gate 71 is configured to transmit and receive data. The switch is controlled by a reset control signal R8 outputted from a control circuit (not shown) at each start time.

上記パリティ−レベル選択回路80は、上記バイナリカ
ウンタ回路60内のデータラッチ回路68の出力が供給
されるインバータ81、こめインバータ81の出力が一
端に供給されるトランスファゲート82、上記データラ
ッチ回路68の出力が一端に供給され、他端が上記トラ
ンスファゲート82の他端と共通接続されたトランスフ
ァゲートa3、上記両トランスファゲート82.83の
他端共通接続点84に一端が接続されたトランスファゲ
ート85から構成されており、上記トランスファゲート
83には奇数パリティ−1偶数パリティ−を選択するた
めの制御信号O/Eが供給され、トランスファゲート8
2にはこの信号0/Eがインバータ86を介して供給さ
れている。また、上記トランスファゲート85はバリテ
ィー生成タイミング信号Tによりスイッチ制御されるよ
うになっている。
The parity level selection circuit 80 includes an inverter 81 to which the output of the data latch circuit 68 in the binary counter circuit 60 is supplied, a transfer gate 82 to which the output of the inverter 81 is supplied, and a transfer gate 82 to which the output of the data latch circuit 68 in the binary counter circuit 60 is supplied. From a transfer gate a3 whose output is supplied to one end and whose other end is commonly connected to the other end of the transfer gate 82, and from a transfer gate 85 whose one end is connected to the other end common connection point 84 of both transfer gates 82 and 83. The transfer gate 83 is supplied with a control signal O/E for selecting odd parity - 1 even parity.
2 is supplied with this signal 0/E via an inverter 86. Further, the transfer gate 85 is switch-controlled by the parity generation timing signal T.

このような構成のパリティ−生成回路において、バイナ
リカウンタ回路60はシリアルデータSTDとして“1
″レベルが入力されるとその出力、すなわちデータラッ
チ回路68の出力が反転する。すなわち、電源の投入直
後ではリセット信号R8によりトランスファゲート71
が開かれ、データラッチ回路68内のインバータ65の
入力が“OI+レベル、出力が“1”レベルにされ、さ
らにインバータ66の出力が0”レベルにされる。この
とき、シリアルデータSTDは“OI+レベルにされて
おり、“1°゛レベルであるインバータ73の出力でト
ランスファゲート67と70が開かれている。従って、
初期の状態ではトランスファゲート70を介してデータ
ラッチ回路64内のインバータ61の入力が“1″レベ
ルにされ、このインバータ61の出力が110 IIレ
ベルにされ、さらにインバータ62の出力が1”レベル
にされる。
In the parity generation circuit having such a configuration, the binary counter circuit 60 outputs "1" as the serial data STD.
'' level is input, its output, that is, the output of the data latch circuit 68, is inverted. In other words, immediately after the power is turned on, the transfer gate 71 is inverted by the reset signal R8.
is opened, the input of the inverter 65 in the data latch circuit 68 is set to the "OI+" level, the output is set to the "1" level, and the output of the inverter 66 is set to the "0" level. At this time, the serial data STD is at the "OI+" level, and the transfer gates 67 and 70 are opened by the output of the inverter 73, which is at the "1°" level. Therefore,
In the initial state, the input of the inverter 61 in the data latch circuit 64 is set to the "1" level via the transfer gate 70, the output of this inverter 61 is set to the 110 II level, and the output of the inverter 62 is set to the 1" level. be done.

次にシリアルデータSTDとしてまず始めに” 1 ”
レベルが入力されたとする。これによりアンドゲート7
2から“1″レベルの信号が出力され、上記トランスフ
ァゲート67と70に変わってトランスファゲート63
と69が開かれる。トランスファゲート63が開かれる
ことにより、データラッチ回路64が動作してインバー
タ62の゛1″レベル出力がラッチされると同時に、ト
ランスファゲート69を介してこのラッチ出力がデータ
ラッチ回路68に出力される。従って、このとき、デー
タラッチ回路68の出力は゛1″レベルにされる。
Next, first of all, "1" as serial data STD.
Assume that a level is input. This allows and gate 7
A "1" level signal is output from the transfer gate 63 instead of the transfer gates 67 and 70.
and 69 will be opened. When the transfer gate 63 is opened, the data latch circuit 64 operates to latch the "1" level output of the inverter 62, and at the same time, this latch output is output to the data latch circuit 68 via the transfer gate 69. Therefore, at this time, the output of the data latch circuit 68 is set to the "1" level.

この後、アンドゲート72の出力は゛′O″レベルにさ
れ、前記と同様にトランスファゲート67と70が開か
れるので、データラッチ回路68が動作してインバータ
66の゛′1′ルベル出力がラッチされると同時に、ト
ランスファゲート70を介してこのラッチ出力がデータ
ラッチ回路64に出力される。そしてこの状態は次にシ
リアルデータSTDとして“″1″レベルが入力される
まで続く。そして次にシリアルデータSTDとして゛′
1゛°レベルが入力されると、トランス77ゲート63
と69が開かれ、データラッチ回路64が動作してイン
バータ62の“°0”レベル出力がラッチされると同時
に、トランスファゲート69を介してこのラッチ出力が
データラッチ回路68に出力される。従って、このとき
、データラッチ回路68の出力は゛′0″レベルに反転
する。以下、同様にして、データラッチ回路68の出力
はシリアルデータSTDとしてII 1 I+レベルが
入力される毎に反転する。
After this, the output of the AND gate 72 is set to the ``O'' level, and the transfer gates 67 and 70 are opened in the same way as described above, so the data latch circuit 68 operates and the ``1'' level output of the inverter 66 is latched. At the same time, this latch output is outputted to the data latch circuit 64 via the transfer gate 70.This state continues until the next "1" level is input as the serial data STD. And then as serial data STD ゛′
When the 1° level is input, the transformer 77 gate 63
and 69 are opened, and the data latch circuit 64 operates to latch the "°0" level output of the inverter 62, and at the same time, this latch output is output to the data latch circuit 68 via the transfer gate 69. Therefore, at this time, the output of the data latch circuit 68 is inverted to the "0" level. Similarly, the output of the data latch circuit 68 is inverted every time the II 1 I+ level is inputted as the serial data STD.

この結果、バイナリカウンタ回路60の出力はシリアル
データSTDに対応した偶数パリティ−となる。このバ
イナリカウンタ回路60からの出力はパリティ−レベル
選択回路80において、制御信号0/Eが“1”レベル
にされている偶数パリティ−選択時にはトランス77ゲ
ート83を介してそのままのレベルで出力され、制御信
号0/Eが“O”レベルにされている奇数パリティ−選
択時にはインバータ81で反転された後にトランスファ
ゲート82を介して出力され、さらに制御信号Tのタイ
ミングでトランス77ゲート85を介して出力される。
As a result, the output of the binary counter circuit 60 becomes even parity corresponding to the serial data STD. The output from the binary counter circuit 60 is outputted at the same level through the transformer 77 gate 83 in the parity level selection circuit 80 when an even parity is selected in which the control signal 0/E is set to the "1" level. When odd parity is selected with control signal 0/E set to "O" level, it is inverted by inverter 81 and then output via transfer gate 82, and further output via transformer 77 gate 85 at the timing of control signal T. be done.

このように上記実施例回路は7個のインバータと8個の
トランス77ゲートとから構成されており、各インバー
タにCMOSインバータを用い、トランスファゲートと
してNチャネルMOSトランジスタを用いれば、合計で
22個のMOSトランジスタで構成することができる。
As described above, the above embodiment circuit is composed of seven inverters and eight transformer 77 gates, and if a CMOS inverter is used for each inverter and an N-channel MOS transistor is used as a transfer gate, a total of 22 It can be configured with a MOS transistor.

前記第4図に示す従来回路を0MO8構成で実現する場
合、一つの排他的論理和回路は16個のMoSトランジ
スタで構成され、全体で129個ものMoSトランジス
タが必要なので、この実施例回路によれば素子数を従来
よりも大幅に削減できる。
When the conventional circuit shown in FIG. 4 is realized with a 0MO8 configuration, one exclusive OR circuit is composed of 16 MoS transistors, and a total of 129 MoS transistors are required. The number of elements can be significantly reduced compared to conventional methods.

第2図および第3図はそれぞれこの発明の応用例を示す
。第2図は上記実施例のパリティ−生成回路をシリアル
データの送信を行なうシリアルデータ送信回路に使用し
た場合の構成を示す回路図である。このシリアルデータ
送信回路には送信データのビット数に対応した数の送信
バッファ90が多段接続されており、CP(J等から内
部バスを介して出力される例えば8ビツトの送信データ
TOOないしTD7が各送信バッファ90内のインバー
タ91に並列に供給される。このインバータ91の出力
は、上記CPU等の内部バスから各送信バッファ90に
各送信データを取込むための、クロック信号CLKに同
期した制御信号IBによりスイッチ制御されるトランス
ファゲート92を介して各インバータ93に供給されて
いる。これら各インバータ93の出力は各インバータ9
4に供給されてける。これら各インバータ94の出力は
、反転クロック信号CLKによりスイッチ制御されるト
ランスファゲート95を介して上記各インバータ93の
入力側に帰還されている。すなわち、各送信バッファ9
0内ではインバータ93と94およびトランスファゲー
ト95とで正帰還回路形式のデータラッチ回路が構成さ
れている。そしてこのデータラッチ回路のデータラッチ
点である回路点96には、前記反転クロック信号CLK
でスイッチ制御されるトランスファゲート97および前
記シフトパルス信号SPでスイッチ制御されるトランス
ファゲート98が直列に接続されている。なお、最下位
ビット、すなわちデータTDOが供給される送信バッフ
ァ90では上記トランスファゲート97.98が省略さ
れ、その回路点96からシリアル送信データSTDが出
力されるようになっているとともに、インバータ94の
入力端にはパリティ−の出力タイミング時に開かれるト
ランス77ゲート99の一端が接続されている。また上
記最下位ビットの送信バッファ90から出力されるシリ
アル送信データSTDが上記第1図のように構成された
パリティ−生成回路100に順次供給され、ここで前記
のようにして生成されたパリティ−が上記トランスファ
ゲート99の他端に供給される。
FIGS. 2 and 3 each show an example of application of the present invention. FIG. 2 is a circuit diagram showing a configuration when the parity generation circuit of the above embodiment is used in a serial data transmission circuit for transmitting serial data. This serial data transmission circuit is connected in multiple stages with transmission buffers 90 whose number corresponds to the number of bits of the transmission data. The output of this inverter 91 is supplied in parallel to the inverter 91 in each transmission buffer 90.The output of this inverter 91 is controlled in synchronization with the clock signal CLK to take in each transmission data from the internal bus of the CPU etc. to each transmission buffer 90. It is supplied to each inverter 93 via a transfer gate 92 whose switch is controlled by signal IB.The output of each of these inverters 93 is
4 can be supplied. The output of each of these inverters 94 is fed back to the input side of each of the inverters 93 through a transfer gate 95 whose switch is controlled by an inverted clock signal CLK. That is, each transmission buffer 9
0, inverters 93 and 94 and transfer gate 95 constitute a data latch circuit in the form of a positive feedback circuit. The circuit point 96, which is the data latch point of this data latch circuit, is connected to the inverted clock signal CLK.
A transfer gate 97 whose switch is controlled by the shift pulse signal SP and a transfer gate 98 whose switch is controlled by the shift pulse signal SP are connected in series. The transfer gates 97 and 98 are omitted in the transmission buffer 90 to which the least significant bit, that is, the data TDO is supplied, and the serial transmission data STD is output from the circuit point 96. One end of the transformer 77 gate 99, which is opened at the parity output timing, is connected to the input end. Further, the serial transmission data STD outputted from the transmission buffer 90 of the least significant bit is sequentially supplied to the parity generation circuit 100 configured as shown in FIG. is supplied to the other end of the transfer gate 99.

このシリアルデータ送信回路では、制御信号■Bにより
トランスファゲート92が開かれると、8ビツトの送信
データTDOないしT D ’7が各送信バッファ90
内の回路点96に取り込まれる。その後、トランスファ
ゲート95が反転クロック信号CLKにより開かれ、前
記のデータラッチ回路により各1ビツトの入力データが
ランチされ、次に各送信バッファ90内のラッチデータ
がシフトパルス信号SPおよび反転クロック信号CLK
により、各送信バッファ90内のトランスファゲート9
7.98を介して順次、下位ビットの送信バッファ90
に転送され、最下位ビットの送信バッファ90からシリ
アル送信データSTDとして出力される。このとき、こ
のデータSTDはパリティ−生成回路100にも供給さ
れ、ここでパリティ−ビットが生成される。
In this serial data transmission circuit, when the transfer gate 92 is opened by the control signal ■B, 8-bit transmission data TDO to TD'7 are transferred to each transmission buffer 90.
The signal is taken into circuit point 96 within. Thereafter, the transfer gate 95 is opened by the inverted clock signal CLK, each 1-bit input data is launched by the data latch circuit, and then the latched data in each transmission buffer 90 is transferred to the shift pulse signal SP and the inverted clock signal CLK.
Accordingly, the transfer gate 9 in each transmission buffer 90
7.98 through the lower bit transmission buffer 90
and is output from the least significant bit transmission buffer 90 as serial transmission data STD. At this time, this data STD is also supplied to the parity generation circuit 100, where a parity bit is generated.

生成されたパリティ−ビットはトランスファゲート99
を介して最下位ビットの送信バッファ90に供給され、
ここでシリアル送信データSTDの末尾に付加されるこ
とになる。
The generated parity bits are transferred to the transfer gate 99.
is supplied to the least significant bit transmission buffer 90 via
Here, it is added to the end of the serial transmission data STD.

第3図は上記実施例のパリティ−生成回路をシリアルデ
ータの受信を行なうシリアルデータ受信回路に使用した
場合の構成を示す回路図である。
FIG. 3 is a circuit diagram showing a configuration when the parity generating circuit of the above embodiment is used in a serial data receiving circuit for receiving serial data.

このシリアルデータ受信回路にには前記第5図に示す従
来と同様の受信バッファ40が受信データのビット数に
対応した数だけ多段接続されている。
In this serial data receiving circuit, receiving buffers 40 similar to the conventional one shown in FIG. 5 are connected in multiple stages in a number corresponding to the number of bits of the received data.

そしてこの場合には、最上位ビットの受信バッファ40
内のインバータ41の出力が前記第1図に示すように構
成されたパリティ−生成回路100に順次供給されてい
る。
In this case, the most significant bit receive buffer 40
The output of the inverter 41 is sequentially supplied to a parity generation circuit 100 configured as shown in FIG.

このシリアルデータ受信回路では、反転クロック信号C
LKおよびシフトパルス信号SPによりトランスファゲ
ート46.45が開かれ、シリアルデータSTDが受信
バッファ40内の回路点44に順次取り込まれると同時
にパリティ−生成回路100にも供給される。その後、
トランスファゲート43が開かれてそれぞれ1ビツトの
データが各受信バッファ40でラッチされる間にパリテ
ィ−生成回路100は供給データからパリティ−ビット
を生成して比較回路50に出力する。他方、シリアルデ
ータSTDの末尾に付加された受信パリティ−PARが
比較回路50に供給されると、この比較回路50は両パ
リティ−を比較してパリティ−エラーチェックを行なう
。そしてこのエラーチェックの結果、受信データXDO
ないしXD7に誤りがあれば、図示しない回路でこれが
訂正される。
In this serial data receiving circuit, the inverted clock signal C
Transfer gates 46 and 45 are opened by LK and shift pulse signal SP, and serial data STD is sequentially fetched into circuit point 44 in reception buffer 40 and simultaneously supplied to parity generation circuit 100. after that,
While the transfer gate 43 is opened and one bit of data is latched in each receive buffer 40, the parity generation circuit 100 generates a parity bit from the supplied data and outputs it to the comparison circuit 50. On the other hand, when the received parity PAR added to the end of the serial data STD is supplied to the comparison circuit 50, the comparison circuit 50 compares both parities and performs a parity error check. As a result of this error check, the received data
If there is an error in XD7, it is corrected by a circuit not shown.

このように上記応用例のシリアルデータ送受信回路では
各送信バッファ90もしくは受信バッファ40にシリア
ルデータを順次転送している際にパリティ−生成回路1
00でパリティ−を生成するようにしているので、従来
のパリティ−生成回路に比較してバリティー生成回路1
00の使用頻度を高めることができる。
In this way, in the serial data transmitting/receiving circuit of the above application example, when serial data is sequentially transferred to each transmitting buffer 90 or receiving buffer 40, the parity generating circuit 1
Since the parity is generated using 00, the parity generation circuit 1 is
00 can be used more frequently.

なお、この発明は上記実施例に限定されるものではなく
種々の変形が可能であることはいうまでもない。例えば
、上記実施例ではバイナリカウンタ回路60として基本
的に二つのデータラッチ回路64.68を使用した形式
のものについて説明したが、これはバイナリカウンタ回
路であればどのような形式のものであっても使用が可能
である。
It goes without saying that the present invention is not limited to the above-mentioned embodiments, and that various modifications can be made. For example, in the above embodiment, the binary counter circuit 60 basically uses two data latch circuits 64 and 68, but this can be any type of binary counter circuit. can also be used.

[発明の効果] 以上説明したようにこの発明によれば、使用頻度が高く
、しかも極めて簡単な回路で実現できるシリアルデータ
転送時におけるパリティ−生成回路を提供することがで
きる。
[Effects of the Invention] As described above, according to the present invention, it is possible to provide a parity generation circuit for serial data transfer that is frequently used and can be realized with an extremely simple circuit.

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

第1図はこの発明に係るパリティ−生成回路の一実施例
の構成を示す回路図、第2図および第3図はそれぞれこ
の発明の応用例の構成を示す回路図、第4図は従来のパ
リティ−生成回路の回路図、第5図および第6図はそれ
ぞれ上記従来のパリティ−生成回路を使用した応用例回
路の回路図である。 40・・・受信バッファ、60・・・バイナリカウンタ
回路、80・・・パリティ−レベル選択回路、90・・
・送信バッファ、100・・・パリティ−生成回路。 出願人代理人 弁理士 鈴江武彦 すり 第3図
FIG. 1 is a circuit diagram showing the configuration of an embodiment of the parity generation circuit according to the present invention, FIGS. 2 and 3 are circuit diagrams showing the configuration of an applied example of the present invention, and FIG. The circuit diagrams of the parity generation circuit, FIGS. 5 and 6, are circuit diagrams of application example circuits using the above-mentioned conventional parity generation circuit, respectively. 40... Reception buffer, 60... Binary counter circuit, 80... Parity-level selection circuit, 90...
- Transmission buffer, 100... Parity generation circuit. Applicant's agent Patent attorney Takehiko Suzue Figure 3

Claims (1)

【特許請求の範囲】[Claims] シリアルデータが供給され、このシリアルデータの一方
レベルの入力回数をカウントするバイナリカウンタによ
り上記シリアルデータのパリティーを形成するようにし
たことを特徴とするパリティー生成回路。
1. A parity generation circuit characterized in that serial data is supplied and a binary counter that counts the number of inputs of one level of the serial data forms parity of the serial data.
JP12876485A 1985-06-13 1985-06-13 Parity generation circuit Pending JPS61287335A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP12876485A JPS61287335A (en) 1985-06-13 1985-06-13 Parity generation circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP12876485A JPS61287335A (en) 1985-06-13 1985-06-13 Parity generation circuit

Publications (1)

Publication Number Publication Date
JPS61287335A true JPS61287335A (en) 1986-12-17

Family

ID=14992887

Family Applications (1)

Application Number Title Priority Date Filing Date
JP12876485A Pending JPS61287335A (en) 1985-06-13 1985-06-13 Parity generation circuit

Country Status (1)

Country Link
JP (1) JPS61287335A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2003021453A2 (en) * 2001-08-29 2003-03-13 Analog Devices, Inc. Generic serial port architecture and system

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2003021453A2 (en) * 2001-08-29 2003-03-13 Analog Devices, Inc. Generic serial port architecture and system
WO2003021453A3 (en) * 2001-08-29 2004-03-18 Analog Devices Inc Generic serial port architecture and system
US7114093B2 (en) 2001-08-29 2006-09-26 Analog Devices, Inc. Generic architecture and system for a programmable serial port having a shift register and state machine therein

Similar Documents

Publication Publication Date Title
US5777501A (en) Digital delay line for a reduced jitter digital delay lock loop
US20050195008A1 (en) Hybrid latch flip-flop
US20080080262A1 (en) Data alignment circuit and data alignment method for semiconductor memory device
US6696874B2 (en) Single-event upset immune flip-flop circuit
EP0440356A2 (en) Analog-to-digital converter with minimized metastability
US6769044B2 (en) Input/output interface and semiconductor integrated circuit having input/output interface
KR950011302B1 (en) Circuit for detecting data accord
JPH11177639A (en) Data transmission equipment
US7692564B2 (en) Serial-to-parallel conversion circuit and method of designing the same
US6175885B1 (en) System for series to parallel conversion of a low-amplitude and high frequency signal
JPS61287335A (en) Parity generation circuit
JPH10256886A (en) Signal multiplexing circuit
US11152042B2 (en) Inversion signal generation circuit
US6859070B2 (en) Semiconductor integrated circuit device having flip-flops that can be reset easily
JP4077123B2 (en) Differential signal output circuit
US5608741A (en) Fast parity generator using complement pass-transistor logic
KR100353533B1 (en) Delay locked loop circuit
JPH0247038B2 (en)
US20200402600A1 (en) Bit data shifter
US20200328743A1 (en) Signal-multiplexing device
KR100451765B1 (en) parity error detection circuit
KR0183752B1 (en) Output port having a delay circuit
KR910009093B1 (en) Coded mark inversion coding circuit
KR100213256B1 (en) 5 bit and 16 bit cyclic redundancy check circuit
JPH0749680Y2 (en) Drive circuit of shift register