JP2009142122A - Motor controller - Google Patents

Motor controller Download PDF

Info

Publication number
JP2009142122A
JP2009142122A JP2007318366A JP2007318366A JP2009142122A JP 2009142122 A JP2009142122 A JP 2009142122A JP 2007318366 A JP2007318366 A JP 2007318366A JP 2007318366 A JP2007318366 A JP 2007318366A JP 2009142122 A JP2009142122 A JP 2009142122A
Authority
JP
Japan
Prior art keywords
motor
rotation signal
opening
counting means
window
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.)
Granted
Application number
JP2007318366A
Other languages
Japanese (ja)
Other versions
JP5078582B2 (en
Inventor
Tomohiro Takahashi
智宏 高橋
Takeshi Sekine
武司 関根
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.)
Omron Corp
Original Assignee
Omron Corp
Omron Tateisi Electronics Co
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 Omron Corp, Omron Tateisi Electronics Co filed Critical Omron Corp
Priority to JP2007318366A priority Critical patent/JP5078582B2/en
Publication of JP2009142122A publication Critical patent/JP2009142122A/en
Application granted granted Critical
Publication of JP5078582B2 publication Critical patent/JP5078582B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Power-Operated Mechanisms For Wings (AREA)
  • Window Of Vehicle (AREA)
  • Control Of Electric Motors In General (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a motor controller capable of exactly detecting the life of a switching element, such as a relay, with a simple means and issuing a warning. <P>SOLUTION: The motor controller includes a control unit 1 which outputs a normal rotation signal and a reverse rotation signal for rotating a motor 3 in a normal direction and in a reverse direction, and a motor driving circuit 2 which changes the direction of a current supplied to the motor 3 by a switching element operating based on the normal rotation signal and the reverse rotation signal to drive the motor 3. The motor controller also has a catch detecting means which detects an object's being caught in an opening and closing body during the operation of the opening and closing body. A counter 62 counts the number of times the object being caught is detected by the catch detecting means, and when the detected number of times of the object being caught exceeds a preset threshold 61, a lamp 8 is turned on to issue a warning on the life of the switching element. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は、リレーなどのスイッチング素子を用いてモータの通電を制御するモータ制御装置に関する。   The present invention relates to a motor control device that controls energization of a motor using a switching element such as a relay.

例えば、自動車の窓を開閉制御するパワーウインドウ装置においては、スイッチの操作により、モータを正転または逆転させてドアの窓ガラスを昇降させ、窓を開閉する。このようなパワーウインドウ装置には、手動で窓を開閉するマニュアルモードと、自動で窓を開閉するオートモードとを備えたものがある。後掲の特許文献1には、マニュアル閉、オート閉、マニュアル開、オート開、中立(停止)の5つの操作状態に切換可能なパワーウインドウ装置用の操作スイッチが記載されている。   For example, in a power window device that controls the opening and closing of a window of an automobile, a window is opened and closed by moving a motor forward or backward by moving a switch to move a window glass of a door up and down. Some of such power window devices have a manual mode for manually opening and closing a window and an auto mode for automatically opening and closing a window. Patent Document 1 described later describes an operation switch for a power window device that can be switched to five operation states of manual close, auto close, manual open, auto open, and neutral (stop).

一般に、マニュアルモードの場合は、スイッチの操作ノブがマニュアル閉またはマニュアル開の位置に手で保持され続ける間だけ、窓の閉動作または開動作が行われ、操作ノブから手を離してノブが中立位置に復帰すると、窓の閉動作または開動作は停止する。これに対して、オートモードの場合は、一旦、操作ノブがオート閉またはオート開の位置まで操作されると、その後は操作ノブから手を離してノブが中立位置に復帰しても、窓の閉動作または開動作が継続して行われる。   In general, in manual mode, the window is closed or opened only while the switch operation knob is held in the manual close or open position by hand. When returning to the position, the window closing or opening operation stops. On the other hand, in the auto mode, once the operation knob is operated to the auto-close or auto-open position, after that, even if you release the operation knob and the knob returns to the neutral position, The closing or opening operation continues.

パワーウインドウ装置においては、窓が閉じている途中で窓ガラスの隙間に物体や人体が挟み込まれた場合、これを検出して窓の閉動作を開動作に切り換えることで、物体や人体の損傷を防止し、安全を確保するようにしている。特に、オート閉動作で窓を閉じる場合は、挟み込み検出機能がないと、挟み込みが発生した後も窓が閉じ続けるため、危険を回避する点から挟み込み検出機能は不可欠である。   In the power window device, if an object or human body is caught in the gap between the window glass while the window is closed, this is detected and the closing operation of the window is switched to the opening operation, thereby damaging the object or human body. To prevent and ensure safety. In particular, when a window is closed by an automatic closing operation, if there is no pinch detection function, the window will continue to close even after pinching has occurred, so the pinch detection function is indispensable in order to avoid danger.

挟み込みが発生すると、窓ガラス昇降用のモータの負荷が増大して回転速度が低下するので、モータの回転速度の変化量が増大する。そこで、モータの回転速度の変化量を所定の閾値と比較し、変化量が閾値を超えなければ挟み込みが発生していないと判定し、変化量が閾値を超えれば挟み込みが発生したと判定することで、挟み込みの有無を検出することができる。また、モータの回転速度の変化量に代えて、モータに流れる電流の変化量を用いることによっても、挟み込みの有無を検出することが可能である。   When pinching occurs, the load on the window glass raising / lowering motor increases and the rotation speed decreases, so the amount of change in the rotation speed of the motor increases. Therefore, the amount of change in the rotational speed of the motor is compared with a predetermined threshold value, and if the amount of change does not exceed the threshold value, it is determined that pinching has not occurred, and if the amount of change exceeds the threshold value, it is determined that pinching has occurred. Thus, it is possible to detect the presence or absence of pinching. Further, it is possible to detect the presence or absence of pinching by using the amount of change in the current flowing in the motor instead of the amount of change in the rotational speed of the motor.

特許文献2には、挟み込み検出の機能を備えたパワーウインドウ装置が記載されている。本文献では、窓の閉動作時に、モータの印加電圧を変化させることにより、モータ速度を目標値に維持する速度制御を原則的に実行し、モータ負荷またはその微分値が第1閾値よりも大きい第2閾値を超えると、挟み込みが発生したと判定して、窓を開動作に切り換えることで、挟み込み荷重の低い挟み込み防止機能を実現できるようにしている。   Patent Document 2 describes a power window device having a pinching detection function. In this document, speed control for maintaining the motor speed at the target value is executed in principle by changing the applied voltage of the motor when the window is closed, and the motor load or its differential value is larger than the first threshold value. When the second threshold value is exceeded, it is determined that pinching has occurred, and the window is switched to the opening operation, so that a pinching prevention function with a low pinching load can be realized.

ところで、スイッチの閉操作によりモータを正転させて窓を閉じている途中で、挟み込みが検出されると、モータを自動的に逆転させて窓を開く制御が行われるが、モータの回転方向が急に反転すると、そのときに発生する大きな電流がモータ駆動回路に流れ、駆動回路におけるスイッチング素子(リレーなど)の寿命が短くなる原因となる。また、窓を閉じている途中で、開操作を行ってモータを逆転させ、窓を開こうとした場合も、モータの回転方向が急に反転することから、上記と同様の問題が生じる。   By the way, when pinching is detected while the motor is rotated forward by closing the switch and the window is closed, the motor is automatically reversed to open the window. When suddenly reversed, a large current generated at that time flows to the motor drive circuit, which causes the life of a switching element (such as a relay) in the drive circuit to be shortened. Further, when the window is opened by performing an opening operation while the window is closed, the rotation direction of the motor is suddenly reversed to cause the same problem as described above.

そこで、特許文献3に記載されているように、モータの回転方向を反転する場合には、モータの両極を所定時間同電位に保持することにより、電磁誘導による制動力を発生させてモータを一旦停止させ、その後にモータを反転駆動するようにすれば、モータ反転時に大電流が発生することはなく、素子の寿命が短くなるのを抑制することができる。   Therefore, as described in Patent Document 3, when the rotation direction of the motor is reversed, both the motor poles are held at the same potential for a predetermined time, thereby generating a braking force by electromagnetic induction to temporarily turn off the motor. If the motor is stopped and then the motor is driven reversely, no large current is generated when the motor is reversed, and the life of the element can be suppressed from being shortened.

図24は、パワーウインドウ装置におけるモータ駆動ブロックを示す図である。1aはCPU、2はモータ制御回路、3は窓開閉用の直流モータである。CPU1aは、正転信号を出力するポートAと、逆転信号を出力するポートBとを有している。モータ制御回路2において、RY1は正転制御用のリレー、L1はリレーRY1のコイル、X1はリレーRY1の接点、Q1は正転制御用のトランジスタ、RY2は逆転制御用のリレー、L2はリレーRY2のコイル、X2はリレーRY2の接点、Q2は逆転制御用のトランジスタである。リレーRY1,RY2におけるNOは常開(Normal Open)接点、NCは常閉(Normal Close)接点である。A’はモータ3の一方の端子、B’はモータ3の他方の端子である。   FIG. 24 is a diagram showing a motor drive block in the power window device. 1a is a CPU, 2 is a motor control circuit, and 3 is a DC motor for opening and closing windows. The CPU 1a has a port A that outputs a normal rotation signal and a port B that outputs a reverse rotation signal. In the motor control circuit 2, RY1 is a forward rotation control relay, L1 is a coil of the relay RY1, X1 is a contact of the relay RY1, Q1 is a forward rotation control transistor, RY2 is a reverse rotation control relay, and L2 is a relay RY2. , X2 is a contact of relay RY2, and Q2 is a transistor for reverse rotation control. In relays RY1 and RY2, NO is a normally open contact, and NC is a normally closed contact. A ′ is one terminal of the motor 3, and B ′ is the other terminal of the motor 3.

図24の状態では、CPU1aのポートA,Bから信号は出力されておらず、トランジスタQ1,Q2はいずれもOFFしている。したがって、リレーRY1,RY2のコイルL1,L2に通電がされず、接点X1,X2は常閉(NC)側にあって、モータ3の両端子A’,B’が接地されて零電位となっているので、モータ3は停止している。   In the state of FIG. 24, no signal is output from the ports A and B of the CPU 1a, and the transistors Q1 and Q2 are both OFF. Therefore, the coils L1 and L2 of the relays RY1 and RY2 are not energized, the contacts X1 and X2 are on the normally closed (NC) side, and both terminals A ′ and B ′ of the motor 3 are grounded and become zero potential. Therefore, the motor 3 is stopped.

図25は、CPU1aのポートAから正転信号が出力された場合を示している。正転信号によりトランジスタQ1がONとなり、リレーRY1のコイルL1に電源+Vから通電がされるので、リレーRY1が動作して接点X1が常閉(NC)側から常開(NO)側に切り換わる。一方、トランジスタQ2はOFFのままであり、リレーRY2は動作しないので、接点X2は常閉(NC)側にある。この結果、電源+Vから接点X1、モータ3、接点X2を介して、矢印で示すように電流が流れ、モータ3が正転する。このとき、モータ3の一方の端子A’の電位は+Vであり、他方の端子B’の電位は零である。   FIG. 25 shows a case where a normal rotation signal is output from the port A of the CPU 1a. The transistor Q1 is turned on by the forward rotation signal, and the coil L1 of the relay RY1 is energized from the power source + V, so that the relay RY1 operates and the contact X1 is switched from the normally closed (NC) side to the normally open (NO) side. . On the other hand, since the transistor Q2 remains OFF and the relay RY2 does not operate, the contact X2 is on the normally closed (NC) side. As a result, a current flows from the power source + V through the contact X1, the motor 3, and the contact X2, as indicated by an arrow, and the motor 3 rotates in the forward direction. At this time, the potential of one terminal A 'of the motor 3 is + V, and the potential of the other terminal B' is zero.

図26は、CPU1aのポートBから逆転信号が出力された場合を示している。逆転信号によりトランジスタQ2がONとなり、リレーRY2のコイルL2に電源+Vから通電がされるので、リレーRY2が動作して接点X2が常閉(NC)側から常開(NO)側に切り換わる。一方、トランジスタQ1はOFFのままであり、リレーRY1は動作しないので、接点X1は常閉(NC)側にある。この結果、電源+Vから接点X2、モータ3、接点X1を介して、矢印で示すように電流が流れ、モータ3が逆転する。このとき、モータ3の一方の端子A’の電位は零であり、他方の端子B’の電位は+Vである。   FIG. 26 shows a case where a reverse rotation signal is output from the port B of the CPU 1a. The transistor Q2 is turned on by the reverse signal, and the coil L2 of the relay RY2 is energized from the power source + V, so that the relay RY2 operates and the contact X2 is switched from the normally closed (NC) side to the normally open (NO) side. On the other hand, since the transistor Q1 remains OFF and the relay RY1 does not operate, the contact X1 is on the normally closed (NC) side. As a result, a current flows from the power source + V through the contact X2, the motor 3, and the contact X1, as indicated by an arrow, and the motor 3 is reversed. At this time, the potential of one terminal A ′ of the motor 3 is zero, and the potential of the other terminal B ′ is + V.

図27は、CPU1aのポートA,Bから正転信号と逆転信号が同時に出力された場合を示している。この場合は、トランジスタQ1,Q2が共にONとなり、リレーRY1,RY2が動作して接点X1,X2が常閉(NC)側から常開(NO)側に切り換わる。この結果、モータ3の一方の端子A’と他方の端子B’の電位は、共に+Vで同電位となる。このため、モータ3には電流が供給されなくなり、回転していたモータ3は、回生制動がかかって停止する。   FIG. 27 shows a case where the normal rotation signal and the reverse rotation signal are simultaneously output from the ports A and B of the CPU 1a. In this case, the transistors Q1 and Q2 are both turned ON, and the relays RY1 and RY2 operate to switch the contacts X1 and X2 from the normally closed (NC) side to the normally open (NO) side. As a result, the potentials of one terminal A 'and the other terminal B' of the motor 3 are both + V and the same potential. For this reason, no current is supplied to the motor 3, and the rotating motor 3 is stopped due to regenerative braking.

図28および図29は、挟み込みがあった場合のモータ制御のタイミングチャートを示している。図28は正転信号を停止した後に逆転信号を出力する場合、図29は正転信号を停止する前に逆転信号を出力する場合のタイミングチャートである。図中、AはCPU1aのポートAから出力される正転信号、BはポートBから出力される逆転信号、A’はモータ3の一方の端子A’の電位、B’はモータ3の他方の端子B’の電位をそれぞれ表している。t1,t2,t3,…は、時刻を表している。   FIG. 28 and FIG. 29 show timing charts of motor control when there is pinching. FIG. 28 is a timing chart when the reverse rotation signal is output after stopping the normal rotation signal, and FIG. 29 is a timing chart when the reverse rotation signal is output before stopping the normal rotation signal. In the figure, A is a normal rotation signal output from the port A of the CPU 1a, B is a reverse rotation signal output from the port B, A 'is a potential of one terminal A' of the motor 3, and B 'is the other of the motor 3. Each potential of the terminal B ′ is shown. t1, t2, t3,... represent times.

図28において、t1でポートAから正転信号が出力されると、時間αだけ遅れてt2でリレーRY1がONし、モータ3が正転を開始する(図25)。その後、t3で挟み込みが検出されると、ポートAからの正転信号の出力が停止し、時間βだけ遅れてt4でリレーRY1がOFFする。このt4の時点から、リレーRY1,RY2は共にOFFとなり、モータ3の両端子A’,B’は接点X1,X2を介して接地される(図24)。この結果、両端子A’,B’が同電位となるため、正転しているモータ3に回生制動がかかって、モータ3は停止に至る。そして、t5でポートBから逆転信号が出力されると、時間αだけ遅れてt6でリレーRY2がONし、モータ3が逆転を開始する(図26)。そして、t7でポートBからの逆転信号の出力が停止すると、時間βだけ遅れてt8でリレーRY2がOFFし、この時点から一定時間後にモータ3は停止する。   In FIG. 28, when a normal rotation signal is output from port A at t1, relay RY1 is turned on at time t2 with a delay of time α, and motor 3 starts normal rotation (FIG. 25). Thereafter, when pinching is detected at t3, the output of the forward rotation signal from port A stops, and relay RY1 is turned off at time t4 with a delay of time β. From time t4, the relays RY1 and RY2 are both turned OFF, and both terminals A 'and B' of the motor 3 are grounded via the contacts X1 and X2 (FIG. 24). As a result, since both terminals A ′ and B ′ have the same potential, the regenerative braking is applied to the forwardly rotating motor 3 and the motor 3 stops. When a reverse rotation signal is output from port B at t5, the relay RY2 is turned on at time t6 with a delay of time α, and the motor 3 starts reverse rotation (FIG. 26). When the output of the reverse rotation signal from the port B stops at t7, the relay RY2 is turned off at t8 with a delay of time β, and the motor 3 stops after a certain time from this point.

一方、図29の場合は、モータ3が正転を開始した後、挟み込みが検出されたt3の時点で、ポートBから逆転信号が出力される。すなわち、ポートA,Bから正転信号と逆転信号が同時に出力される状態となる。そして、この時点から時間αだけ遅れてt4’でリレーRY2がONする。これにより、リレーRY1,RY2は共にONとなり、モータ3の両端子A’,B’は接点X1,X2を介して電源+Vに接続される(図27)。この結果、両端子A’,B’が同電位となるため、正転しているモータ3に回生制動がかかって、モータ3は停止に至る。そして、t5’でポートAからの正転信号を停止して、ポートBから逆転信号のみが出力される状態にすると、この時点から時間βだけ遅れてt6’でリレーRY1がOFFする。これにより、モータ3が逆転を開始する(図26)。そして、t7でポートBからの逆転信号の出力が停止すると、時間βだけ遅れてt8でリレーRY2がOFFし、この時点から一定時間後にモータ3は停止する。   On the other hand, in the case of FIG. 29, after the motor 3 starts normal rotation, a reverse rotation signal is output from the port B at time t3 when pinching is detected. That is, the normal rotation signal and the reverse rotation signal are simultaneously output from the ports A and B. Then, the relay RY2 is turned on at t4 'with a delay of time α from this point. As a result, the relays RY1 and RY2 are both turned on, and both terminals A 'and B' of the motor 3 are connected to the power source + V via the contacts X1 and X2 (FIG. 27). As a result, since both terminals A ′ and B ′ have the same potential, the regenerative braking is applied to the forwardly rotating motor 3 and the motor 3 stops. When the forward rotation signal from the port A is stopped at t5 'and only the reverse rotation signal is output from the port B, the relay RY1 is turned off at time t6' with a delay of time β from this point. Thereby, the motor 3 starts reverse rotation (FIG. 26). When the output of the reverse rotation signal from the port B stops at t7, the relay RY2 is turned off at t8 with a delay of time β, and the motor 3 stops after a certain time from this point.

ところで、リレーの動作特性として、OFFからONとなる場合の動作時間(コイルに通電されてから可動接点が常開接点と接触するまでの時間)αと、ONからOFFとなる場合の動作時間(コイルの通電が断たれてから可動接点が常閉接点と接触するまでの時間)βとを比較した場合、α<βの関係にあることが知られている。これは、OFFからONの場合は、コイルの励磁によって発生する磁気吸引力により可動鉄片が直ちに固定鉄心に吸着されるのに対し、ONからOFFの場合は、コイルの励磁を解いても固定鉄心には残留磁気が残り、これが原因で可動鉄片が固定鉄心から離れるまでに時間がかかるためである。特に、コイルと並列に逆起電力吸収用のフライホイールダイオードが接続されている場合は、当該ダイオードに回生電流が流れる間、コイルが励磁状態を維持するので、OFFするまでの時間が長くなる。   By the way, as the operation characteristics of the relay, the operation time when turning from OFF to ON (the time from when the coil is energized until the movable contact comes into contact with the normally open contact) α and the operation time when turning from ON to OFF ( It is known that the relation of α <β is established when β is compared with the time (between the time when the coil is turned off until the movable contact comes into contact with the normally closed contact). In the case of OFF to ON, the movable iron piece is immediately attracted to the fixed iron core by the magnetic attractive force generated by the excitation of the coil. On the other hand, in the case of ON to OFF, the fixed iron core is released even if the coil is de-energized. This is because residual magnetism remains in the magnetic iron and it takes time for the movable iron piece to move away from the fixed iron core. In particular, when a flywheel diode for back electromotive force absorption is connected in parallel with the coil, the coil maintains an excited state while a regenerative current flows through the diode, so that the time until turning off becomes longer.

そこで、図28と図29とを比べてみると、図28においては、挟み込みが検出されたt3の時点で正転信号が停止し、これとほぼ同時にリレーRY1のコイルL1の通電が断たれるが、この時点からリレーRY1が実際にOFFするt4まで、すなわち接点X1が常閉(NC)側に切り換わってモータ3に制動がかかるまでにはβの時間を要する。このため、挟み込みが検出されてからモータ3が逆転を開始するまでの時間τ1が長くなり、挟み込みの解除を迅速に行えないことになる。これに対して、図29の場合は、挟み込みが検出されたt3の時点で逆転信号を出力し、t4’でリレーRY1,RY2の両方をON状態にしてモータ3に制動をかけており、挟み込みが検出されてからモータ3に制動がかかるまでの時間はαとなる。上述したようにα<βであるから、図29の制御のほうが、モータ3に制動がかかるタイミングを早めて、挟み込みが検出されてからモータ3が逆転を開始するまでの時間τ2を短くでき、挟み込みの解除を迅速に行うことができる。   Therefore, comparing FIG. 28 with FIG. 29, in FIG. 28, the forward rotation signal is stopped at the time t3 when the pinching is detected, and the energization of the coil L1 of the relay RY1 is cut off almost simultaneously with this. However, from this time until t4 when the relay RY1 is actually turned off, that is, until the contact X1 is switched to the normally closed (NC) side and the motor 3 is braked, β time is required. For this reason, the time τ1 from when the pinching is detected until the motor 3 starts reverse rotation becomes longer, and the pinching cannot be released quickly. On the other hand, in the case of FIG. 29, the reverse rotation signal is output at the time t3 when the pinching is detected, and both the relays RY1 and RY2 are turned on at t4 ′ to brake the motor 3, and the pinching is performed. The time from when the motor is detected until the motor 3 is braked is α. Since α <β as described above, the control in FIG. 29 can shorten the timing at which the motor 3 is braked, and shorten the time τ2 from when the pinching is detected until the motor 3 starts reverse rotation. It is possible to quickly release the pinching.

しかしながら、図29の制御を行う場合は、モータ3に制動をかけるためにリレーRY1,RY2を共に動作状態(ON状態)にする必要があることから、以下のような問題が生じる。   However, when the control shown in FIG. 29 is performed, the relays RY1 and RY2 both need to be in an operating state (ON state) in order to brake the motor 3, which causes the following problems.

図30は、リレーの接点開閉時におけるアークの発生を説明する図である。(a)のように、可動接点が常閉接点に接触して破線のように電流が流れている状態から、(b)のように、可動接点が常閉接点側から常開接点側に切り換わって電流を遮断する場合、可動接点と常閉接点との間にアークが発生し、このアークによって接点が消耗し、これがリレーの寿命を縮める要因となる。特に、図のように接点が常閉側から常開側に切り換わる場合は、接点が常開側から常閉側に切り換わる場合に比べて、アークが発生しやすい。これは、常開側から常閉側への切換時には、リレーの可動鉄片はひとたび固定鉄心から離れてしまえばスプリングの力で速やかに復帰するので、接点の切換速度が早くアークを遮断しやすいのに対し、常閉側から常開側への切換時には、可動鉄片をスプリングの弾性力に抗して電磁力で吸引しなければならないため、接点の切換速度が遅くアークを遮断しにくいためである。   FIG. 30 is a diagram for explaining the generation of an arc when the relay contacts are opened and closed. As shown in (a), the movable contact contacts the normally closed contact and the current flows as shown by the broken line, and as shown in (b), the movable contact is switched from the normally closed contact side to the normally open contact side. When the current is interrupted instead, an arc is generated between the movable contact and the normally closed contact, and the contact is consumed by this arc, which becomes a factor of shortening the life of the relay. In particular, when the contact is switched from the normally closed side to the normally open side as shown in the figure, an arc is more likely to occur than when the contact is switched from the normally open side to the normally closed side. This is because, when switching from the normally open side to the normally closed side, once the movable iron piece of the relay moves away from the fixed core, it quickly returns with the force of the spring, so the contact switching speed is fast and the arc is easily interrupted. On the other hand, at the time of switching from the normally closed side to the normally open side, the movable iron piece must be attracted by electromagnetic force against the elastic force of the spring, so the switching speed of the contact is slow and it is difficult to interrupt the arc. .

このことから、図25の正転状態において、リレーRY2の接点X2は、常閉接点NCと接触して電流が流れているので、この状態から図27のように、リレーRY2を動作させて接点X2を常開接点NO側に切り換えると、この切換時、すなわち図29のt4’の時点において、接点X2と常閉接点NC間にアークが発生し、接点が消耗する。このように、モータ3が逆転するタイミングを早めるために、リレーRY1,RY2の双方を動作させて回生制動をかけようとすると、リレーRY2の接点がアークにより消耗し、リレー寿命に影響を与えることになる。   Therefore, in the forward rotation state of FIG. 25, the contact X2 of the relay RY2 is in contact with the normally closed contact NC, and the current flows. From this state, the relay RY2 is operated as shown in FIG. When X2 is switched to the normally open contact NO side, an arc is generated between the contact X2 and the normally closed contact NC at the time of this switching, that is, at time t4 ′ in FIG. 29, and the contact is consumed. As described above, if the regenerative braking is applied by operating both of the relays RY1 and RY2 in order to advance the timing of the reverse rotation of the motor 3, the contact of the relay RY2 is consumed by the arc, which affects the life of the relay. become.

なお、図28の制御の場合は、リレーRY1,RY2が同時にONとなることはないので、接点切換時のアークによるリレー寿命短縮の問題は生じない。すなわち、t6でリレーRY2の接点X2が常開接点NO側に切り換わる場合は、図26の状態となり、接点X2が常閉接点NC側にあるときは、接点X1が常開接点NO側に切り換わっていないので、接点X2には電流が流れていない。したがって、接点X2が常閉接点NCから常開接点NOへ切り換わっても、接点X2にアークが発生することはない。   In the case of the control of FIG. 28, the relays RY1 and RY2 are not simultaneously turned on, so that there is no problem of shortening the relay life due to arcing at the time of switching the contacts. That is, when the contact X2 of the relay RY2 switches to the normally open contact NO side at t6, the state shown in FIG. 26 is obtained. When the contact X2 is on the normally closed contact NC side, the contact X1 switches to the normally open contact NO side. Since no change has been made, no current flows through the contact X2. Therefore, even when the contact X2 is switched from the normally closed contact NC to the normally open contact NO, no arc is generated at the contact X2.

接点寿命を予測してリレーの交換時期を報知する技術が、特許文献4に開示されている。本技術では、リレー接点の開閉回数を計測するとともに、リレー接点に流れる電流および接点に印加される電圧を測定し、測定した電流・電圧の値に基づいて、メーカから提供されているリレー寿命に関するデータを補正する。そして、開閉回数のカウント値を寿命データの補正値に基づいて補正し、補正後のカウント値が所定値に達すると、リレー交換を指示する信号を出力するようにしている。しかし、この特許文献4には、上述したようなモータの正転・逆転制御において、2つのリレーを同時にON状態にしてモータに制動をかける場合の問題点とその対策について開示がない。また、本文献の方法によると、多種のデータを計測する必要があり、補正処理も複雑になるという問題がある。   A technique for predicting the contact life and notifying the relay replacement time is disclosed in Patent Document 4. In this technology, the number of times the relay contact is opened and closed is measured, and the current flowing through the relay contact and the voltage applied to the contact are measured. Based on the measured current and voltage values, the relay life provided by the manufacturer is related. Correct the data. Then, the count value of the number of times of opening / closing is corrected based on the correction value of the life data, and when the corrected count value reaches a predetermined value, a signal instructing relay replacement is output. However, this Patent Document 4 does not disclose problems and countermeasures in the case where the two relays are simultaneously turned on to brake the motor in the forward / reverse control of the motor as described above. Further, according to the method of this document, it is necessary to measure various kinds of data, and there is a problem that the correction processing becomes complicated.

また、以上述べた以外にも、モータの正転・逆転制御においては、例えば開閉体を上限位置と下限位置間で移動させる場合に、上限位置または下限位置でモータがロック状態(モータが回転せず通電だけが行われる状態)になると、モータに大電流が流れて接点の負荷が増大し、これがリレー寿命の低下の原因となることがある。   In addition to the above, in forward / reverse rotation control of the motor, for example, when the opening / closing body is moved between the upper limit position and the lower limit position, the motor is locked at the upper limit position or the lower limit position (the motor is not rotated). In a state where only energization is performed), a large current flows through the motor and the load on the contact increases, which may cause a decrease in the relay life.

特開2001−118465号公報JP 2001-118465 A 特許第3835522号公報Japanese Patent No. 3835522 実用新案登録第2589589号公報Utility Model Registration No. 2589589 実開平5−11277号公報Japanese Utility Model Publication No. 5-11277

そこで、本発明の課題は、簡単な手段によってリレーなどのスイッチング素子の寿命を正確に検知して警告を行うことができるモータ制御装置を提供することにある。   SUMMARY OF THE INVENTION An object of the present invention is to provide a motor control device that can accurately detect the life of a switching element such as a relay and issue a warning by simple means.

本発明に係るモータ制御装置は、モータを正転および逆転させるための正転信号および逆転信号を出力する制御部と、正転信号および逆転信号に基づいて動作するスイッチング素子により、モータに流す電流の方向を切り換えて、当該モータを駆動するモータ駆動回路とを備えたモータ制御装置であって、モータの回転状態が変化する際、スイッチング素子の寿命に影響を与えるような大きな負荷が当該素子に発生した場合に、その発生回数を計数する計数手段と、この計数手段により計数された回数に基づいて、スイッチング素子の寿命に対する警告を出力する出力手段とを更に備える。   The motor control device according to the present invention includes a control unit that outputs a normal rotation signal and a reverse rotation signal for normal rotation and reverse rotation of the motor, and a current that flows through the motor by a switching element that operates based on the normal rotation signal and the reverse rotation signal. The motor control device includes a motor drive circuit that drives the motor by switching the direction of the motor, and when the rotation state of the motor changes, a large load that affects the life of the switching element is applied to the element. In the case of occurrence, it further comprises counting means for counting the number of occurrences, and output means for outputting a warning for the life of the switching element based on the number counted by the counting means.

このようにすると、モータの回転状態が変化する際(例えば回転方向の反転時)に、スイッチング素子の寿命に影響を与える大負荷(例えばアークや大電流)が発生した場合、その発生回数が計数され、これに基づいてスイッチング素子の寿命に対する警告が出力される。このため、スイッチング素子の寿命を報知して交換を促すことができ、素子の故障による誤動作などのトラブルを未然に防止することができる。また、回数を計数するだけでよいので、制御部での処理が簡単となり、メモリの容量も少なくて済む。   In this way, when a large load (for example, arc or large current) that affects the life of the switching element occurs when the rotation state of the motor changes (for example, when the rotation direction is reversed), the number of occurrences is counted. Based on this, a warning for the life of the switching element is output. For this reason, the life of the switching element can be notified to prompt replacement, and troubles such as malfunction due to element failure can be prevented in advance. Further, since it is only necessary to count the number of times, the processing in the control unit is simplified, and the memory capacity can be reduced.

このような本発明の具体例として、モータにより駆動される開閉体の開動作および閉動作を指示する操作スイッチと、開閉体の閉動作中に、当該開閉体に物体が挟み込まれたことを検出する挟み込み検出手段とを更に備えた構成が考えられる。この場合、計数手段は、挟み込み検出手段により検出された挟み込みの発生回数を計数し、計数手段の計数値に対する閾値が予め設定されており、出力手段は、計数手段の計数値が閾値を超えた場合に、警告を出力する。   As a specific example of the present invention, an operation switch for instructing an opening and closing operation of an opening / closing body driven by a motor, and detecting that an object has been caught in the opening / closing body during the closing operation of the opening / closing body It is conceivable to further include a pinching detection means. In this case, the counting means counts the number of occurrences of pinching detected by the pinching detection means, a threshold value for the count value of the counting means is set in advance, and the output means has a count value of the counting means exceeding the threshold value. In that case, a warning is output.

これによると、挟み込みが検出されてモータを速やかに停止させる必要がある場合に、モータに制動をかけるためにスイッチング素子に大きな負荷が発生すると、その発生回数を計数して当該計数値が閾値を超えた場合に警告が出力されるので、挟み込みに起因するスイッチング素子の寿命低下に対し、誤動作などのトラブルを未然に防止することができる。   According to this, when pinching is detected and it is necessary to stop the motor promptly, if a large load is generated in the switching element to brake the motor, the number of occurrences is counted and the count value becomes the threshold value. Since the warning is output when exceeding, troubles such as malfunction can be prevented in advance against the life reduction of the switching element due to the pinching.

より具体的には、スイッチング素子は、正転信号により動作して第1の接点が切り換わる第1のリレーと、逆転信号により動作して第2の接点が切り換わる第2のリレーとからなり、第1の接点が切り換わることにより、モータの一方の端子が第1の接点を介して電源と接続されてモータが正転する一方、第2の接点が切り換わることにより、モータの他方の端子が第2の接点を介して電源と接続されてモータが逆転するような構成とすることができる。この場合、制御部は、挟み込みが検出されると、正転信号と逆転信号を同時に出力して第1および第2のリレーを共に動作させ、第1および第2の接点を介して電源電圧によりモータの両端子を高電位で同電位に保持してモータの正転を停止させ、その後、正転信号の出力を停止し逆転信号のみを出力することによりモータを逆転させる。   More specifically, the switching element includes a first relay that operates by a forward rotation signal to switch the first contact, and a second relay that operates by a reverse rotation signal to switch the second contact. When the first contact is switched, one terminal of the motor is connected to the power supply via the first contact and the motor rotates normally, while the second contact is switched, the other terminal of the motor The terminal can be connected to the power supply via the second contact so that the motor can be reversed. In this case, when the pinching is detected, the control unit outputs the normal rotation signal and the reverse rotation signal at the same time to operate both the first and second relays, and the power supply voltage is supplied via the first and second contacts. Both terminals of the motor are held at the same potential at a high potential to stop the forward rotation of the motor, and then the output of the forward rotation signal is stopped and only the reverse rotation signal is output to reverse the motor.

これによると、正転信号と逆転信号を同時に出力して2つのリレーを共に動作させ、それぞれの接点を介してモータの両端子を高電位で同電位に保持することで、モータに制動がかかるタイミングを早めて、挟み込み検出からモータ逆転までの時間を短くすることができる。この結果、挟み込みを迅速に解除することができる。   According to this, the forward rotation signal and the reverse rotation signal are output simultaneously to operate the two relays together, and the motor is braked by holding both terminals of the motor at the same potential at a high potential via the respective contacts. It is possible to shorten the time from pinching detection to motor reverse rotation by advancing the timing. As a result, the pinching can be quickly released.

また、制御部は、出力手段が警告を出力した場合、第1および第2のリレーを共に非動作状態にして、第1および第2の接点を介してモータの両端子を低電位で同電位に保持し、一定時間経過後に逆転信号を出力して第2のリレーを動作させるようにしてもよい。   In addition, when the output means outputs a warning, the control unit deactivates both the first and second relays and sets both terminals of the motor to the same potential at the low potential via the first and second contacts. And the second relay may be operated by outputting a reverse rotation signal after a predetermined time has elapsed.

これによると、警告が出力されない場合は、正転信号と逆転信号を同時に出力してモータの両端電位を高電位で同電位とすることで、挟み込み検出からモータ逆転までの時間を短くし、迅速な挟み込み解除を行うことができる。一方、警告が出力された場合は、正転信号を停止してモータの両端電位を低電位で同電位とし、一定時間後に逆転信号を出力することで、リレー接点にアークが発生するのを回避し、リレーの寿命がそれ以上短くならないようにすることができる。   According to this, when the warning is not output, the forward rotation signal and the reverse rotation signal are output at the same time, and the potentials at both ends of the motor are set to the same potential at a high potential, thereby shortening the time from the pinch detection to the motor reverse rotation. Can be released. On the other hand, when a warning is output, the forward rotation signal is stopped, the electric potentials at both ends of the motor are set to the same potential at a low potential, and a reverse rotation signal is output after a certain time, thereby avoiding the occurrence of an arc at the relay contact. In addition, the life of the relay can be prevented from becoming shorter.

また、制御部は、挟み込み検出時以外でモータを逆転させる場合、第1および第2のリレーを共に非動作状態にして、第1および第2の接点を介してモータの両端子を低電位で同電位に保持し、一定時間経過後に逆転信号を出力して第2のリレーを動作させるようにしてもよい。   In addition, when reversing the motor at a time other than when pinching is detected, the control unit sets both the first and second relays to the non-operating state, and sets both terminals of the motor at a low potential via the first and second contacts. The second relay may be operated by holding the same potential and outputting a reverse rotation signal after a predetermined time has elapsed.

通常、挟み込みが発生する頻度はそれほど高くないので、挟み込み検出時以外でモータを逆転する場合は、上記のような制御とすることで、第1および第2のリレーが共に動作状態となる回数が必要最小限に抑えられ、これによってアークによる接点の摩耗を極力少なくすることができる。   Normally, the frequency of pinching is not so high, and when the motor is rotated in reverse except when pinching is detected, the number of times that both the first and second relays are in the operating state can be controlled by the above control. This minimizes the wear of the contacts caused by the arc as much as possible.

また、本発明の他の具体例として、計数手段は、モータの回転方向を反転させる際にモータの両端子を同電位にしてモータに回生制動をかけた回数を計数する計数手段であって、モータの両端子が低電位で同電位となった回数を計数する第1の計数手段と、モータの両端子が高電位で同電位となった回数を計数する第2の計数手段とからなる構成が考えられる。この場合、第1の計数手段の計数値に対する閾値が予め設定されており、第2の計数手段の計数値に基づいて閾値を変更し、出力手段は、第1の計数手段の計数値が変更後の閾値を超えた場合に、警告を出力するようにしてもよい。   As another specific example of the present invention, the counting means is a counting means for counting the number of times that the motor is subjected to regenerative braking with both terminals of the motor having the same potential when reversing the rotation direction of the motor, A first counting means for counting the number of times that both terminals of the motor are at the same potential at a low potential, and a second counting means for counting the number of times that both terminals of the motor are at the same potential at a high potential. Can be considered. In this case, a threshold value for the count value of the first counting means is preset, the threshold value is changed based on the count value of the second counting means, and the output means changes the count value of the first counting means. A warning may be output when a later threshold value is exceeded.

これによると、モータの両端を低電位で同電位にして回生制動をかけた回数と、高電位で同電位にして回生制動をかけた回数とを、区別して計数することができる。また、第1の計数手段の計数値に対して設定された閾値を、第2の計数手段の計数値に基づいて変更するようにすれば、モータの両端を高電位で同電位にして回生制動をかけた回数に応じて閾値が変更されるので、閾値が寿命低下の要因発生を反映した適正な値となり、スイッチング素子の寿命を正確に検出して警告を出力することができる。   According to this, it is possible to distinguish and count the number of times that regenerative braking is performed with both ends of the motor at the same potential at a low potential and the number of times that regenerative braking is applied with the same potential at a high potential. Further, if the threshold set for the count value of the first counting means is changed based on the count value of the second counting means, both ends of the motor are set to the same potential at a high potential and regenerative braking is performed. Since the threshold value is changed according to the number of times applied, the threshold value becomes an appropriate value reflecting the cause of the decrease in the lifetime, and the warning can be output by accurately detecting the lifetime of the switching element.

また、本発明の他の具体例として、モータにより駆動される開閉体の開動作および閉動作を指示する操作スイッチと、開閉体が原点位置にある場合にモータのロック状態を検出するロック検出手段とを更に備え、計数手段は、開閉体の駆動回数を計数する第3の計数手段と、モータのロック状態が検出された回数を計数する第4の計数手段とからなる構成が考えられる。この場合、第3の計数手段の計数値に対する閾値が予め設定されており、第4の計数手段の計数値に基づいて閾値を変更し、出力手段は、第3の計数手段の計数値が変更後の閾値を超えた場合に、警告を出力する。   As another specific example of the present invention, an operation switch for instructing an opening and closing operation of an opening / closing body driven by a motor, and a lock detection means for detecting a lock state of the motor when the opening / closing body is at the origin position The counting means may include a third counting means that counts the number of times the opening / closing body is driven and a fourth counting means that counts the number of times the locked state of the motor is detected. In this case, a threshold value for the count value of the third counting means is set in advance, the threshold value is changed based on the count value of the fourth counting means, and the output means changes the count value of the third counting means. When the later threshold is exceeded, a warning is output.

これによると、モータにより開閉体を駆動した回数に対する閾値が、モータにロック状態が発生した回数に応じて変更されるので、閾値が寿命低下の要因発生を反映した適正な値となり、スイッチング素子の寿命を正確に検出して警告を出力することができる。   According to this, since the threshold for the number of times that the opening / closing body is driven by the motor is changed according to the number of times the motor is locked, the threshold becomes an appropriate value reflecting the occurrence of the cause of the life reduction, and the switching element It is possible to accurately detect the life and output a warning.

本発明によれば、簡単な手段によってスイッチング素子の寿命を正確に検知して警告を出力することができ、素子の寿命に伴う装置の故障を未然に防止することが可能となる。   According to the present invention, it is possible to accurately detect the life of the switching element by a simple means and output a warning, and it is possible to prevent a failure of the apparatus accompanying the life of the element.

図1は、本発明をパワーウインドウ装置に適用した場合の実施形態を示すブロック図である。1はCPUを含む制御部、2はモータ3を駆動するモータ駆動回路、4はモータ3の回転に同期したパルスを出力するロータリエンコーダ、5はロータリエンコーダ4から出力されるパルスを検出するパルス検出回路、6はROMやRAM等から構成されるメモリ、7は窓の開動作および閉動作を指示する操作スイッチ、8はモータ駆動回路2におけるリレー(後述)の寿命を警告するランプである。メモリ6には、リレーの寿命に関して予め設定された閾値61が記憶されているとともに、所定のデータを計数するカウンタ62が備わっている。制御部1は本発明における挟み込み検出手段の一実施形態を構成し、カウンタ62は本発明における計数手段の一実施形態を構成している。また、ランプ8は本発明における出力手段の一実施形態を構成している。   FIG. 1 is a block diagram showing an embodiment when the present invention is applied to a power window device. 1 is a control unit including a CPU, 2 is a motor drive circuit that drives a motor 3, 4 is a rotary encoder that outputs a pulse synchronized with the rotation of the motor 3, and 5 is a pulse detector that detects a pulse output from the rotary encoder 4. A circuit, 6 is a memory composed of a ROM, a RAM, and the like, 7 is an operation switch for instructing an opening operation and a closing operation of a window, and 8 is a lamp for warning a life of a relay (described later) in the motor drive circuit 2. The memory 6 stores a preset threshold 61 for the life of the relay, and includes a counter 62 that counts predetermined data. The control unit 1 constitutes an embodiment of the pinch detection means in the present invention, and the counter 62 constitutes an embodiment of the counting means in the present invention. The lamp 8 constitutes an embodiment of output means in the present invention.

モータ駆動回路2の構成は、図24に示したものと同じである。リレーRY1,RY2はそれぞれ本発明における第1のリレー、第2のリレーの一実施形態を構成し、接点X1,X2はそれぞれ本発明における第1の接点、第2の接点の一実施形態を構成している。また、制御部1は、図24に示すCPU1aを備えている。以下では、図24〜図29を本発明の実施形態として引用する。   The configuration of the motor drive circuit 2 is the same as that shown in FIG. The relays RY1 and RY2 constitute one embodiment of the first relay and the second relay in the present invention, respectively, and the contacts X1 and X2 constitute one embodiment of the first contact and the second contact in the present invention, respectively. is doing. Moreover, the control part 1 is provided with CPU1a shown in FIG. In the following, FIGS. 24 to 29 are cited as embodiments of the present invention.

図1において、操作スイッチ7を操作すると、制御部1に窓開閉指令が与えられる。これを受けて、制御部1のCPU1aは、図25、図26で説明したように、正転信号(窓閉の場合)または逆転信号(窓開の場合)を出力し、モータ駆動回路2によりモータ3が正転または逆転する。モータ3の回転により、モータ3と連動する窓開閉機構(後述)が作動して窓100の開閉が行われる。パルス検出回路5はロータリエンコーダ4から出力されるパルスを検出し、制御部1はこの検出結果に基づき窓100の開閉量やモータ3の回転速度を算出して、モータ3の回転を制御する。   In FIG. 1, when the operation switch 7 is operated, a window opening / closing command is given to the control unit 1. In response to this, the CPU 1a of the control unit 1 outputs a forward rotation signal (when the window is closed) or a reverse rotation signal (when the window is opened) as described with reference to FIGS. The motor 3 rotates forward or backward. As the motor 3 rotates, a window opening / closing mechanism (described later) linked to the motor 3 operates to open / close the window 100. The pulse detection circuit 5 detects a pulse output from the rotary encoder 4, and the control unit 1 controls the rotation of the motor 3 by calculating the opening / closing amount of the window 100 and the rotation speed of the motor 3 based on the detection result.

図2は、操作スイッチ7の一例を示した概略構成図である。操作スイッチ7は、軸75を中心としてab方向に回転可能な操作ノブ71と、この操作ノブ71と一体に設けられたロッド72と、公知のスライドスイッチ73とから構成される。74はスライドスイッチ73のアクチュエータ、20は操作スイッチ7が組み込まれるスイッチユニットのカバーである。ロッド72の下端は、スライドスイッチ73のアクチュエータ74と係合しており、操作ノブ71がab方向に回転すると、ロッド72を介してアクチュエータ74がa’b’方向に移動し、その移動位置に応じてスライドスイッチ73の接点(図示省略)が切り換えられる。   FIG. 2 is a schematic configuration diagram illustrating an example of the operation switch 7. The operation switch 7 includes an operation knob 71 that can rotate in the ab direction around a shaft 75, a rod 72 that is provided integrally with the operation knob 71, and a known slide switch 73. 74 is an actuator of the slide switch 73, and 20 is a cover of the switch unit in which the operation switch 7 is incorporated. The lower end of the rod 72 is engaged with the actuator 74 of the slide switch 73, and when the operation knob 71 rotates in the ab direction, the actuator 74 moves in the a′b ′ direction via the rod 72 and reaches its moving position. Accordingly, the contacts (not shown) of the slide switch 73 are switched.

操作ノブ71は、オート閉AC、マニュアル閉MC、中立N、マニュアル開MO、オート開AOの各位置へ切換可能となっている。図2は、操作ノブ71が中立Nの位置にある状態を示している。この位置から操作ノブ71をa方向に一定量回転させて、マニュアル閉MCの位置にすると、マニュアルモードで窓が閉じるマニュアル閉動作が行われ、この位置よりさらにa方向に操作ノブ71を回転させてオート閉ACの位置にすると、オートモードで窓が閉じるオート閉動作が行われる。また、操作ノブ71を中立Nの位置からb方向に一定量回転させて、マニュアル開MOの位置にすると、マニュアルモードで窓が開くマニュアル開動作が行われ、この位置よりさらにb方向に操作ノブ71を回転させてオート開AOの位置にすると、オートモードで窓が開くオート開動作が行われる。操作ノブ71には、図示しないバネが設けられており、回転した操作ノブ71から手を離すと、操作ノブ71はバネの力により中立Nの位置に復帰する。   The operation knob 71 can be switched to each position of auto-close AC, manual close MC, neutral N, manual open MO, and auto open AO. FIG. 2 shows a state in which the operation knob 71 is in the neutral N position. When the operation knob 71 is rotated a certain amount in the direction a from this position to the manual closing MC position, a manual closing operation is performed to close the window in the manual mode, and the operation knob 71 is further rotated in the direction a from this position. When the auto-close AC position is set, an auto-close operation is performed to close the window in the auto mode. Further, when the operation knob 71 is rotated by a certain amount in the b direction from the neutral N position to the manual opening MO position, a manual opening operation for opening the window in the manual mode is performed, and the operation knob is further moved in the b direction from this position. When 71 is rotated to the automatic opening AO position, an automatic opening operation is performed in which the window is opened in the automatic mode. The operation knob 71 is provided with a spring (not shown), and when the hand is released from the rotated operation knob 71, the operation knob 71 returns to the neutral N position by the force of the spring.

マニュアルモードの場合は、操作ノブ71がマニュアル閉MCまたはマニュアル開MOの位置に手で保持され続ける間だけ、窓の閉動作または開動作が行われ、操作ノブ71から手を離してノブが中立Nの位置に復帰すると、窓の閉動作または開動作は停止する。これに対して、オートモードの場合は、一旦、操作ノブ71がオート閉ACまたはオート開AOの位置まで操作されると、その後は操作ノブ71から手を離してノブが中立Nの位置に復帰しても、窓の閉動作または開動作が継続して行われる。   In the manual mode, the window closing or opening operation is performed only while the operation knob 71 is held by hand in the manual closing MC or manual opening MO position. When returning to the N position, the window closing or opening operation stops. On the other hand, in the case of the auto mode, once the operation knob 71 is operated to the position of auto-close AC or auto-open AO, after that, the hand is released from the operation knob 71 and the knob returns to the neutral N position. Even then, the window closing or opening operation is continued.

図3は、車両の各窓に設けられる窓開閉機構の一例を示した図である。100は自動車の窓、101は窓100を開閉する窓ガラス、102は窓開閉機構である。窓ガラス101は、窓開閉機構102の作動により昇降動作を行い、窓ガラス101の上昇により窓100が閉じ、窓ガラス101の下降により窓100が開く。窓ガラス101は、本発明における開閉体の一実施形態を構成する。窓開閉機構102において、103は窓ガラス101の下端に取り付けられた支持部材である。104は一端が支持部材103に係合され、他端がブラケット106に回転可能に支持された第1アーム、105は一端が支持部材103に係合され、他端がガイド部材107に係合された第2アームである。第1アーム104と第2アーム105とは、それぞれの中間部において軸を介して連結されている。3は前述のモータ、4は前述のロータリエンコーダである。ロータリエンコーダ4はモータ3の回転軸に連結されており、モータ3の回転量に比例した数のパルスを出力する。所定時間内にロータリエンコーダ4から出力されるパルスを計数することにより、モータ3の回転速度を検出することができる。また、ロータリエンコーダ4の出力から、モータ3の回転量(窓ガラス101の移動量)を算出することができる。   FIG. 3 is a view showing an example of a window opening / closing mechanism provided in each window of the vehicle. Reference numeral 100 denotes an automobile window, 101 denotes a window glass for opening and closing the window 100, and 102 denotes a window opening / closing mechanism. The window glass 101 moves up and down by the operation of the window opening / closing mechanism 102, the window 100 is closed when the window glass 101 is raised, and the window 100 is opened when the window glass 101 is lowered. Window glass 101 constitutes an embodiment of an opening / closing body in the present invention. In the window opening / closing mechanism 102, 103 is a support member attached to the lower end of the window glass 101. 104 is a first arm whose one end is engaged with the support member 103, and the other end is rotatably supported by the bracket 106. 105 is one end engaged with the support member 103, and the other end is engaged with the guide member 107. Second arm. The 1st arm 104 and the 2nd arm 105 are connected via the axis | shaft in each intermediate part. 3 is the motor described above, and 4 is the rotary encoder described above. The rotary encoder 4 is connected to the rotating shaft of the motor 3 and outputs a number of pulses proportional to the amount of rotation of the motor 3. The rotational speed of the motor 3 can be detected by counting the pulses output from the rotary encoder 4 within a predetermined time. Further, the amount of rotation of the motor 3 (the amount of movement of the window glass 101) can be calculated from the output of the rotary encoder 4.

109はモータ3により回転駆動されるピニオン、110はピニオン109と噛合して回転する扇形のギヤである。ギヤ110は、第1アーム104に固定されている。モータ3は正逆方向に回転可能であり、正逆方向への回転によりピニオン109およびギヤ110を回転させて、第1アーム104を正逆方向へ回動させる。これに追随して、第2アーム105の他端がガイド部材107の溝に沿って横方向にスライドし、支持部材103が上下方向に移動して窓ガラス101を昇降させ、窓100を開閉する。   Reference numeral 109 denotes a pinion that is rotationally driven by the motor 3, and 110 denotes a fan-shaped gear that meshes with the pinion 109 and rotates. The gear 110 is fixed to the first arm 104. The motor 3 can rotate in the forward and reverse directions, and rotates the pinion 109 and the gear 110 by rotating in the forward and reverse directions to rotate the first arm 104 in the forward and reverse directions. Following this, the other end of the second arm 105 slides laterally along the groove of the guide member 107, and the support member 103 moves up and down to raise and lower the window glass 101, thereby opening and closing the window 100. .

以上のようなパワーウインドウ装置において、操作ノブ71が図2のオート閉ACまたはマニュアル閉MCの位置にあって閉動作が行われる場合は、物体の挟み込みを検出する機能が備わっている。すなわち、図4に示したように、窓100が閉まる途中で窓ガラス101の隙間に物体Zが挟み込まれた場合、物体Zが損傷するのを防ぐため、挟み込みを検知して窓100の閉動作を開動作へ自動的に切り換えるようになっている。   In the power window device as described above, when the operation knob 71 is at the position of the automatic closing AC or the manual closing MC in FIG. 2 and the closing operation is performed, a function of detecting the object pinching is provided. That is, as shown in FIG. 4, when the object Z is sandwiched in the gap between the window glasses 101 while the window 100 is closed, in order to prevent the object Z from being damaged, the sandwiching operation is detected and the window 100 is closed. Is automatically switched to open operation.

挟み込みの検出にあたっては、パルス検出回路5の出力であるモータ3の回転速度を制御部1が随時読み込み、現在の回転速度と以前の回転速度とを比較して、その比較結果に基づいて挟み込みの有無を判定する。図4のように窓100に物体Zの挟み込みが発生すると、モータ3の負荷が増大して回転速度が低下するため、速度の変化量が大きくなり、この速度変化量が所定値を超えたときに、物体Zが挟み込まれたと判定する。   In detecting pinching, the controller 1 reads the rotational speed of the motor 3 that is the output of the pulse detection circuit 5 as needed, compares the current rotational speed with the previous rotational speed, and based on the comparison result, Determine presence or absence. When the object Z is caught in the window 100 as shown in FIG. 4, the load of the motor 3 increases and the rotational speed decreases, so that the amount of change in speed increases and the amount of change in speed exceeds a predetermined value. Then, it is determined that the object Z is sandwiched.

図5は、本発明の実施形態に係るパワーウインドウ装置の基本的な動作を示したフローチャートである。図中の「SW」は「操作スイッチ7」を表している(以下の図6〜図11のフローチャートにおいても同様)。ステップS1で、操作スイッチ7がマニュアル閉MCの位置にあれば、マニュアル閉動作の処理が行われ(ステップS2)、ステップS3で、操作スイッチ7がオート閉ACの位置にあれば、オート閉動作の処理が行われ(ステップS4)、ステップS5で、操作スイッチ7がマニュアル開MOの位置にあれば、マニュアル開動作の処理が行われ(ステップS6)、ステップS7で、操作スイッチ7がオート開AOの位置にあれば、オート開動作の処理が行われる(ステップS8)。また、ステップS7で、操作スイッチ7がオート開AOの位置になければ、操作スイッチ7は中立Nの位置にあって、何も処理を行わない。ステップS2、S4、S6、S8の詳細については、以下に順を追って説明する。   FIG. 5 is a flowchart showing the basic operation of the power window device according to the embodiment of the present invention. “SW” in the drawing represents “operation switch 7” (the same applies to the flowcharts of FIGS. 6 to 11 below). If the operation switch 7 is in the manual closing MC position in step S1, the manual closing operation is performed (step S2). If the operation switch 7 is in the auto closing AC position in step S3, the automatic closing operation is performed. If the operation switch 7 is in the manual opening MO position in step S5, the manual opening operation is performed (step S6). In step S7, the operation switch 7 is automatically opened. If it is at the position of AO, an automatic opening operation process is performed (step S8). If the operation switch 7 is not in the auto-open AO position in step S7, the operation switch 7 is in the neutral N position and no processing is performed. Details of steps S2, S4, S6, and S8 will be described below in order.

図6は、図5のステップS2での「マニュアル閉処理」の詳細手順を示している。この手順は、制御部1により実行される。最初に、窓100が完全に閉じているか否かを、ロータリエンコーダ4の出力に基づいて判定する(ステップS11)。窓100が完全に閉じていれば(ステップS11:YES)、処理を終了し、完全に閉じていなければ(ステップS11:NO)、図25に示したように、CPU1aのポートAから正転信号を出力し、モータ3を正転させて窓を閉じる(ステップS12)。続いて、窓100が完全に閉じたか否かを判定し(ステップS13)、完全に閉じれば(ステップS13:YES)、処理を終了し、完全に閉じてなければ(ステップS13:NO)、挟み込みが検出されたか否かを判定する(ステップS14)。   FIG. 6 shows a detailed procedure of the “manual closing process” in step S2 of FIG. This procedure is executed by the control unit 1. First, it is determined based on the output of the rotary encoder 4 whether or not the window 100 is completely closed (step S11). If the window 100 is completely closed (step S11: YES), the process is terminated. If the window 100 is not completely closed (step S11: NO), a normal rotation signal is output from the port A of the CPU 1a as shown in FIG. Is output, the motor 3 is rotated forward to close the window (step S12). Subsequently, it is determined whether or not the window 100 is completely closed (step S13). If the window 100 is completely closed (step S13: YES), the processing is terminated. If the window 100 is not completely closed (step S13: NO), the jamming is performed. Is detected (step S14).

挟み込みが検出されなければ(ステップS14:NO)、操作スイッチ7がマニュアル閉MCの位置にあるか否かを判定し(ステップS15)、マニュアル閉MCの位置にあれば(ステップS15:YES)、ステップS12へ戻ってモータ3の正転を継続する。操作スイッチ7がマニュアル閉MCの位置になければ(ステップS15:NO)、オート閉ACの位置にあるか否かを判定する(ステップS16)。操作スイッチ7がオート閉ACの位置にあれば(ステップS16:YES)、後述(図7)のオート閉処理に移り(ステップS17)、オート閉ACの位置になければ(ステップS16:NO)、マニュアル開MOの位置にあるか否かを判定する(ステップS18)。操作スイッチ7がマニュアル開MOの位置にあれば(ステップS18:YES)、後述(図10)のマニュアル開処理に移り(ステップS19)、マニュアル開MOの位置になければ(ステップS18:NO)、オート開AOの位置にあるか否かを判定する(ステップS20)。操作スイッチ7がオート開AOの位置にあれば(ステップS20:YES)、後述(図11)のオート開処理に移り(ステップS21)、操作スイッチ7がオート開AOの位置になければ(ステップS20:NO)、何も処理せずに終了する。   If pinching is not detected (step S14: NO), it is determined whether or not the operation switch 7 is in the manually closed MC position (step S15). If it is in the manually closed MC position (step S15: YES), Returning to step S12, the forward rotation of the motor 3 is continued. If the operation switch 7 is not in the manual closing MC position (step S15: NO), it is determined whether or not it is in the automatic closing AC position (step S16). If the operation switch 7 is in the automatic closing AC position (step S16: YES), the process proceeds to the automatic closing process described later (FIG. 7) (step S17), and if it is not in the automatic closing AC position (step S16: NO), It is determined whether or not the position is the manual opening MO position (step S18). If the operation switch 7 is in the manual opening MO position (step S18: YES), the process proceeds to the manual opening process described later (FIG. 10) (step S19), and if it is not in the manual opening MO position (step S18: NO), It is determined whether or not the automatic open AO position is reached (step S20). If the operation switch 7 is in the auto-open AO position (step S20: YES), the process proceeds to an auto-open process described later (FIG. 11) (step S21). If the operation switch 7 is not in the auto-open AO position (step S20). : NO), the process ends without any processing.

