JP2006042493A - Apparatus and method for controlling motor - Google Patents

Apparatus and method for controlling motor Download PDF

Info

Publication number
JP2006042493A
JP2006042493A JP2004218394A JP2004218394A JP2006042493A JP 2006042493 A JP2006042493 A JP 2006042493A JP 2004218394 A JP2004218394 A JP 2004218394A JP 2004218394 A JP2004218394 A JP 2004218394A JP 2006042493 A JP2006042493 A JP 2006042493A
Authority
JP
Japan
Prior art keywords
phase excitation
motor
clock
stepping motor
output
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.)
Withdrawn
Application number
JP2004218394A
Other languages
Japanese (ja)
Inventor
Yoshiyuki Nakajima
中島  慶幸
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2004218394A priority Critical patent/JP2006042493A/en
Publication of JP2006042493A publication Critical patent/JP2006042493A/en
Withdrawn legal-status Critical Current

Links

Images

Landscapes

  • Control Of Stepping Motors (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a motor controller with which the following problems can be solved: a problem that, when the speed of a phase excitation motor is changed during constant speed rotation, the CPU resources become insufficient; a problem that, when the motor speed is controlled simply using acceleration/deceleration tables, much processing time is required. <P>SOLUTION: An image forming apparatus includes: CPU 200 having a clock oscillator 210 and a communication control unit 211; and ASIC 203 having a clock oscillator 221, a control unit 223, and a port register 224. The control unit 223 of the ASIC 203 operates as follows: when a stepping motor 204 is controlled at acceleration, it outputs to the stepping motor 204 a phase excitation signal synchronized with internal clock and corresponding to a phase excitation pattern; when the stepping motor 204 is controlled at constant speed, it outputs to the stepping motor 204 a phase excitation signal synchronized with external clock from the CPU 200; and when the stepping motor 204 is controlled at deceleration, it outputs to the stepping motor 204 a phase excitation signal synchronized with internal clock. <P>COPYRIGHT: (C)2006,JPO&NCIPI

Description

本発明は、ステッピングモータ等の相励磁方式モータの制御に適用可能なモータ制御装置及びその制御方法に関する。   The present invention relates to a motor control device applicable to control of a phase excitation motor such as a stepping motor and a control method thereof.

従来、相励磁方式のモータの制御に際しては、汎用CPU(中央演算処理装置)或いはCPUに代わる制御回路を用いて制御を行っている。特に、画像形成装置では非常に多くの相励磁方式のモータを使用している。従って、画像形成装置においては、1つのCPUの制御により全てのモータを動作させることは、CPUの資源(タイマ、ポート数、DTC(Data Transfer Controller)、DMAC(Direct Memory Access Controller)など)の制約を受けたり、CPUにおける処理負荷の増大を伴ったりするので非常に困難である。   Conventionally, when controlling a phase excitation motor, control is performed using a general-purpose CPU (central processing unit) or a control circuit in place of the CPU. In particular, an image forming apparatus uses a very large number of phase excitation motors. Therefore, in an image forming apparatus, operating all motors under the control of one CPU restricts CPU resources (timer, number of ports, DTC (Data Transfer Controller), DMAC (Direct Memory Access Controller), etc.). And is accompanied by an increase in processing load on the CPU, which is very difficult.

そこで、画像形成装置等の装置が複数の相励磁方式のモータを搭載している場合、複雑な制御を必要としないモータについては、ASIC(Application Specific Integrated Circuit)などの制御回路を通してCPUから独立して制御させる方法が提案されている(例えば、特許文献1、特許文献2参照)。   Therefore, when an apparatus such as an image forming apparatus is equipped with a plurality of phase excitation motors, a motor that does not require complicated control is independent of the CPU through a control circuit such as an ASIC (Application Specific Integrated Circuit). Have been proposed (see, for example, Patent Document 1 and Patent Document 2).

更に、相励磁方式のモータを制御するための制御情報を予めCPUからASICへ転送しておき、モータの制御時にはCPUがモータを動作させるトリガを与えるだけでASICがモータの制御を開始するような構成が提案されている。
特開平11−21587号公報 特開2002−23283号公報
Further, control information for controlling the phase excitation type motor is transferred in advance from the CPU to the ASIC, and when the motor is controlled, the ASIC starts the motor control only by giving a trigger for the CPU to operate the motor. A configuration is proposed.
Japanese Patent Laid-Open No. 11-21587 JP 2002-23283 A

しかしながら、従来技術において、相励磁方式のモータを一定速度で回転駆動する等速回転時に速度変更を行うような場合は、予めモータの回転パターンが決められているASICなどで速度変更制御を行うことは非常に困難である。このような場合はCPUを用いた制御が適しているが、画像形成装置のように多くの相励磁方式のモータを使用する場合、CPUの資源が不足してしまうという問題がある。   However, in the prior art, when the speed change is performed at the constant speed rotation of the phase excitation motor at a constant speed, the speed change control is performed by an ASIC or the like in which the rotation pattern of the motor is determined in advance. Is very difficult. In such a case, control using a CPU is suitable. However, when many phase excitation motors are used as in an image forming apparatus, there is a problem that CPU resources are insufficient.

一方、相励磁方式のモータの速度制御に際しては、モータの加速/減速を制御するための加速度パターン/減速度パターンを記憶した加減速テーブルを用いて速度制御を行うことも可能である。しかし、加減速テーブルを用いた場合、テーブル長が非常に長くなってしまうため、予め加速度パターン/減速度パターンをASICに設定するために時間がかかってしまうという問題がある。   On the other hand, when controlling the speed of a phase excitation type motor, it is also possible to perform speed control using an acceleration / deceleration table storing acceleration patterns / deceleration patterns for controlling acceleration / deceleration of the motor. However, when the acceleration / deceleration table is used, the table length becomes very long, and there is a problem that it takes time to set the acceleration pattern / deceleration pattern in the ASIC in advance.

本発明の目的は、相励磁方式のモータの等速回転時の速度変更を行う場合にCPU資源が不足する問題や、単に加減速テーブルを用いてモータ速度制御を行う場合の処理時間がかかる問題を解消することを可能としたモータ制御装置及びその制御方法を提供することにある。   It is an object of the present invention to have a problem that CPU resources are insufficient when changing the speed of a phase excitation motor at a constant speed, or a problem that takes a long processing time when motor speed control is simply performed using an acceleration / deceleration table. It is an object of the present invention to provide a motor control device and a control method thereof that can eliminate the above-described problem.

上述の目的を達成するために、本発明のモータ制御装置は、相励磁方式のモータを駆動制御するモータ制御装置であって、クロックを発生する発生手段と、前記モータ制御装置外部から入力されるクロックを受信する受信手段と、前記モータの制御目標状態に応じて、前記発生手段により発生したクロックと前記受信手段により受信したクロックとを選択的に切り換える選択手段と、前記選択手段により選択されたクロックに同期させながら相励磁パターンに対応した相励磁信号を前記モータに出力する出力手段とを備えることを特徴とする。   In order to achieve the above-described object, a motor control device of the present invention is a motor control device that controls driving of a phase excitation type motor, and is generated from a generating means for generating a clock, and from outside the motor control device. A receiving means for receiving a clock; a selecting means for selectively switching between a clock generated by the generating means and a clock received by the receiving means in accordance with a control target state of the motor; and the selection means selected by the selecting means Output means for outputting a phase excitation signal corresponding to a phase excitation pattern to the motor while synchronizing with a clock.

上述の目的を達成するために、本発明のモータ制御装置は、相励磁方式のモータを駆動制御するモータ制御装置であって、相励磁パターンを供給する内部供給手段と、前記モータ制御装置外部から入力される相励磁パターンを供給する外部供給手段と、前記モータの制御目標状態に応じて、前記内部供給手段により供給される相励磁パターンと前記外部供給手段により供給される相励磁パターンとを選択的に切り換える選択手段と、前記選択手段により選択された相励磁パターンに対応した相励磁信号を前記モータに出力する出力手段とを備えることを特徴とする。   In order to achieve the above-described object, a motor control device of the present invention is a motor control device that drives and controls a phase excitation type motor, and includes an internal supply means for supplying a phase excitation pattern, and an outside of the motor control device. The external supply means for supplying the input phase excitation pattern, and the phase excitation pattern supplied by the internal supply means and the phase excitation pattern supplied by the external supply means are selected according to the control target state of the motor Selection means for switching automatically, and output means for outputting to the motor a phase excitation signal corresponding to the phase excitation pattern selected by the selection means.

本発明によれば、相励磁方式のモータの制御目標に応じて、モータ制御装置内部で発生したクロックとモータ制御装置外部から受信したクロックとを選択的に切り換え、選択されたクロックに同期させながら相励磁パターンに対応した相励磁信号をモータに出力する。これにより、モータの制御目標(加速制御、等速制御、減速制御)に応じて、モータを制御する制御主体(モータ制御装置、モータ制御装置外部の装置)を自由に切り換えることが可能となる。その結果、従来の、モータの等速回転時の速度変更を行う場合にCPU資源が不足する問題や、単に加減速テーブルを用いてモータ速度制御を行う場合の処理時間がかかる問題を解消することができる。   According to the present invention, the clock generated inside the motor control device and the clock received from the outside of the motor control device are selectively switched according to the control target of the phase excitation motor, and synchronized with the selected clock. A phase excitation signal corresponding to the phase excitation pattern is output to the motor. This makes it possible to freely switch the control subject (motor control device, device outside the motor control device) that controls the motor in accordance with the motor control target (acceleration control, constant speed control, deceleration control). As a result, it is possible to solve the conventional problem that the CPU resource is insufficient when changing the speed at the constant speed of the motor, and the processing time when the motor speed control is simply performed using the acceleration / deceleration table. Can do.

以下、本発明の実施の形態を図面に基づき説明する。   Hereinafter, embodiments of the present invention will be described with reference to the drawings.

[第1の実施の形態]
図1は、本発明の第1の実施の形態に係る画像形成装置の内部構造を示す構成図である。
[First Embodiment]
FIG. 1 is a block diagram showing the internal structure of the image forming apparatus according to the first embodiment of the present invention.

図1において、画像形成装置は、デジタル複写機として構成されており、自動原稿送り装置10、本体画像入力部11、本体画像出力部12、フィニッシャ13を備えている。尚、以下では本発明のモータ制御に直接関係しない個所については説明を簡略化または省略する。   In FIG. 1, the image forming apparatus is configured as a digital copying machine, and includes an automatic document feeder 10, a main body image input unit 11, a main body image output unit 12, and a finisher 13. In the following, description of parts not directly related to the motor control of the present invention will be simplified or omitted.

自動原稿送り装置10は、本体画像入力部11の上部に装着されており、原稿を原稿台上の読取位置に給送する装置である。   The automatic document feeder 10 is mounted on the upper part of the main body image input unit 11 and feeds a document to a reading position on a document table.

本体画像入力部11は、原稿から画像を読み取る機構である。光源21は、光学系モータ(不図示)の駆動力で図1の左右方向に往復動作し、原稿台上の原稿を照明しながら走査する。原稿からの反射光(光学像)は、光源21と一体的に駆動されるミラー22、23、24及びレンズ25を介してCCD26に結像される。CCD26は、光学像を電気信号に変換する。電気信号は、更にデジタル信号(画像データ)に変換される。画像データは、種々の補正処理と画像処理が施され、画像メモリ(不図示)に蓄積され、本体画像出力部11に転送される。   The main body image input unit 11 is a mechanism for reading an image from a document. The light source 21 reciprocates in the left-right direction in FIG. 1 by the driving force of an optical system motor (not shown), and scans while illuminating the document on the document table. Reflected light (optical image) from the original is imaged on the CCD 26 through mirrors 22, 23, 24 and a lens 25 that are driven integrally with the light source 21. The CCD 26 converts the optical image into an electric signal. The electrical signal is further converted into a digital signal (image data). The image data is subjected to various correction processes and image processes, stored in an image memory (not shown), and transferred to the main body image output unit 11.

本体画像出力部12は、原稿の読取画像を記録紙に形成し出力する機構である。本体画像出力部11から転送された画像データは、デジタル信号からアナログ信号に再変換され、更に露光制御部(不図示)により適正な出力値に増幅され、光学照射部27により光信号に変換される。光信号は、スキャナ28、レンズ29及びミラー30を伝播して、感光ドラム31上に照射され、静電潜像が形成される。静電潜像は、トナーにより現像され、搬送されてくる記録紙上にトナー像が転写され、更に定着ローラ32によりトナー像が定着されることで画像形成される。画像形成後の記録紙は、フィニッシャ13に送出される。   The main body image output unit 12 is a mechanism for forming and outputting a read image of a document on a recording sheet. The image data transferred from the main body image output unit 11 is converted again from a digital signal to an analog signal, further amplified to an appropriate output value by an exposure control unit (not shown), and converted to an optical signal by the optical irradiation unit 27. The The optical signal propagates through the scanner 28, the lens 29, and the mirror 30 and is irradiated onto the photosensitive drum 31 to form an electrostatic latent image. The electrostatic latent image is developed with toner, and the toner image is transferred onto the conveyed recording paper. Further, the toner image is fixed by the fixing roller 32, thereby forming an image. The recording paper after the image formation is sent to the finisher 13.

給紙トレイ34、35、給紙デッキ36は、複数枚の記録紙を収納可能である。手差しトレイ37からは、任意種類の記録紙(OHPシート等の特殊紙を含む)を給紙可能である。給紙ローラ38、39、40、41、42は、記録紙を搬送するローラであり、駆動源としてのステッピングモータに歯車等の伝達機構を介して接続されている。   The paper feed trays 34 and 35 and the paper feed deck 36 can store a plurality of recording sheets. Any type of recording paper (including special paper such as an OHP sheet) can be fed from the manual feed tray 37. The paper feed rollers 38, 39, 40, 41, and 42 are rollers for transporting the recording paper, and are connected to a stepping motor as a drive source via a transmission mechanism such as a gear.

ここで、ステッピングモータにより駆動される感光ドラム31と定着ローラ32の回転速度は、プロセス速度と呼ばれる。プロセス速度は、トナーの粒子形状、トナーの定着特性、レーザの発光特性などに大きく左右され、個々の画像形成装置に特有の速度となっているので可変制御することは困難である。従って、画像形成装置では、厚紙を搬送するのに十二分なトルクを出力できるステッピングモータが選択されている。   Here, the rotational speed of the photosensitive drum 31 and the fixing roller 32 driven by the stepping motor is called a process speed. The process speed greatly depends on the toner particle shape, toner fixing characteristics, laser emission characteristics, and the like, and is a speed specific to each image forming apparatus, so that it is difficult to variably control the process speed. Therefore, in the image forming apparatus, a stepping motor that can output a torque sufficient for conveying thick paper is selected.

他方、給紙ローラ38、39、40、41、42や搬送ローラは、記録紙の給紙や搬送のみを行っている。従って、感光ドラム31、定着ローラ32の何れかに記録紙が挟まっていない場合は、給紙ローラ38、39、40、41、42や搬送ローラをできるだけ高速に駆動し、記録紙間の距離をできるだけ短く制御する。これにより、画像形成装置としてのプロダクティビティを向上可能としている。   On the other hand, the paper feed rollers 38, 39, 40, 41, 42 and the transport rollers only feed and transport the recording paper. Therefore, when the recording paper is not sandwiched between the photosensitive drum 31 and the fixing roller 32, the paper feed rollers 38, 39, 40, 41, 42 and the conveying roller are driven as fast as possible to reduce the distance between the recording papers. Control as short as possible. As a result, the productivity as an image forming apparatus can be improved.

フィニッシャ13は、本体画像出力部12に付設されており、本体画像出力部12から送出された記録紙を制御部が指示した排紙トレイ33に仕分ける装置である。   The finisher 13 is an apparatus attached to the main body image output unit 12 and sorts the recording paper sent from the main body image output unit 12 into the paper discharge tray 33 instructed by the control unit.

図2は、図1に示した画像形成装置の制御系の構成を示すブロック図である。   FIG. 2 is a block diagram showing the configuration of the control system of the image forming apparatus shown in FIG.

図2において、画像形成装置の制御系は、CPU200、ROM201、RAM202、ASIC203、データバス/アドレスバス207から構成されている。CPU200は、クロック発振器210、通信制御部(データ送受信部)211を備えている。ASIC203は、クロック受信器220、クロック発振器221、制御部223、ポートレジスタ224、ROM225、RAM226を備えている。   In FIG. 2, the control system of the image forming apparatus includes a CPU 200, a ROM 201, a RAM 202, an ASIC 203, and a data bus / address bus 207. The CPU 200 includes a clock oscillator 210 and a communication control unit (data transmission / reception unit) 211. The ASIC 203 includes a clock receiver 220, a clock oscillator 221, a control unit 223, a port register 224, a ROM 225, and a RAM 226.

CPU200は、画像形成装置の制御を司る中央演算処理装置である。CPU200のクロック発振器210とASIC203のクロック受信器220との間には、クロック信号線205が接続されている。クロック信号線205は、クロック発振器210で発生したクロックをASIC203へ送信する信号線である。CPU200の通信制御部211とASIC203の制御部223との間には、通信信号線206−1及び206−2が接続されている。通信信号線206−1は、CPU200からASIC203へデータを送信する信号線である。通信信号線206−2は、ASIC203からCPU200へデータを送信する信号線である。   The CPU 200 is a central processing unit that controls the image forming apparatus. A clock signal line 205 is connected between the clock oscillator 210 of the CPU 200 and the clock receiver 220 of the ASIC 203. The clock signal line 205 is a signal line for transmitting the clock generated by the clock oscillator 210 to the ASIC 203. Communication signal lines 206-1 and 206-2 are connected between the communication control unit 211 of the CPU 200 and the control unit 223 of the ASIC 203. Communication signal line 206-1 is a signal line for transmitting data from CPU 200 to ASIC 203. The communication signal line 206-2 is a signal line for transmitting data from the ASIC 203 to the CPU 200.

クロック発振器210は、任意周期のクロックを発生する。通信制御部211は、ASIC203との間で通信を行う。ROM201は、画像形成装置の制御に用いるプログラム、ASIC203との通信を行うプログラム、クロック発振器210を制御するプログラムを格納している。RAM202は、CPU200により作業領域や一時記憶領域に使用される。本構成では、ROM201とRAM202をCPU200の外部に配設しているが、CPU200に内蔵してもよい。   The clock oscillator 210 generates a clock having an arbitrary period. The communication control unit 211 performs communication with the ASIC 203. The ROM 201 stores a program used for controlling the image forming apparatus, a program for communicating with the ASIC 203, and a program for controlling the clock oscillator 210. The RAM 202 is used by the CPU 200 as a work area and a temporary storage area. In this configuration, the ROM 201 and the RAM 202 are disposed outside the CPU 200, but may be built in the CPU 200.

ステッピングモータ204は、画像形成装置の機構を駆動する駆動源である。尚、図2ではステッピングモータを1つしか図示していないが、画像形成装置には、上記の感光ドラム31、定着ローラ32、他の機構をそれぞれ駆動する複数のステッピングモータが装備されている。また、図2ではセンサなどは図示していない。   The stepping motor 204 is a drive source that drives the mechanism of the image forming apparatus. Although only one stepping motor is shown in FIG. 2, the image forming apparatus is equipped with a plurality of stepping motors that respectively drive the photosensitive drum 31, the fixing roller 32, and other mechanisms. Further, in FIG. 2, sensors and the like are not shown.

ASIC203は、ステッピングモータ204を駆動する制御回路である。クロック受信器220は、CPU200のクロック発振器210が発生するクロックをクロック信号線205を介して受信する。クロック発振器221は、ASIC203内部で任意周期のクロックを発生する。クロック発振器221は、制御部223内部のタイマ(不図示)を動作させることで発振を行うことができる。   The ASIC 203 is a control circuit that drives the stepping motor 204. The clock receiver 220 receives a clock generated by the clock oscillator 210 of the CPU 200 via the clock signal line 205. The clock oscillator 221 generates a clock having an arbitrary period inside the ASIC 203. The clock oscillator 221 can oscillate by operating a timer (not shown) in the control unit 223.

制御部223は、ASIC203の制御を司るものであり、ROM225及びRAM226を用いて、ASIC203に接続されているステッピングモータ204及びセンサ(不図示)などを制御する。制御部223は、ASIC203内部のクロック発振器221で発生したクロック(内部クロック)と、CPU200のクロック発振器210からクロック信号線205を介して入力されるクロック(外部クロック)とを選択的に切り換える。また、制御部223は、ROM225に格納されたプログラムに基づいて図10乃至図12のフローチャートに示す処理を実行する。   The control unit 223 controls the ASIC 203, and controls the stepping motor 204 and sensors (not shown) connected to the ASIC 203 using the ROM 225 and the RAM 226. The control unit 223 selectively switches between a clock (internal clock) generated by the clock oscillator 221 inside the ASIC 203 and a clock (external clock) input from the clock oscillator 210 of the CPU 200 via the clock signal line 205. Further, the control unit 223 executes processing shown in the flowcharts of FIGS. 10 to 12 based on a program stored in the ROM 225.

ROM225は、ステッピングモータ204を駆動するための複数の相励磁パターンと、ステッピングモータ204を加速/減速するための複数の加速パターン/減速パターンを格納している。RAM226は、制御部223により作業領域や一時記憶領域に使用される。尚、ROM225に格納される相励磁パターンは、ASIC203の外部から設定変更することが可能である。   The ROM 225 stores a plurality of phase excitation patterns for driving the stepping motor 204 and a plurality of acceleration patterns / deceleration patterns for accelerating / decelerating the stepping motor 204. The RAM 226 is used by the control unit 223 for a work area and a temporary storage area. The phase excitation pattern stored in the ROM 225 can be set and changed from outside the ASIC 203.

ポートレジスタ224とステッピングモータ204との間には、4本の信号線230、231、232、233が接続されている。ポートレジスタ224は、制御部223によりROM225から読み出されポートレジスタ224に出力された相励磁パターンに対応した相励磁信号を、信号線230、231、232、233を介してステッピングモータ204に出力する。   Four signal lines 230, 231, 232, and 233 are connected between the port register 224 and the stepping motor 204. The port register 224 outputs a phase excitation signal corresponding to the phase excitation pattern read from the ROM 225 by the control unit 223 and output to the port register 224 to the stepping motor 204 via the signal lines 230, 231, 232, and 233. .

図3は、ステッピングモータ204の駆動方法を示すタイミングチャートである。   FIG. 3 is a timing chart showing a method for driving the stepping motor 204.

図3において、「クロック」は、CPU200のクロック発振器210からクロック信号線205を介して供給されるクロック(外部クロック)、または、ASIC203内部のクロック発振器221から供給されるクロック(内部クロック)を示している。クロックの供給に伴い、信号線230、231、232、233には、ポートレジスタ224から図示の相励磁信号がクロックに同期するように出力される。ステッピングモータ204は、信号線230、231、232、233を介して所定の相励磁パターンの並びを順に入力することで回転させることができる。   In FIG. 3, “clock” indicates a clock (external clock) supplied from the clock oscillator 210 of the CPU 200 via the clock signal line 205 or a clock (internal clock) supplied from the clock oscillator 221 inside the ASIC 203. ing. With the supply of the clock, the illustrated phase excitation signal is output from the port register 224 to the signal lines 230, 231, 232, and 233 so as to be synchronized with the clock. The stepping motor 204 can be rotated by sequentially inputting a sequence of predetermined phase excitation patterns via the signal lines 230, 231, 232, and 233.

ポートレジスタ224から信号線230、231、232、233に出力される図示の相励磁信号は、ステッピングモータ204の2相励磁のときの相励磁パターンを示している。信号線230〜233を、それぞれ、bit0〜bit3と表記すると、
相励磁パターンの組合せ(bit3、bit2、bit1、bit0)
={(0,1,0,1)→(1,0,0,1)→(1,0,1,0)→(0,1,1,0)} :正転
={(0,1,0,1)→(0,1,1,0)→(1,0,1,0)→(1,0,0,1)} :逆転
のようになる。相励磁パターンを4ビットのデータとみなせば、相励磁パターンは、ステッピングモータ204の正転時は「5→9→A→6」のようなデータの並び、ステッピングモータ204の逆転時は「5→6→A→9」のようなデータの並びと考えることができる。尚、データは16進数による表記である。
The illustrated phase excitation signals output from the port register 224 to the signal lines 230, 231, 232, and 233 indicate phase excitation patterns when the stepping motor 204 is in two-phase excitation. When the signal lines 230 to 233 are expressed as bit0 to bit3, respectively,
Combination of phase excitation patterns (bit3, bit2, bit1, bit0)
= {(0,1,0,1) → (1,0,0,1) → (1,0,1,0) → (0,1,1,0)}: Forward rotation = {(0, 1,0,1) → (0,1,1,0) → (1,0,1,0) → (1,0,0,1)}: It looks like reverse. If the phase excitation pattern is regarded as 4-bit data, the phase excitation pattern is arranged with data such as “5 → 9 → A → 6” at the time of forward rotation of the stepping motor 204 and “5” at the time of reverse rotation of the stepping motor 204. It can be thought of as an array of data such as “→ 6 → A → 9”. The data is expressed in hexadecimal.

次に、上記構成を有する本実施の形態の画像形成装置において、ステッピングモータ204の加速及び減速についてはASIC203で制御し、ステッピングモータ204の等速域の速度及び進み量制御についてはCPU200で制御する例を、図4〜図12を参照しながら詳細に説明する。   Next, in the image forming apparatus of the present embodiment having the above-described configuration, acceleration and deceleration of the stepping motor 204 are controlled by the ASIC 203, and speed and advance amount control of the stepping motor 204 are controlled by the CPU 200. Examples will be described in detail with reference to FIGS.

図4(a)は、ステッピングモータ204の加速区間/等速区間/減速区間の速度変化を示す図、図4(b)、図4(c)は、CPU及びASIC間の通信信号線206−1、206−2上を流れるデータとクロック信号線205の関係を示す図である。   4A is a diagram showing the speed change of the acceleration section / constant speed section / deceleration section of the stepping motor 204, and FIGS. 4B and 4C are communication signal lines 206- between the CPU and the ASIC. 1 is a diagram illustrating a relationship between data flowing on 1 and 206-2 and a clock signal line 205. FIG.

図4(a)において、横軸は時間を表し、縦軸はステッピングモータ204の速度(回転数)を表している。本実施の形態では、ステッピングモータ204を加速してから一定期間等速(変速してもよい)で駆動した後、減速して停止させるような場合を示している。図4(b)、図4(c)において、横軸は図4(a)に示した時間と共通な時間を示している。   In FIG. 4A, the horizontal axis represents time, and the vertical axis represents the speed (number of rotations) of the stepping motor 204. In the present embodiment, the stepping motor 204 is accelerated and driven at a constant speed (may be changed) after being accelerated, and then decelerated and stopped. In FIG. 4B and FIG. 4C, the horizontal axis indicates the time common to the time shown in FIG.

ステッピングモータ204を起動する場合、図4(a)の横軸の0点よりも前に、CPU200とASIC203との間で通信データA及びBがやり取りされる。通信データA及びBの内容については後述する。通信データA及びBがやり取りされた後、CPU200は、クロック信号線205を所定時間有効にする。このとき、ASIC203の制御部223は、クロック信号線205から供給されるクロックがHighからLowに変化するタイミングを検出し、検出タイミングに同期させて、ASIC203内部のクロック発振器221で発生したクロック(内部クロック)を使用してステッピングモータ204の加速制御を行う。   When the stepping motor 204 is started, communication data A and B are exchanged between the CPU 200 and the ASIC 203 before the zero point on the horizontal axis in FIG. The contents of the communication data A and B will be described later. After the communication data A and B are exchanged, the CPU 200 enables the clock signal line 205 for a predetermined time. At this time, the control unit 223 of the ASIC 203 detects the timing at which the clock supplied from the clock signal line 205 changes from High to Low, and synchronizes with the detection timing to generate a clock (internally generated by the clock oscillator 221 inside the ASIC 203. The stepping motor 204 is accelerated using a clock.

その後、ステッピングモータ204が等速区間になると、ASIC203の制御部223は、クロック発振器221で発生したクロックを使用したステッピングモータ204の加速制御を終了し、CPU200のクロック発振器210からクロック信号線205を介して入力されるクロック(外部クロック)に同期させながら、ASIC203内部のROM225に記憶されている相励磁パターンをポートレジスタ224へ転送する。   Thereafter, when the stepping motor 204 enters the constant speed section, the control unit 223 of the ASIC 203 ends the acceleration control of the stepping motor 204 using the clock generated by the clock oscillator 221, and connects the clock signal line 205 from the clock oscillator 210 of the CPU 200. The phase excitation pattern stored in the ROM 225 in the ASIC 203 is transferred to the port register 224 while synchronizing with the clock (external clock) input via the port 224.

CPU200は、ステッピングモータ204を停止するときは、図4(b)のデータCを通信信号線206−1を介してASIC203に送出する。ASIC203の制御部223は、CPU200からデータCを受信したときに、ステッピングモータ204の減速制御を開始する。ASIC203の制御部223は、ASIC203内部のクロック発振器221を再起動し、クロック発振器221で発生したクロック(内部クロック)に同期させながら、ROM225に記憶されている相励磁パターンをポートレジスタ224へ転送する。   When stopping the stepping motor 204, the CPU 200 sends the data C in FIG. 4B to the ASIC 203 via the communication signal line 206-1. When the control unit 223 of the ASIC 203 receives the data C from the CPU 200, it starts deceleration control of the stepping motor 204. The control unit 223 of the ASIC 203 restarts the clock oscillator 221 inside the ASIC 203 and transfers the phase excitation pattern stored in the ROM 225 to the port register 224 while synchronizing with the clock (internal clock) generated by the clock oscillator 221. .

図4(b)及び図4(c)における、通信データAはステッピングモータ起動コマンド、通信データBはステッピングモータ起動応答コマンド、データCはステッピングモータ停止コマンド、データDはステッピングモータ停止応答コマンドである。ステッピングモータ起動コマンド、ステッピングモータ停止コマンド等については下記で詳述する。   4B and 4C, communication data A is a stepping motor start command, communication data B is a stepping motor start response command, data C is a stepping motor stop command, and data D is a stepping motor stop response command. . The stepping motor start command, stepping motor stop command, etc. will be described in detail below.

図4(b)に示す例(内部クロック/外部クロックの出力パターン1)では、ステッピングモータ204の加速区間及び減速区間は、ASIC203のクロック発振器221から供給されるクロック(内部クロック)に同期させて相励磁パターンに対応した相励磁信号をステッピングモータ204に出力し、ステッピングモータ204の等速区間は、CPU200のクロック発振器210から供給されるクロック(外部クロック)に同期させて相励磁パターンに対応した相励磁信号をステッピングモータ204に出力する。   In the example shown in FIG. 4B (internal clock / external clock output pattern 1), the acceleration interval and deceleration interval of the stepping motor 204 are synchronized with the clock (internal clock) supplied from the clock oscillator 221 of the ASIC 203. A phase excitation signal corresponding to the phase excitation pattern is output to the stepping motor 204, and the constant speed section of the stepping motor 204 corresponds to the phase excitation pattern in synchronization with a clock (external clock) supplied from the clock oscillator 210 of the CPU 200. A phase excitation signal is output to the stepping motor 204.

図4(c)に示す例(内部クロック/外部クロックの出力パターン2)では、ステッピングモータ204の加速区間及び減速区間は、CPU200のクロック発振器210から供給されるクロック(外部クロック)に同期させて相励磁パターンに対応した相励磁信号をステッピングモータ204に出力し、ステッピングモータ204の等速区間は、ASIC203のクロック発振器221から供給されるクロック(内部クロック)に同期させて相励磁パターンに対応した相励磁信号をステッピングモータ204に出力する。   In the example shown in FIG. 4C (internal clock / external clock output pattern 2), the acceleration interval and deceleration interval of the stepping motor 204 are synchronized with the clock (external clock) supplied from the clock oscillator 210 of the CPU 200. A phase excitation signal corresponding to the phase excitation pattern is output to the stepping motor 204, and the constant velocity section of the stepping motor 204 corresponds to the phase excitation pattern in synchronization with the clock (internal clock) supplied from the clock oscillator 221 of the ASIC 203. A phase excitation signal is output to the stepping motor 204.

図5は、ASIC203の制御部223がステッピングモータ204を制御するのに必要な構成を示す図である。   FIG. 5 is a diagram illustrating a configuration necessary for the control unit 223 of the ASIC 203 to control the stepping motor 204.

図5において、タイマカウンタ401とタイマレジスタ402は、ASIC203内部のタイマ(不図示)を制御するためのものである。タイマカウンタ401の値とタイマレジスタ402の値が一致したときに、ASIC203内部のクロック発振器221がパルス状のクロックを出力することができる。   In FIG. 5, a timer counter 401 and a timer register 402 are for controlling a timer (not shown) in the ASIC 203. When the value of the timer counter 401 matches the value of the timer register 402, the clock oscillator 221 in the ASIC 203 can output a pulsed clock.

加速/減速テーブル403、シーケンステーブル404、相励磁パターンテーブル408は、ROM225に格納されており、必要に応じてROM225からRAM226上に読み込まれ参照される。   The acceleration / deceleration table 403, the sequence table 404, and the phase excitation pattern table 408 are stored in the ROM 225, and are read from the ROM 225 onto the RAM 226 and referred to as necessary.

加速/減速テーブル403は、ステッピングモータ204の加速制御/減速制御を行うためのテーブルであり、複数のテーブル(テーブル1、テーブル2、テーブル3)を備えている。テーブル1、テーブル2、テーブル3は、それぞれ、加速テーブルと減速テーブルから構成されている。   The acceleration / deceleration table 403 is a table for performing acceleration control / deceleration control of the stepping motor 204, and includes a plurality of tables (table 1, table 2, table 3). Table 1, table 2, and table 3 are each composed of an acceleration table and a deceleration table.

シーケンステーブル404は、加速/減速テーブル403のテーブル(テーブル1、テーブル2・・・)毎の相励磁パターンのステップ数と、外部クロック(CPU200のクロック発振器210からASIC203に供給されるクロック)のステップ数(クロック数)を記憶するテーブルである。   The sequence table 404 includes steps of the phase excitation pattern for each table (table 1, table 2,...) Of the acceleration / deceleration table 403 and steps of an external clock (clock supplied from the clock oscillator 210 of the CPU 200 to the ASIC 203). It is a table which memorize | stores a number (clock number).

相励磁パターンテーブル408は、ステッピングモータ204の相励磁を行うための複数の相励磁パターンを個々のアドレスに対応付けて記憶している。相励磁パターンテーブル408においてどのアドレスの相励磁パターンまでポートレジスタ405(図2の224に対応)に出力したかは、ASIC203の制御部223が周回型ポインタの出力ポインタ409により把握することができる。   The phase excitation pattern table 408 stores a plurality of phase excitation patterns for performing phase excitation of the stepping motor 204 in association with individual addresses. The address excitation pattern of the phase excitation pattern table 408 up to which phase excitation pattern is output to the port register 405 (corresponding to 224 in FIG. 2) can be grasped by the output pointer 409 of the circular pointer by the control unit 223 of the ASIC 203.

ポートレジスタ405は、該ポートレジスタ内に相励磁パターンが書き込まれると、信号線230、231、232、233に対し相励磁パターンに対応した相励磁信号を送出する。   When the phase excitation pattern is written in the port register, the port register 405 transmits a phase excitation signal corresponding to the phase excitation pattern to the signal lines 230, 231, 232, and 233.

ステップ数カウンタ406は、ASIC203からステッピングモータ204に出力した相励磁パターン(相励磁パターンに対応した相励磁信号)の数を計数する。   The step number counter 406 counts the number of phase excitation patterns (phase excitation signals corresponding to the phase excitation patterns) output from the ASIC 203 to the stepping motor 204.

ステップ数設定用レジスタ407は、ステッピングモータ204を加速するために必要なクロック数(加速ステップ数)が設定される加速ステップ数レジスタ、ステッピングモータ204を等速で駆動するために必要なクロック数(等速ステップ数)が設定される等速ステップ数レジスタ、ステッピングモータ204を減速して停止させるために必要なクロック数(減速ステップ数)が設定される減速ステップ数レジスタを備えている。   The step number setting register 407 is an acceleration step number register in which the number of clocks (acceleration step number) necessary for accelerating the stepping motor 204 is set, and the number of clocks necessary for driving the stepping motor 204 at a constant speed ( A constant speed step number register in which a constant speed step number) is set, and a deceleration step number register in which the number of clocks (deceleration step number) necessary to decelerate and stop the stepping motor 204 is provided.

上記のステップ数カウンタ406、ステップ数設定用レジスタ407は、ASIC203がステッピングモータ204の制御を加速/等速/減速と切り換えるためのタイミングを計測するためのものである。   The step number counter 406 and the step number setting register 407 are for measuring the timing at which the ASIC 203 switches the control of the stepping motor 204 between acceleration / constant speed / deceleration.

尚、加速/減速テーブル403、ステップ数設定用レジスタ407、及び相励磁パターンテーブル408は、ASIC203が複数備える構成としてもよいし、CPU200から通信信号線206−1、206−2を介した通信により変更可能な構成としてもよい。   The ASIC 203 may have a plurality of the acceleration / deceleration table 403, the step number setting register 407, and the phase excitation pattern table 408, or may be communicated from the CPU 200 via the communication signal lines 206-1 and 206-2. It is good also as a structure which can be changed.

図6は、CPU200及びASIC203間の送受信データの基本的な構造を示す図である。   FIG. 6 is a diagram showing a basic structure of transmission / reception data between the CPU 200 and the ASIC 203.

図6において、図示のブロックは、CPU200及びASIC203間において通信信号線206−1、206−2上をコマンド単位でやり取りされるデータの構造を示している。データの先頭はヘッダと呼ばれる2バイトのデータであり、コマンドの種類を区別するためのデータである。ヘッダに続いて、データ長と呼ばれる2バイトのデータが並んでいる。データ長は、ヘッダとデータ長自身と後述するSUMとを除いたデータ(データ1〜データN)の長さを示している。   In FIG. 6, the illustrated block shows the structure of data exchanged in units of commands on the communication signal lines 206-1 and 206-2 between the CPU 200 and the ASIC 203. The head of the data is 2-byte data called a header, and is data for distinguishing the type of command. Following the header, 2-byte data called data length is arranged. The data length indicates the length of data (data 1 to data N) excluding the header, the data length itself, and SUM described later.

データ長に続いて、データ1〜データNまでのNバイト(各1バイト)のデータが並んでいる。データ1〜Nの後には、SUMと呼ばれるデータが並んでいる。SUMは、データ受信側(CPU200からASIC203にデータを送信する場合はASIC203、ASIC203からCPU200にデータを送信する場合はCPU200)が正しくデータを受信したかどうかを確認するための1バイトのデータである。ヘッダからデータNまでの各データの総和を計算し、最下位1バイトのデータをSUMに設定する。   Following the data length, N bytes (1 byte each) of data 1 to data N are arranged. After the data 1 to N, data called SUM is arranged. The SUM is 1-byte data for confirming whether the data receiving side (the ASIC 203 when transmitting data from the CPU 200 to the ASIC 203, or the CPU 200 when transmitting data from the ASIC 203 to the CPU 200) correctly receives the data. . The sum of each data from the header to the data N is calculated, and the data of the lowest 1 byte is set in the SUM.

図7は、ステッピングモータ204を起動するためのステッピングモータ起動コマンド及びステッピングモータ起動応答コマンドを示す図である。   FIG. 7 is a diagram showing a stepping motor start command and a stepping motor start response command for starting the stepping motor 204.

図7において、図示のブロックは、ステッピングモータ起動コマンドと、ステッピングモータ起動応答コマンドを示しており、ステッピングモータ204の制御を行うためのコマンドである。ステッピングモータ起動コマンドは、ヘッダ上位、ヘッダ下位、データ長上位、データ長下位、モータ番号、シーケンス番号、SUMから構成されている。ステッピングモータ起動応答コマンドは、ヘッダ上位、ヘッダ下位、データ長上位、データ長下位、結果、SUMから構成されている。   In FIG. 7, the illustrated block indicates a stepping motor start command and a stepping motor start response command, and is a command for controlling the stepping motor 204. The stepping motor start command is composed of an upper header, lower header, upper data length, lower data length, motor number, sequence number, and SUM. The stepping motor activation response command is composed of an upper header, lower header, upper data length, lower data length, result, and SUM.

上記図4に示した通信データAはステッピングモータ起動コマンドであり、通信データBはステッピングモータ起動応答コマンドである。ステッピングモータ204を起動する場合、起動前に必ずCPU及びASIC間でステッピングモータ起動コマンドとステッピングモータ起動応答コマンドのやり取りを行う。これは、クロック信号線205にノイズが乗った場合の誤動作対策である。CPU200からステッピングモータ起動コマンドを受信していない間、ASIC203の制御部223はステッピングモータ204を動作させないように制御する。   The communication data A shown in FIG. 4 is a stepping motor start command, and the communication data B is a stepping motor start response command. When the stepping motor 204 is activated, a stepping motor activation command and a stepping motor activation response command are always exchanged between the CPU and the ASIC before activation. This is a countermeasure against malfunction when noise is applied to the clock signal line 205. While the stepping motor activation command is not received from the CPU 200, the control unit 223 of the ASIC 203 performs control so that the stepping motor 204 is not operated.

図8は、ステッピングモータ204を停止させるためのステッピングモータ停止コマンド及びステッピングモータ停止応答コマンドを示す図である。   FIG. 8 is a diagram showing a stepping motor stop command and a stepping motor stop response command for stopping the stepping motor 204.

図8において、図示のブロックは、ステッピングモータ停止コマンドと、ステッピングモータ停止応答コマンドを示しており、ステッピングモータ204の制御を行うためのコマンドである。ステッピングモータ停止コマンドは、ヘッダ上位、ヘッダ下位、データ長上位、データ長下位、モータ番号、SUMから構成されている。ステッピングモータ停止応答コマンドは、ヘッダ上位、ヘッダ下位、データ長上位、データ長下位、結果、SUMから構成されている。   In FIG. 8, the illustrated block indicates a stepping motor stop command and a stepping motor stop response command, and is a command for controlling the stepping motor 204. The stepping motor stop command is composed of an upper header, lower header, upper data length, lower data length, motor number, and SUM. The stepping motor stop response command is composed of an upper header, lower header, upper data length, lower data length, result, and SUM.

通常、ASIC203の制御部223は、ステップ数設定用レジスタ407内の加速ステップ数レジスタ、等速ステップ数レジスタ、減速ステップ数レジスタにそれぞれ設定されたカウンタ値に従ってステッピングモータ204を制御する。しかし、緊急にステッピングモータ204を停止させたい場合には、ステッピングモータ停止コマンドとステッピングモータ停止応答コマンドを用いる。   Normally, the control unit 223 of the ASIC 203 controls the stepping motor 204 according to the counter values set in the acceleration step number register, the constant speed step number register, and the deceleration step number register in the step number setting register 407, respectively. However, when it is desired to stop the stepping motor 204 urgently, a stepping motor stop command and a stepping motor stop response command are used.

図9は、ステッピングモータ204のモータシーケンス設定コマンド及びモータシーケンス設定応答コマンドを示す図である。   FIG. 9 is a diagram showing a motor sequence setting command and a motor sequence setting response command of the stepping motor 204.

図9において、図示のブロックは、モータシーケンス設定コマンドと、モータシーケンス設定応答コマンドを示している。ステッピングモータ設定コマンドは、ヘッダ上位、ヘッダ下位、データ長、モータ番号、シーケンス番号、加減速状態、クロックトリガ、ステップ数、周波数、・・・加減速状態、クロックトリガ、ステップ数、周波数、#3から構成されている。ステッピングモータ設定応答コマンドは、ヘッダ上位、ヘッダ下位、データ長上位、データ長下位、モータ番号、設定結果、SUMから構成されている。   In FIG. 9, the illustrated block indicates a motor sequence setting command and a motor sequence setting response command. Stepping motor setting commands are: header high, header low, data length, motor number, sequence number, acceleration / deceleration state, clock trigger, step number, frequency, ... acceleration / deceleration state, clock trigger, step number, frequency, # 3 It is composed of The stepping motor setting response command is composed of an upper header, lower header, upper data length, lower data length, motor number, setting result, and SUM.

尚、ステッピングモータ204の駆動/停止は、上述した通信コマンドを使わずに、ハード信号などで制御できる構成としてもよい。   The driving / stopping of the stepping motor 204 may be controlled by a hardware signal or the like without using the communication command described above.

図10乃至図12は、ASIC203の制御部223によるステッピングモータ204に対するクロック切り換え制御を示すフローチャートである。   10 to 12 are flowcharts showing clock switching control for the stepping motor 204 by the control unit 223 of the ASIC 203.

図10乃至図12において、ステッピングモータ204の起動タイミングになり(ステップS100)、ASIC203の制御部223は、クロック信号線205のクロックのH(High)エッジを検出すると(ステップS101でYES)、次の処理を行う。即ち、ASIC203の制御部223は、ROM225の加速/減速テーブル403における加速テーブルの先頭アドレスをタイマレジスタ402に設定した後、ROM225の相励磁パターンテーブル408の先頭アドレスのデータをRAM226上に保持する出力準備を行い、ステップ数カウンタ406を0にクリアし、ステッピングモータ204の駆動電流値を設定する(ステップS102)。   In FIG. 10 to FIG. 12, it is the start timing of the stepping motor 204 (step S100), and when the control unit 223 of the ASIC 203 detects the H (High) edge of the clock of the clock signal line 205 (YES in step S101), the next step is performed. Perform the process. That is, the control unit 223 of the ASIC 203 sets the start address of the acceleration table in the acceleration / deceleration table 403 of the ROM 225 in the timer register 402, and then outputs the data of the start address of the phase excitation pattern table 408 of the ROM 225 on the RAM 226. Preparation is performed, the step number counter 406 is cleared to 0, and the drive current value of the stepping motor 204 is set (step S102).

次に、ASIC203の制御部223は、クロック信号線205のL(Low)エッジを検出すると(ステップS103でYES)、ASIC内部のクロック発振器221からクロックを入力する内部クロック入力設定となり、タイマ(不図示)をスタートさせる(ステップS104)。ここで、タイマカウンタ401は、ASIC内部のクロック発振器221からのクロック入力に同期して自動的にカウントアップされる。   Next, when the control unit 223 of the ASIC 203 detects the L (Low) edge of the clock signal line 205 (YES in Step S103), the internal clock input setting for inputting the clock from the clock oscillator 221 in the ASIC is performed, and the timer (not set) is set. Is started (step S104). Here, the timer counter 401 is automatically counted up in synchronization with the clock input from the clock oscillator 221 inside the ASIC.

タイマカウンタ401の値がタイマレジスタ402に設定された値と等しくなると(ステップS105でYES)、ASIC203の制御部223は、ROM225からRAM226上に読み込まれている相励磁パターンテーブル408のアドレスが示す領域に記憶されているデータを読み出し、ポートレジスタ405にセットすることで、相励磁パターンを1つ出力する。このとき、ASIC203の制御部223は、ステップ数カウンタ406の値を1増加させる(ステップS106)。   When the value of the timer counter 401 becomes equal to the value set in the timer register 402 (YES in step S105), the control unit 223 of the ASIC 203 indicates the area indicated by the address of the phase excitation pattern table 408 read from the ROM 225 onto the RAM 226. Is read out and set in the port register 405 to output one phase excitation pattern. At this time, the control unit 223 of the ASIC 203 increases the value of the step number counter 406 by 1 (step S106).

次に、ASIC203の制御部223は、ステップ数カウンタ406の計数値(ASIC203から出力した相励磁パターンの数)と、ステップ数設定用レジスタ407内の加速ステップ数レジスタの設定値とを比較する(ステップS107)。前記両者の値が一致していない場合は(ステップS107でNO)、ASIC203の制御部223は、ステッピングモータ204の加速は終了していないと判断し、加速/減速テーブル403における加速テーブルのアドレスと相励磁パターンテーブル408のアドレスを、それぞれ1増加させる(ステップS108)。   Next, the control unit 223 of the ASIC 203 compares the count value of the step number counter 406 (the number of phase excitation patterns output from the ASIC 203) with the set value of the acceleration step number register in the step number setting register 407 ( Step S107). If the values do not match (NO in step S107), the control unit 223 of the ASIC 203 determines that the acceleration of the stepping motor 204 has not ended, and the address of the acceleration table in the acceleration / deceleration table 403 is determined. The address of the phase excitation pattern table 408 is incremented by 1 (step S108).

アドレスを1増加させたとき、相励磁パターンテーブル408のアドレスがn(相励磁パターンテーブル408の最終データのアドレス+1(アドレス超過))であれば(ステップS109でYES)、ASIC203の制御部223は、相励磁パターンテーブル408の参照アドレスを先頭アドレスとし(ステップS110)、再びタイマカウンタ401の値がタイマレジスタ402の値に一致するのを待つ(ステップS105)。相励磁パターンテーブル408のアドレスがn(相励磁パターン最終データのアドレス+1)でなければ(ステップS109でNO)、ASIC203の制御部223は、何もせず、ステップS105へ制御を移す。   When the address is incremented by 1 and the address of the phase excitation pattern table 408 is n (the address of the final data in the phase excitation pattern table 408 + 1 (excess address)) (YES in step S109), the control unit 223 of the ASIC 203 Then, the reference address of the phase excitation pattern table 408 is set as the head address (step S110), and the process waits until the value of the timer counter 401 matches the value of the timer register 402 (step S105). If the address of the phase excitation pattern table 408 is not n (address of the phase excitation pattern final data + 1) (NO in step S109), the control unit 223 of the ASIC 203 does nothing and shifts the control to step S105.

一方、ステップ数カウンタ406の計数値(ASIC203から出力した相励磁パターンの数)と、ステップ数設定用レジスタ407内の加速ステップ数レジスタの設定値とが一致している場合は(ステップS107でYES)、ステッピングモータ204の加速が終了したことになるので、ASIC203の制御部223は、ステッピングモータ204の等速制御に移行する。   On the other hand, if the count value of the step number counter 406 (the number of phase excitation patterns output from the ASIC 203) matches the set value of the acceleration step number register in the step number setting register 407 (YES in step S107). ) Since the acceleration of the stepping motor 204 is completed, the control unit 223 of the ASIC 203 shifts to the constant speed control of the stepping motor 204.

ステッピングモータ204の等速制御では、まず、ASIC203の制御部223は、内部クロック入力(ASIC203のクロック発振器221からのクロック入力)から外部クロック入力(CPU200のクロック発振器210からのクロック入力)の設定に切り換える。そして、ASIC203の制御部223は、ステップ数カウンタ406を0にクリアして、相励磁パターンテーブル408のアドレスを1増加させる(ステップS111)。   In the constant speed control of the stepping motor 204, first, the control unit 223 of the ASIC 203 sets the internal clock input (clock input from the clock oscillator 221 of the ASIC 203) to the external clock input (clock input from the clock oscillator 210 of the CPU 200). Switch. Then, the control unit 223 of the ASIC 203 clears the step number counter 406 to 0 and increments the address of the phase excitation pattern table 408 by 1 (step S111).

次に、ASIC203の制御部223は、CPU200のクロック発振器210からクロック信号線205を介して出力されるクロックのエッジを検出すると(ステップS112でYES)、ステップS111で決定された相励磁パターンテーブル408のアドレスを参照し、該アドレスが示す領域に記憶されている相励磁パターンをポートレジスタ405へ出力し、ステップ数カウンタ406の値を1増加させる(ステップS113)。   Next, when the control unit 223 of the ASIC 203 detects the edge of the clock output from the clock oscillator 210 of the CPU 200 via the clock signal line 205 (YES in step S112), the phase excitation pattern table 408 determined in step S111. The phase excitation pattern stored in the area indicated by the address is output to the port register 405, and the value of the step number counter 406 is incremented by 1 (step S113).

その後、ASIC203の制御部223は、ステップ数カウンタ406の計数値(ASIC203から出力した相励磁パターンの数)と、ステップ数設定用レジスタ407内の等速ステップ数レジスタの設定値とを比較する。このとき、ASIC203の制御部223は、前記両者の値が一致しているかどうか、またはCPU200からステッピングモータ停止コマンド(図8参照)を受信したかどうかを確認する(ステップS114)。前記両者の値が一致していない場合、またはCPU200からステッピングモータ停止コマンドを受信していない場合は(ステップS114でNO)、ASIC203の制御部223は、相励磁パターンテーブル408のアドレスを1増加させる(ステップS115)。   Thereafter, the control unit 223 of the ASIC 203 compares the count value of the step number counter 406 (the number of phase excitation patterns output from the ASIC 203) with the set value of the constant speed step number register in the step number setting register 407. At this time, the control unit 223 of the ASIC 203 checks whether or not the two values match or whether a stepping motor stop command (see FIG. 8) has been received from the CPU 200 (step S114). If the two values do not match or if a stepping motor stop command has not been received from CPU 200 (NO in step S114), control unit 223 of ASIC 203 increments the address of phase excitation pattern table 408 by one. (Step S115).

このとき、相励磁パターンテーブル408のアドレスがn(相励磁パターンテーブル408の最終データのアドレス+1(アドレス超過))であれば(ステップS116でYES)、ASIC203の制御部223は、相励磁パターンテーブル408の参照アドレスを先頭アドレスとし(ステップS117)、再びCPU200のクロック発振器210からクロック信号線205を介して出力されるクロックのエッジ検出を待つ(ステップS112)。相励磁パターンテーブル408のアドレスがn(相励磁パターン最終データのアドレス+1(アドレス超過))でなければ(ステップS116でNO)、ASIC203の制御部223は、何もせず、ステップS112へ制御を移す。   At this time, if the address of the phase excitation pattern table 408 is n (the address of the final data in the phase excitation pattern table 408 + 1 (excess address)) (YES in step S116), the control unit 223 of the ASIC 203 performs the phase excitation pattern table. The reference address 408 is set as the head address (step S117), and the detection of the edge of the clock output from the clock oscillator 210 of the CPU 200 via the clock signal line 205 is awaited again (step S112). If the address of phase excitation pattern table 408 is not n (address of phase excitation pattern final data + 1 (excess address)) (NO in step S116), control unit 223 of ASIC 203 does nothing and shifts control to step S112. .

一方、ステップ数カウンタ406の計数値(ASIC203から出力した相励磁パターンの数)と、ステップ数設定用レジスタ407内の等速ステップ数レジスタの設定値とが一致している場合、または、CPU200からステッピングモータ停止コマンドを受信している場合は(ステップS114でYES)、ステッピングモータ204の等速制御が終了したことになるので、ASIC203の制御部223は、ステッピングモータ204の減速制御に移行する。   On the other hand, when the count value of the step number counter 406 (the number of phase excitation patterns output from the ASIC 203) matches the set value of the constant speed step number register in the step number setting register 407, or from the CPU 200 If the stepping motor stop command has been received (YES in step S114), the constant speed control of the stepping motor 204 has been completed, and the control unit 223 of the ASIC 203 shifts to the deceleration control of the stepping motor 204.

ステッピングモータ204の減速制御では、ASIC203の制御部223は、外部クロック入力(CPU200のクロック発振器210からのクロック入力)の設定から内部クロック入力(ASIC203のクロック発振器221からのクロック入力)の設定に切り換える。そして、ASIC203の制御部223は、加速/減速テーブル403における減速テーブルの先頭アドレスをタイマレジスタ402に設定し、ステップ数カウンタ406を0にクリアし、相励磁パターンテーブル408のアドレスを1増加させ、タイマ(不図示)をスタートさせる。(ステップS118)。   In the deceleration control of the stepping motor 204, the control unit 223 of the ASIC 203 switches from the setting of the external clock input (clock input from the clock oscillator 210 of the CPU 200) to the setting of the internal clock input (clock input from the clock oscillator 221 of the ASIC 203). . Then, the control unit 223 of the ASIC 203 sets the start address of the deceleration table in the acceleration / deceleration table 403 in the timer register 402, clears the step number counter 406 to 0, increments the address of the phase excitation pattern table 408 by 1, A timer (not shown) is started. (Step S118).

タイマカウンタ401の値がタイマレジスタ402の値と一致すると(ステップS119でYES)、ASIC203の制御部223は、相励磁パターンテーブル408のアドレスを参照し、該アドレスが示す領域に記憶されている相励磁パターンをポートレジスタ405へ出力し、ステップ数カウンタ406を1増加させる(ステップS120)。   When the value of the timer counter 401 matches the value of the timer register 402 (YES in step S119), the control unit 223 of the ASIC 203 refers to the address of the phase excitation pattern table 408, and stores the phase stored in the area indicated by the address. The excitation pattern is output to the port register 405, and the step number counter 406 is incremented by 1 (step S120).

次に、ASIC203の制御部223は、ステップ数カウンタ406の計数値(ASIC203から出力した相励磁パターンの数)と、ステップ数設定用レジスタ407内の減速ステップ数レジスタの設定値とを比較する(ステップS121)。ステップ数カウンタ406の値(ASIC203から出力した相励磁パターンの数)と、前記両者の値が一致していない場合は(ステップS121でNO)、ASIC203の制御部223は、ステッピングモータ204の減速が終了していないと判断し、加速/減速テーブル403における減速テーブルのアドレスと、相励磁パターンテーブル408のアドレスを1増加させる(ステップS122)。   Next, the control unit 223 of the ASIC 203 compares the count value of the step number counter 406 (the number of phase excitation patterns output from the ASIC 203) with the set value of the deceleration step number register in the step number setting register 407 ( Step S121). If the value of the step number counter 406 (the number of phase excitation patterns output from the ASIC 203) and the two values do not match (NO in step S121), the controller 223 of the ASIC 203 causes the stepping motor 204 to decelerate. It is determined that the process has not been completed, and the address of the deceleration table in the acceleration / deceleration table 403 and the address of the phase excitation pattern table 408 are incremented by 1 (step S122).

このとき、相励磁パターンテーブル408のアドレスがn(相励磁パターン最終データのアドレス+1(アドレス超過))であれば(ステップS123でYES)、ASIC203の制御部223は、相励磁パターンテーブル408の参照アドレスを先頭アドレスとし(ステップS124)、再びタイマカウンタ401の値がタイマレジスタ402の値に一致するのを待つ(ステップS119)。相励磁パターンテーブル408のアドレスがn(相励磁パターン最終データのアドレス+1(アドレス超過))でなければ(ステップS123でNO)、ASIC203の制御部223は、何もせず、ステップS119へ制御を移す。   At this time, if the address of the phase excitation pattern table 408 is n (address of phase excitation pattern final data + 1 (excess address)) (YES in step S123), the control unit 223 of the ASIC 203 refers to the phase excitation pattern table 408. The address is set as the head address (step S124), and the process waits again for the value of the timer counter 401 to match the value of the timer register 402 (step S119). If the address of phase excitation pattern table 408 is not n (address of phase excitation pattern final data + 1 (excess address)) (NO in step S123), control unit 223 of ASIC 203 does nothing and shifts control to step S119. .

一方、ステップ数カウンタ406の計数値(ASIC203から出力した相励磁パターンの数)と、ステップ数設定用レジスタ407内の減速ステップ数レジスタの設定値とが一致している場合は(ステップS121でYES)、ステッピングモータ204の減速制御が終了したことになるので、ASIC203の制御部223は、ステッピングモータ204の電流値を0に設定し、再度、クロック信号線205上のクロックを検出できるように、外部クロック入力(CPU200のクロック発振器210からのクロック入力)の設定とし(ステップS125)、一連の処理を終了する(ステップS126)。   On the other hand, when the count value of the step number counter 406 (the number of phase excitation patterns output from the ASIC 203) matches the set value of the deceleration step number register in the step number setting register 407 (YES in step S121). ) Since the deceleration control of the stepping motor 204 is completed, the control unit 223 of the ASIC 203 sets the current value of the stepping motor 204 to 0 so that the clock on the clock signal line 205 can be detected again. The external clock input (clock input from the clock oscillator 210 of the CPU 200) is set (step S125), and the series of processing ends (step S126).

