The Alarm System for the SPring-8 Storage Ring
A.Yamashita, T.Fukui, K.Kobayashi, T.Masuda, A.Taketani, R.Tanaka and T.WadaSPring-8, Kamigori, Ako-gun, Hyogo 678-12, JapanAbstract
The alarm system for the SPring-8 storage ring isdescribed. The system watches status of equipment, gives awarning to operators when a trouble happens, records it andanalyzes past troubles. The system is built on the databasesystem using client/server scheme.
1 Introduction
The SPring-8 storage ring (SR) ended its commissioning
phase and began to feed synchrotron light to users inOctober 1997. The alarm system has been monitoring the4200 signals of the SR since the beginning of thecommissioning in March 1997.
The main purpose of the system is giving alarm to theoperators when an equipment failure happens. Secondly thealarm system enters current status of alarm to the on-line
database and records alarm history for off-line analysis.
The alarm system gives no feedback to the equipment.
Independent hardware system manages interlocks for safetyor equipment protection.
The alarm system consists of the distributed processes onworkstations on the SR control network. [1] Each process
is a client of the SR database system. [2]2 Signal to watch
The poller/collector system [3] collects data fromequipment and enter them into the on-line database. The
alarm system reads the current data of equipment from theon-line database, not from equipment directly.
The alarm system watches two kinds of signals, i.e.
digital and analog signals. A digital signal contains up to
30 independent on/off status in one 32 bit integer. The
alarm system loads nominal digital signals and bit masks tobe set. It compares the nominal digital value to the valueread from the on-line database and writes alarm information if it is different.
Two bits out of the 32 bit integer are reserved for special
purposes. One bit means failure to take data and anothermeans the signal is off state for some reasons. The alarmsystem gives an alarm when a failure is detected under any
alarm condition. The alarm system ignores thesignals with the off bit.
Analog signals are expressed by a 32 bit single precision
floating point value. Analog values are watched by eitherof five kinds of threshold:l Absolute difference to another signal in on-line
database,l Relative difference to another signal in on-line
database,l Absolute high,l Absolute low,l Absolute high and low.
The alarm system makes an alarm with independent
alarm conditions and no combinational alarm.
3 Equipment subgroup
We define equipment subgroups to manage alarm conditions under the equipment groups. Here, an equipment
subgroup means a group of equipment which have thesame status of alarm at the same time. For example, RFequipment group has four equipment subgroups whichhave the subgroup status independently. A RF station is a
one of RF subgroups and it can have three sub group statusi.e. on, off and standby.
A set of alarm signal conditions is defined for one
subgroup status. Here, an alarm condition can mean
thresholds for analog signals or nominal values for digital
signals are exceeded. The alarm system reads the current
status of each equipment subgroup from the parameter
database. Then it loads a set of alarm conditions whichcorrespond to the subgroup status.
4 Two levels of alarm
The alarm system issues two level of alarm i.e. warningand alert. An alert is more serious than a warning. A yellow
signal is displayed on screens when a warning happens anda red signal is displayed for an alert. In addition to thedisplay, a voice alarm warns to operators when an alert
happens.
5 Alarm processes
The alarm system consists of four parts, the alarm watch,
the alarm watch control, the voice alarm and the alarm
display. Each process communicates with each otherthrough message queue [4] or the database. Though those
processes can run at any workstations on the network, weassign a workstation for alarm watch to ease management.
5.1 Alarm control panel
One equipment group, i.e. magnet, vacuum, RF or safety
has only one alarm control panel. At the beginning of thealarm watch, an operator opens alarm control panel on Xwindow. The alarm control panel starts an alarm watch
process and communicates with it through the message
queue.
The operator can change the signal to watch the watch
cycle and the alarm conditions. When the control panel
accepts changes from the panel, it updates data on theparameter database and passes it to the alarm watch
process.
The control panel receives status from the alarm watch
process and displays changes on the screen.5.2 Alarm watch process
An alarm watch control panel forks the alarm watch
process, the heart of the alarm system.
The alarm watch process interacts only with the database
and the alarm control panel. It loads alarm conditions fromthe parameter database at the beginning of the process.
The alarm watch process executes the following job every
5 seconds.
1. Check if the subgroup status has been changed since
the last watch by comparing the time stamp of the databasewith current time. We use the clock on the database serveras the standard time of the system to prevent trouble
occurring by different times on different computers.
2. Read the current status of the equipment from the online database.
3. Compare to them to the alarm condition.
4. Write the alarm information to the alarm tables of theon-line and the archive database when it detects an alarm.
5. Records the end time of the alarm to the archive
database when the alarm turns off.
When the alarm watch receives a message from thecontrol panel, it reloads the alarm conditions for the signals
marked by the control panel from the parameter database.
Another message from the alarm control panel can change
the watch cycle.
5.3 Voice alarm
An independent process, the voice alarm watches the online alarm status and notifies operators when an alarm
happens. This process is limited to one in the entire system.
A panel on X-window is displayed when the process
starts. The panel has on/of buttons for each equipmentgroup.
The voice alarm process watches the on-line alarm tablein 5 second cycle. It issues a Remote Procedure Call (RPC)
to a voice synthesizer to say a simple message like “alarmat magnet group” when an alert happens.
The messages continue in 10 second cycle. An operator
can pause them for 120 seconds pushing a group button on
the panel. However it does not end until the alarm stops.
We did not employ “acknowledged and don’t say anymore”
strategy because we are afraid operators would forget thealarm.
5.4 Alarm display
The alarm display process shows alarm status graphically, statistics of alarm and detailed information for signals
as shown in Figure1.
Unlike the alarm watch process, unlimited number ofalarm display processes can run everywhere on the SRcontrol network.
The alarm display process shows one X-window basedpanel which consists of three parts i.e. graphics, statistics
and signal names. A clock is also displayed to check theprocess running.
Operators can see alarm status at a glance with a graphicalpart of the panel. The graphics illustrates the SR with thevacuum cell, the magnet power supply stations and theRFstations. Troubled parts fill with either red or yellow.

