62
Friction compensation for a haptic manipulator: the HapticMASTER T.A.C. Verschuren DCT 2008.003 Traineeship report Prof. dr. H. Nijmeijer Ir. P. Lammertse (Moog FCS B.V.) Eindhoven University of Technology Department of Mechanical Engineering Dynamics and Control Group Nieuw Vennep, January 9, 2008

Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

  • Upload
    others

  • View
    5

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Friction compensation for ahaptic manipulator:the HapticMASTER

T.A.C. Verschuren

DCT 2008.003

Traineeship report

Prof. dr. H. NijmeijerIr. P. Lammertse (Moog FCS B.V.)

Eindhoven University of TechnologyDepartment of Mechanical EngineeringDynamics and Control Group

Nieuw Vennep, January 9, 2008

Page 2: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction
Page 3: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Abstract

The performance of mechanical systems, such as servomechanisms and robotic systems, is oftendeteriorated by friction. Friction can induce unwanted effects such as steady-state errors and limitcycling. The HapticMaster, a 3-dof haptic manipulator developed by Moog FCS Robotics, alsosuffers from friction. This device is developed to create a sense of touch to the user in a virtualenvironment. Due to the presence of friction however, the device does not feel realistic enough.Especially when motion changes direction the user feels an undesired reversal bump.

In order to reduce the effects of friction and remove the reversal bump, friction has to be com-pensated. To accomplish this, several model based friction compensators are designed and imple-mented on the HapticMaster.

In order to apply model based friction compensation, the original servo loop is adapted and anew feedback controller is designed. Next, various friction identification experiments are per-formed. These experiments showed that Coulomb, viscous and Stribeck friction phenomena arepresent. Furthermore, during a velocity reversal presliding behaviour is noticed at microscopiclevel.

Several model based friction compensators are designed and tested. Experiments have shownthat using a classic friction model results in overcompensation when motion changes direction.This can be explained by the fact that presliding behaviour is not incorporated in the model.Smoothing the classical model with a velocity based one-sided arctan function improves the ve-locity reversal a lot. However, the slope of the arctan function should be tuned different for everyacceleration during a velocity reversal. Measurements show that the relationship between the ac-celeration and the slope of the arctan function implies position dependent friction in the preslidingregime. Both the LuGre model and generalized Maxwell-slip model are able to incorporate thisposition dependent presliding behaviour. Experiments show that the GMS model is superior tothe LuGre model with respect to modeling the hysteresis loop, i.e., modeling presliding friction.Combining a PID controller with both inertia and GMS model based friction feedforward resultsin small tracking errors and very smooth velocity reversals.

iii

Page 4: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction
Page 5: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Samenvatting

De volg- en positioneernauwkeurigheid van mechanische systemen, zoals bijvoorbeeld servome-chanismen en robot-systemen, kan onder invloed van wrijving verslechteren. De aanwezigheidvan wrijving kan resulteren in ongewenst gedrag, zoals limit cycli en constante positioneerfouten.De HapticMaster, een 3-graden-van-vrijheid haptisch systeem ontwikkeld door Moog FCS Robo-tics, is ook onderhevig aan wrijving. Dit apparaat is ontwikkeld om voor de gebruiker gevoel tecreeren in een virtuele omgeving. Echter, door de aanwezigheid van wrijving voelt het apparaatniet realistisch genoeg. Vooral wanneer bewegingen van richting omkeren voelt de gebruiker eenomkeereffect genaamd ‘reversal bump’.

Om in staat te zijn de effecten van wrijving te verminderen en de ‘reversal bump’ te verwij-deren, moet de wrijving in het systeem gecompenseerd worden. Om dit te bereiken zijn enkelewrijvingscompensators ontworpen en geımplementeerd op de HapticMaster.

De originele servo lus is aangepast en een nieuwe regelaar is ontworpen om een stategie te kun-nen toepassen die wrijving compenseert op basis van een model. Vervolgens zijn er een aantalexperimenten uitgevoerd om te wrijving te identificeren. Deze experimenten toonden aan dat erCoulmbse, viskeuze en Stribeck wrijving aanwezig was op het systeem. Verder was er sprake van‘presliding’ gedrag op mircoscopisch niveau van het contact oppervlak.

Verschillende model gebaseerde wrijvingscompensators zijn ontworpen en getest. Experimententoonden aan dat het gebruik van een klassiek wrijvingsmodel resulteert in overcompensatie ophet moment dat het systeem van bewegingsrichting omkeert. Dit kan worden verklaard door hetfeit dat het ‘presliding’ gedrag niet gemodelleerd is in het klassieke wrijvingsmodel. Het gladdermaken van dit klassieke model door middel van een eenzijdige arctan functie reduceert de ‘reversalbump’ aanzienlijk. De helling van de arctan functie moet echter voor elke mogelijke versnellinganders getuned worden. Metingen tonen aan dat de relatie tussen versnelling en helling van dearctan functie positie afhankelijk wrijvingsgedrag in het ‘presliding’ regime aanduidt. Het LuGremodel en het gegeneraliseerde Maxwell-slip model zijn beide in staat om dit positie afhankelijk‘presliding’ gedrag te modelleren. Experimenten tonen aan dat het GMS model superieur is tenopzichte van het LuGre model wat betreft het modelleren van het ‘presliding’ gedrag. Uiteindelijklevert het combineren van een PID regelaar en massa- en GMS wrijvingscompensatie op basis vanvoorwaartse sturing de kleinste volgfouten en meest gladde snelheids nuldoorgangen op.

v

Page 6: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction
Page 7: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Contents

Abstract iii

Samenvatting iv

1 Introduction 11.1 Motivation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11.2 Problem definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11.3 Outline of the report . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

2 The HapticMaster 32.1 Working principle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32.2 Control algorithm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32.3 Experimental set-up . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

3 Overview of relevant literature 73.1 Modeling of friction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

3.1.1 Friction phenomena . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73.1.2 Static friction models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83.1.3 Dynamic friction models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9

3.2 Friction compensation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 113.2.1 Non-model based compensation . . . . . . . . . . . . . . . . . . . . . . . . . 113.2.2 Model based compensation . . . . . . . . . . . . . . . . . . . . . . . . . . . 12

4 Controller design 134.1 Servo loop modification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134.2 System identification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144.3 Controller design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15

5 Friction identification 175.1 Constant velocity experiments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175.2 Break-away experiments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195.3 Hysteresis loop measurements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205.4 Estimation of static friction parameters . . . . . . . . . . . . . . . . . . . . . . . . 21

6 Friction compensator design 236.1 Classical model based compensation . . . . . . . . . . . . . . . . . . . . . . . . . . 246.2 One-sided arctan model based compensation . . . . . . . . . . . . . . . . . . . . . . 246.3 LuGre model based compensation . . . . . . . . . . . . . . . . . . . . . . . . . . . 256.4 Generalized Maxwell-slip model based compensation . . . . . . . . . . . . . . . . . 27

vii

Page 8: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

CONTENTS

7 Experimental results 297.1 Experimental conditions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 297.2 Control without friction compensation . . . . . . . . . . . . . . . . . . . . . . . . . 307.3 Control with friction compensation . . . . . . . . . . . . . . . . . . . . . . . . . . . 31

7.3.1 Classic model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 317.3.2 One-sided arctan model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 317.3.3 LuGre model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337.3.4 Generalized Maxwell-slip model . . . . . . . . . . . . . . . . . . . . . . . . . 33

7.4 Discussion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34

8 Conclusions and recommendations 358.1 Conclusions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 358.2 Recommendations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36

A Datasheets 37A.1 HapticMaster . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37A.2 Brushed DC motor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38A.3 Tacho generator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39A.4 Incremental encoder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40

B Servo loop 41

C Maxwell-slip model parameters 43

D Source code 45

Acknowledgements 50

Bibliography 52

viii

Page 9: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Chapter 1

Introduction

This report deals with friction compensation in the HapticMaster developed by Moog FCS Robotics.Most controlled mechanical systems, including the HapticMaster, are subject to friction. Frictiondeteriorates the performance of these control systems severely, since its presence can give rise toundesired effects, such as large steady state errors, large settling times and limit cycling. Con-ventional feedback controller methods, like PID control, will not achieve satisfactory performanceanymore in those situations. In order to cope with the performance demands one has to compen-sate for friction.In this chapter we start with the motivation of this traineeship at Moog FCS Robotics. Next, theproblem definition is introduced and an outline of the report is presented.

1.1 Motivation

Moog FCS Robotics develops and manufactures haptic manipulators for medical industries. Theword ’haptic’ comes from the Greek ’haptesthai’, which means contact or touch. It is the modernterm for force feedback devices.This traineeship deals with the HapticMaster. The HapticMaster is a force feedback manipulatorused for robot-assisted rehabilitation. Since a force sensor is situated at the end effector andthe HapticMaster is programmable, it can render virtual environments to a human operator tosimulate a real physical environment. This virtual environment consists of virtual forces which aresummed with the forces the human operator exerts at the end effector. Because the force sensormeasures the resulting force and divides it by a virtual mass, eventually motion will occur.Due to friction however the motion of the HapticMaster doesn’t feel realistic enough. Especiallywhen the velocity changes sign the system gets stuck for a while, which can be felt by the user asa bump. This friction induced phenomenon is known as the reversal bump.The HapticMaster is admittance controlled and therefore consists of a inner motion loop andan outer force loop. The performance of the inner loop determines the maximally achievableperformance of the outer loop. If friction can be compensated for within the motion loop, theperformance of the force loop can be improved.

1.2 Problem definition

Friction compensation in the HapticMaster has to reduce the reversal bump effect and linearizethe motion loop as much as possible. In order to do so a friction compensator has to be de-signed and implemented in the control scheme of the HapticMaster. The present controller is aPID controller that deals with friction by means of analog integration. A possible solution to theproblems stated above is to replace or to extend this analog integrator with a nonlinear controllerthat compensates for friction. Although the HapticMaster is a 3-degree-of-freedom device, this

1

Page 10: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Introduction

assignment deals with a one-dimensional problem. Only the vertical movement will be examined.

The problem definition can be stated as:

Design, implement and test a nonlinear controller which realizes friction compensation in thez-axis of the HapticMaster. Here, the emphasis is on reducing the reversal bump which occurswhen motion changes direction.

In order to accomplish this assignment successfully the problem definition stated above is dividedinto subproblems. These subproblems are:

• carry out a literature search to gain insight in former work done on friction in the field ofcontrol,

• reconfigure the servo loop, i.e., remove the analog control in the loop and design a digitalfeedback controller,

• identify friction phenomena by means of experiments,

• design possible nonlinear controllers which compensate for friction,

• implement and test the designed controllers.

1.3 Outline of the report

Before focussing on friction compensation, the HapticMaster itself will be discussed first in chapter2. This is done to get insight in the force feedback control structure. Compared to conventionalmotion controllers it is quite different.In chapter 3 results of a literature search on friction will be given. Existing friction models andcompensation techniques will be presented and compared to each other.Chapter 4 will focus on controller design. The present inner servo loop will be adapted to allowfull digital control and friction compensation. This means that the analog part of the existingcontroller will be removed and replaced by a digital controller in software.Next, friction identification is discussed in chapter 5. Identification is carried out by performingconstant velocity, break-away and hysteresis experiments. Based on the results of these identifi-cation experiments, several friction compensation controllers are designed. Chapter 6 is devotedto describe these compensators.Experimental results obtained with the experimental setup are presented in chapter 7. The de-signed friction compensators are tested and compared to each other. Finally, conclusions andrecommendations for further research are presented in chapter 8.

2

Page 11: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Chapter 2

The HapticMaster

This chapter describes the working principle of the HapticMaster and its control strategy behindit. An overview of the complete experimental set-up is given as well.

2.1 Working principle

The HapticMaster is a three degree-of-freedom, force controlled haptic device. It is especiallydesigned for interaction with the human arm and can generate virtual environments to simulatereal physical environments. The human operator holds the end effector and actually feels thevirtual environment in the computer or, in other words, the operator gets force feedback. TheHapticMaster is a device for force sensations from a virtual world in the same way that a TV ora computer screen is a display for visual images from a virtual world. The virtual world of theHapticMaster is programmed by means of a HapticAPI. All kinds of haptic effects can be created,like springs and dampers, and spatial geometrical primitives can be defined, like spheres, conesand cubes.

Figure 2.1: Common model block diagram

The diagram in figure 2.1 shows the basic physics in terms of Newton’s law for the device’s endeffector perceived mass. Both the user and the virtual environment exert forces on the end effector,and it will move accordingly. If the virtual world contains a rigid object like a wall, this wall issimulated by a very stiff spring, which will stop the end effector regardless how much the userpushes it. If the virtual world exerts no forces, the end effector will follow the forces applied bythe user according to Newton’s law of ”acceleration equals force divided by mass”, and the userwill feel a ”free-air” movement where the device almost doesn’t resist to motion. The user willfeel a certain mass, called the perceived mass. Some friction can be felt especially at slow, subtlezero crossings of the velocity.