本実施の形態の制御をまとめると、ステッピングモータ204の加速区間では、ステップ数カウンタ406の計数値がステップ数設定用レジスタ407内の加速ステップ数レジスタの設定値に一致するまで、内部クロックに同期させて相励磁パターンに対応した相励磁信号をステッピングモータ204に出力する。また、ステッピングモータ204の等速区間では、ステップ数カウンタ406の計数値がステップ数設定用レジスタ407内の等速ステップ数レジスタの設定値に一致するまで、外部クロックに同期させて相励磁パターンに対応した相励磁信号をステッピングモータ204に出力する。また、ステッピングモータ204の減速区間では、ステップ数カウンタ406の計数値がステップ数設定用レジスタ407内の減速ステップ数レジスタの設定値に一致するまで、内部クロックに同期させて相励磁パターンに対応した相励磁信号をステッピングモータ204に出力する。   To summarize the control of the present embodiment, in the acceleration section of the stepping motor 204, it is synchronized with the internal clock until the count value of the step number counter 406 matches the set value of the acceleration step number register in the step number setting register 407. Thus, a phase excitation signal corresponding to the phase excitation pattern is output to the stepping motor 204. In the constant speed section of the stepping motor 204, the phase excitation pattern is synchronized with the external clock until the count value of the step number counter 406 matches the set value of the constant speed step number register in the step number setting register 407. A corresponding phase excitation signal is output to the stepping motor 204. In the deceleration zone of the stepping motor 204, the phase excitation pattern is synchronized with the internal clock until the count value of the step number counter 406 matches the set value of the deceleration step number register in the step number setting register 407. A phase excitation signal is output to the stepping motor 204.

