You are on page 1of 9

Smooth Control the Coaxial Self-Balance

Robot Under Impact Disturbances

Li Chaoquan, Gao Xueshan and Li Kejie

Intelligent Robotics Institute, Beijing Institute of Technology, China

Abstract The purpose of this paper is to propose a


systematic smooth control method for improving the
stability of the twowheeled selfbalance robot under
impactdisturbances.Forenhancingtherobtotstability,a
blend controller based on states feedback control
embedded with the PID speed synchronization is
estabilished, as well as a hybrid filter composes of RC
network and Kalman algorithm. With the hybrid filter,
disturbance signals are maximally attenuated or directly
eliminated, and the system sensitivity to the impact
disturbances significantly declines ; under the blend
motion controller, the robot can not only keep balance
under impacts but also achieve synchronization of the
two driving wheels. The dynamic model, the blend
controller, hybrid filter, and experimental results
including application to transport are described, both of
the simulation and experimental results are provided to
verifytheanalysis.

Keywords Smooth control, twowheeled robot, compact


disturbances

1.Introduction
Twowheeled coaxial robots, with their outstanding
advantages, such as compact in mechanical structure,
flexibility in motion and portability, have attracted
considerable attentions in the past decades, JOE (Grasser,
DArrigo et al. 2002), nBOT(Anderson. 2007) and many
other similar robots have been reported over worldwide.
Balancecontrolisoneoftheresearchissues,andavariety
of control methods have been proposed for it, such as
59 International Journal of Advanced Robotic Systems, Vol. 8, No. 2. (2011)
Vol. 8, No. 2. (2011), ISSN 1729-8806, pp 59-67

slidingmodel(RongJongandLiJung2006;Huang,Guan
etal.2010), adaptivecontrol(RongJong andLiJung2006)
and state feedback(Shiroma, Matsumoto et al. 1996;
Grasser, DArrigo et al. 2002; Pathak, Franch et al. 2005).
Although balance control is fundamental for the
selfbalancerobots,itisnottheultimateresearchgoal.For
a robot with practical values, balance control is the basis,
anditneedstohavegoodstabilitynomatterdisturbedor
not,especiallyundertheimpactdisturbances.Otherwise,a
tiny impact disturbance may be a fatal unstable resource,
and even directly cause the robot out of balance. When
used as a mobile robot platform, instability caused by the
impact may lead to damages of the airborne equipment;
and conditions may even worse when it is as a personal
transport,forserioussecurityproblemsmayhappenwhen
it suddenly lose its balance. Therefore, studying how to
decay the impacts and realize stability is meaningful and
important. In spite of many studies have been published
concerningthebalancecontrol,butfewattentionsarepaid
to the impact disturbance. In reference (Zhou, Wu et al.
2004), the authors build a disturbance observer for
controlling the robot and give the simulation results, it
shows that the system has better ability to restrain
disturbances and improved motion capabilities. It is
obviously that interference studies can improve system
stability. Different from with the former researches, we
focus on a new systematic way to attenuate the impact
disturbances,whichiseasiertoimplement.

In the balance control studies, states feedback control


may be the most popular and successful one so far.
Different types of states feedback control method are
www.intechweb.org
www.intechopen.com

used to control the robot balance (Gans and Hutchinson


2006; Butler and Bright 2008). However, the robot speed
not the wheel speed is selected as the state variables in
themodellingprocess.Sofortherobotspeed,itisaclose
control loop, but for the two driving wheels, it is
openloop.Speedofthetwodrivingwheelsmaydifferent
and can not realize a line running. As a result, it is
necessary to add a closeloop in order to get smooth
control, whether in equilibrium or in the running
condition. PID (proportion, integrated and differential)
control with its outstanding performance has successful
applications in the past researches. Consequently, we
proposetoaddaPIDsubcontrollertothestatesfeedback
controllertoachievedoubleloopcontrollerinthispaper.

