I. INTRODUCTION
The development of present applications focused on
real time control of a technological process must usually
go through whole range of development steps, each of compatibility with MATLAB/Simulink environment.
which demands human resources as well as software
and hardware implementation and testing requirements, Fig. 1. Architecture of a process control by classical way
and by the help of REX Controls
which is very often connected with high cost for
development and longer time. Architecture of a process control by classical way and
If we come from an assumption of requirements for by the help of REX Controls
present systems, it is obvious that they further aim at Another interesting advantage is in very low cost of
more sophisticated and more demanding solutions, described solution opposite to classical solutions with
namely regarding control quality, energetic RT Measurement Card (like dSPACE).
consumption, knowledge of system behaviour and the Third advantage is in possibility of remote or
entire process control as it is. standalone run of WinPAC. In that case is not necessary
An example can be hydraulic systems with clear to have an own control PC with RT card attached to
tendency and a requirement for so called “smart iron
controlled system, but only existing robust WinPAC Graphical designer RexDraw enables its own
system. drawing, proposal and also adapting already designed
block schema directly from *.mdl files in
TABLE I MATLAB/Simulink environment.
COST COMPARISON OF POSSIBLE CONTROL SOLUTIONS It uses its own large library blocks, namely various
types of regulation and controllers, which are problem
RT Card solution REX Control solution oriented especially on real process control, as well as the
Matlab toolbox for RT 180 EUR REX control SW 390 EUR fundamental library blocks, which are similar to the
dSPACE (no.1104) 9800 EUR WinPAC Wincon 1600 EUR
MATLAB/Simulink program, and which are
automatically recognized after reading the mdl file and
10000 EUR 2000 EUR
sent to RexDraw environment in form of a new block
schema, which is very similar to the Simulink one.
II. ARCHITECTURE DESCRIPTION Most of the fundamental blocks in Simulink have
their equivalent in REX Control block library.
Program MATLAB represents at the present time a
The REX Control libraries are also supported and
complex tool for technical calculations and its own
displayed directly in MATLAB/Simulink as another
design for an entire range of technical problems from
Simulink library toolbox, therefore the schema design
different areas, namely by MATLAB/Simulink and its
and tuning can be done in Simulink directly, even
problem oriented toolboxes, block sets and libraries in
before the RexDraw environment run.
which it is possible easily and quickly simulate system
behaviour and design their suitable control and control
algorithms [6]. 1 u y Gain
u1
u2
y
Substraction
GAIN
Problems however start if we want to transfer the Gain Add1
SUB
B. Target Platforms
As the target platform it is possible to select a whole
range of supported platforms, or write your own
supported drivers. The presently supported standard
platforms are:
• PC and IPC (industrial PC) with OS Windows
95/98/ME/NT4/2000/XP, Phar Lap ETS and
VenturCom RTX, National Instruments and Advantech
boards, Ethernet based Terminator I/O
• WinPLC equipped with DL205 series modules
and Windows CE OS
• TECOMAT TC700 with Windows CE OS
The RT WinPLC - WinCon 8000 Compact Embedded
Controller was used as the universal target equipment in
our case, which represents a new generation of
programmable controllers, combining the classical PC Fig. 4. Possibilities of connection and extension of
and PLC and creating so called PAC - Programmable peripheries and communication
Automation Controller, whose advantages are obvious
from the first sight in Figure 3. III. MEASUREMENT AND CONTROL ON A REAL SYSTEM
The controlled system is dynamically demanding
Windows CE system of a hydraulic drive, Figure 6, which is
I/O Modules controlled by four-way flow servo valve, which
implements discharging and shifting piston, which is
during the stroke loaded with pressure and tension force
implementing disturbance on a system and which
requires design of more sophisticated control algorithms
Ruggedness and Reliability and control quality that are able to compensate effects
related to hydraulic drive control, as for example
Fig. 3. Advantage of the PAC usage (left) and WinPLC hydrodynamic forces acting inside of valves, system
(PAC) WinCon 8000 machinery used for real application nonlinearities, leakages, friction, cavitation effects, etc.
control (right)
14-bits, 100kHz), an analog output module I-87024 (4 Fig. 5. Block schema of feedback control in
voltage and 4 current outputs -14bit) and digital I/O MATLAB/Simulink (left and top) and a case with inputs
module I-8054 (8 digital input and outputs). The reading and outputs generating options directly in MATLAB
possibilities of a network connection, connecting other (right)
Required Values Substraction P-regulator Range change OUTPUTS: WinCon was connected directly to Ethernet. Each
Y RUN
y
is
u1
u2
y
error
u1
u2
y u1 y [WCN__SA5I24V0] sample of a signal connected to RDC block was
CNB_1 u2 E
ANLS_1 SUB_1
MUL_2 DIV_2 HALT
err transferred about every two miliseconds, which was
B f resh C
INPUTS: y y
u0
u1
y0
y1
sufficient for our required sampling period 0.005s.
CNR_5 CNR_6 u2
[WCN__S2I17X0] u1
y
A u3
y2
u2 y3
u4
y4
MUL_3 Range Changes u5
y5
u6
CNR_4 u7
y6
V. VISUALISATION OPTION
y
y7
u8
y8
u9
y9
u10
u11
u12
y 10
y 11 All input and output variables of all the blocks can be
y 12
u13
u14
y 13
y 14
monitored and changed and set with RexView Program.
u15
y 15
RDC_1 The important property of the REX problem solution is
the implementation of a standard OPC interface,
Fig. 6. Block schema in Figure 5 in RexDraw with
enabling connecting to all significant systems for
connected inputs and outputs for autonomous process control visualization and operator supervision of controlled
from WinCon and forwarding measurement variables to processes (SCADA and HMI).
Simulink (signals A and B) at the same time This OPC interface (called Automation) enables to
create an interconnection to another application for
For the design of control schemas the fundamental visualizing measured data. Such application can be
feedback circuit was tested first, whose schema in created in Microsoft Visual Studio 2008 in C# language.
Simulink can be seen in Figure 5 and it’s automatically This solution is free of cost and easy to create. For data
generated equivalent in REX environment in Figure 6. storage the RT database Microsoft SQL Server CE can
From the figures, it is obvious that blocks used in both be used.
cases are very similar and the design of control schema We create such solution based on Microsoft RT
using REX libraries and automatic loading of mdl files solutions. First test of complete measurement and
and their schemas is not too difficult. control network are sufficient. The measurements with
Matlab visualization are delayed by 20 % in mean value.
IV. WIRELESS NETWORK MEASURING AND RT WinCon solution with our own application for
COMMUNICATION visualization is always in time. As test bed we used
VRDB testbed [8] and [9].
Used PAC equipment enables connecting to higher
control levels with UDP/IP protocol. This protocol is
used as often as the well – known TCP/IP and functions
on all LAN and Internet as well.
One of the specialized blocks of REX library, the
RDC (Remote Data Copy) block is used for
communication between two blocks on different
computers, or two Simulinks on the same PC and/or
Simulink and REX system, Figure 5 and Figure 6. In
this case we used it for communication between REX
program in WinCon and Simulink on the second PC.
Set parameters are always the IP address of the
second equipment, a remote port – rport, a local port –
lport, the id and the sampling period, which must be the
same for both communicating blocks.
Block SLEEP is then used for synchronization of sent Fig. 7. Visualization of real fluid motor control. The graph
and received data with WInCon, since the of required and real values
communication would not work without it, and it
contain a parameter “SleepTime”, which needs to be set VII. CONCLUSION
the same as a parameter “tick” in block EXEC, which
determines the shortest sampling period, with which the This contribution brought a design and
target equipment WinCon will work and in which the implementation for permanent problem solution for a
data will be transferred. The smallest possible setting is control of dynamically demanding process with
0.001s. In our case and also from the security reasons multiplatform control system REX Control compatible
the sampling period 0.005s was used. with MATLAB/Simulink. Real time measurements and
The whole control process was tested and controlled control via network and Wifi connections were
from MATLAB/Simulink environment, which run on a performed directly from Simulink and compared to
notebook connected to a network through WiFi, while autonomous control at WinCon and furthermore with a
classical method using measurements implemented on
PC RT data acquisition cards AD614 and dSPACE
system.
ACKNOWLEDGEMENT
This research has been carried out under the financial
support of the research grants “Safety and security of
networked embedded system applications”, GACR, GA
102/08/1429, Grant Agency of Czech Republic, and
“Centre for Applied Cybernetics“, Ministry of
Education of the Czech Republic under Project
1M0567.
REFERENCES
[1] Official pages of multiplatform control system REX
[online]. Available on http://www.rexcontrols.cz
[2] Official pages of PAC WinCon8000 [online].Available
on http://www.elcomgroup.cz/ipc/en/default.asp
[3] Official pages for web and wireless applications \
INDUSOFT - tool for automation [online].Available on
http://www.indusoft.com
[4] Official pages of ICP DAS [online]. Available on
http://www.icpdas.com
[5] Official pages of dSPACE Systems [online]. Available on
http://www.dspace.com/ww/en/inc/home.cfm
[6] Official pages of MATLAB product [online]. Available
on http://www.mathworks.com
[7] Krejcar, O.: User Localization for Intelligent Crisis
Management. In AIAI 2006, 3rd IFIP Conference on
Artificial Intelligence Applications and Innovation, pp.
221-227, Athens, Greece, (2006).
[8] Krejcar, O., Cernohorsky, J.: Database Prebuffering as a
Way to Create a Mobile Control and Information System
with Better Response Time. In Lecture Notes in
Computer Science, Computational Science – ICCS 2008,
Volume 5101/2008, The International Conference on
Computational Science 2008, pp. 489-498, Cracow,
Poland, (2008).
[9] Slanina, Z.: Embedded linux scheduler monitoring, In
ETFA 2007: 12th IEEE International Conference on
Emerging Technologies and Factory Automation, Vols 1-
3, SEP 25-28, 2007 Univ Patras, Patras, Greece, pp. 760-
763, (2007)
[10] Krejcar, O.: Prebuffering as a way to exceed the data
transfer speed limits in mobile control systems, In
ICINCO 2008, 5th International Conference on
Informatics in Control, Automation and Robotics, May
11-15, 2008 Funchal, Portugal, pp. 111-114, (2008)