一方、ステップS14で挟み込みが検出されると(ステップS14:YES)、挟み込みフラグを1にセットする(ステップS22)。そして、挟み込みの回数を計数するカウンタ62の計数値CNTに+1を加算する(ステップS23)。計数値CNTは、工場出荷時にCNT=0(初期値)に設定されている。続いて、ステップS23で算出した計数値CNTが、メモリ6に記憶されている閾値61を超えたか否かを判定する(ステップS24)。計数値CNTが閾値61を超えておれば(ステップS24:YES)、ステップS25へ進み、超えてなければ(ステップS24:NO)、ステップS26へ進む。   On the other hand, if pinching is detected in step S14 (step S14: YES), the pinching flag is set to 1 (step S22). Then, +1 is added to the count value CNT of the counter 62 that counts the number of times of pinching (step S23). The count value CNT is set to CNT = 0 (initial value) at the time of shipment from the factory. Subsequently, it is determined whether or not the count value CNT calculated in step S23 exceeds a threshold 61 stored in the memory 6 (step S24). If the count value CNT exceeds the threshold 61 (step S24: YES), the process proceeds to step S25, and if not (step S24: NO), the process proceeds to step S26.

ステップS25では、ランプ8を点灯させて、リレーの寿命が到来したこと、あるいはリレーの寿命が近づいたことを警告する。この場合、ランプ8を点滅させてもよい。また、ランプ8とは別の表示部に、警告のメッセージを表示するようにしてもよい。   In step S25, the lamp 8 is turned on to warn that the relay has reached the end of its life or that the relay has reached its end of life. In this case, the lamp 8 may be blinked. Further, a warning message may be displayed on a display unit different from the lamp 8.