2.2 Control algorithm

The HapticMaster is controlled by a control algorithm that is called admittance control. Generally,there are two ways to control haptic manipulators. Besides admittance control, there is alsoimpedance control. Since both control algorithms are strongly related both of them are discussedbelow.

3

Page 12: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

The HapticMaster

Admittance control

The admittance control algorithm means that the device measures the force using a sensitive forcesensor. An internal mass model then calculates the acceleration, velocity and position (pva-vector)which a (virtual) mass would get as a result of this force. The pva-vector is used as a referencesignal to the robot. The actual motion then is governed by means of a regular controller. So, thedevice measures the forces that the user exerts on it, and reacts with motion. In other words,the manipulator acts as a mechanical admittance which accepts force inputs and yields motionoutputs.

Figure 2.2: Admittance control algorithm

In terms of stability there is a potential problem when simulating free air movement. In thiscase, the manipulator needs to accelerate very fast at the lightest touch. This means a very highcontrol gain from force input to acceleration output. A very low virtual mass means a very highcontrol gain. Control gains cannot become infinitely high without causing instability, so there isa problem when the mass needs to be low. The same holds when the end effector is in contactwith a physical hard surface. A small movement of the machine will give a strong rise in contactforce in that situation. It is the physical environment which closes the admittance control loopwith a very high gain from position to force this time, creating contact instability. On a simulatedvirtual surface however, a very high force will command only a very small motion. In fact, foran infinitely stiff simulated surface, the control gain from force to position is zero. So, simulatinghard surfaces doesn’t cause any stability problems.

Impedance control

The inverse of admittance control is called impedance control. The impedance control algorithmmeans that the user moves the device, and the device will react with a force if a virtual objectis met. In other words, the manipulator acts as a mechanical impedance which accepts motioninputs and yields force output. Within this control strategy, by force output we mean the actualmotor torque.

Figure 2.3: Impedance control algorithm

In contrast to admittance control, there is a potential stability problem when the end effector is

4

Page 13: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

2.3 Experimental set-up

in contact with a hard simulated surface instead of a hard physical surface. Any small change inposition will cause a very high rise in motor reaction force while the manipulator is in contact withthe virtual wall. This implies a very high control gain from measured device position to motorforce. Therefore, in an impedance controller there is a limit to the stiffness of a virtual object.When simulating free air movement, the user is free to move the manipulator, and the motordoesn’t have to do anything. The user however, will inevitably feel the mass and friction of theactual manipulator. In this situation the gain from position input to force output is zero. Evenif the manipulator is in contact with a hard physical object this will hold. There is no stabilityproblem then, since the object can stop the end effector without any special reaction being requiredof the motor.

Duality

Admittance control and impedance control are dual in their performance.Admittance controlled devices are capable of generating very high stiffness, because there is nostability issue when simulating hard surfaces. The inner servo loop cancels the real mass and mostof the friction of the mechanical device. Simulating free air motion is a problem, because thevirtual mass always has a certain value in order to avoid infinite acceleration reference inputs.Within impedance control the control algorithm cannot compensate for the real mass and fric-tion. Therefore, impedance controlled devices are typically lightly built to come close to free airmovement. Friction is hard to avoid mechanically, so the presence of friction is a major drawbackof impedance controlled manipulators. They cannot generate very stiff virtual objects as well.

2.3 Experimental set-up

A HapticMaster is available as the experimental set-up. In addition to the actual mechanicalsystem, a HapticMaster set-up consists of an amplifier, a real-time computer and a client pc.Figure 2.4 presents a schematic representation.

Figure 2.4: Schematic overview of experimental set-up

The HapticMaster is a device with three degrees of freedom. The kinematic chain from the bottomup yields a rotation, an up/down translation and an in/out translation. Together, this spans avolumetric workspace.The haptic rendering and the control loop run on a dedicated real-time computer with VxWorksas operating system. During operation, the sampling frequency is set to 2500 Hz.The z-axis of the HapticMaster is equipped with a brushed dc motor and a leadscrew with ananti-backlash nut and a pitch of 0.4 inch or 0.0102 m. The relationship between rotational andlinear movement is given by:

φ =2π

px, (2.1)

where φ is the rotational distance traveled in radians, x is the linear distance in meters and p isthe pitch of the leadscrew.

5

Page 14: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

The HapticMaster

To measure the position and velocity of the dc motor shaft, an incremental encoder and a tachome-ter are connected to it respectively. The encoder produces two 90 phase-shifted signals, corre-sponding to 500 increments per revolution. Due to the quadrature phase between the two signals,however, position changes of 0.25 of an increment can be detected. This yields an encoder res-olution of 2000 ticks per revolution, which corresponds to a position resolution on the leadscrewof 5.08 µm. To measure the velocity, a tachometer is rigidly connected to the motor shaft. Atachometer is actually a small generator which develops an output voltage proportional to itsangular velocity. The tachometer used in the z-axis of the HapticMaster produces 6 volts per 1000rpm.More details on the brushed dc motor, the encoder and the tachometer can be found in thedatasheets given in Appendix A. An overview of the complete set-up is shown in figure 2.5. Thevarious components are listed in table 2.1.

Figure 2.5: Overview of the complete experimental set-up

Table 2.1: Components of the experimental set-upnumber component

1 robot2 real-time computer3 electronics and amplifier4 client PC

6

Page 15: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Chapter 3

Overview of relevant literature

This chapter gives a survey of the existing literature on friction phenomena, models, identificationand compensation. Purpose of this survey was to gain insight in the way friction is treated in thefield of controlled mechanical systems.

3.1 Modeling of friction

3.1.1 Friction phenomena

Over the past few decades friction was studied extensively in classical mechanical engineering.Originally this was done to understand the mechanisms behind friction which occurs at the in-terface of two surfaces in contact. Friction is also important for control engineering, for examplein the design and control of servo mechanisms and robots. Based on a range of experiments per-formed in the field of tribology, mechanics, physics and control, there are several phenomena offriction that can be distinguished. Descriptions of these phenomena, according to Armstrong [3]and Canudas de Wit [6], are given below:

Static friction phenomena

• Coulomb or kinetic frictionthe friction component which is generated when two dry surfaces slide against each other;depends on the sign of the velocity,

• viscous frictionthe friction component which is generated when two surfaces separated by a liquid slideagainst each other; linear relationship between velocity and viscous friction force,

• stictionthe phenomenon that the force which is necessary to initiate motion from rest is often largerthan the Coulomb friction,

• Stribeck effectthe friction phenomenon that aries from the use of lubrication and gives rise to a decreasingfriction force with increasing velocity; also called negative viscous friction effect.

Dynamic friction phenomena

• varying break-away forcethe break-away force depends on the rate of applied force and the dwell time; varying fromstiction level to Coulomb friction level,

7

Page 16: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Overview of relevant literature

• presliding behaviourthe spring-like behaviour of friction that occurs when the applied force is smaller than thebreak-away force,

• frictional lagthe delay in the change of the friction force as a function of a change in the velocity.

These friction phenomena are considered to be important for accurate friction modeling and syn-thesis of controllers. Various models have been proposed in literature that describe a number ofthese phenomena. In the following, a brief review of the most relevant and popular models will begiven. A distinction can be made between static and dynamic models depending on the inclusionof frictional memory. For static friction models, this frictional memory is omitted, whereas fordynamic friction models this memory is described with additional dynamics between velocity andthe friction force.

3.1.2 Static friction models

Classical friction models

Static friction models only have a static dependence on velocity. Often, they are referred to asclassical models of friction, because static friction models include those friction phenomena thatwere discovered in the early days of studies of friction. In 1994, Armstrong-Helouvry et al. [3]summarized these models which basically model Coulomb, viscous, static and Stribeck friction.Figure 3.1 shows possible combinations of static friction models.

Figure 3.1: Examples of static friction models

The main disadvantage of static friction models is that they can not model presliding displacementand rate-dependent phenomena such as varying break-away force and frictional lag. Also the dis-continuity at zero velocity is a major drawback. To overcome this latter problem the discontinuousbehaviour near zero velocity is approximated by means of a continuous function. Spreeuwers [25],for example uses an arctan function with a very steep slope. However, while the discontinuityissue is solved, the model doesn’t correspond to friction in reality, because it assumes that thefriction force is zero for zero velocity. Furthermore, the zero velocity detection will be crucial forproper use of such a model.In 1985, Karnopp [15] proposed an alternative model to avoid the problem of locating the zerovelocity detection with high precision. The Karnopp model defines a small band around zerovelocity. Outside this band friction is modeled as the usual function of velocity. Inside, it is afunction of the applied force.

Armstrong’s seven parameter model

In 1994, Armstrong proposed his seven parameter model [3]. By means of two separate equa-tions for sliding and sticking this model incorporated dynamic friction phenomena. The stickingequation, which describes presliding displacement, is given by

F (x) = σ0x, (3.1)

8

Page 17: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

3.1 Modeling of friction

where σ0 determines the presliding stiffness. When the system is sliding the friction is describedby

F (v, t) = (FC + Fs(γ, t)1

1 + (v(t− τl)/vS)2) sgn(v) + Fvv, (3.2)

where

Fs(γ, t) = Fs,a + (Fs,∞ − Fs,a)t2

t2 + γ(3.3)

describes the varying friction level at break-away. The level of the stiction force Fs varies withdwell time t2 at zero velocity. A long dwell time gives rise to a high break-away force. The timedelay τl accounts for the desired frictional memory. So, in the sliding equation temporal effectssuch as frictional lag and varying break-away force are incorporated. A logical statement governsthe switching between the sliding model and the sticking model.

3.1.3 Dynamic friction models

Although Armstrong’s seven parameter model includes dynamic friction phenomena it is notconsidered as a dynamic friction model here, because actually it is just a fusion of two separatestatic models into one ‘dynamic’ model.

The Dahl model

The first dynamic friction model was proposed in 1968 by Dahl [8]. The starting point of Dahl’smodel is the stress-strain curve in classical solid mechanics. The friction model is an extension ofthe Coulomb friction, but it produces a smooth transition around zero velocity. Dahl modeled thestress-strain curve by a differential equation which describes essentially a Coulomb friction witha lag in the change of friction force when the direction of motion is changed. The Dahl modelequation is given by

dF

dt= σ0

∣∣∣∣1− F

Fssgn (v)

∣∣∣∣α sgn(

1− F

Fssgn (v)

), (3.4)

where F is the friction force, Fs is the stiction force, σ0 is the initial stiffness of the contact atvelocity reversal and the exponent α determines the shape of the hysteresis. Because the modelonly incorporates Coulomb friction and pre-sliding displacement, the model is appropriate forsystems in which Coulomb friction dominates, but does not apply when other phenomena, suchas static friction, viscous friction or the Stribeck effect, cannot be neglected.

The Bliman-Sorine model

In order to incorporate static friction into a dynamic model, in 1995 Bliman and Sorine [5] extendedthe Dahl model to a second order friction model. The Bliman-Sorine model connects a fast anda slow Dahl model in parallel, where the fast model has the highest steady-state friction. Thefriction force from the slow model is subtracted from the fast model, which results in a stictionpeak.

The LuGre model

Parallel to Bliman and Sorine, in 1995 Canudas de Wit et al. proposed the LuGre model [6] whichis also in line with the considerations of the Dahl model, but in addition employs the idea of thebristle model introduced by Haessig [13]. The LuGre model combines the pre-sliding behaviourof the Dahl model with the steady-state friction characteristic in the sliding regime. The frictionforce as function of the state variable z and the velocity v is given by

F = σ0z + σ1dz

dt+ σ2v, (3.5)

9

Page 18: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Overview of relevant literature

where the parameters σ0, σ1 and σ2 are the averaged bristle stiffness, the micro-viscous frictioncoefficient and the viscous friction coefficient respectively. The interpretation of the internal statez is linked to the bristle model, i.e., friction is visualized as forces produced by bending bristleswhich behave like springs. The average deflection of the bristles is denoted by z and is modeledas

dz

dt= v − σ0

v

g(v)z, (3.6)

where the arbitrary steady-state behaviour g(v) models the Stribeck effect with a Gaussian func-tion. It is a decreasing function for increasing velocity bounded by an upper limit equal to thestatic friction force Fs and a lower limit equal to the Coulomb friction force FC :

g(v) = sgn(v)(FC + (Fs − FC)e|

vvs|δ)

(3.7)

Here, vs denotes the Stribeck velocity and δ is a Stribeck shape parameter. The LuGre model ex-hibits a rich behaviour in terms of observed friction phenomena. It supports hysteresis behaviourdue to frictional lag, spring-like behaviour in stiction and gives a varying break-away force de-pending on the rate of change of applied force. Studies done by Olsson et al. [22] and Gafvert [11]compared the Bliman-Sorine model with the LuGre model. These studies revealed that the LuGremodel is beneficial with respect to the ability to model friction phenomena mentioned above.

The Leuven model

