Method for controlling speed of motor for driving robot

Information

  • Patent Grant
  • 6278253
  • Patent Number
    6,278,253
  • Date Filed
    Monday, August 2, 1999
    25 years ago
  • Date Issued
    Tuesday, August 21, 2001
    23 years ago
Abstract
A motor speed controlling method is provided in a motor speed controlling apparatus including a motor for driving the robot, a position controller for controlling position of a motor and a main controller for producing a speed command profile of a smooth curve to control the motor based on a robot operational command input by a user and transmit the produced speed command profile to the position controller. The motor speed controlling method includes a step of producing a speed command profile having an acceleration profile of a smooth curve within a predetermined robot control interval so that a robot can be controlled on a real-time basis. Accordingly, vibration and noise of the motor are reduced and thus a control reliability is enhanced.
Description




BACKGROUND OF THE INVENTION




1. Field of the Invention




The present invention relates to a motor speed controlling method, and more particularly, to a method for controlling speed of a motor for driving an industrial robot.




2. Description of the Related Art




In general, an industrial robot includes mechanical parts for moving a target object on a three-dimensional space or performing a requested job. The robot includes a body which is a central portion for supporting a robot, a manipulator having an arm for moving an end effector into which a tool necessary for a requested job is fitted, to a particular position in a working area, a controller for controlling the manipulator, and a power source for supplying an electric power to the body, the manipulator and the controller. A servo motor is mounted in the arm of the manipulator and the controller controls the servo motor to perform an allocated job.




Generally, a controller includes a main controller, a position controller and a servo driver for driving a servo motor. The main controller produces a speed command profile based on a current position and a user operation command such as a target position input by a user and transfers the produced speed command profile to the position controller. The position controller controls the servo driver based on the received speed command profile and drives the servo motor to move an arm from a certain point to another point. Meanwhile, the position controller receives a current position from an encoder mounted in the servo motor and feedback-controls the position of the arm.





FIGS. 1



a


and


1




a


′ show user command paths according to the conventional art.

FIGS. 1



b


and


1




b


′ show speed command profiles with respect to

FIGS. 1



a


and


1




a


′, respectively according to the conventional art.

FIGS. 1



c


and


1




c


′ show acceleration paths with respect to

FIGS. 1



a


and


1




a


′, respectively, according to the conventional art.




In a conventional robot, the main controller produces a path plan such as a speed trace in which a final target value is planned according to a movement command from a user as shown in

FIGS. 1



a


and


1




a


′. Then, the main controller produces a trajectory plan profile such as a speed command profile in which an actual acceleration and deceleration is performed based on the path plan as shown in

FIGS. 1



b


and


1




b′.






In other words, according to the conventional robot, the main controller produces a path plan to control a servo motor which drives a manipulator, and then produces a trajectory plan profile based on the path plan. As a result, a response to a user command is not fast. Further, even though a trajectory plan profile is given as a continuous value of a smooth curve, a number of points where a differentiation is impossible exist in a jerk such as an acceleration profile as shown in

FIGS. 1



c


and


1




c


′. Since an acceleration change rate is sharp in the vicinity of the differentiation-impossible points, vibration and noise are generated in the motor. The vibration and noise lowers reliability with respect to performance of the robot and gives a shock to mechanical components including a motor, thereby shortening the lifetime of the robot. The vibration and noise is conspicuously severe in a large-scale mechanical apparatus such as an industrial robot which is greatly influenced by the inertia and gravity.




SUMMARY OF THE INVENTION




To solve the above problems, it is an object of the present invention to provide a motor speed controlling method capable of performing a real-time control, in which a speed command profile and an acceleration profile have a continuous value of a smooth curve, respectively, and the time taken when a changed speed reaches an actual operational speed of a motor is reduced.




To accomplish the above object of the present invention, there is provided a motor speed controlling method for use in a motor speed controlling apparatus including a motor for driving a robot, a position controller for controlling the motor, and a main controller for producing a speed command profile of a smooth curve for controlling the motor based on a robot operational command input by a user and transmitting the produced speed command profile to the position controller, the motor speed controlling method comprising the step of producing a speed command profile having an acceleration profile of a smooth curve within a predetermined robot control interval so that a robot can be controlled on a real-time basis.




