JPH0540563A - Key switch controller - Google Patents

Key switch controller

Info

Publication number
JPH0540563A
JPH0540563A JP3196737A JP19673791A JPH0540563A JP H0540563 A JPH0540563 A JP H0540563A JP 3196737 A JP3196737 A JP 3196737A JP 19673791 A JP19673791 A JP 19673791A JP H0540563 A JPH0540563 A JP H0540563A
Authority
JP
Japan
Prior art keywords
key switch
information
output
unit
data
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
JP3196737A
Other languages
Japanese (ja)
Inventor
Tetsuo Takagi
哲男 高木
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.)
Seiko Epson Corp
Original Assignee
Seiko Epson 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 Seiko Epson Corp filed Critical Seiko Epson Corp
Priority to JP3196737A priority Critical patent/JPH0540563A/en
Publication of JPH0540563A publication Critical patent/JPH0540563A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To judge which key switch obtains state data by a CPU even without providing data holding circuits as many as all the key switches in the key switch controller by providing a function to output the state data of the key switch from an output part and cycle information showing which key switch obtains the state data. CONSTITUTION:This controller is provided with a count part 2 to input a clock signal, information converter 4 to input the data of the count part 2 and to generate plural decode signals corresponding to respective states, plural key switches 13 to be controlled by these decode signals, data input circuit to input the states of the key switches 13 and to hold the data, and output part 18 to output the data of the count part 2 and the key switch state data in the data input circuit.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は、キー・スイッチ制御装
置に関し、特にキー・スイッチ制御用出力駆動装置の制
御方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a key switch control device, and more particularly to a control method of an output drive device for key switch control.

【0002】[0002]