ステップS26以下では、挟み込み検出に基づく窓の反転動作(開動作)が行われる。まず、ステップS26において、ステップS12で出力された正転信号に加えて逆転信号を出力し、モータ3の両端電位を同電位にして、モータ3に制動をかける。すなわち、CPU1aのポートAから正転信号が出力されている状態で、更にポートBから逆転信号を出力し、図27のように正転信号と逆転信号とが同時に出力される状態とする(図29のt3)。これによって、トランジスタQ1,Q2が共にONとなり、リレーRY1,RY2が動作して接点X1,X2が常閉(NC)側から常開(NO)側に切り換わる。この結果、モータ3の一方の端子A’は、接点X1を介して電源電圧により+Vとなり、他方の端子B’は、接点X2を介して電源電圧により+Vとなる(図27)。すなわち、モータ3の両端子A’,
B’は、共に高電位で同電位となる。このため、モータ3には電流が流れなくなって、回生制動がかかる。この場合、接点X2の切り換わり時にアークが発生して、リレーRY2の寿命に影響を与えることは前述の通りである。
In step S26 and after, a window reversal operation (opening operation) based on pinching detection is performed. First, in step S26, in addition to the forward rotation signal output in step S12, a reverse rotation signal is output, the potentials at both ends of the motor 3 are set to the same potential, and the motor 3 is braked. That is, while the normal rotation signal is being output from the port A of the CPU 1a, the reverse rotation signal is further output from the port B, and the normal rotation signal and the reverse rotation signal are simultaneously output as shown in FIG. 29 t3). As a result, the transistors Q1 and Q2 are both turned ON, and the relays RY1 and RY2 operate to switch the contacts X1 and X2 from the normally closed (NC) side to the normally open (NO) side. As a result, one terminal A ′ of the motor 3 becomes + V due to the power supply voltage via the contact X1, and the other terminal B ′ becomes + V due to the power supply voltage via the contact X2 (FIG. 27). That is, both terminals A ′ of the motor 3
Both B ′ are the same potential at a high potential. Therefore, no current flows through the motor 3 and regenerative braking is applied. In this case, as described above, an arc is generated when the contact point X2 is switched, which affects the life of the relay RY2.

