1 / 88

Accelerator Controls at KEK Mainly KEKB and Linac Evolution at Tsukuba Site

< kazuro.furukawa @ kek.jp >. Accelerator Controls at KEK Mainly KEKB and Linac Evolution at Tsukuba Site. Kazuro Furukawa, KEK KEKB and Linac Control Groups <kazuro.furukawa@kek.jp> Oct. 2009. Several aspects of Evolution of the Accelerator Controls at the KEK Communication Networks

afya
Télécharger la présentation

Accelerator Controls at KEK Mainly KEKB and Linac Evolution at Tsukuba Site

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. < kazuro.furukawa @ kek.jp > Accelerator Controls at KEKMainly KEKB and Linac Evolution at Tsukuba Site Kazuro Furukawa, KEK KEKB and Linac Control Groups <kazuro.furukawa@kek.jp> Oct. 2009.

  2. Several aspects of Evolution of the Accelerator Controls at the KEK • Communication Networks • Equipment Controllers • EPICS Environments • Scripting Languages • Summary

  3. Mt. Tsukuba J-PARC (at Tokai Site) KEKB ATF STF PF-AR cERL PF Linac

  4. Accelerator / Control Systems Accelerators/Control Systems in KEK • Operational Presently • Linac, PF, PF-AR, ATF, KEKB, J-PARC • Under Construction • STF, cERL • EPICS • KEKB, … Linac PF-AR J-PARC EPICS Group KEKB PF ATF

  5. Accelerator / Control Systems Control Systems • 12GeV Proton Synchrotron (PS): Hardwire + Mini-computers • 2.5GeV Electron Linac (Linac): 8 Mini-computers + >200 Micro-computers, Optical Networks • Photon Factory (PF): Mini-computers -- Workstations • TRISTAN ~33GeV: ~20 Mini-computers, CAMAC + NODAL Interpreter • Upgraded PS: VME/VersaDOS + MAP • Upgraded Linac: Unix servers, VME, PLC, CAMAC + TCP/IP + Home-grown RPC, Tcl/Tk, Gateway to EPICS • ATF: VMS, CAMAC + V-System (Vista) • KEKB: VME, CAMAC, VXI, ARCnet + EPICS + Python, SADscript • PF-AR: the Same architecture as KEKB • PF: Many of the Components with EPICS • STF, cERL, SuperKEKB, …

  6. Accelerator / Control Systems PF, PF-AR, ATF, STF • PF-AR • Mostly the same environment as KEKB • Many CAMAC installations • PF • Moved to EPICS environment • Mainly with Linux-VME • ATF • Vista Controls environment with CAMAC • Linux and socket environment • EPICS devices • STF • Test facility for ILC • Linux, ATCA test, PLC, … • cERL • Being built for ERL development • Will share the same environment with STF

  7. Accelerator / Control Systems J-PARC at Tokai Canpus HD (hadron) 50GeV MR (0.75MW) MLF (neutron & muon) 3GeV RCS (25Hz,1MW) NU (neutrino) CCR(Central Control Room) Linac (181MeV)

  8. Accelerator / Control Systems J-PARC Controls • We started the design in 1998 • But nobody was dedicated at the beginning • EPICS was chosen • The same reason as KEKB, EPICS was successful at KEKB • IP/Ethernet-only field network was chosen • It was successful at Linac • Device support • Development was started with Network-based device supports • WE7000, FAM3 PLC, EMB-Lan etc. • Later, Integrated into NetDev by Odagiri • Mixed application environment with Java, SAD, XAL, Python • Good practice for inter-institute developments with different cultures • Under commissioning, user experiments in 2010

  9. Accelerator / Control Systems EPICS Software Environment

  10. KEKB and Linac Accelerator ATF STF PF-AR PF Linac Mt. Tsukuba B-factory: Electron/Positron Asymmetric Collider for CP-violation Study ~3km Dual-rings: Electron(8GeV - 1.4A) / Positron(3.5GeV - 1.8A) J-PARC KEKB

  11. KEKB and Linac Accelerator KEKB and Linac • KEKB B-factory: Electron/Positron Asymmetric Collider for CP-violation Study • ~3km Dual-rings: Electron(8GeV - 1.4A) / Positron(3.5GeV - 1.8A) • Stable and Robust Operation • Many Active Operation Parameters • Importance of Controls • Linac: • ~600m, 50Hz • 8GeV 2nC Electron, 3.5GeV 1.2nC Positron • Beam switchings for PF and PF-AR rings Increase of Luminosity with Crab Cavities

  12. KEKB and Linac Accelerator Increase of the Luminosity percent by percent Feb.2005 Continuous Injections May.2000 Apr.2003 Dual Bunch e+ Now, Collision with Crab Cavities and with Simultaneous Injection

  13. KEKB / Linac Controls KEKB and Linac Control Systems • Linac • Controls Upgrade, (1990~)1993 • De-facto (and International) Standards, IP-only Networks • No long Shutdown for KEKB upgrade • 3.5-times Energy increase, 10-times current increase • Three indirect User Facilities (KEKB, PF, PF-AR) • Fewer resources • KEKB • 5-year Shutdown after TRISTAN, 1994-1998 • Precision requirements were much different for KEKB • Complete transition of Controls • from Nodal at TRISTAN to EPICS+SADscript at KEKB • from Energy frontier to Luminosity frontier • Basically Single-user (Belle)

  14. Linac Network Communication Network at Linac • Fiber-optic Networks (1982~1996) • Because of High-power modulators for rf systems • ~30 Loops to connect ~300 equipment controllers • However, the fiber-optic Technology was not mature enough yet • Often Failed and Loop Topology made it difficult to identify the trouble • All IP network (1993~) • Still all Fiber-optic • (Faster Ethernet enables shorter packets and less failures) • Inherited at J-PARC Controls as well • Gradual Transition of Technologies • From FDDI + 10Base-FL to 1000Base-LX + 100Base-Fx • Redundancy (1996~) • At more than 50 Ethernet links • Helped continuous operation in spite of a failure at night • Redundant Transceivers, then Rapid Spanning-tree and HSRP/VRRP

  15. KEKB Network Communication Network at KEKB • TRISTAN • Token Ring and CAMAC Serial highways • Token ring between mini-computers • CAMAC serial highways to equipment controllers • KEKB • IP Network for EPICS • FDDI+10BaseT to GbE+100Base-Tx • Single broadcast domain • ARCNet for equipment controllers • More than 200 network segments • MXI-1/2 for VXI-based frames • 20 segments, 200 frames • Keep some CAMAC Serial highways • 10 highways, 50 crates

  16. Linac Controller Equipment Controllers at Linac • 1982~(1997) (1st generation) • 300 microprocessor-based controllers • Linked together with home-grown fiber-optic network • 1993~now (upgrade of controls) • 160 PLCs (programmable logic controller) • Linked via only Fiber-optic Ethernet/IP • Control communication with servers and program development • 1995~ (upgrade for KEKB) • Direct Fiber-optic Ethernet/IP to each Controllers • 30 VXI for rf measurement • 7 VME / 10 CAMAC for Timing (will retire soon) • 20 VME for Beam monitors, etc (will retire soon) • 2007~ (upgrade for 50Hz beam switching) • 17 (increasing) VME for fast “event” handling, timing, llrf controls, etc. • 24 Oscilloscopes with WindowsXP IOC for 100 BPMs • 10Gs/s, 50Hz acquisition, local processing with 25 calibration parameters/BPM

  17. KEKB Controller Equipment Controllers at KEKB • TRISTAN • Mostly CAMAC • Equipment group responsibility: CAMAC module and outside • KEKB • 100 VME/IOC without Analog processing • 200 VXI/MXI mainframes for 900 BPMs • 50 CAMAC crates are kept for rf and vacuum • ARCNet boards for Magnet ps. settings, and others • GPIB for Magnet ps. readback, and other measurements • PLCs for Magnet interlocks, and others

  18. EPICS at Linac EPICS Transition at Linac • Home-grown RPC at Linac (1990~/1993~) • At end of old mini-computer support • Not complete transition to EPICS yet at Linac • Mixed EPICS devices and gateways to middleware and applications • LynxOS Transition was developed (1994~1996) • To cover both RPC and EPICS with pthread, posix • Mostly working, Failed to get funding for Hardware/Software upgrade • Gateways to EPICS in several ways • Software-only IOC and Gateway (Clients to both RPC/CA) • Portable Channel Access Server of EPICS-3.12 (1995~) • Soft-IOC with device support to Linac RPC (2002~) • Redundant EPICS environment as well (2008~) • Real IOCs are increasing • PLC(rf,vacuum,magnet) and Linux, Oscilloscope(bpm) with Windows, VME(event-based llrf and timing) • RPC servers read EPICS IOCs, EPICS gateways read RPC servers

  19. EPICS at KEKB EPICS Transition at KEKB • Some candidates discussed after Nodal at TRISTAN • RPC/CORBA based control design • Reflective memory (hardware shared memory) design • No other choice than EPICS for KEKB • No man-power for control system software • The choice at SSC • International collaboration was attractive

  20. KEKB Controls KEKB Control System (Hardware) • GbE Fiber Optic Networks • Single Broadcast Domain for now • Central Control Room and 26 Local Control Rooms • VME/IOC • ~100 VME/IOC mostly with PowerPC CPU • Fieldbus • VXI thru MXI for BPM Instrumentations • CAMAC for rf and Vacuum (inherited from TRISTAN) • ~180 ArcNet network segments for Magnet Power Supplies, and other field Controllers • GPIB for Instrumentations, RS232C, Modbus+ for PLCs • Host Computers • (HP-UX/PA-Risc,) Linux/x86 Controls Server • (3 Tru64/Alpha with TruCluster) • Several Linux • Many MacOSX • (Solaris/Sparc for VxWorks)

  21. KEKB Controls KEKB Control System (Software) • EPICS 3.13.1 mainly, with increasing 3.14.9 • VxWorks 5.3.1 mainly, with increasing 5.5.1 • Hope to upgrade EPICS/VxWorks Shortly • VxWorks 6.7 is also under testing • IOC Development • CapFast, VDCT, Perl, SADscript for Database Configuration • Oracle as a backend Database (Partially) • Operational Application Development • MEDM(DM2k) for Startup • Python/Tk for Equipment Controls • SADScript/Tk for Beam Operation, etc

  22. KEKB Controls IOC and Records • There are Several Groups in KEKB • Each IOC is Assigned to a Group • MG, RF, VA, BM, etc • About 100 in Total • About 250k Records in Total • Most Groups Follow Naming Convention • Accelerator GroupName DeviceType • DeviceName • Property • Some EPICS Databases are Generated from Oracle Database

  23. KEKB Controls IOC Configuration

  24. KEKB Controls IOC Database with Oracle

  25. KEKB Controls Magnet Controls • ~5000 Magnets, ~2500 Power Supplies • No One-to-one Correspondence • Basic Controls thru ARCnet • Voltmeter Scanner for Analog Read-out • PLC for Interlocks • IOC Manages All Controls • Interlock Status, On/Off, etc • Energy - Field - Current • Synchronous Operation • for Tune change, Orbit Correction, etc. • Standardization • Special Large Subroutine Record • “hugesub” Record and C Routine

  26. KEKB Controls Magnet Controls

  27. Linac Controls Linac Controls • KEKB = Factory Machine => Reliable Operation • Controls should be Robust and Flexible • ~1000 devices and ~10000 signals • Frequent Beam Mode Switches • Four very Different Beam Modes, 360 times/day • Now 20ms switching with event-based controls • Precise Controls of Beam Parameters • Energy, Orbit, Emittance, Charge, Energy spread, Timing, etc.

  28. Linac Controls History and Design Concept • History • 1978-1982: Construction of First Computer-controlled System with 8 mini-computers, >200 micro-computers, >30 optical loop networks • 1989-1992: Design of the next system • 1993-1997: Installation and expansion for KEKB • Design Concept • Use of International and/or de-facto Standards • Use of Optical IP Networks for every Device controllers • No new field Networks, only IP Network (to be inherited by J-PARC) • Both of above should make future upgrade easier • (EPICS was not available widely at that time)

  29. Linac Controls Physical Structure • Multi-tier, Multi-hardware, Multi-client, …

  30. Linac Controls Multi-tier Logical Structure

  31. Linac Controls Software Architecture (old) • Base control software structure for Multi-platform • any Unix, OS9, LynxOS (Realtime), VMS, DOS, Windows, MacOS • TCP - UDP General Communication Library • Shared-Memory, Semaphore Library • Simple Home-grown RPC (Remote Procedure Call) Library • Memory-resident Hash Database Library • Control Server software • Lower-layer servers (UDP-RPC) for control hardware • Upper-layer server (TCP-RPC) for accelerator equipment • Read-only Information on Distributed Shared Memory • Works redundantly on multiple servers • Client Applications • Established applications in C language with RPC • Many of the beam operation software in scripting language, • Tcl/Tk • SADscript/Tk

  32. Linac Controls Why EPICS in my case • We made too much effort on duplicate development on many control systems • Our goal is to achieve high performance in the accelerator and the physics experiments • Reuse of available resources is preferable • Devices in Linac have been modernized, and development of EPICS device supports became possible • Anyway we need interface to down-stream accelerators esp. KEKB • Want to merge several archive formats in Linac • May expect (?) man-power from other groups • May contribute to world-wide EPICS collaboration

  33. Linac Controls Building EPICS Gateway • Common Control System at the Top (of Linac and Ring) • Needs too much resources • Port EPICS onto our VME/OS9-LynxOS (1994) • Failed to get support/budget for LynxOS at Linac • (EPICS Maintenance with an unsupported Platform ?) • Special Gateway Software, which interfaces to both the Linac Controls and EPICS IOCs as a Client • Built to ensure the feasibility at 1995 • Portable Channel Access Server • Implemented with EPICS 3.12 and being used on HP-UX since 1996 • It is being used for several application software including Alarm display • Software IOC with 3.14 • Being used and being extended on Linux since 2003

  34. Linac Controls Use of Existing EPICS IOC (Gateway IOC) • Software availability • Portable Channel Access Server was not available at around 1995 • Channel Access Server Emulation with Available Software Components • New gateway software which is clients to the both Linac and EPICS, and group of EPICS soft records • Real-time Operation is possible both ways using Monitors • Tested for Magnet Controls • MEDM panels were written Gateway

  35. Linac Controls Portable Channel Access Server (PCAS) • Protocol Conversion • Client to Linac Controls with Home-grown RPC and Cache Memory, Interface to Upper-level Servers (not directly to Lower-level Hardware Servers) • Server to EPICS environment, with some Name wrapping • Implemented for Linac in 1996- • for Magnets, RF, Beam Instrumentations • >4000 Records are available • Write-access Possible, normally Read-only • Still used for KEKB Unified Alarm,Operation Status, etc. CA Server

  36. Linac Controls Soft IOC • IOCcore is available on Unix in EPICS 3.14 • We have Tru64unix, Linux, HP-UX • Simple • IOCcore hides the complexity of Channel Access, etc • We design the device support to Upper-level Linac Servers, as we access to hardware in normal IOC • All standard EPICS facilities are available • Alarms, Operation Limits, Links, Periodic processing, Monitors, etc. • Implemented for Linac on Linux since 2003 • For RF, Beam Instrumentation, Vacuum, etc. • >5000 Records are available and extending • Most records are archived in Channel Archiver and KBlog • KBlog is used to analyze correlations between Linac/Ring • (Developed Java viewer of the archive at One Time) • Channel Archiver/Viewer from SNS is used for Linac Internals

  37. Linac Controls General Comparisons • Symmetry • Gateway IOC is Symmetric between outside and inside of EPICS • Accessing from/to EPICS goes thru the same Gateway • Others are (somewhat) asymmetric • Name Resolution • PCAS can resolve names dynamically (at run-time) • Consumes less memory (?) • SoftIOC has to be prepared with static database • May be expected to give better response • Can be impossible for a large installations • Database processing and associate fields • SoftIOC provides EPICS database Facilities like Limits, Alarms, Links, etc. • If we archive them, Archive Deadband is most necessary • Implementation of Gateway • SoftIOC is relatively straight forward • Simply adding device supports

  38. Linac Controls Application software • Most records from the Linac Soft IOC are archived both in Channel Archiver and in KBlog • KBlog is used to analyze correlations between Linac/Ring • (Developing Java viewer of the archive) • KEKB Alarm is connected to Linac PCAS • May migrate to Linac SoftIOC (Linac PCAS is currently based on EPICS 3.12) • Some other applications utilize PCAS as well • (Many others access Linac Controls directly now) • Small number of Records are going thru Gateway IOC, historically

  39. Linac Controls Performance • EPICS Gateway and Channel Archiver • are Running on Linux 2.4.20 (Redhat) with Intel Xeon 2.4GHz and Memory of 2GB • About 10% of CPU usage • Monitors/Archives all of ~2200 Channels (partial in Kblog) • Can process 5400~6600 Channel Access Requests over Network • Archive size is about 400MB/day (300MB/day in Kblog) • Both Channel Archiver and KBlog collect Data

  40. Archiver Archiver/Logger • Linac • Several archivers with group-dependent filters • Replaced with two EPICS archivers (2000~) • Channel archiver, with Java viewer, and Web-based viewer • KEKBlog, SADscript-based viewer • Both ~500MB/day, Dynamic ADEL changes • KEKB • KEKBlog, since 1998 • Once there was a plan to replace it with Channel Archiver • Data conversion, no much performance difference • Only ADEL-based filter • ~4GB/day • SADscript-based viewer, one of the most-used applications in controls • With Data analysis capability, easy manipulations

  41. Scripting Language Scripting Languages • Heavy use because of rapid prototyping • Linac • (1992~) Tcl/Tk as Test tools on Unix • (1997~) Tcl/Tk as Main Operator Programming Tool • Mostly replaced Windows/VisualBasic-based environment • (Now) Mixture of Tcl/Tk, SADscript/Tk, Python/Tk • SADscript has most accelerator design capability • Covers most features like MATLAB, Mathematica, XAL, MAD • KEKB • (Nodal interpreter and Fortran covered everything at TRISTAN) • Python covers many areas which is not covered by medm • SADscript is used by operators and physicists everyday • Realization of novel ideas in hours • Only some ideas are effective, so rapid prototyping is important

  42. KEKB and Linac Operation SADScript • Accelerator Modeling Environment • MAD-like Environment was created during TRISTAN • Needs for Conditionals, Flow-controls, Data manipulations, Plot, GUI • Mathematica-like Language introduced as a front-end • Not Real Symbolic Manipulation (Thus fast) • Data Manipulations (Fit, FFT, …), List Processing (Mathematica-like) • EPICS CA (Synchronous and Asynchronous) CaRead/CaWrite[ ], CaMonitor[ ], etc. • Tk Widget • Canvas Draw and “Plot” • KBFrame on top of Tk • Greek Letters, Compound widgets, etc • Relational Database • Inter-Process Communication (Exec, Pipe, etc) System[ ], OpenRead/Write[ ], BidirectionalPipe[ ], etc. • Beam Operation with Full Accelerator Modeling Capability • Online and offline under the same environments • Also Used for non-Accelerator Applications (Archiver viewer, Alarm handler, etc.) • Comparable to XAL, MATLAB, but very different architecture

  43. KEKB and Linac Operation SADScript • Mathematica-like Language • Not Real Symbolic Manipulation (Fast) • EPICS CA (Synchronous and Asynchronous) CaRead/CaWrite[ ], CaMonitor[ ], etc. • (Oracle Database) • Tk Widget • Canvas Draw and Plot • KBFrame on top of Tk • Data Processing (Fit, FFT, …) • Inter-Process Communication (Exec, Pipe, etc) System[ ], OpenRead/Write[ ], BidirectionalPipe[ ], etc. • Greek Letter • Full Accelerator Modeling Capability • Also Used for non-Accelerator Applications

  44. KEKB and Linac Operation SADScript • Data manipulation/plot example FFS; w=KBMainFrame["w1",fm,Title->"t1"]; $DisplayFunction=CanvasDrawer; W1=Frame[fm]; c1=Canvas[w1,Width->600,Height->400, Side->"top"]; Canvas$Widget=c1; data = {{0,0}, {1,1}, {2,5}, {3,8}, {4,10}, {5,7}, {6,4}, {7,2}, {8,0}, {9,2}} fit = FitPlot[data,a Sin[x b + c] + d, x, {a,5},{b,1},{c,1},{d,5}, FrameLabel->{"X","Y"}]; phase = StringJoin["Phase : ", (c/.fit[[1]]) 180/Pi, " Deg."]; f1=KBFComponentFrame[w1,Add->{KBFText[Text->phase]}]; TkWait[]; Exit[];

  45. SADscript Virtual Accelerator in SADscript • A Example in KEKB • most Beam Optics Condition is maintained in the Optics Panel • Other Panels Manipulate Parameters Communicating with the Optics Panel (Oide, Koiso, Ohnishi et al) • ===> • Tune Measurement/Changer Optics Panels

  46. KEKB and Linac Operation KEKB Commissioning Groups • Formation of Commissioning Group (KCG) • Linac Commissioning (LCG) • 7 from Linac • ~10 from Ring • KEKB Ring Commissioning Group (KCG) • All LCG • ~20 from Ring • Several from Detector (BCG) • Commissioning softwarebase was formed during Linac Commissioning (1997~) Tcl/Tk, SAD/Tk , Python/Tk KEKB Commissioning Group Linac Commissioning Group KEKB Ring Linac

  47. KEKB and Linac Operation KEKB Alarm Panel • KEKB Alarm Main Panel covers Linac Alarms as well. ~10,000 Records are Monitored in One Panel. Detailed alarm information/history is available in a separate panel Linac Ring

  48. KEKB and Linac Operation Beam Optics Panels in SAD • Beam Optics Matching and Optimization Panels in SADscript • Some Parameters goesthru EPICS Gateways, others directly to Linac

  49. KEKB and Linac Operation KEKB Operation Panel Examples • Tune Measurement and Tune Changer

  50. KEKB and Linac Operation Virtual Accelerator in KEKB • Tune/Optics Server • Keep A Model of Real Accelerator • Can Change Tune, Chromaticity, etc, on Request by Other Panels • Act as a Virtual Accelerator

More Related