以上説明したように、本実施の形態によれば、ASIC203の制御部223は、ステッピングモータ204の加速制御時には、ASIC203の内部クロックに同期させて相励磁パターンに対応した相励磁信号をステッピングモータ204に出力し、ステッピングモータ204の等速制御時には、CPU200からの外部クロックに同期させて相励磁信号をステッピングモータ204に出力し、ステッピングモータ204の減速制御時には、ASIC203の内部クロックに同期させて相励磁信号をステッピングモータ204に出力する制御を行う。   As described above, according to the present embodiment, the control unit 223 of the ASIC 203 transmits the phase excitation signal corresponding to the phase excitation pattern in synchronization with the internal clock of the ASIC 203 during the acceleration control of the stepping motor 204. When the stepping motor 204 is controlled at a constant speed, a phase excitation signal is output to the stepping motor 204 in synchronization with the external clock from the CPU 200. When the stepping motor 204 is controlled to be decelerated, the phase is synchronized with the internal clock of the ASIC 203. Control to output an excitation signal to the stepping motor 204 is performed.

これにより、ステッピングモータ204の制御目標(加速制御、等速制御、減速制御)に応じて、ステッピングモータ204を制御する制御装置(CPU200またはASIC203)を自由に切り換えることが可能となる。その結果、従来の、モータの等速回転時の速度変更を行う場合にCPU資源が不足する問題や、単に加減速テーブルを用いてモータ速度制御を行う場合の処理時間がかかる問題を解消することができる。   This makes it possible to freely switch the control device (CPU 200 or ASIC 203) that controls the stepping motor 204 according to the control target (acceleration control, constant speed control, deceleration control) of the stepping motor 204. As a result, it is possible to solve the conventional problem that the CPU resource is insufficient when changing the speed at the constant speed of the motor, and the processing time when the motor speed control is simply performed using the acceleration / deceleration table. Can do.

