ELT CII Core Integration Infrastructure Pres 1 15









































- Slides: 41
ELT CII Core Integration Infrastructure Pres 1: 15 MAL 0: 25 Config 0: 15 OLDB 0: 10 Error 0: 10 Log 0: 05 Alarms 0: 05 Telem 0: 05
CII Overview Ø Communication Ø ICDs Ø MAL Ø Services Ø Configuration Ø Online Database Ø Logging Ø Alarm System Ø Telemetry Instrument Control Systems Seminar 2019 2
MAL Middleware Abstraction Layer Documentation: ELT Control Software / MAL
MAL Overview is Library for Communication Ø ICD Definition Language Entities, Interfaces, Exceptions, Qo. S, … Ø Communication Patterns Ø Pub/Sub (Loan, Multi-/Single-Thread) Ø Req/Rep (Futures, Multi-Reply) Ø Middlewares/Protocols DDS, ZMQ, OPC UA, MUDPI Ø Available in Cpp, Java, Python Instrument Control Systems Seminar 2019 4
MAL Workflow Developer Workflow Ø 1. Write ICD Ø in XML File Ø 2. Build ICD Ø with ELT Build System Ø 3. Write Application Ø uses the ICD Can combine ICD and Application into one Instrument Control Systems Seminar 2019 5
MAL Write ICD Entities Interfaces Qo. S Instrument Control Systems Seminar 2019 6
MAL Build ICD Ø Behind the scenes of building an ICD XML File waf build ICD Library Instrument Control Systems Seminar 2019 7
MAL Communication Patterns Supported Communication Patterns Ø Req Rep Stub/Skeleton Design Ø Pub Sub or Poll (or Read, …) Instrument Control Systems Seminar 2019 8
MAL Middlewares Supported Middlewares/Protocols Ø DDS Ø typically over UDP, inter-application Ø ZPB (= ZMQ & Protocol Buffers) Ø over TCP, inter-application Ø OPC UA Ø over TCP, device access Ø MUDPI Ø over UDP, low-latency Instrument Control Systems Seminar 2019 9
MAL Languages Available in 3 Languages Ø Cpp Ø Java Ø Python Binds to Cpp Instrument Control Systems Seminar 2019 10
Configuration Service Documentation: ELT Control Software / Services
Configuration Service Overview Characteristics Ø Configs are Documents, Access is Type-Safe Ø Rich Data Types with Meta. Data Ø Remote DB and Local DB Ø Querying over the DB Instrument Control Systems Seminar 2019 12
Configuration Service Config Class Config Instance (aka Target Config) instance : Time. Check. Cfg hh mdi: Int 8 Std value: 15 Config Point mm mdi: Int 8 Std value: 50 Config Point Time. Check. Cfg (extends Cii. Config. Class) hh : Md. Int 8 mm : Md. Int 8 Ø Each Config Point (= Leaf Node) carries a value and Metadata Instrument Control Systems Seminar 2019 13
Configuration Service Meta. Data Config Instance instance : Time. Check. Cfg hh mdi: Int 8_023 value: 15 mm mdi: Int 8_059 value: 50 Config Point Meta. Data Instances Int 8_023 : Md. Int 8 min. Value: 0 max. Value: 23 default. Value: 0 Time. Zone : Md. String allowed: [GMT, CET] default. Value: CET Ø Each Config Point carries a value and Metadata Ø Meta. Data: unit, min-val, max-val, default-val Ø Meta. Data is reusable Instrument Control Systems Seminar 2019 14
Configuration Service Define own Meta. Data Ø Can define own Meta. Data Ø Meta. Data organised as Instances and Classes, too Config Class Meta. Data Class File. Server. Cfg (extends Cii. Config. Class) rootdir : Md. Path (extends Md. String. Class) filesystem: STRING valid: BOOLEAN Config Instance instance : File. Server. Cfg rootdir: mdi: Log. Files value: “/mnt/log” Config Point Instrument Control Systems Seminar 2019 Meta. Data Instance Log. Files: Md. Path filesystem: “ext 4” valid: true default. Value: “/var/log” 15
Configuration Service Example 1/3 1. 2. 3. 4. 5. Define Config Class Build Define Config Instance Deploy Use Config Class $ waf build Instrument Control Systems Seminar 2019 16
Configuration Service Example 2/3 1. 2. 3. 4. 5. Define Config Class Build Define Config Instance Deploy Use Instrument Control Systems Seminar 2019 Config Instance 17
Configuration Service Example 3/3 1. 2. 3. 4. 5. Define Config Class Build Define Config Instance Deploy Use Instrument Control Systems Seminar 2019 18
Coffee Break Instrument Control Systems Seminar 2019 19
Online Database Documentation: ELT Control Software / Services
Online Database Overview Characteristics Ø Read, Write, Subscribe Ø CII Built-in Data Types with Meta. Data Ø Calculation Engine Instrument Control Systems Seminar 2019 21
Online Database CRUD Create, Read, Update, Delete operations Ø From Cpp, Java, Python Create. Datapoint(…), Get. Data. Point(…)->Read. Value(), … Ø From GUI oldb. Gui Ø From Command Line oldb. Read, oldb. Write, oldb. Subscribe Instrument Control Systems Seminar 2019 22
Online Database Meta. Data Like for Config Points Ø Meta. Data: unit, min-val, max-val, default-val, … Ø additionally: timestamp, max-age, quality, formula, … Ø Can define own Meta. Data Instrument Control Systems Seminar 2019 Like for Config Points 23
Online Database Calculation Engine Characteristics Ø Processes formulas Ø terms, logical, procedures, … Ø Computes values and quality Ø Can modify formulas at run-time Instrument Control Systems Seminar 2019 24
Online Database CE - Formulas Ø Data. Point. Meta. Data. Quality is set by a Writer, or calculated by Formula if (CURR_TIMESTAMP() < PREV_TIMESTAMP() + 5000) SETQUAL(OK) else SETQUAL(SUSPECT) endif Ø Data. Point. Value is set by a Writer, or calculated by Formula sin(deg 2 rad(${/root/child/motor/decoder_position})) Can define own functions: sin 2 deg(…) {…} Instrument Control Systems Seminar 2019 25
Error Handling Documentation: ELT Control Software / Services
Error Handling Overview Characteristics Ø Auto-Fill Ø Error Codes Ø Error Handling is Exception Handling Instrument Control Systems Seminar 2019 27
Error Handling is Exception Handling 1/2 Error Handling is Exception Handling, with additions. Define Throw Instrument Control Systems Seminar 2019 28
Error Handling is Exception Handling 2/2 Error Handling is Exception Handling, with additions. Stack (= catch + wrap + throw) Log Output Instrument Control Systems Seminar 2019 29
Error Handling Auto-Fill Ø Auto-filled Information Stack Trace, Line No, Host Name, … Ø Java and Python: automatic Ø Cpp: by Macro Instrument Control Systems Seminar 2019 30
Error Handling Error Codes Ø Error Code Ø is the fully-qualified class name Ø Error Code Repository Ø exceptions defined in dedicated SVN/GIT modules Ø indexing service Ø index stored in EA database Ø query-able through REST search. Exceptions <code> --remote Instrument Control Systems Seminar 2019 31
Log Documentation: <pending>
Log API Uses widely known APIs Ø Cpp: log 4 cpp Ø Java: log 4 j Ø Python: python logging Ø Output Format: same for all languages Instrument Control Systems Seminar 2019 33
Log Transport Not yet implemented Re-uses existing solution: ELK Instrument Control Systems Seminar 2019 34
Alarms Documentation: <pending>
Alarms Overview Characteristics Ø Alarm conditions modifiable at run-time Ø by Operator or SW Support Ø Alarms must be acknowledged Ø and counter-action triggered Ø Alarms can be shelved Ø per GUI Ø Alarms persist Ø through system restart Ø keep history for analysis Instrument Control Systems Seminar 2019 36
Alarms Transport / Persistence Software is currently in design phase Instrument Control Systems Seminar 2019 37
Telemetry Documentation: <pending>
Telemetry Overview Characteristics Ø Monitor Points Ø CII built-in data types (Int 8, Int 32, String, Float[], …) Ø Receives Monitor Points Ø from Applications Ø from OLDB Ø Stores Monitor Points Ø with time stamp, quality, address, units, … Ø in long-term database Instrument Control Systems Seminar 2019 39
Telemetry Service Software is currently in design phase Instrument Control Systems Seminar 2019 40
Thank you Instrument Control Systems Seminar 2019 41