【従来の技術】従来のキー・スイッチ制御装置は中央処
理装置(以後center processing u
nit より構成され、キー・スイッチは各入出力装置
に接続されており、キー・スイッチ制御はメモリ内部に
保持されたプログラム・デーダをCPUが実行する事に
より出力装置から周期性を有した特定の制御コードを複
数のキー・スイッチに出力し、複数のキー・スイッチ
は、各キー・スイッチのON−OFF状態を、入力装置
に対し伝えることで実現されていた。しかし、CPUは
その情報処理能力の多くをキー・スイッチ制御に占有さ
れるため、周期性を有した特定の制御コードをCPU以
外のカウンター回路に発生させ、周期的に全キー・スイ
ッチを走査しながらキー・スイッチと同数のデータ保持
回路に各キー・スイッチの状態を記憶させる方法が考え
られる。
2. Description of the Related Art A conventional key switch controller is a central processing unit (hereinafter referred to as "center processing unit").
The key switch is connected to each input / output device, and the key switch control is such that the CPU executes the program data held in the memory to cause the output device to have a specific periodicity. The control code is output to a plurality of key switches, and the plurality of key switches are realized by transmitting the ON-OFF state of each key switch to an input device. However, since most of the information processing capability of the CPU is occupied by key switch control, a specific control code having periodicity is generated in a counter circuit other than the CPU to periodically scan all key switches. However, a method of storing the state of each key switch in the same number of data holding circuits as the key switch can be considered.

【0003】[0003]

【発明が解決しようとする課題】しかし、従来技術では
キー・スイッチと同数のデータ保持回路が必要となる。
そこで、本発明は従来のこのような問題点を解決するた
め、回路素子数が少なく、CPUの負荷を低減させる事
の可能なキー・スイッチ制御が行える制御装置を提供す
ることを目的としている。
However, the prior art requires as many data holding circuits as there are key switches.
Therefore, in order to solve such a conventional problem, the present invention has an object to provide a control device which has a small number of circuit elements and can perform key switch control capable of reducing the load on the CPU.

【0004】[0004]

【課題を解決するための手段】上記問題点を解決するた
めに、本発明のキー・スイッチ制御装置は、クロック信
号を入力し該クロック信号を計測する計数部、該計数部
の計数情報を入力し計測情報を変換する情報変換部、該
情報変換部からの変換された情報を出力する出力駆動
部,該出力駆動部の出力端子に接続した複数のキー・ス
イッチより構成されるキー・スイッチ部,該キー・スイ
ッチ部からの情報を保持する入力制御部,該入力制御部
の情報を出力する出力部より構成されるキー・スイッチ
制御装置において,該計数部の情報と該情報に対応する
該キー・スイッチ部からの情報をともに出力処理する出
力部を有する事を特徴とする。
In order to solve the above-mentioned problems, a key switch controller according to the present invention inputs a clock signal, a counter for measuring the clock signal, and a count information of the counter. Information conversion section for converting measurement information, an output drive section for outputting the converted information from the information conversion section, and a key switch section composed of a plurality of key switches connected to output terminals of the output drive section A key switch control device comprising an input control unit for holding information from the key switch unit and an output unit for outputting information from the input control unit, the information corresponding to the counting unit and the information corresponding to the information. It is characterized in that it has an output section for outputting the information from the key switch section together.

【0005】[0005]

【作用】上記のように クロック信号を入力し該クロッ
ク信号を計測する計数部(以下カウンターと言う)のデ
ータを変換する情報変換部(以下デコーターと言う)の
データをキー・スイッチ用出力駆動装置の出力端子に出
力し、該出力端子で複数のキー・スイッチを駆動し、該
キー・スイッチの出力端子からのON−OFF状態デー
タをキー・スイッチ用入力制御部に取り込み、取り込ん
だデータと、取り込んだデータに対応するカウンターの
情報をCPUに転送する事により、入力制御部内のデー
タ保持回路数は全キー・スイッチ数の数分の一とする事
が出来る。
As described above, the data output from the information conversion section (hereinafter referred to as a "decoder") for converting the data of the counting section (hereinafter referred to as a "counter") for inputting the clock signal and measuring the clock signal is output to the key switch. Output to an output terminal of the key switch, drive a plurality of key switches with the output terminal, take in the ON-OFF state data from the output terminal of the key switch to the key switch input control unit, and the taken-in data, By transferring the information of the counter corresponding to the fetched data to the CPU, the number of data holding circuits in the input control unit can be reduced to a fraction of the total number of key switches.

【0006】[0006]

【実施例】以下、図面に従い本発明の構成及び実施例に
ついて説明する。図1は本発明のキー・スイッチ制御装
置の構成図である。 計数部2はクロック信号1を入力
しクロック・カウントを行い、その計数データ3を情報
変換部4及び出力部18に出力する。 情報変換部4で
は計数データのデコードを行い、常に複数のスイッチ群
の中から時分割して一つのスイッチ群を選択する為の信
号をキー・スイッチ制御用出力駆動部5に送り、該駆動
部5はキースイッチ部13に対し制御信号を出力する。
キースイッチ部13は各キー・スイッチのON/OF
F情報をキー・スイッチ制御用入力装置7に転送する。
キー・スイッチ制御用入力装置7は情報伝達出力12を
介して出力部18に対し該情報を転送する。出力部18
は計数部2からの計数データ3と,キー・スイッチ制御
用入力装置7のキー・スイッチのON/OFF情報をを
出力端子19を介しCPUに対し出力する。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS The configuration and embodiments of the present invention will be described below with reference to the drawings. FIG. 1 is a block diagram of a key switch control device of the present invention. The counting unit 2 inputs the clock signal 1 and performs clock counting, and outputs the count data 3 to the information converting unit 4 and the output unit 18. The information conversion unit 4 decodes the count data and sends a signal for selecting one switch group in a time-divisional manner from a plurality of switch groups to the key / switch control output drive unit 5, and the drive unit Reference numeral 5 outputs a control signal to the key switch unit 13.
The key switch unit 13 turns ON / OFF each key switch.
The F information is transferred to the key switch control input device 7.
The key switch control input device 7 transfers the information to the output unit 18 via the information transmission output 12. Output unit 18
Outputs the count data 3 from the counting unit 2 and ON / OFF information of the key switch of the key switch control input device 7 to the CPU via the output terminal 19.

【0007】図2は該計数部 及び情報変換部の回路構
成の1実施例である。 本回路はCLすなわちクロック
信号1をカウントするために3ビットの同期カウンタを
利用しており、デ−タ入力型フリップフロップ14の出
力Q0、Q1、Q2がCLの立上りエッジにより周期的
に変化する。 Q0、Q1、Q2は出力状態を8状態、
表現出来、該状態は情報変換部4において各状態に対応
する8本の出力信号6(OUT0〜OUT7)に変換さ
れる。 該出力信号はキー・スイッチ制御用出力駆動部
5に送られキー・スイッチ部13の制御を行う。図6に
CL、Q0〜Q2、OUT0〜OUT7のタイミング図
を示す。 情報変換部4からの出力信号6(OUT0〜
OUT7)は、ある一定期間一つの出力信号だけがLO
Wレベルとなり、該期間だけ該信号線に接続したスイッ
チ群のみ動作可能状態になる。図3はキ−・スイッチ群
13の一実施例である。 出力信号6はそれぞれダイオ
ードのアノード端子に接続しており、出力信号6がLO
Wの時のみカソード端子にLOWレベルを伝搬させ、出
力信号6がHIGHレベルの時はカソード端子はオープ
ン状態(電位が定まらない状態)となる。 該カソード
端子には複数のキー・スイッチの入力端子が接続してお
り、各出力信号6毎に8個のスイッチ・グループに分け
られているので 常にどれか一つのスイッチ・グループ
が周期的に選択される事になる。 OUT0に選択され
たスイッチ・グループに注目すると、選択期間において
はキー・スイッチの入力端子はLOW電位が与えられて
いる事になる。 この時あるキー・スイッチがON状態
であれば該キー・スイッチの出力端子にLOWが、OF
F状態の時にはオープン状態が現れる。 また非選択期
間においてはキー・スイッチのON/OFF状態に係わ
らずオープン状態が現れる。 出力端子IN0〜INn
にはそれぞれ異なったスイッチ・グループのスイッチ出
力端子がそれぞれ一つ接続しており、各スイッチ・グル
ープのスイッチ状態が時分割して出力される。図4はキ
ー・スイッチ制御用入力部の一実施例である。 キ−・
スイッチ部13からの出力端子IN0〜INnがキー・
スイッチ情報入力端子15に接続されておりキー・スイ
ッチ情報をデータ保持回路部10に取り込む事ができ
る。本実施例での保持回路数は全キ−・スイッチ数の8
分の1に抑えられている。比較の為に図8に従来のキ−
・スイッチ制御装置のブロック図、図9に従来の制御用
入力部を示す。 従来例ては全キ−・スイッチ数と同数
の保持回路を用意しキ−・スイッチ部が走査された時得
られるデータをすべで保持し、CPUは全保持回路を確
認することにより初めて必要な情報を入手していた。図
4はデータを取り込むにあたっては、キ−・スイッチ部
13からの出力端子IN0〜INnの出力状態はオープ
ンとLOWレベルの2状態であるため、データ保持回路
10に取り込む事ができるHIGH/LOW状態に変換
する必要がある事から、入力プルアップ回路9が設けら
れており、 16はオープン状態をHIGH状態に変換
するためのプルアップ抵抗である。 データの取り込み
は8個の各選択期間内にデータが取り込めるようにラッ
チ・クロック17(LC)が入力される。データ・ラッ
チ出力端子12を介してキー・スイッチ情報を出力部に
転送する。
FIG. 2 shows an embodiment of the circuit configuration of the counting section and the information converting section. This circuit uses a 3-bit synchronous counter to count CL, that is, the clock signal 1, and the outputs Q0, Q1 and Q2 of the data input type flip-flop 14 are periodically changed by the rising edge of CL. .. Q0, Q1, and Q2 have eight output states,
It can be expressed, and the state is converted into eight output signals 6 (OUT0 to OUT7) corresponding to each state in the information conversion unit 4. The output signal is sent to the key switch control output drive section 5 to control the key switch section 13. FIG. 6 shows a timing chart of CL, Q0 to Q2, and OUT0 to OUT7. An output signal 6 (OUT0 to OUT0 from the information conversion unit 4
OUT7) outputs only one output signal for a certain period of time.
It becomes the W level, and only the switch group connected to the signal line becomes operable only during the period. FIG. 3 shows an embodiment of the key switch group 13. The output signal 6 is connected to the anode terminal of the diode, and the output signal 6 is LO
Only when W, LOW level is propagated to the cathode terminal, and when the output signal 6 is HIGH level, the cathode terminal is in an open state (state in which the potential is not fixed). The input terminals of a plurality of key switches are connected to the cathode terminal, and each output signal 6 is divided into eight switch groups, so one of the switch groups is always selected periodically. Will be done. Focusing on the switch group selected as OUT0, the LOW potential is applied to the input terminal of the key switch during the selection period. At this time, if a certain key switch is in the ON state, LOW is output to the output terminal of the key switch
In the F state, the open state appears. In the non-selected period, the open state appears regardless of the ON / OFF state of the key switch. Output terminals IN0 to INn
One switch output terminal of each different switch group is connected to each of the switch groups, and the switch states of each switch group are output in a time division manner. FIG. 4 shows an embodiment of a key switch control input section. Key
The output terminals IN0 to INn from the switch unit 13 are key
It is connected to the switch information input terminal 15 so that the key / switch information can be taken into the data holding circuit section 10. The number of holding circuits in this embodiment is 8 which is the total number of keys and switches.
It is suppressed to one-tenth. For comparison, the conventional key is shown in FIG.
A block diagram of the switch control device, and FIG. 9 shows a conventional control input unit. In the conventional example, the same number of holding circuits as the number of all the key switches are prepared, all the data obtained when the key switches are scanned are held, and the CPU is required only by checking all the holding circuits. I was getting information. In FIG. 4, when the data is fetched, the output states of the output terminals IN0 to INn from the key switch unit 13 are open and LOW level. Therefore, the input pull-up circuit 9 is provided, and 16 is a pull-up resistor for converting the open state to the HIGH state. The latch clock 17 (LC) is input so that the data can be fetched within each of the eight selection periods. The key switch information is transferred to the output section through the data latch output terminal 12.

【0008】図5は出力部の回路構成の一例である。
カウンター・データ保持回路20は計数部2のデータを
保持するが、その取り込みクロックはラッチ・クロック
17(LC)であるためキ−・スイッチ情報のキー・ス
イッチ制御用入力部7への取り込みタイミングと同時で
あるため、出力部3の出力端子19に現れる情報をCP
Uが得ることにより、CPUは入手したデータがどのキ
ー・スイッチの情報なのかが判断できる。 問題は、出
力端子19に現れる情報はキー・スイッチの状態が変化
した時、追従して変化する。 この時にCPUが情報の
取得処理を行った場合,誤認識をする可能性があるた
め、AND回路21はラッチ・クロック17(LC)の
立ち上がりタイミングからHIGHレベルの期間、出力
端子19を全てHIGHレベルにすることによりCPU
に対し、変化期間であることを知らせるために用意され
ている。
FIG. 5 shows an example of the circuit configuration of the output section.
The counter / data holding circuit 20 holds the data of the counting section 2, but since the fetch clock is the latch clock 17 (LC), the timing of fetching the key switch information to the key switch control input section 7 and Since it is simultaneous, the information appearing at the output terminal 19 of the output unit 3 is CP
By obtaining U, the CPU can determine which key switch information is the obtained data. The problem is that the information appearing at the output terminal 19 changes as the state of the key switch changes. If the CPU performs information acquisition processing at this time, there is a possibility of erroneous recognition. Therefore, the AND circuit 21 sets all the output terminals 19 to the HIGH level during the HIGH level from the rising timing of the latch clock 17 (LC). CPU by
It is prepared to inform the change period.

【0009】図7にOUT0〜OUT7、A1〜A3、
IN0〜INn、LCのタイミング図を示す。
In FIG. 7, OUT0 to OUT7, A1 to A3,
The timing chart of IN0 to INn and LC is shown.

【0010】[0010]

【発明の効果】以上説明したように本発明のキー・スイ
ッチ制御装置は、出力部よりキー・スイッチの状態デー
タと、その状態データがどのキー・スイッチのものなの
かを示す周期情報を出力する機能を有するるため、キー
・スイッチ制御装置内部に全キー・スイッチ数と同数の
データ保持回路を用意しなくともCPUが求める情報を
提供する事ができる。
As described above, the key switch control device of the present invention outputs the state data of the key switch and the cycle information indicating which key switch the state data belongs to from the output section. Since it has a function, it is possible to provide information required by the CPU without preparing the same number of data holding circuits as the total number of key switches in the key switch controller.

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

【図1】本発明のキー・スイッチ制御装置の構成図。FIG. 1 is a block diagram of a key switch control device of the present invention.

【図2】本発明の計数部及び情報変換部の一実施例の回
路図。
FIG. 2 is a circuit diagram of an embodiment of a counting unit and an information converting unit according to the present invention.

【図3】本発明のキー・スイッチ部の一実施例の回路
図。
FIG. 3 is a circuit diagram of an embodiment of a key switch unit of the present invention.

【図4】本発明のキー・スイッチ制御用入力装置の一実
施例の回路図。
FIG. 4 is a circuit diagram of an embodiment of an input device for controlling a key switch of the present invention.

【図5】本発明のキー・スイッチ制御用入力装置の出力
部の一実施例の回路図。
FIG. 5 is a circuit diagram of an embodiment of an output section of the key switch control input device of the present invention.

【図6】本発明の計数部及び情報変換部のタイミング
図。
FIG. 6 is a timing diagram of a counting unit and an information converting unit according to the present invention.

【図7】本発明の情報変換部及びキー・スイッチ制御用
入力装置のタイミング図。
FIG. 7 is a timing chart of the information conversion unit and the key switch control input device of the present invention.

【図8】従来のキー・スイッチ制御装置のブロック図。FIG. 8 is a block diagram of a conventional key switch control device.

【図9】従来のキー・スイッチ制御用入力装置の一実施
例の回路図。
FIG. 9 is a circuit diagram of an embodiment of a conventional key switch control input device.

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

1 クロック信号 2 計数部 3 計数情報伝達信号 4 情報変換部 5 キー・スイッチ制御用出力駆動装置 6 キー・スイッチ制御用出力信号 7 キー・スイッチ制御用入力装置 9 キー・スイッチ制御用入力装置内のプルアップ回路 10 キー・スイッチ制御用入力装置内のデータ保持回
路 12 データ・ラッチ出力端子 13 キー・スイッチ部 17 キー・スイッチ情報取り込み信号 18 出力部 19 出力部の出力端子 20 カウンター・データ保持回路 21 AND回路
1 clock signal 2 counting unit 3 counting information transmission signal 4 information conversion unit 5 key switch control output drive device 6 key switch control output signal 7 key switch control input device 9 key switch control input device Pull-up circuit 10 Data holding circuit in input device for key switch control 12 Data latch output terminal 13 Key switch section 17 Key switch information capture signal 18 Output section 19 Output terminal of output section 20 Counter data holding circuit 21 AND circuit

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】クロック信号を入力し該クロック信号を計
測する計数部、該計数部の計数情報を入力し計測情報を
変換する情報変換部、該情報変換部からの変換された情
報を出力する出力駆動部,該出力駆動部の出力端子に接
続した複数のキー・スイッチより構成されるキー・スイ
ッチ部,該キー・スイッチ部からの情報を保持する入力
制御部,該入力制御部の情報を出力する出力部より構成
されるキー・スイッチ制御装置において,該計数部の情
報と該情報に対応する該キー・スイッチ部からの情報を
ともに出力処理する出力部を有する事を特徴とするキー
・スイッチ制御装置。
1. A counting unit for inputting a clock signal and measuring the clock signal, an information converting unit for inputting count information of the counting unit and converting measurement information, and outputting converted information from the information converting unit. An output drive unit, a key switch unit composed of a plurality of key switches connected to the output terminals of the output drive unit, an input control unit that holds information from the key switch unit, and information of the input control unit. A key switch control device comprising an output unit for outputting, a key switch characterized by having an output unit for outputting both the information of the counting unit and the information from the key switch unit corresponding to the information. Switch control device.
JP3196737A 1991-08-06 1991-08-06 Key switch controller Pending JPH0540563A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP3196737A JPH0540563A (en) 1991-08-06 1991-08-06 Key switch controller

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP3196737A JPH0540563A (en) 1991-08-06 1991-08-06 Key switch controller

Publications (1)

Publication Number Publication Date
JPH0540563A true JPH0540563A (en) 1993-02-19

Family

ID=16362764

Family Applications (1)

Application Number Title Priority Date Filing Date
JP3196737A Pending JPH0540563A (en) 1991-08-06 1991-08-06 Key switch controller

Country Status (1)

Country Link
JP (1) JPH0540563A (en)

Similar Documents

Publication Publication Date Title
JPH0540563A (en) Key switch controller
JP3498106B2 (en) Analog-to-digital converter
JPH0431918A (en) Key scanning device
JPH0540564A (en) Key switch controller
KR0134365B1 (en) Single chip microprocessor with program data memory flag
JPH0540556A (en) Key switch controller
JPH0546535A (en) Data transfer interface device
KR200155054Y1 (en) Counter circuit
JP3887025B2 (en) Clock multiplexer
US4297532A (en) Interfacing circuit status detection arrangement in a telephone exchange
KR0164790B1 (en) Apparatus for converting color format
JP2548023Y2 (en) Key input device
JP2564318B2 (en) Communication processing device
KR880000422B1 (en) Matrix key and data selector
JPH074665Y2 (en) Key matrix reading circuit
KR0168832B1 (en) Semiconductor memory device
KR900000112B1 (en) Reading method and circuit of keyboard's key inputing
KR960016271B1 (en) Exchange riset -out circuit
KR920007488B1 (en) Universial signal transceiving circuit
JPH11288330A (en) Integrated circuit with setting function
JP3645831B2 (en) State machine circuit
JP2575920Y2 (en) Switching information issuing circuit
KR970001293Y1 (en) Private switching
JPH035788A (en) Display device driving lsi
JP2000252822A (en) Interrupt circuit