[第2の実施の形態]
図13は、本発明の第2の実施の形態に係る画像形成装置の制御系の構成を示すブロック図である。
[Second Embodiment]
FIG. 13 is a block diagram showing the configuration of the control system of the image forming apparatus according to the second embodiment of the present invention.

図13において、画像形成装置の制御系は、CPU700、ROM701、RAM702、ASIC703、データバス/アドレスバス707から構成されている。CPU700は、通信制御部711を備えている。ASIC703は、マルチプレクサ720、クロック発振器721、制御部723、ポートレジスタ724、ROM725、RAM724を備えている。   In FIG. 13, the control system of the image forming apparatus includes a CPU 700, a ROM 701, a RAM 702, an ASIC 703, and a data bus / address bus 707. The CPU 700 includes a communication control unit 711. The ASIC 703 includes a multiplexer 720, a clock oscillator 721, a control unit 723, a port register 724, a ROM 725, and a RAM 724.

本実施の形態は、上述した第1の実施の形態に対して、CPU700からクロック発振器を除去した点、ASIC703からクロック受信器を除去しマルチプレクサ720を追加した点、マルチプレクサ720によりCPU700に接続されたモータ制御信号線とASIC703内部のモータ制御信号線とを選択的に切り換える点において相違する。本実施の形態のその他の要素は、上述した第1の実施の形態(図2)の対応するものと同一なので、説明を省略する。   The present embodiment is connected to the CPU 700 by the multiplexer 720 in that the clock oscillator is removed from the CPU 700, the clock receiver is removed from the ASIC 703, and the multiplexer 720 is added to the first embodiment described above. The difference is that the motor control signal line and the motor control signal line inside the ASIC 703 are selectively switched. Since the other elements of the present embodiment are the same as the corresponding ones of the first embodiment (FIG. 2) described above, description thereof is omitted.