Preferably, the speed command profile producing step comprises an operational control preparation step for obtaining a position change amount ΔP, the maximum number of intervals TP


max


, and the number of acceleration intervals TA


max


according to the following expressions:




Formula 1








Δ





P

=


P
g

-

P
c



;






TP
max

=


Δ





P


V
m



;

and






TA
max

=

A
p











wherein P


g


is a target position, P


c


is a current position, V


m


is a maximum speed per unit time and A


p


is an acceleration interval and is a value set by the user robot operational command.




It is preferable that the operational control preparation step comprises the step of obtaining the maximum number of intervals TP


max


, and the number of acceleration intervals TA


max


according to the following expressions:




Formula 2







x
=


TP
max

×

TA
max



;






TA
max

=

x


;
and





TP
max

=

x

TA
max












where the maximum number of intervals TP


max


is smaller than the number of acceleration intervals TA


max


.




It is also preferable that the operational control preparation step comprises the step of obtaining a position change amount ΔP


1


of one interval according to the following expression, using the obtained position change amount ΔP, the obtained maximum number of intervals TP


max


, and the obtained number of acceleration intervals TA


max


, and setting initial values of an initial speed S


i


, a maximum speed S


m


and a final speed S


f


into 0, 1 and 0, respectively:




Formula 3







Δ






P
1


=



Δ





P


TP
max


.











Meanwhile, the speed command profile producing step comprises the step of setting an initial value, TP


c


, of an interval counter which increases by one(1) whenever the speed command profile is produced, to zero, and obtaining values (Aa


0


, Aa


1


, Aa


2


) for calculating a current speed during acceleration, values (Da


0


, Da


1


) for calculating a current speed during deceleration, the number of acceleration intervals T


acc


, the number of deceleration intervals T


dec


, and the number of acceleration and constant speed intervals TP


i


, in order to obtain values of variables necessary for production of the speed command profile, according to the following expressions:




Formula 4








T
acc

=


TA
max

×

&LeftBracketingBar;


S
m

-

S
i


&RightBracketingBar;



;






T
dec

=


TA
max

×

&LeftBracketingBar;


S
m

-

S
f


&RightBracketingBar;



;








TP
i

=






TP
max

-

(



T
acc

×

S
i


+



(


S
m

-

S
f


)

×

T
acc


2

+

















(


S
m

-

S
f


)

×

T
dec


2

)

;













Formula 5








Aa
0

=

S
i


;






Aa
1

=


3


T
acc

×

T
acc



×

(


S
m

-

S
i


)



;






Aa
2

=



-
2



T
acc

×

T
acc

×

T
acc



×

(


S
m

-

S
i


)



;






Da
0

=


3


T
dec

×

T
dec



×

(


S
m

-

S
f


)



;
and





Da
1

=



-
2



T
dec

×

T
dec

×

T
dec



×


(


S
m

-

S
f


)

.












It is preferable that when a value of the expression






&LeftBracketingBar;

{



T
acc

×

S
i


+



(


S
m

-

S
i


)

×

T
acc


2

+


(


S
m

-

S
f


)

×

T
dec



}

&RightBracketingBar;










is larger than a predetermined constant, the number of constant speed intervals TP


i


and the maximum speed S


m


are obtained by the following expressions:




Formula 6








TP
i

=


TP
i

+




T
acc

×

S
i


+



(


S
m

-

S
i


)

×

T
acc


2

+



(


S
m

-

S
f


)

×

T
dec


2

-

S
m


VELCOPENSATION



;



and




S
m

=



(


TP
max

-


S
i

×

T
acc



)



T
acc

+

T
dec

+


TP
i

×
2



.











Also, under the above conditions, the current speed value V


c


is calculated to produce a speed command profile, and the obtained current speed V


c


and the current position P


c


are added to update the current position P


c


:




{circle around (1)} where TP


c


<T


acc






Formula 7






V


c


=ΔP


1


×(Aa


0


+Aa


1


×TP


c


×TP


c


+Aa


2


×TP


c


×TP


c


×TP


c


);






{circle around (2)} where TP


c


<TP


i






Formula 8






V


c


=ΔP


1


(Da


0


×TP


c


×TP


c


+Da


1


×TP


c


×TP


c


×TP


c


); and






{circle around (3)} in the remaining cases




