Control System of PLS 2-GeV Storage Ring
I. S. Ko, Jin W. Lee, Jong C. Yun, Eun H. Lee, and Byoung R. Park
Pohang Accelerator Laboratory, POSTECH
Pohang 790-784, Korea
Abstract
A real-time computer control system is developed andused for the remote operation of the Pohang Light Source(PLS) 2-GeV storage ring. It consists of three layers ofcomputer systems; console computer for operator interface,subsystem control computer (SCC) for front-end dataprocessing, machine interface unit (MIU) for low-level dataacquisition. The console computer is Sun Microsystem's
SPARCstation with UNIX. It uses X-Window/Motif for theGUI (graphical user interface) tool. The SCC acts as afront-end data processing between the console computerand the MIU. There are 24 MIUs placed in the storage ringbuilding. The MIU is directly connected to individualmachine components to do low-level data acquisition. TheSCC and MIU are based on VMEbus standard and use
Microware's OS-9 real-time operating system. Consolecomputers and SCCs are connected through Ethernet(TCP/IP). SCCs and MIUs are connected through MILSTD-1553B fieldbus.
1 Introduction
The Pohang Light Source (PLS) is a 2-GeV third
generation light source that has a 150-m 2-GeV full energy
injection linac and a 280-m circumference storage ring. Itsconstruction was completed in December 1994 and normal
operation for beam-line users started in September 1995.
We have developed a large-scale computer control
system for the PLS 2-GeV storage ring. The control system
was completed in August 1994. After minor systemmodification and upgrade works during machinecommissioning period from September 1994 to July 1995,
the control system now shows very stable and reliablecharacteristics which meet our control requirement.
However, the control system is continuously being
upgraded to accommodate additional control requirements
such as insertion devices. With better operational
experiences, we are also doing research and development
work according to the advance of computer technology
such as multimedia system [1].
The computer control system for the PLS 2-GeV storage
ring has a distributed control architecture, and has threelayers of hierarchy; operator interface computer (OIC)
layer, subsystem control computer (SCC) layer, andmachine interface unit (MIU) layer. The OIC layer isbased on Sun Microsystems' SPARCstation with UNIX(SunOS 4.1.3) and X-terminals. X-Window/Motif is used
for graphical user interface tool. The SCC acts as a data
gateway between the OIC layer and the MIU layer. TheMIU layer is directly interfaced to individual machine
devices for low-level data acquisition and control. The

SCC and MIU layer is based on VMEbus standard with
OS-9 real-time operating system. SCC and MIU are OS-9ROM-based system. Executable application softwaremodules are downloaded from host computer at systemstart-up time. There are 4 SCCs and 24 MIUs in total. The
OIC layer and SCC layer is linked through Ethernet(TCP/IP). They communicate with each other in the formof client-server. The SCC layer and MIU layer is linked
through MIL-STD-1553B fieldbus. They communicate
with each other in the form of master-slave.
2 Machine components under control
The 2-GeV storage ring consists of various kinds ofmachine components which need remote control. Major
components include magnet power supplies, vacuum
devices, beam diagnostic devices, RF system, and timing
devices. These components are placed around the 280-m
circumference storage ring building. The number of control
points from these components amounts to about 6,000 intotal.
There are a total of 215 power supplies for various
magnets in the storage ring. These power supplies areplaced in two locations: 6 units in the linac power
substation and other units in the 12 local control sheds
around the storage ring building. Each corrector magnet
power supply unit has a digital type I/O port that isconnected to the machine interface unit called the COMIU.
However, each unit of remaining power supplies has aRS422 serial communication port that is connected to themachine interface unit called the VMMIU.
The vacuum system consists of 123 ion pumps, 53 iongauges, and 15 gate valves. These components have theirown local controllers placed in the 12 local control sheds.
These local controllers are interfaced to the machineinterface units called the VMMIU. Each pump and gauge
controller has an RS422 type serial communication port.
Each gate valve controller has a relay type I/O port.
For beam diagnostic purpose, there are 108 beam
position monitors, 1 DCCT system, 3 screen monitors, 1tune measurement system, and 1 beam scraper system. We
have developed in-house VXI-type electronic modules toprocess electric signals from beam position monitors, andthese modules are installed in VXI crates. The VXI crate islinked to the machine interface unit called the COMIU via
VXI-to-VME repeater. The subsystem control computer,
the VMSCC, is used for low-level data acquisition for therest of diagnostic systems.
The RF system consists of various components such as
klystron, cavity, high voltage power supply, circulator, low-level RF electronic system, etc. These components areplaced in the RF building. For low-level data acquisition

Interface Layer

Operator

SUN
SPARCstation(SUN-OS 4.1.3)

SUN
SPARCstation(SUN-OS 4.1.3)

SUN£”PARCstation£®SUN-OS 4.1.3)

X-Term

X-Term

X-TermControl Layer

Subsystem

Ethernet(TCP/IP)
TISCC

VMSCC