Although the former models are able to model dynamic effects they are still not able to predictfriction as observed experimentally. In 2000, Swevers et al. [21] proposed the Leuven model thatimproves on this.Basically, the LuGre model has two shortcomings. First, the models do not account for hysteresiswith nonlocal memory. Hysteresis behaviour with nonlocal memory is defined as an input-outputrelationship for which the output not only depends on the output at some time instant in thepast and the input since then, but also on past extremum values of the input and output. Thesecond shortcoming of the former models is that they do not adapt the displacement-force curvein the sticking regime. Besides the parameter σ0 which models the initial stiffness of the bristlesat velocity reversal, no parameters are left for shaping of the displacement-force curve.The Leuven model, also called the integrated friction model, tries to fit these phenomena intothe LuGre model. It consists of two equations: a friction force equation and a nonlinear stateequation. These equations are given by

F = Fh(z) + σ1dz

dt+ σ2v, (3.8)

dz

dt= v

(1− sgn

(Fh(z)g(v)

) ∣∣∣∣Fh(z)g(v)

∣∣∣∣δ)

, (3.9)

where Fh(z) is the hysteresis force, which accounts for nonlocal memory. The hysteresis forceFh(z) can be implemented by using a Maxwell-slip approximation. Essentially, this means thatthe hysteresis force is the sum of the forces of a number n elasto-plastic elements in parallel.

The generalized Maxwell-slip model

In 2003, Lampaert et al. [17] proposed the generalized Maxwell-slip (GMS) friction model. Thismodel is based on three friction properties: (i) the Stribeck curve for constant velocities, (ii) thehysteresis function with non-local memory in the pre-sliding regime, and (iii) the frictional memoryin the sliding regime. The developed model is a parallel connection of different single state frictionmodels, all having the same input namely the velocity. The dynamic behavior of each elementarymodel written as

dFi

dt= kix, (3.10)

10

Page 19: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

3.2 Friction compensation

when it is sticking and

dFi

dt= sgn(v)C

(αi −

Fi

g(v)

), (3.11)

when it is sliding. The total estimated friction force is given as the summation of the outputs ofthose single state models plus an extra viscous term:

F (t) =n∑

i=1

Fi(t) + σ2v(t). (3.12)

The parameters σ2 and the Stribeck curve g(v) are the same as for the LuGre and Leuven model.The attraction parameter C determines the attraction of the total friction force towards theStribeck curve in sliding. Each elementary model i has its own stiffness ki and fractional parameterαi. This latter determines the maximal force for each Fi during sticking.

3.2 Friction compensation

This section summarizes the most relevant friction compensation techniques used in the field.Compensating friction begins with avoiding friction in the design and development phase of asystem. Different methods, like selection of appropriate lubricant, use of special bearings andreplacement of sliding contacts by rolling contacts, are available to reduce friction by mechanicalmeans [4]. Since friction cannot be avoided completely, compensation techniques are necessary.These can be classified into two main groups: non-model based compensation and model basedcompensation.

3.2.1 Non-model based compensation

In non-model based friction compensation, no explicit model is used for the design of the frictioncompensator.

Stiff PD/Pl/PID control

A common way of friction compensation is the use of stiff PD, PI or PID controllers [3]. Nonlinearfriction can be seen as disturbance that must be canceled by the controller. Steady-state errorswhich occur for PD control can be eliminated by integral control. However, integral control canlead to limit cycling around a desired position [22] and the tracking error at velocity reversals isenlarged due to integral windup [3]. An advantage of the feedback compensation technique is thatno friction modeling is needed. There are certain limitations on the use of high gains, becausethey make the controller sensitive for high frequency measurement noise and controller saturation[2].

Dithering

Dithering is a technique characterized by the addition of a high frequency, low amplitude signalon top of the desired reference signal in order to smoothen the discontinuity of friction near zerovelocities [22]. It is commonly used in positioning tasks [3]. Dithering is not appropriate forhaptic applications. The constant vibration is distracting and destroys the effects being rendered.Furthermore, possible excitation of higher order dynamics can occur.

Impulsive control

With this method a pulse is applied to a system in rest, which results in a small displacement. Bymaking the impulses of great magnitude, but short duration, the static friction is overcome andthe sensitivity to friction is reduced [3],[4].

11

Page 20: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Overview of relevant literature

Fuzzy PI control

This technique uses different gains of a PI controller for the different regions of the friction curve.For low velocities other gains are used than for high velocities. The gains are computed on thebasis of the input and output of the system and on the basis of the reference signal [27].

3.2.2 Model based compensation

In this group of compensation techniques a model of the friction nonlinearity is explicitly utilizedfor the design of the friction compensation. The friction compensator uses either the reference,measured or estimated velocity as an input signal. Using the measured velocity as an input resultsin a feedback compensator and hence, the stability issue must be considered. Noisy velocity mea-surements can be a problem for good performance of the feedback friction compensator. Obtainingan estimation of the velocity by means of filtering or using an observer can reduce the impact ofthe sensor noise. When the reference velocity is used as the input, in fact a feedforward frictioncompensator is applied [3].Different compensation methods, such as fixed, robust and adaptive compensation, with differentfriction models can be used.

Fixed compensation

Fixed model based friction compensation uses a compensator with the parameters of the frictionmodel fixed at one value. Once the parameters are estimated through experiments, they are usedin the compensator. Fixed model based friction compensation is performed in [1],[10], [9] and [26]using static friction models as well as the LuGre model. The major drawback of fixed model basedfriction compensation is that the friction parameters may change with time due to things like lossof lubricant, deformation of the surface material and change in temperature.

Robust compensation

In a robust model based friction compensator, the friction parameters do not have to be knownexactly. It is assumed that the friction parameters of the friction model used are known withincertain bounds. In [12] a controller with robust friction compensation is proposed such that acertain accuracy of the tracking is achieved.Studies performed by Mallon [19] and Putra [20] investigates the influence of small modeling errorson an observer-based friction compensation strategy. Here, the friction is modeled by a classicalfriction model and for the resulting discontinuous closed-loop system dynamics, the cases of exactfriction compensation, undercompensation and overcompensation are investigated. It is proventhat exact friction compensation makes the closed-loop system behave like a linear system withoutfriction. It has been shown that undercompensation of friction may result in steady-state errorsand that limit cycling never occurs. The steady-state error is bounded by the size of a equilibriumset, which can be influenced by tuning the feedback controller. It also has been proven thatovercompensation results in limit cycling. However, this will disappear if the gains of the feedbackcontroller are tuned such that the dynamics become supercritically damped.

Adaptive compensation

In contrast to fixed compensation the parameters (or some of the parameters) of the friction modelused in the adaptive compensator are adaptively updated. In [7] the performance of a velocitycontrolled servo motor with friction is improved using an adaptive friction compensator with aCoulomb plus viscous friction model. An adaptive compensator with the LuGre model is usedin [28] and [24] An advantage of this method is that no a priori parameter values are needed.Furthermore, the adaptation mechanism will adjust the parameter values when they change overtime. However, adaptation for nonlinear model parameters is difficult.

12

Page 21: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Chapter 4

Controller design

During this traineeship we focus on the inner motion loop of the z-axis of the HapticMaster. Thisservo loop has some shortcomings regarding the ability to apply model based friction compensation.In order to overcome these shortcomings, the existing control structure has to be adapted and a newcontroller has to be designed. In this chapter the modification of the servo loop will be discussedfirst. Section 4.2 deals with identification of the system by means of FRF measurements. Thefeedback controller will be designed in section 4.3.

4.1 Servo loop modification

The existing servo loop for the z-axis of the HapticMaster is basically a PID controller with inertiafeedforward. However, the controller is not very straightforward. Figure 4.1 shows the top levelof the existing servo loop. Details can be found in Appendix B.The servo loop consists of three main components: the software, an amplifier and the mechani-cal system. Although proportional, integral and derivative feedback terms can be recognized inthe servo loop, the controller is not a classical digital PID controller which sends a voltage tothe amplifier. The loop contains a digital controller in software and an analog controller in theamplifier. The feedback terms are divided over the different components in the loop. Essentially,velocity feedback is realised by the analog PI controller using a tachometer. Position feedback,using an encoder, and inertia feedforward are realised by software control. The reasoning behindthis implementation is that the tacho feedback realises the desired motion trajectory, while theencoder feedback prevents drift. So, the voltage input to the amplifier is in fact a velocity setpoint.The total servo loop is scaled such that a velocity reference vr of 1 m/s in software actually resultsin a measured velocity vm of 1 m/s.

A major drawback of this servo loop is that is almost impossible to apply model based fric-tion compensation. The main reason for this is the presence of the analog integrator. If we wish

-xr + h - kp

6+

h-+kv-

xr ?+

ka-

xr

- ksc1-+ h - PI - km

ms

xmq - 1s

q -xm

ksc2

6−

6−

Software Amplifier Plant

Figure 4.1: Block diagram of the existing servo loop

13

Page 22: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Controller design

to apply model based friction compensation, a friction compensation term has to be added insoftware to the control output. This term however will be integrated by the analog PI controller,which will distort the friction compensation. Multiplying the friction compensation term by theinverse of the analog PI controller could prevent this. However, this will be complicated since theexact parameters of the PI controller are unknown. The closed-loop is tuned by hand, by tuningpotmeters and listening.

A second disadvantage regards the function of the analog integral controller. The common reasonto add integral control is to eliminate steady-state errors caused by a constant disturbance. In thiscontext, integral control refers to integrating the position error. This is not what the analog inte-grator in the servo loop is doing. It is integrating the control output, which results in additionalproportional feedback and velocity feedforward. Hence, the analog integrator does not improvethe insight in what is going on regarding classic proportional, derivative and integral feedbackterms.

In addition to the shortcomings mentioned above, it is also desired to have tacho informationavailable in software. This offers more options in controller design. It is decided to modify theservo loop by means of removing the analog integrator and the analog tacho feedback. This re-duces the function of the amplifier to converting an applied voltage into a motor current. It doesnot contain any feedback control anymore. Feedback control in this modified servo loop will beperformed by a new controller which is completely built in software. The only difference withtextbook feedback controllers is that derivative feedback is not realised by differentiation of theposition error, but by using the tachometer.

4.2 System identification

In order to design a controller which has good stability and robustness margins more informationabout the experimental system has to be known. Therefore, in this section we will determine anestimate of the frequency response function of the experimental system. A closed-loop systemidentification procedure is chosen. The layout of this procedure is given in figure 4.2.

-xr + h -

eC -

n + h?w

+-

uH q -

xm

6

Figure 4.2: Block diagram of the closed-loop FRF measurement

To determine an estimate of the frequency response function H(s), a disturbance signal w isinserted into the system. Here, we use a chirp signal. In order to reduce the influence of frictionon the system identification, a constant velocity reference signal is chosen. We measure the inputto the system u and the error signal e. The transfer from w to u equals the sensitivity S:

u(s)w(s)

= S(s) =1

1 + C(s)H(s). (4.1)

Furthermore, the transfer from w to e equals the process sensitivity PS:

e(s)w(s)

= PS(s) =−H(s)

1 + C(s)H(s), (4.2)

in which s denotes the Laplace variable. Dividing the process sensitivity function by the sensitivityfunction yields the system transferfunction H(s). In order to use this identification procedure a

14

Page 23: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

4.3 Controller design

controller C(s) is needed. A PD controller is chosen, i.e., C(s) = Kp + Kds with Kp = 1 andKd = 1.

The sampling frequency used during the system identification experiment is set to 2500 Hz. Thefrequency response function is estimated using a Fourier analysis, where the number of Fourierpoints equals 1 · 104. This corresponds to a measurement time of 4 seconds and a frequency reso-lution ∆f of 0.25 Hz. To prevent signal leakage a Hanning window is used.

Figure 4.3 shows the measured frequency response function. This FRF was obtained with aconstant velocity reference of xr = 0.1 m/s and a chirp signal w with varying frequency from 1Hz to 1250 Hz. The input w is uncorrelated with xr. A resonance peak is observed at approx-imately f = 50 Hz. The resonance is probably caused by the decoupling of the z-axis structurefrom the leadscrew. A second resonance peak can be seen at f = 870 Hz. This resonance can beexplained by the limited torsional stiffness of the motor axle. A fourth-order fit of the measuredFRF, obtained with the Matlab function frsfit.m, is also given in figure 4.3.

100

101

102

103

−120

−100

−80

−60

−40

−20

0

20

Mag

nitu

de |H

(jω)|

[dB

]

Frequency [Hz]

measuredfitted

Figure 4.3: Measured and estimated plant FRF

4.3 Controller design

A controller has to be designed, which has to fulfill stability margins (sufficient gain margin and aminimum phase margin of 30) and robustness margins (the magnitude of the sensitivity functionmust remain below 6 dB). The controller is designed using the fitted plant FRF and the ShapeIt-toolbox.The designed feedback controller consists of three parts. The first part is a lead filter, which givesthe desired phase-margin while preventing high-frequent components to be excited. Then a pro-portional gain is introduced to obtain a certain bandwidth. The emphasis during this traineeshipis not on achieving best performance with respect to tracking accuracy. Therefore, there are nospecific demands on the bandwidth of the closed-loop system. Since the z-axis structure decouplesat frequencies above approximately 50 Hz, the bandwidth of the designed controller is chosen as45 Hz. Furthermore, integral control is added. The controller is given as:

C(s) = k

12πfzero

s + 11

2πfpoles + 1

s + 2πfint

s, (4.3)

where its parameters are listed in table 4.1. With these parameters an infinite gain margin andphase margin of 84 is obtained. The sensitivity remains below 6 dB. So, the stability and robust-

15

Page 24: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Controller design

ness margins are fulfilled.

The former servo loop also contained an inertia feedforward term. The feedforward gain ka wasmanually tuned at ka = 0.001. Due to the presence of the analog integrator this gain did notreally represent the actual inertia of the system. Since there is no longer analog integral controlpresent, the amplifier can be represented as a gain. Hence, it is possible to apply accurate in-ertia feedforward. From figure 4.3 it can be concluded that the system shows double integratorbehaviour at low frequencies. Below approximately 30 Hz the plant FRF can be described by:

lims→0

H(s) =1

ms2, (4.4)

where m is the lumped inertia of the dc motor, the leadscrew and the translating z-axis structure.Accounting for the amplifier gain kamp, the motor constant km and torque-to-force conversion, wecan estimate the inertia as:

m =kampkm

2πp

H10Hz(2π10)2≈ 22 kg. (4.5)

The motor inertia is known to be Jm = 3.25 · 10−5 kgm2, which corresponds to 12.33 kg if it isreflected to the end effector. This can be calculated according to:

mm = Jm

(2π

p

)2

. (4.6)

The translating mass of the z-axis is therefore approximated as 10 kg. This seems like a reasonableestimation. Figure 4.4 shows the controller in the modified servo loop.

Table 4.1: Controller parametersParameter Value

k 50fzero 8 Hzfpole 500 Hzfint 5 Hzka 0.0035

-xr + h - C -+ h?+

ka

xr-

- kamp- km

- 1ms

-xm

1s

q -xm

6−

SoftwarePlant

Figure 4.4: Block diagram of the modified servo loop

16

Page 25: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Chapter 5

Friction identification

In this chapter the identification of the friction on the z-axis of the HapticMaster will be discussed.As already discussed in section 3.2 there are many approaches to compensate for friction. In orderto apply model based friction compensation the real friction as it appears on the experimentalset-up must be identified. To determine which friction phenomena are encountered on the z-axis ofthe HapticMaster several experiments were performed. Based on the results of the identificationexperiments the parameters of the friction model to be applied were identified.To determine the friction behaviour of the experimental setup three different experiments wereperformed; constant velocity, break-away and hysteresis loop experiments.

5.1 Constant velocity experiments

Constant velocity experiments provide insight in the friction force that is induced by the frictionalcontact at constant velocity, in the system. These results are gathered in a so-called friction-velocity map. In such a map, the friction force F is given as a function of the linear velocityx. If we model the experimental set-up as an equivalent mass subjected to friction, then thecorresponding equation of motion becomes:

mx + F = u, (5.1)

where m is the lumped inertia of the dc motor, leadscrew and z-axis structure. At constant ve-locity, the acceleration is equal to zero and hence, the equation of motion reduces to F = u. Thismeans that at constant velocity, the control output equals the friction force.

Figure 5.1 shows the results of constant velocity experiments at several different velocities. Bothpositive and negative directions have been investigated. The friction force is calculated using thelinear relationship between motor torque T and control output u:

T = kampkmu. (5.2)

In the obtained friction-velocity map we can distinguish Coulomb and viscous friction as well asthe Stribeck effect. In order to minimize the influence of measurement noise the results are aver-aged over several experiments. The viscous friction for both directions is approximately the same,but the Coulomb friction level for negative velocities is a bit larger than the Coulomb frictionlevel for positive velocities. Furthermore, the Stribeck effect is also somewhat different for eachdirection.

Another result that can be extracted from the constant velocity experiments is the influenceof the position on the friction parameters. Figure 5.2 shows the results of constant velocity exper-iment with xr = 0.0102 m/s, which corresponds to ω = 2π rad/s. The carriage on the leadscrew

17

Page 26: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Friction identification

−0.1 −0.05 0 0.05 0.1−60

−40

−20

0

20

40

60

Velocity [m/s]

Fric

tion

forc

e [N

]

Figure 5.1: Friction-velocity map

−0.2 −0.15 −0.1 −0.05 0 0.05 0.1 0.15 0.2−50

−40

−30

−20

−10

0

10

20

30

40

50

Position [m]

Fric

tion

forc

e [N

]

Figure 5.2: Friction-position map

is moved up and down three times to map the position dependency of the friction.

From this position-friction map we can conclude a dependency of the friction on the leadscrewposition, which can be explained by looking in detail at the construction of the leadscrew. It turnsout that its is not constructed properly with respect to its alignment. Therefore, it is possiblethat the nut is loaded sideways as the carriage is moving to one end of the leadscrew and hence,the friction forces increase in that situation. Although it was tried to overcome this problem byimproving the alignment, the friction-position map from figure 5.2 is the best achievable result.Therefore, all experiments done in this report, including the former constant velocity experiments,are performed within a range of x ∈ [−0.10, 0.15] m.

The control output u during a constant velocity experiment is not constant. As shown in figure5.2 the applied force, and hence the control output, is subjected to more disturbances than justincorrect leadscrew alignment. Spectral analysis of the control output u is performed to identifydominant harmonic components in the frequency content of the signal. The autopowerspectrumof the signal is given in figure 5.3. Some frequency components in the signal are dominant, which

18

Page 27: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

5.2 Break-away experiments

100

101

102

10−8

10−7

10−6

10−5

10−4

10−3

|PS

D|

Frequentie [Hz]

Figure 5.3: Autopowerspectrum of the control output, rotational velocity ω = 2π rad/s

suggests that periodic disturbances are present.An explanation for the 4 Hz peak is the following. The stator part of the motor consists of 4permanent magnets spaced at 90 intervals. Therefore each mechanical period (one rotation)consists of four electrical periods. The commutation of the motor is periodic with the electricalperiod. If the commutation is not perfect a disturbance occurs with a period equalling the electricalperiod. At a rotational velocity of 1 Hz, this results in a 4 Hz disturbance. The peaks in figure5.3 at 8 and 12 Hz can be explained as harmonics of the base frequency of 4 Hz.Moreover, a peak at 17 Hz can be identified. This periodic disturbance can be explained bymotor torque ripple. The rotor part of the motor is composed of a 17-teeth core with straightlaminations. The peaks at 34, 51 and 68 Hz are related to harmonics of the base frequency of 17Hz. Compensation these effect is beyond the scope of this traineeship.

5.2 Break-away experiments

Stiction is the phenomenon where applying torque to a mechanical system which is at rest will notalways result in motion of the system. To identify this stiction phenomenon on the HapticMasterso-called break-away experiments are performed. When stiction occurs the input force is equal tothe friction torque present in the system. The level at which the input force exceeds the frictionforce is called the break-away force.

The break-away force is measured in an open-loop experiment where a ramped force is applied tothe system which is initially at rest. The force level at which gross sliding occurs is defined to bethe break-away force. The positive break-away forces at different initial positions on the leadscreware shown in figure 5.4(a). From the results we can see that the break-away forces are highly ir-regular and a clear position dependency in the range x ∈ [−0.10, 0.15] m can not be distinguished.Figure 5.4(b) shows the results for an open-loop break-away experiment where the force is notonly ramped up in one direction, but is slowly ramped up and down several times. Again, somedifferences between positive and negative velocities can be seen regarding the Coulomb frictionlevel and the stiction level.

In figure 5.5(a) and 5.5(b), zoomed-in responses are given for two break-away experiments. Thebreak-away forces Fb in these experiments are approximately 42 and 44 N respectively. Moreover,during the break-away experiments it was observed that pre-sliding phenomena occur. When theapplied force is less than the break-away force a small displacement between the contacting sur-

19

Page 28: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Friction identification

faces takes place. From the figures, we can clearly see the presliding behaviour of the experimentalsystem. It is noted that presliding is seen in all the break-away experiments. To investigate pres-liding closely, hysteresis loop experiments will be performed. This will be discussed in the nextsection.

−0.2 −0.15 −0.1 −0.05 0 0.05 0.1 0.15 0.235

36

37

38

39

40

41

42

43

44

45

Position [m]

Bre

ak−

away

forc

e [N

]

(a) Break-away forces for different positions

−0.1 −0.05 0 0.05 0.1

−50

−40

−30

−20

−10

0

10

20

30

40

50

Velocity [m/s]

Fric

tion

forc

e [N

]

(b) Applied motor force versus velocity

Figure 5.4: Results of break-away experiments

8 10 12 14 16 18 2010

20

30

40

50

App

lied

forc

e [N

]

8 10 12 14 16 18 20−2

0

2

4

6

8

x 10−4

Pos

ition

[m]

Time [s]

(a)

12 13 14 15 16 17 1825

30

35

40

45

App

lied

forc

e [N

]

12 13 14 15 16 17 18

0

5

10

15

x 10−4

Pos

ition

[m]

Time [s]

(b)

Figure 5.5: Examples of break-away responses

5.3 Hysteresis loop measurements

The velocity reversal is investigated by performing a hysteresis loop measurement. In order toreduce the reversal bump at velocity reversals not only the static friction parameters Fs, Fc andFv need to be known. It is also necessary to know exactly what happens when motion changes di-rection, i.e., when velocity changes sign. There might be backlash or compliance. Backlash allowsthe motor shaft to move a limited range, equal to the clearance between the nut and the leadscrew,without causing any motion at the load. Compliance also allows to rotate the motor shaft withoutthe load moving. With compliance you are actually winding up the mechanical system like a spring.

The hysteresis loop, also called the static characteristic in [16], is determined by performing thesame open-loop experiment as done to obtain the results from figure 5.4(b). However, in this case

20

Page 29: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

5.4 Estimation of static friction parameters

the force is ramped up and down just below the break-away level. No gross sliding will occur inthat situation. Figure 5.6 shows the result when the applied force is mapped with position.

−1 −0.5 0 0.5 1

x 10−4

−40

−30

−20

−10

0

10

20

30

40

Position [m]

Fric

tion

forc

e [N

]

Figure 5.6: Hysteresis loop

Although there is a leadscrew, there is no backlash present in the system. This would be char-acterized by a slope of zero somewhere in the hysteresis loop. The backlash-free nut seems towork properly. The fact that the system is not at rest and somehow deflects like springs can beexplained as follows. By the observation of the surface at microscopic level, it has many irregularasperities. These asperities can be regarded as elastic bristles. When force is applied, the bristlesdeform, so there occurs a relative displacement between the surface in contact. This displace-ment is called the presliding displacement. On this experimental set-up, the displacement in thepresliding regime can be determined as approximately 30 encoder counts, which corresponds to1.52 · 10−4 m.

5.4 Estimation of static friction parameters

This section aims to determine the static friction parameters of the z-axis of the HapticMasterbased on the former experiments. This is done by fitting the Stribeck curve,

F = g(x) + Fvx, (5.3)

g(x) = Fc + (Fs − Fc) e

(−| x

xs|ds

), (5.4)

through the data points in the friction velocity map in figure 5.1. As already mentioned, theCoulomb friction force has a somewhat different value for positive and negative velocities. It turnsout that the same holds for the viscous friction component and the Stribeck effect. We saw thatthe break-away force is highly irregular. An unambiguous estimation of the stiction force is hardto identify from the break-away experiments. Therefore, we determine the stiction force Fs fromthe friction-velocity map.

The friction parameters θ = [Fc Fs Fv vs ds] are obtained using nonlinear optimizationtechniques (with the MATLAB function lsqcurvefit.m), such that the quadratic cost function I isminimized:

minθ

I =N∑

i=1

(F (xi, θ)− F (xi)

)2

(5.5)

21

Page 30: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Friction identification

Herein, F equals the experimental averaged friction force during constant velocity xi, N is thenumber of data-points and F represents the friction model output. The obtained friction parametervalues for positive and negative velocity are given in table 5.1. Figure 5.7 shows the static frictionmodel output together with the data points.

Table 5.1: Static friction parametersPositive velocity Negative velocity

F+c 33.0 N F−c 32.3 N

F+s 43 N F−s 42 N

F+v 150 Ns/m F−v 140 Ns/m

v+s 0.0025 m/s v−s 0.003 m/s

d+s 0.7 d−s 0.8

−0.1 −0.05 0 0.05 0.1−60

−40

−20

0

20

40

60

Velocity [m/s]

Fric

tion

forc

e [N

]

MeasurementsData fit

Figure 5.7: Friction-velocity map: measurements and estimated friction curve

22

Page 31: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Chapter 6

Friction compensator design