次に、上記のようにしてモータ3の両端子A’, B’を同電位とした後、挟み込みが検出されてから所定時間が経過したか否かを判定する(ステップS27)。この所定時間は、モータ3の停止に要する時間を考慮して設定される。所定時間が経過していなければ(ステップS27:NO)、ステップS26へ戻って、モータ3の制動を継続する。所定時間が経過すると(ステップS27:YES)、ステップS28へ進んで、CPU1aのAポートから出力していた正転信号を停止する(図29のt5’)。これにより、ステップS26で出力されたBポートからの逆転信号のみが継続して出力される状態となり、リレーRY1が非動作状態となって、接点X1が常閉(NC)側に復帰するので(図26)、モータ3が逆転して窓が開く。このような制御により、挟み込みを検出してからモータ3が逆転を開始するまでの時間を短くできることは、前述の通りである。   Next, after setting both terminals A 'and B' of the motor 3 to the same potential as described above, it is determined whether or not a predetermined time has passed since the pinching was detected (step S27). This predetermined time is set in consideration of the time required to stop the motor 3. If the predetermined time has not elapsed (step S27: NO), the process returns to step S26 and the braking of the motor 3 is continued. When the predetermined time has elapsed (step S27: YES), the process proceeds to step S28, and the normal rotation signal output from the A port of the CPU 1a is stopped (t5 'in FIG. 29). As a result, only the reverse signal from the B port output in step S26 is continuously output, the relay RY1 becomes inoperative, and the contact X1 returns to the normally closed (NC) side ( FIG. 26), the motor 3 reverses and the window opens. As described above, it is possible to shorten the time from the detection of pinching until the motor 3 starts reverse rotation by such control.

次に、窓が完全に開いたか否かを判定し(ステップS29)、完全に開いていなければ(ステップS29:NO)、ステップS28へ戻ってモータ3の逆転を継続し、窓が完全に開くと(ステップS29:YES)、ステップS22で1にセットした挟み込みフラグを0にリセットし(ステップS30)、処理を終了する。   Next, it is determined whether or not the window is completely opened (step S29). If not completely opened (step S29: NO), the process returns to step S28 to continue the reverse rotation of the motor 3, and the window is completely opened. (Step S29: YES), the pinching flag set to 1 in Step S22 is reset to 0 (Step S30), and the process is terminated.

図7は、図5のステップS4での「オート閉処理」の詳細手順を示している。この手順は、制御部1により実行される。最初に、窓100が完全に閉じているか否かを、ロータリエンコーダ4の出力に基づいて判定する(ステップS31)。窓100が完全に閉じていれば(ステップS31:YES)、処理を終了し、完全に閉じていなければ(ステップS31:NO)、図25に示したように、CPU1aのポートAから正転信号を出力し、モータ3を正転させて窓を閉じる(ステップS32)。続いて、窓100が完全に閉じたか否かを判定し(ステップS33)、完全に閉じれば(ステップS33:YES)、処理を終了し、完全に閉じてなければ(ステップS33:NO)、挟み込みが検出されたか否かを判定する(ステップS34)。   FIG. 7 shows a detailed procedure of the “automatic closing process” in step S4 of FIG. This procedure is executed by the control unit 1. First, it is determined based on the output of the rotary encoder 4 whether or not the window 100 is completely closed (step S31). If the window 100 is completely closed (step S31: YES), the process is terminated. If the window 100 is not completely closed (step S31: NO), as shown in FIG. 25, a normal rotation signal is output from the port A of the CPU 1a. Is output, the motor 3 is rotated forward to close the window (step S32). Subsequently, it is determined whether or not the window 100 is completely closed (step S33). If the window 100 is completely closed (step S33: YES), the process is terminated. If the window 100 is not completely closed (step S33: NO), the jamming is performed. Is detected (step S34).

挟み込みが検出されなければ(ステップS34:NO)、操作スイッチ7がマニュアル開MOの位置にあるか否かを判定し(ステップS35)、マニュアル開MOの位置にあれば(ステップS35:YES)、後述(図10)のマニュアル開処理に移る(ステップS36)。操作スイッチ7がマニュアル開MOの位置になければ(ステップS35:NO)、オート開AOの位置にあるか否かを判定する(ステップS37)。操作スイッチ7がオート開AOの位置にあれば(ステップS37:YES)、後述(図11)のオート開処理に移り(ステップS38)、操作スイッチ7がオート開AOの位置になければ(ステップS37:NO)、何も処理せずに終了する。   If pinching is not detected (step S34: NO), it is determined whether or not the operation switch 7 is in the manual opening MO position (step S35). If it is in the manual opening MO position (step S35: YES), The process proceeds to the manual opening process described later (FIG. 10) (step S36). If the operation switch 7 is not in the manual opening MO position (step S35: NO), it is determined whether or not it is in the automatic opening AO position (step S37). If the operation switch 7 is in the auto-open AO position (step S37: YES), the process proceeds to an auto-open process described later (FIG. 11) (step S38). If the operation switch 7 is not in the auto-open AO position (step S37). : NO), the process ends without any processing.

一方、ステップS34で挟み込みが検出されると(ステップS34:YES)、ステップS39以降の処理が行われる。S39〜S47の各ステップの処理内容は、図6におけるS22〜S30の各ステップの処理内容と同じなので、以下では簡単に説明する。   On the other hand, when the pinching is detected in step S34 (step S34: YES), the processing after step S39 is performed. Since the processing content of each step of S39-S47 is the same as the processing content of each step of S22-S30 in FIG. 6, it demonstrates easily below.

挟み込みに対して、挟み込みフラグを1にセットした後(ステップS39)、挟み込み回数を計数するカウンタ62の計数値CNTに+1を加算する(ステップS40)。この計数値CNTが閾値61を超えた場合は(ステップS41:YES)、警告を出力してランプ8を点灯させる(ステップS42)。計数値CNTが閾値61を超えない場合は(ステップS41:NO)、ステップS32で出力された正転信号に加えて逆転信号を出力し、モータ3の両端電位を高電位で同電位とすることで、モータ3に制動をかける(ステップS43)。そして、挟み込み検出から所定時間が経過すると(ステップS44:YES)、正転信号を停止してステップS43で出力された逆転信号のみが継続して出力される状態とし、モータ3を逆転させて窓を開く(ステップS45)。窓が完全に開くと(ステップS46:YES)、挟み込みフラグを0にリセットし(ステップS47)、処理を終了する。   For pinching, after setting the pinching flag to 1 (step S39), +1 is added to the count value CNT of the counter 62 for counting the number of pinching (step S40). When the count value CNT exceeds the threshold 61 (step S41: YES), a warning is output and the lamp 8 is turned on (step S42). When the count value CNT does not exceed the threshold 61 (step S41: NO), in addition to the forward rotation signal output in step S32, the reverse rotation signal is output, and the potentials at both ends of the motor 3 are set to the same potential at a high potential. Thus, the motor 3 is braked (step S43). When a predetermined time elapses after the pinching is detected (step S44: YES), the forward rotation signal is stopped and only the reverse rotation signal output in step S43 is continuously output, and the motor 3 is rotated in reverse to open the window. Is opened (step S45). When the window is completely opened (step S46: YES), the pinching flag is reset to 0 (step S47), and the process is terminated.