CPU700の通信制御部711とASIC703の制御部723との間には、通信信号線706−1、706−2が接続されている。通信信号線706−1は、CPU700からASIC703へデータを送信する信号線である。通信信号線706−2は、ASIC703からCPU700へデータを送信する信号線である。ASIC703の制御部723は、CPU700の通信制御部711から所定のデータを受信し、ステッピングモータ704を制御することができる。   Communication signal lines 706-1 and 706-2 are connected between the communication control unit 711 of the CPU 700 and the control unit 723 of the ASIC 703. The communication signal line 706-1 is a signal line for transmitting data from the CPU 700 to the ASIC 703. A communication signal line 706-2 is a signal line for transmitting data from the ASIC 703 to the CPU 700. The control unit 723 of the ASIC 703 can receive predetermined data from the communication control unit 711 of the CPU 700 and control the stepping motor 704.

CPU700とASIC703のマルチプレクサ720との間には、モータ制御信号線705−1、705−2、705−3、705−4が接続されている。マルチプレクサ720は、CPU700からモータ制御信号線705−1、705−2、705−3、705−4を介してモータ制御信号を受信する。   Motor control signal lines 705-1, 705-2, 705-3, and 705-4 are connected between the CPU 700 and the multiplexer 720 of the ASIC 703. The multiplexer 720 receives a motor control signal from the CPU 700 via the motor control signal lines 705-1, 705-2, 705-3, and 705-4.