Haptic performance achieved with standard feedback controllers is often limited due to the presenceof friction. The controller gains have certain limits due to stability issues. Besides being stablehaptic devices should also feel nicely. Tuning a feedback controller with large gains makes you feelall kind of disturbances such as motor torque ripple. It is possible to achieve better performanceby means of model based friction compensation. It is decided to use model based compensation,since non-model based compensation like dither and impulsive control are typical compensationmethods for positioning tasks. The high frequent control signals would distort the rendering ofhaptic effect.In this chapter we search for a model based friction compensator that can reduce the reversalbump at velocity reversals in particular. Different friction models are discussed to improve theperformance with respect to this velocity reversal. Two static models, classic and smoothed, andtwo dynamic models, LuGre and generalized Maxwell-slip, are developed in this chapter.

Figure 6.1 shows the control structure that is used to apply friction compensation. The fric-tion force F is estimated based on the reference velocity xr and applied using feedforward control.The same is done for the inertia force. The control output u is given as:

u = mxr + F + upid, (6.1)upid = C(xr − xm), (6.2)

where F denotes the estimated friction force, m the estimated inertia and C the controller designedin chapter 4.

-xr + h - C -+ h?+

h-+Fxr

- ?+

m-xr

-u + h - 1

ms

xmq - 1s

q -xm

F

6−6−

Controller

Plant

Figure 6.1: Block diagram for model based feedforward friction compensation

23

Page 32: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Friction compensator design

6.1 Classical model based compensation

First, a classic model is considered. The friction force will be described by Coulomb and viscousfriction as well as the Stribeck effect. In chapter 5 it was observed that the friction phenomenawere asymmetric with respect to the direction of motion. Therefore, to compensate for frictionthe following asymmetric static friction model is used:

F =

g+(x) + F+

v x if x > 0,

F+s if x = 0 and sgn(u) > 0,

F−s if x = 0 and sgn(u) < 0,

g−(x) + F−v x if x < 0.

(6.3)

Here, g(x) is the same Stribeck curve as described in chapter 5:

g(x) = Fc + (Fs − Fc) e

(−| x

xs|ds

), (6.4)

but g+(x) denotes that the static friction parameters F+c , F+

s and F+v for positive velocities are

used and g−(x) denotes that the static friction parameters F−c , F−s and F−v for negative veloci-ties are used. For tracking problems with velocity reversals, presliding behaviour should not beignored as we will notice in chapter 7. The discontinuous switching at velocity reversals results inovercompensation.

6.2 One-sided arctan model based compensation

A possible way to prevent discontinuous switching of the friction force is to use a smoothingfunction. There are several possibilities to apply this smoothing. First of all, the smoothingfunction itself may be characterized by various functions. Possible functions that are suitable arelinear, arctan or versed sine functions. Secondly, these smoothing functions can be time based[23], position based [3] or velocity based. A velocity based arctan smoothing function, depicted infigure 6.2(a), is used at Moog FCS. With this model, the friction force is estimated as:

F =

F+

c2π arctan(αx) + F+

v x if x > 0,

F−c2π arctan(αx) + F−v x if x < 0.

(6.5)

Here, α denotes the slope of the arctan function. The slope α which gives the smoothest velocityreversal is different for each acceleration during such a reversal. At Moog FCS, a fuzzy logiccontroller is used to incorporate this varying slope.

−0.1 −0.05 0 0.05 0.1−40

−30

−20

−10

0

10

20

30

40

Velocity [m/s]

Fric

tion

forc

e [N

]

(a) Regular arctan compensator

−0.1 −0.05 0 0.05 0.1−40

−30

−20

−10

0

10

20

30

40

Velocity [m/s]

Fric

tion

forc

e [N

]

(b) One-sided arctan compensator

Figure 6.2: Working principle of arctan compensators

24

Page 33: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

6.3 LuGre model based compensation

At zero crossings of the velocity the estimated friction force is built up slowly to prevent over-compensation. However, the estimation is also slowly decreased when the system is braking downto zero velocity. This doesn’t correspond to true friction as observed on an experimental set-up.To overcome this, a so-called one-sided arctan model is developed during this traineeship. Figure6.2(b) shows the working principle behind this friction model. For simplicity, only Coulomb fric-tion is depicted. The adapted model makes sure that when the system is braking down the fullCoulomb friction is compensated until a velocity reversal occurs. From that moment, the frictionforce is build up according to an arctan function. The model switches to a regular static modelwhen the friction force reaches the Coulomb level again.

6.3 LuGre model based compensation

During identification experiments we observed that presliding behaviour occurred when the di-rection of motion changed. Above mentioned friction models did not incorporate this preslidingregime explicitly. To incorporate presliding behaviour, the LuGre model can be used for frictioncompensation. The LuGre model is a dynamic model for the description of the behavior of thefriction force. In the LuGre model, the friction interface between two surfaces is considered as acontact between elastic bristles. When an external force is applied tangential to these bristles,they will deform like springs. This gives rise to the friction force. When the external force exceedsa certain level, the bristle contacts (asperities) break and sliding occurs. The LuGre friction modelis described by the following equations:

F = σ0z + σ1dz

dt+ σ2x, (6.6)

dz

dt= x− σ0

x

g(x)z, (6.7)

g(x) = Fc + (Fs − Fc) e

(−| x

xs|ds

)/σ0, (6.8)

where the parameters σ0, σ1 and σ2 are the averaged bristle stiffness, the micro-viscous frictioncoefficient and the viscous friction coefficient respectively. These equation can be interpreted asfollows. Equation (6.7) describes the behavior of the internal state of the friction model, i.e.the deflection of the above mentioned bristles. The first term on the right hand side causes adeflection of the bristles that is proportional to the integral of the relative velocity between thecontact surfaces. The second term ensures that the deflection of the bristles reaches a final valueand therefore accounts for breaking of the bristles. Equation (6.6) describes the dependency ofthe friction force upon the internal friction state. The first term corresponds to the friction forcedue to the stiffness of the bristles, while the second term adds damping to the friction model tocounteract unwanted oscillations of the bristle deflection. The third term accounts for viscousfriction.

According to Altpeter [2], digital implementation of the friction state z requires particular at-tention since its dynamics can be very fast. The Euler approximation, i.e., replacing z by

zk ≈zk − zk−1

h, (6.9)

where h denotes the sampling time, leads to stability problems. As an alternative it is proposedto use a formulation which is based on the assumption that the velocity remains constant betweentwo samples. Under this condition the friction state z can be updated as:

zk =

−a1zk−1 + b0xk if xk 6= 0zk−1 if xk = 0

(6.10)

25

Page 34: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Friction compensator design

with

a1 = − exp(− |xk|

g(xk)h

)(6.11)

b0 =g(xk)|xk|

(1 + a1). (6.12)

To determine the LuGre model parameters σ0 and σ1 the plant FRF in the presliding regime ismeasured with a method proposed by Hensen [14]. Hereto, a mass m, subjected to linearized LuGrefriction around zero initial state, is regarded. The system dynamics within small displacementsare described by:

mx + (σ1 + σ2)x + σ0x = u. (6.13)

In order to measure the FRF in the presliding regime, the system is excited in open-loop with achirp signal with zero initial velocity. During the open-loop FRF measurement the amplitude ofthe chirp signal is kept within the break-away friction level of the system to prevent the systemfrom sliding. The transfer function of the system in the presliding regime equals:

H(s) =x(s)u(s)

=1

ms2 + (σ1 + σ2)s + σ0(6.14)

The average bristle stiffness σ0 can be determined from the low-frequent region. At low frequencies,the magnitude of the transfer function approaches:

lims→0

|H(s)| = 1σ0

. (6.15)

The measured and estimated plant FRF in the presliding regime are depicted in figure 6.3. Theestimated dynamic LuGre parameters become σ0 = 1.3 · 106 N/m and σ1 = 4000 Ns/m. Here,the parameters have to be considered as the lumped compliance of the system rather than thestiffness and the damping of the friction alone.

100

101

102

10−4

10−3

10−2

Frequency [Hz]

Mag

nitu

de |H

(jω)|

[−]

Measured FRFEstimated LuGre

Figure 6.3: Frequency response function of presliding behaviour

To validate the developed LuGre friction model the presliding regime is simulated. Figure 6.4shows the result of a comparison to the measured data. It is observed that the model doesn’tdescribe the presliding regime very well. However, due to the lack of tuning parameters, no betterestimation can be achieved with the LuGre model.

26

Page 35: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

6.4 Generalized Maxwell-slip model based compensation

−1 −0.5 0 0.5 1

x 10−4

−40

−30

−20

−10

0

10

20

30

40

Position [m]

Fric

tion

forc

e [N

]

MeasurementLuGre model

Figure 6.4: Measured and LuGre estimated hysteresis loop

6.4 Generalized Maxwell-slip model based compensation

The generalized Maxwell-slip friction (GMS) model offers a better solution to estimate the pres-liding regime. It is based explicitly on three friction properties: (i) the Stribeck curve for constantvelocities, (ii) the hysteresis function with non-local memory in the presliding regime, and (iii) thefrictional memory in the sliding regime.The hysteresis function is estimated by means of a parallel connection of N elementary frictionmodels. The elementary models consist of slip-blocks and springs with different properties. Thefriction force is summation of the outputs of the N elementary state models, as depicted in figure6.5.

Figure 6.5: Maxwell-slip model for N elements

Each elementary friction model corresponds to an asperity in the contact surface, where each as-perity can stick or slip. If the asperity sticks, the elementary friction model force Fi, is proportionalto the deflection of the asperity. This can be modeled as:

dFi

dt= kix, (6.16)

where ki the stiffness of the asperity. Formulating the presliding regime as stated above makesit position dependent. The asperity will slip if the elementary friction force gets larger than themaximal value Wi that it can sustain. In the sliding regime the friction behavior is characterized

27

Page 36: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Friction compensator design

by the following equation:

dFi

dt= sgn(x)C

(αi −

Fi

g(x)

), (6.17)

where αi determines the maximum friction force Wi for an elementary model as Wi = αig(x).If∑

αi = 1 the total friction force, when all asperities are slipping, equals the Stribeck curve.Once the model is slipping, it remains slipping until the direction of motion is reversed. Thetotal estimated friction force is given as the summation of the elementary models plus the viscousfriction term:

F (t) =N∑

i=1

Fi(t) + σ2x(t). (6.18)

Figure 6.6 shows the hysteresis loop when it is approximated with a GMS friction model. Inthis case, four Maxwell-slip elements are used with parameters as given in table 6.1. AppendixC describes how to determine these parameters of the Maxwell-slip elements. The parameter Ccan be used to model frictional lag by means of a first order delay. However, frictional lag hasnot been investigated. Therefore the parameter is chosen quite large, i.e., C = 1 · 104 N/s, whichensures fast attraction to the Stribeck curve g(x).

Table 6.1: GMS elementary model parametersStiffness ki N/m Friction force Wi N

k1 1.1 · 107 W1 14.65k2 9.1 · 105 W2 9.28k3 2.0 · 105 W3 11.03k4 5.0 · 104 W4 4.19

−1 −0.5 0 0.5 1

x 10−4

−40

−30

−20

−10

0

10

20

30

40

Position [m]

Fric

tion

forc

e [N

]

MeasurementGMS model

Figure 6.6: Measured and GMS estimated hysteresis loop

The simulated GMS hysteresis loop shows good correspondence with the measured hysteresis loop.It is much better than the one estimated with the LuGre model, but still some deviation can beseen. The characteristic is somewhat different for positive and negative velocity. Due to timelimitation however, the experiments were performed with the Maxwell-slip parameters from table6.1.

28

Page 37: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Chapter 7

Experimental results

In this chapter the results of the experiments are discussed. The experiments are performed onthe z-axis of the Hapticmaster with the compensators designed in chapter 6. Section 7.1 describesthe conditions under which the experiments were performed. Section 7.2 deals with the systemperformance without friction compensation. The results of the experiments with static, arctan,LuGre and GMS model based friction compensation will be discussed in section 7.3. In section7.4 an overview and a comparison of the results will be given.

7.1 Experimental conditions

To compare the results of the different friction compensators, all experiments were performed withthe same reference trajectory, depicted in figure 7.1. It is a trajectory which generates a velocityreversal with constant acceleration and which has a maximum velocity that corresponds to gentleuse of the HapticMaster.

0 2 4 6 8 10 12

−0.2

−0.1

0

Pos

[m]

0 2 4 6 8 10 12

−0.1

0

0.1

Vel

[m/s

]

0 2 4 6 8 10 12

−0.1

0

0.1

Acc

[m/s

2 ]

Time [s]

Figure 7.1: Reference trajectory for experiments

The control performance is evaluated on the basis of three criteria; namely position error, velocityerror and by means of feeling. Our goal is not to achieve the smallest possible tracking errors,although their values have to be in an acceptable range. The emphasis is on minimizing peaks inthe position and velocity errors, since jerkiness is felt by the user when operating the HapticMaster.The latter criterion, assessing the smoothness of the velocity reversal by feeling, is the key criterionconsidering haptic devices, but at the same time it is the most subjective one. The human

29

Page 38: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Experimental results

