Professional Documents
Culture Documents
Windows95 Windows95
10Base-T HUB
PLC Objects
MELSECNET/10
MELSEC (10Mbps)
ORB for PLC Access
Driver Prototype ORB Ladder I/O Device Simulator
for PLC Program
WindowsNT
Internet technology is applicable without addi- (3) Remote monitoring application : This is an
tional mechanism in PLC side. application to monitor manufacturing line from
remote site through Internet. This application
In our proposed architecture of a CORBA-based has the same functions as manufacturing line
remote monitoring system for FA, hard real-time con- monitoring application described in (1).
trol of I/O devices is executed by PLCs. PLC objects,
which are abstraction models of PLCs to information (4) PLC objects : These CORBA-based objects
systems, are used as a gateway to real-time control represent components or functions of a PLC.
sub-system.
The following are abstracts of software components. (5) ORB for PLC : This is an ORB aimed to be
In Figure 1, colored software modules were developed implemented in a PLC. Features are compactness
by ourselves. of module size and high performance of response
time.
(1) Manufacturing Line monitoring application : (6) Ladder Program : This controls I/O device
This module provides following functions. simulator.
searching a conguration of hardware units The denition of the object model of PLC and the
of PLC, development of ORB for PLC are most critical in the
searching information about each hardware development of this prototype system. In 2.2 and 2.3,
units, we describe the details of them.
searching dynamic information such as total 2.2 Object modeling of PLC
operation time, In existing manufacturing systems, I/O memory
searching and changing information about address, to which each I/O device is connected, has
I/O relay address, to be specied to control the I/O device or to set a
monitoring condition. Therefore, not only sequence
searching and changing status of each mem- control programs but also manufacturing line monitor-
ories, and ing programs have to be changed when I/O memory
searching and changing status of I/O de- address is changed because of changing conguration
vices. of manufacturing lines.
It is expected to become very easy to maintain a
(2) OLE server : This OLE server is a gateway be- manufacturing line monitoring application if it uses
tween OLE environment and CORBA environ- an abstract name to check the status of PLC and I/O
ment to provide OLE interface to an application. device instead of a physical memory address.
PLC Hardware
maintenance information
maintenance information abstract name
get information
get information get abstract name
execution PLC change abstract name
stop PLC
CPU unit Power unit Communication Unit Input/Output unit Another unit
maintenace inf. maintenance inf. maintenance inf. maintenance inf. maintenance inf.
spec. inf. spec. inf. spec. inf. spec. inf. spec. inf.
get information get information get information get information get information
Memory
memory type
data type
read value
write value
Register Memory Timer Memory Counter Memory Output Memory Input Memory I/O device
values values device type
values values values
abstract name
read value read value
address to I/O memory
write value write value
read value read value read value
get status
write value write value write value
change status
get abstract name
change abstract name
Data Memory Shared Memory
values values
read value read value
write value write value
Object-oriented technology can solve the above information such as establishment time and oper-
problems. Following design policies were adopted in ating start time, and abstract name.
the design of PLC objects.
(3) CPU unit class, power unit class, commu-
(1) Modeled objects should be used both to monitor nication unit class, input/output unit class,
the production status of manufacturing line and and another unit class have attributes of hard-
to maintain manufacturing devices. ware specication information such as a manu-
facturer name and type name, and maintenance
(2) PLC controls all I/O devices in existing systems. information such as total operating time and ver-
However, some intelligent I/O devices which can sion number of system ROM.
connect to network directly and act with au-
tonomy such like LONWORKS[7] are appearing. (4) Memory class is a base class of each type of
Therefore, we separated functions of I/O devices memories in PLC. A PLC has a various types of
and those of PLC. Our modeled object would be computing resources called memories to control
possible to be used when autonomous I/O devices I/O devices. Memory class has attributes of mem-
are used in manufacturing system. ory type and data type (bit data or byte data).
The dened object model of PLC is shown in Figure (5) Register memory class, timer memory
2. The following are details of classes. class, counter memory class, data memory
class, shared memory class, input memory
(1) PLC class manages all objects related to PLC class, and output memory class correspond
and provides functions for starting and stopping to each memories in a PLC. A PLC works con-
PLC. tinually by scanning a program which is usually
programmed by ladder program. I/O devices are
(2) Hardware class is a base class of hardware units controlled through input/output memory which
of PLC. This class has attributes of maintenance re
ects the status of I/O devices.
(6) I/O device class is a virtual I/O device for an of an object is to be invoked. Therefore, dynamic cre-
application to check the status of I/O device with ation/deletion of objects and dynamic method invo-
using an abstract name of each I/O device. cation have not been implemented in the ORB for FA
environment. By this, design policy (2) was achieved.
2.3 Software architecture of distributed Figure 3 shows the software architecture of our
object management for PLC ORB for PLC.
The following design policies were adopted when we PLC related objects are created based on the def-
implemented distributed object management middle- inition of object model of PLC described in Section
ware for PLC. 2.2.
ORB core processes communication protocol be-
(1) For each process, the most suitable PLCs have tween a client application and server objects.
to be selected to produce high quality products Object Adapter creates a unique identier for
with high eciency and safety. In that case, the each object within network, and dispatches a corre-
same types of PLCs or the same vendor's PLCs sponding method called by a client application to an
are not always used. Therefore our distributed appropriate object.
object management middleware must have inter- Method parameter processing for PLC re-
operability with other vendor's distributed object lated objects execute marshaling and un-marshaling
management middleware. (Openness) parameters of a called method. In a general-purpose
ORB, these codes are created by IDL(Interface Deni-
(2) In general, CPU and memory performance of con- tion Language) compiler automatically. IDL compiler
trollers are restricted. And most controllers do refers object interface denitions in IDL les. How-
not have second storage devices such as hard disk. ever we implemented these codes manually in every
Therefore, execution module size of distributed method. The reasons are,
object management middleware should be small.
(Compactness) (1) The program created by IDL compiler is generally
large.
(3) A manufacturing line monitoring application and
remote monitoring application must have short (2) The number of dened methods for PLC object
response time compared with remote access ap- model is not so large.
plication used in oce automation. Processing
algorithm in our distributed object management (3) It is possible to optimize modules by sharing com-
middleware should have high performance. (High mon processing parts.
Performance) PLC related objects execute called method.
(4) The open communication protocol between client We implemented the ORB and PLC related objects
and server objects must be adopted in the In- within one process to improve processing performance.
ternet environment as well as LAN environment. Furthermore, we adopted IIOP (Internet Inter-
(Expansiveness) ORB Protocol) specied in CORBA2.0 to satisfy de-
sign policy (4).
To satisfy design policy (1), 2.4 Interoperable Object Reference
we adopted CORBA(Common Object Request Bro- In a CORBA environment in which IIOP is used,
ker Architecture) standardized in OMG(Object Man- the IOR(Interoperable Object Reference) is the iden-
agement Group) and developed ORB (Object Request tier of the object.
Broker) based on CORBA.
type_id profiles
string sequence <Tagged Profile>
PLC related objects
tag profile_data
Method parameter processing ProfileId sequence <octet>
for PLC related objects
ProfileId iiop_version host port object_key
unsigned long Version string unsigned short sequence <octet>
Object Adapter
major minor
ORB Core char char
Figure 3: Software Architecture of our ORB for PLC Figure 4: Data Structure of IOR
It is not necessary to implement all functions in the Figure 4 shows the data structure of IOR. In Fig-
CORBA specication. Only functions required for FA ure 4, colored parts of IOR show the types of data.
environment should be implemented. In FA environ- An object adapter in an ORB receives "object key" in
ment, the number of such objects as controllers, I/O IOR , method name and parameters to be executed.
devices, and applications is xed when a system starts. The object key in IOR is the key to search an object
And a client application already knows which method to execute called method. The CORBA specication
PLC object
Management
Management Management
Management
Table
Table Table
Table
does not dene any algorithm to create object key. concept of this method is analogous to that of existing
A PLC for a large scale system controls more than manufacturing line monitoring application.
two thousands of I/O devices. This means that more Figure 5 shows an example of objects showing one
than two thousands of I/O device objects are created. switch is connected to a PLC. The switch is connected
Therefore it is necessary for object adapter to search to input memory "X0".
the object to execute called method eciently. For a status check function of type 1, manufactur-
In our prototype system, we adopted following def- ing line monitoring application uses read IODevVal ()
inition of object key. operation which is provided by I/O device class. This
The type of object key is octet string and the length operation has only one output parameter of the status
is indenite. Object key based on character string of I/O device.
causes overhead searching of object because of com- Calling sequences and processings in I/O device ob-
paring character strings. We adopted 32 bits integer ject are as follows.
key. Upper 16-bits is class identier for each class de-
ned in 2.2. Lower 16-bits is sequential number of (1) A manufacturing line monitoring application
objects whose number is changed depending on each must get an IOR of an I/O device object that
FA system. represents the switch. A get IOdeviceRef() oper-
ation, which is provided by PLC object, is used.
3 A Manufacturing Line Monitoring There are two types of methods to specify tar-
get I/O device object. One is to set the name
In this section, we present a prototype manufactur- of "switch1" in input parameter. The other is to
ing line monitoring system to which a CORBA-based set memory type "X" and address "0" in input
architecture is applied. We discuss feasibility and ef- parameters.
fectiveness of out architecture.
3.1 Status check functions of I/O devices (2) The manufacturing line monitoring application
calls read DataMem () operation to the I/O de-
Two types of status check functions of I/O device vice object. This operation has only one output
are provided. One is to recognize I/O device as object parameter of the status of I/O device.
and to access I/O device through that object (Type 1).
The other is to specify input/output memory address (3) In I/O device object, the status of "switch1" is
to which target I/O device is connected (Type 2). The checked and returned to the manufacturing line
monitoring application. In existing systems, manufacturing line monitor-
ing applications send polling message to each PLC to
For a status check function of type 2, manufactur- check the status of event conditions, or some parts
ing line monitoring application uses read DataMem ( of distributed shared memory are allocated for event
) operation. This operation is provided by input mem- notication
ags. However, a manufacturing line mon-
ory class. Input parameters of read DataMem ( ) op- itoring application can not detect events immediately
eration are memory type ("X") and address number in case of polling. In the case that distributed shared
("0"). Output parameter is the status of "X0". memory is used to detect event, data must be copied
In input memory object, following processes are ex- to the shared memory. This procedure must be writ-
ecuted. ten in control programs. It restricts extensibility of
(1) Searching the management table to detect target control programs.
I/O device object by using address number. In this prototype system, necessary event condi-
tions are maintained in the server object, which checks
(2) Calling read IODevVal () operation to target I/O the event condition.
device object.
It is possible to check the status of "X0" directly in
4 Application to the Remote PLC
input memory object. However we designed to check Monitoring with using Web Browser
the status only through operation to I/O device ob- Internet technology is also important for an agile
ject. The reason is, manufacturing. It is important that the Internet tech-
nology can be applied under our architecture.
If both input memory object and I/O device ob- We also developed a remote PLC monitoring sys-
ject have the status of I/O device, consistency has tem with using Web browser for prototype system.
to be maintained. It causes processing delay. This prototype system can be applied to the intranet
Manufacturing line monitoring application, in based manufacturing management system and remote
which status check functions of this type are used, fault diagnostic system of PLC.
must be modied if I/O device is re-connected to an- Figure 6 shows action scenarios.
other address of input memory. (1) In Web browser, a type code of target PLC is
Because of providing a status check function of this specied.
type 1, a manufacturing line monitoring application
turns out to be independent of physical memory ad- (2) A Java applet corresponding to the target PLC is
dress of I/O devices. That is, a manufacturing line downloaded from maintenance center server.
application turns to be more
exible to a congura-
tion changing of manufacturing line. (3) The downloaded Java applet runs on Web browser
A status check function of type 2 is provided to by communicating with server objects.
inherit programming style adopted while developing (4) The remote PLC monitoring application user can
legacy software in the past. It gives no
exibility to check the status of the PLC by using the down-
a manufacturing line monitoring application. How- loaded Java applet.
ever, it is easy to change existing manufacturing line
monitoring applications to object-oriented program by The Java applet is a CORBA client and can access
using a status check function of type 2. to objects in a PLC. In this prototype system, Web
Existing SCADA software, such as FIX/DMACS, browser uses OrbixWeb, and communicates with PLC
polls a status of I/O device with minimum cyclic time objects by IIOP.
of 50 ms. We have evaluated that necessary time to Because of the security restriction of Java, a host
process ORB related modules is less than 4 ms in our from which Java applet was downloaded should be the
early performance evaluation. This proved to be very same host that PLC objects are implemented.
usable to connect the user interface for line monitoring If WWW server was implemented in PLC and all
to real-time I/O control sub-system. PLC data in memories were translated to HTML data,
3.2 Event notication function by I/O the same functions can be provided. Our prototype
device monitoring system has two features compared with that.
Event notication function is one of the most signif- In WWW server based system, status of all mem-
icant functions. The following are necessary functions ories in PLC must be translated to HTML data.
for event notication. It causes time delay to real data. Toward this, our
A manufacturing line monitoring application can prototype directly accesses to I/O device through
set conditions for issuing event notication. object. A remote monitoring application can get
real data.
A PLC checks the specied conditions by the
manufacturing line monitoring applications spec- Because PLC objects provide basic functions to
ied. control PLC, a remote monitoring application can
be customized to select suitable functions from
A PLC sends event notication to the manufac- them. Toward this, WWW server based system
turing line monitoring application if specied con- has restricted extensibility because customization
ditions are met. must be executed in WWW server side.
Web Browser
Remote Maintenance
Remote Monitoring Menu Page
Terminal
JAVA
applet
Download
get information Maintenance Program
Objects control PLC Search
target PLCs
Java applet