VME
(OS-9)

Interface Layer

MachineMIL-STD-1553B

VMMIU

COMIU

VME
(OS-9)

VME(OS-9)(6)(6). .RF system

(6)
COMIU

VME
(OS-9)

VME(OS-9). VACUUM dvices. RS422 type MPSs
. Injection system. etc.

VME(OS-9)

COMIU

VMMIU

VMMIU

.Timing systemCOMIU
VME(OS-9)(6)

VME(OS-9)

Devices

VME(OS-9)MIL-STD-1553B

VMMIU

Machine

COSCC

RFSCC
VME
(OS-9)

VME(OS-9)VME(OS-9). Beam position monitors. MPSs for corrector magnets

Fig. 1: Schematic diagram of the PLS 2-GeV storage ring control system.

for these RF components, we have assigned a subsystem
control computer (RFSCC) placed in the RF building.
Various types of commercial VME I/O boards are used tointerface with these RF components [2].
We have also developed in-house electronic modules formachine timing and synchronisation system. All thesemodules are based on VXI, and installed in a VXI crate
together with VME type CPU board to form a subsystem
control computer (TISCC).

SPARCstation #2 is used for the magnet power supply
control. Third SPARCstation is used for the timing control.
X-terminal #1 is used for the beam position monitor data
display. Second X-terminal is used for the vacuum profile
displays. Third X-terminal is used for the beam current andlifetime display. All graphic user interface programminghas been done with X-Windows/Motif.

3 Hardware of control system

In order to reduce work load on OICs, we have divided
the control system into five subsystems according to thesimilar functional characteristics in the control point ofview; vacuum system and RS-422 type magnet powersupplies (VMSCC), beam position monitors and digital I/Otype magnet power supplies (COSCC), RF system(RFSCC), and timing system (TISCC). The VMSCC has
twelve machine interface units named VMMIUs and theCOSCC also has twelve machine interface units named
COMIUs. These MIUs are multi-dropped from SCC
through MIL-STD-1553B. The RFSCC and TISCC aredirectly interfaced to devices to do low-level dataacquisition. The SCCs use Motorola's MVME147SB-2 astheir CPU board. MVME147B-2 has 16MB DRAM with
33 MHz CPU clock. Each SCC is a diskless ROM-basedsystem. The ROM contains OS-9 real-time operating
system and other necessary application modules. The SCCs
and the OICs are connected through Ethernet (TCP/IP) fordata communication between them.

The schematic diagram of the PLS 2-GeV storage ring
control system is shown in Fig. 1. There are three layers inthe control hierarchy; Operator Interface Computer (OIC)
layer, Subsystem Control Computer (SCC) layer, andMachine Interface Unit (MIU) layer.
3.1 Operator interface computer (OIC)The OIC layer provides various kinds of graphical userinterface windows for the operator to control and monitor
the storage ring machine. In the OIC layer, there are three
SUN Microsystems' SPARCstations and three X-terminals,
which are placed in the main control room. Each
SPARCstation has 64MB main memory and 4.4 GB harddisk.
We have assigned a dedicated function to each of OICs
for the operator's convenience. SPARCstation #1 is used
for the control and monitoring of the RF system.

3.2 Subsystem control computer (SCC)them.
X-servermonitorOperator Interface Layer

application
process

3.4 VME boards
Most of VME boards used in SCCs and MIUs arecommercial products. A summary of commercial VME
boards used for SCCs and MIUs are shown in Table 1.

lib.
mulccfclientdynamic
database

ccf
clientfreshdb
clientstaticdatabase

Ethernet(TCP/IP)

ccf
serverSubsystem Control Layer

mulccfserverfreshdb
serverlocal
database

command buffer

controltask

monitortask
conmgrrfrmgrI/O driverdriverI/O
HardwareTable 1: Summary of VME boards used
Model
MVME147S-1
MVME147SB-2
BUS65522II
AVME9510-I

#24
428
20

AVME9330
AVME9470
AVME9210
AVME9450-I
TSVME630
TSVME500
ESD-ASIO16
ESD-DIOC0/40
ESD-DIOC48/0

1
3441
2
25
48
48

Description
SBC, 25 MHz, 4MB DRAM
SBC, 33 MHz, 16MB DRAM
MIL-STD-1553B Interface
32 digital input/output,
16 ADC, 2 DAC
16 ADC
80 digital input/output
8 DAC
32 digital input/output
Image Processing
4 x RS422
16 x RS422
48 digital outputs
48 digital inputs

devices
MIL-1553B driverMachin Interface Layer

netmgrcommandbuffer

local
database

controltask

