Fahmizal 2019

Download as pdf or txt
Download as pdf or txt
You are on page 1of 6

2019 International Conference on Advanced Mechatronics, Intelligent Manufacture and Industrial Automation (ICAMIMIA)

Heading Control on Differential Drive Wheeled


Mobile Robot with Odometry for Tracking Problem
Fahmizal Angga Priyatmoko Esa Apriaskar Afrizal Mayub
Department of Electrical Department of Electrical Department of Electrical Graduate School of Science
Engineering and Informatics Engineering and Informatics Engineering Education
Vocational College, Vocational College, Universitas Negeri Semarang University of Bengkulu
Universitas Gadjah Mada Universitas Gadjah Mada Semarang, Indonesia Bengkulu, Indonesia
Yogyakarta, Indonesia Yogyakarta, Indonesia [email protected] [email protected]
[email protected] [email protected]

Abstract—This paper describes the process of designing study uses the robust controller method that can provide better
odometry and heading controls from a differential steering stability against the uncertainty which might occur. Has a
wheeled mobile robot (DSWMR). The odometry system aims to different viewpoint, [6] involves image processing to detect
estimate the position relative to the initial position of the robot lines to accomplish the trajectory tracking mission. The
to estimate changes in position from time to time in the camera sensor here performs as a motion sensor used in
trajectory tracking process. The problem that often arises in the odometry techniques. The use of cameras and the addition of
tracking problem is the heading error that can be caused by a fuzzy logic is proven to help the robot can follow the line and
slip on the robot wheel or an irregularity between the speed of
reach the coordinates of the expected destination.
the DC motor on the robot wheel. Heading errors in DSWR can
be obtained with the help of a rotary encoder located on a DC In determining the system of movement, the robot can use
motor. This work applied PID control to obtain the heading two types of media; they are outside and inside. Examples of
error close to 0 degrees on the odometry system for trajectory the use of external media are lines and walls [7]. However, the
tracking. It works by controlling the rotating speed of each DC use of media from outside is less efficient. The robot should
motor on the robot wheel. The results of the PID control be able to determine the direction of movement from within
parameters implemented on the DSWMR were obtained from the robot itself. The sensor that is commonly used to obtain
the results of tuning experiments. position data from a robot is a rotary encoder. Data from this
sensor will be included in the calculation of odometry to
Keywords—DSWMR, heading control, tracking problem
produce the relative position of the robot [8]. The odometry
I. INTRODUCTION method has been widely used for the completion of a robot in
the process of carrying out a tracking. A trajectory tracking is
The rapid development of science has had a considerable a method for determining the movement pattern of a robot
impact on human life to learn and develop the technology. One from the starting point to the end point. There are two types of
of them is robotics technology, where more and more robot algorithms for trajectory tracking, namely off-line path
innovations are created both in terms of saving energy sources trajectory and on-line trajectory [9].
and time efficiency. In modern industry, robots have taken
over the positions of workers in factories. Both in In this study, we made a mobile robot with a differential
manufacturing and process industries, robots tend to have drive driver that can reach the desired target position. Robots
become the main drivers of the industry. The main reason for with this type are usually used in modern industries to move
using robots is because robots can be ideal workers with high goods from one place to another. The mobile robot uses
levels of accuracy and efficiency, and more importantly, odometry technique by utilizing a rotary encoder to detect the
operating costs tend to be low for large-scale production [1]. movement of the robot. In contrast to research [4]–[6] which
looks at the performance of the results of tracking from the
The more agile development of the world of robotics position generated by the robot, this study focuses on
makes researchers and engineers motivated to create a robot evaluating the performance of heading control on a mobile
that can support the needs of the industrial world. Robots that robot. PID control is used with several variations to see
can move following the predefined path accurately are one differences in performance.
example of applications that are useful in industrial society
[2]. It is intended that robots should move autonomously This paper is organized as follows. In Part II, the
without the need for operators to increase the effectiveness of methodology in this study was proposed. Part III explains the
the industrial process. This autonomous driving requires the design of DSWMR robot hardware. Section IV discusses
ability of a robot to solve a tracking problem [3]. That is one experiments that show the effectiveness and benefits of the
reason for the importance of researching the tracking problem proposed method. Part V is the conclusion of this study.
in robots.
II. METHODS
Many studies often used a mobile robot as an object in
testing a way to complete a tracking problem. In [4], a two- A. Kinematics of Differential Steering Mobile Robot
wheeled mobile robot resolves this problem by using a
In this paper, the type of steering or control of the
proportional-integral (PI) controller and comparing it with a
movement of the robot used is the differential steering type.
model-predictive controller. In that research, information on
the dynamics model of the mobile robot used is something The geometry and kinematic parameters of the differential
mandatory in supporting the controller's design. [5] also steering shown in Fig. 1. The position and heading of the
T
requires information about the dynamics model of a mobile robot are explained by vector q   xQ , yQ ,  , with
robot to make the robot can follow a particular trajectory. That

978-1-7281-3090—3/19/$31.00 ©2019 IEEE


47
Authorized licensed use limited to: Auckland University of Technology. Downloaded on October 27,2020 at 11:44:07 UTC from IEEE Xplore. Restrictions apply.
 xQ , yQ  indicating the location of point Q (the center of the in calculating the coordinates of the robot position, namely
diameter of the freewheel 𝐷𝑊( ) , the number of encoder
body axis of the robot being moved) and  is the heading of
resolution (resolusienc), and the number of rotary encoder
the robot in the framework of global coordinates (Glcs). l and pulses produced (pulse). To calculate the circumference of
 denote the angular velocity of the left and right wheels. the freewheel (𝐾𝑊( ) ), 𝐷𝑊( ) is multiplied by  as described
r
in (7). When using the axis of the cartesian motion, changes
There are three variables to control  xQ , yQ ,   with only in the position x coordinates (xtempuh) and y coordinates (ytempuh)
two control inputs. Therefore, the system is under-actuated. can be calculated using (8) and (9).
The relationship between the linear velocity of the robot v and KW i  DW i  (7)
its angular velocity ω with the rate of change of position and
heading are explained in (1). pulse x 
xtempuh  KW x  (8)
 xQ  cos  0 resolusienc
    v
 yQ    sin  0    (1) pulse y 
ytempuh  KW y  (9)
    0 1 
  resolusienc
Linear speed and heading robot angle are explained in (2) To find out the direction of the robot heading (  ), the
- (3), current position coordinates (xsaat_ini, ysaat_ini) relative to the

v

r r  l  (2)
movement of the initial position (xawal, y_awal) as presented in
Fig. 2. Then the robot heading can be obtained by (10).
2 Whereas to find the length of distance from the current



r r  l  (3)
position to the initial state can be calculated by (11).
ytempuh (10
  tan 1
2b xtempuh )
where r is the wheel radius, and 2b is the base length of the
(11
wheel, which is the distance between the wheels measured Distance  ( xsaat _ ini  xawal )2  (ysaat _ ini  yawal )2 )
along the axis of the wheel rotation. By substituting (2) and
(3) into (1), (4) – (6) are obtained.

xQ 
r
2
r cos   l cos   (4)

y Q 
r
r sin   l sin   (5)
2



r r  l  (6)
2b


l

Fig. 2. Robot heading calculations on the odometry system

Q Fig. 3. presents changes in coordinates and heading on the


Olcs odometry system over time. The change value consists of
changes in the position of the robot's heading and coordinates
to the robot's global coordinates, where  is the direction of
r the robot heading, and the bearing target (β) is the angle
between the robot's current position and the destination point.
To determine the β value and robot heading error (α) can be
Glcs xQ calculated using (12) and (13). Furthermore, to find out the
Fig. 1. Geometry and kinematic parameters of the differential steering target distance can be calculated using (14).
 ytujuan  ysaat _ ini 
B. Odometry System in Differential Steering Mobile Robot   90  tan1  (12)
 xtujuan  xsaat _ ini 
Odometry is the use of data from the movement of an
actuator to estimate changes in coordinate position over time.     (13)
Odometry is used to calculate the coordinates of location
relative to the initial position [10], [11]. In the wheeled Target  ( xtujuan  xsaat _ ini )2  (ytujuan  ysaat _ ini )2 (14)
odometry system, the sensor used is a rotary encoder to detect
the number of wheel turns. There are three main parameters