このように、図6および図7の実施形態においては、挟み込みが検出されて、モータ3の回転状態が正転から逆転へ変化する際、すなわち、リレーRY2の接点X2が常閉(NC)側から常開(NO)側へ切り換わる際に、リレーRY2の寿命に影響を与えるような大きな負荷(アーク)が接点X2に発生するが、この発生回数、換言すれば挟み込みの検出回数をカウンタ62で計数し、その計数値CNTが閾値61を超えた場合に、ランプ8を点灯させて警告するようにしている。このため、リレーの寿命を報知して交換を促すことができ、リレーの故障による誤動作などのトラブルを未然に防止することができる。また、特許文献4のように接点の開閉回数や、電流、電圧などの多種のデータを計測する必要がなく、挟み込みの検出回数を計数するだけでよいので、制御部1での処理が簡単となり、メモリ6の容量も少なくて済む。   As described above, in the embodiment of FIGS. 6 and 7, when pinching is detected and the rotation state of the motor 3 changes from normal rotation to reverse rotation, that is, the contact X2 of the relay RY2 is normally closed (NC) side. When switching from the normally open (NO) side to the normally open (NO) side, a large load (arc) that affects the life of the relay RY2 is generated at the contact X2, and this counter counts the number of occurrences, in other words, the number of pinching detections. When the count value CNT exceeds the threshold 61, the lamp 8 is lit to warn. For this reason, it is possible to notify the life of the relay and promote replacement, and it is possible to prevent troubles such as malfunction due to a failure of the relay. Further, unlike Patent Document 4, there is no need to measure various data such as the number of contact opening / closing times, current, voltage, etc., and it is only necessary to count the number of pinching detections. The capacity of the memory 6 can be small.

図8は、図6の変形例を示したフローチャートである。図8では、図6と同一の処理を行うステップに同一の符号を付してある。図8において図6と異なる点は、ステップS25以後の処理である。ステップS25で警告が出力された後、ステップS25aにおいて、正転信号を停止させてモータ3の両端電位を同電位にし、モータ3に制動をかける。この場合は、ステップS26と異なり、モータ3の両端を低電位の同電位とする。すなわち、CPU1aのポートAからの正転信号の出力を停止して、正転信号も逆転信号も出力されない状態とする(図28のt3)。これによって、トランジスタQ1,Q2が共にOFFとなり、リレーRY1,RY2が非動作状態となるので、接点X1,X2が常閉(NC)側に切り換わる。この結果、モータ3の一方の端子A’は、接点X1を介して接地され、他方の端子B’は、接点X2を介して接地される(図24)。すなわち、モータ3の両端子A’,
B’は、共に低電位で同電位となる。このため、モータ3に回生制動がかかる。
FIG. 8 is a flowchart showing a modification of FIG. In FIG. 8, the same reference numerals are given to the steps for performing the same processing as in FIG. 6. 8 differs from FIG. 6 in the processing after step S25. After the warning is output in step S25, in step S25a, the forward rotation signal is stopped, the potentials at both ends of the motor 3 are set to the same potential, and the motor 3 is braked. In this case, unlike step S26, both ends of the motor 3 are set to the same low potential. That is, the output of the normal rotation signal from the port A of the CPU 1a is stopped, and neither the normal rotation signal nor the reverse rotation signal is output (t3 in FIG. 28). As a result, the transistors Q1 and Q2 are both turned OFF, and the relays RY1 and RY2 are deactivated, so that the contacts X1 and X2 are switched to the normally closed (NC) side. As a result, one terminal A ′ of the motor 3 is grounded via the contact X1, and the other terminal B ′ is grounded via the contact X2 (FIG. 24). That is, both terminals A ′ of the motor 3
B ′ is the same potential at a low potential. For this reason, regenerative braking is applied to the motor 3.

次に、挟み込みが検出されてから所定時間が経過したか否かを判定する(ステップS25b)。この所定時間は、モータ3の停止に要する時間を考慮して設定される。所定時間が経過していなければ(ステップS25b:NO)、ステップS25aへ戻って、モータ3の制動を継続する。所定時間が経過すると(ステップS25b:YES)、ステップS25cへ進んで、CPU1aのBポートから逆転信号を出力する(図28のt5)。これにより、リレーRY2が動作し、接点X2が常開(NO)側に切り換わるので(図26)、モータ3が逆転して窓が開く。   Next, it is determined whether or not a predetermined time has elapsed since the pinching was detected (step S25b). This predetermined time is set in consideration of the time required to stop the motor 3. If the predetermined time has not elapsed (step S25b: NO), the process returns to step S25a to continue the braking of the motor 3. When the predetermined time has elapsed (step S25b: YES), the process proceeds to step S25c, and a reverse rotation signal is output from the B port of the CPU 1a (t5 in FIG. 28). As a result, the relay RY2 operates and the contact X2 is switched to the normally open (NO) side (FIG. 26), so that the motor 3 reverses and the window opens.

次に、窓が完全に開いたか否かを判定し(ステップS25d)、完全に開いていなければ(ステップS25d:NO)、ステップS25cへ戻ってモータ3の逆転を継続し、窓が完全に開くと(ステップS25d:YES)、ステップS22で1にセットした挟み込みフラグを0にリセットし(ステップS30)、処理を終了する。   Next, it is determined whether or not the window is completely opened (step S25d). If the window is not completely opened (step S25d: NO), the process returns to step S25c to continue the reverse rotation of the motor 3, and the window is completely opened. (Step S25d: YES), the pinching flag set to 1 in Step S22 is reset to 0 (Step S30), and the process ends.

図9は、図7の変形例を示したフローチャートである。図9では、図7と同一の処理を行うステップに同一の符号を付してある。図9において図7と異なる点は、ステップS42以後の処理である。ステップS42で警告が出力された後、ステップS42aにおいて、正転信号を停止させてモータ3の両端電位を同電位にし、モータ3に制動をかける。この場合は、ステップS43と異なり、モータ3の両端を低電位の同電位とする。すなわち、CPU1aのポートAからの正転信号の出力を停止して、正転信号も逆転信号も出力されない状態とする(図28のt3)。これによって、トランジスタQ1,Q2が共にOFFとなり、リレーRY1,RY2が非動作状態となるので、接点X1,X2が常閉(NC)側に切り換わる。この結果、モータ3の一方の端子A’は、接点X1を介して接地され、他方の端子B’は、接点X2を介して接地される(図24)。すなわち、モータ3の両端子A’,
B’は、共に低電位で同電位となる。このため、モータ3に回生制動がかかる。
FIG. 9 is a flowchart showing a modification of FIG. In FIG. 9, the same reference numerals are given to steps for performing the same processing as in FIG. 7. 9 differs from FIG. 7 in the processing after step S42. After the warning is output in step S42, in step S42a, the forward rotation signal is stopped, the potentials at both ends of the motor 3 are set to the same potential, and the motor 3 is braked. In this case, unlike step S43, both ends of the motor 3 are set to the same low potential. That is, the output of the normal rotation signal from the port A of the CPU 1a is stopped, and neither the normal rotation signal nor the reverse rotation signal is output (t3 in FIG. 28). As a result, the transistors Q1 and Q2 are both turned OFF, and the relays RY1 and RY2 are deactivated, so that the contacts X1 and X2 are switched to the normally closed (NC) side. As a result, one terminal A ′ of the motor 3 is grounded via the contact X1, and the other terminal B ′ is grounded via the contact X2 (FIG. 24). That is, both terminals A ′ of the motor 3
B ′ is the same potential at a low potential. For this reason, regenerative braking is applied to the motor 3.

次に、挟み込みが検出されてから所定時間が経過したか否かを判定する(ステップS42b)。この所定時間は、モータ3の停止に要する時間を考慮して設定される。所定時間が経過していなければ(ステップS42b:NO)、ステップS42aへ戻って、モータ3の制動を継続する。所定時間が経過すると(ステップS42b:YES)、ステップS42cへ進んで、CPU1aのBポートから逆転信号を出力する(図28のt5)。これにより、リレーRY2が動作し、接点X2が常開(NO)側に切り換わるので(図26)、モータ3が逆転して窓が開く。   Next, it is determined whether or not a predetermined time has elapsed since the pinching was detected (step S42b). This predetermined time is set in consideration of the time required to stop the motor 3. If the predetermined time has not elapsed (step S42b: NO), the process returns to step S42a and the braking of the motor 3 is continued. When the predetermined time has elapsed (step S42b: YES), the process proceeds to step S42c, and a reverse rotation signal is output from the B port of the CPU 1a (t5 in FIG. 28). As a result, the relay RY2 operates and the contact X2 is switched to the normally open (NO) side (FIG. 26), so that the motor 3 reverses and the window opens.

次に、窓が完全に開いたか否かを判定し(ステップS42d)、完全に開いていなければ(ステップS42d:NO)、ステップS42cへ戻ってモータ3の逆転を継続し、窓が完全に開くと(ステップS42d:YES)、ステップS39で1にセットした挟み込みフラグを0にリセットし(ステップS47)、処理を終了する。   Next, it is determined whether or not the window is completely opened (step S42d). If not completely opened (step S42d: NO), the process returns to step S42c to continue the reverse rotation of the motor 3, and the window is completely opened. (Step S42d: YES), the pinching flag set to 1 in Step S39 is reset to 0 (Step S47), and the process is terminated.

このように、図8および図9の実施形態においては、挟み込み検出回数が閾値を超えない場合は、図29の制御を行い、正転信号と逆転信号を同時に出力してモータ3の両端電位を高電位で同電位とすることで、挟み込み検出からモータ逆転までの時間を短くし、迅速な挟み込み解除を行うことができる。一方、挟み込み検出回数が閾値を超えて警告が出力された場合は、図28の制御を行い、正転信号を停止してモータ3の両端電位を低電位で同電位とし、一定時間後に逆転信号を出力することで、リレー接点にアークが発生するのを回避し、リレーの寿命がそれ以上短くならないようにすることができる。   Thus, in the embodiment of FIGS. 8 and 9, when the number of pinching detections does not exceed the threshold value, the control of FIG. 29 is performed, and the forward and reverse signals are output simultaneously to By setting the same potential at a high potential, the time from the detection of pinching to the reverse rotation of the motor can be shortened, and pinching can be quickly released. On the other hand, if a warning is output when the number of pinching detections exceeds the threshold value, the control of FIG. 28 is performed, the forward rotation signal is stopped, the potentials at both ends of the motor 3 are set to the same potential at a low potential, and the reverse rotation signal is output after a certain time. Can be prevented from generating an arc at the relay contact, and the life of the relay can be prevented from further shortening.

図10は、図5のステップS6での「マニュアル開処理」の詳細手順を示している。この手順は、制御部1より実行される。最初に、マニュアル開動作により窓100が完全に開いたか否かをロータリエンコーダ4の出力に基づいて判定する(ステップS51)。窓100が完全に開けば(ステップS51:YES)処理を終了し、完全に開いてなければ(ステップS51:NO)、CPU1aのポートBから逆転信号を出力してモータ3を逆転させ、窓100を開ける(ステップS52)。続いて、窓100が完全に開いたか否かを判定し(ステップS53)、完全に開けば(ステップS53:YES)処理を終了し、完全に開いてなければ(ステップS53:NO)、操作スイッチ7がマニュアル開MOの位置にあるか否かを判定する(ステップS54)。   FIG. 10 shows a detailed procedure of the “manual opening process” in step S6 of FIG. This procedure is executed by the control unit 1. First, it is determined based on the output of the rotary encoder 4 whether or not the window 100 is completely opened by the manual opening operation (step S51). If the window 100 is completely opened (step S51: YES), the process is terminated. If the window 100 is not completely opened (step S51: NO), a reverse rotation signal is output from the port B of the CPU 1a to reverse the motor 3, and the window 100 Is opened (step S52). Subsequently, it is determined whether or not the window 100 is completely opened (step S53). If the window 100 is completely opened (step S53: YES), the processing is terminated. If the window 100 is not completely opened (step S53: NO), the operation switch It is determined whether or not 7 is at the position of manual opening MO (step S54).

操作スイッチ7がマニュアル開MOの位置にあれば(ステップS54:YES)、ステップS52へ戻ってモータ3の逆転を継続し、マニュアル開MOの位置になければ(ステップS54:NO)、オート開AOの位置にあるか否かを判定する(ステップS55)。操作スイッチ7がオート開AOの位置にあれば(ステップS55:YES)、後述(図11)のオート開処理に移り(ステップS56)、オート開AOの位置になければ(ステップS55:NO)、マニュアル閉MCの位置にあるか否かを判定する(ステップS57)。操作スイッチ7がマニュアル閉MCの位置にあれば(ステップS57:YES)、前述(図6、図8)のマニュアル閉処理に移り(ステップS58)、マニュアル閉MCの位置になければ(ステップS57:NO)、オート閉ACの位置にあるか否かを判定する(ステップS59)。操作スイッチ7がオート閉ACの位置にあれば(ステップS59:YES)、前述(図7、図9)のオート閉処理に移り(ステップS60)、操作スイッチ7がオート閉ACの位置になければ(ステップS59:NO)、何も処理せずに終了する。   If the operation switch 7 is in the manual opening MO position (step S54: YES), the process returns to step S52 to continue the reverse rotation of the motor 3, and if it is not in the manual opening MO position (step S54: NO), the automatic opening AO It is determined whether it is in the position (step S55). If the operation switch 7 is at the auto-open AO position (step S55: YES), the process proceeds to an auto-open process described later (FIG. 11) (step S56), and if it is not at the auto-open AO position (step S55: NO), It is determined whether or not the position is the manual closing MC position (step S57). If the operation switch 7 is in the manual closing MC position (step S57: YES), the process proceeds to the manual closing process described above (FIGS. 6 and 8) (step S58), and if it is not in the manual closing MC position (step S57: NO), it is determined whether or not it is in the auto-closed AC position (step S59). If the operation switch 7 is in the auto-close AC position (step S59: YES), the process proceeds to the auto-close process described above (FIGS. 7 and 9) (step S60). If the operation switch 7 is not in the auto-close AC position. (Step S59: NO), the process ends without performing any processing.

図11は、図5のステップS8での「オート開処理」の詳細手順を示している。この手順は、制御部1により実行される。最初に、オート開動作により窓100が完全に開いたか否かをロータリエンコーダ4の出力に基づいて判定する(ステップS71)。窓100が完全に開けば(ステップS71:YES)処理を終了し、完全に開いてなければ(ステップS71:NO)、CPU1aのポートBから逆転信号を出力してモータ3を逆転させ、窓100を開ける(ステップS72)。続いて、窓100が完全に開いたか否かを判定し(ステップS73)、完全に開けば(ステップS73:YES)処理を終了し、完全に開いてなければ(ステップS73:NO)、操作スイッチ7がマニュアル閉MCの位置にあるか否かを判定する(ステップS74)。   FIG. 11 shows a detailed procedure of the “automatic opening process” in step S8 of FIG. This procedure is executed by the control unit 1. First, it is determined based on the output of the rotary encoder 4 whether or not the window 100 is completely opened by the automatic opening operation (step S71). If the window 100 is completely opened (step S71: YES), the process is terminated. If the window 100 is not completely opened (step S71: NO), a reverse signal is output from the port B of the CPU 1a to reverse the motor 3, and the window 100 Is opened (step S72). Subsequently, it is determined whether or not the window 100 is completely opened (step S73). If the window 100 is completely opened (step S73: YES), the processing is terminated. If the window 100 is not completely opened (step S73: NO), the operation switch It is determined whether or not 7 is at the position of the manual closing MC (step S74).

操作スイッチ7がマニュアル閉MCの位置にあれば(ステップS74:YES)、前述(図6、図8)のマニュアル閉処理に移り(ステップS75)、マニュアル閉MCの位置になければ(ステップS74:NO)、オート閉ACの位置にあるか否かを判定する(ステップS76)。操作スイッチ7がオート閉ACの位置にあれば(ステップS76:YES)、前述(図7、図9)のオート閉処理に移り(ステップS77)、操作スイッチ7がオート閉ACの位置になければ(ステップS76:NO)、ステップS72へ戻って、モータ3の逆転を継続する。   If the operation switch 7 is in the manual closing MC position (step S74: YES), the process proceeds to the manual closing process described above (FIGS. 6 and 8) (step S75), and if it is not in the manual closing MC position (step S74: NO), it is determined whether or not it is in the position of auto-close AC (step S76). If the operation switch 7 is in the auto-closed AC position (step S76: YES), the process proceeds to the auto-close process described above (FIGS. 7 and 9) (step S77). If the operation switch 7 is not in the auto-closed AC position. (Step S76: NO), returning to Step S72, the reverse rotation of the motor 3 is continued.

図6または図8のマニュアル閉処理において、モータ3が正転して窓が閉じている状態で(ステップS12)、マニュアル開の操作が行われた場合は(ステップS18、S19)、図10のマニュアル開処理において、モータ3を逆転させて窓を開き(ステップS52)、オート開の操作が行われた場合は(ステップS20、S21)、図11のオート開処理において、モータ3を逆転させて窓を開く(ステップS72)。すなわち、この場合は図28の制御が行われる。   In the manual closing process of FIG. 6 or FIG. 8, when the motor 3 is rotated forward and the window is closed (step S12), and a manual opening operation is performed (steps S18 and S19), FIG. In the manual opening process, the motor 3 is reversed and the window is opened (step S52). When the automatic opening operation is performed (steps S20 and S21), the motor 3 is reversed in the automatic opening process of FIG. A window is opened (step S72). That is, in this case, the control of FIG. 28 is performed.

