Development of operator interface using Angular at the KEK e-/e+ injector linac
M. Satoh †, 1, I. Satake, High Energy Accelerator Organization (KEK), Accelerator Laboratory, Tsukuba, JapanT. Kudou, S. Kusano, Mitsubishi Electric System & Service Co., Ltd (MSC), Tsukuba, Japan1
also at The Graduate University for Advanced Studies (SOKENDAI), Department of Accelerator
Science, Tsukuba, Japan
Abstract
At the KEK e-/e+ injector LINAC, the first electronic
operation logbook system was de veloped in 1995 using arelational database. This logbook system can automaticallyrecord the detailed operational status. In addition, operators
can manually input detailed information about operational
problems, which is highly helpful for future troubleshooting. In 2010, the logbook system was improved with theimplementation of a redundant database, an Adobe Flashbased frontend, and an image file handling feature. In 2011,
we started using the CSS archiver system using PostgreSQL as a backend database and a new web-based archiver viewer developed by Adobe Flash. However, withthe discontinuation of Adobe Flash support at the end of2020, it became necessary to develop a new frontend without Adobe Flash for both the operation logbook and archiver viewer systems. For this purpose, the authors
adopted the Angular framework, which is widely used forthe development of web applications using JavaScript. In
this paper, we report the development of operator interfaces
using Angular for the injector LINAC.

through Open Database Connectivity (ODBC), and an operator can enter the current operation status of LINAC in
the Japanese language. After 1999, the beam injection into
the KEKB ring started and the data size markedly increased. After that, the electrical operation logbook system
has been gradually improved. Finally, the backend database was replaced with PostgreSQL, and the frontend component, which operates within web browsers, was developed using Angular [6], a well-known web application
framework, in addition to React. Additionally, the viewer
web application for the data archiver system was also developed and has been operated using Angular.

INTRODUCTION
The KEK e-/e+ injector LINAC [1, 2] established thesimultaneous top-up injection to five independent rings in2019 to support both the SuperKEKB particle collider experiment with DR, LER and HER rings [3], and the photon
science experiment at the PF ring and PF-AR, as shown inFig. 1. It succeeded in improving the efficiency of theSuperKEKB collision experiment more than 200% before
and after the introduction of the simultaneous top-up injection [4]. This noble injection scheme became indispensable
because the beam lifetime of the SuperKEKB ring is short,especially at the LER positron ring, which was less than 10min in 2021. On the basis of this operation arrangement,
the injector LINAC has gradually improves the injection
performance and contributed to the achievement of theworld-record collision luminosity of SuperKEKB [5].
At the injector LINAC, the beam operation status and its
history have been automatically recorded with an electronic operation logbook system. In 1995, the first operation logbook system was developed with Microsoft Access(MS-ACCESS) and Microsoft SQL (MS-SQL) on the Windows 2000 server because of the easy database management and development of the user interface. MS-ACCESS
is a frontend component, and it decreases the CPU load ofMS-SQL. The console PC and MS-SQL are connected___________________________________________† email address: masanori.satoh@kek.jp

Figure 1: Layout of the KEK e-/e+ accelerator complex with beam properties from the injector LINAC
to five independent rings.

PREVIOUS OPERATOR INTERFACE
In injector operations, following the transformation of
the electronic operation logbook system into a web application in 2010 [7], Adobe Flash was extensively employedin the frontend of web applications. Flash applications offered enhanced usability and expressive capabilities compared with simple HTML-based pages. They could run on
computers with Flash Player, regardless of the operating
system, and being web applications, they facilitated easy
redistribution, significantly reducing operational complexity compared with native applications that required installation. These applications had been stably operated since
their development. However, with the discontinuation ofAdobe Flash Player support by major web browsers in2020, a transition to a new framework became imperative.
At the injector LINAC, Angular emerged as a promisingframework to replace Adobe Flash. Angular is a webapplication framework developed by a community led byGoogle, and it is well suited for building Single Page Applications (SPAs). SPAs operate swiftly, much like nativeapplications, as they transmit and receive only the necessary data without performing full-page reloads.