Formula 9






V


c


=ΔP


1


×S


m


.













BRIEF DESCRIPTION OF THE DRAWINGS




The object and other advantages of the present invention will become more apparent by describing in detail the structures and operations of the present invention with reference to the accompanying drawings, in which:





FIGS. 1



a


and


1




a


′ show user command paths according to the conventional art;





FIGS. 1



b


and


1




b


′ show speed command profiles with respect to

FIGS. 1



a


and


1




a


′, respectively;





FIGS. 1



c


and


1




c


′ show an acceleration profile with respect to

FIGS. 1



a


and


1




a


′, respectively;





FIG. 2

is a schematic block diagram of a robot according to a preferred embodiment of the present invention;





FIG. 3

is a schematic block diagram of a main controller according to a preferred embodiment of the present invention;





FIG. 4

is a software block diagram for producing a speed command profile and an acceleration profile;





FIG. 5

is a flowchart view for producing a speed command profile and an acceleration profile in an operational controller;





FIGS. 6



a


and


6




b


are graphical views showing a speed command profile and an acceleration profile in a constant speed interval according to the present invention, respectively;





FIGS. 7



a


and


7




b


are graphical views respectively showing a speed command profile and an acceleration profile in the case that the speed in a constant speed interval is changed into a 60% speed;





FIGS. 8



a


and


8




b


are graphical views respectively showing a speed command profile and an acceleration profile in the interval where the constant speed interval is not included therein; and





FIGS. 9



a


and


9




b


are graphical views respectively showing a speed command profile and an acceleration profile when the speed is changed into a 60% speed in the interval where a constant speed interval is not included therein.











DETAILED DESCRIPTION OF THE INVENTION




A preferred embodiment of the present invention will be described in detail with reference to the accompanying drawings.




Referring to

FIG. 2

, a robot according to the present invention includes a main controller


1


, a position controller


3


for controlling a servo driver


5


and at the same time feedback-controlling the position of the robot, based on the speed command profile supplied from the main controller


1


. The servo driver


5


receives a command from the position controller


3


to drive a servo motor


7


, and the servo motor


7


mounted in the robot drives the robot actually.




Referring to

FIG. 3

, the main controller


1


includes a communications module


11


for communication with a user interface unit


2


by which an operational command for the robot can be programmed by a user, a central processing unit (CPU)


13


for producing a speed command profile, a read only memory (ROM)


15


for storing a robot system control program as an execution code, a random access memory (RAM)


16


for storing the user command program and variable information necessary for operation of speed and acceleration profiles in the CPU


13


, and a dual port RAM (DPRAM)


17


for communication with the position controller


3


with respect to speed command and position information.




By the above configuration, if an electric power is supplied to the robot, a control execution code stored in the ROM


15


operates and data necessary for execution of the control execution code is recorded in the RAM


16


. If a user inputs a command program by use of the user interface unit


2


, the CPU


13


produces a speed command profile and an acceleration profile based thereon.





FIG. 4

is a software block diagram for producing a speed command profile and an acceleration profile which is performed in the main controller


1


.

FIG. 5

is a flowchart view for producing a speed command profile and an acceleration profile in an operational controller


140


of FIG.


4


.




Hereinafter, a process for producing a speed command profile by the main controller


1


according to the present invention will be described in detail with reference to the accompanying drawings.




If a user command program made up into a predetermined robot language is input to the main controller


1


via the user interface unit


2


, a robot language interpreter


110


interprets the meaning thereof. In the case that the interpreted command is an operational command, the robot language interpreter


110


sends the interpreted command to an operation controller


120


. The operation controller


120


, which receives an operation instruction and a target position P


g


, performs the operations to be described below, by use of the target position P


g


and a value of other user-set variables, to thereby prepare an operation control (S


1


). That is, in the operation control preparation step (S


1


), a position change amount ΔP, corresponding to a difference value between a current position P


c


and a target position P


g


, the maximum number of intervals TP


max


, and the number of acceleration intervals TA


max


are given by the following expressions:




Formula 1








Δ





P

=


P
g

-

P
c



;






TP
max

=


Δ





P


V
m



;

and






TA
max

=

A
p











wherein P


g


is a target position, P


c


is a current position, V


m


is a maximum speed per unit time and A