Atthesametime,nomatterwhatkindofcontrolmethod
isused,accurateestimatesofsystemstateinformationis
a fundamental problem. For instance, the simple way of
estimating the absolute angle of the robot is to integrate
theangularvelocityoutfromagyro.However,itwillbe
inadequateoverprolongedperiodsoftime,becausedrift
in the gyro signal will result in a ramping error in the
position measurement. This problem is described in
reference (Ashokaraj, Silson et al. 2002; Chen 2003;
Imamura, Takei et al. 2008), and the authors had to
designaspecialcompensatortodealwith.Inthispaper,
wegetthetiltanglefromdirectmeasurementratherthan
integration; an accelerometer and a gyro compose the
measurement system, the accelerometer measures the
robot tilt angle, and the angular velocity is measured by
the gyroscope. In this way, the accelerometer provides a
good lowfrequencies estimate of its orientation in
gravity, and it can get a better response in the effective
frequency range of the robot. A gyro measures only the
absoluteangularrate.Althoughitcanestimatethestates
value more accurate, a strong filter is more necessary. A
hybrid filter based on RC network and Kalman filter for
sensor signals filtering is designed. Unlike previous
studies (Chen 2003; Imamura, Takei et al. 2008), the
estimation method for the states values we proposed is
compactableandhighlyeffective,anditdosenotneedto
considerthedriftofthesensors.

This paper presents a control method to eliminate the


impactofinterference,soastorealizesmoothcontrolfor
the twowheeled coaxial selfbalance robot under the
impact disturbances. The controller design, the blend
filterandexperimentalresultsarealsopresented.

2.Controllerdesign

The coaxial twowheeled robot is inherent unstable and


underactuatedsystem(Andary,Chemorietal.2008),all

of the positions such as keep balance and running are


realized by the torque of thetwo driving wheels, shown
in Fig.6. Theoretically, when the two driving wheels are
fed by the same torque, the robot will only move in one
direction(withasmallforwardandbackwardmovement
before the settlement is achieved)(Ahmad, Tokbi et al.
2009).Here,weonlyfocusonthexdirectionandassume
thatthetorquesfedonthetwowheelsarethesame.Fig.1
showsthediagramofforceactingontherobot,wherethe
variables are defined as follows (McGill & King, 1995;
Ren,Chen,Tsai,&Yao,2004):

Tr

r
fr

Hr

xr
Hl

mg

yp

y
xl

Vl

y
Tl

D/2

Hr

fl

Hl

xp

Tg
Mg

xl

xr

Vr

mg

Figure1.Straightrunningmodelfortherobot

m :Weightofonedrivingwheel
M :Weightofrobotbody
J :Momentofinertiaofthedrivingwheel

J p :Momentofinertiaoftherobotbody
R :Radiusofthewheel
D :Distancebetweenthetwowheels
L :DistancefromsystemCenterofgravitytorotaryaxis

:Tiltangularofrobotbody
:Tiltangularspeedoftherobotbody
xm :Displacementof x direction
Tr , Tl :Torquesofthedrivingwheels

Analysis system and operation of the forces, the


following kinetics equations are established based on
Newtonanalysis:

(Tr Tl ) / R
xm (M 2m 2J / R2 ) ( cos 2 sin )ML (1)

2
2

(2)
J P M ( g L sin L cos ) L sin [
x m M ( cos sin ) M L ] L cos (Tr Tl )

60 International Journal of Advanced Robotic Systems, Vol. 8, No. 2. (2011)

www.intechweb.org
www.intechopen.com

For DC gear brush motors, following relationship exists,


asshowninequation(3):

K K N 2m NK mU

(3)

T m e
Ra
Ra

upper two equations are continuous. For the computer


control,theycanbedeformedtodiscreteequationsas:

Where K , K is the motor constant, N is the reduction


m
e

u (n ) rp = K rP e(n ) + K ri e(i) + K rd [e(n ) - e(n - 1) ] (9)

ratio, m is the motor rotation angular speed, R is the


a

motor resistance, T is the output torque of the reducer


and U isthemotorarmaturevoltage.

Modifying(1)to(3)andthenlinearizingtheresultround
the operating point ( 0, v 0 ) the systems state
spaceequationscanbewritteninmatrixformas:

