JP3158665B2 - Printer and control method thereof - Google Patents

Printer and control method thereof

Info

Publication number
JP3158665B2
JP3158665B2 JP16932592A JP16932592A JP3158665B2 JP 3158665 B2 JP3158665 B2 JP 3158665B2 JP 16932592 A JP16932592 A JP 16932592A JP 16932592 A JP16932592 A JP 16932592A JP 3158665 B2 JP3158665 B2 JP 3158665B2
Authority
JP
Japan
Prior art keywords
pulse
edge
detected
timing
predetermined number
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP16932592A
Other languages
Japanese (ja)
Other versions
JPH068591A (en
Inventor
眞 花村
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
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 JP16932592A priority Critical patent/JP3158665B2/en
Publication of JPH068591A publication Critical patent/JPH068591A/en
Application granted granted Critical
Publication of JP3158665B2 publication Critical patent/JP3158665B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Accessory Devices And Overall Control Thereof (AREA)

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【産業上の利用分野】本発明は、電卓等に用いられる機
械式接点を有するプリンタおよびその制御方法に関す
る。
The present invention relates to a method of controlling the printer and its having a mechanical contact used in calculators and the like.

【0002】[0002]

【従来の技術】従来この種の技術は、モータ電源を投入
した直後に立ち上がったタイミングパルスが所定の回数
発生した後に、タイミングパルスとリセットパルスを使
って初期設定を行ない、印字・紙送りに入る制御方法と
なっていた。
2. Description of the Related Art Conventionally, in this type of technology, after a timing pulse which rises immediately after turning on a motor power is generated a predetermined number of times, initialization is performed using a timing pulse and a reset pulse, and printing / paper feeding is started. It was a control method.

【0003】図4は従来技術の一般的なプリンタの動作
方法を示したタイミングチャートでである。尚、本発明
で説明するプリンタは特公平3−20352に記載され
ている為、制御方法についてのみ簡単に説明する。
FIG. 4 is a timing chart showing an operation method of a conventional general printer. Since the printer described in the present invention is described in JP-B-3-20352, only the control method will be briefly described.

【0004】まずモータ駆動信号51を投入してモータ
を起動させ、タイミングパルス52が所定の回数N発生
した後にリセットパルス53の立ち上がりの検索を開始
し、リセットパルス53が立ち上がった直後のタイミン
グパルス52をTP0とカウントし、所望の活字と対応
したタイミングパルス52の位置で文字選択信号54を
投入して印字していく。一桁目の文字選択信号54の立
ち上がりから立ち下がりまでの間隔は文字選択信号54
の立ち上がりでタイマー出力信号55をスタートさせて
計測している。以後必要な桁数だけ文字選択を繰り返し
た後、再上位桁で一桁目で計測した文字選択信号54の
立ち上がっている間隔の数倍を文字選択信号54投入後
に付加することでキャリッジ復帰通電Cを行っている。
キャリッジ復帰通電Cによりキャリッジ復帰動作56が
終了し、続いて紙送り動作57が終了する。以後必要な
行数だけ印字・紙送りを繰り返した後、モータ駆動信号
51を遮断してモータを停止する。
First, a motor drive signal 51 is supplied to start the motor. After a predetermined number N of timing pulses 52 have been generated, a search for the rise of the reset pulse 53 is started, and the timing pulse 52 immediately after the rise of the reset pulse 53 is started. Is counted as TP0, and a character selection signal 54 is input at the position of the timing pulse 52 corresponding to the desired type and printing is performed. The interval between the rise and fall of the first digit character selection signal 54 is determined by the character selection signal 54.
The timer output signal 55 is started at the rising edge of the measurement, and the measurement is performed. Thereafter, the character selection is repeated by the required number of digits, and then several times the rising interval of the character selection signal 54 measured at the first digit in the uppermost digit is added after the input of the character selection signal 54. It is carried out.
The carriage return operation 56 ends with the carriage return energization C, and then the paper feed operation 57 ends. Thereafter, after printing and paper feeding are repeated for the required number of lines, the motor drive signal 51 is cut off to stop the motor.

【0005】以下図5のフローチャート及び図6のタイ
ムチャートに従って、従来のプリンタ制御方法を説明す
る。まずステップF61でモータ駆動信号70を投入し
てモータを起動する。ステップF62でタイミングパル
ス71が立ち上がったかを判断する。ここでタイミング
パルス71が立ち上がっていない場合には、ステップF
62の制御を繰り返し行う。タイミングパルス71が立
ち上がったら、ステップF63でタイミングパルス71
が所定の回数N以上発生したか確認する。ここで所定の
回数N以上であれば、ステップF64のリセットパルス
72の立ち上がり検出の制御へ進む。タイミングパルス
71の発生回数が所定の発生回数N未満であれば、タイ
ミングパルス71の発生回数が所定の発生回数N以上に
なるまで、ステップF62・ステップF63の制御を繰
り返す。ステップF64でリセットパルス72の立ち上
がりを検出したら、ステップF65でタイミングパルス
71の立ち上がりを検出する。ステップF65で立ち上
がったタイミングパルス71をTP0としてステップF
66でタイミングパルス71のカウントをTP0に設定
する。
A conventional printer control method will be described below with reference to a flowchart of FIG. 5 and a time chart of FIG. First, in step F61, the motor drive signal 70 is input to start the motor. In step F62, it is determined whether the timing pulse 71 has risen. If the timing pulse 71 has not risen here, step F
The control of 62 is repeated. When the timing pulse 71 rises, in step F63, the timing pulse 71
It is checked whether or not N has occurred a predetermined number of times or more. If the number is equal to or greater than the predetermined number N, the process proceeds to the control of detecting the rising edge of the reset pulse 72 in step F64. If the number of occurrences of the timing pulse 71 is less than the predetermined number of occurrences N, the control of steps F62 and F63 is repeated until the number of occurrences of the timing pulse 71 becomes equal to or more than the predetermined number of occurrences N. If the rise of the reset pulse 72 is detected in step F64, the rise of the timing pulse 71 is detected in step F65. The timing pulse 71 rising in step F65 is set to TP0 and
At 66, the count of the timing pulse 71 is set to TP0.

【0006】このプリンタ制御方法によると、タイミン
グパルス71の発生回数が所定の発生回数N以上になっ
た直後に検出されたリセットパルス72の立ち上がり
を、リセットパルス72の最初の立ち上がりとして判断
するが、機械式接点を有するプリンタでは、接点の摺動
部の振動及び摩耗による接触不良から、図示するような
チャタリング73がリセットパルス72の波形に発生す
る。本来のリセットパルス72の立ち上がり部分では、
タイミングパルス71の発生回数が所定の発生回数N未
満のため、リセットパルス72の最初の立ち上がりが検
出できず、タイミングパルス71の発生回数が所定の発
生回数N以後の、リセットパルス72にチャタリング7
3が発生した所をリセットパルス72の立ち上がり部分
と判断し、タイミングパルス71の次の立ち上がりをT
P0としてミスカウントしてしまうため、所定の位置よ
りも1つ印字位置が遅れて誤印字となる。
According to this printer control method, the rising edge of the reset pulse 72 detected immediately after the number of occurrences of the timing pulse 71 becomes equal to or more than the predetermined number of occurrences N is determined as the first rising edge of the reset pulse 72. In a printer having mechanical contacts, chattering 73 as shown in the drawing is generated in the waveform of the reset pulse 72 due to contact failure due to vibration and wear of the sliding portion of the contact. At the rising edge of the original reset pulse 72,
Since the number of occurrences of the timing pulse 71 is less than the predetermined number N, the first rise of the reset pulse 72 cannot be detected, and the number of occurrences of the timing pulse 71 is less than the predetermined number N.
3 is determined as the rising portion of the reset pulse 72, and the next rising of the timing pulse 71 is determined as T
Since miscounting is performed as P0, one printing position is delayed from a predetermined position, resulting in erroneous printing.

【0007】以上述べたように、タイミングパルス71
の発生回数が所定の発生回数N以上になった直後に検出
されたリセットパルス72の立ち上がりを、リセットパ
ルス72の最初の立ち上がりとして判断し、タイミング
パルス71の次の立ち上がりをTP0とカウントして初
期設定を行なっていた。
As described above, the timing pulse 71
The rising edge of the reset pulse 72 detected immediately after the number of occurrences of the reset pulse 72 becomes equal to or more than the predetermined number of occurrences N is determined as the first rising edge of the reset pulse 72, and the next rising edge of the timing pulse 71 is counted as TP0 and initialized. Setting was done.

【0008】[0008]

【発明が解決しようとする課題】しかし、前述の従来技
術では、次のような欠点があった。 (1)接点の摺動部の振動及び摩耗による接触不良から
リセットパルスの波形にチャタリングが発生するとカウ
ントミスが起き、プリンタ誤動作が発生していた 。(2)前述の誤動作を防止するため、コンデンサや抵
抗で積分回路を付加したり、接点を金メッキにする等の
高価な対策部品を使用するなどして、コストアップとな
る対策を施す必要があった。
However, the above-mentioned prior art has the following disadvantages. (1) If chattering occurs in the waveform of the reset pulse due to contact failure due to vibration and wear of the sliding portion of the contact, a counting error occurs and a printer malfunction occurs. (2) In order to prevent the above-described malfunction, it is necessary to take measures to increase the cost by adding an integrating circuit with a capacitor or a resistor, or using expensive countermeasures such as gold-plated contacts. Was.

【0009】本発明はこのような欠点を解決するために
なされたものであり、高価なチャタリング対策部品を使
用せずに、チャタリングの発生に左右される事なく、リ
セットパルスの最初の立ち上がり検出が可能な、信頼製
の高いプリンタを提供することを目的とする。
The present invention has been made to solve such a drawback, and the first rising edge of the reset pulse can be detected without using an expensive chattering countermeasure component and without being affected by chattering. The aim is to provide a reliable, highly reliable printer.

【0010】[0010]

【課題を解決するための手段】本発明のプリンタは、モ
ータの駆動によって活字輪を回転させる手段と、前記活
字輪の回転に対応して第1パルスを発生させる手段と、
前記活字輪の1回転に1度、第2パルスを発生させる手
段と、を備え、前記第2パルスのエッジを前記第1パル
スによって検出することにより、前記活字輪の初期設定
を行うプリンタにおいて、前記第1パルスを計数する計
数手段と、前記計数手段による前記第1パルスの計数
が、所定の発生回数以上であるかどうか判断する判断手
段と、を備え、前記判断手段が前記第1パルスの計数が
前記所定の発生回数以上であると判断したとき、既に前
記第2パルスのエッジを前記第1パルスによって検出済
みかどうか判断し、前記第2パルスのエッジを検出済み
のとき当該第2パルスによる初期設定値を無効とし、次
に到来する第2パルスのエッジを検出する第1パルスに
よって初期設定値を得、前記判断手段が前記第1パルス
の計数が前記所定の発生回数以上であると判断したと
き、既に前記第2パルスのエッジを前記第1パルスによ
って検出済みかどうか判断し、前記第2パルスのエッジ
を検出済みでないとき、次に到来する第2パルスのエッ
ジを検出する第1パルスによって初期設定値を得ること
を特徴とする。また、本発明のプリンタの制御方法は、
モータの駆動によって活字輪を回転させる手段と、前記
活字輪の回転に対応して第1パルスを発生させる手段
と、前記活字輪の1回転に1度、第2パルスを発生させ
る手段と、を備え、前記第2パルスのエッジを前記第1
パルスによって検出することにより、前記活字輪の初期
設定を行うプリンタの制御方法において、前記第1パル
スを計数し、所定の発生回数以上であるかどうか判断す
る第1の判断工程と、前記第1の判断工程によって、前
記第1パルスの計数が前記所定の発生回数以上であると
判断されたとき、既に前記第2パルスのエッジを前記第
1パルスによって検出済みかどうか判断する第2の判断
工程と、を備え、前記第2の判断工程によって、第2パ
ルスのエッジを検出済みと判断したとき、当該第2パル
スによる初期設定値を無効とし、次に到来する第2パル
スのエッジを検出する第1パルスによって初期設定値を
得、前記第2の判断工程によって、前記第2パルスのエ
ッジを検出済みでないと判断したとき、次に到来する第
2パルスのエッジを検出する第1パルスによって初期設
定値を得ることを特徴とする。
According to the present invention, there is provided a printer comprising: means for rotating a character wheel by driving a motor; means for generating a first pulse in response to rotation of the character wheel;
Means for generating a second pulse once per rotation of the character wheel, wherein the printer performs initial setting of the character wheel by detecting an edge of the second pulse by the first pulse. Counting means for counting the first pulse; and judging means for judging whether or not the counting of the first pulse by the counting means is equal to or more than a predetermined number of occurrences. When it is determined that the count is equal to or greater than the predetermined number of occurrences, it is determined whether the edge of the second pulse has already been detected by the first pulse. When the edge of the second pulse has been detected, the second pulse has been detected. Is invalidated, and an initial setting value is obtained by a first pulse that detects an edge of a second pulse that arrives next, and the determination unit determines that the count of the first pulse is equal to the predetermined value. When it is determined that the number of times of birth is equal to or more than the number of times of birth, it is determined whether or not the edge of the second pulse has already been detected by the first pulse. An initial set value is obtained by a first pulse for detecting an edge. Further, the control method of the printer of the present invention includes:
Means for rotating a character wheel by driving a motor, means for generating a first pulse corresponding to the rotation of the character wheel, and means for generating a second pulse once for each rotation of the character wheel. The edge of the second pulse is connected to the first pulse.
A first determining step of counting the first pulse and determining whether the number of occurrences is equal to or greater than a predetermined number of times, in the printer control method of performing initial setting of the character ring by detecting with a pulse; A second determining step of determining whether or not the edge of the second pulse has already been detected by the first pulse when it is determined in the determining step that the count of the first pulse is equal to or greater than the predetermined number of occurrences. When the second determination step determines that the edge of the second pulse has been detected, the initial value of the second pulse is invalidated, and the edge of the second pulse that arrives next is detected. When the initial setting value is obtained by the first pulse, and it is determined in the second determination step that the edge of the second pulse has not been detected, the edge of the next incoming second pulse Characterized in that to obtain the initial set value by the first pulse to be detected.

【0011】[0011]

【作用】本発明の上記の構成によれば、初期設定を行な
うためにモータ電源を投入した後に立ち上がったリセッ
トパルスに、機械式接点の振動及び摩耗によるチャタリ
ングが発生しても、リセットパルスの最初の立ち上がり
を確実に検出する事が可能となり、タイミングパルスT
P0のカウントには全く支障がなく、プリンタの誤動作
を防止できる。又、高価なチャタリング対策部品を使用
することもない。
According to the above configuration of the present invention, even if chattering due to vibration and wear of the mechanical contacts occurs in the reset pulse that rises after the motor power is turned on to perform the initial setting, Can be reliably detected, and the timing pulse T
There is no hindrance to the count of P0, and malfunction of the printer can be prevented. Also, no expensive chattering countermeasure parts are used.

【0012】[0012]

【実施例】以下に本発明の一実施例を図1から図3にも
とづいて説明する。図1は、初期設定を行うための制御
方法を示すフローチャート。図2はそのタイミングチャ
ート、図3はそのブロック図である。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS One embodiment of the present invention will be described below with reference to FIGS. FIG. 1 is a flowchart illustrating a control method for performing initialization. FIG. 2 is a timing chart thereof, and FIG. 3 is a block diagram thereof.

【0013】図1のフローチャートに示すように、モー
タの起動時には、まずステップF1でモータを起動させ
るモータ駆動信号20を投入し、ステップF2でタイミ
ングパルス21の立ち上がりを確認する。ここでタイミ
ングパルス21が立ち上がるまでステップF2の制御を
繰り返し行う。タイミングパルス21が立ち上がった
ら、ステップF3でタイミングパルス21が所定の回数
N以上発生したか確認する。ここで所定の回数N以上で
あれば、ステップF4のリセットパルスフラグ23の判
断を行なう。タイミングパルス21の発生回数が所定の
発生回数N未満であれば、ステップF5のリセットパル
スフラグ23の判断を行なう。
As shown in the flowchart of FIG. 1, when starting the motor, first, a motor drive signal 20 for starting the motor is input in step F1, and the rising of the timing pulse 21 is confirmed in step F2. Here, the control of step F2 is repeated until the timing pulse 21 rises. When the timing pulse 21 rises, it is checked in step F3 whether the timing pulse 21 has occurred a predetermined number N or more. If the number is equal to or greater than the predetermined number N, the reset pulse flag 23 is determined in step F4. If the number of times of generation of the timing pulse 21 is less than the predetermined number of times N, the determination of the reset pulse flag 23 in step F5 is performed.

【0014】リセットパルスフラグ23は、直前のタイ
ミングパルス21の立ち上がりから立ち上がりまでの間
で、リセットパルス22の立ち上がりが検出できると割
込み処理によりリセットパルスフラグ23が”1”とな
り、検出できなければ”0”となる。ステップF5でリ
セットパルスフラグ23が”1”と判断した時は、ステ
ップF6に進みリセットパルスフラグ23を”0”にし
た後に、ステップF2へ戻ってタイミングパルス21の
立ち上がりを確認する。ステップF5でリセットパルス
フラグ23が”0”と判断した時は、ステップF2へ戻
ってタイミングパルス21の立ち上がりを確認する。
The reset pulse flag 23 is set to "1" by interruption processing when the rise of the reset pulse 22 can be detected during the period from the rise of the previous timing pulse 21 to the rise. 0 ". If it is determined in step F5 that the reset pulse flag 23 is "1", the process proceeds to step F6, where the reset pulse flag 23 is set to "0". Then, the process returns to step F2 to check the rise of the timing pulse 21. When it is determined in step F5 that the reset pulse flag 23 is "0", the process returns to step F2 to check the rise of the timing pulse 21.

【0015】ステップF4でリセットパルスフラグ23
が”1”と判断した時は、ステップF4以前にリセット
パルス22が発生したことになり、タイミングパルス2
1のTP0をカウントするための、リセットパルス22
の最初の立ち上がりが検出できないため、ステップF6
に進みリセットパルスフラグ23を”0”にした後に、
ステップF2へ戻ってタイミングパルス21の立ち上が
りを確認する。ステップF4でリセットパルスフラグ2
3が”0”と判断した時は、直前のタイミングパルス2
1の立ち上がりから立ち上がりまでの間で、リセットパ
ルス22が発生していない事が確認できたので、ステッ
プF7に進みリセットパルス22の立ち上がりを検出す
る。このステップF7からは割込み処理によりリセット
パルス22の立ち上がりが検出できた所で、次のステッ
プF8に進む。ステップF8でタイミングパルス21の
立ち上がりを検出し、検出できたらステップF9で立ち
上がったタイミングパルス21をタイミングパルスカウ
ントTP0に設定する。このプリンタ制御方法により、
初期設定を行った場合のタイミングチャートが図2であ
る。
In step F4, the reset pulse flag 23
Is "1", it means that the reset pulse 22 has been generated before step F4, and the timing pulse 2
Reset pulse 22 for counting TP0 of 1
Since the first rising edge cannot be detected, step F6
To set the reset pulse flag 23 to “0”,
Returning to step F2, the rising of the timing pulse 21 is confirmed. Reset pulse flag 2 in step F4
3 is "0", the timing pulse 2 immediately before
Since it was confirmed that the reset pulse 22 was not generated between the rise of 1 and the rise, the process proceeds to step F7 to detect the rise of the reset pulse 22. From this step F7, when the rise of the reset pulse 22 has been detected by the interrupt processing, the process proceeds to the next step F8. The rising of the timing pulse 21 is detected in step F8, and if detected, the rising timing pulse 21 is set in the timing pulse count TP0 in step F9. With this printer control method,
FIG. 2 is a timing chart when the initial setting is performed.

【0016】図2のタイミングチャートに示すように、
モータを起動するモータ駆動信号20を投入し、タイミ
ングパルス21の立ち上がりを確認する。タイミングパ
ルス21が立ち上がったら、タイミングパルス21が所
定の発生回数N以上か確認する。ここで所定の発生回数
N未満のため、再度次のタイミングパルス21の立ち上
がりを待つ。タイミングパルス21の検出を所定の発生
回数N以上になるまで続け、この間はタイミングパルス
21のカウントはTP0のままである。所定の発生回数
N未満の間もリセットパルス22の立ち上がり検出は続
ける。タイミングパルス21の検出が所定の発生回数N
以上になったならば、リセットパルス22の立ち上がり
検出を続け、リセットパルス22が立ち上がった以降最
初に立ち上がったタイミングパルス21をTP0として
カウントし、初期設定を終了する。
As shown in the timing chart of FIG.
The motor drive signal 20 for starting the motor is supplied, and the rise of the timing pulse 21 is confirmed. When the timing pulse 21 rises, it is confirmed whether the timing pulse 21 is equal to or more than a predetermined number N of occurrences. Here, since the number of occurrences is less than the predetermined number N, the rising of the next timing pulse 21 is waited again. The detection of the timing pulse 21 is continued until the number of occurrences reaches a predetermined number N or more, during which time the count of the timing pulse 21 remains TP0. The detection of the rising edge of the reset pulse 22 continues even during the period less than the predetermined number of occurrences N. The timing pulse 21 is detected a predetermined number of times N
If this is the case, the detection of the rise of the reset pulse 22 is continued, and the timing pulse 21 that first rises after the rise of the reset pulse 22 is counted as TP0, and the initial setting ends.

【0017】こうして確認したタイミングパルス21を
使用して印字・紙送りを行なう。図2ではタイミングパ
ルス21の発生回数N−1の時に、リセットパルス22
が立ち上がったため、タイミングパルス21の発生回数
Nの時に発生しているリセットパルス22のチャタリン
グ24で、リセットパルスフラグ23が”1”に設定さ
れるが、リセットパルスフラグ23が”0”でなけれ
ば、タイミングパルス21のTPO直前に発生するリセ
ットパルス22の立ち上がり検出へ進めないために、再
度リセットパルスフラグ23を”0”に設定してタイミ
ングパルス21とリセットパルス22の立ち上がり検出
へ戻る。
Printing and paper feeding are performed using the timing pulse 21 confirmed as described above. In FIG. 2, when the number of generations of the timing pulse 21 is N-1, the reset pulse 22
Rises, the reset pulse flag 23 is set to “1” by the chattering 24 of the reset pulse 22 generated when the number N of times of the timing pulse 21 is generated, but the reset pulse flag 23 is not “0”. In order not to proceed to the detection of the rising edge of the reset pulse 22 generated immediately before the TPO of the timing pulse 21, the reset pulse flag 23 is set to "0" again, and the process returns to the detection of the rising edges of the timing pulse 21 and the reset pulse 22.

【0018】次のタイミングパルス21の発生回数N+
1の時にも直前に立ち上がったリセットパルス22のチ
ャタリング24でリセットパルスフラグ23が”1”と
なっているため、再々度リセットパルスフラグ23を”
0”に設定してタイミングパルス21とリセットパルス
22の立ち上がり検出へ戻る。次のタイミングパルス2
1の発生回数N+2の時には直前にリセットパルス22
が発生していないので、リセットパルスフラグ23が”
0”となっており、タイミングパルス21のTPO直前
に発生する、リセットパルス22の立ち上がり検出へ進
み、タイミングパルス21の発生回数N+Xの時に直前
にリセットパルス22が発生して、次のタイミングパル
ス21をTP0とカウントして初期設定が終了する状態
を図示している。
The number of occurrences N + of the next timing pulse 21
Also at the time of 1, the reset pulse flag 23 is "1" due to the chattering 24 of the reset pulse 22 which has risen immediately before, so that the reset pulse flag 23 is reset to "1" again.
The timing pulse 21 and the reset pulse 22 are set to “0” and the process returns to the detection of the rise of the timing pulse 21 and the reset pulse 22. The next timing pulse 2
When the number of occurrences of 1 is N + 2, the reset pulse 22
Does not occur, the reset pulse flag 23 is set to "
0 ", and the process proceeds to the detection of the rising edge of the reset pulse 22, which occurs immediately before the TPO of the timing pulse 21, and the reset pulse 22 is generated immediately before the number of times N + X of the timing pulse 21 is generated. Is counted as TP0, and the state where the initialization is completed is illustrated.

【0019】この様に、タイミングパルス21の発生回
数N−1の時に、リセットパルス22が立ち上がったた
め、タイミングパルス21の発生回数Nの時に発生して
いるリセットパルス22のチャタリング24で、リセッ
トパルス21の最初の立ち上がりと誤判断して本来のタ
イミングパルス21のカウントTP0+1をTP0にす
ることを未然に防止できる。
As described above, since the reset pulse 22 rises at the number N-1 of times of generation of the timing pulse 21, the chattering 24 of the reset pulse 22 generated at the number N of times of generation of the timing pulse 21 causes the reset pulse 21 to rise. TP0 + 1 of the original timing pulse 21 by mistakenly determining that it is the first rising edge of TP0 can be prevented from occurring.

【0020】次に図3のブロック図により本発明の制御
方法の一例を説明する。制御部は時間を計測するタイマ
ー40、演算処理中のデータを一時的に保存するRAM
41、プログラムを格納するROM42、プログラム全
体を統括制御するCPU43、紙送り・印字等の為の電
磁石駆動回路44、モータを駆動する為のモータ駆動回
路45、タイミングパルス等を検出する検出回路46、
リセットパルスを検出する検出回路47とからなる。右
側の破線部で囲まれた部分48は、プリンタ本体側を示
す。
Next, an example of the control method of the present invention will be described with reference to the block diagram of FIG. The control unit includes a timer 40 for measuring time and a RAM for temporarily storing data being processed.
41, a ROM 42 for storing a program, a CPU 43 for controlling the whole program, an electromagnet drive circuit 44 for paper feeding and printing, a motor drive circuit 45 for driving a motor, a detection circuit 46 for detecting timing pulses,
And a detection circuit 47 for detecting a reset pulse. A portion 48 surrounded by a broken line on the right side indicates the printer main body side.

【0021】[0021]

【発明の効果】以上述べたように本発明よれば、初期設
定を行なうためにモータ電源を投入した後に立ち上がっ
たリセットパルスに、機械式接点の振動及び摩耗による
チャタリングが発生しても、リセットパルスの最初の立
ち上がりを確実に検出する事が可能となり、タイミング
パルスのカウントには全く支障がなく、プリンタの誤動
作を防止できる。又、高価なチャタリング対策部品を使
用することもなくプリンタの誤動作を防止することが可
能な、品質の高いプリンタを提供することができた。
As described above, according to the present invention, even if chattering due to vibration and wear of the mechanical contact occurs in the reset pulse that rises after the motor power is turned on for initial setting, the reset pulse Can be reliably detected, the counting of timing pulses is not affected at all, and malfunction of the printer can be prevented. In addition, a high-quality printer capable of preventing malfunction of the printer without using expensive chattering countermeasure parts can be provided.

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

【図1】 本発明の一実施例を示すフローチャート。FIG. 1 is a flowchart showing an embodiment of the present invention.

【図2】 本発明の一実施例を示すタイミングチャー
ト。
FIG. 2 is a timing chart showing one embodiment of the present invention.

【図3】 本発明の制御方法の一例を示すブロック図。FIG. 3 is a block diagram showing an example of a control method according to the present invention.

【図4】 従来技術の例を示すタイミングチャート。FIG. 4 is a timing chart showing an example of the related art.

【図5】 従来技術の例を示すフローチャート。FIG. 5 is a flowchart showing an example of the related art.

【図6】 従来技術の例を示すタイミングチャート。FIG. 6 is a timing chart showing an example of the related art.

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

F1 モータ駆動信号投入の処理 F2 タイミングパルスの立ち上がりを判断する処理 F3 所定の回数タイミングパルスが発生したか判断す
る処理 F4 リセットパルスが立ち上がったか判断する処理 F5 リセットパルスが立ち上がったか判断する処理 F6 リセットパルスフラグを”0”とする処理 F7 リセットパルスが立ち上がったか判断する処理 F8 タイミングパルスの立ち上がりを判断する処理 F9 タイミングパルスのカウントをTP0とする処理
F1 Motor drive signal input processing F2 Processing to determine the rise of timing pulse F3 Processing to determine whether a predetermined number of timing pulses have been generated F4 Processing to determine whether a reset pulse has risen F5 Processing to determine whether a reset pulse has risen F6 Reset pulse Processing to set the flag to "0" F7 Processing to determine whether the reset pulse has risen F8 Processing to determine the rise of the timing pulse F9 Processing to count the timing pulse to TP0

Claims (2)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】モータの駆動によって活字輪を回転させる
手段と、 前記活字輪の回転に対応して第1パルスを発生させる手
段と、 前記活字輪の1回転に1度、第2パルスを発生させる手
段と、を備え、 前記第2パルスのエッジを前記第1パルスによって検出
することにより、前記活字輪の初期設定を行うプリンタ
において、 前記第1パルスを計数する計数手段と、 前記計数手段による前記第1パルスの計数が、所定の発
生回数以上であるかどうか判断する判断手段と、を備
え、 前記判断手段が前記第1パルスの計数が前記所定の発生
回数以上であると判断したとき、既に前記第2パルスの
エッジを前記第1パルスによって検出済みかどうか判断
し、前記第2パルスのエッジを検出済みのとき当該第2
パルスによる初期設定値を無効とし、次に到来する第2
パルスのエッジを検出する第1パルスによって初期設定
値を得、 前記判断手段が前記第1パルスの計数が前記所定の発生
回数以上であると判断したとき、既に前記第2パルスの
エッジを前記第1パルスによって検出済みかどうか判断
し、前記第2パルスのエッジを検出済みでないとき、次
に到来する第2パルスのエッジを検出する第1パルスに
よって初期設定値を得ることを特徴とするプリンタ。
Means for rotating a character wheel by driving a motor; means for generating a first pulse in response to rotation of the character wheel; generating a second pulse once for each rotation of the character wheel. Means for performing initial setting of the character ring by detecting an edge of the second pulse by the first pulse, wherein: a counting means for counting the first pulse; and And determining means for determining whether or not the count of the first pulse is equal to or greater than a predetermined number of occurrences. When the determination means determines that the count of the first pulse is equal to or greater than the predetermined number of occurrences, It is determined whether or not the edge of the second pulse has already been detected by the first pulse. If the edge of the second pulse has been detected, the second pulse
Invalidate the initial setting value by the pulse, and
An initial setting value is obtained by a first pulse for detecting an edge of a pulse, and when the determination unit determines that the count of the first pulse is equal to or more than the predetermined number of times, the edge of the second pulse is already determined by the second pulse. A printer characterized in that it is determined whether or not detection has been performed by one pulse, and when an edge of the second pulse has not been detected, an initial setting value is obtained by a first pulse that detects an edge of a next incoming second pulse.
【請求項2】モータの駆動によって活字輪を回転させる
手段と、前記活字輪の回転に対応して第1パルスを発生
させる手段と、前記活字輪の1回転に1度、第2パルス
を発生させる手段と、を備え、前記第2パルスのエッジ
を前記第1パルスによって検出することにより、前記活
字輪の初期設定を行うプリンタの制御方法において、 前記第1パルスを計数し、所定の発生回数以上であるか
どうか判断する第1の判断工程と、 前記第1の判断工程によって、前記第1パルスの計数が
前記所定の発生回数以上であると判断されたとき、既に
前記第2パルスのエッジを前記第1パルスによって検出
済みかどうか判断する第2の判断工程と、 を備え、 前記第2の判断工程によって、第2パルスのエッジを検
出済みと判断したとき、当該第2パルスによる初期設定
値を無効とし、次に到来する第2パルスのエッジを検出
する第1パルスによって初期設定値を得、 前記第2の判断工程によって、前記第2パルスのエッジ
を検出済みでないと判断したとき、次に到来する第2パ
ルスのエッジを検出する第1パルスによって初期設定値
を得ることを特徴とするプリンタの制御方法。
2. A means for rotating a character wheel by driving a motor, means for generating a first pulse in response to rotation of the character wheel, and generating a second pulse once for each rotation of the character wheel. Means for performing initial setting of the character ring by detecting an edge of the second pulse by the first pulse, wherein the first pulse is counted and a predetermined number of occurrences is performed. A first judging step of judging whether or not the above is satisfied, and when it is judged by the first judging step that the count of the first pulse is equal to or more than the predetermined number of occurrences, the edge of the second pulse has already been detected. A second determining step of determining whether or not the edge of the second pulse has been detected by the second determining step. The initial setting value is invalidated, and the initial setting value is obtained by the first pulse for detecting the edge of the next incoming second pulse. The second determining step determines that the edge of the second pulse has not been detected. A first pulse for detecting an edge of a second pulse that arrives next to obtain an initial set value.
JP16932592A 1992-06-26 1992-06-26 Printer and control method thereof Expired - Fee Related JP3158665B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP16932592A JP3158665B2 (en) 1992-06-26 1992-06-26 Printer and control method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP16932592A JP3158665B2 (en) 1992-06-26 1992-06-26 Printer and control method thereof

Publications (2)

Publication Number Publication Date
JPH068591A JPH068591A (en) 1994-01-18
JP3158665B2 true JP3158665B2 (en) 2001-04-23

Family

ID=15884460

Family Applications (1)

Application Number Title Priority Date Filing Date
JP16932592A Expired - Fee Related JP3158665B2 (en) 1992-06-26 1992-06-26 Printer and control method thereof

Country Status (1)

Country Link
JP (1) JP3158665B2 (en)

Also Published As

Publication number Publication date
JPH068591A (en) 1994-01-18

Similar Documents

Publication Publication Date Title
US4405982A (en) Arrangement for monitoring the function of a programmable electronic switching circuit
EP0183771B1 (en) Reference pulse verification circuit adaptable for engine control
US3973256A (en) Key detection system interconnecting keyboard and data processing system
KR950000220B1 (en) Engine control system
GB2129587A (en) A method of and apparatus for fail-safe operation of a vehicle computer
US4312315A (en) System for digital control of operation of internal combustion engine
JP3158665B2 (en) Printer and control method thereof
US4821033A (en) Matrix switching apparatus for preventing pseudo input
WO1986007477A1 (en) Skew insensitive fault detect and signal routing device
EP0788227B1 (en) Timer apparatus
US6163164A (en) Noise detection circuit
JPH06227062A (en) Serial printer and control method of serial printer
JPH0371644B2 (en)
JPS6136665B2 (en)
KR0180386B1 (en) Noise detecting apparatus of cylinder signal
EP1424479A1 (en) Electronic device architecture for determining the angular position of an engine shaft in internal combustion engines
JPH0464099B2 (en)
KR940022059A (en) Encoder Output Error Compensation Method
JPS6354891B2 (en)
JPH01239417A (en) Pulse reading-in circuit for pulse encoder
JPS6155878B2 (en)
JPS6126989Y2 (en)
JPH0914040A (en) Abnormality detection method for engine rotation sensor
JP3022075B2 (en) Printer
JP2516711B2 (en) Watchdog timer device

Legal Events

Date Code Title Description
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080216

Year of fee payment: 7

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

Free format text: PAYMENT UNTIL: 20090216

Year of fee payment: 8

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

Free format text: PAYMENT UNTIL: 20090216

Year of fee payment: 8

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

Free format text: PAYMENT UNTIL: 20100216

Year of fee payment: 9

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

Free format text: PAYMENT UNTIL: 20110216

Year of fee payment: 10

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

Free format text: PAYMENT UNTIL: 20110216

Year of fee payment: 10

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

Free format text: PAYMENT UNTIL: 20120216

Year of fee payment: 11

LAPS Cancellation because of no payment of annual fees