The cryogenic control system of SHINE

The Shanghai High repetition rate XFEL and Extreme Light Facility (SHINE), an advanced XFEL project, is now being built at Shanghai Advanced Research Institute (SARI), Chinese Academy of Sciences. It includes a hard X-ray free electron laser and a 100 pW intense laser facilities with overall length of 3.1 km. The XFEL part including an 8 GeV LINAC and 3 undulator lines is cooled with forced superfluid and supercritical helium at 2 K/4 K. The cryogenic system of SHINE consists of test facility cryogenic system (TFCS), accelerator cryogenic system (ACCS), and undulator cryogenic system (UNCS). A dedicated control system based on Experimental Physics and Industrial Control System (EPICS) will be built to automate the cryogenic system with process control, PID control loops, real-time data acquisition and storage, alarm handler and human machine interface. It is capable of automatic recovery as well. This paper describes details of control system structure, interfaces, controllers and the integration under EPICS framework.


Introduction
The SHINE cryogenic system is built to provide sufficient cooling at appropriate temperature levels to enable the test and operation of the superconducting components of accelerator and undulator system respectively. It is divided into three parts, TFCS, ACCS and UNCS. Each part consists of three major subsystems: cryogenic plant, distribution system and associated auxiliary systems (including Helium gas recovery, storage and purification). The TFCS will be built to test the superconducting cavity, tuner, BPM, input coupler, 2 K heat exchanger, and assembled cryomodule, etc. According to the project construction sequence, the TFCS will be the first of the SHINE cryogenic system to be designed, installed and commissioned.
The ACCS will generate and transfer all the required cooling to the LINAC containing seventy five 1.3 GHz and two 3.9 GHz cryomodules. To archive the overall 2 K cooling capacity of 12 kW, the ACCS adopts three individual cryoplants with state-ofthe-art technology. Each cryoplant could provide an approximate 4 kW cooling power at 2 K and an overall equivalent cooling power of 18 kW at 4.5 K. Accordingly, the LINAC will also be divided into three strings: the upstream string, the midstream string, and the downstream string. The accelerator cryoplants (ACCP) will be located at the two ends of the LINAC (around 2 km distance). Among three cryoplants, two cryoplants will be installed at the beginning of the LINAC to feed the upstream and midstream string by independent cryogenic distribution systems, and the third one will be located at the end of the LINAC to feed the downstream cryomodule string [1]. The layout of SHINE ACCS and LINAC are shown in Fig. 1 as follows: The UNCS will provide the cooling to the 40 Superconducting undulators. The cooling requirements of undulators are rather different from the cryomodules. Therefore, a separate conventional 4.5 K Helium cryoplant with additional sub cooling and circulating system will be designed and constructed to fulfill the cooling requirements of the undulators. At current stage, our design and construction only focus and cover ACCS part.
The UNCS and ACCS will share a common Helium gas recovery, purification, and inventory system. Separate liquid Helium storage Dewar will be equipped for those three plants to serve as a thermal buffer in one aspect and provide liquid Helium to the experiment station in the other aspect. The TFCS contains a separate gas storage and purification system, however, it could be linked to UNCS and ACCS by distribution lines.
The control system is aimed to implement all devices control and integerates them all. For each sub cryogenic system, refrigerator cold box will be purchased from the vendor-ALAT Company, which performs the cryogenic plant control through Siemens PLCs, mainly model is S7-1500, Profinet and WinCC software. The controls of auxiliary systems supplied by domestic manufacturers is assigned by using Siemens PLCs too. Other controls, such as distribution system, vacuum, etc. are designed and implemented by SARI using Siemens S7-1500/et200SP model PLCs. Up till now, TFCS is being installed and on commissioning at the end of 2020, so next chapters will focus on more details on TFCS control system. Since the whole cryogenic controls is designed scalable, the whole system will be easy to expand based on technical verification after TFCS station construction.

Control system overview
The cryogenic control system for SHINE is designed to clarifying subsystems including helium compressors, refrigerators, auxiliary subsystems, distribution subsystem, liquid nitrogen, vacuum subsystem, interlock safety, etc. These sub systems can be installed and tested separately and combined into the top control system to accomplish supervisory control, automation, and operational analysis. All essential parameters for the operation of the cryogenic plant shall be monitored and controlled complying with the SHINE technical and safety specifications. Also, the cryogenic control system should be designed to interface with the SHINE central control system. To achieve stability, flexibility, high performance and minimize long-term costs of maintenance for software and hardware, it will be built by using industrial controllers and based on EPICS.
As shown in Fig. 2, the control system will adopt the standard three layers control architecture to ensure scalability and avoid performance limitations. EPICS will give a set of toolkits with well-defined interfaces at both the servers and clients to enable integration and development. SIEMENS fiber Ethernet using TCP/IP protocol will be used to connect all cryogenic control devices.
At the device level, the various components, for example, sensors, actuators and measurement devices are interfaced to local PLCs with touch panel through different types of signal transition.
At the middle layer, PLC will implement most of control logic and PID cycle. Soft IOCs running EPICS runtime database accomplish signal collection from PLC, and convert them to Process Variables (PV) under the rule of EPICS Channel Access (CA) protocol. In the core of the control system, powerful Linux servers host the operational files and run other application software based on JAVA or script languages.
With this structure, remote consoles running Graphical User Interfaces (GUI) will allow machine operators to control and optimize the beams and to supervise the state of cryogenic plant in central control room. Since SHINE machine is a long distance LINAC, two key points, Long distance data transfer and scalable need to be considered precisely in system design stage.