v 1 0 0v b21 b21
a a 1 0 0 Ul
22 23
U
r

a 42 a43 0

b41 b41

(4)

a22 a23 a42 a43 b21 b41


determinedbythesystem,and U l , U l arethearmature
,

Where

are constants

voltageofthetwo motors.

Astatesfeedbackcontrollercanbeestablishedaccording
to equation (4), and it only can achieve balance control
and line running. In this controller, the robot velocity
v isselectedasthesystemstatevariable,anditisdefined
byequation(5).

u (n ) lp = K lP e(n ) + K li e(i) + K ld [e(n ) - e(n - 1) ] (8)


i= 0
n

i= 0

Inthisway,thestructureoftheequationsbecomesclear,
where u(n)*p is the motor control voltage in the control
cycle n , e(n) is the velocity error, K *P , K *i and

K *d respectively are the proportional, integral and


differential constants. In the actual designing of the
controller, in order to make the algorithm compact and
easy to implement, the right wheel speed is selected as
the reference rate, and control the left wheel speed to
follow with the right. Consequently, equation (9) can be
changedas:

u(n) rp = u(n) reference = k1 q + k 2 w + k 3 v


(10)

Theleftcontrolvoltageis:

u(n)lp = k1 q + k 2 w + k 3 v + Du(n -1)

Where Du(n -1) = u(n)lp - u(n) reference .

Robot

UR

v 0.5( v l v r )

Where

vl

and

vr

(5)

are the speeds of the two driving

de(t)

dt
de(t)

e(t)dt + k rd
dt

u (t) lp = K lP e(t) + k li e(t)dt + k ld

(6)

u(t) rp = K rP e(t) + k ri

(7)

Where u(t)*p is the output of the PID controller, and

K *P , k *i , k *d are the coefficients of the controller. The


www.intechweb.org
www.intechopen.com

UL

wheels. From equation (4), a close loop is easy to


establishfor v ,butforthespeedofthetwowheels,itis
openloop. This will lead to different speed of the two
wheels,itisintolerablewhentherobotrunningintheline
model for the existing of hunting. As a result, it is
necessary to add a new loop after the state feedback
controller to control the speed of the two wheels, and a
PIDcontrollermaybethebestchoice.Takingintoaccount
the amount of state space control of the controller is the
armature voltage, we select the armature voltage is the
outputofthePIDcontroller.ThePIDcontrolleriseasyto
implement, and the controller we designed shown as
follows:

(11)

+
+
+

u lp

u rp

vl

u rk

vr

PID
+

u lk
+

remoter

Ki

Figure2.Hybridcontroller

Sofar,ahybridcontrollerwithtwoclosedloopshasbeen
established, the controllers inputs are the control
voltagesofthemotorsandoutputsarethestatevariables.
Although nominally there are two inputs, but from the
equation (5) can be seen walking in the completely line
model, exactly the same input, can be considered a
singleinput system. Different from [4] [5], a PID
closedloop is added, so the new controller can control
the robot in a state of equilibrium while to synchronize
thespeedofthetwowalkingwheelsatthesametime.

Li Chaoquan, Gao Xueshan and Li Kejie: Smooth Control the Coaxial Self-Balance Robot Under Impact Disturbances

61

3.Sensorbasicrelations

Inthecontrollerdesignprocess, v , and havebeen


identified as system state variables. This sensor system
determining the system state variables must be able to
provide all the information, which determines the
systemsensor system must be able to provide
informationforallstatevariables.Wecangettheabsolute
tilt angle of the robot body from the accelerometer,
and we can also obtain the realtime angular velocity
information of the gyro outputs. But we can not
directlyobtaintherobotvelocity v byRotaryencoders.
A rotary encoder can only provide a relative measure of
the rotation between two bodies. For the coaxial
selfstabilizing robot, an encoder which measures the
relative angle between the body and the wheel. For
invertedcoaxialselfstabilizingrobot,toobtaintherobot

velocity v , it is necessary to combine the absolute tilt


