JP3783455B2 - Stepping motor control device, control method, and printer - Google Patents

Stepping motor control device, control method, and printer Download PDF

Info

Publication number
JP3783455B2
JP3783455B2 JP7788699A JP7788699A JP3783455B2 JP 3783455 B2 JP3783455 B2 JP 3783455B2 JP 7788699 A JP7788699 A JP 7788699A JP 7788699 A JP7788699 A JP 7788699A JP 3783455 B2 JP3783455 B2 JP 3783455B2
Authority
JP
Japan
Prior art keywords
phase
excitation
counter
stepping motor
switching
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
JP7788699A
Other languages
Japanese (ja)
Other versions
JP2000272190A (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 JP7788699A priority Critical patent/JP3783455B2/en
Publication of JP2000272190A publication Critical patent/JP2000272190A/en
Application granted granted Critical
Publication of JP3783455B2 publication Critical patent/JP3783455B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Character Spaces And Line Spaces In Printers (AREA)
  • Control Of Stepping Motors (AREA)

Description

【0001】
【発明の属する技術分野】
本発明は、ステッピングモータの制御装置および方法に関するものである。
【0002】
【従来の技術】
キャリッジあるいは紙送り機構の駆動源としてステッピングモータが採用されているプリンタでは、その励磁方式を切替えてキャリッジあるいは紙送り速度が制御される。このため、ASIC等でハード的に複数の励磁方式、たとえば、1相、2−2相、1−2相あるいはW1−2相などの励磁方式によりステッピングモータを駆動する制御装置が知られている。もちろん、このような制御装置はプリンタに限らずステッピングモータの速度を制御する必要のある機器に多く用いられている。このような制御装置の1つには、相励磁信号を生成するためのカウンタを用いた方式のものがある。このカウンタ(以降においては相励磁カウンタ)は、最もステート(ステップ角、ステッピングアングル)の数の多い励磁方式(相励磁モード)に基づき作成した相励磁テーブルのステート数を基準に用意されている。このため、最もステート数の多い相励磁モードに対し、それよりステート数の少ない相励磁モードでステッピングモータを駆動するときは、1ステップで更新するカウンタの値を2倍、あるいは4倍等することによりそのステートに適した相励磁信号が出力されるようにしている。
【0003】
【発明が解決しようとする課題】
この装置において励磁方式を切替える、すなわち、相切替えを行う場合は、切替える励磁方式でロータがとりうるステップ角で行わなければならない。このため、相切替えを行うときは、ステッピングモータのステップ角をソフトあるいはハード的に確認し相切替えを行うタイミングを判断しなければならない。あるいは、ステッピングモータを駆動するプログラムを作成する際にステップ単位で検討し、誤りのないステップ角で相切替えが行われるようにする必要がある。
【0004】
ステッピングモータのステップ角を常にモニタしながら適当なステップ角になったときに相切替えを行う方法は、モニタするためのハードウェアおよびモニタリング時間が必要になり、さらに、相切替えをすべきときにステップ角が適当でないとすぐには相切替できない。したがって、制御速度はそれほど早くできず、コスト面でもメリットは少ない。さらに、相切替えの応答速度が低下する可能性がある。このため、制御性は良好とは言えない。ステップ角をモニタしないで相切替えをしても多くの場合ステッピングモータはそのまま回転させることができるかもしれないが、励磁方式と合致しないステップ角でロータが回転する可能性が高いので、騒音や振動の原因となり、また、ステッピングモータの耐久性にも悪影響を与える。
【0005】
一方、ステッピングモータを制御するシーケンスあるいはプログラムを作成する際にステップ単位で明確に定めておけば、騒音などの心配はなく、適切なタイミングで相切替えできる。しかしながら、様々な条件を考慮してステッピングモータをステップ角の単位でプログラムミングするのは大変な時間と労力がかかり開発コストが増大する。また、何らかの衝撃やプログラム作成時には意図しない要因によってステップ角が変動することは往々にしてあることであり、そのような事態のときはやはり相切替え時のステップ角が適当ではなくなるので騒音や振動など上記と同様の問題が発生する。
【0006】
そこで、本発明においては、相切替えするときに切替え可能なステップ角になるまで常に確認する手間を省くことができ、その一方で、相切替えを行うタイミングにおけるステップ角が適当ではなくても振動や騒音などを発生させることなく相切替えできる制御装置および制御方法を提供することを目的としている。
【0007】
また、何らかの要因で相切替えするときのステップ角が適当でなかったときは何らかの異常が発生している。しかしながら、ステップ角を常に監視する方法では適当なステップ角になったときに相切替えされるので、そのような異常は判明しない。また、詳細に検討されたシーケンスあるいはプログラムが用いられているときは異常が発生したのか否かは分からない。
【0008】
そこで、本発明においては、さらに、相切替えするタイミングでステップ角が予期しない、すなわち適当なステップ角でなかったことを判断できる制御装置および制御方法を提供することを目的としている。
【0009】
【課題を解決するための手段】
このため、本発明においては、ステッピングモータの全ステップ角をサイクリックにカウントする2進のカウンタを用意し、相切替えのタイミングで切替え後の励磁方式のステップ角と合致しないときはカウンタの値を強制的に補正するようにしている。さらに、補正するときのステップ角は、切替えの先の励磁方式に適当したステップ角となる、最小のステップ角の2倍あるいは4倍など適当な角度になっていないときである。したがって、2進カウンタの最下位ビットあるいは最下位ビットから適当なビット列をハードあるいはソフトにより強制的に0にすることにより簡単に補正できる。
【0010】
すなわち、本発明の、ステッピングモータを複数の励磁方式で駆動可能な制御装置においては、ステッピングモータの最小ステップ角をカウントするビットを最下位ビットとして全ステップ角をサイクリックにカウントする2進のカウンタであって、該当するステップ角の相励磁信号を生成可能な相励磁カウンタと、この相励磁カウンタの値をステッピングモータの回転方向および励磁方式に従って増減する更新手段と、励磁方式を切替えるときに相励磁カウンタの値が切替え後の励磁方式に対応していないときは、更新手段により相励磁カウンタを更新する前に、切替え後の励磁方式に応じた該相励磁カウンタの最下位ビットまたは下位のビット列を0にする補正手段とを有する。
【0011】
また、本発明のステッピングモータの最小ステップ角を最下位ビットとしてカウントし、全ステップ角をサイクリックにカウントする2進のカウンタであって、該当するステップ角の相励磁信号を生成可能な相励磁カウンタを用い、ステッピングモータを複数の励磁方式で駆動する制御方法においては、相励磁カウンタの値をステッピングモータの回転方向および励磁方式に従って増減する更新工程と、励磁方式を切替えるときに相励磁カウンタの値が切替え後の励磁方式に対応していないときは、更新工程の前に、切替え後の励磁方式に応じた該相励磁カウンタの最下位ビットまたは下位のビット列を0にする補正工程とを有する。
【0012】
本発明の制御装置および制御方法においては、励磁方式を切替えるときにステップ角が合致しないときは相励磁カウンタの最下位ビット、あるいは励磁方式によっては最下位も含めた下位の適当な長さのビット列を0にすることにより相励磁カウンタを励磁方式に対応したカウントに補正し、その後、励磁方式と回転方向にしたがって相励磁カウンタを更新している。したがって、励磁方式を切替えるときにステップ角が合致しないときであっても、ステップ角が適当になるまでモニタリングしながら待つ必要はなく、切替え後の励磁方式に合致した最も近いステップ角を相励磁した後に、その切替え後の励磁方式に合致したステップ角で動かすことができる。このため、必要なときはいつでも相切替えすることができる。さらに、ステップ角が対応していないときでもステップ角を切替え後の励磁方式に合致したステップ角に補正してから切替えるので、騒音や振動が発生することはない。また、ステッピングモータの寿命に影響を与えることもない。
【0013】
さらに、本発明の制御装置および制御方法により、切替えするときにステップ角が合致しなくてもスムーズに相切替えされるので、ステッピングモータを制御するシーケンスあるいはプログラムを開発するときもステップ角単位で詳細に検討しなくても良い。このため、これらの開発期間およびコストを大幅に低減できる。
【0014】
また、補正手段により相励磁カウンタを強制操作したことを記憶可能な異常モニタ手段を設けておくことにより、本来、励磁方式を切替えるためにステップ角が一致するであろう予定のタイミングでステップ角がずれていた異常を検出することができる。したがって、プログラムあるいはシーケンスに含まれた異常を容易に確認でき、デバックできる。また、ステッピングモータを搭載したプリンタなどの機器を駆動中に異常騒音や異常振動が発生したときに、ステッピングモータの制御がその要因であるか否かも確認することができる。
【0015】
本発明の制御装置および制御方法により、2−2相、1−2相およびW1−2相の励磁方式で4相のステッピングモータを駆動する場合は、相励磁カウンタには4ビットカウンタが採用でき、補正手段あるいは補正工程においては、切替え後の励磁方式が1−2相のときは相励磁カウンタの最下位ビットを強制的に0にし、切替え後の励磁方式が2−2相のときは相励磁カウンタの最下位ビットから2つのビット列を強制的に0にすれば良い。
【0016】
【発明の実施の形態】
以下に図面を参照しながら、本発明をさらに説明する。図1に、本発明にかかる制御装置を搭載したプリンタを示してある。本例のプリンタ1は、インクジェット方式あるいはインパクトドット方式などの印刷用のヘッド2が印刷用紙5の走査方向に往復動するシリアルタイプのプリンタである。ヘッド2を搭載したキャリッジ3はタイミングベルト4などの駆動機構により走査方向、本図においては左右の方向に駆動され、タイミングベルト4の駆動源としてステッピングモータ10が採用されている。印刷ヘッド2は、印刷を開始する位置まで移動する速度と印刷する速度が異なるなど、複数の速度で駆動されることがある。このような場合は、ステッピングモータ10を駆動する励磁方式を変えることで制御される。印刷ヘッド2に限らず、印刷用紙5の紙送り機構(不図示)においても給紙の速度と印刷するときの速度が異なり、その場合の制御も同様に行われる。
【0017】
本例のプリンタ1は、ステッピングモータ10に対し制御回路30から適当な実効電力の駆動パルスを供給して駆動する。制御回路30は、ステッピングモータ10の励磁方式がセットされる励磁方式選択レジスタ(モードレジスタ)32と、回転方向がセットされる方向指示レジスタ33と、その他の設定条件、たとえば、後述する相切替え時の補正動さ有無などをセットする初期設定レジスタ31を備えている。制御回路30は、さらに、ロータ11の各ステップ角を定義できる相励磁カウンタ35を備えており、この相励磁カウンタ35の値にしたがい駆動回路20から適当な実効電力および極性の駆動パルスがステ−タ12の各コイルL1、L2、L3およびL4に供給される。そして、この相励磁カウンタ35は、ステッピングモータ10を駆動する条件が設定されたレジスタ31、32および33の内容にしたがって動作するカウンタ制御部40によりアップまたはダウンカウントされる。
【0018】
カウンタ制御部40は、レジスタ31、32あるいは33の内容を判断して全体的な制御を行う中央制御部41と、相励磁カウンタ35に対し回転方向に応じて所定のカウントを加算または減算する更新部42と、励磁方式を切替えるときに相励磁カウンタ35の値が適当でないときにカウンタ35の値を強制的に補正する補正部43を備えている。さらに、補正部43で相励磁カウンタ35の値を強制的に変更したことを異常モニタレジスタ39にセットする異常出力部44を備えている。このような機能を備えたカウンタ制御部40は、ステートマシンによってハード的に実現することも可能であり、あるいは、マイクロプログラムにより実現することも可能である。
【0019】
以下においては、4相のステッピングモータ10に対し、2−2相、1−2相およびW1−2相の励磁方式を切替えて駆動する例を説明する。図2に、各励磁方式における相励磁カウンタ35の値と、ステッピングモータ10のステ−タ12に供給される相励磁信号を示してある。相励磁カウンタ35は2進のカウンタであり、最もステップ角の数の多いW1−2相の16ステップ角に合わせて4ビットのカウンタが採用されている。そして、図2(c)に示すようにW1−2相でステッピングモータ10を駆動するときは相励磁カウンタ35においては、最下位ビットがカウントアップまたはカウントダウンされる。ステート番号36は、ロータ11を制御可能なステップ角に対応している。したがって、図2(a)に示した2−2相、図2(b)に示した1−2相および図2(c)に示したW1−2相で共通したステート番号が用いられており、ステート番号を参照することによりロータ11の角度がわかるようになっている。相励磁信号37は、A相およびB相を構成するコイルL1、L2およびL3、L4に供給される信号レベルを示しており、その比率がさらに表中に示されている。
【0020】
このように、本例の制御回路30においては、相励磁カウンタ35の値に対し相励磁信号37が一義的に設定されている。したがって、相励磁カウンタ35の値を設定することにより、ステッピングモータ10に対し適当な駆動パルスが供給され、ロータ11を所定の角度だけ回転させることができる。さらに、本例の相励磁カウンタ35は2進のカウンタであり、最下位ビットも用いて最もステート数の多いW1−2相の各状態が定義できるようにしている。したがって、ステート数が1/2の8つとなる1−2相においては、図2(b)に示すように、相励磁カウンタ35を2づつ、すなわち2進「10」づつカウントアップあるいはダウンすることにより1−2相の励磁方式でロータ11が移動するステートの相励磁信号を出力できる。同様に、ステート数が4つとなる2−2相の励磁方式においては、相励磁カウンタ35を4づつ、すなわち2進「100」づつカウントアップあるいはダウンすることにより、この励磁方式に合致するステートの相励磁信号を出力できる。
【0021】
したがって、たとえば、W1−2相の励磁方式から1−2相の励磁方式に切替えるときは共通のステートの相励磁信号が出力されている必要があるが、その条件が満足しているか否かは相励磁カウンタ35の最下位ビットが「0」か否かで容易に判断できる。また、2−2相の励磁方式に切替えるときは、相励磁カウンタ35の下位ビット2つが「00」であるか否かで切替え可能なステートであるか否かを容易に判断できる。
【0022】
さらに、相切替えするときのステートが切替え後の励磁方式と共通したものでないときは、切替え後の励磁方式が1−2相のときは、相励磁カウンタ35の最下位ビットを強制的に「0」にして、回転方向に応じて2進「10」を加算あるいは減算することにより、相切替え時のステートに最も近く、切替え後の励磁方式、すなわち1−2相の励磁方式に対応するステートの相励磁信号を出力することができる。したがって、その後は1−2相の励磁方式で相励磁カウンタ35を更新することにより、所定のステート(ステップ角)の相励磁信号を順次出力することができる。2−2相の励磁方式に切替えるときは、下位2ビットを強制的に「00」にした後に、回転方向に応じて2進「100」を増減すれば良い。
【0023】
図3に示したフローチャートに基づき、本例の制御装置30の動作についてさらに説明する。まず、ステップ51において、初期レジスタ31、モードレジスタ32および回転方向レジスタ33を初期設定する。この際、相励磁カウンタ35にも初期の励磁相を設定する。初期の励磁相は相励磁カウンタ35に直接設定しても良く、あるいは、初期設定レジスタに初期励磁相を設定する領域を設けておいても良い。
【0024】
次に、ステップ52で、ステートの異常をチェックする。すなわち、相励磁カウンタ35にセットされた初期の励磁相がモードレジスタ32に設定された励磁方式に合致するか否かをチェックする。2−2相がセットされていれば、相励磁カウンタ35の下位2ビットは「00」である必要がある。また、1−2相がセットされていれば、相励磁カウンタ35の最下位ビットは「0」である必要がある。
【0025】
相励磁カウンタ35の値がモードレジスタ32にセットされた励磁方式と一致しない場合は、プログラムあるいはマシンの状態に何らかの異常があるので、ステップ53において、異常出力部44により異常モニタレジスタ39を異常にセットする。これにより、後で、ジョブ中に異常が発生したか否かを明確に判断できる。また、異常モニタレジスタ44に異常がセットされた段階で、プリンタなどの動作を停止して、ユーザあるいはオペレータが異常の内容をチェックできるようにしておくことも可能である。このような設定は、初期設定レジスタに含め、ジョブ毎に変えることも容易である。
【0026】
相励磁カウンタ35の値がモードレジスタ32にセットされている励磁方式と一致しない場合は、さらに、ステップ54で、補正部43により、励磁次カウンタ35の値を補正する。2−2相がセットされている場合は、相励磁カウンタ35の下位2ビットを「00」にし、1−2相が選択されている場合は相励磁カウンタ35の最下位ビットを「0」にする。W1−2相がセットされている場合は、相励磁カウンタ35に設定可能ないずれのステートも選択しうるので、相励磁カウンタ35の値をチェックする必要はない。
【0027】
ステップ52においてステートの異常が見つからなかったとき、あるいは、ステップ54において励磁方式と合うように相励磁カウンタ35の値が補正されると、ステップ55において、回転方向レジスタ33にセットされた回転方向、およびモードレジスタ32にセットされた励磁方式に基づき更新部42により、相励磁カウンタ35の値が更新される。
【0028】
本例では、2−2相で回転方向がCCW(反時計方向)の場合は、相励磁カウンタ35に2進「0100」を加算する。2−2相で回転方向がCW(時計方向)の場合は、相励磁カウンタ35から2進「0100」を減じる。同様に、本例では、1−2相で回転方向がCCWの場合は、相励磁カウンタ35に2進「0010」を加算し、回転方向がCWの場合は、相励磁カウンタ35から2進「0010」を減じる。さらに、W1−2相で回転方向がCCWの場合は、相励磁カウンタ35に2進「0001」を加算し、回転方向がCWのときは、相励磁カウンタ35から2進「0001」を減じる。
【0029】
このように相励磁カウンタ35の値を更新することにより、各励磁方式および回転方向における次のステートの相励磁信号が出力され、ロータ11が回転する。
【0030】
ステップ55において、制御装置30に励磁方式を変更する指示が入力されると、ステップ57において、モータ10を停止させるのか否かを確認する。停止する命令が出力されているときは、ステップ58で駆動回路20からの駆動パルスを停止しロータ11の回転を止める。一方、モータ10の停止命令でないときは、ステップ59においてモードレジスタ32に新しい励磁方式を格納し、ステップ52に戻って相励磁カウンタ35のカウント値が新しい励磁方式に合致するものであるか否かを判断する。
【0031】
モータ10を駆動中に励磁方式を変更する指示があったときのステップ52、53および54における処理は上記と同様である。まず、ステップ52において、切替え後の励磁方式により、例えば、W1−2相から2−2相に変更するときは相励磁カウンタ35の下位2ビットが0であるか否かを確認し、合致しないときはステップ53で異常モニタレジスタ39をセットする。そして、相励磁カウンタ35の下位2ビットをステップ54で強制的に「00」に設定し、その後、方向がCCWであれば2進「0100」を加算する。したがって、W1−2相で駆動中に2−2相に相切替えしたときに、2−2相のステートになっていない場合でも、切替え時のステートにもっとも近い2−2相のステートに相励磁カウンタ35がセットされ、その相励磁信号が出力される。そして、励磁方式が切り替わった後は、2−2相のピッチで相励磁カウンタ35の値が変化する。W1−2相から1−2相、あるいは1−2相から2−2相に励磁方式を切替える場合も同様である。
【0032】
このように、本例の制御装置30および制御方法においては、励磁方式を切替えるタイミングで、ステッピングモータ10のステートが、切り替え後の励磁方式とは合致しない場合でも、補正部43で強制的に相励磁カウンタ35を操作し、その後、カウンタ35を更新することにより切替え後の励磁方式のステートでステッピングモータ10を駆動することができる。そして、本例においては、2進のカウンタを用いているので、補正するときは切替え後の励磁方式に対応した下位ビットを強制的に0にするだけで良い。このため、切替え時のステート番号を把握したり、切替え後のステート番号を演算するなどの処理は一切不要であり、簡単なハードウェアあるいはソフトウェアで相励磁カウンタ35の値を適切に補正できる。
【0033】
したがって、本例の制御装置および制御方法を採用することにより、ステッピングモータの速度を変更するために相切替えを行うときに、ステップ角(ステート)を監視して適当なステップ角になるタイミングになるまで相切替えを待つようなハードあるいはソフトウェアは不要であり、極めて簡単に、そして短時間に相切替えを行うことができる。また、切替え時にステップ角に異常があっても、補正することにより、タイミングを調整しなくても相切替え後は、所定のステップ角でステッピングモータを駆動できる。したがって、切替え時に異常が発生したときでも、その後、モータを駆動する間に振動あるいは騒音が発生し、モータの寿命を縮めるようなこともない。
【0034】
また、本発明により、切替え時にステップ角が対応していないという異常があっても実際にはスムーズに相切替えを行ってステッピングモータの速度調整が行える。このため、ステッピングモータを制御するプログラムあるいはシーケンスを開発する際も、多少のバグやエラーが含まれている状態でも実用上は問題なくステッピングモータを制御できる。したがって、プログラムあるいはシーケンスを開発する時間およびコストをセーブすることができ、ステッピングモータを用いたプリンタなどの機器の開発時間およびコストを低減することができる。
【0035】
さらに、本例の制御装置および制御方法においては、相切替え時にステップ角に異常があったときは、専用のレジスタに記憶できるようにしている。したがって、製品全体のシーケンスの中で異常があったときに、それが相励磁モードの切替えに起因するものであるか否かを判断し、エラーの修正に役立てることができる。さらに、ステップ角の自動補正を行わないようにすることももちろん可能であり、開発中に設計的な異常の有無を発見することも容易となる。
【0036】
なお、以上においては、4相のステッピングモータを用いて励磁方式が2−2相、1−2相およびW1−2相を例に本発明を説明しているが、このような例に限定されないことはもちろんである。WW1−2相などのさらにステップ角の小さな励磁方式においても本発明を適用することができる。
【0037】
また、相励磁カウンタとして4ビットのカウンタを採用しているが、5ビット以上のカウンタを用いてももちろん良い。しかしながら、W1−2相の16ステートをサイクリックにカウントするには、最上位ビットから4ビット目でステートをカウントすることが望ましい。したがって、W1−2相においては、2進「10」でカウンタを増減し、4ビット目を最下位ビットとすることにより上記のように処理することができる。
【0038】
【発明の効果】
以上に説明したように、本発明においては、ステップ角の相励磁信号を生成可能な2進の相励磁カウンタを設け、励磁方式を切替えるときにステップ角が切替え後の励磁方式と一致しないときは相励磁カウンタを切替え後の励磁方式と一致するように強制的に補正し、その後、切り替え後の励磁方式に従ってカウンタを増減するようにしている。さらに、2進の相励磁カウンタを採用することにより、最下位ビットあるいは最下位から所定のビット列を0にすることで補正することができる。したがって、励磁方式を切替えるときに、ステップ角が合わない異常があっても、最も近い適当なステップ角から切替え後の励磁方式でスムーズにステッピングモータを駆動できる。
【0039】
このため、本発明にかかるステッピングモータの制御装置および制御方法を採用することにより、プリンタなどに採用されているステッピングモータの励磁方式を切替えて速度制御するときに、ステッピングモータのステップ角が適当な値になるまで監視するようなハードあるいはソフトウェアは不要になる。そして、切替えるタイミングであれば、ステップ角が合致しない場合でもスムーズに励磁方式を切替えることができる。
【0040】
さらに、本発明を採用することにより、ステッピングモータの制御用のプログラムあるいはシーケンスの開発時間および費用を削減することができる。また、本発明の制御装置および制御方法においては、ステップ角に異常があれば、それを補正するようにしているので、そのタイミングでステップ角の異常の有無をレジスタなどに記憶できる。したがって、その情報をプログラム開発あるいは製品に不具合が発生したときのログとして有効活用することも可能となる。
【図面の簡単な説明】
【図1】本発明の実施の形態にかかる制御装置の概略構成を示すブロック図である。
【図2】図1に示す相励磁カウンタの値と、励磁方式との関係を示す表であり、図2(a)は2−2相、図2(b)は1−2相、および図2(c)はW1−2相の励磁方式を示している。
【図3】図1に示す制御装置における処理を示すフローチャートである。
【符号の説明】
1 プリンタ
2 ヘッド
3 キャリッジ
5 印刷用紙
10 ステッピングモータ
11 ロータ
12 ステータ
20 駆動回路
30 モータ制御装置
35 相励磁カウンタ
39 異常モニタレジスタ
40 カウンタ制御部
41 中央制御部
42 更新部
43 補正部
44 異常出力部
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a stepping motor control apparatus and method.
[0002]
[Prior art]
In a printer that employs a stepping motor as a drive source for the carriage or paper feed mechanism, the carriage or paper feed speed is controlled by switching the excitation method. For this reason, there is known a control device that drives a stepping motor by an ASIC or the like by a plurality of excitation methods in hardware, for example, excitation methods such as one-phase, 2-2 phase, 1-2 phase, or W1-2 phase. . Of course, such a control device is not limited to a printer, and is often used for devices that need to control the speed of a stepping motor. One of such control devices is a system using a counter for generating a phase excitation signal. This counter (hereinafter, phase excitation counter) is prepared based on the number of states in the phase excitation table created based on the excitation method (phase excitation mode) having the largest number of states (step angle, stepping angle). Therefore, when the stepping motor is driven in the phase excitation mode with the smallest number of states compared to the phase excitation mode with the largest number of states, the counter value updated in one step should be doubled or quadrupled. Thus, a phase excitation signal suitable for the state is output.
[0003]
[Problems to be solved by the invention]
In this apparatus, when the excitation method is switched, that is, when the phase is switched, it must be performed at a step angle that the rotor can take in the switching excitation method. For this reason, when performing phase switching, the step angle of the stepping motor must be confirmed in software or hardware to determine the timing for phase switching. Alternatively, when creating a program for driving the stepping motor, it is necessary to consider in units of steps so that phase switching is performed at a step angle without error.
[0004]
The method of phase switching when an appropriate step angle is obtained while constantly monitoring the step angle of the stepping motor requires hardware and monitoring time for monitoring, and further steps when phase switching should be performed. If the angle is not appropriate, the phase cannot be switched immediately. Therefore, the control speed cannot be made so fast, and there are few advantages in terms of cost. Furthermore, the response speed of phase switching may be reduced. For this reason, controllability is not good. Even if the phase is switched without monitoring the step angle, the stepping motor may still be able to rotate as it is, but the rotor is likely to rotate at a step angle that does not match the excitation method. In addition, the durability of the stepping motor is also adversely affected.
[0005]
On the other hand, if the sequence or program for controlling the stepping motor is clearly defined for each step, there is no concern about noise and the like, and the phase can be switched at an appropriate timing. However, it takes a lot of time and labor to program the stepping motor in units of step angles in consideration of various conditions, and the development cost increases. Also, it is often the case that the step angle fluctuates due to some impact or an unintended factor when creating a program. In such a situation, the step angle at the time of phase switching is no longer appropriate, so noise, vibration, etc. The same problem as above occurs.
[0006]
Therefore, in the present invention, it is possible to save the trouble of constantly checking until the switchable step angle is reached when the phase is switched. On the other hand, even if the step angle at the timing of phase switching is not appropriate, vibration or An object of the present invention is to provide a control device and a control method capable of phase switching without generating noise or the like.
[0007]
In addition, if the step angle at the time of phase switching is not appropriate for some reason, some abnormality has occurred. However, in the method of constantly monitoring the step angle, since the phase is switched when the appropriate step angle is reached, such an abnormality is not found. Further, when a sequence or program that has been studied in detail is used, it is not known whether or not an abnormality has occurred.
[0008]
Therefore, an object of the present invention is to provide a control device and a control method capable of determining that the step angle is unexpected, that is, not an appropriate step angle at the phase switching timing.
[0009]
[Means for Solving the Problems]
For this reason, in the present invention, a binary counter that cyclically counts all step angles of the stepping motor is prepared. When the step angle of the excitation method does not match at the phase switching timing, the counter value is set. The correction is forcibly made. Further, the step angle for correction is a time that is not a suitable angle such as 2 or 4 times the minimum step angle, which is a step angle suitable for the excitation method of the switching destination. Therefore, it can be easily corrected by forcibly setting an appropriate bit string from the least significant bit or the least significant bit of the binary counter to 0 by hardware or software.
[0010]
That is, in the control device capable of driving the stepping motor by a plurality of excitation methods according to the present invention, the binary counter that counts all step angles cyclically with the bit for counting the minimum step angle of the stepping motor as the least significant bit. A phase excitation counter that can generate a phase excitation signal of the corresponding step angle, an update means that increases or decreases the value of the phase excitation counter according to the rotation direction of the stepping motor and the excitation method, and a phase when the excitation method is switched. When the value of the excitation counter does not correspond to the excitation method after switching, before updating the phase excitation counter by the updating means, the least significant bit or the lower bit string of the phase excitation counter according to the excitation method after switching And a correction means for setting 0 to 0.
[0011]
Further, the present invention is a binary counter that counts the minimum step angle of the stepping motor of the present invention as the least significant bit and cyclically counts all the step angles, and can generate a phase excitation signal of the corresponding step angle. In a control method that uses a counter and drives a stepping motor with a plurality of excitation methods, an update process that increases or decreases the value of the phase excitation counter according to the rotation direction of the stepping motor and the excitation method, and the phase excitation counter value when the excitation method is switched. When the value does not correspond to the excitation method after switching, a correction step of setting the least significant bit or the lower-order bit string of the phase excitation counter according to the excitation method after switching to 0 before the updating step is included .
[0012]
In the control apparatus and control method of the present invention, when the step angle does not match when switching the excitation method, the least significant bit of the phase excitation counter, or a lower-order bit string including the least significant bit depending on the excitation method By setting 0 to 0, the phase excitation counter is corrected to a count corresponding to the excitation method, and then the phase excitation counter is updated according to the excitation method and the rotation direction. Therefore, even when the step angle does not match when switching the excitation method, there is no need to wait while monitoring until the step angle is suitable, and the nearest step angle that matches the excitation method after switching is phase excited. Later, it can be moved at a step angle that matches the excitation method after the switching. For this reason, the phase can be switched whenever necessary. Furthermore, even when the step angle is not compatible, the step angle is corrected to the step angle that matches the excitation method after switching, so that noise and vibration do not occur. Further, it does not affect the life of the stepping motor.
[0013]
Furthermore, because the control device and the control method of the present invention smoothly perform phase switching even when the step angle does not match when switching, the details for each step angle when developing a sequence or program for controlling a stepping motor are also provided. You do not have to consider it. For this reason, these development periods and costs can be significantly reduced.
[0014]
Also, by providing abnormality monitoring means that can memorize that the phase excitation counter has been forcibly operated by the correction means, the step angle can be set at the timing at which the step angles are supposed to coincide in order to switch the excitation method. The shifted abnormality can be detected. Therefore, the abnormality included in the program or sequence can be easily confirmed and debugged. Further, when abnormal noise or abnormal vibration occurs while driving a device such as a printer equipped with a stepping motor, it can also be confirmed whether or not the control of the stepping motor is the cause.
[0015]
When a 4-phase stepping motor is driven by the 2-2 phase, 1-2 phase, and W1-2 phase excitation methods using the control device and control method of the present invention, a 4-bit counter can be adopted as the phase excitation counter. In the correction means or the correction process, when the excitation method after switching is 1-2 phase, the least significant bit of the phase excitation counter is forcibly set to 0, and when the excitation method after switching is 2-2 phase, the phase is The two bit strings may be forced to 0 from the least significant bit of the excitation counter.
[0016]
DETAILED DESCRIPTION OF THE INVENTION
The present invention will be further described below with reference to the drawings. FIG. 1 shows a printer equipped with a control device according to the present invention. The printer 1 of this example is a serial type printer in which a printing head 2 such as an inkjet method or an impact dot method reciprocates in the scanning direction of the printing paper 5. The carriage 3 on which the head 2 is mounted is driven in the scanning direction, in the right and left directions in the drawing, by a driving mechanism such as a timing belt 4, and a stepping motor 10 is employed as a driving source for the timing belt 4. The print head 2 may be driven at a plurality of speeds, for example, the speed at which the print head 2 moves to a position where printing is started differs from the speed at which printing is performed. In such a case, it is controlled by changing the excitation method for driving the stepping motor 10. Not only the print head 2 but also a paper feed mechanism (not shown) of the printing paper 5 has a different paper feed speed and printing speed, and the control in that case is performed in the same way.
[0017]
The printer 1 of this example is driven by supplying a driving pulse of appropriate effective power from the control circuit 30 to the stepping motor 10. The control circuit 30 includes an excitation method selection register (mode register) 32 in which the excitation method of the stepping motor 10 is set, a direction instruction register 33 in which the rotation direction is set, and other setting conditions such as a phase switching described later. Is provided with an initial setting register 31 for setting the presence / absence of correction movement. The control circuit 30 further includes a phase excitation counter 35 that can define each step angle of the rotor 11. According to the value of the phase excitation counter 35, a drive pulse of appropriate effective power and polarity is supplied from the drive circuit 20. Is supplied to each of the coils L1, L2, L3 and L4. The phase excitation counter 35 is counted up or down by the counter control unit 40 that operates according to the contents of the registers 31, 32, and 33 in which conditions for driving the stepping motor 10 are set.
[0018]
The counter control unit 40 judges the contents of the register 31, 32 or 33, and performs central control 41 for performing overall control, and update for adding or subtracting a predetermined count to the phase excitation counter 35 according to the rotation direction And a correction unit 43 that forcibly corrects the value of the counter 35 when the value of the phase excitation counter 35 is not appropriate when switching the excitation method. Further, an abnormality output unit 44 that sets in the abnormality monitor register 39 that the correction unit 43 has forcibly changed the value of the phase excitation counter 35 is provided. The counter control unit 40 having such a function can be realized in hardware by a state machine, or can be realized by a microprogram.
[0019]
Hereinafter, an example will be described in which the four-phase stepping motor 10 is driven by switching the excitation method of the 2-2 phase, 1-2 phase, and W1-2 phase. FIG. 2 shows the value of the phase excitation counter 35 and the phase excitation signal supplied to the stator 12 of the stepping motor 10 in each excitation method. The phase excitation counter 35 is a binary counter, and a 4-bit counter is employed in accordance with the 16-step angle of the W1-2 phase having the largest number of step angles. As shown in FIG. 2C, when the stepping motor 10 is driven in the W1-2 phase, in the phase excitation counter 35, the least significant bit is counted up or down. The state number 36 corresponds to a step angle at which the rotor 11 can be controlled. Therefore, a common state number is used for the 2-2 phase shown in FIG. 2A, the 1-2 phase shown in FIG. 2B, and the W1-2 phase shown in FIG. 2C. The angle of the rotor 11 can be known by referring to the state number. The phase excitation signal 37 indicates the signal level supplied to the coils L1, L2 and L3, L4 constituting the A phase and the B phase, and the ratio is further shown in the table.
[0020]
Thus, in the control circuit 30 of this example, the phase excitation signal 37 is uniquely set with respect to the value of the phase excitation counter 35. Therefore, by setting the value of the phase excitation counter 35, an appropriate drive pulse is supplied to the stepping motor 10 and the rotor 11 can be rotated by a predetermined angle. Further, the phase excitation counter 35 of this example is a binary counter, and the W1-2 phase state having the largest number of states can be defined using the least significant bit. Accordingly, in the 1-2 phase where the number of states is eight, which is 1/2, as shown in FIG. 2B, the phase excitation counter 35 is incremented or decremented by two, that is, by binary "10". Thus, a phase excitation signal in a state in which the rotor 11 moves by the 1-2 phase excitation method can be output. Similarly, in the 2-2 phase excitation method in which the number of states is four, the phase excitation counter 35 is counted up or down by four, that is, by binary “100”, so that the state that matches this excitation method can be obtained. A phase excitation signal can be output.
[0021]
Therefore, for example, when switching from the W1-2 phase excitation method to the 1-2 phase excitation method, it is necessary to output a phase excitation signal in a common state. This can be easily determined by determining whether the least significant bit of the phase excitation counter 35 is “0”. Further, when switching to the 2-2 phase excitation method, it is possible to easily determine whether or not it is a switchable state based on whether or not the two lower bits of the phase excitation counter 35 are “00”.
[0022]
Furthermore, when the state at the time of phase switching is not common with the excitation method after switching, when the excitation method after switching is 1-2 phase, the least significant bit of the phase excitation counter 35 is forcibly set to “0”. ”And adding or subtracting binary“ 10 ”according to the direction of rotation, it is closest to the state at the time of phase switching, and the state of the state corresponding to the excitation method after switching, that is, the 1-2 phase excitation method. A phase excitation signal can be output. Therefore, thereafter, the phase excitation counter 35 is updated by the 1-2 phase excitation method, so that the phase excitation signal of a predetermined state (step angle) can be sequentially output. When switching to the 2-2 phase excitation method, the lower 2 bits are forcibly set to “00” and then the binary “100” is increased or decreased according to the rotation direction.
[0023]
Based on the flowchart shown in FIG. 3, the operation of the control device 30 of this example will be further described. First, in step 51, the initial register 31, the mode register 32, and the rotation direction register 33 are initialized. At this time, the initial excitation phase is also set in the phase excitation counter 35. The initial excitation phase may be set directly in the phase excitation counter 35, or an area for setting the initial excitation phase may be provided in the initial setting register.
[0024]
Next, in step 52, the state abnormality is checked. That is, it is checked whether the initial excitation phase set in the phase excitation counter 35 matches the excitation method set in the mode register 32. If the 2-2 phase is set, the lower 2 bits of the phase excitation counter 35 need to be “00”. If the 1-2 phase is set, the least significant bit of the phase excitation counter 35 needs to be “0”.
[0025]
If the value of the phase excitation counter 35 does not match the excitation method set in the mode register 32, there is some abnormality in the state of the program or the machine. In step 53, the abnormality output register 44 makes the abnormality monitor register 39 abnormal. set. Thereby, it can be clearly determined later whether or not an abnormality has occurred during the job. It is also possible to stop the operation of the printer or the like when an abnormality is set in the abnormality monitor register 44 so that the user or operator can check the content of the abnormality. Such settings can be easily included in the initial setting register and changed for each job.
[0026]
If the value of the phase excitation counter 35 does not match the excitation method set in the mode register 32, the correction unit 43 corrects the value of the excitation next counter 35 in step 54. When the 2-2 phase is set, the lower 2 bits of the phase excitation counter 35 are set to “00”. When the 1-2 phase is selected, the least significant bit of the phase excitation counter 35 is set to “0”. To do. When the W1-2 phase is set, any state that can be set in the phase excitation counter 35 can be selected, so it is not necessary to check the value of the phase excitation counter 35.
[0027]
If no state abnormality is found in step 52, or if the value of the phase excitation counter 35 is corrected to match the excitation method in step 54, the rotation direction set in the rotation direction register 33 in step 55, Based on the excitation method set in the mode register 32, the value of the phase excitation counter 35 is updated by the updating unit 42.
[0028]
In this example, when the rotation direction is CCW (counterclockwise) in the 2-2 phase, binary “0100” is added to the phase excitation counter 35. When the rotation direction is CW (clockwise) in the 2-2 phase, the binary “0100” is subtracted from the phase excitation counter 35. Similarly, in this example, when the rotation direction is CCW in the 1-2 phase, binary “0010” is added to the phase excitation counter 35, and when the rotation direction is CW, the binary excitation “35” is output from the phase excitation counter 35. Reduce "0010". Further, when the rotation direction is CCW in the W1-2 phase, binary “0001” is added to the phase excitation counter 35, and when the rotation direction is CW, binary “0001” is subtracted from the phase excitation counter 35.
[0029]
Thus, by updating the value of the phase excitation counter 35, the phase excitation signal of the next state in each excitation method and rotation direction is output, and the rotor 11 rotates.
[0030]
In step 55, when an instruction to change the excitation method is input to the control device 30, it is confirmed in step 57 whether or not the motor 10 is to be stopped. If a command to stop is output, the drive pulse from the drive circuit 20 is stopped in step 58 to stop the rotation of the rotor 11. On the other hand, if the instruction is not to stop the motor 10, the new excitation method is stored in the mode register 32 in step 59, and the process returns to step 52 to check whether the count value of the phase excitation counter 35 matches the new excitation method. Judging.
[0031]
The processing in steps 52, 53 and 54 when there is an instruction to change the excitation method while driving the motor 10 is the same as described above. First, in step 52, for example, when changing from the W1-2 phase to the 2-2 phase according to the excitation method after switching, it is confirmed whether the lower 2 bits of the phase excitation counter 35 are 0 and do not match. In step 53, the abnormality monitor register 39 is set. Then, the lower 2 bits of the phase excitation counter 35 are forcibly set to “00” in step 54, and thereafter, if the direction is CCW, binary “0100” is added. Therefore, when the phase is switched to 2-2 phase during driving in the W1-2 phase, even if it is not in the 2-2 phase state, phase excitation is performed to the 2-2 phase state closest to the switching state. The counter 35 is set and the phase excitation signal is output. After the excitation method is switched, the value of the phase excitation counter 35 changes at a 2-2 phase pitch. The same applies when switching the excitation method from the W1-2 phase to the 1-2 phase, or from the 1-2 phase to the 2-2 phase.
[0032]
As described above, in the control device 30 and the control method of this example, even when the state of the stepping motor 10 does not match the excitation method after switching at the timing of switching the excitation method, the correction unit 43 forcibly complies with the excitation method. By operating the excitation counter 35 and then updating the counter 35, the stepping motor 10 can be driven in the state of the excitation method after switching. In this example, since a binary counter is used, it is only necessary to forcibly set the lower bits corresponding to the excitation method after switching to 0 for correction. For this reason, it is not necessary to know the state number at the time of switching or to calculate the state number after switching, and the value of the phase excitation counter 35 can be appropriately corrected with simple hardware or software.
[0033]
Therefore, by adopting the control device and the control method of this example, when phase switching is performed to change the speed of the stepping motor, the step angle (state) is monitored and the timing becomes an appropriate step angle. No hardware or software that waits until phase switching is required, and phase switching can be performed very easily and in a short time. Even if there is an abnormality in the step angle at the time of switching, the stepping motor can be driven at a predetermined step angle after phase switching without correcting the timing by correcting it. Therefore, even when an abnormality occurs at the time of switching, vibrations or noises are not generated during the subsequent driving of the motor, and the life of the motor is not shortened.
[0034]
In addition, according to the present invention, even if there is an abnormality that the step angle does not correspond at the time of switching, the speed of the stepping motor can be adjusted by actually smoothly switching the phases. Therefore, even when a program or sequence for controlling the stepping motor is developed, the stepping motor can be controlled practically without any problem even if some bugs or errors are included. Therefore, the time and cost for developing a program or sequence can be saved, and the development time and cost of a device such as a printer using a stepping motor can be reduced.
[0035]
Further, in the control device and the control method of this example, when there is an abnormality in the step angle during phase switching, it can be stored in a dedicated register. Therefore, when there is an abnormality in the sequence of the entire product, it can be determined whether or not it is caused by switching of the phase excitation mode, and can be used for correcting the error. Furthermore, it is of course possible not to automatically correct the step angle, and it becomes easy to find out whether there is a design abnormality during development.
[0036]
In the above description, the present invention has been described using a four-phase stepping motor as an example of the excitation method 2-2 phase, 1-2 phase, and W1-2 phase. However, the present invention is not limited to such an example. Of course. The present invention can also be applied to an excitation method with a smaller step angle such as the WW1-2 phase.
[0037]
Further, although a 4-bit counter is adopted as the phase excitation counter, it is of course possible to use a 5-bit or more counter. However, in order to cyclically count the 16 states of the W1-2 phase, it is desirable to count the states at the fourth bit from the most significant bit. Therefore, in the W1-2 phase, the processing can be performed as described above by increasing or decreasing the counter by binary “10” and setting the fourth bit as the least significant bit.
[0038]
【The invention's effect】
As described above, in the present invention, when a binary phase excitation counter capable of generating a step angle phase excitation signal is provided and the step angle does not match the excitation method after switching when the excitation method is switched, The phase excitation counter is forcibly corrected to coincide with the excitation method after switching, and then the counter is increased or decreased according to the excitation method after switching. Further, by adopting a binary phase excitation counter, correction can be made by setting a predetermined bit string to 0 from the least significant bit or the least significant bit. Therefore, even when there is an abnormality in which the step angle does not match when switching the excitation method, the stepping motor can be driven smoothly from the nearest appropriate step angle by the excitation method after switching.
[0039]
For this reason, by adopting the stepping motor control device and control method according to the present invention, the stepping motor has a suitable step angle when speed control is performed by switching the excitation method of the stepping motor employed in a printer or the like. No hardware or software to monitor until the value is reached. Then, at the timing of switching, the excitation method can be switched smoothly even when the step angles do not match.
[0040]
Further, by adopting the present invention, it is possible to reduce the development time and cost of a program or sequence for controlling a stepping motor. Further, in the control device and the control method of the present invention, if there is an abnormality in the step angle, it is corrected, so the presence or absence of the abnormality in the step angle can be stored in a register or the like at that timing. Therefore, the information can be effectively utilized as a log when a problem occurs in program development or product.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a schematic configuration of a control device according to an embodiment of the present invention.
2 is a table showing the relationship between the value of the phase excitation counter shown in FIG. 1 and the excitation method, FIG. 2 (a) is 2-2 phase, FIG. 2 (b) is 1-2 phase, and FIG. 2 (c) shows the W1-2 phase excitation method.
FIG. 3 is a flowchart showing processing in the control device shown in FIG. 1;
[Explanation of symbols]
1 Printer
2 heads
3 Carriage
5 Printing paper
10 Stepping motor
11 Rotor
12 Stator
20 Drive circuit
30 Motor controller
35-phase excitation counter
39 Abnormality monitor register
40 Counter control unit
41 Central control unit
42 Update Department
43 Correction section
44 Abnormal output section

Claims (5)

ステッピングモータを複数の励磁方式で駆動可能な制御装置であって、
ステッピングモータの最小ステップ角をカウントするビットを最下位ビットとして全ステップ角をサイクリックにカウントする2進のカウンタであって、該当するステップ角の相励磁信号を生成可能な相励磁カウンタと、
この相励磁カウンタの値をステッピングモータの回転方向および励磁方式に従って増減する更新手段と、
励磁方式を切替えるときに前記相励磁カウンタの値が切替え後の励磁方式に対応しているかどうかを判断する判断手段と、
前記相励磁カウンタの値が切替え後の励磁方式に対応していないときは、前記更新手段により前記相励磁カウンタを更新する前に、切替え後の励磁方式に応じた該相励磁カウンタの最下位ビットまたは最下のビット列を0にする補正手段と
前記補正手段により前記相励磁カウンタを操作したことを記憶可能な異常モニタ手段と、を有するステッピングモータの制御装置。
A control device capable of driving a stepping motor with a plurality of excitation methods,
A binary counter that cyclically counts all step angles with the bit that counts the minimum step angle of the stepping motor as the least significant bit, and a phase excitation counter that can generate a phase excitation signal of the corresponding step angle;
Updating means for increasing or decreasing the value of the phase excitation counter according to the rotation direction and excitation method of the stepping motor;
Determining means for determining whether compatible with excitation method after the value of the phase excitation counter switch when switching the excitation mode,
When the value of the phase excitation counter does not correspond to the excitation method after switching, before updating the phase excitation counter by the updating means, the least significant bit of the phase excitation counter corresponding to the excitation method after switching Or correction means for setting the lowest bit string to 0 ;
A stepping motor control device comprising: an abnormality monitoring unit capable of storing the operation of the phase excitation counter by the correction unit .
請求項1において、前記制御装置は、2−2相、1−2相およびW1−2相の励磁方式で4相のステッピングモータを駆動可能であり、
前記相励磁カウンタは4ビットで、前記補正手段は、切替え後の励磁方式が1−2相のときは前記相励磁カウンタの最下位ビットを強制的に0にし、切替え後の励磁方式が2−2相のときは前記相励磁カウンタの最下位ビットから2つのビット列を強制的に0にすることを特徴とするステッピングモータの制御装置。
In Claim 1, the said control apparatus can drive a 4-phase stepping motor by the excitation method of 2-2 phase, 1-2 phase, and W1-2 phase,
The phase excitation counter is 4 bits, and the correction means forcibly sets the least significant bit of the phase excitation counter to 0 when the excitation method after switching is 1-2 phase, and the excitation method after switching is 2- In the case of two phases, the stepping motor control device is characterized in that two bit strings are forcibly set to 0 from the least significant bit of the phase excitation counter.
ステッピングモータの最小ステップ角を最下位ビットとしてカウントし、全ステップ角をサイクリックにカウントする2進のカウンタであって、該当するステップ角の相励磁信号を生成可能な相励磁カウンタを用い、ステッピングモータを複数の励磁方式で駆動する制御方法であって、
前記相励磁カウンタの値をステッピングモータの回転方向および励磁方式に従って増減する更新工程と、
励磁方式を切替えるときに前記相励磁カウンタの値が切替え後の励磁方式に対応しているかどうかを判断する判断工程と、
前記相励磁カウンタの値が切替え後の励磁方式に対応していないときは、前記更新工程の前に、切替え後の励磁方式に応じた該相励磁カウンタの最下位ビットまたは下位のビット列を0にする補正工程と、
前記補正工程により前記相励磁カウンタを操作したことを記憶する異常モニタ工程と、を有するステッピングモータの制御方法。
Stepping motor using a phase excitation counter that counts the minimum step angle of the stepping motor as the least significant bit and cyclically counts all step angles, and can generate a phase excitation signal of the corresponding step angle. A control method for driving a motor with a plurality of excitation methods,
An update step of increasing or decreasing the value of the phase excitation counter according to the rotation direction and excitation method of the stepping motor;
A determination step of determining whether compatible with excitation method after the value of the phase excitation counter switch when switching the excitation mode,
When the value of the phase excitation counter does not correspond to the excitation method after switching, the least significant bit or the lower-order bit string of the phase excitation counter corresponding to the excitation method after switching is set to 0 before the update process. A correction process to
A stepping motor control method comprising: an abnormality monitoring step of storing that the phase excitation counter has been operated in the correction step .
請求項3において、4ビットの前記相励磁カウンタにより、2−2相、1−2相およびW1−2相の励磁方式で4相のステッピングモータを駆動し、
前記補正工程では、切替え後の励磁方式が1−2相のときは前記相励磁カウンタの最下位ビットを強制的に0にし、切替え後の励磁方式が2−2相のときは前記相励磁カウンタの最下位ビットから2つのビット列を強制的に0にすることを特徴とするステッピングモータの制御方法。
In Claim 3, the 4-bit stepping motor is driven by the excitation method of 2-2 phase, 1-2 phase and W1-2 phase by the 4-bit phase excitation counter,
In the correction step, when the excitation method after switching is 1-2 phase, the least significant bit of the phase excitation counter is forcibly set to 0, and when the excitation method after switching is 2-2 phase, the phase excitation counter A stepping motor control method characterized in that two bit strings are forcibly set to 0 from the least significant bit.
ステッピングモータによりキャリッジまたは紙送り機構を駆動するプリンタにおいて、請求項1に記載の制御装置を有することを特徴とするプリンタ。  A printer that drives a carriage or a paper feed mechanism by a stepping motor, comprising the control device according to claim 1.
JP7788699A 1999-03-23 1999-03-23 Stepping motor control device, control method, and printer Expired - Fee Related JP3783455B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP7788699A JP3783455B2 (en) 1999-03-23 1999-03-23 Stepping motor control device, control method, and printer

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP7788699A JP3783455B2 (en) 1999-03-23 1999-03-23 Stepping motor control device, control method, and printer

Publications (2)

Publication Number Publication Date
JP2000272190A JP2000272190A (en) 2000-10-03
JP3783455B2 true JP3783455B2 (en) 2006-06-07

Family

ID=13646566

Family Applications (1)

Application Number Title Priority Date Filing Date
JP7788699A Expired - Fee Related JP3783455B2 (en) 1999-03-23 1999-03-23 Stepping motor control device, control method, and printer

Country Status (1)

Country Link
JP (1) JP3783455B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4089469B2 (en) 2002-03-14 2008-05-28 セイコーエプソン株式会社 Motor drive device and recording device

Also Published As

Publication number Publication date
JP2000272190A (en) 2000-10-03

Similar Documents

Publication Publication Date Title
JP3783455B2 (en) Stepping motor control device, control method, and printer
US5264769A (en) Recording device with a controllable carriage driving motor
JP3800917B2 (en) Motor control device and storage medium
JP2001275374A (en) Motor controller and storage medium
JPH0515197A (en) Drive control method for step motor
JPS632643A (en) Cutting machine
JP2741751B2 (en) Stepping motor drive system
JPS59194699A (en) Stopping controller of stepping motor
JP2002284341A (en) Turntable control system and control method for turntable control system
JP4251982B2 (en) Velocity control device and image forming apparatus having the same
JP6962044B2 (en) Motor control device, image forming device and electronic equipment
JPH03164085A (en) Automatic motor controller
JP2000287498A (en) Controller for driving stepping motor
JP3415258B2 (en) Dot printer shuttle controller
JP2002240381A (en) Serial printer
KR930000183B1 (en) Serial printer
JPH1127986A (en) Motor controller
JPH0345713B2 (en)
JPS6281997A (en) Method for driving stepping motor
JPH10138596A (en) Carriage driving device for printer and assembling method thereof
JP2005111712A (en) Printer
JP3059118U (en) Stepping motor control device
JPH0295200A (en) Recording device
JPH07194195A (en) Controller for stepping motor
JPH10157203A (en) Method for controlling shuttle of dot printer

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20040930

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20041109

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20050107

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20060221

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20060306

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20090324

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20100324

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20100324

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20110324

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20120324

Year of fee payment: 6

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

Free format text: PAYMENT UNTIL: 20120324

Year of fee payment: 6

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

Free format text: PAYMENT UNTIL: 20130324

Year of fee payment: 7

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

Free format text: PAYMENT UNTIL: 20140324

Year of fee payment: 8

LAPS Cancellation because of no payment of annual fees