また、図7または図9のオート閉処理において、モータ3が正転して窓が閉じている状態で(ステップS32)、マニュアル開の操作が行われた場合は(ステップS35、S36)、図10のマニュアル開処理において、モータ3を逆転させて窓を開き(ステップS52)、オート開の操作が行われた場合は(ステップS37、S38)、図11のオート開処理において、モータ3を逆転させて窓を開く(ステップS72)。すなわち、この場合も図28の制御が行われる。   Further, in the automatic closing process of FIG. 7 or FIG. 9, when a manual opening operation is performed (steps S35 and S36) with the motor 3 rotating forward and the window closed (step S32), FIG. In the manual opening process 10, the motor 3 is reversely rotated to open the window (step S 52). When an automatic opening operation is performed (steps S 37 and S 38), the motor 3 is reversely rotated in the automatic opening process of FIG. Then, the window is opened (step S72). That is, also in this case, the control of FIG. 28 is performed.

以上のように、図6〜図11の実施形態においては、挟み込み検出時にモータ3を逆転させる場合は、図29の制御を行って、モータ逆転までの時間短縮を行い、挟み込み検出時以外でモータ3を逆転させる場合は、図28の制御を行って、リレーの接点にアークが発生するのを回避している。通常、挟み込みが発生する頻度はそれほど高くないので、上記のようにすることで、図29の制御が行われる回数が必要最小限に抑えられ、これによってアークによる接点の摩耗を極力少なくすることができる。   As described above, in the embodiment shown in FIGS. 6 to 11, when the motor 3 is reversely rotated when the pinching is detected, the control shown in FIG. 29 is performed to shorten the time until the motor reverses. When 3 is reversed, the control of FIG. 28 is performed to avoid the occurrence of an arc at the relay contact. Normally, the frequency of pinching is not so high, and by doing so, the number of times the control of FIG. 29 is performed can be minimized, thereby reducing the contact wear due to the arc as much as possible. it can.

次に、本発明の他の実施形態について説明する。以下では、本発明を車庫などのシャッターの開閉制御に適用した例を挙げる。シャッター制御装置の全体的なブロック図は図1と同じであり、モータ駆動回路2の構成も図24と同じである。但し、図2の操作スイッチ7に代えて、図12のようなシャッター開閉用の操作スイッチ50が用いられる。図13はシャッター30の外観図である。シャッター30は、モータ3の回転方向に応じて、図示しない昇降機構を介して開閉動作を行う。   Next, another embodiment of the present invention will be described. Below, the example which applied this invention to opening / closing control of shutters, such as a garage, is given. The overall block diagram of the shutter control device is the same as in FIG. 1, and the configuration of the motor drive circuit 2 is also the same as in FIG. However, instead of the operation switch 7 of FIG. 2, a shutter opening / closing operation switch 50 as shown in FIG. 12 is used. FIG. 13 is an external view of the shutter 30. The shutter 30 performs an opening / closing operation via an elevating mechanism (not shown) according to the rotation direction of the motor 3.

図12において、操作スイッチ50は、スイッチ本体51とレバー52とを備えている。スイッチ本体51には、図示しないスイッチ機構が内蔵されており、レバー52の操作によりスイッチ機構が作動して接点の切り換えが行われる。レバー52を実線の中立位置から左側に倒すと(開操作)、シャッター開が指示され、CPU1aのポートAから正転信号が出力されてモータ3が正転し(図25)、図13(a)のように閉じているシャッター30は、図13(b)の矢印c方向に上昇して開く。また、レバー52を実線の中立位置から右側に倒すと(閉操作)、シャッター閉が指示され、CPU1aのポートBから逆転信号が出力されてモータ3が逆転し(図26)、シャッター30は、図13(b)の矢印d方向に下降して閉じる。   In FIG. 12, the operation switch 50 includes a switch body 51 and a lever 52. The switch main body 51 incorporates a switch mechanism (not shown), and the switch mechanism is operated by the operation of the lever 52 to switch the contacts. When the lever 52 is tilted to the left from the neutral position of the solid line (opening operation), the shutter opening is instructed, a forward rotation signal is output from the port A of the CPU 1a, and the motor 3 rotates forward (FIG. 25), FIG. The closed shutter 30 as shown in FIG. 13B is raised in the direction of arrow c in FIG. When the lever 52 is tilted to the right from the neutral position of the solid line (closing operation), the shutter is instructed, a reverse signal is output from the port B of the CPU 1a, the motor 3 is reversely rotated (FIG. 26), and the shutter 30 is It descends in the direction of arrow d in FIG.

図14は、上述したシャッター制御装置の基本的な動作を示したフローチャートである。図中の「SW」は「操作スイッチ50」を表している(以下の図15〜図17のフローチャートにおいても同様)。ステップS81で、操作スイッチ50の開操作が行われたかどうかを判定し、開操作が行われると(ステップS81:YES)、ステップS82へ進んで、後述(図15)のシャッター開処理が実行される。開操作が行われなければ(ステップS81:NO)、ステップS83で、操作スイッチ50の閉操作が行われたかどうかを判定し、閉操作が行われると(ステップS83:YES)、ステップS84へ進んで、後述(図16)のシャッター閉処理が実行される。閉操作が行われなければ(ステップS83:NO)、ステップS85へ進んで、後述(図17)のシャッター中立状態処理が実行される。   FIG. 14 is a flowchart showing the basic operation of the shutter control device described above. “SW” in the drawing represents “operation switch 50” (the same applies to the flowcharts of FIGS. 15 to 17 below). In step S81, it is determined whether or not the opening operation of the operation switch 50 has been performed. If the opening operation has been performed (step S81: YES), the process proceeds to step S82, and a shutter opening process described later (FIG. 15) is executed. The If the opening operation is not performed (step S81: NO), it is determined in step S83 whether or not the operation switch 50 is closed. If the closing operation is performed (step S83: YES), the process proceeds to step S84. Thus, the shutter closing process described later (FIG. 16) is executed. If the closing operation is not performed (step S83: NO), the process proceeds to step S85, and the shutter neutral state process described later (FIG. 17) is executed.

図15は、図14のステップS82での「シャッター開処理」の詳細手順を示している。この手順は、制御部1により実行される。最初に、シャッター30の開方向の可動限界が検出されたかどうかを判定する(ステップS91)。開方向の可動限界は、シャッター30が開いてそれ以上上昇できなくなったときの位置である。可動限界が検出された場合は(ステップS91:YES)、シャッター30が完全に開いたことになるので、処理を終了する。可動限界が検出されなければ(ステップS91:NO)、図25に示したように、CPU1aのポートAから正転信号を出力し、モータ3を正転させてシャッター30を開く(ステップS92)。続いて、開方向の可動限界が検出されたかどうかを判定し(ステップS93)、可動限界が検出されると(ステップS93:YES)、処理を終了し、可動限界が検出されなければ(ステップS93:NO)、操作スイッチ50が開操作の状態にあるか否かを判定する(ステップS94)。操作スイッチ50が開操作の状態にあれば(ステップS94:YES)、ステップS92へ戻って、シャッター30の開動作を継続する。操作スイッチ50が開操作の状態になければ(ステップS94:NO)、後述するシャッター中立状態処理が実行される(ステップS95)。操作スイッチ50の開操作後に、連続的に閉操作がされる場合も、一旦中立状態処理へ移行する。   FIG. 15 shows a detailed procedure of the “shutter opening process” in step S82 of FIG. This procedure is executed by the control unit 1. First, it is determined whether or not a movable limit in the opening direction of the shutter 30 has been detected (step S91). The movable limit in the opening direction is a position when the shutter 30 is opened and can no longer be raised. If the movable limit is detected (step S91: YES), the shutter 30 is completely opened, and the process is terminated. If the movable limit is not detected (step S91: NO), as shown in FIG. 25, a normal rotation signal is output from the port A of the CPU 1a, the motor 3 is rotated forward, and the shutter 30 is opened (step S92). Subsequently, it is determined whether or not the movable limit in the opening direction is detected (step S93). When the movable limit is detected (step S93: YES), the process is terminated, and the movable limit is not detected (step S93). : NO), it is determined whether or not the operation switch 50 is in the open operation state (step S94). If the operation switch 50 is in the open operation state (step S94: YES), the process returns to step S92 and the opening operation of the shutter 30 is continued. If the operation switch 50 is not in the open operation state (step S94: NO), a shutter neutral state process described later is executed (step S95). Even when the operation switch 50 is continuously opened after the opening operation, the process proceeds to the neutral state process.

図16は、図14のステップS84での「シャッター閉処理」の詳細手順を示している。この手順は、制御部1により実行される。最初に、シャッター30の閉方向の可動限界が検出されたかどうかを判定する(ステップS101)。閉方向の可動限界は、シャッター30が閉じてそれ以上下降できなくなったときの位置である。可動限界が検出された場合は(ステップS101:YES)、シャッター30が完全に閉じたことになるので、処理を終了する。可動限界が検出されなければ(ステップS101:NO)、図26に示したように、CPU1aのポートBから逆転信号を出力し、モータ3を逆転させてシャッター30を閉じる(ステップS102)。続いて、閉方向の可動限界が検出されたかどうかを判定し(ステップS103)、可動限界が検出されると(ステップS103:YES)、処理を終了し、可動限界が検出されなければ(ステップS103:NO)、操作スイッチ50が閉操作の状態にあるか否かを判定する(ステップS104)。操作スイッチ50が閉操作の状態にあれば(ステップS104:YES)、ステップS102へ戻って、シャッター30の閉動作を継続する。操作スイッチ50が閉操作の状態になければ(ステップS104:NO)、後述するシャッター中立状態処理が実行される(ステップS105)。操作スイッチ50の閉操作後に、連続的に開操作がされる場合も、一旦中立状態処理へ移行する。   FIG. 16 shows a detailed procedure of the “shutter closing process” in step S84 of FIG. This procedure is executed by the control unit 1. First, it is determined whether or not a movable limit in the closing direction of the shutter 30 has been detected (step S101). The movable limit in the closing direction is a position when the shutter 30 is closed and can no longer be lowered. If the movable limit is detected (step S101: YES), the shutter 30 is completely closed, and the process is terminated. If the movable limit is not detected (step S101: NO), as shown in FIG. 26, a reverse rotation signal is output from the port B of the CPU 1a, the motor 3 is reversely rotated and the shutter 30 is closed (step S102). Subsequently, it is determined whether or not a movable limit in the closing direction has been detected (step S103). When the movable limit is detected (step S103: YES), the process ends, and if the movable limit is not detected (step S103). : NO), it is determined whether or not the operation switch 50 is in the closed operation state (step S104). If the operation switch 50 is in the closing operation state (step S104: YES), the process returns to step S102, and the closing operation of the shutter 30 is continued. If the operation switch 50 is not in the closed operation state (step S104: NO), a shutter neutral state process described later is executed (step S105). Even when the opening operation is continuously performed after the operation switch 50 is closed, the process proceeds to the neutral state process.

図17は、図14のステップS85、図15のステップS95、および図16のステップS105での「シャッター中立状態処理」の詳細手順を示している。この手順は、制御部1により実行される。最初に、操作スイッチ50が開操作から閉操作へ切り換わる時間、または閉操作から開操作へ切り換わる時間を計測する(ステップS111)。次に、この計測した時間Tが0.5秒以下であるか否かを判定する(ステップS112)。この0.5秒は一例であって、これ以外の基準値を用いてもよい。   FIG. 17 shows a detailed procedure of “shutter neutral state processing” in step S85 of FIG. 14, step S95 of FIG. 15, and step S105 of FIG. This procedure is executed by the control unit 1. First, the time for the operation switch 50 to switch from the opening operation to the closing operation, or the time to switch from the closing operation to the opening operation is measured (step S111). Next, it is determined whether or not the measured time T is 0.5 seconds or less (step S112). This 0.5 second is an example, and other reference values may be used.

時間Tが0.5秒を超えている場合、すなわち、操作スイッチ50の開操作または閉操作の後、0.5秒を過ぎてから閉操作または開操作が行われた場合は(ステップS112:NO)、通常の閉操作または開操作であると判断し、ステップS113、S115でいずれの操作であるかを判定する。そして、開操作である場合は(ステップS113:YES)、前述した図15のシャッター開処理を実行し(ステップS114)、閉操作である場合は(ステップS115:YES)、前述した図16のシャッター閉処理を実行する(ステップS116)。   When the time T exceeds 0.5 seconds, that is, after the opening operation or closing operation of the operation switch 50, the closing operation or opening operation is performed after 0.5 seconds (step S112: NO), it is determined that the operation is a normal closing operation or an opening operation, and it is determined which operation is performed in steps S113 and S115. If it is an opening operation (step S113: YES), the shutter opening process shown in FIG. 15 is executed (step S114). If it is a closing operation (step S115: YES), the shutter shown in FIG. A closing process is executed (step S116).

一方、時間Tが0.5秒以下の場合、すなわち、操作スイッチ50の開操作または閉操作の後、0.5秒が経過する前に閉操作または開操作が行われた場合は(ステップS112:YES)、開動作中または閉動作中のシャッターを一旦停止させる必要があると判断し、ステップS117以下の処理を実行する。   On the other hand, when the time T is 0.5 seconds or less, that is, when the closing operation or opening operation is performed before 0.5 seconds elapses after the opening operation or closing operation of the operation switch 50 (step S112). : YES), it is determined that it is necessary to temporarily stop the shutter during the opening operation or the closing operation, and the processing after step S117 is executed.

ステップS117では、図27のように、CPU1aのポートA,Bからそれぞれ正転信号と逆転信号が同時に出力される状態にして、リレーRY1,RY2を共に動作させ、モータ3の両端子A’,
B’を高電位で同電位とすることによって、モータ3に回生制動をかける。この場合、接点X2の切り換わり時にアークが発生して、リレーRY2の寿命に影響を与えることは前述の通りである。
In step S117, as shown in FIG. 27, the normal rotation signal and the reverse rotation signal are simultaneously output from the ports A and B of the CPU 1a, respectively, the relays RY1 and RY2 are operated together, and both terminals A ′,
Regenerative braking is applied to the motor 3 by setting B ′ to the same potential at a high potential. In this case, as described above, an arc is generated when the contact point X2 is switched, which affects the life of the relay RY2.

上記のようにしてモータ3の回生制動を開始した後、所定時間が経過したか否かを判定する(ステップS118)。この所定時間は、モータ3の停止に要する時間を考慮して設定される。所定時間が経過していなければ(ステップS118:NO)、ステップS117へ戻って、モータ3の制動を継続する。所定時間が経過すると(ステップS118:YES)、回生制動によってモータ3が停止に至り、開動作中または閉動作中のシャッター30は一旦停止する。この場合は、ステップS119で、リレーRY1,RY2が同時に動作した回数を計数するカウンタ62の計数値Nに+1を加算する。計数値Nは、工場出荷時にN=0(初期値)に設定されている。続いて、ステップS119で算出した計数値Nが、メモリ6に記憶されている閾値61を超えたか否かを判定する(ステップS120)。計数値Nが閾値61を超えておれば(ステップS120:YES)、ステップS121へ進み、超えてなければ(ステップS120:NO)、ステップS122へ進む。   After starting regenerative braking of the motor 3 as described above, it is determined whether or not a predetermined time has elapsed (step S118). This predetermined time is set in consideration of the time required to stop the motor 3. If the predetermined time has not elapsed (step S118: NO), the process returns to step S117 and the braking of the motor 3 is continued. When the predetermined time has elapsed (step S118: YES), the motor 3 is stopped by regenerative braking, and the shutter 30 during the opening operation or the closing operation is temporarily stopped. In this case, in step S119, +1 is added to the count value N of the counter 62 that counts the number of times the relays RY1 and RY2 are operated simultaneously. The count value N is set to N = 0 (initial value) at the time of factory shipment. Subsequently, it is determined whether or not the count value N calculated in step S119 exceeds a threshold 61 stored in the memory 6 (step S120). If the count value N exceeds the threshold 61 (step S120: YES), the process proceeds to step S121, and if not (step S120: NO), the process proceeds to step S122.

ステップS121では、ランプ8を点灯させて、リレーの寿命が到来したこと、あるいはリレーの寿命が近づいたことを警告する。この場合、ランプ8を点滅させてもよい。また、ランプ8とは別の表示部に、警告のメッセージを表示するようにしてもよい。   In step S121, the lamp 8 is turned on to warn that the relay has reached the end of its life or that the relay has reached its end of life. In this case, the lamp 8 may be blinked. Further, a warning message may be displayed on a display unit different from the lamp 8.

ステップS122では、操作スイッチ50が開操作されたか否かを判定し、開操作がされた場合は(ステップS122:YES)、図15に示したシャッター開処理を実行する(ステップS123)。これにより、一旦停止したシャッター30は開動作へ移行する。開操作がされない場合は(ステップS122:NO)、操作スイッチ50が閉操作されたか否かを判定し(ステップS124)、閉操作がされた場合は(ステップS124:YES)、図16に示したシャッター閉処理を実行する(ステップS125)。これにより、一旦停止したシャッター30は閉動作へ移行する。   In step S122, it is determined whether or not the operation switch 50 has been opened. If the operation switch 50 has been opened (step S122: YES), the shutter opening process shown in FIG. 15 is executed (step S123). As a result, the shutter 30 once stopped shifts to an opening operation. When the opening operation is not performed (step S122: NO), it is determined whether or not the operation switch 50 is closed (step S124). When the closing operation is performed (step S124: YES), FIG. 16 shows. Shutter closing processing is executed (step S125). As a result, the shutter 30 once stopped shifts to a closing operation.

図17の実施形態においては、シャッター30の開動作または閉動作を一旦停止させる場合、正転信号と逆転信号が同時に出力される状態とすることで(ステップS117)、図29の制御が行われる。このため、モータ3に回生制動がかかるタイミングを早めて、非常時などにシャッター30を速やかに停止させることができる。   In the embodiment of FIG. 17, when the opening operation or the closing operation of the shutter 30 is temporarily stopped, the control of FIG. 29 is performed by setting the forward rotation signal and the reverse rotation signal to be output simultaneously (step S117). . Therefore, the timing at which regenerative braking is applied to the motor 3 can be advanced so that the shutter 30 can be quickly stopped in an emergency or the like.