p


is an acceleration interval and is a value set by the user robot operational command.




Here, since it is not logical if the maximum number of intervals TP


max


is smaller than the number of acceleration intervals TA


max


, the maximum number of intervals TP


max


and the number of acceleration intervals TA


max


are obtained again using the following expressions:




Formula 2







x
=


TP
max

×

TA
max



;






TA
max

=

x


;
and





TP
max

=


x

TA
max


.











Using the obtained position change amount ΔP1, the obtained maximum number of intervals TP


max


, and the obtained number of acceleration intervals TA


max


, a position change amount ΔP


1


of one interval is obtained according to the following expression:




Formula 3







Δ






P
1


=



Δ





P


TP
max


.











Initial values of an initial speed S


i


, a maximum speed S


m


and a final speed S


f


are set into 0, 1 and 0, respectively:




As described above, if the position change amount ΔP, the maximum number of intervals TP


max


, the number of acceleration intervals TA


max


, and the position change amount ΔP


1


of one interval are obtained and then the initial speed S


i


, the maximum speed S


m


and the final speed S


f


are set, the operation control preparation step S


1


is completed.




However, in the case that the position change amount ΔP obtained in the operation control preparation step S


1


is smaller than a minimum position movement amount MINPOSITION which is a constant value set in the robot system control program stored in the ROM


15


, it is judged that the robot has been already positioned at a target position and then the operation control is completed.




If the operation control preparation is completed, the operation controller


120


obtains a variable value necessary for producing a speed command profile (S


2


). In this step S


2


, values (Aa


0


, Aa


1


, Aa


2


) for calculating a current speed during acceleration, values (Da


0


, Da


1


) for calculating a current speed during deceleration, the number of acceleration intervals T


acc


, the number of deceleration intervals T


dec


, and the number of acceleration and constant speed intervals TP


i


are obtained.




First, the number of acceleration intervals T


acc


and the number of deceleration intervals T


dec


are first obtained, and then the number of acceleration and constant speed intervals TP


i


is obtained, according to the following expressions:




Formula 4












T
acc

=


TA
max

×

&LeftBracketingBar;


S
m

-

S
i


&RightBracketingBar;



;
and








T

dec






=


TA
max

×


&LeftBracketingBar;


S
m

-

S
f


&RightBracketingBar;

.









TP
i

=






TP
max

-

(



T
acc

×

S
i


+



(


S
m

-

S
f


)

×

T
acc


2

+


















(


S
m

-

S
f


)

×

T
dec


2

)


.

























Here, when a value resulting from the expression






&LeftBracketingBar;

{



T
acc

×

S
i


+



(


S
m

-

S
i


)

×

T
acc


2

+


(


S
m

-

S
f


)

×

T
dec



}

&RightBracketingBar;










is larger than a speed correction reference value VELCOMPENSATION which is a predetermined constant value set in the root system control program stored in the ROM


15


, it is beyond the reliable control range set by the robot user. Thus, the numbers0 of constant speed intervals TP


i


and the maximum speed S


m


are obtained again by the following expressions:




Formula 6












TP
i

=


TP
i

+




T
acc

×

S
i


+



(


S
m

-

S
i


)

×

T
acc


2

+



(


S
m

-

S
f


)

×

T
dec


2

-

S
m


VELCOPENSATION



;







and


                          









S
m

=



(


TP
max

-


S
i

×

T
acc



)



T
acc

+

T
dec

+


TP
i

×
2



.

            





















Then, the Aa


0


, Aa


1


, Aa


2


, Da


0


, and Da


1


are obtained by using the following expressions:




Formula 5












Aa
0

=

S
i


;









Aa
1

=


3


T
acc

×

T
acc



×

(


S
m

-

S
i


)



;









Aa
2

=



-
2



T
acc

×

T
acc

×

T
acc



×

(


S
m

-

S
i


)



;









Da
0

=


3


T
dec

×

T
dec



×

(


S
m

-

S
f


)



;
and








Da
1

=



-
2



T
dec

×

T
dec

×

T
dec



×


(


S
m

-

S
f


)

.





















Meanwhile, TP


c


is an interval counter and an initial value is set as zero, which increases by one whenever a speed command profile is produced.




The next step S


3