angle with the relative angle respect to the body,
whichisobtainedfromtherotaryencoders,asshownin
Fig. 3. In Fig. 3 (a), the robot is in a vertical state, all
angles are zero; then the wheel runs a certain angle, as
shown in Fig. 3 (b), it is clear that the angle q2 of the
wheel turns and the absolute tilt angle of it has the
followingrelationship:

q2 = q + q1

(12)

q2 = q + q1

(13)

Where 1 is the relative angle of the robot with the


wheel, and it could be directly obtained from the
incremental encoder. As

q2 is the absolute angle in

respecttothegravity,sotherobotsabsolutespeed v can
begotbydifferential.Tobeclear,theabovequationsare
vectorratherthanscalar.

4.Blendfilter

4.1.RCnetworksforlowpassfilter

Obtains the undamped angular natural frequency of the


robot by calculating is very difficult, but obtains it
throughtestwillbeeasy,asshowninFig.4,invertedto
place the robot, while holding the wheels fixed. Pull the
turningbarawayfromtheequilibriumpositionandthen
let it go, recording all the data from swing to its stop in
thebalanceposition.ImportthedatatoMATLBthenget
the testing drawing, as shown in Fig. 5, the natural
periodofoscillationtisabout1.45s.Soitisconvenientto
calculatethenaturalangularfrequencywithoutdamping
of the robot is approximate 4.33rad/s. This angular
frequency directly determines the designed filter cutoff
frequency.

For the coaxial twowheeled robot, it works in the low


frequency range in most cases, high frequency signals
willcausevibrationsandmaketherobotlosebalance,so
alowpassfilterisnecessary.AfirstorderRCnetworkis
simple, low cost, and easy to implement. More
importantly,ithasverygoodlowfrequencyperformance,
whichthegainisconstant1andthedelayphaseangleis
too small to compensate. For our sensor system, using
onlyafewresistorsandcapacitorswillbeabletoforma
lowpassfilterunitwithgoodeffects,anditisapplicable
toanytypeofvoltageoutputsensors.

For RC networks, there are two equations in our design


areparticularlyimportant,asfollows:

wc = 1 t

(14)

t = RC

(15)

The cutoff frequency is determined equation (14). For


our filter, it is 9 rad/s for the gyro and 6.5rad/s for the
accelerator.

2
o
(a)

o
(b)

Figure3.Relationshipsbetweentheangles

Figure4.Testingthenaturalfrequency

62 International Journal of Advanced Robotic Systems, Vol. 8, No. 2. (2011)

www.intechweb.org
www.intechopen.com

non-damping natural frequency

0.2

sita(rad)

0.1
0
-0.1
-0.2
-0.3
0

10

15

20

25

30

35

40

45

50

time/s

55

Figure5.Oscillationoftherobot

4.2.Kalmanfilterforimpactfilter

Filtering effect of the RC network low pass filter unit is


clear, there is an obvious reduction in the sensor signals
burrandthesignalstationaryhasbeengreatlyimproved,
whichcanbeverifiedfromthemodeltestinginthenext
section. Nevertheless, the sensor signals there are still
neededtofilteroutthefluctuationsinvalue.Forinstance,
with the robot resting on the floor, the accelerometer
output is a combination of rood vibrations and noise,
someofthevibrationvaluescannotbefilteredoutwitha
RC network, which needs to adopt digital filter method,
through the AD collection of digital data after digital
filtering.Inallofthedigitalfilteralgorithms,theKalman
filterhasextensiveandsuccessfulapplication(Ashokaraj,
Silsonetal.2002).TheKalmanfilter(Widjaja,Sheeetal.
2008)canbesuccinctlydescribedasanoptimalrecursive
data processing algorithm for systems corrupted by
noise.Itdoesnothavetosaveallthedatacollected,only
needs a previous state data for calculating, and can
achieve highspeed recursive calculation, which is
significant importance to the inherent unstable robot in
terms of high realtime requirements. As a result, we
choose the Kalman filter to deal with the digital
fluctuations,toestimatetheoptimalvaluesofthesensor
data,theKalmanfiltercorearecalculatedasfollows:

x(k | k -1) = x(k -1| k -1)

(16)

p(k | k -1) = p(k -1| k -1) + q