この場合、リレーRY1,RY2が共に動作状態となることから(図27)、リレーRY2の接点X2が常閉(NC)側から常開(NO)側へ切り換わる際に、リレーRY2の寿命に影響を与えるような大きな負荷(アーク)が接点X2に発生するが、この発生回数、換言すればリレーRY1,RY2の同時動作回数をカウンタ62で計数し、その計数値Nが閾値61を超えた場合に、ランプ8を点灯させて警告するようにしている。このため、リレーの寿命を報知して交換を促すことができ、リレーの故障による誤動作などのトラブルを未然に防止することができる。また、特許文献4のように電流や電圧を計測する必要がなく、リレーの同時動作回数を計数するだけでよいので、制御部1での処理が簡単となり、メモリ6の容量も少なくて済む。   In this case, since both of the relays RY1 and RY2 are in an operating state (FIG. 27), when the contact X2 of the relay RY2 switches from the normally closed (NC) side to the normally open (NO) side, the life of the relay RY2 is reached. A large load (arc) that has an effect is generated at the contact X2, but the number of occurrences, in other words, the number of simultaneous operations of the relays RY1 and RY2 is counted by the counter 62, and the counted value N exceeds the threshold value 61. In such a case, the lamp 8 is lit to warn. For this reason, it is possible to notify the life of the relay and promote replacement, and it is possible to prevent troubles such as malfunction due to a failure of the relay. Further, unlike Patent Document 4, it is not necessary to measure current and voltage, and it is only necessary to count the number of simultaneous operations of the relays. Therefore, the processing in the control unit 1 is simplified, and the capacity of the memory 6 can be reduced.

次に、本発明のさらに他の実施形態を、図18〜図20に基づいて説明する。図18は、他の実施形態に係るパワーウインドウ装置のブロック図であり、図1と同一部分には同一符号を付してある。図18において、図1と異なる点は、カウンタとして、第1カウンタ62aと第2カウンタ62bの2つが設けられている点である。第1カウンタ62aは、本発明における第1の計数手段の一実施形態を構成し、第2カウンタ62bは、本発明における第2の計数手段の一実施形態を構成する。その他の構成に関しては、図1と同じであるので、詳細な説明は省略する。また、モータ駆動回路2の構成は、図24と同じである。   Next, still another embodiment of the present invention will be described with reference to FIGS. FIG. 18 is a block diagram of a power window device according to another embodiment, and the same components as those in FIG. 18 differs from FIG. 1 in that two counters, a first counter 62a and a second counter 62b, are provided. The first counter 62a constitutes an embodiment of the first counting means in the present invention, and the second counter 62b constitutes an embodiment of the second counting means in the present invention. Since other configurations are the same as those in FIG. 1, detailed description thereof is omitted. The configuration of the motor drive circuit 2 is the same as that shown in FIG.

本実施形態では、メモリ6に予め設定されている閾値61(第1カウンタ62aに対する閾値)を、第2カウンタ62bの計数値に基づいて変更するようにしている。以下、詳細について図19のフローチャートを参照しながら説明する。   In the present embodiment, the threshold 61 (threshold for the first counter 62a) preset in the memory 6 is changed based on the count value of the second counter 62b. Details will be described below with reference to the flowchart of FIG.

図19において、ステップS131では、モータ3の回転方向を反転させる際に、モータ3の両端の電位を同電位にして回生制動をかける。次に、モータ3の両端の電位を高電位にしたか、低電位にしたかを判定する(ステップS132)。モータ3の両端を低電位にした場合は(ステップS132:NO)、第1カウンタ62aの計数値Xに+1を加算する(ステップS133)。計数値Xは、工場出荷時にX=0(初期値)に設定されている。続いて、ステップS133で算出した計数値Xが、メモリ6に記憶されている閾値61を超えたか否かを判定する(ステップS134)。計数値Xが閾値61を超えておれば(ステップS134:YES)、ステップS135へ進んで警告を出力する(ランプ8を点灯)。計数値Xが閾値61を超えていなければ(ステップS134:NO)、警告は出力せずに最初に戻る。   In FIG. 19, in step S131, when reversing the rotation direction of the motor 3, regenerative braking is applied with the potentials at both ends of the motor 3 set to the same potential. Next, it is determined whether the electric potential at both ends of the motor 3 is set to a high potential or a low potential (step S132). When both ends of the motor 3 are set to a low potential (step S132: NO), +1 is added to the count value X of the first counter 62a (step S133). The count value X is set to X = 0 (initial value) at the time of factory shipment. Subsequently, it is determined whether or not the count value X calculated in step S133 exceeds a threshold 61 stored in the memory 6 (step S134). If the count value X exceeds the threshold value 61 (step S134: YES), the process proceeds to step S135 and a warning is output (lamp 8 is turned on). If the count value X does not exceed the threshold 61 (step S134: NO), no warning is output and the process returns to the beginning.

一方、モータ3の両端を高電位にした場合は(ステップS132:YES)、ステップS136へ進んで、第2カウンタ62bの計数値Yに+1を加算する。計数値Yは、工場出荷時にY=0(初期値)に設定されている。続いて、計数値Yに基づいて、閾値61を変更する(ステップS137)。具体的には、閾値61を小さくする。変更後の閾値61は、メモリ6に上書きされて記憶される。したがって、次回のステップS134では、変更後の閾値61と計数値Xとが比較される。   On the other hand, when both ends of the motor 3 are set to a high potential (step S132: YES), the process proceeds to step S136, and +1 is added to the count value Y of the second counter 62b. The count value Y is set to Y = 0 (initial value) at the time of factory shipment. Subsequently, the threshold 61 is changed based on the count value Y (step S137). Specifically, the threshold 61 is reduced. The changed threshold 61 is overwritten and stored in the memory 6. Therefore, in the next step S134, the changed threshold 61 and the count value X are compared.

以上のような処理を行うことにより、モータ3の両端を低電位で同電位にして回生制動をかけた回数と、高電位で同電位にして回生制動をかけた回数とを、区別して計数することができる。そして、図20に示したように、第1カウンタ62aの計数値Xが増加しても閾値は変化しないが、第2カウンタ62bの計数値Yが増加すると、それに応じて閾値は減少してゆく。第1カウンタ62aの計数値Xは、モータ3の両端を低電位で同電位にして回生制動をかけた回数であり、通常の反転制御(図28)を行った回数である。一方、第2カウンタ62bの計数値Yは、モータ3の両端を高電位で同電位にして回生制動をかけた回数であり、挟み込み検出時のようにモータ3の停止を早める必要がある場合の反転制御(図29)を行った回数である。後者の場合は、既述のように接点にアークが発生してリレーの寿命に影響を与えるので、第2カウンタ62bの計数値Yに応じて閾値を下げることで、第1カウンタ62aの計数値Xに対する閾値が、寿命低下の要因発生を反映した適正な値となり、リレーの寿命を正確に検出して警告を出力することができる。   By performing the above processing, the number of times that regenerative braking is performed with both ends of the motor 3 set to the same potential at a low potential and the number of times that regenerative braking is applied with the same potential at a high potential are counted separately. be able to. As shown in FIG. 20, the threshold value does not change even if the count value X of the first counter 62a increases, but the threshold value decreases accordingly when the count value Y of the second counter 62b increases. . The count value X of the first counter 62a is the number of times that regenerative braking is applied with both ends of the motor 3 being at the same potential at a low potential, and is the number of times of performing normal inversion control (FIG. 28). On the other hand, the count value Y of the second counter 62b is the number of times that regenerative braking is applied with both ends of the motor 3 set to the same potential at a high potential. This is the number of times the inversion control (FIG. 29) has been performed. In the latter case, as described above, an arc is generated at the contact point and affects the life of the relay. Therefore, the count value of the first counter 62a is reduced by lowering the threshold value according to the count value Y of the second counter 62b. The threshold value for X becomes an appropriate value reflecting the occurrence of the cause of life reduction, and the warning can be output by accurately detecting the life of the relay.

なお、本実施形態は、パワーウインドウ装置に限らず、前述したシャッターの開閉制御にも適用することができる。   The present embodiment can be applied not only to the power window device but also to the shutter opening / closing control described above.

次に、本発明のさらに他の実施形態を、図21〜図23に基づいて説明する。図21は、他の実施形態に係るパワーウインドウ装置のブロック図であり、図1と同一部分には同一符号を付してある。図21において、図1と異なる点は、カウンタとして、第3カウンタ62cと第4カウンタ62dの2つが設けられている点である。第3カウンタ62cは、本発明における第3の計数手段の一実施形態を構成し、第4カウンタ62dは、本発明における第4の計数手段の一実施形態を構成する。その他の構成に関しては、図1と同じであるので、詳細な説明は省略する。また、モータ駆動回路2の構成は、図24と同じである。図24のロータリエンコーダ4、パルス検出回路5、および制御部1は、本発明におけるロック検出手段の一実施形態を構成する。   Next, still another embodiment of the present invention will be described with reference to FIGS. FIG. 21 is a block diagram of a power window device according to another embodiment, and the same components as those in FIG. 21 is different from FIG. 1 in that two counters, a third counter 62c and a fourth counter 62d, are provided as counters. The third counter 62c constitutes an embodiment of the third counting means in the present invention, and the fourth counter 62d constitutes an embodiment of the fourth counting means in the present invention. Since other configurations are the same as those in FIG. 1, detailed description thereof is omitted. The configuration of the motor drive circuit 2 is the same as that shown in FIG. The rotary encoder 4, the pulse detection circuit 5, and the control unit 1 in FIG. 24 constitute an embodiment of the lock detection means in the present invention.

本実施形態では、メモリ6に予め設定されている閾値61(第3カウンタ62cに対する閾値)を、第4カウンタ62dの計数値に基づいて変更するようにしている。以下、詳細について図22のフローチャートを参照しながら説明する。   In the present embodiment, the threshold 61 (threshold for the third counter 62c) preset in the memory 6 is changed based on the count value of the fourth counter 62d. Details will be described below with reference to the flowchart of FIG.

図22において、ステップS141では、モータ3を正転または逆転して開閉体を駆動する。ここでは、開閉体は窓ガラスである。次に、開閉体の駆動回数を計数する第3カウンタ62cの計数値Pに+1を加算する(ステップS142)。計数値Pは、工場出荷時にP=0(初期値)に設定されている。その後、モータ3のロック状態があったか否かを判定する(ステップS143)。窓ガラスが上限位置または下限位置(これらを原点位置という。)に達すると、窓ガラスはそれ以上動かなくなるが、窓の全閉および全開を確実にするために、窓ガラスが原点位置に達した後も、モータ駆動回路2によりモータ3に所定時間通電が行われる。しかし、窓ガラスが停止していてモータ3は回転することができないので、ロータリエンコーダ4から回転検出信号は出力されない。このように、モータ3が通電状態にあるのに回転が検出されない状態がモータのロック状態である。ロック状態を検出することにより、窓ガラスが原点位置にあることを判別することができる。   In FIG. 22, in step S141, the motor 3 is rotated forward or backward to drive the opening / closing body. Here, the opening / closing body is a window glass. Next, +1 is added to the count value P of the third counter 62c that counts the number of times the opening / closing body is driven (step S142). The count value P is set to P = 0 (initial value) at the time of factory shipment. Thereafter, it is determined whether or not the motor 3 is locked (step S143). When the window glass reaches the upper limit position or lower limit position (these are called the origin positions), the window glass stops moving further, but the window glass has reached the origin position to ensure that the window is fully closed and fully opened. Thereafter, the motor 3 is energized for a predetermined time by the motor drive circuit 2. However, since the window glass is stopped and the motor 3 cannot rotate, no rotation detection signal is output from the rotary encoder 4. Thus, the state in which rotation is not detected even though the motor 3 is energized is the motor locked state. By detecting the locked state, it can be determined that the window glass is at the origin position.

ステップS143でモータ3のロック状態がなかったと判定されれば(ステップS143:NO)、ステップS142で算出した計数値Pが、メモリ6に記憶されている閾値61を超えたか否かを判定する(ステップS144)。計数値Pが閾値61を超えておれば(ステップS144:YES)、ステップS145へ進んで警告を出力する(ランプ8を点灯)。計数値Pが閾値61を超えていなければ(ステップS144:NO)、警告は出力せずに最初に戻る。   If it is determined in step S143 that the motor 3 is not locked (step S143: NO), it is determined whether or not the count value P calculated in step S142 exceeds the threshold 61 stored in the memory 6 ( Step S144). If the count value P exceeds the threshold 61 (step S144: YES), the process proceeds to step S145 to output a warning (lamp 8 is turned on). If the count value P does not exceed the threshold value 61 (step S144: NO), no warning is output and the process returns to the beginning.

一方、ステップS143でモータ3のロック状態があったと判定されれば(ステップS143:YES)、ステップS146へ進んで、第4カウンタ62dの計数値Qに+1を加算する。計数値Qは、工場出荷時にQ=0(初期値)に設定されている。続いて、計数値Qに基づいて、閾値61を変更する(ステップS147)。具体的には、閾値61を小さくする。変更後の閾値61は、メモリ6に上書きされて記憶される。したがって、次回のステップS144では、変更後の閾値61と計数値Pとが比較される。   On the other hand, if it is determined in step S143 that the motor 3 is locked (step S143: YES), the process proceeds to step S146, and +1 is added to the count value Q of the fourth counter 62d. The count value Q is set to Q = 0 (initial value) at the time of factory shipment. Subsequently, the threshold 61 is changed based on the count value Q (step S147). Specifically, the threshold 61 is reduced. The changed threshold 61 is overwritten and stored in the memory 6. Therefore, in the next step S144, the changed threshold 61 and the count value P are compared.

以上のような処理を行うことにより、図23に示したように、第3カウンタ62cの計数値Pが増加しても閾値は変化しないが、第4カウンタ62dの計数値Qが増加すると、それに応じて閾値は減少してゆく。第3カウンタ62cの計数値Pは、モータ3により開閉体を駆動した回数であり、第4カウンタ62dの計数値Qは、そのうちモータ3にロック状態が発生した回数である。モータ3がロック状態になると、モータ3に大電流が流れるため、モータ駆動回路2のリレー接点X1,X2の負荷が大きくなって、リレーの寿命が短くなる。そこで、第4カウンタ62dの計数値Qに応じて閾値を下げることで、第3カウンタ62cの計数値Pに対する閾値が、寿命低下の要因発生を反映した適正な値となり、リレーの寿命を正確に検出して警告を出力することができる。   By performing the above processing, as shown in FIG. 23, the threshold value does not change even when the count value P of the third counter 62c increases, but when the count value Q of the fourth counter 62d increases, Accordingly, the threshold value decreases. The count value P of the third counter 62c is the number of times that the opening / closing body is driven by the motor 3, and the count value Q of the fourth counter 62d is the number of times that the motor 3 is locked. When the motor 3 is in a locked state, a large current flows through the motor 3, so that the loads on the relay contacts X1 and X2 of the motor drive circuit 2 become large, and the life of the relay is shortened. Therefore, by lowering the threshold value in accordance with the count value Q of the fourth counter 62d, the threshold value for the count value P of the third counter 62c becomes an appropriate value reflecting the occurrence of the cause of life reduction, and the life of the relay is accurately determined. Can detect and output warnings.

本実施形態も、パワーウインドウ装置に限らず、前述したシャッターの開閉制御などに適用することができる。   The present embodiment is not limited to the power window device, and can be applied to the shutter opening / closing control described above.

本発明は、以上述べた実施形態以外にも、種々の実施形態を採用することができる。例えば、モータ3の両端子が高電位で同電位となった回数を計数するカウンタと、モータ3のロック状態が検出された回数を計数するカウンタとを併用し、それぞれのカウンタの計数値に基づいて、閾値の補正を行うようにしてもよい。   The present invention can employ various embodiments other than the above-described embodiments. For example, a counter that counts the number of times that both terminals of the motor 3 become the same potential at a high potential and a counter that counts the number of times that the lock state of the motor 3 is detected are used together, and based on the count value of each counter Then, the threshold value may be corrected.

また、上記実施形態では、スイッチング素子としてリレーを用いた例を挙げたが、本発明は半導体のスイッチング素子を用いたモータ制御装置にも適用することができる。   Moreover, although the example which used the relay as a switching element was given in the said embodiment, this invention is applicable also to the motor control apparatus using the semiconductor switching element.

また、上記実施形態では、警告出力の例として、ランプ8の点灯や表示部へのメッセージ表示を例に挙げたが、オート動作を禁止するような信号を出力したり、警告内容をメモリにログデータとして記憶したりしてもよく、本発明における警告出力には、このような実施形態も含まれる。   In the above embodiment, as an example of warning output, lighting of the lamp 8 and message display on the display unit are given as examples. However, a signal that prohibits the automatic operation is output, or the warning content is logged in the memory. Such an embodiment is also included in the warning output in the present invention.

また、図6〜図9の実施形態では、マニュアル閉処理とオート閉処理の両方の場合に挟み込み検出を行う例を挙げたが、オート閉処理の場合にのみ挟み込み検出を行うようにしてもよい。   Further, in the embodiments of FIGS. 6 to 9, the example in which the pinching detection is performed in both the manual closing process and the automatic closing process has been described. However, the pinching detection may be performed only in the case of the automatic closing process. .

また、上記実施形態では、本発明をパワーウインドウ装置やシャッター制御装置に適用した例を挙げたが、本発明は車両の後部扉やサンルーフなどの開閉体を制御する場合にも適用することができる。さらに、本発明は開閉体に限らず、例えば車両のミラーの角度を調節するミラー制御装置などにも適用することができる。   Moreover, although the example which applied this invention to the power window apparatus and the shutter control apparatus was given in the said embodiment, this invention can be applied also when controlling opening-closing bodies, such as a rear door of a vehicle, and a sunroof. . Furthermore, the present invention is not limited to an opening / closing body, and can be applied to, for example, a mirror control device that adjusts the angle of a vehicle mirror.