Network
In SHINE cryoplant, ACCS (cryoplant1 and cryoplant2) is distributed in two shafts which is about 2 km far away. TFCS is about 100 m nearby cryoplant1. In TFCS, there are three halls to accommodate cryogenic devices. As shown in Fig. 3, we choose SIEM ENS Industrial Ethernet switches SCALANCEX with fiber ring to compose backbone network. 3-Layers XM408 switches can support VLAN technology to avoid network storm and full network management functions. Ring network design can reduce network failure possibility [2].
By using 2-Layer switch XC224 and some protocol converters, other field buses such as Profibus, serial bus can be reached from everywhere via Ethernet. The cryogenic control network is designed to operate standalone and integrate into the SHINE central network via EPICS CA gateway to guarantee the performance and not influenced by accelerator network. With this, remote accessing and monitoring are available by exchanging PV data between the accelerator and cryogenic systems.

Interfaces
Under Industrial Ethernet (IE) structure, all full sub control systems can be connected physically, but interfaces still need to be chosen carefully. We also add a dedicated set of PLC to take the role of all PLC master. There are several kinds of interfaces as Fig. 4: interface 1 between PLCs. With same brand SIEMENS PLC, we can use its proprietary protocol to exchange data. There is still a tiny difference between

Device control
The SIEMENS Distribution Control System (DCS) offers the software TIA Portal to be used in all PLC stations. These include configuration software, control software, advanced process control software, GUI software for remote computer and local touch panel. Almost all actuators, sensors and transducers' process variables and status information are converted to manipulable and supervisory data by PLCs. Analog/Data conversion, time restricted operation of control algorithm and disposal of input/output variables are realized by PLC as well. To those devices without strict time limit, such as some vacuum signals, circumstance monitor, etc. will be manipulate by IOC. Meanwhile, several kinds of signal condition module with Ethernet port are developed to reduce big mount of long distance cables which originally connecting to PLC rack. At present, TFCS device I/O numbers are shown in Table 1.
There are 1500 I/O numbers in the control system, under consideration of about 15% margin. In vacuum/nitrogen system, analog or gauge's value is acquired via network, here is presented as digital/network. If the value exceeds threshold, digital output will trigger warning or interlock.  All test devices havetheir own interlock signal/logic requirements and these cryostats need to be worked in parallel as possible. The interlock system design strategy is to find the balance between refrigerator shutdown and device safety. Therefore each cryostat control station adopts a separate LADDER program to implement different interlock logic combining with devices locally first. Each cryostat control station has three pairs of DI/DO signal connected to master interlock PLC. Master interlock PLC will execute more complicated safe logic and exchange interlock signals with refrigerator interlock system by electric wire. To ensure strict time limitation and easy connection, a dedicated Complex Programmable Logic Device (CPLD) module with one fiber port, sixteen electric ports and LATTICE chip is developed. With one pair of this module, electric and optical signal can be converted bidirectional in microsecond level [3]. The test results show the time from cryostat control PLC output to master interlock PLC's. Response is about several tens millisecond. Certainly, there are more interlock conditions will be tested, modified and verified during commissioning stage later.

Process control
The SHINE cryogenic system has several operational modes including cool-down, normal operation, warm-up and quench recovery. During the different operational modes, the low level control logic and loops are written in LADDER or SCL resident in PLC. While in TFCS, especially cryostat controls, the control logic and loops often need to be modified during the test stage. Generally the loops running on the PLCs must work continuously, even momentary interruptions can't be tolerated whereas a short interruption can be tolerated in IOC. Thus for those non critical controls, such as cryostats operational modes will be implemented by State Notation Language (SNL). With this, IOC reboot is allowed for maintenance and modification, PLC will keep the value of all inputs and outputs when the IOC and PLC communication is broken for a while. The EPICS PID record will be used in IOC, which not only allows easy adjustment of the loop constants and changing the loop parameters, but also provides the digital enabling interface to realize the software protection of the cryogenic system.