hand is particulary sensitive to jerkiness. It is tried to quantify this phenomenon by means of aaccelerometer, but no specific relationship is found between acceleration during a velocity reversaland the feeling sensed by the operator. Still, the velocity reversals will be evaluated by means offeeling, but no quantified results will be presented.

7.2 Control without friction compensation

The system performance is first evaluated without applying any model based friction compensa-tion. For this purpose, the feedback controller with inertia feedforward designed in section 4.3 isused both with and without integral control.

Figure 7.2 shows the results from an experiment using PD control without integral action. Fromfigure 7.2(a) the Coulomb and viscous friction phenomena can be identified from, respectively, thesudden change and the skew slopes in the position error. In figure 7.2(b) a zoomed-in velocityreversal is given. At the zero-crossing, the system gets stuck because of the friction and the PDcontroller needs to build up a certain amount of error to overcome the friction level. This kind ofresponse can be felt pretty well by the operator.

0 2 4 6 8 10 12−1.5

−1

−0.5

0

0.5

1

1.5x 10

−4

Time [s]

Pos

ition

err

or [m

]

(a) Position error

9 9.02 9.04 9.06 9.08 9.10 9.12−4

−2

0

2

4

6

8

10x 10

−3

Time [s]

Vel

ocity

[m/s

]

ReferenceMeasured

(b) Velocity reversal

Figure 7.2: Results from PD controller

0 2 4 6 8 10 12−6

−4

−2

0

2

4

6x 10

−5

Time [s]

Pos

ition

err

or [m

]

(a) Position error

9 9,02 9,04 9,06 9,08 9,12 9,14−6

−4

−2

0

2

4

6

8x 10

−3

Time [s]

Vel

ocity

[m/s

]

ReferenceMeasured

(b) Velocity reversal

Figure 7.3: Results from PID controller

In order to reduce this time, integral control can be added to the controller. Figure 7.3 shows theresults from an experiment with a PID controller. Compared to former results with PD controlonly the tracking error is drastically drastically and friction is compensated very well by adding

30

Page 39: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

7.3 Control with friction compensation

integral control. However, the response around zero velocity is not improved, because there arestill large errors at the zero-crossing. In fact, the response is even worse than with PD control.In addition to the fact that the system gets stuck, it also has an overshoot, which gets larger asthe integral action is increased. This overshoot is extremely harmful for proper haptic rendering,because it can be felt very well by the operator. One should be careful with adding integral control.

7.3 Control with friction compensation

In this section the results of the model based friction compensators will be tested. To be ableto evaluate and compare the performance of each compensator, the experiments are performedwithout integral control.

7.3.1 Classic model

First, experiments are performed to test the static model based friction compensation. Figure7.4 shows the results. Coulomb and viscous friction is well compensated for. However, instead ofthe system getting stuck at zero velocity, the friction is overcompensated. This results in an evenworse velocity reversal compared with using feedback control only. Removing the Stribeck effectfrom the model doesn’t solve the problem. Compensating for Coulomb and viscous friction onlygives slightly less overcompensation, but the velocity reversal still feels very bad.

0 2 4 6 8 10 12−5

−4

−3

−2

−1

0

1

2

3

4

5x 10

−5

Time [s]

Pos

ition

err

or [m

]

(a) Position error

9.04 9.06 9.08 9.1 9.12 9.14−4

−2

0

2

4

6

8

10x 10

−3

Time [s]

Vel

ocity

[m/s

]

ReferenceTacho

(b) Velocity reversal

Figure 7.4: Results from static model compensation

The overcompensation can be explained by the fact that the presliding regime is not incorporatedin the static model. Figure 5.6 shows that the friction force is built up slowly when the directionof motion is reversed. Therefore, the Coulomb friction shouldn’t be switched instantly at a zero-crossing.

7.3.2 One-sided arctan model

The adjustment suggested in section 6.2, the one-sided arctan model, is implemented next. Here,an arctan function is used to smoothen the friction model. The slope of the arctan function,characterized by α, which gives the smoothest velocity reversal, has to be determined experimen-tally. Figure 7.5 shows the results for α = 970 s/m. After tuning the slope for x = 0.1 m/s2, thespikes in the position error are decreased and the velocity reversal is made very smooth. However,further experiments show that using the slope α = 970 s/m for other accelerations than x = 0.1m/s2 again results in non-smooth velocity reversals. Therefore, the experimental tuning of theslope is investigated in depth. Figure 7.6 shows the relationship between the acceleration and thecorresponding slope which gives the best results.

31

Page 40: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Experimental results

0 2 4 6 8 10 12−5

−4

−3

−2

−1

0

1

2

3

4

5x 10

−5

Time [s]

Pos

ition

err

or [m

]

(a) Position error

9.04 9.06 9.08 9.1 9.12 9.14 9.16 9.18−4

−2

0

2

4

6

8

10x 10

−3

Time [s]

Vel

ocity

[m/s

]

ReferenceTacho

(b) Velocity reversal

Figure 7.5: Results from one-arctan model compensation

0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 10

100

200

300

400

500

600

700

800

900

1000

Acceleration [m/s2]

Slo

pe α

[−]

Figure 7.6: Relationship between acceleration xr and slope α

From this figure a position dependency of the friction can be deduced. This can be explained asfollows. If we assume that x(0) = x(0) = 0 and that during a velocity reversal x = constant, thedisplacement of the system is then given by:

x =12xt2 =

12

x2

x=

12

F 2c

α2x, (7.1)

wherein the arctan function is linearized for small velocities, i.e.,

x =Fc

α. (7.2)

Assuming a constant displacement in the presliding regime means that α2x should be constant.The relationship between acceleration x and slope α is then given by:

α ∼√

1x

, (7.3)

which corresponds to the measurements in figure 7.6. It can be concluded that tuning the slope ofthe arctan function different for every acceleration corresponds to trying to incorporate positiondependent friction. However, building up the friction force based on velocity is essentially wrong,since figure 7.6 shows a relationship which implies position dependency. Therefore, it is better toactually incorporate the presliding regime into the friction model as is done in the LuGre modeland the generalized Maxwell-slip model.

32

Page 41: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

7.3 Control with friction compensation

7.3.3 LuGre model

Figure 7.7 shows the results from an experiment with LuGre model based friction compensation.As with arctan friction compensation, the spikes in the tracking error at velocity reversals arealmost completely removed. The zoomed-in velocity reversal shows good behaviour compared tofeedback control and static model based compensation. However, a short sticking period can still berecognized. This can be explained by the fact that the LuGre model doesn’t estimate the preslidingregime perfectly. From figure 6.4 it can be seen that it is initially somewhat undercompensating.

0 2 4 6 8 10 12−5

−4

−3

−2

−1

0

1

2

3

4

5x 10

−5

Time [s]

Pos

ition

err

or [m

]

(a) Position error

9.06 9.08 9.1 9.12 9.14 9.16 9.18 9.2−4

−2

0

2

4

6

8

10x 10

−3

Time [s]

Vel

ocity

[m/s

]

ReferenceTacho

(b) Velocity reversal

Figure 7.7: Results from LuGre model compensation

7.3.4 Generalized Maxwell-slip model

Figure 7.8 shows the results from generalized Maxwell-slip (GMS) model based friction compen-sation. The GMS model turned out to be superior to the LuGre model with regard to modelingthe presliding behavior. Again, there are no spikes in the tracking error. Even the small stickingperiod at the velocity reversal has gone. Although the presliding regime is not perfectly modeledby the four element GMS model the result is very good.

0 2 4 6 8 10 12−5

−4

−3

−2

−1

0

1

2

3

4

5x 10

−5

Time [s]

Pos

ition

err

or [m

]

(a) Position error

9.04 9.06 9.08 9.1 9.12 9.14 9.16 9.18−4

−2

0

2

4

6

8

10x 10

−3

Time [s]

Vel

ocity

[m/s

]

ReferenceTacho

(b) Velocity reversal

Figure 7.8: Results from GMS model compensation

Combining the GMS model based friction feedforward with a PID controller results in the per-formance shown in figure 7.9. Here, one cannot distinguish any changes in direction of motionanymore from either the tracking error or the zoomed-in velocity reversal. The haptic feeling hasbeen improved also.

33

Page 42: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Experimental results

0 2 4 6 8 10 12−5

−4

−3

−2

−1

0

1

2

3

4

5x 10

−5

Time [s]

Pos

ition

err

or [m

]

(a) Position error

9.1 9.12 9.14 9.16 9.18 9.2 9.22 9.24−4

−2

0

2

4

6

8

10x 10

−3

Time [s]

Vel

ocity

[m/s

]

ReferenceTacho

(b) Velocity reversal

Figure 7.9: Results from PID controller with GMS model compensation

7.4 Discussion

Compensation of the friction results in large reductions of the tracking error around zero velocityand improves the smoothness of the velocity reversals enormously. A classical friction model isable to compensate well for Coulomb and viscous friction, but it results in a non-smooth velocityreversal because of overcompensation. This is explained by the fact that this model does notincorporate any presliding behaviour. The one-sided arctan model is able to reduce the overcom-pensation and smooth the velocity reversal very well. However, the slope α of the arctan functionis dependent on the acceleration. Measurements show that the relationship between accelerationx and slope α implies position dependent friction in the presliding regime. Both the LuGre andgeneralized Maxwell-slip model are able to incorporate position dependent presliding behaviour.Experiments showed that the GMS model is superior to the LuGre model with respect to mod-eling the presliding behaviour. Combining a PID controller with both inertia and GMS modelbased friction feedforward results in small tracking errors and a very smooth velocity reversal. Tosummarize, table 7.1 gives both position and velocity peak errors of the performed compensationstrategies.

Table 7.1: Peak tracking errorsFeedback control Compensation strategy Position error [µm] Velocity error [mm/s]

PD control no compensation 140 2.7classic 43 5.3

one-sided arctan 19 0.6LuGre 19 1.5GMS 18 0.5

PID control no compensation 56 1.8GMS 12 0.5

34

Page 43: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Chapter 8

Conclusions and recommendations

8.1 Conclusions

In order to reduce the reversal bump at velocity reversal, the identification, modeling and com-pensation of friction on the z-axis of the HapticMaster was examined during this traineeship. Aliterature search was performed to gain insight in former research done in the field. The survey hasresulted in an overview of existing friction models which incorporate different friction phenomena.Furthermore, possible approaches to compensate for friction were discussed.

The original servo loop of the HapticMaster was adapted in order to apply friction compensa-tion and to be more flexible in designing a feedback controller. A linear feedback controller wasdesigned based on measurements of the FRF of the z-axis structure of the HapticMaster. With thiscontroller various friction identification experiments were performed. First, closed-loop constantvelocity experiments were carried out to determine the friction-velocity map. In these, the frictionforce was estimated by assuming that, at constant velocity, the friction force equals the controloutput. The friction-velocity map shows that Coulomb, viscous and Stribeck friction phenomenaare present. Next, the break-away force is estimated by applying an open-loop ramp input to thesystem and determine the force at which gross sliding occurs. It is seen that this break-away forceis highly nonlinear. Furthermore, presliding is observed. To investigate the presliding behaviourin more detail, the hysteresis loop is measured. Results show that in the presliding regime, thesystem shows spring-like behaviour.

Several nonlinear controllers that compensate for friction are designed and implemented on thesystem. All of them are based on model based friction compensation. It is decided to use modelbased friction compensation, since techniques like dither and impulsive control were consideredinappropriate for haptic devices. A static model, an one-sided arctan model, a LuGre model anda generalized Maxwell-slip model were used.The static friction parameters are obtained from the friction-velocity map using a nonlinear opti-mization algorithm. This resulted in different friction parameters for both positive and negativevelocity.The one-sided arctan model is developed as an optimization of the regular arctan model. It makessure that the full Coulomb friction is compensated for when the system is braking down.The LuGre model parameters, the average bristle stiffness and damping respectively, are obtainedfrom a FRF measurement in the presliding regime. Obtaining parameters of the N elements ofthe generalized Maxwell-slip model is done by means of best fitting the presliding characteristic.A Maxwell-slip model of four elements is chosen to estimate the presliding behaviour.

The friction models are implemented on the experimental set-up. The system performance isexpressed in terms of tracking error, smoothness of the velocity reversal and haptic feeling. Ex-

35

Page 44: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Conclusions and recommendations

periments showed that a classic friction model can compensate well for Coulomb and viscousfriction, but results in overcompensation. This is explained by the fact that this model does notincorporate any presliding behaviour. The one-sided arctan model is able to reduce the overcom-pensation and smooth the velocity reversal very well. However, the slope α of the arctan functionshould be tuned differently for every possible acceleration during a velocity reversal. Measure-ments showed that the relationship between acceleration x and slope α implies position dependentfriction in presliding regime. Both the LuGre and generalized Maxwell-slip model are able toincorporate this presliding behaviour. Experiments showed that the GMS model is superior to theLuGre model with respect to modeling the presliding behaviour and compensating for friction.Combining a PID controller with both inertia and GMS model based friction feedforward resultsin small tracking errors and very smooth velocity reversals.