ASIC703のポートレジスタ724とステッピングモータ704との間には、モータ制御信号線730、731、732、733がマルチプレクサ720を介して接続されている。制御部223によりROM725に格納されている相励磁パターンが読み出され、ポートレジスタ724を介してモータ制御信号線730、731、732、733に供給される。尚、ROM725に格納される相励磁パターンは、ASIC703の外部から設定変更することが可能である。   Motor control signal lines 730, 731, 732, and 733 are connected via a multiplexer 720 between the port register 724 of the ASIC 703 and the stepping motor 704. The phase excitation pattern stored in the ROM 725 is read by the controller 223 and supplied to the motor control signal lines 730, 731, 732, and 733 via the port register 724. The phase excitation pattern stored in the ROM 725 can be set and changed from outside the ASIC 703.

マルチプレクサ720は、制御部723からの指示に基づき、ステッピングモータ704を駆動するためのモータ制御信号(相励磁パターンに対応した相励磁信号)を、CPU700からモータ制御信号線705−1〜705−4を介して供給されるモータ制御信号と、制御部723からポートレジスタ724経由でモータ制御信号線730〜733を介して供給されるモータ制御信号の何れかに切り換える。   The multiplexer 720 receives a motor control signal (phase excitation signal corresponding to the phase excitation pattern) for driving the stepping motor 704 from the CPU 700 based on an instruction from the control unit 723, and motor control signal lines 705-1 to 705-4. And the motor control signal supplied from the control unit 723 via the port register 724 via the motor control signal lines 730 to 733.

本実施の形態の制御をまとめると、ステッピングモータ704の加速区間では、ステップ数カウンタ406の計数値がステップ数設定用レジスタ407内の加速ステップ数レジスタの設定値に一致するまで、ASIC内部の相励磁パターンに対応した相励磁信号をステッピングモータ704に出力する。また、ステッピングモータ704の等速区間では、ステップ数カウンタ406の計数値がステップ数設定用レジスタ407内の等速ステップ数レジスタの設定値に一致するまで、CPU700から入力された相励磁パターンに対応した相励磁信号をステッピングモータ704に出力する。また、ステッピングモータ704の減速区間では、ステップ数カウンタ406の計数値がステップ数設定用レジスタ407内の減速ステップ数レジスタの設定値に一致するまで、ASIC内部の相励磁パターンに対応した相励磁信号をステッピングモータ704に出力する。   To summarize the control of the present embodiment, in the acceleration section of the stepping motor 704, the phase inside the ASIC is kept until the count value of the step number counter 406 matches the set value of the acceleration step number register in the step number setting register 407. A phase excitation signal corresponding to the excitation pattern is output to the stepping motor 704. Further, in the constant speed section of the stepping motor 704, it corresponds to the phase excitation pattern input from the CPU 700 until the count value of the step number counter 406 matches the set value of the constant speed step number register in the step number setting register 407. The phase excitation signal thus output is output to the stepping motor 704. In the deceleration zone of the stepping motor 704, the phase excitation signal corresponding to the phase excitation pattern in the ASIC until the count value of the step number counter 406 matches the set value of the deceleration step number register in the step number setting register 407. Is output to the stepping motor 704.

以上説明したように、本実施の形態によれば、ステッピングモータ704の加速/等速/減速の各区間に応じて、ステッピングモータ704を駆動するためのモータ制御信号(相励磁パターンに対応した相励磁信号)を出力する4本のモータ制御信号線(モータ制御信号線705−1〜705−4またはモータ制御信号線730〜733)をマルチプレクサ720により切り換える。   As described above, according to the present embodiment, the motor control signal (the phase corresponding to the phase excitation pattern) for driving the stepping motor 704 in accordance with the acceleration / constant speed / deceleration sections of the stepping motor 704. The four motor control signal lines (motor control signal lines 705-1 to 705-4 or motor control signal lines 730 to 733) that output the excitation signal are switched by the multiplexer 720.

これにより、ステッピングモータ704の制御目標(加速制御、等速制御、減速制御)に応じて、ステッピングモータ704を制御する制御装置(CPU700またはASIC703)を自由に切り換えることが可能となる。その結果、従来の、モータの等速回転時の速度変更を行う場合にCPU資源が不足する問題や、単に加減速テーブルを用いてモータ速度制御を行う場合の処理時間がかかる問題を解消することができる。   This makes it possible to freely switch the control device (CPU 700 or ASIC 703) that controls the stepping motor 704 in accordance with the control target (acceleration control, constant speed control, deceleration control) of the stepping motor 704. As a result, it is possible to solve the conventional problem that the CPU resource is insufficient when changing the speed at the constant speed of the motor, and the processing time when the motor speed control is simply performed using the acceleration / deceleration table. Can do.

[他の実施の形態]
上記第1の実施の形態では、ステッピングモータ204の加速区間及び減速区間は、ASIC203の内部クロックに同期させて相励磁パターンに対応した相励磁信号を出力し、ステッピングモータ204の等速区間は、CPU200からの外部クロックに同期させて相励磁パターンに対応した相励磁信号を出力する方法(図4(b)の場合)を用いた。しかし、加速区間及び減速区間においてCPU200の処理負荷が大きくなる場合には、加速区間及び減速区間は、CPU200からの外部クロックに同期させて相励磁パターンに対応した相励磁信号を出力し、等速区間は、ASIC203の内部クロックに同期させて相励磁信号を出力する方法(図4(c)の場合)を用いてもよい。
[Other embodiments]
In the first embodiment, the acceleration interval and the deceleration interval of the stepping motor 204 output a phase excitation signal corresponding to the phase excitation pattern in synchronization with the internal clock of the ASIC 203, and the constant velocity interval of the stepping motor 204 is A method of outputting a phase excitation signal corresponding to the phase excitation pattern in synchronization with the external clock from the CPU 200 (in the case of FIG. 4B) was used. However, when the processing load of the CPU 200 increases in the acceleration section and the deceleration section, the acceleration section and the deceleration section output a phase excitation signal corresponding to the phase excitation pattern in synchronization with the external clock from the CPU 200, and the constant speed For the section, a method of outputting a phase excitation signal in synchronization with the internal clock of the ASIC 203 (in the case of FIG. 4C) may be used.