48
Authorized licensed use limited to: Auckland University of Technology. Downloaded on October 27,2020 at 11:44:07 UTC from IEEE Xplore. Restrictions apply.
c. To reduce oscillation, add a differential constant by
 dividing the proportional constant, and observe the state
 of the robot system to be stable and more responsive.
 d. If the robot system has been stable, integral control can
be optional to improve the performance of the robot.
However, giving improper integral value can make the
robot system unstable.
e. The value of sampling time also affects the calculation
of PID, especially when using integral and differential
controls.
f. Re-check system performance to get satisfactory results.
III. SYSTEM DESIGN
Fig. 3. Illustration of the position of the robot on the cartesian axis in the
odometry system A. Design of Robot Mechanics and Electronics
The design of the robot mechanics in this study was
C. Digital PID Control and Parameter Tuning designed using two wheels that had a rotary encoder as an
Digital PID control is another form of PID control odometry process counter. Fig. 4 displays the overall
programmed and run using a computer or microcontroller. To appearance of the robot design, while Fig. 5 presents the
be able to implement digital PID on a computer or display of the base and bottom of the robot.
microcontroller, analog PID control design must be changed
to digital form. The mathematical form of the PID control is
in (15).
 1 d 
i 
u(t )  K p e(t )  e(t )dt   d e(t )  (15)
 dt 
With Ki  1 and Kd   d , then the integral and
i
differential forms can be written in discrete form as in (16) -
(17).
t k

 e(t) dt  T  e(k)
0 0
(16)
Fig. 4. Overall robot design
de(t) e  e k 1
 k (17)
dt T
Thus, it obtains the form of a discrete PID control, as stated
in (18).
k
1
u ( k )  K p e k  K iT  e k  K d ( e k  e k 1 ) (18)
0 T
where Kp is a proportional constant, Ki is an integral Fig. 5. The mechanical design of the robot.
constant, Kd is a differential constant, ek is an error value,
The robot's electronic system uses an Arduino Mega,
and the ek 1 is the value of the previous error and Ts is the
which is placed on the top of the robot. The wheel rotary
sampling time. encoder sensor is used to monitor direction and number of
Tuning experiment is a process carried out to obtain DC motor rotation of the robot. The electronic system
optimal control results through an experiment. The essence diagram block configuration of the robot as a whole is
of tuning experiment is to determine the value of three presented in Fig. 6. Furthermore, the results of the printed
parameters contained in the PID control, namely proportional circuit board (PCB) design of this robot are shown in Fig. 7.
constant (Kp), integral constant (Ki) and differential constant
(Kd). Several methods can help in tuning PID control Wireless Telemetry
Telemetry 433Mhz
parameters with an experiment such as the Ziegler-Nichols Rotary Encoder
433Mhz + Laptop

method, the Cohen-Coon method, and the empirical method.


Motor 1
In this study, the PID control was tuned using empirical
methods based on the effect of each control on the system.
The steps for determining the parameters Kp, Ki, and Kd is Driver Motor
Arduino Mega
LCD 16x2
Motor 2
adopted from [12], as follows:
a. The first step is to use proportional control first, ignore
the integral constant and the derivative by giving them
Rotary Encoder
zero values Tombol
b. Add the maximum proportional constant until the state is
stable but the robot is still oscillating. Fig. 6. Schematic diagram of omni robot electronic devices

49
Authorized licensed use limited to: Auckland University of Technology. Downloaded on October 27,2020 at 11:44:07 UTC from IEEE Xplore. Restrictions apply.
Fig. 7. PCB design of the robot

Fig. 10. The odometry testing.


B. PID Control Design
When the robot is running, slip problems that occur on the The bearing (β) target value can be obtained from the
robot wheels appear, causing the direction of the robot to be reading of the rotary encoder found on the left and right
an incorrect or heading error. If the value of the heading error wheels of the robot concerning (12-14). The error position
is less than zero, then the robot turns left and vice versa if the value on the y-axis is denoted by ey, and on the x-axis, it is
value of the heading error is positive then the robot turns right denoted by ex as presented in Fig. 11.
as in the illustration in Fig. 8. Y Yrobot

Xrobot

Castor
wheel

Xc c
,Y
Reference
Castor Trajectory
ey
wheel

r

Fig. 8. Illustration of robot heading. ex

The difference in the value of heading robot with setpoint


value is an error as in (19). Setpoint (SP) is a desired value xQ xr
X

or reference, present value (PV) is the value of sensor


readings or inputs that are fed back by sensors to the system. Fig. 11. The illustration of robot heading error.
Every time the program looping, the rotary encoder updates
the error data and the previous error stored on another The purpose of the PID control in this system is driving
variable named last_error. The error and last_error are then the robot to be able to move straight. It can be noticed from
processed with digital PID controls as in (18). After the PID the value of the robot heading error, which is 0o. Before using
value is obtained, it will be added or subtracted by the PWM PID, the test was carried out by giving a PWM value of 80 on
Base value as presented in Fig. 9. the right motor and left motor. Fig. 12. shows heading data
𝑒𝑟𝑟𝑜𝑟 = 𝑆𝑃 − 𝑃𝑉 (19) before the robot is tested using a PID controller.
Base PWM Differential Drive Wheeled Mobile
Robot with Odometry
Motor DC
+ Left Wheel
+
Set Point
SP
Jarak error PID Driver
+ _ Kontroler PID
Control Motor
- Motor DC
PV + Right
PV Wheel
Base PWM

Rotary Encoder
Calculate Heading Error

Fig. 9. PID control block diagram

IV. RESULTS AND DISCUSSIONS


This work conducted the test by giving nine target points
of odometry coordinates (0.40), (20.39), (38.60), (39.81),
(58.80), (60.40), (39.0) and (20.0) for the robot in units of
centimeter distance as shown in Fig. 10 uses graphical user
interface (GUI) from Processing IDE. Fig. 12. Heading robot data without PID control.

50
Authorized licensed use limited to: Auckland University of Technology. Downloaded on October 27,2020 at 11:44:07 UTC from IEEE Xplore. Restrictions apply.
The graph above shows that the value of the robot heading
is always negative during the test. It means that the robot
tends to turn left. Table III addresses the results of the heading
robot value after adding the proportional component that
forms the PID controller. The experiment is carried out by
running a robot that adjusts the straight track reference as far
as 100 cm.
TABLE III Kp = 3.0 ; Kd = 2.5 Kp = 3.0 ; Kd = 3.0
THE RESULTS OF THE PROPORTIONAL CONTROL TEST

The data shown in table IV explains that the addition of


Kd makes the oscillations smaller, but still not able to get a
system output that is close to the expected setpoint.
Therefore, Integral control is applied to resolve the problem.
The results of testing the PID control are displayed in Table
V.
TABEL V
Kp = 6.0 Kp = 5.0 THE RESULTS OF THE PROPORTIONAL, INTEGRAL AND DERIVATIVE
CONTROL TEST

PID
System response
Paramater

Kp
(3.0)
Kp = 4.0 Kp = 3.0
Kd
(2.5)

Ki
(0.0001)

Kp = 2.5 Kp = 2.0

From the results of the proportional control test, the value Kp


(3.0)
of Kp 3.0 produces a heading value that is close to the setpoint
(0o). There are still oscillations, but this is better than the Kd
other Kp values. To improve system response for the better, (2.5)
derivative control is necessary. The results of the proportional
and derivative control tests are shown in Table IV. Ki
(0.0003)
TABEL IV
THE RESULTS OF THE PROPORTIONAL AND DERIVATIVE CONTROL TEST

Kp
(3.0

Kd
(2.5)
Kp = 3.0 ; Kd = 0.5 Kp = 3.0 ; Kd = 1.0
Ki
(0.0005)

From the results of the PID control test, it can be inferred


that the bigger the value of Kp produces a bigger oscillation.
Kp = 3.0 ; Kd = 1.5 Kp = 3.0 ; Kd = 2.0 Choosing the smaller gain for Kp will be safer to the

51
Authorized licensed use limited to: Auckland University of Technology. Downloaded on October 27,2020 at 11:44:07 UTC from IEEE Xplore. Restrictions apply.
navigation system of the robot. Based on the experiment, and Department of Electrical Engineering, Universitas Negeri
Kp=3.0, Kd=2.5 and Ki=0.0003 is the most optimal option of Semarang, for encouraging this work.
trial-error tuning experiment. Even it seems that the system
still has an error steady state, but it is small enough to be REFERENCES
neglected. It does not look having bad performance through [1] B. Curuklu, G. Dodig-Crnkovic, and B. Akan, “Towards industrial
robots with human-like moral responsibilities,” in 2010 5th
direct eye observation as depicted in Fig.13. ACM/IEEE International Conference on Human-Robot Interaction
(HRI), 2010, pp. 85–86.
[2] F. Kaiser, S. Islam, W. Imran, K. H. Khan, and K. M. A. Islam, “Line
follower robot: Fabrication and accuracy measurement by data
acquisition,” in 2014 International Conference on Electrical
Engineering and Information & Communication Technology, 2014,
pp. 1–6.
[3] R. V. Soans, Ranjith, A. Hegde, C. Singh, and A. Kumar, “Object
tracking robot using adaptive color thresholding,” in 2017 2nd
International Conference on Communication and Electronics Systems
(ICCES), 2017, pp. 790–793.
[4] M. Manel and B. Faouzi, “Trajectory tracking of two wheeled mobile
robot,” in 2015 6th International Conference on Modeling,
Simulation, and Applied Optimization (ICMSAO), 2015, pp. 1–6.
[5] J. Osusky and J. Ciganek, “Trajectory tracking robust control for two
wheels robot,” in 2018 Cybernetics & Informatics (K&I), 2018, pp.
1–4.
[6] N. T. Truc, E.-H. Sun, Y.-M. Kim, and Y.-T. Kim, “Navigation
method using fuzzy line tracking for the transportation robot,” in 2014
Joint 7th International Conference on Soft Computing and Intelligent
Systems (SCIS) and 15th International Symposium on Advanced
Intelligent Systems (ISIS), 2014, pp. 819–822.
Fig. 13. Experimental result of robot heading.
[7] F. Fahmizal, M. Arrofiq, and A. Mayub, “Identifikasi Pemodelan
Matematis Robot Wall Following,” J. Nas. Tek. Elektro dan Teknol.
V. CONCLUSION Inf., vol. 7, no. 1, Mar. 2018.
[8] K. Ohno, T. Tsubouchi, B. Shigematsu, S. Maeyama, and S. Yuta,
This paper presents the performance evaluation of heading
“Outdoor navigation of a mobile robot between buildings based on
control on differential drive wheeled mobile robot with DGPS and odometry data fusion,” in 2003 IEEE International
odometry for tracking problem. The test conducted in this Conference on Robotics and Automation (Cat. No.03CH37422),
paper used several target points to see the overall performance 2003, pp. 1978–1984.
of the system. The results obtained are that PID controller is [9] J.-P. Laumond, S. Sekhavat, and F. Lamiraux, “Guidelines in
qualified to conduct heading control for the robot. The PID nonholonomic motion planning for mobile robots,” in Robot motion
planning and control, Berlin: Springer, 1998, pp. 1–53.
control parameters obtained from the tuning experiment are [10] Kok Seng Chong and L. Kleeman, “Accurate odometry and error
Kp = 3.0, Ki = 0.0003 and Kd = 2.5. The test results of this modelling for a mobile robot,” in Proceedings of International
PID control have also published on the YouTube video Conference on Robotics and Automation, 1997, vol. 4, pp. 2783–2788.
channel at the address [13]. [11] J. Borenstein and Liqiang Feng, “Measurement and correction of
systematic odometry errors in mobile robots,” IEEE Trans. Robot.
ACKNOWLEDGMENT Autom., vol. 12, no. 6, pp. 869–880, 1996.
[12] K. Ogata, Modern Control Engineering, 5th ed. New Jersey: Prentice
We firmly thank Department of Electrical and Informatics Hall, 2010.
Engineering, Vocational College, Universitas Gadjah Mada [13]Video implementation [Online]. Available on :
https://youtu.be/1vndGHznzyU

52
Authorized licensed use limited to: Auckland University of Technology. Downloaded on October 27,2020 at 11:44:07 UTC from IEEE Xplore. Restrictions apply.

You might also like