PC-based Control System for Storage Ring TERAS
H. Ohgaki, H. Toyokawa, R. Suzuki, S. Sugiyama, T. Mikado, K. Yamada, T. Ohdaira, N. Sei, andM. Chiwaki, Electrotechnical Laboratory, 1-1-4 Umezono, Tsukuba, Ibaraki 305-8568, Japan

Abstract
Personal Computer-based control system has beendeveloped for the storage ring TERAS at ElectrotechnicalLaboratory. The system consists of three layers: device
control layer, user interface layer, and network layer. I/O
cards installed in IBM-PCs are connected to the control
devices. Each I/O card has a corresponding client/serverapplication communicating via TCP/IP protocol. A
database subsystem has been developed to record themachine status and to help an operation of the ring. This
inexpensive system shows a good reliability for thestorage ring operation and a large flexibility for upgrading.

1 INTRODUCTION
Personal Computer (PC)-based control system is one ofreasonable choices for an accelerator facility[1]. Due tothe advances in the hardware technology of the PC, a PC
with a moderate speed PC costs below $1000. Softwaredevelopment tools have also been developed in the PC
world. Moreover, a recent operating system (OS) runningon a PC has a built-in network service that smoothly
connects with their applications working on a distributed
PC environment. Therefore, a distributed control system
can also be constructed with PCs over a network system
inexpensively[2].
A PC-based control system is introduced to the control
system for the storage ring TERAS[3] at ElectrotechnicalLaboratory (ETL) constructed for a multipurpose
synchrotron radiation source. Electron beam is injected by
a 300 MeV linac and the ring is operated ranging from
200 MeV to 800 MeV fitting for user’s request. The
electron orbit has also been tuned to several specificexperiments. The original control system was constructed
in 1979. All knobs and switches were manually controlled
in the control room with hard-wired cables. Since nocomputer system was employed in this original system, anoperator had to change the ring parameters with a goodskill. Therefore, a computer control system has been
greatly desired. The PC-based control system for the main
magnet power supplies (PSs) has been introduced in
1990[4]. Then, the steering magnet and the RF control PC
were added to the system[5]. However, these PCs wereoperated independently; operators still had to operatethese independent subsystems simultaneously. To
combine the independent subsystems and to adjust thering parameters at any place, the system has been
upgraded to use a network system since 1996[6]. AFig.1 Schematic view of the PC-based controlsystem. IOC-PC means I/O control PC and MMIPC, man-machine interface PC.
vacuum monitoring system, several I/O devices, and the
database subsystem have been added to the system.
The system consists of three layers: device control layer,
user interface layer, and network layer. Figure 1 shows aschematic view of the system. Several subsystems, shownas dotted boxes in the figure (beam transport system, andtiming system) are still isolated from the PC-control
system and are wired with cables. These subsystems will
be added to the system in the near future.

2 DEVICE CONTROL LAYER
The device control layer consists of several I/O
control (IOC) PCs that are equipped with I/O cards
inserted into the expansion slots. IBM clones are used forthe control PC. Windows95/98 is used for the OS, because
1) it works with a small resource PC; 2) the I/O card isdirectly accessible from applications without any device
drivers; 3) the built-in TCP/IP protocol is ready-to-use; 4)
it is commonly used in our facility and many excellent
applications and software development tools are available

with reasonable costs. We use industrial ADC cards, DAC
cards, and GPIB cards for interfacing to the control
devices. When the density of the control device is low,
I/O card system is cheaper than that with standard bus(CAMAC or VME). Each I/O card has a corresponding
control application that consists of I/O card manager, dataprocessing manager, local user interface, and Windows
Socket server. Therefore any I/O card and/or IOC can beeasily replaced and upgraded. Furthermore, if the numberof IOC-PC increases to distribute the I/O card, the system
power is enhanced within a minimum change of theapplication and the system itself. The data acquired by theIOCs are transported to any PCs via network, when they
are required.

2.1 Magnet control
A 16-bit/32-channel ADC card is employed to monitor
the output currents of the magnet PSs via isolationamplifiers. Magnet ADC-IOC is located apart from themagnet PSs and the ADC data are averaged in 500 times,
because of large switching noise generated by the magnet
PSs. The smoothing of the data limits the data acquisition
rate below 10 Hz. This data acquisition rate is still highenough to operate the storage ring. The magnetic field of
the main dipole magnet measured with a hall probe andthe stored electron current measured with a DCCT are
also monitored by this IOC.
Magnet DAC-IOC consists of a 16-bit/4-channel DAC
card and two 12-bit/8-channel DAC cards. The 16-bit
DAC card controls main magnet PSs. The 12-bit DAC
cards control the beam steering magnet PSs. Each DAC
card has a corresponding client/server (C/S) application,and they work independently. Because these magnets
should be controlled simultaneously, the client applicationof the 16-bit/4channel DAC has three Windows Sockets
clients and controls the two 12-bit DAC cards
simultaneously. The data communication rate is 1 Hz forthe 16-bit DAC card and 2 Hz for the 12-bit DAC cards.
Figure 2 shows a structure of IOC-PC for the magnetcontrol system. This figure also shows several client
applications running on man-machine interface PCs(MMI-PCs).