(17)

kg(k) = p(k | k -1) / (p(k | k -1) + r)

(18)

x(k | k) = x(k | k -1) + kg(k)(z(k) - x(k | k -1)) (19)

p(k | k) = (1- kg(k))p(k | k -1)

(20)

The above equations are based on the following


conditions:thesystemparametersA,BandHare1,and
there is none control variable U; q and r respectively are
process noise and measurement noise covariance, and
assumethattheirvaluesareconstantduringthefiltering
process.
www.intechweb.org
www.intechopen.com

Inallofthefiveequations,(16)and(17)aretheestimated
equations, (18) (19) and (20) are the recursive formulas.
Note that the initial state value and covariance have to
beensetupbeforeitstartstowork.

5.Experimentanddiscussion

Experimental platform we use in the testing is a coaxial


twowheeled selfstabilizing robot, as shown in Fig. 6. It
has a steer bar upon the body and two coaxial
symmetrical arranged driving wheels. The system
structure is simple and compact; it can work in the
remote mode, autonomous mode or operation mode,
usingasarobotplatformorapersonaltransporterwitha
maxim load of 70kg despite its only about 20kg weight.
A TA25 accelerometer is used for the tilt angle
measurement and a TFG160D gyro is used to get the
angular velocity. Two Incremental encoders are used to
measure each wheels rotation relative to the angle of
robot body. A RC networks compose of the low pass
filters;thecutofffrequencyis6.28rad/sforthetiltsensor
and 4.2rad/s for the angular velocity. Backlash (Grasser,
DArrigoetal.2002)effectdoesnotexisthereforthetwo
selected harmonic reducers. The robot can add a variety
of control algorithms while need not change the
hardwarestructure.

Figure6.Selfbalancerobot

5.1.FiltereffectoftheRCnetworks

To verify the effect of RC filter network, obtaining the


sensorsystemdataunderandwithouttheRCfilteristhe
primary problem. Place the robot as shown in Fig. 4, in
the case of static state an impact signal is loaded to the
robotbody,thenrecordallofthedatawithandwithout
theRCfilteruntiltherobotrestoretostaticstate.Import
thedatatoMATLAB,thenthetestingdrawingcanbegot,
asshowninFig.7andFig.8.

Withoutthefilter,thesensorsignalshaveobviousspikes,
asshowninFig.7,eveninthestaticstate,thesensorisno
different either, there are obvious fluctuations in the
output. When the robot is attacked, the sensor system
outputappearsadramaticshockandaseriousdeviation
fromactualvalues.Afterfiltering,asshowninFig.8,the
outputsignalglitcheshavebeensignificantlyreduced,

Li Chaoquan, Gao Xueshan and Li Kejie: Smooth Control the Coaxial Self-Balance Robot Under Impact Disturbances

63

Andfortheangularfilteris:

unfilter of sita and omg

unfilter sita (rad)


unfilter omg(rad/s)

0.5

sita(0 | 0) = 0

(24)

sp(0 | 0) = 0.06

(25)

sr = 0.2,sq = 0.04

(26)

-0.5

Where omg(0 | 0) sita(0 | 0) andaretheoptimalestimate

-1

0.5

1.5

2
time/s

2.5

3.5

Figure7.SignalswithoutRCfilter

filter of the sita and omg

0.6

sita(rad)
omg(rad/s)

0.4
0.2
0
-0.2
-0.4
-0.6
-0.8

0.5

1.5

2
time/s

2.5

3.5

Figure8.SignalsafterRCfiltering

and the filtered image becomes very smooth. When in


staticstate,thereareonlyfewfluctuationsintheoutput.
However, the robot signals output under the shock
remains heavy fluctuations, which performance is very
clear near 0.5s as shown in Fig. 8. It seems that the RC
network for these fluctuations is helpless; they need to
use other filtering methods to deal with, which will be
explainedinthenextsection.

Totallyspeaking,thefirstorderRCfilternetworkshows
satisfactoryperformance.Thevastmajorityoftheimpact
and disturbance signals are filtered, and the filtered
sensorsignalsaresmoothedalot.Signaldistortionisnot
serious,andthephaseangledelayisnotobvious.