is a step for producing a speed command profile with the calculation results. Also, the current speed value V


c


is calculated to produce a speed command profile, in which case the current speed value V


c


is selectively calculated under the following conditions:




{circle around (1)} where TP


c


<T


acc






Formula 7






V


c


=ΔP


1


×(Aa


0


+Aa


1


×TP


c


×TP


c


+Aa


2


×TP


c


×TP


c


×TP


c


);






{circle around (2)} where TP


c


<TP


i






Formula 8






V


c


=ΔP


1


×(Da


0


×TP


c


×TP


c


+Da


1


×TP


c


×TP


c


×TP


c


); and






{circle around (3)} in the remaining cases




Formula 9






V


c


=ΔP


1


×S


m


.






Since the obtained current speed V


c


means a current movement distance per unit time, the current speed V


c


is added to the current position P


c


to update the current position P


c


.




Then, a speed command transmitter


130


stores the P


c


value in the DPROM


17


and then informs the position controller


3


that the current position has been updated (S


4


).




Also, the operation controller


120


compares the position change amount ΔP between the first input target position P


g


and the updated current position P


c


with the minimum position movement amount MINPOSITION. If the position change amount is smaller than the minimum position movement amount, the controller


120


judges that the current is the target position (S


5


), to then complete the operation control. However, if the position change amount is equal to or larger than the minimum position movement amount, the controller


120


judge that the current position is not the target position (S


5


), and then, checks whether a user command speed S has been altered (S


6


).




If it is judged that the user command speed S has not been altered in step S


6


, the program returns to the speed command profile production step S


3


to reach the target position. If it is judged that the user command speed S has been altered in step S


6


, a variable value necessary for production of a speed command profile is obtained again in step S


2


. Then, based on the newly obtained speed command profile, a speed command profile is produced again (S


3


).




The operation controller


120


completes the operation control if it is judged to reach the target position through the above procedures,





FIGS. 6



a


through


9




b


show a speed command profile and an acceleration profile which are obtained through the above procedures. In more detail,

FIGS. 6



a


and


6




b


are graphical views respectively showing a speed command profile and an acceleration profile in a constant speed interval according to the present invention.

FIGS. 7



a


and


7




b


are graphical views respectively showing a speed command profile and an acceleration profile in the case that the speed in a constant speed interval is changed into a 60% speed.

FIGS. 8



a


and


8




b


are graphical views respectively showing a speed command profile and an acceleration profile in the interval where the constant speed interval is not included therein.

FIGS. 9



a


and


9




b


are graphical views respectively showing a speed command profile and an acceleration profile, when the speed is changed into a 60% speed in the interval where a constant speed interval is included therein.




As illustrated in

FIGS. 6



a


through


9




b


, even in the case that a speed change has occurred in a constant speed interval, the speed command profile and the acceleration profile have a continuous change amount of a smooth curve, respectively. Thus, it can be seen from the accompanying drawings that there are no points of sharp change in acceleration speed as well as in speed.




As described above, the present invention provides a motor speed controling method having a continuous change amount in a speed command profile and an acceleration profile, to accordingly reduce vibration and noise and improve a control reliability.




In addition, the conventional motor speed controlling method adopts two steps of producing a path plan of a target value based on a user driving command and then producing a speed command profile. The motor speed controlling method can immediately produce a speed command profile according to a target value. Thus, although a user speed command is altered during production of a speed command profile, the speed command profile can be produced immediately. Accordingly, a response to the speed change is very fast enough to enabling the robot to be controlled on a real-time basis.




Although the present invention has been described in connection with preferred embodiment thereof, it will be appreciated by those skilled in the art that additions, modifications, substitutions and deletions not specifically described may be made without departing from the spirit and scope of the invention as defined in the appended claims.