NEW OPERATOR INTERFACEElectronic Operation Logbook System
The electronic operation logbook system comprises a database component, an automatic operation information recording component, a user interface (UI) component, anda web page generation component for delivering operationinformation. From the viewpoint of affinity with theexisting LINAC operation software, this system was developed as application software on the Linux operating system. PostgreSQL is used as the backend database component. The system employs a redundant configuration withthree database servers, as shown in Fig. 2. For the redundant operation, we adopted the replication feature of PostgreSQL and Pgpool-II, which is a middleware that works
between PostgreSQL servers and a PostgreSQL databaseclient. Communication between the database servers andthe UI component is facilitated with PHP scripts.
The total number of application screens developed using
Angular is nine. These application screens cover functions
such as the input/edit of operation logs, the input/edit oftroubleshooting information, information retrieval, and uploading image files. As the system is constructed as anSPA, the transition between different screens is sufficiently
fast, which is very important for the usability of software.
As shown in Fig. 3, during input/edit operations, the dedicated dialogs pop up. In this popup dialog screen, the operator can upload files such as images, videos, and URLs,
or enter the detailed event contents.

Archive Viewer Web Application

Figure 2: Software block diagram of the electronic
operation logbook system.

The injector LINAC control system has been developed
using the Experimental Physics and Industrial Control System (EPICS). As a machine parameter archiving system,
the Channel Archiver, one of the EPICS tools developed atthe Spallation Neutron Source in 2004, was introduced.
However, because of the discontinuation of the Channel
Archiver development, the CSS Archiver [8] was adopted
in 2011, and the Archiver Appliance (AA) was introduced
in 2019, subsequently facilitating its operation [9]. Although both CSS Archiver and AA packages include graphing tools for archived parameters, their functionalities
are limited. To improve the usability of viewer functionality, an Archive Viewer web application was developed.
This application has the functionalities such as keywordsearches for recorded EPICS process variables (PVs), plotting multiple PVs on a single screen, plotting calculated
values from retrieved data, zooming via mouse interaction,and toggling the visibility of individual PVs. It supports up
to 10 independent vertical axes, each of which can be(a) Main page(b) Edit dialog
Figure 3: Screenshot of the web-based electronic
logbook user interface.

Figure 4: Screenshot of archive viewer web application. Archive data are plotted with five independent vertical axes.

customized with titles, font colors, sizes, and logarithmicscaling. An example utilizing five vertical axes is illustrated in Fig. 4. In addition to line graphs, scatter plots canalso be plotted, facilitating the easy examination of correlations among different PVs.
Data retrieval periods are not only specified by the exact
date and time but also allow for relative time specifications.
Through its auto-screen-update feature, the application canautomatically display the most recent historical information. It can easily work as a simple real-time monitoring
tool for the selected PVs. Moreover, since these settings
can be saved into files, application users can significantly
reduce the detailed configurations.

RF Conditioning Status Recording System
During a certain period following a prolonged machine
maintenance as in the case of the summer shut down, theinjector LINAC conducts RF conditioning. To monitor andrecord the status of 60 klystrons, an RF conditioning statusrecording system was developed. Similarly to the electronic operation logbook system, this system employs
PostgreSQL as the backend database component and Angular as the frontend UI component.
This system can manage various items, including thecurrently automatically updated klystron setting voltage
and manually input conditioning target values from the UI.
When the current setting voltage reaches the target value,
the background color of the corresponding klystronchanges to enhance the visibility of the RF conditioning
progress. Moreover, application users can fill in a detailed
description, such as the reason for changing the target values. As shown in Fig. 5, the dedicated dialogs pop up forinput/edit operations.

required much effort. To simplify the updating database
work, a web application based on a relational database formagnet information management was developed andlaunched for operation in 2022 [10].
This system, similarly to the electronic operation logbook system, employs PostgreSQL as the backend database component and Angular as the frontend UI component. Access to the system is restricted by usernames andpasswords, allowing for varying attributes to be set peruser, such as read-only access or both read and edit access.
User management is integrated with the existing LDAP
system already operating at the injector LINAC. The main
page screenshot is shown in Fig. 6. It appears after user
authentication.
In this system, approximately 100 different types of data
can be managed for each electromagnet, including thename of the electromagnet, the corresponding power supply specification, and the coefficients of the polynomial fit
for the excitation curve. Application users can freely customize the items displayed on the web browser and extract
data through filtering by combining multiple keywords as
desired. In addition to the operations of editing, adding,and deleting items directly on the web browser, the system