initialweight,andtheyareeasytobefixed.

GetthesensordatawhichhasbeenattenuatedbytheRC
network, and load them to the Kalman filter in the
MATLABenvironment.Thenthefilteredsignalcurves,as
showninFig.9andFig.10,canbeaccessed.InFig.9,the
redcurveisthefilteredangularvelocitycurve,whilethe
blueistheinitialone.Inthevicinityof0.5s,asignificant
changeofthecurveisthatthesignalmutationcausedby
theshockdisappears,andthesamephenomenonexistsin
theanglesensorsignalfiltering,asshowninFig.10,this
shows that the designed Kalman filter has played a
filteringeffect,attenuatingtheimpactdisturbance,thisis
whatweexpect.AnotherphenomenonexistsinbothFig.
9 and Fig. 10 is the change of the phase or amplitude in
thefilteredcurve.InFig.9bothhavechangedandsome
morechangesofamplitudeinFig.10,however,thisisnot
a major problem, what we concern is the impact
disturbancecanbefilteredbythefilter,nowouraimhas
been achieved and they can be weaken by adjusting the
valueofcovariancetosolve.

omg

0.2
0
-0.2
-0.4
-0.6
-0.8

0.5

1.5

2
time/s

2.5

3.5

Figure9.Kalmanfiltertestingfortiltanglerate

ItisclearthattheRCnetworkhasanobviouseffectinthe
highfrequency signal attenuation in part A, however,
some impact signals have passed the low pass filter and
they must be filtered. In this section, test for attenuating
the impact signals based the designed Kalman filter will
begiven.Initialvaluesoftheparametersareasfollowing:
Fortheangularvelocityfilter,

omg(0 | 0) = 0.2

(21)

filter of the sita signal

0.2

sitaf
0.1

sita

0
rad

omgf

0.4

5.2.FiltereffectoftheKalmanfilter

filter of the omg signal

0.6

rad/s

-1.5

oftheinitialsensorvalue, op(0 | 0) and op(0 | 0) arethe

-0.1
-0.2

op(0 | 0) = 0.06

or = 0.1, oq = 0.02

(22)

64 International Journal of Advanced Robotic Systems, Vol. 8, No. 2. (2011)

(23)

-0.3

0.5

1.5

2
time/s

2.5

3.5

Figure10.Kalmanfiltertestingfortiltangle
www.intechweb.org
www.intechopen.com

single states feedback controller

1.5

omg(rad/s)

sita(rad)

vlo(m/s)

1
0.5
0
-0.5
-1
-1.5
-2
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5 5.5 6 6.5 7 7.5 8 8.5

time/s

Figure11.Nonsmoothcontroller

tilt angle rate signal in the hybrid controller


omg (rad/s)
f

rad/s

0.5

omg(rad/s)

-0.5
-1
0 0.25 0.5 0.75 1 1.25 1.5 1.75 2 2.25 2.5
time/s

Figure12.Tiltangleratesignalsinthehybridcontroller

0.2

tilt angle signal in the hybrid controller

0.1
rad

5.3.Testingofthehybridcontroller

To contrast the effects with the smooth control method


andthenonsmoothcontrolmethod,twosetsoftestsare
giveninthissection.Thefirstgroupisnotloadedsmooth
controller,andthesecondisconsistedofsmoothcontrol.
In the two trials, the interference sources are both a
rubber hammer. Because it is impossible to accurately
controltheforce,thetwogroupsinterferingsignalenergy
will be different, but we have tried to reduce the errors
betweentheminthecourseoftheexperiment.

Forthefirsttest,thesinglestatesfeedbackgainsaresetas
1.83forthetiltrate,10.96forthetiltangleand9.63for
the robot speed. They are different from the second test;
the reason is that in a nonsmooth controller, the
overlarge feedback gain is a direct reason of the system
instability.

In the second test, the hybrid controller parameters are


set as follows. For the partial states feedback controller,
states feedback gain of the tilt angle, tilt angle rate and
therobotvelocityare17.25,7.25,16.75;andforthePID
controllerthecoefficientsare75forproportional,100for
integraland50fordifferentialconstant.

At the beginning of the first test the robot is in balance,


exertinganinstantaneousdisturbance(intheexperiment,
we use the rubber hammer to hit shift to get the impact
signal.), and then record all the data, import them to
MATLABthengetthetestcurve,asshowninFig.11.

As can be seen from the experimental curves, when the


robot is first under the impact disturbances, it will
generate severe vibrations in 3 seconds department,
especially the tilt angle rate (green curve in Fig. 11).
Meanwhile, the output of angle sensor is severely
distortedduetothevibrations,anddistortionofthedata
willeitherleadtomoreseriousvibrationoftherobot,or
therobotunderthecontrollergraduallystabilized,which
dependsonthestatefeedbackgainsmatrix.Althoughthe
robotwilltendtostabilityintheselectedfeedbackgains,
thevibrationsstillexistwhenitisbasicallyinthebalance
position. For the nonsmooth controller, despite it can
restore to balance position in about 3 seconds after the
impact disturbance, vibrations exist in all of the control
processing; such vibrations are not tolerated for the
twowheeledrobot.

For the second test, the experiments process is the same


asthefirstone,andthetestcurvesareobtainedasshown
inFig.12,Fig.13andFig.14.

sita

sita

-0.1
-0.2
0 0.25 0.5 0.75 1 1.25 1.5 1.75 2 2.25 2.5
time/s

Figure13.Tiltanglesignalsinthehybridcontroller

Itisclearthattherobotcanrestoretobalanceinabout2s,
under the impact disturbance from the test; when the
impact signal is applied on the robot at about 0.1s, as
showninFig.13,thetiltanglehasasignificantmutation,
the mutation signal is not really the point of the angle
signal,buttheaccelerationsensorsignalastheimpactof
thedisturbancecausedbytheinterferenceoutput,needs
to be filtered or smoothed. The red curve, as shown in
Fig.13,showsthattheKalmanfilteronasignalthrough
the RC network has a smoothing function so that the
system under the impact of disturbances can realize
smoothstablecontrol.

www.intechweb.org
www.intechopen.com

Li Chaoquan, Gao Xueshan and Li Kejie: Smooth Control the Coaxial Self-Balance Robot Under Impact Disturbances

65

The PID speed synchronized control effect, as shown in


Fig.14,showsgoodspeedtrackingperformanceanalysis
of the data by more than three hundreds groups, the
speeddeviationofalgebraandonly0.037526m/s,thiscan
be seen from Fig. 15. The maxim speed error occurs at
about 0.35s, and the value of it is approximately 0.07. In
other sessions, error of plus or minus 0.03m/s or less,
walk straight for two robots, the control precision can
satisfy such requirements, after all, the ground situation
in the case of inconsistencies do the complete wheel
speedconsensusishardlyrealized.

velocity of x and y in hybrid controller

0.6

m/s

0.4

0.2
0

-0.2
0 0.25 0.5 0.75 1 1.25 1.5 1.75 2 2.25 2.5
time/s

Figure14.Twowheelspeedofhybridcontroller

velocity error of x and y

0.08

error

0.06

m/s

0.04
0.02
0
-0.02
-0.04

0.25 0.5 0.75

1.25 1.5 1.75


time/s

2.25 2.5

Figure15.Velocityerrorsofthetwowheels

7.Conclusion

A smooth control method for the twowheeled


selfbalancerobotunderimpactdisturbancesisproposed
in this paper, and implementing of it is presented.
Undamped frequency of the robot is researched and the
cutoff frequency of the filters is got. A dual closedloop
controller based on partial states feedback and PID is
then established, as well as a filter combined with RC
networkandKalmanfilter.Theblendcontrolleriseasyto
implementandcanachieveboththespeedofthewheels
coordinated control, and the impact disturbance signals
can be maximally eliminated for a smooth control
performance. From the experiments, the smooth control
method is feasible and effective. Although the

66 International Journal of Advanced Robotic Systems, Vol. 8, No. 2. (2011)