本発明の実施形態に係るパワーウインドウ装置のブロック図である。It is a block diagram of a power window device concerning an embodiment of the present invention. 操作スイッチの一例を示した概略構成図である。It is the schematic block diagram which showed an example of the operation switch. 窓開閉機構の一例を示した図である。It is the figure which showed an example of the window opening / closing mechanism. 窓に物体が挟み込まれた状態を示す図である。It is a figure which shows the state by which the object was pinched | interposed into the window. パワーウインドウ装置の基本的な動作を示したフローチャートである。It is the flowchart which showed the basic operation | movement of the power window apparatus. マニュアル閉処理の詳細手順を示したフローチャートである。It is the flowchart which showed the detailed procedure of the manual closing process. オート閉処理の詳細手順を示したフローチャートである。It is the flowchart which showed the detailed procedure of the automatic closing process. マニュアル閉処理の他の例を示したフローチャートである。It is the flowchart which showed the other example of the manual closing process. オート閉処理の他の例を示したフローチャートである。It is the flowchart which showed the other example of the automatic closing process. マニュアル開処理の詳細手順を表したフローチャートである。It is a flowchart showing the detailed procedure of the manual opening process. オート開処理の詳細手順を表したフローチャートである。It is a flowchart showing the detailed procedure of the automatic opening process. シャッター開閉用の操作スイッチを示す概略図である。It is the schematic which shows the operation switch for shutter opening and closing. シャッターの外観図である。It is an external view of a shutter. シャッター制御装置の基本的な動作を示したフローチャートである。It is the flowchart which showed the basic operation | movement of the shutter control apparatus. シャッター開処理の詳細手順を示したフローチャートである。It is the flowchart which showed the detailed procedure of the shutter opening process. シャッター閉処理の詳細手順を示したフローチャートである。It is the flowchart which showed the detailed procedure of the shutter closing process. シャッター中立状態処理の詳細手順を示したフローチャートである。It is the flowchart which showed the detailed procedure of the shutter neutral state process. 本発明の他の実施形態に係るパワーウインドウ装置のブロック図である。It is a block diagram of a power window device concerning other embodiments of the present invention. 同装置における処理を示したフローチャートである。It is the flowchart which showed the process in the same apparatus. 同装置における閾値の変更を説明する図である。It is a figure explaining the change of the threshold value in the same apparatus. 本発明の他の実施形態に係るパワーウインドウ装置のブロック図である。It is a block diagram of a power window device concerning other embodiments of the present invention. 同装置における処理を示したフローチャートである。It is the flowchart which showed the process in the same apparatus. 同装置における閾値の変更を説明する図である。It is a figure explaining the change of the threshold value in the same apparatus. モータ駆動ブロックを示す図である。It is a figure which shows a motor drive block. モータ駆動回路の動作を説明する図である。It is a figure explaining operation | movement of a motor drive circuit. モータ駆動回路の動作を説明する図である。It is a figure explaining operation | movement of a motor drive circuit. モータ駆動回路の動作を説明する図である。It is a figure explaining operation | movement of a motor drive circuit. 挟み込みがあった場合のモータ制御のタイミングチャートである。It is a timing chart of motor control when there is pinching. 挟み込みがあった場合のモータ制御のタイミングチャートである。It is a timing chart of motor control when there is pinching. リレーの接点開閉時におけるアークの発生を説明する図である。It is a figure explaining generation | occurrence | production of the arc at the time of the contact opening / closing of a relay.

符号の説明Explanation of symbols

1 制御部
1a CPU
2 モータ駆動回路
3 モータ
4 ロータリエンコーダ
5 パルス検出回路
6 メモリ
7 操作スイッチ
8 ランプ
30 シャッター
50 操作スイッチ
61 閾値
62 カウンタ
62a 第1カウンタ
62b 第2カウンタ
62c 第3カウンタ
62d 第4カウンタ
100 窓
101 窓ガラス
RY1,RY2 リレー
X1,X2 接点
A,B ポート
A’,B’ 端子
+V 電源
1 Control unit 1a CPU
DESCRIPTION OF SYMBOLS 2 Motor drive circuit 3 Motor 4 Rotary encoder 5 Pulse detection circuit 6 Memory 7 Operation switch 8 Lamp 30 Shutter 50 Operation switch 61 Threshold 62 Counter 62a 1st counter 62b 2nd counter 62c 3rd counter 62d 4th counter 100 Window 101 Window glass RY1, RY2 relay X1, X2 contact A, B port A ', B' terminal + V power supply

Claims (8)

モータを正転および逆転させるための正転信号および逆転信号を出力する制御部と、
前記正転信号および逆転信号に基づいて動作するスイッチング素子により、モータに流す電流の方向を切り換えて、当該モータを駆動するモータ駆動回路と、
を備えたモータ制御装置において、
前記モータの回転状態が変化する際、前記スイッチング素子の寿命に影響を与えるような大きな負荷が当該素子に発生した場合に、その発生回数を計数する計数手段と、
前記計数手段により計数された回数に基づいて、スイッチング素子の寿命に対する警告を出力する出力手段と、
を更に備えたことを特徴とするモータ制御装置。
A controller that outputs a forward rotation signal and a reverse rotation signal for rotating the motor forward and backward, and
A switching element that operates based on the forward rotation signal and the reverse rotation signal, and switches a direction of a current that flows to the motor to drive the motor;
In a motor control device comprising:
When a large load that affects the life of the switching element is generated in the element when the rotation state of the motor changes, a counting unit that counts the number of occurrences of the load,
An output means for outputting a warning for the lifetime of the switching element based on the number of times counted by the counting means;
A motor control device further comprising:
請求項1に記載のモータ制御装置において、
前記モータにより駆動される開閉体の開動作および閉動作を指示する操作スイッチと、
前記開閉体の閉動作中に、当該開閉体に物体が挟み込まれたことを検出する挟み込み検出手段と、を更に備え、
前記計数手段は、前記挟み込み検出手段により検出された挟み込みの発生回数を計数し、
前記計数手段の計数値に対する閾値が予め設定されており、
前記出力手段は、前記計数手段の計数値が前記閾値を超えた場合に、警告を出力することを特徴とするモータ制御装置。
The motor control device according to claim 1,
An operation switch for instructing an opening operation and a closing operation of the opening / closing body driven by the motor;
A pinching detection means for detecting that an object is pinched in the opening and closing body during the closing operation of the opening and closing body;
The counting means counts the number of occurrences of pinching detected by the pinching detection means;
A threshold for the count value of the counting means is preset,
The motor control apparatus according to claim 1, wherein the output means outputs a warning when a count value of the counting means exceeds the threshold value.
請求項2に記載のモータ制御装置において、
前記スイッチング素子は、正転信号により動作して第1の接点が切り換わる第1のリレーと、逆転信号により動作して第2の接点が切り換わる第2のリレーとからなり、
前記第1の接点が切り換わることにより、モータの一方の端子が第1の接点を介して電源と接続されてモータが正転する一方、前記第2の接点が切り換わることにより、モータの他方の端子が第2の接点を介して電源と接続されてモータが逆転し、
前記制御部は、挟み込みが検出された場合に、正転信号と逆転信号を同時に出力して第1および第2のリレーを共に動作させ、第1および第2の接点を介して電源電圧によりモータの両端子を高電位で同電位に保持してモータの正転を停止させ、その後、正転信号の出力を停止し逆転信号のみを出力することによりモータを逆転させることを特徴とするモータ制御装置。
The motor control device according to claim 2,
The switching element includes a first relay that operates by a forward rotation signal to switch the first contact, and a second relay that operates by a reverse rotation signal to switch the second contact,
When the first contact is switched, one terminal of the motor is connected to the power source via the first contact and the motor rotates normally, while the second contact is switched, the other terminal of the motor Is connected to the power source via the second contact, and the motor reverses,
The controller outputs the forward rotation signal and the reverse rotation signal simultaneously to operate both the first and second relays when pinching is detected, and operates the motor by the power supply voltage via the first and second contacts. The motor control is characterized in that both terminals of the motor are held at the same potential at a high potential to stop the forward rotation of the motor, and then the forward rotation signal is stopped and only the reverse rotation signal is output to reverse the motor. apparatus.
請求項3に記載のモータ制御装置において、
前記制御部は、前記出力手段が警告を出力した場合、第1および第2のリレーを共に非動作状態にして、第1および第2の接点を介してモータの両端子を低電位で同電位に保持し、一定時間経過後に逆転信号を出力して第2のリレーを動作させることによりモータを逆転させることを特徴とするモータ制御装置。
The motor control device according to claim 3,
When the output means outputs a warning, the control unit disables both the first and second relays and sets both terminals of the motor to the same potential at a low potential via the first and second contacts. And a motor control device that reversely rotates the motor by outputting a reverse rotation signal and operating the second relay after a predetermined time has elapsed.
請求項3に記載のモータ制御装置において、
前記制御部は、挟み込み検出時以外でモータを逆転させる場合、第1および第2のリレーを共に非動作状態にして、第1および第2の接点を介してモータの両端子を低電位で同電位に保持し、一定時間経過後に逆転信号を出力して第2のリレーを動作させることによりモータを逆転させることを特徴とするモータ制御装置。
The motor control device according to claim 3,
When reversing the motor except when jamming is detected, the control unit sets both the first and second relays to the non-operating state, and causes both terminals of the motor to be kept at the same potential through the first and second contacts. A motor control device characterized in that the motor is reversely rotated by holding a potential and outputting a reverse rotation signal after a predetermined time has elapsed to operate the second relay.
請求項1に記載のモータ制御装置において、
前記計数手段は、モータの回転方向を反転させる際にモータの両端子を同電位にしてモータに回生制動をかけた回数を計数する計数手段であって、モータの両端子が低電位で同電位となった回数を計数する第1の計数手段と、モータの両端子が高電位で同電位となった回数を計数する第2の計数手段とからなることを特徴とするモータ制御装置。
The motor control device according to claim 1,
The counting means is a counting means for counting the number of times that regenerative braking is applied to the motor by setting both terminals of the motor to the same potential when reversing the rotation direction of the motor, and both terminals of the motor are at the same potential at a low potential. A motor control device comprising: a first counting means for counting the number of times of occurrence; and a second counting means for counting the number of times that both terminals of the motor have the same potential at a high potential.
請求項6に記載のモータ制御装置において、
前記第1の計数手段の計数値に対する閾値が予め設定されており、
前記第2の計数手段の計数値に基づいて前記閾値を変更し、
前記出力手段は、前記第1の計数手段の計数値が変更後の閾値を超えた場合に、警告を出力することを特徴とするモータ制御装置。
The motor control device according to claim 6,
A threshold for the count value of the first counting means is preset,
Changing the threshold based on the count value of the second counting means;
The output means outputs a warning when the count value of the first counting means exceeds a changed threshold value.
請求項1に記載のモータ制御装置において、
前記モータにより駆動される開閉体の開動作および閉動作を指示する操作スイッチと、
前記開閉体が原点位置にある場合にモータのロック状態を検出するロック検出手段と、を更に備え、
前記計数手段は、前記開閉体の駆動回数を計数する第3の計数手段と、前記モータのロック状態が検出された回数を計数する第4の計数手段とからなり、
前記第3の計数手段の計数値に対する閾値が予め設定されており、
前記第4の計数手段の計数値に基づいて前記閾値を変更し、
前記出力手段は、前記第3の計数手段の計数値が変更後の閾値を超えた場合に、警告を出力することを特徴とするモータ制御装置。
The motor control device according to claim 1,
An operation switch for instructing an opening operation and a closing operation of the opening / closing body driven by the motor;
Lock detecting means for detecting a lock state of the motor when the opening / closing body is at the origin position; and
The counting means comprises a third counting means for counting the number of times the opening / closing body is driven, and a fourth counting means for counting the number of times the locked state of the motor is detected,
A threshold for the count value of the third counting means is preset,
Changing the threshold based on the count value of the fourth counting means;
The motor control apparatus according to claim 1, wherein the output means outputs a warning when the count value of the third counting means exceeds the changed threshold value.
JP2007318366A 2007-12-10 2007-12-10 Motor control device Expired - Fee Related JP5078582B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007318366A JP5078582B2 (en) 2007-12-10 2007-12-10 Motor control device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007318366A JP5078582B2 (en) 2007-12-10 2007-12-10 Motor control device

Publications (2)

Publication Number Publication Date
JP2009142122A true JP2009142122A (en) 2009-06-25
JP5078582B2 JP5078582B2 (en) 2012-11-21

Family

ID=40872166

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007318366A Expired - Fee Related JP5078582B2 (en) 2007-12-10 2007-12-10 Motor control device

Country Status (1)

Country Link
JP (1) JP5078582B2 (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011250773A (en) * 2010-06-04 2011-12-15 Hitachi Koki Co Ltd Hedge trimmer
WO2013121623A1 (en) * 2012-02-15 2013-08-22 株式会社リブ技術研究所 Vehicle open/close portion control apparatus, and vehicle open/close portion control method
JP2017022940A (en) * 2015-07-14 2017-01-26 ファナック株式会社 Motor driving device having dynamic brake circuit
CN107002445A (en) * 2014-11-26 2017-08-01 爱信精机株式会社 The control device and control method of vehicle open/close part
CN112285556A (en) * 2020-09-27 2021-01-29 芜湖莫森泰克汽车科技股份有限公司 Quick detection method for skylight speed regulating motor
CN114397102A (en) * 2022-01-10 2022-04-26 深圳市佳迈自动化股份有限公司 Aging detection device for pressure switch

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105117301B (en) * 2015-08-14 2018-08-14 杭州华为数字技术有限公司 A kind of method and device of memory early warning

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH08275586A (en) * 1995-03-28 1996-10-18 Toshiba Corp Inverter
JP2004308200A (en) * 2003-04-04 2004-11-04 Yazaki Corp Motor movable device and its operation controlling method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH08275586A (en) * 1995-03-28 1996-10-18 Toshiba Corp Inverter
JP2004308200A (en) * 2003-04-04 2004-11-04 Yazaki Corp Motor movable device and its operation controlling method

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011250773A (en) * 2010-06-04 2011-12-15 Hitachi Koki Co Ltd Hedge trimmer
WO2013121623A1 (en) * 2012-02-15 2013-08-22 株式会社リブ技術研究所 Vehicle open/close portion control apparatus, and vehicle open/close portion control method
CN103392048A (en) * 2012-02-15 2013-11-13 利禄株式会社 Vehicle open/close portion control apparatus, and vehicle open/close portion control method
JP5632959B2 (en) * 2012-02-15 2014-11-26 株式会社リブ技術研究所 Vehicle opening / closing part control device and vehicle opening / closing part control method
US9115527B2 (en) 2012-02-15 2015-08-25 Rib Laboratory, Inc. Control device at opening/closing section of vehicle and method for controlling opening/closing section of vehicle
CN103392048B (en) * 2012-02-15 2015-10-14 利禄株式会社 The method of the control device of the opening/closing portion of vehicle and the opening/closing portion of control vehicle
US10253544B2 (en) 2014-11-26 2019-04-09 Aisin Seiki Kabushiki Kaisha Control device and control method of opening and closing member for vehicle
CN107002445A (en) * 2014-11-26 2017-08-01 爱信精机株式会社 The control device and control method of vehicle open/close part
US10054640B2 (en) 2015-07-14 2018-08-21 Fanuc Corporation Motor driving device including dynamic braking circuit
JP2017022940A (en) * 2015-07-14 2017-01-26 ファナック株式会社 Motor driving device having dynamic brake circuit
CN112285556A (en) * 2020-09-27 2021-01-29 芜湖莫森泰克汽车科技股份有限公司 Quick detection method for skylight speed regulating motor
CN114397102A (en) * 2022-01-10 2022-04-26 深圳市佳迈自动化股份有限公司 Aging detection device for pressure switch
CN114397102B (en) * 2022-01-10 2023-12-19 深圳市佳迈自动化股份有限公司 Pressure switch aging detection device

Also Published As

Publication number Publication date
JP5078582B2 (en) 2012-11-21

Similar Documents

Publication Publication Date Title
JP5078582B2 (en) Motor control device
JP4855173B2 (en) Opening and closing body control device
US20060290310A1 (en) Motor control apparatus
JP2007009413A (en) Window opening-closing control device
JP2006265919A (en) Opening-closing control device
JP2006226032A (en) Power window device
JP2008002089A (en) Control unit for opening/closing body for vehicle
JP2007151380A (en) Motor control unit
JP2014055431A (en) Vehicle window opening/closing control device
JP6012569B2 (en) Power window device for vehicle
US10253544B2 (en) Control device and control method of opening and closing member for vehicle
JP2009052247A (en) Opening/closing body controller
JP4781126B2 (en) Opening and closing body control device
JP2007327240A (en) Opening/closing body controller and power window device
JP2007009573A (en) Opening/closing control device
US9647587B2 (en) System and method for determining the position of a moving part driven by an electric motor
JP4732628B2 (en) Opening / closing member control device and opening / closing member origin position setting method in opening / closing member control device
JP2017160708A (en) Opening-and-closing member control device
JP6332676B2 (en) Drive device
JP2003129753A (en) Opening/closing member controller and opening/closing member controlling method
JP5095303B2 (en) Switchgear
JP2003025855A (en) Device and method for controlling sunroof
JP2002371750A (en) Opening and closing member control device, and origin position setting method of opening and closing member in opening and closing member control device
JP3056934B2 (en) Opening / closing body opening / closing control method
JP2003003739A (en) Open-close member controller and method for setting place of origin of open-close member in its controller

Legal Events

Date Code Title Description
A711 Notification of change in applicant

Free format text: JAPANESE INTERMEDIATE CODE: A712

Effective date: 20100726

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20100804

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20120502

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20120522

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20120717

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: 20120828

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20120828

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

Free format text: PAYMENT UNTIL: 20150907

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Ref document number: 5078582

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees