04338825

You might also like

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

Design of DSP-based Open Control System

for Industrial Robot



Bo You, Dongjie Li and Suju Liu
College of Automation
Harbin University of Science and Technology
Harbin, Heilongjiang Province, China
youbo@hrbust.edu.cn

Abstract - The closed structure of control system limits the
flexibility and expandability of industrial robot. In order to
improve the openess and transplant ability of the industrial robot
control system, the DSP-based open industrial robotic control
system is designed. The hardware and software are both designed
in modular structure, which makes the system easy to maintain,
expand and transplant. The fuzzy self-adjusting PID control &
velocity and acceleration feedforward strategy is employed to
improve the systems dynamic performance and the control
precision. The dynamic link library (DLL) is developed with
Microsoft Visual C++6.0 for the convenience of second
development. Simulation shows the validity of the strategy
adopted. The actual running proves that the system has good
operating and dynamic performance, high control precision and
perfect programming function, so it can meet the actual
operating requirements completely.

Index Terms - industrial robot, open structure, motion control,
DSP, velocity and acceleration feedforward

I. INTRODUCTION
Robot control system is the main part of robot information
processing and control, whether the design is good or not will
have a great impact on the robotic systems behavior and
performances [1] [2]. Currently, a great many control systems
of industrial robots are designed based on their own
independent structure, employing the specific robotic
language and operating system, some of which even adopts
dedicated computers [3]. For example, the commercial
MOTOMAN robots do not have open controllers, it is
difficult for clients to modify and expand the functions [4].
PUMA robots adopt PDP-11 as the master computer and VAL
as specific robotic language [5]. The closed structure limits
the flexibility and expandability of robotic control system, and
makes the system have bad transplant performance [6]. Thus,
developing robotic control system with open structure has
become a hot focus in the robotic study at home and abroad.
Based on the ideas above, the DSP-based open industrial
robotic control system is designed.
The control system utilizes Industrial Personal Computer
(IPC) or compatible computers as hardware platform and
Windows as software platform and adopts open structure. The
powerful operation function of DSP makes it more and more
widely used in motion control [7]. It integrates a strong digital
signal processing ability as well as all the inputs, outputs, A/D
converting, occurrence capturing and other peripheral
equipment that motor control system requires; also it has the
function of producing PWM pulse [8]. So the motion
controller of this control system is designed with DSP as the
microprocessor. The motion control chip TMS320LF2407A is
adopted which is produced by TI Corp. The motion controller
developed in this paper has multi-motion control mode, which
meets the requirement of robots variable control. In order to
improve the dynamic performance and the control precision,
the fuzzy self-adjusting PID control & velocity and
acceleration feedforward strategy is adopted. The users
interface (the upper-computer software) is designed with
Microsoft Visual C++6.0 and the dynamic link library (DLL)
is developed for the convenience of second development and
for the improvement of systems openness.
II. MOTION CONTROLLER DESIGN
A. Overall Design of the Controller
Though TMS320LF2407A is a motion control application
oriented digital signal processor, on which there is various
primary function modules required for the motor control
application. But one piece of TMS320LF2407A can only
receive two groups of encoder signals, that means only two
axes can be controlled. For multi-axes control, one piece is
apparently not enough. If multi-DSP are adopted, obviously
they will bring trouble to work with other devices. Because
the time sequence of DSP does not match with that of IPCs
bus, multi-DSP can make a big mess, making the data
communication not reliable any more. If multi-DSP request to
communicate with the upper computer at the same time, there
will be confliction between address bus and data bus. LM628
can be used to fulfill the feedback regulation of the motion
control for it has the feedback signal processing unit.
Therefore, using one piece of DSP combined with LM628 can
realize multi-motor control without mess of time sequence. In
the controller, DSP plays the part of manager and LM628 is
the executor, so expanding to multi-axis can become very
convenient and DSP will not have an influence on the system
because of heavy overhead. Its structure diagram is shown in
Fig. 1. DSP is responsible for receiving and identifying the
control commands and data from IPC and makes some
necessary processing, and then these data are sent to LM628
to control the servo motors. At the same time, DSP collects
the relevant data report during the motors motion to transmit
to IPC for analysis and vision processing, and monitor the
working condition of the system automatically in case that
1-4244-1531-4/07/$25.00 2007 IEEE. 1585
Proceedings of the IEEE
International Conference on Automation and Logistics
August 18 - 21, 2007, Jinan, China
I
P
C
Dual-
port
RAM
DSP
Step
motor
Signal
Modulation
LM628
D/A
Conver-
sion
Power
Amplifi-
cation
Servo
motor
PWM Pulse
External signal input
Feedback Signals of Encoder
Direction Signal