establishmentofthestatespacemodeldoesnotconsider
turning movement, the robot can achieve turning
movementbychangingthespeedoftwowheels.

8.Acknowledgment

This work was supported by National Hitech Research


and Development Program of China (Grant No.
2008AA04Z208),andNationalNatureScienceFoundation
ofChina(GrantNo.60975070).

9.References

[1] Ahmad,S.,M.O.Tokbi,etal.(2009).RejectionofYaw
Disturbance in a TwoWheeled Wheelchair System.
2009 Third Asia International Conference on
Modelling&Simulation,Vols1and2:454459776.
[2] Andary,S.,A.Chemori,etal.(2008).Stablelimitcycle
generation for underactuated mechanical systems,
application: Inertia wheel inverted pendulum.
Intelligent Robots and Systems, 2008. IROS 2008.
IEEE/RSJInternationalConferenceon.
[3] Anderson.,D.P.(2007).nBot.from
http://www.geology.smu.edu/~dpawww/robo/nbot/,
[200771].
[4] Ashokaraj,I.,P.Silson,etal.(2002).Applicationofan
extended Kalman filter to multiple low cost
navigationsensorsinwheeledmobilerobots.Sensors,
2002.ProceedingsofIEEE.
[5] Butler,L.J.andG.Bright(2008).Feedbackcontrolofa
selfbalancing materials handling robot. 2008 10th
International Conference on Control, Automation,
RoboticsandVision(ICARCV2008),1720Dec.2008,
Piscataway,NJ,USA,IEEE.
[6] Chen, X. (2003). Modeling random gyro drift by time
series neural networks and by traditional method.
Neural Networks and Signal Processing, 2003.
Proceedingsofthe2003InternationalConferenceon.
[7] Gans,N.R.andS.A.Hutchinson(2006).VisualServo
Velocity and Pose Control of a Wheeled Inverted
Pendulum through PartialFeedback Linearization.
Intelligent Robots and Systems, 2006 IEEE/RSJ
InternationalConferenceon.
[8] Grasser, F., A.DArrigo, et al. (2002).JOE:A mobile,
invertedpendulum.IEEETransactionsonIndustrial
Electronics49(1):107114.
[9] Huang, J.A.,Z. H. Guan, et al. (2010). SlidingMode
Velocity
Control
of
MobileWheeled
InvertedPendulum Systems. Ieee Transactions on
Robotics26(4):750758.
[10] Imamura, R., T. Takei, et al. (2008). Sensor drift
compensation and control of a wheeled inverted
pendulum mobile robot. Advanced Motion Control,
2008.AMC08.10thIEEEInternationalWorkshopon.
[11] Pathak, K., J. Franch, et al. (2005). Velocity and
positioncontrolofawheeledinvertedpendulumby

www.intechweb.org
www.intechopen.com

partial feedback linearization. Ieee Transactions on


Robotics21(3):505513.
[12] RongJong, W. and C. LiJung (2006). Adaptive
stabilizing and tracking control for a nonlinear
invertedpendulum system via slidingmode
technique. Industrial Electronics, IEEE Transactions
on53(2):674692.
[13] Shiroma,N.,O.Matsumoto,etal.(1996).Cooperative
behaviorofawheeledinvertedpendulumforobject
transportation. Intelligent Robots and Systems 96,
IROS 96, Proceedings of the 1996 IEEE/RSJ
InternationalConferenceon.
[14] Widjaja,F.,C.Y.Shee,etal.(2008).Kalmanfiltering
of accelerometer and electromyography (EMG) data
in pathological tremor sensing system. Robotics and
Automation, 2008. ICRA 2008. IEEE International
Conferenceon.
[15] Zhou, J., W. Wu, et al. (2004). The application of
disturbance observer in twowheeled mobile robot.
2004 Ieee Conference on Robotics, Automation and
Mechatronics,Vols1and2:1711741202.

www.intechweb.org
www.intechopen.com

Li Chaoquan, Gao Xueshan and Li Kejie: Smooth Control the Coaxial Self-Balance Robot Under Impact Disturbances

67