Claims
  • 1. A motor speed controlling method for use in a motor speed controlling apparatus including a motor for driving a robot, a position controller for controlling the motor, and a main controller for producing a speed command profile of a smooth curve to control the motor based on a robot operational command input by a user and transmit the produced speed command profile to the position controller, the motor speed controlling method comprising the step of:producing a speed command profile having an acceleration profile of a smooth curve within a predetermined robot control interval so that a robot can be controlled on a real-time basis, said speed command profile producing step comprising an operational preparation step for obtaining a position change amount ΔP, the maximum number of intervals TPmax, and the number of acceleration intervals TAmax according to the following expressions: Formula 1 Δ⁢ ⁢P=Pg-Pc;TPmax=Δ⁢ ⁢PVm;andTAmax=Apwherein Pg is a target position, Pc is a current position, Vm is a maximum speed per unit time and Ap is an acceleration interval and is a value set by the user robot operational command.
  • 2. The motor speed controlling method according to claim 1, wherein said operational control preparation step comprises the step of obtaining the maximum number of intervals TPmax, and the number of acceleration intervals TAmax according to the following expressions:Formula 2 x=TPmax⁢xTAmax;⁢⁢TAmax=x;and⁢⁢TPmax=xTAmax where the maximum number of intervals TPmax is smaller than the number of acceleration intervals TAmax.
  • 3. The motor speed controlling method according to claim 1, wherein said operational control preparation step comprises the steps of obtaining a position change amount ΔP1 of one interval according to the following expression, using the obtained position change amount ΔP, the obtained maximum number of intervals TPmax, and the obtained number of acceleration intervals TAmax and setting initial values of an initial speed Si, a maximum speed Sm and a final speed Sf into 0, 1 and 0, respectively:Formula 3 Δ⁢ ⁢P1=Δ⁢ ⁢PTPmax.
  • 4. The motor speed controlling method according to claim 3, wherein said speed command profile producing step comprises the step of setting an initial value, TPc, of an interval counter which increases by one whenever the speed command profile is produced, to zero, and obtaining values (Aa0, Aa1, Aa2) for calculating a current speed during acceleration, values (Da0, Da1) for calculating a current speed during deceleration, the number of acceleration intervals Tacc, the number of deceleration intervals Tdec, and the number of acceleration and constant speed intervals TPi, in order to obtain values of variables necessary for production of the speed command profile, according to the following expressions:Formula 4 Tacc=TAmax×&LeftBracketingBar;Sm-Si&RightBracketingBar;;and⁢⁢Tdec⁢ =TAmax×&LeftBracketingBar;Sm-Sf&RightBracketingBar;.⁢TPi= ⁢TPmax-(Tacc×Si+(Sm-Sf)×Tacc2+ ⁢(Sm-Sf)×Tdec2). Aa0=Si;⁢⁢Aa1=3Tacc×Tacc×(Sm-Si);⁢⁢Aa2=-2Tacc×Tacc×Tacc×(Sm-Si);⁢⁢Da0=3Tdec×Tdec×(Sm-Sf);and⁢⁢Da1=-2Tdec×Tdec×Tdec×(Sm-Sf).
  • 5. The motor speed controlling method according to claim 4, wherein when a value resulting from the &LeftBracketingBar;{Tacc×Si+(Sm-Si)×Tacc2+(Sm-Sf)×Tdec}&RightBracketingBar;is larger than a predetermined constant, the number of constant speed intervals TPi and the maximum speed Sm are obtained by the following expressions:Formula 6 TPi=TPi+Tacc×Si+(Sm-Si)×Tacc2+(Sm-Sf)×Tdec2-SmVELCOPENSATION;⁢⁢and⁢                          ⁢⁢Sm=(TPmax-Si×Tacc)Tacc+Tdec+TPi×2.
  • 6. The motor speed controlling method according to claim 5, wherein the current speed value Vc is calculated to produce a speed command profile, and the obtained current speed Vc and the current position Pc are added to update the current position Pc under the following conditions:{circle around (1)} where TPc<Tacc Formula 7 Vc=ΔP1×(Aa0+Aa1×TPc×TPc+Aa2×TPc×TPc×TPc); {circle around (2)} where TPc<TPi Formula 8 Vc=ΔP1×(Da0×TPc×TPc+Da1×TPc×TPc×TPc); and {circle around (3)} in the remaining cases Formula 9 Vc=ΔP1×Sm.
Priority Claims (1)
Number Date Country Kind
99-24365 Jun 1999 KR
US Referenced Citations (6)
Number Name Date Kind
4529921 Moribe Jul 1985
4912753 Evans, Jr. Mar 1990
5373439 Jeon Dec 1994
5684374 Chaffee Nov 1997
5804941 Ray Sep 1998
5892345 Olsen Apr 1999