上記第2の実施の形態では、ステッピングモータ704の加速区間及び減速区間は、モータ制御信号線730〜733を介してASIC内部の相励磁パターンに対応した相励磁信号を出力し、ステッピングモータ704の等速区間は、モータ制御信号線705−1〜705−4を介してCPU700から入力された相励磁パターンに対応した相励磁信号を出力する方法を用いた。しかし、加速区間及び減速区間においてCPU700の処理負荷が大きくなる場合には、加速区間及び減速区間は、モータ制御信号線705−1〜705−4を介してCPU700から入力された相励磁パターンに対応した相励磁信号を出力し、等速区間は、モータ制御信号線730〜733を介してASIC内部の相励磁パターンに対応した相励磁信号を出力する方法を用いてもよい。   In the second embodiment, the acceleration interval and the deceleration interval of the stepping motor 704 output phase excitation signals corresponding to the phase excitation pattern inside the ASIC via the motor control signal lines 730 to 733, and the stepping motor 704 For the constant velocity section, a method of outputting a phase excitation signal corresponding to the phase excitation pattern input from the CPU 700 via the motor control signal lines 705-1 to 705-4 was used. However, when the processing load on the CPU 700 increases in the acceleration section and the deceleration section, the acceleration section and the deceleration section correspond to the phase excitation pattern input from the CPU 700 via the motor control signal lines 705-1 to 705-4. A method may be used in which the phase excitation signal is output and the phase excitation signal corresponding to the phase excitation pattern in the ASIC is output via the motor control signal lines 730 to 733 in the constant velocity section.

上記第1及び第2の実施の形態では、ステッピングモータを制御するためにCPUとASICを用いる構成としているが、本発明はCPUとASICを用いる構成に限定されるものではない。ステッピングモータを制御するために2つの制御装置を用い、該2つの制御装置を切り換えながらステッピングモータを制御する構成であれば、任意の構成を用いることができる。   In the first and second embodiments, the CPU and the ASIC are used to control the stepping motor. However, the present invention is not limited to the configuration using the CPU and the ASIC. Any configuration can be used as long as it uses two control devices to control the stepping motor and controls the stepping motor while switching between the two control devices.

上記第1及び第2の実施の形態では、本発明のモータ制御装置を画像形成装置(複写機)に適用した例を説明したが、複写機のみへの適用に限定されるものではない。本発明のモータ制御装置は複写機以外の画像形成装置(プリンタ、複合機)や画像通信装置(ファクシミリ)等に適用することができる。   In the first and second embodiments, the example in which the motor control device of the present invention is applied to an image forming apparatus (copier) has been described. However, the present invention is not limited to application only to a copier. The motor control apparatus of the present invention can be applied to an image forming apparatus (printer, multifunction machine) other than a copying machine, an image communication apparatus (facsimile), or the like.

本発明は、上述した実施の形態の機能を実現するソフトウェアのプログラム(図10〜図12のフローチャート)をコンピュータ又はCPUに供給し、そのコンピュータ又はCPUが該供給されたプログラムを読出して実行することによって、達成することができる。   The present invention supplies a software program (flowcharts in FIGS. 10 to 12) for realizing the functions of the above-described embodiments to a computer or CPU, and the computer or CPU reads and executes the supplied program. Can be achieved.

この場合、上記プログラムは、該プログラムを記録した記憶媒体から直接供給されるか、又はインターネット、商用ネットワーク、若しくはローカルエリアネットワーク等に接続される不図示の他のコンピュータやデータベース等からダウンロードすることにより供給される。   In this case, the program is directly supplied from a storage medium storing the program, or downloaded from another computer or database (not shown) connected to the Internet, a commercial network, a local area network, or the like. Supplied.

上記プログラムの形態は、オブジェクトコード、インタプリタにより実行されるプログラムコード、OS(オペレーティングシステム)に供給されるスクリプトデータ等の形態から成ってもよい。   The form of the program may be in the form of object code, program code executed by an interpreter, script data supplied to an OS (operating system), and the like.

また、本発明は、上述した実施の形態の機能を実現するソフトウェアのプログラムを記憶した記憶媒体をコンピュータ又はCPUに供給し、そのコンピュータ又はCPUが記憶媒体に記憶されたプログラムを読出して実行することによっても、達成することができる。   The present invention also supplies a computer or CPU with a storage medium storing a software program that implements the functions of the above-described embodiments, and the computer or CPU reads and executes the program stored in the storage medium. Can also be achieved.

この場合、格納媒体から読出されたプログラムコード自体が上述した各実施の形態の機能を実現すると共に、そのプログラムコードを記憶した記憶媒体は本発明を構成する。   In this case, the program code itself read from the storage medium realizes the functions of the above-described embodiments, and the storage medium storing the program code constitutes the present invention.

プログラムコードを記憶する記憶媒体としては、例えば、ROM、RAM、NV−RAM、フロッピー(登録商標)ディスク、ハードディスク、光ディスク(登録商標)、光磁気ディスク、CD−ROM、MO、CD−R、CD−RW、DVD−ROM、DVD−RAM、DVD−RW、DVD+RW、磁気テープ、不揮発性のメモリカード等がある。   As a storage medium for storing the program code, for example, ROM, RAM, NV-RAM, floppy (registered trademark) disk, hard disk, optical disk (registered trademark), magneto-optical disk, CD-ROM, MO, CD-R, CD -RW, DVD-ROM, DVD-RAM, DVD-RW, DVD + RW, magnetic tape, nonvolatile memory card, etc.

上述した実施の形態の機能は、コンピュータから読出されたプログラムコードを実行することによるばかりでなく、コンピュータ上で稼動するOS等がプログラムコードの指示に基づいて実際の処理の一部又は全部を行うことによっても実現することができる。   The function of the above-described embodiment is not only by executing the program code read from the computer, but the OS or the like running on the computer performs part or all of the actual processing based on the instruction of the program code. Can also be realized.

本発明の第1の実施の形態に係る画像形成装置の内部構造を示す構成図である。1 is a configuration diagram showing an internal structure of an image forming apparatus according to a first embodiment of the present invention. 画像形成装置の制御系の構成を示すブロック図である。2 is a block diagram illustrating a configuration of a control system of the image forming apparatus. FIG. 画像形成装置のステッピングモータの駆動方法を示すタイミングチャートである。3 is a timing chart illustrating a method for driving a stepping motor of the image forming apparatus. (a)は、ステッピングモータの加速/等速/減速時の速度変化を示す図、(b)、(c)は、CPU及びASIC間の通信信号線上を流れるデータとクロック信号線の関係を示す図である。(A) is a figure which shows the speed change at the time of acceleration / constant speed / deceleration of a stepping motor, (b), (c) shows the relationship between the data which flow on the communication signal line between CPU and ASIC, and a clock signal line. FIG. ASICの制御部がステッピングモータを制御するのに必要な構成を示す図である。It is a figure which shows a structure required in order that the control part of ASIC may control a stepping motor. CPU及びASIC間の送受信データの基本的な構造を示す図である。It is a figure which shows the basic structure of the transmission / reception data between CPU and ASIC. ステッピングモータ起動コマンド及びステッピングモータ起動応答コマンドを示す図である。It is a figure which shows a stepping motor starting command and a stepping motor starting response command. ステッピングモータ停止コマンド及びステッピングモータ停止応答コマンドを示す図である。It is a figure which shows a stepping motor stop command and a stepping motor stop response command. ステッピングモータのモータシーケンス設定コマンド及びモータシーケンス設定応答コマンドを示す図である。It is a figure which shows the motor sequence setting command and motor sequence setting response command of a stepping motor. ASICの制御部によるステッピングモータに対するクロック切り換え制御を示すフローチャートである。It is a flowchart which shows the clock switching control with respect to the stepping motor by the control part of ASIC. 図10のフローチャートの続きである。It is a continuation of the flowchart of FIG. 図11のフローチャートの続きである。It is a continuation of the flowchart of FIG. 本発明の第2の実施の形態に係る画像形成装置の制御系の構成を示すブロック図である。FIG. 6 is a block diagram illustrating a configuration of a control system of an image forming apparatus according to a second embodiment of the present invention.

符号の説明Explanation of symbols

200 CPU(モータ制御装置外部に対応)
203 ASIC(モータ制御装置に対応)
204 ステッピングモータ(相励磁方式のモータに対応)
220 クロック受信器(受信手段に対応)
221 クロック発振器(発生手段に対応)
223 制御部(選択手段に対応)
224 ポートレジスタ(出力手段に対応)
406 ステップ数カウンタ(計数手段に対応)
407 ステップ数設定用レジスタ(加速設定手段、等速設定手段、減速設定手段に対応)
700 CPU(モータ制御装置外部に対応)
703 ASIC(モータ制御装置に対応)
704 ステッピングモータ(相励磁方式のモータに対応)
705−1〜705−4 モータ制御信号線(外部供給手段に対応)
720 マルチプレクサ(選択手段に対応)
725 ポートレジスタ(出力手段に対応)
730〜733 モータ制御信号線(内部供給手段に対応)
200 CPU (external to motor controller)
203 ASIC (corresponding to motor control device)
204 Stepping motor (compatible with phase excitation motor)
220 Clock receiver (corresponding to receiving means)
221 Clock oscillator (corresponding to generating means)
223 control unit (corresponding to selection means)
224 port register (corresponding to output means)
406 Step number counter (corresponding to counting means)
407 Step number setting register (corresponding to acceleration setting means, constant speed setting means, deceleration setting means)
700 CPU (external to motor controller)
703 ASIC (corresponding to motor control device)
704 Stepping motor (compatible with phase excitation motor)
705-1 to 705-4 Motor control signal line (corresponding to external supply means)
720 Multiplexer (corresponding to selection means)
725 port register (corresponding to output means)
730-733 Motor control signal line (corresponding to internal supply means)

Claims (10)