8.2 Recommendations

A few aspects encountered during this traineeship need further research. This traineeship wasfocussed on reducing the reversal bump based on the tacho signal measured at the dc motor. Hapticfeeling, however, is sensed at the end effector. A psychophysical analysis should be performed todetermine what kind of response around zero velocity actually feels nice.In addition to friction, motor torque ripple is also a major disturbance in the system. A suspicionexists that motor torque ripple limits the values of the feedback gains. Tuning the feedbackgains too high results in feeling an irregularity which may be caused by motor torque ripple.Compensating for this may enhance haptic performance.Good performance is already achieved with the four element GMS estimation of presliding regime.However, incorporating the difference between motion in positive and negative direction mayimprove the performance even more. Therefore, a direction dependent GMS friction model shouldbe designed.

36

Page 45: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Appendix A

Datasheets

A.1 HapticMaster

37

Page 46: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Datasheets

A.2 Brushed DC motor

DC-S ERVOMOT OR

RS240B

Low speed torque 0.39 N.m Mo

Permanent current at low speed 6 A Io Supply voltage with loaded motor 28 V U Definition speed 3000 rpm N Maximum supply voltage 40 V Umax Maximum speed 5500 rpm Nmax Peak current 20 A Imax Back emf constant at 1000 rpm (25°C)* 7.2 V Ke Torque constant 0.068 N.m/A Kt Static friction torque 1.5 N.cm Tf Viscous damping for 1000 rpm 0.26 N.cm Kd Winding resistance(25°C) 0.68 Ω Rb Winding inductance 0.45 mH L Rotor inertia 0.0000325 kg.m² J Thermal time constant 7.5 min Tth Motor mass 1.04 kg M

All data are given in typical values under standard conditions

FICHER-001

Création: 14 août 1987 Edition: 02/mars/1999 RS240B .f

8 avenue du Lac BP249F-21007 DIJON Cedex

0

0.2

0.4

0.6

0.8

1

1.2

1.4

0 1000 2000 3000 4000 5000 6000

Continuous duty (Tamb=40°C) Impulse limitation or U=40V

U=36V U=24V

Tor

que

in N

.m

Speed in rpm

38

Page 47: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

A.3 Tacho generator

A.3 Tacho generator

Tacho generators Series TBN with hollow shaft MATTKE AG - SERVOTECHNIK

DB_TBN103-206-306_eng.pdf 1 von 1

Tacho generatorsSeries TBN

with hollow shaft +

Technical Data: Unit TBN 103 TBN 206 TBN 306

EMF/1,000rpm-1 (open circuit): V 3 6 6

Bidirectional tolerance: % KE <1 <1 <1

Peak-to-peak ripple:*** % U <5 <3 <2

Linearity with ref. to 3,600rpm: % <0.2 <0.15 <0.15

Max. perm. current:* mA 15 15 25

Max. speed:** rpm 10,000 10,000 6,000

Rotor moment of inertia: g cm2 15 50 250

Temperature coefficient of output voltage: %/°C -0.015 -0.015 -0.015

Rotor terminal resistance at 25°C: Ohm 60 47 11

Inductance: mH 14 11 6

Isolation class: B B B

Protection: IP 40 IP 40 IP 40

Weight: g 120 200 250

Article Code: TTB103 TTB206 TTB306* = thermally allowable / ** = mechanically allowable / *** = filter RC (800 Hz)+ = available with our motors series R...

Dimensions: TBN 103 Dimensions: TBN 206 / TBN 306

TBN C d E G H I J K S

206 49.5 max. 7 H 7 22.7 38 ±0.1 9.3 60 max. 38 ±0.1 M3 38

306 64.0 max. 12.5 28.0 43 ±0.1 10.3 72 max. 50 ±0.1 M4 52

Home | english start page | Products | Contacts | News | Download | Imprint © MATTKE AG

39

Page 48: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Datasheets

A.4 Incremental encoder

40

Page 49: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Appendix B

Servo loop

This appendix describes the original servo loop of the HapticMaster. In chapter 4 the basic struc-ture was already shown. Here, we will discuss the servo loop in full detail.

The goal of the servo loop is to control the motor such that it follows the reference trajectoryas closely as possible up to a certain bandwidth. Figure B.1 shows the full servo loop as it wasoriginally implemented in the HapticMaster. The servo loop consists of three main components:the software, an amplifier, a dc motor and the mechanical structure. Although proportional, in-tegral and derivative feedback terms can be recognized in the servo loop, the controller is not aclassical digital PID controller which sends a voltage to the amplifier. The controller can be seenas a PI velocity controller with additional position feedback Kp and inertia feedforward Ka. Theloop contains a digital controller in software and an analog controller in the amplifier. The feed-back terms are divided over the different components in the loop. Essentially, velocity feedback isrealised by the analog PI controller using a tachometer. Position feedback, using an encoder, andinertia feedforward are realised by software control.

The software gain ksw1, shown in figure B.1 is scaling the amplifier command such that the voltageerror ue at the summing junction in the amplifier represents the velocity error. This scaling isnecessary since the tacho signal is included in the loop. The tacho signal is a (filtered) voltagewhich is proportional to the rotational velocity of the motor shaft.The gain kDA represents the conversion from digital output to an analog voltage. The amplifiercan be supplied with a voltage in the range of -5 V to 5 V.The current which is eventually supplied to the dc motor originates from the analog PI controlledreference voltage.

In order to apply friction compensation and remove undesired integral control components, theservo loop is adjusted. By means of two switches the analog integrator and the analog tachofeedback are eliminated from the control loop. This results in an amplifier that can be representedby a simple gain.

41

Page 50: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Servo loop

K v

k sw1

k DA

k re

f

2 /p

1/ i s

1/(1

+R

Cs)

k amp

k m

2 /p

1/

m t

1/s

K a

K p

1/s

2 p

k R

k ta

cho

k enc

a ref

v ref

x ref

x

v ref

v refb

its

u ref

u e i

T

F

a v

x

u ta

cho

u tach

o_fil

tere

d

k sw2

Hap

tic M

aste

r S

ervo

Lo

op fo

r z-

axis

So

ftw

are

CA

U

Hap

ticM

aste

r

-

-

ticks

Sym

bo

l M

ean

ing

U

nit

a

End

effe

ctor

acc

eler

atio

n m

/s 2

a re

f R

efer

ence

acc

eler

atio

n m

/s 2

F

Mot

or fo

rce

N

A

ngle

ra

d

ticks

E

ncod

er ti

cks

ticks

i

Mot

or c

urre

nt

A

T

Mot

or to

rque

N

m

u e

Err

or s

igna

l V

u re

f R

efer

ence

vol

tage

V

u ta

cho

Tac

ho v

olta

ge

V

u ta

cho_

filte

red

Filt

ered

tach

o vo

ltage

V

v

End

effe

ctor

vel

ocity

m

/s

v re

f R

efer

ence

vel

ocity

m

/s

v re

fbits

R

efer

ence

vel

ocity

in b

its

bits

Ang

le v

eloc

ity

rad/

s x

End

effe

ctor

pos

ition

m

x

ref

Ref

eren

ce p

ositi

on

m

k CIC

Sym

bo

l M

ean

ing

V

alu

e U

nit

K

a A

ccel

erat

ion

gain

0.

001

k am

p A

mpl

ifier

gai

n 14

.2/ k

ref

A/V

k C

IC

Diff

eren

tial s

calin

g C

IC

2

k D

A

DA

con

vert

ing

10/2

16

k en

c E

ncod

er r

esol

utio

n 20

00/2

k m

M

otor

con

stan

t 0.

068

Nm

/A

K p

Pos

tion

gain

5

a 10

0

k R

S

calin

g 1/

12

k re

f S

calin

g 0.

4

k sw

1 S

oftw

are

scal

ing

2418

9

k sw

2 S

oftw

are

scal

ing

p /2

000

k ta

cho

Tac

hom

eter

gai

n 0.

006*

60/2

V

/(ra

d/s)

K v

Vel

ocity

gai

n 1

m t

Tot

al m

ass

of H

aptic

Mas

ter

18?

kg

p P

itch

0.4*

0.02

54 m

R

C

Filt

er c

onst

ant

0.5e

-3 s

i In

tegr

atio

n tim

e co

nsta

nt

0.00

5 s

CIC

Figure B.1: HapticMaster servo loop in full detail

42

Page 51: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Appendix C

Maxwell-slip model parameters

This appendix describes how to determine the parameters for N elementary friction models in theMaxwell-slip model. An elementary slip model consists of a slip-block with a maximum frictionforce Wi and a spring with stiffness ki. A number N of these elementary friction models in parallelare used to estimate the hysteresis loop measured in the presliding regime. Figure C.1 shows theparallel structure.

Figure C.1: Maxwell-slip model for N elements

The friction model is described by two equations. When an element is in the presliding regime,its behaviour is described by:

dFi

dt= kix. (C.1)

Once the friction force exceeds its maximum value, the slip-block will slip. This is modeled by:

dFi

dt= sgn(x)C

(αi −

Fi

g(x)

), (C.2)

where αi determines the maximum friction force Wi for an elementary model as Wi = αig(x).Hence, there are two parameters which determine the friction behaviour of an elementary frictionmodel: the stiffness ki and the maximum friction value which is determined by αi. These param-eter can be estimated from a measured hysteresis loop as follows.

Assume a measured hysteresis loop as given in figure C.2. The stiffness at the first part of thehysteresis loop is the sum of the stiffness of all elements. In the second part, the stiffness of the el-ement with the lowest attainable maximal friction force is not incorporated anymore. The shaded

43

Page 52: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Maxwell-slip model parameters

part shows the contribution of one specific element. If we measure the friction force contribution∆Fi on the y-axis, the maximum friction force parameter αi can be determined as:

∆Fi = 2αiFc, (C.3)

αi =∆Fi

2Fc. (C.4)

The contribution to the presliding displacement ∆xi can be measured on the x-axis. Then, thestiffness parameter ki can be determined as:

∆Fi = ki∆xi, (C.5)

ki =∆Fi

∆xi. (C.6)

This procedure can be repeated N times to obtain all parameters for the N elements in theMaxwell-slip model.

Figure C.2: Determining the Maxwell-slip parameters

44

Page 53: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Appendix D

Source code

Introduction

This appendix gives the source codes used for performing experiments. Most of the code presentedis part of a larger application. Only the essential code is given.

Integral control

// --------------------------------------------------------------------void CActuatorAMachine::UpdateEncoderPosErrorIntegrator()// --------------------------------------------------------------------

// Integrate the encoder position error if applicable

// PL 2006 - consider stopping this while m_VelCmd == 0,// to prevent windup parallel to friction compensationdouble timeStep =

((CFcsBaseRoot*)rootComponent)->ApplicationTimeStep();

if ( ( m_CurrentStateID == STATE_ENABLED ) &&( m_PosIntGain > 0.0 ) )

m_IntAnalogEq += timeStep * m_EncoderPosError * m_PosIntGain;

else

m_IntAnalogEq = 0.0;

Lead filter

///////////////////////////////////////////////////// LEAD FILTER /////////////////////////////////////////////////////////

u_PID = m_PosGain * m_EncoderPosError+ m_VelGain2 * m_VelTachoError+ m_IntAnalogEq;

double timeStep =((CFcsBaseRoot*)rootComponent)->ApplicationTimeStep();gamma = timeStep / (m_TauLeadFilter + timeStep);

u_PID_Filtered = gamma*u_PID + (1.0-gamma)*u_PID_Filtered;

Static model based compensation

/* Evaluate friction compensatation output */

45

Page 54: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Source code

switch (FrictionCompSelect)

// NO MODEL BASED FRICTION COMPENSATIONcase 0:

u_comp = 0.0;break;

// STRIBECK FEEDFORWARD COMPENSATIONcase 1:

if (m_VelCmd > 0.0)

u_comp = Fc_sb_pos+ (Fs_sb_pos-Fc_sb_pos)*exp(-1*pow(fabs(m_VelCmd/vs_pos),ds_pos))+ Fv_sb_pos * m_VelCmd+ Fg_sb;

else if (m_VelCmd < 0.0)

u_comp = Fc_sb_neg+ (Fs_sb_neg-Fc_sb_neg)*exp(-1*pow(fabs(m_VelCmd/vs_neg),ds_neg))+ Fv_sb_neg * m_VelCmd+ Fg_sb;

else if (m_VelCmd == 0.0 && fabs(amplifierCommand) > 0.0)

u_comp = Fs_sb_pos);else if (m_VelCmd == 0.0 && fabs(amplifierCommand) < 0.0)

u_comp = Fs_sb_neg);break;

One-sided arctan model based compensation

/* Evaluate friction compensatation output */switch (FrictionCompSelect)

// NO MODEL BASED FRICTION COMPENSATIONcase 0:

u_comp = 0.0;break;

// ONE-SIDED ARCTAN FEEDFORWARD COMPENSATIONcase 1:

// Step 1:// Calculate new domain

