Professional Documents
Culture Documents
1.3 - EPICS Introduction
1.3 - EPICS Introduction
Page 1
Content
Content
1. 1. 2. 3. How does it fit into CODAC Core System? What is EPICS? Channel Access Protocol Channel Access Client Tools
Page 2
Content
Content
1. 1. 2. 3. How does it fit into CODAC Core System? What is EPICS? Channel Access Protocol Channel Access Client Tools
Page 3
Page 4
Content
Content
1. 1. 2. 3. How does it fit into CODAC Core System? What is EPICS? Channel Access Protocol Channel Access Client Tools
Page 5
What is EPICS?
CA Client
EPICS
CA Client
Channel Access Server (IOC) Process Variables:
CW S-PHT S-DLHT :VC1 CVZ -F
CA Server
CA Server
Computer Interface
Computer Interface
Thermometer
Page 6
What is EPICS?
EPICS is a Collaboration
developed collaboratively and used worldwide for scientific instruments such as a particle accelerators, telescopes and other large scientific experiments
ANL, LANL, ORNL(SNS), DESY, Gemini, ITER
What is EPICS?
CA Client
EPIC S
CA Client CA Server CA Server
Page 8
What is EPICS?
CSS BOY
CAC
CAS
CAS
Process Variables
Process Variables
Page 9
What is EPICS?/PV
Page 10
What is EPICS?/PV
Values of process variables come from EPICS records defined in the EPICS database
Apart from the values, also other record attributes can be accessed:
Alarm Severity (e.g. NO_ALARM, MINOR, MAJOR, INVALID) ) Alarm Status (e.g. LOW, HI, LOLO, HIHI, READ_error) ) Timestamp N Number of elements (array) Normal Operating Range Control Limits Engineering Unit Designation (e.g. degrees, mm, MW) CWS-PHTS-DLHT:MT2-TT.SEVR
CODAC Core System Training
Page 11
What is EPICS?/Architecture
Computer Interface
Computer Interface
Thermometer
Page 12
What is EPICS?/IOC
Inside an IOC
LAN IOC Channel Access Database Sequencer
Page 13
What is EPICS?/IOC
[EPICS-supplied]
Record Record Record
Record
Record Record
Device/Driver Support Supported Instruments Supported Instruments Supported Instruments Supported Instruments
Shared/Provided Required Optional
CODAC Core System Training
New Equipment
Page 14
What is EPICS?/Database
EPICS Databases
A collection of one or more EPICS records of various types Records can be interconnected and are used as building blocks to create applications A data file thats loaded into IOC memory at boot time Channel access talks to the IOC memory copy of the database Interface to process instrumentation Provide a common toolkit for creating applications
Page 15
What is EPICS?/Database/Records
Each field can be accessed individually by name A record name and field name combined give a the n name of a process variable (PV) A Process Variable name is what Channel Access needs to access data
CODAC Core System Training
Page 16
What is EPICS?/Database/Records
Alarms
HIGH LOW HIHI LOLO HSV LSV HHSV LLSV HYST High alarm limit Low alarm limit HiHi alarm limit LoLo alarm limit High alarm severity Low alarm severity HiHi alarm severity LoLo alarm severity Alarm deadband
Conversion
EGU LINR EGUL EGUF ESLO EOFF Engineering unit string Unit conversion control Low engineering value High engineering value Unit conversion slope Unit conversion offset
Monitors
ADEL MDEL Archive deadband Monitor deadband
Limits
HOPR LOPR DRVH DRVL High operating range Low operating range Drive high Drive low
Runtime data
Old raw value Previous value Old readback value Last Alarm Monitor Trigger Value ALST Last Archiver Monitor Trigger Value ORAW PVAL ORBV LALM
Page 17
Calculus
CALC Calculation
What is EPICS?/Database/Records
Page 18
What is EPICS?/Database/Processing
Record Processing
Record processing can be periodic or event driven Periodic: Standard scan rates are
10, 5, 2, 1, 0.5, 0.2 and 0.1 seconds Custom scan rates can be configured up to speeds allowed by operating system and hardware
Page 19
What is EPICS?/Database/Dataflow
Page 20
What is EPICS?/Example1
IOC
Process Temperature Sensor Analog to Digital Converter
Database
Analog In
ProcTemp
45.5C 51.5C
5.15V 4.55V
INP
0 100C 0 10V
Page 21
What is EPICS?/Example2
Database Processing
IOC
ADC Analog In
L1:water:temp1 INP VAL
Database
Calculation
L1:water:tempChk INPA
We have a water chiller that must be turned ON OUT INPB VAL whenever the average temperature ofDOL two ADC C: 10 temperature sensors rises above a set point. The Analog In CALC: ( (A+B)/2 ) > C set point is nominally 10 degrees centigrade.
L1:water:temp2 SCAN: 10 second INP VAL deg C
Chiller
Sensor T2
EGU:
Page 22
Device Support
Device and driver support interface hardware to the database LAN
IOC Channel Access Database Sequencer
Page 23
Page 24
What is EPICS?/SNL
The Sequencer
State Notation Language (SNL) is a C like language to S facilitate programming of sequential operations Fast execution - compiled code Common uses
Provide automated start-up sequences like vacuum or RF where subsystems need coordination Provide fault recovery or transition to a safe state Provide automatic calibration of equipment
Page 25
Content
Content
1. 1. 2. 3. How does it fit into CODAC Core System? What is EPICS? Channel Access Protocol Channel Access Client Tools
Page 26
Channel Access
CSS BOY
CSS Probe
CSS DataBrowser
Other clients
Channel Access
IOC S7PLC Thermometer Devices IOC PXI 6259 Devices IOC PCI 1588 Devices
Page 27
CSS BOY
CSS Probe
CSS DataBrowser
Other clients
3. TCP Connection Lets talk! 2. UDP Reply I have it! IOC S7PLC Thermometer Devices IOC PXI 6259 Devices 1. UDP Broadcast Sequence Who has aaa:bbb? IOC PXI 6259 Devices
Page 28
CA Client CA Server
Process Variables: CWS-PHTS-DLHT:VC1-FCVZ
CWS-PHTS-DLHT:VC1-FCVY1 CWS-PHTS-DLHT:VC1-FCVY2 CWS-PHTSDLHT:TTSPTARGET
I do.
25.5 degC
Page 29
EPICS_CA_ADDR_LIST
CSS BOY
Broadcast 123.45.1.255
Subnet 123.45.1.x
CSS Probe
CSS DataBrowser
Other clients
Ports
Default port number for Channel Access is 5064
Client side EPICS_CA_SERVER_PORT Server side EPICS_CAS_SERVER_PORT
Page 31
Content
Content
1. 1. 2. 3. How does it fit into CODAC Core System? What is EPICS? Channel Access Protocol Channel Access Client Tools
Page 32
AlarmServer
Aggregates alarm information from several IOCs
ArchiveEngine
Monitors value changes of PVs
Page 33
CSS
Eclipse-based collections of tools to monitor and operate large scale control system. The detail will be explained in another presentation.
Page 34
Page 35
Page 36
Page 37
Command-Line Tools
Useful to debug when CSS doesnt work for some reason
caget <pvname1> <pvname2> <>
Gets the value of one or more PVs
Page 38
Conclusions
Hardware support State machines Data processing System control (screens, alarms, archiving, system restore, logging)
EPICS is based on a network server/client model. All logic is defined in an EPICS database using record. Channel Access protocol is used to exchange data between servers and clients.
Page 39