Figure 6: Main page screenshot of magnet information management system.

Figure 5: Screenshot of RF conditioning info editor.

Web Application for Magnet Information Management
The injector LINAC comprises approximately 600 electromagnets. The detailed device parameters such as an excitation curve and the corresponding power supply specifications were previously managed using a database basedon simple text files. Since there were several different database files in the previous system, database update work

Figure 7: Changelog page screenshot of magnet information management system.

also implements the import and export functionalities via
the CSV file format. This feature significantly reduces thetime required for updating a large amount of data.
The previously used text-based database employed fileheaders to record update histories. However, owing to
manual updates, there was a risk of incorrect or missing
entries. To avoid inaccurate historical information, the system has a feature for easily comprehending update histories. Figure 7 shows a screenshot of the information update
history page. Since this function automatically records thedetailed update histories, the historical information is morereliable than that of the previous software.

REFERENCES[1] M. Akemoto et al., “The KEKB injector linac”, Prog. Theor.
Exp. Phys, vol. 2013, p.03A002, 2013. doi:10.1093/ptep/ptt011[2] K. Furukawa et al., “Rejuvenation of 7-GeV SuperKEKB injector linac”, in Proc. IPAC2018, Vancouver, Canada, 2018,
pp.300–303. doi: 10.18429/JACoW-IPAC2018-MOPMF073[3] K. Akai et al., “SuperKEKB collider”, Nucl. Instrum. MethodsA, vol.907, 2018, pp.188–199. doi:10.1016/j.nima.
2018.08.017[4] K. Furukawa et al., “Advanced acceleration mode switchingfor simultaneous top-up injection at KEK electron/positron
injector linac”, in Proc. PASJ2020, Matsuyama, Japan, 2020,
pp.1–6. https://www.pasj.jp/web_publish/pasj2020/proceedings/PDF/WEOO/WEOOP01.pdf[5] Y. Ohnishi et al., “SuperKEKB operation using crab waist
collision scheme”, Eur. Phys. J. Plus, vol. 136, 2021, p.1023.
doi:10.1140/epjp/s13360-021-01979-8[6] Angular, https://angular.jp/.
[7] T. Kudou et al., “Upgrade of Electronic Logbook System at
KEK Injector Linac”, Proceedings of the 8th Annual Meetingof Particle Accelerator Society of Japan, Tsukuba, Aug. 1-3,2011.
[8] T. Kudou et al., “Status of Data Archive System at KEK Injector Linac”, Proceedings of the 9th Annual Meeting of Particle Accelerator Society of Japan, Osaka, Aug. 8-10, 2012.
[9] I. Satake et al., “Introduction of Archiver Appliance in KEKelectron positron injector linac”, Proc. 16th Annual Meetingof Particle Accelerator Society of Japan (PASJ2019), Kyoto,Japan, Jul.-Aug. 2019.
[10] M. Satoh et al., “Magnet information management system
based on web application for the KEK e-/e+ injector linac”,
Proc. 19th Annual Meeting of Particle Accelerator Society ofJapan (PASJ2022), Kitakyusyu (Online meeting), Japan, Oct.
2022.

SUMMARY
At the KEK e-/e+ injector LINAC, the web applications
with Adobe Flash were developed for operator interfaces,including the electronic operation logbook system, and had
been operated for a decade. However, because of the discontinuation of Adobe Flash Player in 2020, the transition
to a new framework became an urgent necessity. Therefore,
at the injector LINAC, new web applications are developed
using Angular, a web application framework developed bya community led by Google. These applications have beenstably used for daily machine operations. In the near future, we will expand the software with the similar structures to other device management software such as an accelerating structure, a klystron, and a beam monitor.