Fig. 1Diagram of the motion controller
there will be errors or something might be out of control.
Furthermore, DSP utilizing PWM pulse controls the robot
hands open or close, which is controlled by step motor. Fig. 2
is the picture of the controller.
The motion controller developed in this paper has five
motion control modes, they are position tracking mode,
velocity tracking mode, step curve mode, S curve mode and
electronic gear mode. Electronic gear mode is the one that
guarantees each axis can work synchronously and its structure
block diagram is shown as Fig. 3, from which the transfer
function can be seen as (1).
) ( ) ( ) ( 1
) ( ) ( ) (
) (
s G s G s B
s G s G s B
N
M
s G
S M
S M
+
= (1)
Where I(S) is the driving axis encoder pulse input, O(s) is the
driven axis servo motor encoder input; M and N are the
coefficients of frequency multiplication; B(s) is the feedback
control function; is the transfer function of sensors and
is the transfer function of servo drivers. The gear ratio
can be altered by changing the values of M and N. From (1) it
can be obtained that, when changing the values of M and N,
only the proportionality coefficient of input and output is
altered, while the system open gain is not affected, that is,
proportional gearing is realized and system stability is
guaranteed as well. Meanwhile, system precision wont
decline because of the fall of gear ratio, for the adoption of
) ( G
S
s
) (s G
M

Fig. 2Picture of the motion controller
M 1/N B(S) G
M
(S) G
S
(S)
O(S)
I(S)
N
+
_

Fig. 3 Transfer function of the electronic gear mode
frequency multiplication. When the controller is working,
electronic mode gearing at a non-constant speed ratio can be
realized if the values of M and N can be changed real time.
Other control modes wont be discussed further here because
of the lack of space.
III. SYSTEM HARDWARE DESIGN
The design of robot control system adopts the modular
architecture. The whole hardware system is based on IPC,
which offers hardware platform for the robot control; the
motion of the robots four joints is controlled by DSP motion
controller. The control system hardware structure is shown in
Fig. 4. The system controls the working of servo motors of
each joint through the four-axle motion controller developed
in this paper. If the IPC is equipped with internet card, the
robot can have the Internet function. It can receive all the
commands and information from the remote operator, and
feedback its working condition to the operator, which realizes
the teleoperation function.
A. Communication between DSP and IPC
There is a large quality of data that needs to be trans-
mitted between DSP and PC with high speed. In order to fit in
with the communication between DSP and IPC, double-port
RAM plan is adopted for ISA/PCI is parallel transmission bus.
As a kind of special RAM chip, dual-port RAM is widely used
in high-speed data collection system. In this paper, dual-port
RAM chip IDT7133 produced by American IDT Corp. is
used. It is a 2K16bit high-speed static double-port RAM, and
its access speed is 25ns (civilian use). IDT7133 is commonly
Interface Card
IPC
M
o
t
i
o
n

C
o
n
t
r
o
l
l
e
r
S
e
r
v
o

D
r
i
v
e
r
S
e
r
v
o

M
o
t
o
r
Industrial Robot

Fig. 4 System hardware structure
1586
used in the field of digital signal processing application [9]. It
has two rows of independent port, and each has a separate set
of data bus, address bus and control bus, enabling the two
ports to access any unit in the memory independently. But
when the two ports access the same unit in the memory
simultaneously, there will be access conflict. Then the priority
will be decided by the internal arbitration logic. The priority
will be notified to DSP or the IPC by the BUSY signal, as
which is shown in Fig. 5. A0~A15 and D0~D15 are the
address lines and data lines of TMS320LF2407A, and
SA0~SA15 and SD0~SD15 are the address lines and data
lines of ISA/PCI bus. The chip gating pins CEL and CER are
obtained by address decoding of DSP and IPC separately.
BUSY
L
and BUSY
R
are connected to the READY pin of IPC
and TSM320LF2407A separately after decoding. When any
of the READY pin is set to low level, the associated
equipment will wait for an access cycle until the BUSY signal
is high level, which means the dual-port RAM is not busy any
more and the associated equipment can access the memory. So
the correctness and reliability transmission of data are
guaranteed.
accomplished by servo motor driver. The current loop is used
to enhance the system dynamic response performance and
strengthen system capacity of resisting disturbance; velocity
loop is adopted to adjust the rotation speed of servo motor.
PID control is one of the first early developed control
strategies. Because of its simple algorithm, good robustness
and high reliability, it has been widely used in process control
and motion control, especially the deterministic system from
which accurate mathematic model can be built [10]. However,
actual industrial process is usually non-linear, the time
variation is uncertain, and it is hard for this kind of process to
build an accurate mathematical model [11]. So applying the
PID regulation couldnt get ideal control results. In the actual
manufacturing process, common PID parameters adjustment is
usually complicated, of which the parameters are often badly
turned, so its performance is not good enough and the
adaptability to operating condition is bad [12]. Aiming at the
limitation that PID adjustment is not easy to use, we adopt the
fuzzy self-adjusting PID control strategy which is system
independent, has good control results, small overshoot, short
setting time, and a strong adaptability to time variation and
disturbance. Fig. 6 shows the simulation results of common
PID and fuzzy self-adjusting PID, from which we can see that
the overshoot of fuzzy self-adjusting PID reduces by 20%
than that of common PID, while the setting time is only half as
that of common PID. The system close loop regulation
principle block diagram is shown as Fig. 7, which consists of
the position PID, fuzzy self-adjusting regulation structure and
velocity and acceleration feedforward. It is carried out by the
bottom programs of motion controller and can realize precise
positioning, return home and so on. The output saturation
control can guarantee that output voltage wont get in excess
of the setting range. For the servo motors of joint 1, 2, and 4
of the robot, the target position is motor rotation angleu ; for
joint 3, its target location is displacement d.
B. (xternal Signals Processing
Interrupt plus inquiry mode is used to process the external
signals, which means these signal will be sent to GAL for
decoding after optical coupling isolation, and then will be
connected with interrupt pins of DSP. Meantime the signals
that have been isolated are connected with I/O ports of DSP.
When a certain axis moves to limit switch or gives
corresponding signals, the external interrupt signal of DSP
will be triggered, then the DSP can decide which axis is at the
limit. External signals that need to be processed include all the
hardware interrupt introduced from the pins, namely the limit
interrupt signal, warning signal, clear signal, reset signal and
SERVO signal of servo motors of each axis.
The formula for position loop is: IV. FUZZY SELF-ADJUSTING PID CONTROL &
VELOCITY AND ACCELERATION FEEDFORWARD STRATEGY
i actual i et t i
P P E ) ( ) (
arg
= (2)
In order to realize precise and stable control of the
system, typical three-loop regulation is employed. The
functions of velocity regulator and current regulator are
af t vf t i i d i i p i i
K A K V K E K E E K E U + + E + + =

256 / ) ( ) (
1
(3)

Dual-port RAM
IDT7133
A0
L
-A9
L
D0
L
-D15
L
BUSY
L
BUSY
R
A0
R
-A9
R
D0
R
-D15
R
CE
L
CE
R
R\W
L
R\W
R A0-A9 AEN
IOR
IOW
D0-D15
A0-A9
DSP
TMS320LF2407
A0-A9
D0-D15
GAL20V8
Address encoding Address encoding
R\W
R
A0-A15 DS IS PS
PCI
bus
of
IPC

Fig. 6 Simulation results of PID and fuzzy self- adjusting PID Fig. 5 Communication interface between IPC and DSP
1587
General PID
adjust ment
Fuzzy
reasioning
Out put
sat urat ion
cont rol
D/A
conversion
Servo
driver
Kp A Ki A Kd A
1-z
-1
1-2z
-1
-z
-2
Target velocit y
K
vf
K
af
Target
accelerat ion
Fefuzzicat ion
+
+
+
St at ic error
compensat ion
+
Feedback
Velocit y
close-loop
cont rol
Current
close-loop
cont rol
0 0
/ d u
i i
d / u
+
_
Fuzzi-
cation
e ec
K
1
K
2
d / u
E
dE
Execut ive
mechanism

Fig. 7 Closed loop adjusting principle of the system

Where E
i
is the position error and P
target
is the actual position
of the ith sampling time; U
i
is the output velocity command
voltage of position loop; is the accumulated errors of the
ith sampling time; V
i
E E
t
is the current velocity; A
t
is current target
acceleration; K
vf
is velocity feedforward gain; K
af
is the
acceleration feedforward gain; K
p
, K
i
and K
d
are the gain of
proportion, integral and differential respectively.
According to the features of proportional, integral and
derivative control function in the PID control strategy, the
self-adjusting requirements for parameters K
p
, K
i
and K
d
in the
control process are as follows (taking the prismatic joint
control process as example):
(1) When
) (d e
is greater, K
p
should be set a little higher
and K
d
a little lower in order to maintain better tracking
performance. Meantime, in order to avoid a big overshoot of
system response, integral function should be limited, usually
K
i
is set zero;
(2) When
) (d e
and
) (d ec
are both medium, K
p
and K
d

are usually set a little lower and K
i
should be an appropriate
value in order obtain small overshoot;
(3) When
) (d e
is smaller, K
p
and K
i
should be set higher;
when
) (d ec
is greater, K
d
should be set lower in order to
obtain better system stability; when ( ) d ec is big, should
be small and when
d
K
) (d ec
is smaller, K
d
should be set higher
in order to increase the capacity of resisting disturbance and
avoid the system oscillation around the presetting value.
In the self-adjusting of PID process, the Maximum
Minimum method was adopted in fuzzy reasoning and the
area center of gravity method was adopted in defuzzification
according to the states of fuzzy control. The fuzzy rules of
parameters adjusting for K
p
, K
i
and K
d
can be obtained
from conventional experience, which have been downloaded
in the DSP.

During the motion of the motors, the control system
finishes fuzzy control adjustment through table looking up
and calculation, then the modify parameters could be looked
out, thus the parameters of PID are adjusted real time through
the following formulas:
p Ci i p p
K E E K K } { 0 + + = (4)
i Ci i i i
K E E K K } { 0 + + = (5)
d Ci i d d
K E E K K } { 0 + + = (6)

V. SYSTEM SOFTWARE DESIGN
The software plays an important role in the control
performance of the system. Considering that the motion
controller already integrates the digital processing chip
TSM320LF2407A, software design is divided into two parts:
upper computer and lower computer, designed with modular
structure, which realizes the intelligence to the most extent.
Aiming at the features that the core chip DSP of the motion
controller has, all the arithmetic involving real time control is
solidified within DSP. The purpose of doing this is that IPC is
in charge of overall plan and the motion controller will carry
out the specific control, which takes care of the real time
control and increases the openness of motion control.
A. Upper Computer Software Design
For upper computer software, Microsoft Visual C++6.0 is
used to develop the DLL functions of communication between
IPC and DSP, which includes the modules of system
parameter regulation, trace export, motion process control and
data receiving, etc. Design of the program is flexible and easy
to transplant. The communication between the controller and
IPC can be achieved by the library functions, so the users can
control the robot without direct operate to the port. The design
of DLL makes the system easy to develop secondly.
B. Lower Computer Software Design
For the lower computer: TMS320LF2407A not only has
abundant hardware resource, but has a powerful command
system, and supports the high level language at the same time.
1588
So during programming, hardware structure and command
system are fully considered and the hybrid programming of
assemble language and C language is employed to make the
system optimal most. The precision of motion control also
needs to be considered as much as possible, so all that
involved real time control like linear interpolation, circular
interpolation, single axis test and multi-axes motion
synchronously and other arithmetic are solidified within DSP.
Following the design idea above, the software of lower
computer is divided into 3 modules: communication module,
servo control module and motion monitor module.
For communication module, two-stage buffer is
employed: the first stage is used to store the data that is being
executed; the second is used to store the data that is being
received. Servo control module mainly fulfills such tasks as
defining position base point, motion mode option, motion
position transmission, motion performance regulation, and on
or off of Servo ON. Interrupt of this module adopts the
interrupt plus inquiry mode, the interrupt flowchart is shown
as Fig.8. This mode makes several interrupt sources share one
DSP external interrupt, which solves the problem that 2407
doesnt have enough external interrupt interface, and increases
the availability of interrupt resource. Monitor module carries
out the detection of the limitation and error and process trace
of the motors working.

Fig. 8 Interrupt flowchart of the software


VI. EXPERIMENTAL RESULTS AND CONCLUSIONS
Based on the system developed, position tracking
performance of the four DOF SCARA robot was tested, the
result is shown as Fig. 9, from which we can see that the
robotic system developed in this paper has a good control
precision and dynamic performance, so it can meet the actual
operating requirement completely.
At present the control system has been applied to the
industrial and educational robots. The actual running shows
that the system has good operating performance, and the
programming function is complete. Furthermore, both
hardware and software design employed modular structure,
which makes the system easy to maintain, expand and
transplant. Adopting of the three-loop servo control arithmetic
of velocity, acceleration feedforward plus fuzzy PID
regulation make the control system have good dynamic
performance and high control precision.
REFERENCES
[1] E. Dumetz, J.-Y. Dieulot, P.-J. Barre, F. Colas, and T. Delplace, Control
of an Industrial Robot Using Acceleration Feedback, Journal of
Intelligent and Robotic Systems: Theory and Applications, vol. 46, no. 2,
2006, pp. 111-128.
[2] A.-S. Zaki, Control of Industrial Robot Joint Flexibility Using
Acceleration Feedback, Proceedings of the American Society of
Mechanical Engineers (ASME) Dynamic Systems and Control Division
2005, pp.1469-1474, 2005.
[3] V. Poppeova, J. Uricek, R. Zahoransky, T. Galbavy, K. Muller, and S.
Schmeisser, The Development of Robot Control, Robot Simulation and
Digital Image Processing, Komunikacie, vol. 7, no. 1, pp. 41-46, 2005.
[4] J. Cui, A. Song, and W. Huang, Research on Kinematics Modelling of
MOTOMAN-SV3X Robot in Teleoperate System, Journal of Southeast
University (Natural Science Edition), vol. 33, no. 4, pp. 424-429, July,
2003.
[5] Y. Chen, J. Zhang, C. Yang, and B. Niu, The Workspace Mapping with
Deficient-DOF Space for the PUMA 560 Robot and its Exoskeleton Arm
by Using Orthogonal Experiment Design Method, vol. 23, no. 4, pp.
478-487, August, 2007.
[6] S. Fischmeister, M. Holzmann, and G. Menkhaus, Model-based
Development of Robotic Control Systems, Proceedings of ICCC 2004 -
Second IEEE International Conference on Computational Cybernetics,
pp. 13-18, 2004.
[7] A. Onea, V. Horga, and M. Ratoi, Software Tools for DSP Motion
control Applications, WSEAS Transactions on Information Science and
Applications, vol. 2, no. 12, pp. 2251-2258, December, 2005.
400 800 1200 1600 2000
0
1
2
-1
-2
t(ms)

Fig. 9 Position error of the robot
E
r
r
o
r

(
m
m
)

1589
[8] H. Liu, Structure, Principle and Application of TMS320LF240xDSP,
Beijing University of Aeronautics Press, 2002, pp. 1-22.
[9] X. Yan and J. Ma, Study of Data Share in Multiprocessor System Based
on DPRAM-IDT7133, Journal of Electron Devices, vol. 28, no. 4, pp.
863-866, December, 2005.
[10] H.-B. Kazemian, Developments of Fuzzy PID Controllers, Expert
Systems, vol. 22, no. 5, pp. 254-264, November 2005.
[11] S. Tungpataratanawong, K. Ohishi and T. Miyazaki, High Performance
Robust Motion Control of Industrial Robot Using Parameter Identification
Based on Resonant Frequency, IECON 2004 - 30th Annual Conference
of IEEE Industrial Electronics Society, vol. 1, pp. 111-116, 2004.
[12] A. Castillo-Tapia, V. Parra-Vega, M.-A. Arteaga-Perez, and J.J. Gudio-
Lau, Tracking of Industrial Robot Manipulators with PID-like Control -
Theory and Experiments, International Conference on Mechatronics,
ICOM 2003, pp. 491-496, 2003.

1590

You might also like