In situ Measurement of Robot Motor Electrical Constants Peter I. Corke Senior Research Scientist CSIRO Division of Manufacturing Technology P.O. Box 883, Kenmore, Australia. 4069 Fax: +61-7-212-4681 pic@brb.dmt.csiro.au 1 Abstract Motor torque constant is an important parameter in modeling and controlling a robot axis. In practice this parameter can vary considerably from the manufacturer's specication, if available, and this makes it desirable to characterise individual motors. Traditional techniques require that the motor be removed from the robot for testing, or that an elaborate technique involving weights and pulleys be employed. This paper describes a novel method for measuring the torque constant of robot servo motors in situ and is based on the equivalence of motor torque and back EMF constants. It requires a very simple experimental procedure, utilizes existing axis position sensors, and eliminates eects due to static friction and joint cross coupling. A straightforward extension to this approach can provide a measurement of motor armature impedance. Experimental results obtained for a Puma 560 are discussed and compared with other published results. 1 Introduction A large number of existing robot manipulators employ permanent magnet DC motors. For these motors the torque constant, Km , relates the torque output, m , to the armature current, im m = Km im (1) and is an important parameter in control system design, modeling, and the implementation of computed-torque control algorithms. The inverse form of (1) is used when estimating joint torque from measured motor current. Authorita1 2 tive specications or other details of the motors used in commercially available robots is considered proprietary information and is not generally made available. Several reports 2{4 in which torque constants have been measured show considerable variation between similar type motors on a single robot, as well as between similar robots. In most cases the measured torque constant is less than the manufacturer's specication. Torque constant reduces gradually with time due to de-magnetization, but the eect is hastened when the motor current 5 rating is exceeded. For all these reasons it is frequently necessary to determine the actual torque constant for each motor within a robot. Motor torque constant is frequently measured by applying known torque loads to robot joints in position control mode and measuring the current demanded by the servo system to resist that load. The experimental procedure is time consuming and may require pulleys, weights and software to position or move the various robot joints. This paper describes a novel method for determining the torque constant of permanent magnet DC servo motors that is very simple | for each joint, the motor is electrically disconnected from the power amplier and the corresponding robot link is moved around by hand while motor shaft angle and motor terminal voltage are recorded. The open-circuit voltage produced is due to the back EMF (electro-motive force measured in Volts) of the permanent magnet motor. Straightforward processing of the acquired data leads to a determination of the motor torque constant. Section 2 reviews fundamental principles of DC servo motor operation and denes the notation to be used. Section 3 describes the proposed approach and 3 experimental method in detail. Section 4 compares torque constant measurements obtained by the new method with those of the conventional method, and also discusses other published results. An extension to the determination of motor armature impedance is given in section 5, and nally, section 6 presents the conclusions. 2 Motor model For a permanent magnet DC motor we may write 6 = 2Z im = Km im Z d d Eb = = Km 2 dt dt (2) m where is the magnetic ux due to the eld, Z (3) is the number of armature windings, Eb the back EMF, and is the motor shaft angle. If a consistent set of units is used, such as SI, then the torque constant in Nm/A and back EMF constant in Vs/rad will have the same numerical value. Armature reaction is the weakening of the ux density of the permanent magnet eld, by the MMF (magneto-motive force measured in Ampere-turns) due to armature current. This could potentially cause the torque constant to decrease as armature current is increased. However according to Kenjo the ux 6 density increases at one end of the pole and decreases at the other, maintaining the average ux density. Should the ux density become too low at one end of the pole, permanent de-magnetization can occur. A frequent cause of demagnetization is overcurrent at starting, or during deceleration. A reduction of ux density leads to reduction of torque constant by (2). 4 An equivalent circuit for the servo motor is given in Figure 1. This shows motor impedance comprising resistance, Rm , and inductance, Lm . Rs is a shunt resistor which provides a current feedback signal to the `power' amplier. The measured motor terminal voltage is Vt dim = Km d + ( Rs + Rm )im + Lm dt dt (4) which has components due to back EMF, resistance and inductance respectively. The contact potential dierence at the brushes introduces a voltage drop, which is typically around 1 to 1.5V and which will be ignored here. 6 3 Torque constant measurement Back EMF can be measured when the motor is operated open-circuit as a generator. When im = 0 the motor terminal voltage (4) is equal to the back EMF, that is Vt = Km _ (5) This is the basis of textbook approaches to torque constant measurement, where the motor under test is rotated by another motor at constant speed and the terminal voltage measured. For a robot manipulator this approach is clearly impractical, requiring that the motors be removed and an appropriate test rig is available. The conventional approach to in situ measurement is thus to apply known torque loads to the motor and measure the resulting motor current. However this can be complicated by the eects of static friction since some of the applied torque is resisted by the stiction mechanism not the motor, leading to errors 5 in measured torque constant. Lloyd uses an elaborate procedure based on 2 the work done in raising and lowering a mass, so as to cancel out the eects of friction. At best this approach is time consuming and requires pulleys and weights as well as software to position or move the various robot joints. The approach proposed here is based on the measurement of back EMF but without the need for constant speed motion. The motor is disconnected from the power amplier (by removing the fuse) and a time history of terminal voltage and motor shaft angle or velocity is recorded as the joint is manually `backdriven', see Figure 2. The problem is transformed into one of establishing the relationship between back EMF and motor shaft speed, which is immune to the eects of static friction. The experimental procedure based on open-circuit terminal voltage is far simpler and less time consuming than the torque load approach. If the motor contains a tachometer then solution of (5) is straightforward, but requires accurate knowledge of the tachometer gain. In the more common situation where the robot motor does not incorporate a tachometer, velocity must be estimated from the derivative of measured joint angle. Using a 2-point derivative approximation equation (5) can be written in ARX form as Vt = KTm (1 ? z ? ) 1 (6) to facilitate parameter identication. In this work MATLAB and the System Identication Toolbox function `arx()' were used to t a model of the form 7 Vt = (b + z ? b ) 1 1 2 (7) to the measured data using a batch least-squares procedure. The magnitude of 6 the estimated coecients ^b and ^b agreed to within 0:3%. From these identied 1 2 coecients the torque constant is taken as being Km = T ^ b1 ? ^b 2 (8) 2 The eect of other derivative approximations such as 3-point and 5-point derivatives have not been investigated. The results of this procedure are summarized in the rightmost column of Table 1. The results from this method agree with the load-test method on the same robot to within 2%. The armature reaction eect, if present, would be expected to give open-circuit values of Km that were consistently greater than the load test values, due to eld weakening in the latter case. There is no evidence of this being a signicant eect. The considerable discrepancy for joint 6 is the due to cross-coupling in the wrist mechanism. In the load-test procedure, a torque applied to link 6, is transferred to the all the wrist motors. The torque relationship is m = G? l (9) 1 where m is the vector of motor torques, l the vector of torques applied to the links, and G represents the transmission of the manipulator in matrix form. Using knowledge of the gear ratios a unit torque applied to link 6 results in 8 motor torques of " m = 0 0 0 ?0:000138 ?0:002510 0:013040 # (10) Only 83% of the applied torque is transferred to joint 6, 16% to joint 5 and around 1% to joint 4. Thus the torque constant will be overestimated, the true 7 value being 83% of the experimental value or 0:0548. This is close to the value determined directly by the open-circuit method. 3.1 Experimental method The experiments were conducted on a Puma 560 robot with a Mark 1 controller. The motors were disconnected from the power amplier, one at a time, by removing the motor fuse. When the brakes were released the appropriate link was moved around by hand causing the joint motor to rotate. When the shoulder or elbow joint is open circuit care must be taken to support the robot when the brakes are released, otherwise it will collapse under gravity. Motor terminal voltage was measured on the motor side of the fuse holder, with the fuse removed. Motor position was determined from the axis encoders. In these experiments a custom decoder connected to the quadrature encoder signals was used, but motor position could also have been read from the joint's digital servo board. The custom decoder contains a direction discriminator, 16-bit up/down counter and a 16-bit D/A converter. The output is an analog voltage proportional to motor position, which with the motor terminal voltage, is input to a two-channel data-acquisition instrument. The sample interval used was 20ms. 4 Comparison of results for the Puma 560 Table 1 compares various published measurements of Puma 560 torque constant, with local measurements made using the load test and open-circuit methods. 8 Torque constants for dierent Puma 560s have also been determined by Armstrong et al. and Paul et al. and are presented in the table for comparison. 3 9 Armstrong's maximum torque values have been divided by the gear ratio, and the maximum current, to give the torque constant quoted here. Tarn gives 10 the torque constant for the base axis motors as 0.259Nm/A, apparently from the manufacturer's specication. Considerable variation is seen in Table 1, but all values for the base motor are less than Tarn's value. This may be due to loss of motor magnetization in the robots investigated, compared with the `as new' condition of the servo motors. Data on the motors used in the Unimate Puma 560 is dicult to nd, and the motors themselves are unlabeled. There is speculation about the manufacturer and model in, 5, 11 and it is strongly rumoured that the motors are `specials' manufactured for Unimation by Electrocraft. The Puma uses two dierent types of motor, one for the base axes (joints 1-3) and another for the wrist axes (joints 4-6). It is conceivable that dierent types of motor have been used by Unimation over the years. Tarn and Bejczy et al. 10, 12 have published several papers on manipulator control based on the full dynamic model, and cite sources of motor parameter data as Tarn et al. and Goor. The former 13 14 has no attribution for motor parameter data quoted, while the latter quotes \manufacturer's specications" for the base motors. The source of Tarn's data for the wrist motors is not given. 12 9 5 Armature impedance Motor armature impedance, Rm + sLm , is shown in Figure 1. For the Puma 560 armature inductance is low (around 1mH ) and of little signicance since the 12 motor is driven by a current source. Armature resistance however is signicant in determining the maximum achievable joint velocity. Direct measurement of armature resistance, Rm, is dicult. Resistance measurement of a static motor exhibits a strong motor position dependence due to brush and commutation eects. The conventional locked-rotor test suers this disadvantage as well as the mechanical problems involved in locking the motor shaft without removing the motor from the robot. Measurements on a moving motor must allow for the eect of back EMF. Knowledge of the back EMF constant, Km , as determined above, and time records of motor terminal voltage, current and shaft angle allows determination of Rm and Lm . First it is necessary to compute the motor voltage component due to armature impedance Vt0(k) = Vt (k) ? K2Tm ((k + 1) ? (k ? 1)) (11) by subtracting the estimated back EMF from the measured terminal voltage. A 3-point central derivative estimate of _ is used. Equation (4) may then be rewritten in ARX form as Vt0 = R m im + = (Rm + Lm (1 z ?1 )im T Lm Lm ?1 ) z im T T ? ? (12) (13) and a parameter identication technique used as for the torque constant case. 10 For joint 6 the identication results in estimates of Rm = 5:1 and Lm = 0:83 mH. The resistance estimate is higher than the 3.8 value quoted for the `similar' motor in a Kawasaki Puma, but will include contributions due to connectors, the long umbilical cable, and internal robot wiring. Inductance is of a similar order to that reported by Tarn et al. 12 6 Conclusion A simple experimental procedure has been given for in situ measurement of the torque constant of permanent-magnet DC servo motors which are commonly used in robot manipulators. The method is based on the equivalence of motor torque constant and the back EMF constant. The approach can be simply extended to also estimate motor armature resistance and inductance. Experimental results on a Puma 560 give results that are very close to the conventional but more time consuming joint torque load test. The new method eliminates eects due to static friction and axis cross-coupling which are otherwise dicult to eliminate. Armature reaction does not appear to have a signicant eect on open-circuit measurements compared to normal load conditions. References [1] R. Paul, \Modelling, trajectory calculation and servoing of a computer controlled arm," Tech. Rep. AIM-177, Stanford University, Articial Intelligence Laboratory, 1972. 11 [2] J. Lloyd, \Implementation of a robot control development environment," Master's thesis, Mc Gill University, Dec. 1985. [3] B. Armstrong, O. Khatib, and J. Burdick, \The explicit dynamic model and inertial parameters of the Puma 560 arm," in Proc. IEEE Int. Conf. Robotics and Automation, vol. 1, (Washington, USA), pp. 510{18, 1986. [4] M. Liu, \Puma 560 robot arm analogue servo system parameter identication," Tech. Rep. ASR-91-1, Dept. Mechanical and Manufacturing Engineering, University of Melbourne, Feb. 1991. [5] P. Corke and B. Armstrong-Helouvry, \A search for consensus among model parameters reported for the PUMA 560 robot," in Proc. IEEE Int. Conf. Robotics and Automation, (San Diego), May 1994. [6] T. Kenjo and S. Nagamori, Permanent-Magnet and Brushless DC motors. Clarendon Press, Oxford, 1985. [7] L. Ljung, System Identication Toolbox. The MathWorks, Inc., 24 Prime Park Way, Natick, MA 01760, 1988. [8] P. Corke, \The Unimation Puma servo system exposed," MTM-226, CSIRO Division of Manufacturing Technology, 1991. [9] R. Paul, M. Rong, and H. Zhang, \Dynamics of Puma manipulator," in American Control Conference, pp. 491{96, June 1983. 12 [10] T. Tarn, A. K. Bejczy, X. Yun, and Z. Li, \Eect of motor dynamics on nonlinear feedback robot arm control," IEEE Trans. Robot. Autom., vol. 7, pp. 114{122, Feb. 1991. [11] G. B. Andeen, ed., Robot Design Handbook. McGraw-Hill, 1988. [12] T. Tarn, A. Bejczy, G. Marth, and A. Ramadorai, \Performance comparison of four manipulator servo schemes," IEEE Control Systems Magazine, vol. 13, pp. 22{29, Feb. 1993. [13] T. J. Tarn, A. K. Bejczy, S. Han, and X. Yun, \Inertia parameters of Puma 560 robot arm," Tech. Rep. SSM-RL-85-01, Washington University, St. Louis, MO., Sept. 1985. [14] R. M. Goor, \A new approach to minimum time robot control," Tech. Rep. GMR-4869, General Motors Research Laboratories, Nov. 1984. 13 im Lm Fuse Power amplifier Rm Eb Vt Rs Vs Figure 1: Schematic of motor electrical model. 14 Theta @ motor (rad) 30 20 10 0 -10 -20 0 2 4 6 8 10 12 Time (s) 14 16 18 2 4 6 8 10 12 Time (s) 14 16 18 20 Vt (V) 10 0 -10 -20 0 Figure 2: Joint angle and voltage records from open-circuit test on joint 2. 15 Parameter Armstrong 3 Paul 9 CSIRO load test open-circuit Km1 0.189 0.255 0.223 0.227 Km2 0.219 0.220 0.226 0.228 Km3 0.202 0.239 0.240 0.238 Km4 0.075 0.078 0.069 0.0675 Km5 0.066 0.070 0.072 0.0718 Km6 0.066 0.079 0.066 0.0534 Table 1: Experimental motor torque constants - motor referenced (Nm/A). 16