相励磁方式のモータを駆動制御するモータ制御装置であって、
クロックを発生する発生手段と、
前記モータ制御装置外部から入力されるクロックを受信する受信手段と、
前記モータの制御目標状態に応じて、前記発生手段により発生したクロックと前記受信手段により受信したクロックとを選択的に切り換える選択手段と、
前記選択手段により選択されたクロックに同期させながら相励磁パターンに対応した相励磁信号を前記モータに出力する出力手段とを備えることを特徴とするモータ制御装置。
A motor control device for driving and controlling a phase excitation motor,
Generating means for generating a clock;
Receiving means for receiving a clock input from outside the motor control device;
Selection means for selectively switching between the clock generated by the generation means and the clock received by the reception means according to the control target state of the motor;
A motor control apparatus comprising: output means for outputting a phase excitation signal corresponding to a phase excitation pattern to the motor while synchronizing with a clock selected by the selection means.
前記モータの加速に必要なクロック数が設定される加速設定手段と、
前記モータの等速駆動に必要なクロック数が設定される等速設定手段と、
前記モータの減速及び停止に必要なクロック数が設定される減速設定手段と、
前記モータに出力した相励磁信号の数を計数する計数手段とを更に備え、
前記計数手段の計数値が前記加速設定手段の設定値に一致するまで、前記発生手段により発生したクロックに同期させて相励磁信号を出力し、
前記計数手段の計数値が前記等速設定手段の設定値に一致するまで、前記受信手段により受信したクロックに同期させて相励磁信号を出力し、
前記計数手段の計数値が前記減速設定手段の設定値に一致するまで、前記発生手段により発生したクロックに同期させて相励磁信号を出力することを特徴とする請求項1記載のモータ制御装置。
Acceleration setting means for setting the number of clocks required for acceleration of the motor;
Constant speed setting means for setting the number of clocks required for constant speed driving of the motor;
Deceleration setting means for setting the number of clocks required for the deceleration and stop of the motor;
Counting means for counting the number of phase excitation signals output to the motor;
Until the count value of the counting means matches the set value of the acceleration setting means, a phase excitation signal is output in synchronization with the clock generated by the generating means,
Until the count value of the counting means matches the set value of the constant velocity setting means, the phase excitation signal is output in synchronization with the clock received by the receiving means,
2. The motor control device according to claim 1, wherein a phase excitation signal is output in synchronization with a clock generated by the generating means until a count value of the counting means coincides with a set value of the deceleration setting means.
前記モータの加速に必要なクロック数が設定される加速設定手段と、
前記モータの等速駆動に必要なクロック数が設定される等速設定手段と、
前記モータの減速及び停止に必要なクロック数が設定される減速設定手段と、
前記モータに出力した相励磁信号の数を計数する計数手段とを更に備え、
前記計数手段の計数値が前記加速設定手段の設定値に一致するまで、前記受信手段により受信したクロックに同期させて相励磁信号を出力し、
前記計数手段の計数値が前記等速設定手段の設定値に一致するまで、前記発生手段により発生したクロックに同期させて相励磁信号を出力し、
前記計数手段の計数値が前記減速設定手段の設定値に一致するまで、前記受信手段により受信したクロックに同期させて相励磁信号を出力することを特徴とする請求項1記載のモータ制御装置。
Acceleration setting means for setting the number of clocks required for acceleration of the motor;
Constant speed setting means for setting the number of clocks required for constant speed driving of the motor;
Deceleration setting means for setting the number of clocks required for the deceleration and stop of the motor;
Counting means for counting the number of phase excitation signals output to the motor;
Until the count value of the counting means matches the set value of the acceleration setting means, a phase excitation signal is output in synchronization with the clock received by the receiving means,
Until the count value of the counting means matches the set value of the constant speed setting means, a phase excitation signal is output in synchronization with the clock generated by the generating means,
2. The motor control device according to claim 1, wherein a phase excitation signal is output in synchronization with a clock received by the receiving means until a count value of the counting means coincides with a set value of the deceleration setting means.
相励磁方式のモータを駆動制御するモータ制御装置であって、
相励磁パターンを供給する内部供給手段と、
前記モータ制御装置外部から入力される相励磁パターンを供給する外部供給手段と、
前記モータの制御目標状態に応じて、前記内部供給手段により供給される相励磁パターンと前記外部供給手段により供給される相励磁パターンとを選択的に切り換える選択手段と、
前記選択手段により選択された相励磁パターンに対応した相励磁信号を前記モータに出力する出力手段とを備えることを特徴とするモータ制御装置。
A motor control device for driving and controlling a phase excitation motor,
An internal supply means for supplying a phase excitation pattern;
An external supply means for supplying a phase excitation pattern inputted from the outside of the motor control device;
A selection means for selectively switching between a phase excitation pattern supplied by the internal supply means and a phase excitation pattern supplied by the external supply means according to a control target state of the motor;
A motor control apparatus comprising: output means for outputting a phase excitation signal corresponding to the phase excitation pattern selected by the selection means to the motor.
前記モータの加速に必要なクロック数が設定される加速設定手段と、
前記モータの等速駆動に必要なクロック数が設定される等速設定手段と、
前記モータの減速及び停止に必要なクロック数が設定される減速設定手段と、
前記モータに出力した相励磁信号の数を計数する計数手段とを更に備え、
前記計数手段の計数値が前記加速設定手段の設定値に一致するまで、前記内部供給手段により供給される相励磁パターンに対応した相励磁信号を出力し、
前記計数手段の計数値が前記等速設定手段の設定値に一致するまで、前記外部供給手段により供給される相励磁パターンに対応した相励磁信号を出力し、
前記計数手段の計数値が前記減速設定手段の設定値に一致するまで、前記内部供給手段により供給される相励磁パターンに対応した相励磁信号を出力することを特徴とする請求項4記載のモータ制御装置。
Acceleration setting means for setting the number of clocks required for acceleration of the motor;
Constant speed setting means for setting the number of clocks required for constant speed driving of the motor;
Deceleration setting means for setting the number of clocks required for the deceleration and stop of the motor;
Counting means for counting the number of phase excitation signals output to the motor;
Output a phase excitation signal corresponding to the phase excitation pattern supplied by the internal supply means until the count value of the counting means matches the set value of the acceleration setting means,
Output a phase excitation signal corresponding to the phase excitation pattern supplied by the external supply means until the count value of the counting means matches the set value of the constant speed setting means,
5. The motor according to claim 4, wherein a phase excitation signal corresponding to the phase excitation pattern supplied by the internal supply means is output until a count value of the counting means matches a set value of the deceleration setting means. Control device.
前記モータの加速に必要なクロック数が設定される加速設定手段と、
前記モータの等速駆動に必要なクロック数が設定される等速設定手段と、
前記モータの減速及び停止に必要なクロック数が設定される減速設定手段と、
前記モータに出力した相励磁信号の数を計数する計数手段とを更に備え、
前記計数手段の計数値が前記加速設定手段の設定値に一致するまで、前記外部供給手段により供給される相励磁パターンに対応した相励磁信号を出力し、
前記計数手段の計数値が前記等速設定手段の設定値に一致するまで、前記内部供給手段により供給される相励磁パターンに対応した相励磁信号を出力し、
前記計数手段の計数値が前記減速設定手段の設定値に一致するまで、前記外部供給手段により供給される相励磁パターンに対応した相励磁信号を出力することを特徴とする請求項4記載のモータ制御装置。
Acceleration setting means for setting the number of clocks required for acceleration of the motor;
Constant speed setting means for setting the number of clocks required for constant speed driving of the motor;
Deceleration setting means for setting the number of clocks required for the deceleration and stop of the motor;
Counting means for counting the number of phase excitation signals output to the motor;
Output a phase excitation signal corresponding to the phase excitation pattern supplied by the external supply means until the count value of the counting means matches the set value of the acceleration setting means,
Until the count value of the counting means matches the set value of the constant speed setting means, a phase excitation signal corresponding to the phase excitation pattern supplied by the internal supply means is output,
5. The motor according to claim 4, wherein a phase excitation signal corresponding to a phase excitation pattern supplied by the external supply means is output until a count value of the counting means matches a set value of the deceleration setting means. Control device.
前記相励磁パターンは、前記モータ制御装置外部から設定変更することが可能であることを特徴とする請求項1乃至6の何れかに記載のモータ制御装置。   The motor control device according to claim 1, wherein the phase excitation pattern can be set and changed from outside the motor control device. 前記請求項1乃至7の何れかに記載のモータ制御装置を備えることを特徴とする画像形成装置。   An image forming apparatus comprising the motor control device according to claim 1. 相励磁方式のモータを駆動制御するモータ制御装置の制御方法であって、
前記モータ制御装置内部でクロックを発生する発生ステップと、
前記モータ制御装置外部から前記モータ制御装置に入力されるクロックを受信する受信ステップと、
前記モータの制御目標状態に応じて、前記発生ステップにより発生したクロックと前記受信ステップにより受信したクロックとを選択的に切り換える選択ステップと、
前記選択ステップにより選択されたクロックに同期させながら相励磁パターンに対応した相励磁信号を前記モータに出力する出力ステップとを備えることを特徴とする制御方法。
A control method of a motor control device that drives and controls a phase excitation motor,
Generating step for generating a clock inside the motor control device;
A receiving step of receiving a clock input to the motor control device from outside the motor control device;
A selection step of selectively switching between the clock generated by the generation step and the clock received by the reception step according to the control target state of the motor;
And a step of outputting a phase excitation signal corresponding to a phase excitation pattern to the motor while synchronizing with the clock selected in the selection step.
相励磁方式のモータを駆動制御するモータ制御装置の制御方法をコンピュータに実行させるプログラムであって、
前記モータ制御装置内部でクロックを発生する発生モジュールと、
前記モータ制御装置外部から前記モータ制御装置に入力されるクロックを受信する受信モジュールと、
前記モータの制御目標状態に応じて、前記発生モジュールにより発生したクロックと前記受信モジュールにより受信したクロックとを選択的に切り換える選択モジュールと、
前記選択モジュールにより選択されたクロックに同期させながら相励磁パターンに対応した相励磁信号を前記モータに出力する出力モジュールとを備えることを特徴とするプログラム。
A program for causing a computer to execute a control method of a motor control device that drives and controls a phase excitation motor,
A generation module for generating a clock inside the motor control device;
A receiving module for receiving a clock input to the motor control device from the outside of the motor control device;
A selection module that selectively switches between a clock generated by the generation module and a clock received by the reception module in accordance with a control target state of the motor;
A program comprising: an output module for outputting a phase excitation signal corresponding to a phase excitation pattern to the motor while synchronizing with a clock selected by the selection module.
JP2004218394A 2004-07-27 2004-07-27 Apparatus and method for controlling motor Withdrawn JP2006042493A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004218394A JP2006042493A (en) 2004-07-27 2004-07-27 Apparatus and method for controlling motor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004218394A JP2006042493A (en) 2004-07-27 2004-07-27 Apparatus and method for controlling motor

Publications (1)

Publication Number Publication Date
JP2006042493A true JP2006042493A (en) 2006-02-09

Family

ID=35906862

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004218394A Withdrawn JP2006042493A (en) 2004-07-27 2004-07-27 Apparatus and method for controlling motor

Country Status (1)

Country Link
JP (1) JP2006042493A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111061279A (en) * 2020-01-03 2020-04-24 山东大学 Indoor self-adaptive cruise control system and method for electric sickbed
CN112564560A (en) * 2020-12-09 2021-03-26 山东志盈医学科技有限公司 Method and device for controlling acceleration and deceleration of stepping motor of digital slice scanner

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111061279A (en) * 2020-01-03 2020-04-24 山东大学 Indoor self-adaptive cruise control system and method for electric sickbed
CN112564560A (en) * 2020-12-09 2021-03-26 山东志盈医学科技有限公司 Method and device for controlling acceleration and deceleration of stepping motor of digital slice scanner
CN112564560B (en) * 2020-12-09 2022-11-04 山东志盈医学科技有限公司 Method and device for controlling acceleration and deceleration of stepping motor of digital slice scanner

Similar Documents

Publication Publication Date Title
JP6551493B2 (en) Drive device, image forming apparatus, and peripheral device of image forming apparatus
US9846401B2 (en) Image forming apparatus
JP6724475B2 (en) Driving device and image forming apparatus
JP6702768B2 (en) Image forming device
US6911800B2 (en) Stepping motor controller, scanning apparatus, and image forming apparatus
JP5489575B2 (en) Image forming apparatus
US5467173A (en) Speed control circuit for an optical scanning system driving motor for an image forming apparatus
JP4383991B2 (en) Motor control device
US6825636B2 (en) Circuit and method for controlling stepping motor
JP6838452B2 (en) Drive device and image forming device
JP2006042493A (en) Apparatus and method for controlling motor
JP2001341898A (en) Image forming device, image forming method and recording medium
EP0744822B1 (en) Motor rotational speed control apparatus
JP2001292597A (en) Motor driver, its control method, computer-readable storage medium with its control program stored thereon, and image forming apparatus
JP4145002B2 (en) Motor control method, motor control apparatus, document reading apparatus, and image forming apparatus
JP2005168138A (en) Motor controller, image forming apparatus, and motor control method
JP2005351981A (en) Rotating polygon mirror driving apparatus, method of controlling the same and program
JP2001310842A (en) Image forming device, image forming method and recording medium
JP2004215440A (en) Stepping motor controller
JP2023169644A (en) Image forming apparatus and method for controlling motor used for the same
JPH04247760A (en) Image forming device
JP3597875B2 (en) Copying system and copying method
JP2005305769A (en) Image formation engine and image forming apparatus
JPH01172152A (en) Copying device
JPH11180612A (en) Image forming device

Legal Events

Date Code Title Description
RD03 Notification of appointment of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7423

Effective date: 20060419

A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20071002