Figure1. Alarm display
The statistical part of the display shows number ofwarnings, alerts and their sum grouped by equipment
subgroups. Operators can also see a graph of number ofalarms vs time.
The names of alarmed signal are displayed in the signalname part. When an operator points and clicks the name ofalarmed signal with a mouse, detailed information about thesignal like the current value, the alarm conditions and the bit
information are displayed on another pop-up window.
5.5 WWW
Equipment specialist cannot see the alarm display panel
from the outside of the SR control network because it isprotected by the firewall. We built another way to see thealarm status from WWW. Although it has no graphicalcapability, a user can see the current status and the history ofalarms at their office via WWW common gateway interface(cgi) programs.
6 Parameter entry
The experts set the alarm conditions to the database in twoways. One is using alarm control panel interactively but it′srather ineffective. Another is to write a spread sheet foralarm conditions. A utility program written in Python [5]converts the spread sheet file to the parameter database. The
initial alarm conditions were set by this method.
7 Conclusion
We built an alarm system for the SR system fully based on
the database system. The database system makes thestructure of the system simple and easy to extend. The alarmsystem has been in operation since March 1997. It
has been working with no major trouble. It will be extended
to watch other system like beamline and injectors.

Acknowledgments
We greatly appreciate members of Mitsui Zosen System
Research Co. Ltd., for their assistance in constructing thissystem.
References[1] T.Fukui et.al., in these proceedings of ICALEPCS ’97,
Beijing, China.

[2] A.Yamashita et.al., “The database system for Spring-8
storage ring control”, in these proceedings ofICALEPCS ’97, Beijing, China.
[3] A.Taketani et.al., “Data acquisition System with
Database at the SPring-8 Strorage Ring” in theseproceedings of ICALEPCS ’97, Beijing, China.
[4] R.Tanaka et.al., P201, The proceedings ofICALEPCS ‘95, Chicago, ILL,USA 1995
[5] http://www.python.org/