160 likes | 349 Views
CLS: An Open Source Control System. E. Matias, R. Berg, G. Wright, T. Wilson, T. Johnson, R. Tanner and H. Zhang Canadian Light Source University of Saskatchewan. CLS Control System Heritage. Saskatchewan Accelerator Laboratory (SAL) was established in the 1960s.
E N D
CLS: An Open Source Control System E. Matias, R. Berg, G. Wright, T. Wilson, T. Johnson, R. Tanner and H. Zhang Canadian Light Source University of Saskatchewan
CLS Control System Heritage • Saskatchewan Accelerator Laboratory (SAL) was established in the 1960s. • Control System evolved from PDP-8 hardware to NeXT and Sun workstations with CAMAC IO. • In 1999 the Nuclear Physics Program was discontinued and the Canadian Light Source established. • The Control System was redesigned based on EPICS using RTEMS and Linux with VME IO. • The same control system platform was deployed on the accelerator and beamlines.
CLS Control System Principles • System design based on highly distributed control. • Extensive use of Single board computers(originally used in SAL). • Target lifetime of 15+ years. • Data communication over Ethernet when possible. • Building an open source control system was not the initial goal, it was the outcome. • The result: • EPICS (with assorted tools) • Linux based operator workstations, • Low-level control implemented in PLC hardware, and • Higher level software implemented in EPICS running on RTEMS, Linux and Windows.
SIL EROC Single Board Computer and Motor Controllers • 16MB, 72 pin, 60 ns DRAM with parity • 256 kilobyte Flash memory • 10baseT Ethernet port • Can control up to 8 motors • Uses Motorola 68360 microprocessorBDM connector (background debug mode) • Console RS-232 port37 input/output connections (general purpose I/O) • 4 - RS-232 Data Ports
Linux and VME • Using VME hardware connected to a Linux pc. • SIS1100 PCI card <-> fiber optic link <-> SIS3100 VME moduleLinux and Windows support as well as others • maps VME backplane to IOC memory. • Advantages: - pc can be physically separated from VME crate. - more than one VME crate per PC - multiple applications can access the same crate. - high throughput 25 Mbytes/sec block transfer. • Work ongoing on RTEMS support.
RTEMS and CLS controller • EPICS version 3.14.beta1 running on RTEMs version 20011025(We do not use VxWorks) • IOCs are CLS/SIL embedded controllers (approx 150) - processor MC68360 25 MHz - 16 Meg RAM - 4 serial ports and console port - easy to deploy, mounts in a 19” rack • Pros and Cons: - No dynamically loaded libraries; so executable must be linked prior to download. - large number of IOCs (separation of function but more points of failure) - each requires a network drop - RTEMS is open source (FreeBSD license terms) • Problems: - possible memory incompatibility problem. - IOC connected to 5 MODBUS PLCs was overloaded.
Control Room • Existing SAL Console was reused. • Operator Workstations: • Redundant Configuration • 4 Headed Workstations • Running RedHat Linux and EPICS EDM • Augmented with workstations and touch panels in the field • EPICS Software: • EDM • Strip Chart • Matlab Channel Access • Knob Manager
Linac • Pre-existing SAL Linac was refurbished for use as an injector • 250 MeV Linac • Controls: • Older CAMAC hardware was completely replaced • Power Supplies were refurbished with Embedded EPICS controllers running EPICS and RTEMS
Booster Ring (BR1) • Danfysik Booster with CLS controls • Controls • Interfaces to Power Supplies, Vacuum Equipment uses EROCs running RTEMS/EPICS • Machine Protectionuses MODICON Momentum PLC hardware
Storage Ring (SR1) • RF Control implemented with Siemens PLC • Power Supplies, Vacuum Equipment control implemented with EROCs running RTEMS/EPICS • Matlab and Accelerator Tool box used for Online Diagnostics
Timing System • Provides Fiber Optic signal distribution of triggers • VXI based hardware • IOC running EPICS on RTEMS • OperatorInterface implemented using Glade
Beamlines • Beamline Controls are based on the same software and hardware as the accelerator systems • Each beamline is on a separate virtual network • The EPICS Gateway provides links between the different networks • Matlab is used for scripting
Interface to Administrative Systems • Administrative (Financials and Work-management) databases are based on MS-SQL. • freeTDS was used to provide an interface into these systems. • The control-system is a source of alarm-data that can be used to trigger preventative maintenance activities. • This integration is still a work in progress.
System Architecture MS-SQL Server MS-Win OPI Linux OPI Linux OPI Linux Touch Panel OPI Linux Network Server (bootp, dhcp, auto restore) Linux Data Archive Server Linux Alarm Server MS-Win VLANs for: each beamline, machine control, development, office, visitors PowerEdge IOC Linux VME Crate (Reflective Memory) EROC IOC RTEMS IOC Step Controller RTEMS PS Boards IOC RTEMS EROC IOC RTEMS IOC Linux 1Gig Bridge MicroStep Field Dev. RS-232 Devices MicroStep Power Supplies Ethernet Devices PLC & GPIB Profibus PLC Motors Field Dev. Motors Magnets Field Dev. Field Dev.
Lessons Learned • The use of open source did not compromise reliability or availability. • Configuration management is critical to the success of the system. • Layering of different software packages requires care to ensure the system is reliable. • Additional flexibility in available in managing upgrades compared to commercial software.