2.2 RF control
The RF-IOC consists of 12-bit/4-channel ADC card and12-bit/4-channel DAC card. The control PC is NEC-PC98.
The ADC reads the RF parameters, i.e. the cavity
temperature, the electric field strength in the RF-cavity,
and RF phase. Operation energy of the storage ring that ismonitored by the Magnet-ADC-IOC is referred via
Windows Socket to provide an optimum RF power fed tothe cavity. The 12-bit DAC controls the output power ofthe RF amplifier. A feedback control is required to theDAC output to stabilize the electric field of the RF-cavity

Fig.2 Structure of IOC-PC for the magnet
control system.
that is monitored by the ADC. To obtain a fast feedback
loop, the control applications of two I/O cards areintegrated into one.

2.3 Others
Vacuum monitoring IOC controls two 12-bit ADC
cards, which read the ion gauge currents and the ion pumpcurrent, respectively. This IOC also reads several RF
power amplifier statuses.
Beam diagnostic IOC consists of a GPIB card reading
the data from the beam position monitor.
Several important subsystems, such as beam profile
monitor, tune monitor, injection subsystem are working
independently. They will be integrated into the PC control
system in the near future.

3 USER INTERFACE LAYER
The user interface layer consists of several manmachine interface (MMI) PCs distributed over the control
room and the experiment rooms. Windows 95/98/NT
gives both the graphical user interface (GUI) environment
and the network communication environment. Because nospecial input device is employed for the GUI, any
Windows PC connected to the Ethernet system can be a
MMI PC. Two exclusive MMI-PCs located in the control
room work as data logger and database server,respectively. Figure 3 shows the screen shots of these
MMI-PCs. Client applications are accessible via networkand no software installation procedure is required except
for the database applications. Therefore IOC-PC
sometimes works as MMI-PC. Tele-remote control is alsoavailable by using Windows dial-up service or ETL-PPP.

4 NETWORK LAYER
The network layer consists of 10 Mbps Ethernet LANsystem installed in the whole facility. This line ismultipurpose one and many items of information ofIntranet and Internet also run through the line. Therefore,
the TCP/IP protocol is used for the network protocol andeach PCs has own IP address. In our control system theI/O cards have individual servers; the clients designate
proper IP address and IP port to open the connection. Thecontrol system has never met any trouble on the network
traffic and any accidental access. The network traffic of
the control system is few k-bps for whole control system.
The Ethernet system is protected from the invalid accessoutside of the facility with a Firewall. A supervisor layer
should be added to limit the network access to the controlsystem.

5 DATABASE
A database subsystem that assists the daily operation of
the storage ring has been developed. The Paradox
database system is used for this system, because Borland(Inprise) Delphi, which has been used for the softwaredevelopment tool, smoothly treats with the Paradox data.
The database subsystem stores the magnet parameters, theBPM data, the RF parameters, and the vacuum condition.
These values are provided via server applications runningin the IOC-PCs. Data-logger applications are running on
the exclusive MMI-PCs in the control room and store thedata. Graphs in fig.3 show several database items. The
data is logged in every 1 minute, and the record size of thedatabase is about 12 MB per month. The database files are
periodically copied to a CD-ROM.

Fig.3 Screen shots of the MMI-PCs running in thecontrol room. Several data logging applications are
running on the background.

6 CONCLUSION AND FUTURE PLAN
PC-based control system has been developed in thestorage ring TERAS step by step. The system consists ofIOC-PCs, MMI-PCs, and the network system. Several
industrial I/O cards inserted into the expansion slots ofIOC-PCs are used for interfacing to the control devices.
This system has a good reliability and the large flexibility
for upgrading. The beam transport system, the timingsystem, several beam diagnostic system, which are notincluded into the PC-control system, will be integrated tothe system in the near future.

REFERENCES[1] See, for example, S.Magyary: Proceedings of the 1993
Particle Accelerator Conference, Vol.3(1993)
1811;CJ.Vincent et al.: IEEE Trans. Nucl. Sci., Vol-43
No.1(1996)30[2] Proceedings of the PCAPAC at DESY (1996); Proceedingsof the ICALEPCS97(1997).
[3] T.Tomimasu et al.: IEEE Trans. Nucl. Sci., 30, 3133(1983).
[4] R.Suzuki et al.:TELL-TERAS Activity Report
1987~1990(1990)63.

[5] H.Ohgaki et al.:Proceedings of the 17th Linear Accelerator
Meeting in Japan,(1992)192.

[6] H.Ohgaki et al.:Proceedings of the ICALEPCS97(1997)185.