monitortask
I/O driver
HardwaredevicesFig. 2: Software structure of the PLS 2-GeV storage ringcontrol system.
3.3 Machine interface unit (MIU)
The MIUs are directly connected to individual devices
and performs low-level data acquisition. There are total 24MIUs; twelve VMMIUs and twelve COMIUs. VMMIUs
are interfaced to vacuum devices and RS-422 type magnet
power supplies. COMIUs are interfaced to beam position
monitors and digital I/O type magnet power supplies. AllVMMIUs and COMIUs are placed in the 12 local control
sheds around the storage ring building. Each MIU uses
Motorola's MVME147S-1 as a CPU board. MVME147S-1
has 4MB DRAM with 25 MHz CPU clock. Each MIU is adiskless ROM-based system. The ROM contains OS-9 realtime operating system and other necessary application
modules. We can remotely control and monitor the power
and reset of each MIU crate from the control panel placedin the control room. The MIUs and the SCCs are connected
through MIL-STD-1553B for data communication between

4 Software of control system
In parallel with the hardware structure, there are threelayers in software structure. The software structure of thePLS 2-GeV storage ring is shown in Fig. 2. There are threeimportant features in the storage ring control software; theclient/server model to exchange data between operator
interface layer and subsystem control layer, themaster/slave model to exchange data between subsystem
control layer and machine interface layer, and theseparation of control and monitor tasks.
4.1 Operator interface computer layer
The major role of operator interface software in the OIC
is to provide operator with various tools to monitor andcontrol the machine. The major components of the OIC
software are database, graphical user interface software,and communication software.
The database consists of static database partition anddynamic database partition. Dynamic database stores setpoint and read-back values for the control signals. Static
database stores all sorts of static information to manage
machine control signals. Current set-point values of themachine components and their read-back values areupdated in real-time basis.
We have adopted a client-server model for communication between the OIC and the SCC. Client tasks runningon the OIC send service requests to server tasks running on
the SCC. Then, server tasks execute services and returnresults to the requesting clients. There are three clients forcommunication in the OIC; dynamic database refresh client(frshdb), single control command forwarding client (ccf),and multiple command forwarding client (mulccf). The ccf
is for setting a specific signal to some value. The mulccf isfor setting multiple signals to corresponding values at once.
The frshdb is for updating specific parts of the dynamic
database with the present machine data stored in the SCCs.
Graphical user interface software is provided to theoperator to use operating environment easily. We haveused X-Window/Motif for the GUI (Graphical User Interface) programming. All graphical user interface processes
may ask frshdb to update the corresponding dynamic
database for the signal group they are interested in. Theyuse database access subroutines to get the interesting realtime data from the dynamic database and display themachine status on the computer screens. They also instruct
ccf to set some control signals to the desired set-pointvalues.
4.2 Subsystem control computer layer
The SCC software acts as data gateway between the OIC
layer and the MIU layer. Network task (rfrmgr) gathers theupdated device data from attached MIUs through MIL1553B network, and stores them in the local data buffer(sccddb). Upon request from the database refresh client of
the OIC, database refresh server sends the requested data inthe sccddb to the OIC through Ethernet. Upon device
control request from the control command forwarding
client or the multiple control command forwarding client of
the OIC, the control command forwarding server transfers
the control command to network task (conmgr), which
finally transmit this command to the proper MIU throughMIL-1553B network.

through the appropriate I/O driver and hardware.
5 Current status
At present, we have a reliable control system for PLS 2GeV storage ring. Recently, timing software has been
modified for the uniform bucket fill function for the fastion instability experiment. We are upgrading and modifying the control system to accommodate new control
requirements and to apply operational experiences. Hereare some of the major activities which are currently beingdone.
We are preparing one more duplicated operator computersystem in addition to the main one. This duplicated system
will be used for research and development works in thenormal situation. In case of main system failure, thissystem can be used as backup. In this way, we cansmoothly apply research and development results to thereal system. We are also building a database server
environment by using ORACLE. This server environment
will be linked to the on-line database of the operator
computer. This will provide physicists and engineers withuniform and integrated environment for the storage andanalysis of the operation and machine dada.
We are also developing the data acquisition system forthe undulator U7 in the storage ring, which was installed inAugust 22, 1997. We have completed local level control
test. The integration into the present control system will bedone by the end of this year.

4.3 Machine interface unit layer

Acknowledgements

Major function of the MIU software is to directly monitor
and control individual devices. The monitor task monitors
attached devices regularly and stores updated hhhdata todata buffer (miuddb). The network task (netmgr) sends thedata stored in the miuddb to the SCC upon its request.
Upon receiving device control command from the SCC, thenetwork task (netmgr) stores the control command in thecommand buffer (cmdbuf). For the fast action, the network
task notifies the appropriate control task of the arrival of
the command through the software interrupt called signal.
The control task finally controls the designated device

This work is supported by Ministry of Science andTechnology, Korea and Pohang Iron & Steel Co..
References[1] I. S. Ko, J. H. Kim, and S. C. Kim, Test bed of Control
System Using Multimedia Technology at PLS, inProc. of IEEE Real-Time Conference 97 (to bepublished).
[2] M. Kwon, H. J. Park, and I. S. Ko, Control of PohangLight Source RF System, in Proc. of IEEE Real-Time
Conference 97 (to be published).