if (m_ArctanDomainPrev == 1) // Then check whether you leave the arctan domain by comparing// abs(Velocity) > Velocity_arctan

if (fabs(Velocity) >= m_VelArctan)

m_ArctanDomainPrev = m_ArctanDomain;m_ArctanDomain = 0;

else if (fabs(Velocity) < m_VelArctan)

m_ArctanDomainPrev = m_ArctanDomain;m_ArctanDomain = 1;

else if (m_ArctanDomainPrev == 0) // Check if you enter the arctan domain// by comparing signs of velocity and accelerations

if ( sgn(VelocityPrev) != sgn(Velocity) )// then you enter the arctan domain

m_ArctanDomainPrev = 1;m_ArctanDomain = 1;

46

Page 55: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

else// then you stay in the Coulomb domain

m_ArctanDomainPrev = m_ArctanDomain;m_ArctanDomain = 0;

// Step 2:// Check whether you are in the arctan domain or in the Coulomb domain// and apply the corresponding friction compensation

if (m_ArctanDomain == 1) // ArctanDomain

if (Velocity > 0.0)

u_comp = (2*Fc_pos-Fm)*atan(alpha_atan*Velocity)/0.5/PI;u_comp = u_comp - (Fc_pos-Fm) + Fv_pos*Velocity + Fg;

else if (Velocity < 0.0)

u_comp = (2*Fc_pos-Fm)*atan(alpha_atan*Velocity)/0.5/PI;u_comp = u_comp + (Fc_pos-Fm) + Fv_neg*Velocity + Fg;

else

u_comp = 0.0;

else if (m_ArctanDomain == 0) // Coulomb domain

if (Velocity > 0.0)

u_comp = Fc_sb_pos+ (Fs_sb_pos-Fc_sb_pos)*exp(-1*pow(fabs(Velocity/vs_pos),ds_pos))+ Fv_sb_pos * Velocity+ Fg_sb;

else if (Velocity < 0.0)

u_comp = Fc_sb_neg+ (Fs_sb_neg-Fc_sb_neg)*exp(-1*pow(fabs(Velocity/vs_neg),ds_neg))+ Fv_sb_neg * Velocity+ Fg_sb;

else

u_comp = 0.0;

// Step 3:// Update VelPrev and AccPrev

VelocityPrev = Velocity;m_AccCmdPrev = m_AccCmd;

break;

LuGre model based compensation

/* Evaluate friction compensatation output */switch (FrictionCompSelect)

// NO MODEL BASED FRICTION COMPENSATIONcase 0:

u_comp = 0.0;break;

// LUGRE FRICTION COMPENSATION

47

Page 56: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Source code

case 1:

// Calculate u_compif (g != 0.0)

u_comp = s0 * hatz+ s1 * (Velocity - hatz*fabs(Velocity)/g)+ Fv_lugre * Velocity+ Fg_lugre;

else

u_comp = 0.0;

// Update state variablesif (Velocity != 0.0)

g = ( (Fc_lugre + (Fs_lugre-Fc_lugre)*exp(-1.0*pow(fabs(Velocity/vs_lugre),2.0))) / s0 );a1 = -1*exp( -1*(1.0/2500.0)*fabs(Velocity)/g );b0 = (1.0+a1)*g/fabs(Velocity);hatz = (-1.0*a1*hatz) + b0*Velocity;

break;

GMS model based compensation

/* Evaluate friction compensatation output */switch (FrictionCompSelect)

// NO MODEL BASED FRICTION COMPENSATIONcase 0:

u_comp = 0.0;break;

// GMS MODEL COMPENSATIONcase 1:

// Calculate new static friction contribution s(v)if (Velocity != 0.0)

s = Fc * sgn(Velocity);

// Check whether you need to leave or enter the presliding regimeif ( fabs(F1) > 1.01 * fabs(a1*s) )

presliding1 = 0;if ( sgn(Velocity) != sgn(VelocityPrev) )

presliding1 = 1;

if ( fabs(F2) > 1.01 * fabs(a2*s) )presliding2 = 0;

if ( sgn(Velocity) != sgn(VelocityPrev) )presliding2 = 1;

if ( fabs(F3) > 1.01 * fabs(a3*s) )presliding3 = 0;

if ( sgn(Velocity) != sgn(VelocityPrev) )presliding3 = 1;

if ( fabs(F4) > 1.01 * fabs(a4*s) )presliding4 = 0;

if ( sgn(Velocity) != sgn(VelocityPrev) )presliding4 = 1;

// Calculate elemental contributions to total friction compensation forceif ( presliding1 == 1 )

F1 = F1 + k1*Velocity*h;else

F1 = F1 + sgn(Velocity) * C * ( a1 - F1/s ) * h;

if ( presliding2 == 1 )F2 = F2 + k2*Velocity*h;

elseF2 = F2 + sgn(Velocity) * C * ( a2 - F2/s ) * h;

48

Page 57: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

if ( presliding3 == 1 )F3 = F3 + k3*Velocity*h;

elseF3 = F3 + sgn(Velocity) * C * ( a3 - F3/s ) * h;

if ( presliding4 == 1 )F4 = F4 + k4*Velocity*h;

elseF4 = F4 + sgn(Velocity) * C * ( a4 - F4/s ) * h;

// Sum up all elemental forces + viscous friction forceu_comp = F1 + F2 + F3 + F4 + Fv*Velocity + Fg;

// Update VelPrevVelocityPrev = Velocity;

break;

Tacho offset compensation/*******************************************///////// TACHO OFFSET COMPENSATION ////////*******************************************/

m_EncoderPos = GetMeasuredPosition();double timeStep =

((CFcsBaseRoot*)rootComponent)->ApplicationTimeStep();alpha = timeStep / (m_TauTachoOffset + timeStep);

// Calculationsm_EncoderPosVel = (m_EncoderPos - m_EncoderPosPrev) / timeStep ;m_TachoOffset = m_VelTacho - m_EncoderPosVel;m_TachoOffsetFiltered = alpha*m_TachoOffset + (1.0-alpha)*m_TachoOffsetFiltered;

// Update variablesm_VelTacho = m_VelTacho - m_TachoOffsetFiltered;m_EncoderPosPrev = m_EncoderPos;

49

Page 58: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Source code

50

Page 59: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Acknowledgements

This report presented the results of a fifteen week traineeship, which has been carried out atthe Robotics department of Moog-FCS in Nieuw Vennep. I would like to thank Piet Lammertseand Henk Nijmeijer for offering me this assignment and great opportunity to develop myself asa mechanical engineer. I would like to thank Piet in particular for his great support during mytraineeship. Without his advice, criticism and our discussions this research would not have beenpossible. I’d also like the other employees at Moog FCS Robotics. With their practical knowl-edge, Harry Wierda and Jos Meuleman offered me great advice and solutions to several problems.Moreover, Niels van den Braber did a great job helping me with programming C++.

Besides former mentioned people, my appreciation goes out to Levi Spreeuwers from the Con-trol Loading department of Moog FCS. I would like to thank him for advising me with the arctanfriction compensation.

Tom VerschurenNieuw Vennep, 2007

51

Page 60: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Source code

52

Page 61: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

Bibliography

[1] F. Altpeter, “Friction modeling, identification and compensation”, Ecole Polytechnique Fed-erale de Lausanne, no. 1988, 1999.

[2] F. Altpeter, P. Myszkorowski, M. Kocher and P. Longchamp, “Friction compensation: PIDsynthesis and state control”, European Control Conference, TH-MI1, 1997.

[3] B. Armstrong-Helouvry, P. Dupont and C. Canudas de Wit, “A survey of models, analysistools and compensation methods for the control of machines wih friction”, Automatica, vol.30, no. 7, 1994, pp. 1083-1138.

[4] B. Armstrong-Helouvry, “Control of machines with friction”, Kluwer Academic Publishers,Boston, 1991.

[5] P.A. Bliman and M. Sorine, “Easy-to-use realistic dry friction models for automatic control”,Proc. of 3rd European Control Reference, 1995, pp. 3788-3794.

[6] C. Canudas de Wit, H. Olssen, K.J. Astrom and P. Lischinksy, “A new model for controlof systems with friction”, IEEE Transaction on Automatic Control, vol. 30, no. 3, 1995, pp.419-425.

[7] C. Canudas de Wit, K.J. Astrom and K. Braun, “Adaptive friction compensation in dc motordrives”, IEEE Journal of Robotics and Automation, vol. RA-3, no. 6, 1987, pp 681-685.

[8] P.R. Dahl, “A solid friction model”, Aerospace Corp., El Segundo, CA. Tech. Rep. TOR-0158(3107-18)-1, 1968.

[9] T. Dietz “Model-based friction compensation for the Furuta Pendulum using the LuGremodel”, Lund University, Department of Automatic Control, 2006.

[10] L. Freidovich, A. Robertson, A. Shiriaev, R. Johansson, “Friction compensation based onLuGre model”, Proceedings of the 45th IEEE Conference on Decision and Control, pp 3837-3842, 2006.

[11] M. Gafvert, “Comparison of two dynamic friction models”, Lund Institute of Technology ,Lutfd2/tfrt-5561-se, 1996.

[12] E. Gortcheva, A. Poznuak, V.D. de Leon, “On Nonlinear Robust Control for Robot Ma-nipulator with Unkown Friction”, Proceedings of the 37th IEEE Conference on Decision andControl, pp. 2019-2022, 1998.

[13] D.A. Haessig and B. Friedland, “On the modeling and simulation of friction”, Journal ofDynamic Systems, Measurements and Control, vol 113, 1991, pp. 354-362.

[14] R.H.A. Hensen, “Controlled mechanical systems with friction”, PhD dissertation, EindhovenUniversity of Technology, 2002.

[15] D. Karnopp, “Computer simulation of stick-slip friction in mechanical dynamic systems”,ASME J. of Dynamic Systems, Measurements and Control, 107(1), pp 100-103, 1985.

53

Page 62: Friction compensation for a haptic manipulator: the ...The performance of mechanical systems, such as servomechanisms and robotic systems, is often deteriorated by friction. Friction

BIBLIOGRAPHY

[16] M.P. Koster, “Constructieprincipes voor het nauwkeurig bewegen en positioneren”, TwenteUniversity Press, 1998, pp 291-310.

[17] V. Lampaert, F. Al-Blender and J. Swevers, “A generalized Maxwell-slip friction modelappropiate for control purposes”, Lund Institute of Technology , Lutfd2/tfrt-5561-se, 1996.

[18] V. Lampaert, F. Al-Blender and J. Swevers, “Comparison of model and non-model basedfriction compensation techniques in the neighbourhood of pre-sliding friction”, Proceedings ofthe 2004 Automatic Control Conference, pp 1121-1126, 2004.

[19] N. Mallon, N. van de Wouw, D. Putra and H. Nijmeijer, “Friction compensation in a con-trolled one-link robot using a reduced-order observer”, IEEE Transactions on Control SystemsTechnology, vol. 14, no. 2, pp 374-383, 2006.

[20] D. Putra, H. Nijmeijer, N. van de Wouw, O.C.L. Haas and K.J. Burnham, “Analysis of frictioncompensation effects in controlled mechanical systems”, Automatica, 43, pp 1387-1394, 2007.

[21] J. Swevers, F. Al-Blender, C.G. Ganseman and T. Prajogo, “An integrated friction modelstructure with improved presliding behavior for accurate friction compensation”, IEEE Trans-actions on Automatic Control, vol. 45, no. 4 pp. 675-686, 2000.

[22] H. Olsson, K.J. Astrom, P. Lischinksy, C. Canudas de Wit and M. Gafvert, “Friction modelsand friction compensation”, European Journal of Control, vol. 4, no. 3, pp 176-195, 1998.

[23] E. Park, H. Lim and C. Choi. “Position control of X-Y table at velocity reversal usingpresliding friction characteristics”, IEEE Transactions on Control Systems Technology, vol 11,no. 1, 2003 pp. 24-31.

[24] N. van Seters, “Compensation of friction in the flight simulator stick using an adaptivefriction compensator”, University of Twente, Electrical Engineering, Control Laboratory, no.006R2001, 2001.

[25] L. Spreeuwers “Learning friction compensation”, University of Twente, Electrical Engineer-ing, Control Laboratory, no. 0xxR99

[26] H.M.R. Suy, “Identification of a friction model for MoS2 solid-lubricated bearings in the con-text of friction compensation”, Eindhoven University of Technology, Mechanical Engineering,Dynamics and Control Group, no. DCT 2004-07, 2004.

[27] J.T. Teeter, M. Chow and J.J. Brickley, “A novel fuzzy friction compensation approach toimprove the performance of a dc motor control system”, IEEE Transactions On IndustrialElectronics, vol. 43, no. 1, 1996, pp. 113-120.

[28] N.J.M. van Dijk, “Adaptive friction compensation of an inertia supported by MoS2 solid-lubricated bearings”, Eindhoven University of Technology, Mechanical Engineering, Dynamicsand Control Group, no. DCT 2005-06, 2005.

54