P5 - CDL CCM and CM Libraries
1 Introduction
CTRL Designer LLC (CDL) is a leading provider of SBC state-based control (procedural control) based on ISA106 solutions to the process industries.
Its software portfolio and work processes help process control engineers develop an overall process control design and convert it automatically to the selected control system code. These solutions allow users to make faster and smarter decisions to improve safety, reliability, efficiency, and sustainability.
The products are divided into phases:
- P1- Industrial Plant Assessment™ (IPA)
- P2- Level of Automation (LoA) [Service]
- P3- Operating Trends for Excel™
- P4- Standard Operating Procedure Analyzer™
- P5-URS-to-FRS-Builder-for-Excel™
- P6-FRS-Engine-for-Excel™
- P7-ACM-Engine-for-Excel™
1.1 CDL Folders
The CDL Package is constructed from the following Folders:
The top folder is called CDL-Product which contains
- Project
- Tools
1.1.1 Project Folder
The CDL Project folder contains:
- CDL-PmName-Project-YYYY
- PmName is the plant name such as VRT
- Project is Optional
- YYYY is the start year is is optional
- Example is CDL-VRT-2023
In this chapter the CM, CCM and CCM-CM Builder library is documented, the document is divided into three parts:
- Control Module - CM Library
- Complex Control Module - CCM Library
- CCM-CM-Builder
The Project folder contains:
- P1-IPA-Industrial-Plant-Assessment
- P2-LofA-Level-Of-Automation
- P3-OT-Operational-Trends
- P4-SOP-Standard-Operating-Procedure
- P5-URS-User-Requirement-Specification
- P6-FRS-Functional-Requirement-Specification
- P7-ACM-Automatic-Code-Maker
Each represent a PHASE of the project.
1.1.2 Tools Folder
The CDL Tools folder contains:
- A-Documentation
- B-Templates
- C-CM-CCM-Libraries
- D-Engines
- E-Issues
The C-CM-CCM-Libraries folder contains
- CCm-Library.xlsx
- Cm-Library.xlsx
The D-Engines folder contains
- CDL-P5-CCmLibrary-Builder-for-Excel.xlsm Engine
2 Control Module (CM) Library
2.1 Introduction
The control system receives inputs (AI,DI, Operator Commands) and using its predefined procedures (Code) calculate the outputs (AO, DO, Step and Alarm).
The CDL CM Library contains the following generic CM Modules.
Index | Name | Description |
---|---|---|
1 | CmAiSelector | Analog Input Selector |
2 | CmAlarm | Alarm |
3 | CmAlarmDev | Deviation Alarm |
4 | CmAnalogCalc | Analog Calculator |
5 | CmAnalogIn | Analog Input (AI) |
6 | CmAnalogOut | Analog Output |
7 | CmAnalogOutA | Analog Output A |
8 | CmAnalogOutB | Analog Output B |
9 | CmAnalyzerIn | Analyzer Input |
10 | CmBigSmall | Big Small Valves |
11 | CmCalc | Calculator |
12 | CmCalcDigital | Calculator Digital |
13 | CmCalcRateOfChange | Calculator Rate of Change |
14 | CmCalcSum | Calculator Sum |
15 | CmDigitalIn | Digital Input (DI) |
16 | CmDigitalOut | Digital Output (DO) |
17 | CmDivider | Divider |
18 | CmDoStatus | Digital Output Status |
19 | CmFlwEst | Flow Estimator |
20 | CmPID | PID |
21 | CmPIDAO | PID + AO |
22 | CmPIDC | PID Cascade >> PID |
23 | CmPIDS | PID >> Selector |
24 | CmPIDR | PID Ratio |
25 | CmSelectorAC | AC Selector |
26 | CmSelectorAO | AO Selector |
27 | CmSelectorDO | DO Selector |
28 | Spliter | Spliter |
29 | CmStep | Step |
30 | CmTemplate | Template |
31 | CmTransition | Transition |
2.2 CmAnalogIn CM Modules
The following CM are shown below:
CmAnalogIn
- General Information
- LLL - Low Low Low Alarm Information
- LL - Low Low Alarm Information
- L - Low Alarm Information
- H - High Alarm Information
- HH - High High Alarm Information
- HHH - High High High Alarm Information
- Err - Error Alarm Information
2.2.1 CmAnalogIn - General Information
Index | Parent-Element | CM-Name | Name | Initial |
---|---|---|---|---|
1 | AI | CmAnalogIn | CMVersion | 2020-11-08 HW Version |
2 | AI | CmAnalogIn | CMType | CmAnalog |
3 | AI | CmAnalogIn | GenName | [To Be Added] |
4 | AI | CmAnalogIn | GenDescription | [To Be Added] |
5 | AI | CmAnalogIn | InstanceName | [To Be Added] |
6 | AI | CmAnalogIn | InstanceDescription | [To Be Added] |
7 | AI | CmAnalogIn | AI | [To Be Added] |
8 | AI | CmAnalogIn | Normal | [To Be Added] |
9 | AI | CmAnalogIn | Minimum | [To Be Added] |
10 | AI | CmAnalogIn | Maximum | [To Be Added] |
11 | AI | CmAnalogIn | FilterTime | 0 |
12 | AI | CmAnalogIn | Input | [To Be Added] |
13 | AI | CmAnalogIn | OutPut | [To Be Added] |
14 | AI | CmAnalogIn | EnableLogic | [To Be Added] |
15 | AI | CmAnalogIn | CommandLogic | [To Be Added] |
16 | AI | CmAnalogIn | AiLockForce | FALSE |
17 | AI | CmAnalogIn | ConsequencesOfInaction | [To Be Added] |
18 | AI | CmAnalogIn | TimeToResponse | [To Be Added] |
2.2.2 LLL - Low Low Low Alarm Information
Index | Parent-Element | CM-Name | Name | Initial |
---|---|---|---|---|
19 | AI | CmAnalogIn | LLLAlmConfig | [V]True,False |
20 | AI | CmAnalogIn | LLLAlmEnableLogic | [To Be Added] |
21 | AI | CmAnalogIn | LLLAlmSeverity | [V]Low,Medium,High,Critical |
22 | AI | CmAnalogIn | LLLAlmSetpoint | [To Be Added] |
23 | AI | CmAnalogIn | LLLAlmHysteresis | [To Be Added] |
24 | AI | CmAnalogIn | LLLAlmDelayTon | [To Be Added] |
25 | AI | CmAnalogIn | LLLAlmDelayToff | [To Be Added] |
26 | AI | CmAnalogIn | LLLAlmManReset | [To Be Added] |
2.2.3 LL -Low Low Alarm Information
Index | Parent-Element | CM-Name | Name | Initial |
---|---|---|---|---|
27 | AI | CmAnalogIn | LLAlmConfig | [V]True,False |
28 | AI | CmAnalogIn | LLAlmEnableLogic | [To Be Added] |
29 | AI | CmAnalogIn | LLAlmSeverity | [V]Low,Medium,High,Critical |
30 | AI | CmAnalogIn | LLAlmSetpoint | [To Be Added] |
31 | AI | CmAnalogIn | LLAlmHysteresis | [To Be Added] |
32 | AI | CmAnalogIn | LLAlmDelayTon | [To Be Added] |
33 | AI | CmAnalogIn | LLAlmDelayToff | [To Be Added] |
34 | AI | CmAnalogIn | LLAlmManReset | [To Be Added] |
2.2.4 L - Low Alarm Information
Index | Parent-Element | CM-Name | Name | Initial |
---|---|---|---|---|
35 | AI | CmAnalogIn | LAlmConfig | [V]True,False |
36 | AI | CmAnalogIn | LAlmEnableLogic | [To Be Added] |
37 | AI | CmAnalogIn | LAlmSeverity | [V]Low,Medium,High,Critical |
38 | AI | CmAnalogIn | LAlmSetpoint | [To Be Added] |
39 | AI | CmAnalogIn | LAlmHysteresis | [To Be Added] |
40 | AI | CmAnalogIn | LAlmDelayTon | [To Be Added] |
41 | AI | CmAnalogIn | LAlmDelayToff | [To Be Added] |
42 | AI | CmAnalogIn | LAlmManReset | [To Be Added] |
2.2.5 H - High Alarm Information
Index | Parent-Element | CM-Name | Name | Initial |
---|---|---|---|---|
43 | AI | CmAnalogIn | HAlmConfig | [V]True,False |
44 | AI | CmAnalogIn | HAlmEnableLogic | [To Be Added] |
45 | AI | CmAnalogIn | HAlmSeverity | [V]Low,Medium,High,Critical |
46 | AI | CmAnalogIn | HAlmSetpoint | [To Be Added] |
47 | AI | CmAnalogIn | HAlmHysteresis | [To Be Added] |
48 | AI | CmAnalogIn | HAlmDelayTon | [To Be Added] |
49 | AI | CmAnalogIn | HAlmDelayToff | [To Be Added] |
50 | AI | CmAnalogIn | HAlmManReset | [To Be Added] |
2.2.6 HH - High High Alarm Information
Index | Parent-Element | CM-Name | Name | Initial |
---|---|---|---|---|
51 | AI | CmAnalogIn | HHAlmConfig | [V]True,False |
52 | AI | CmAnalogIn | HHAlmEnableLogic | [To Be Added] |
53 | AI | CmAnalogIn | HHAlmSeverity | [V]Low,Medium,High,Critical |
54 | AI | CmAnalogIn | HHAlmSetpoint | [To Be Added] |
55 | AI | CmAnalogIn | HHAlmHysteresis | [To Be Added] |
56 | AI | CmAnalogIn | HHAlmDelayTon | [To Be Added] |
57 | AI | CmAnalogIn | HHAlmDelayToff | [To Be Added] |
58 | AI | CmAnalogIn | HHAlmManReset | [To Be Added] |
2.2.7 HHH - High High High Alarm Information
Index | Parent-Element | CM-Name | Name | Initial |
---|---|---|---|---|
59 | AI | CmAnalogIn | HHHAlmConfig | [V]True,False |
60 | AI | CmAnalogIn | HHHAlmEnableLogic | [To Be Added] |
61 | AI | CmAnalogIn | HHHAlmSeverity | [V]Low,Medium,High,Critical |
62 | AI | CmAnalogIn | HHHAlmSetpoint | [To Be Added] |
63 | AI | CmAnalogIn | HHHAlmHysteresis | [To Be Added] |
64 | AI | CmAnalogIn | HHHAlmDelayTon | [To Be Added] |
65 | AI | CmAnalogIn | HHHAlmDelayToff | [To Be Added] |
66 | AI | CmAnalogIn | HHHAlmManReset | [To Be Added] |
2.2.8 Err - Error Alarm Information
Index | Parent-Element | CM-Name | Name | Initial |
---|---|---|---|---|
67 | AI | CmAnalogIn | ErrAlmConfig | [V]True,False |
68 | AI | CmAnalogIn | ErrAlmEnableLogic | [To Be Added] |
69 | AI | CmAnalogIn | ErrAlmSeverity | [V]Low,Medium,High,Critical |
2.3 CmPIDAO - CM Module
The following CM are shown below:
- CmPIDAO
- General Information
- AO ### General Information
Index | Parent-Element | CM-Name | Name | Initial |
---|---|---|---|---|
Index | Parent-Element | CM-Name | Name | Initial-Value |
1 | Pid | CmPIDAO | CMVersion | 2020-11-08 HW Version |
2 | Pid | CmPIDAO | CMType | CmController |
3 | Pid | CmPIDAO | GenName | [To Be Added] |
4 | Pid | CmPIDAO | GenDescription | [To Be Added] |
5 | Pid | CmPIDAO | InstanceName | [To Be Added] |
6 | Pid | CmPIDAO | InstanceDescription | [To Be Added] |
7 | Pid | CmPIDAO | AC | [To Be Added] |
8 | Pid | CmPIDAO | Normal | [To Be Added] |
9 | Pid | CmPIDAO | Minimum | [To Be Added] |
10 | Pid | CmPIDAO | Maximum | [To Be Added] |
11 | Pid | CmPIDAO | Input | [To Be Added] |
12 | Pid | CmPIDAO | OutPut | [To Be Added] |
13 | Pid | CmPIDAO | EnableLogic | [To Be Added] |
14 | Pid | CmPIDAO | CommandLogic | [To Be Added] |
15 | Pid | CmPIDAO | ManualModeLogic | [To Be Added] |
16 | Pid | CmPIDAO | ManualModeTrack | [V]True,False |
17 | Pid | CmPIDAO | AutoModeLogic | [To Be Added] |
18 | Pid | CmPIDAO | AutoModeSpTrack | [V]True,False |
19 | Pid | CmPIDAO | AutoModeSpValue | [To Be Added] |
20 | Pid | CmPIDAO | CascadeModeLogic | [To Be Added] |
21 | Pid | CmPIDAO | DevConfig | [V]True,False |
22 | Pid | CmPIDAO | Gain | 1 |
23 | Pid | CmPIDAO | Ti | 5 |
24 | Pid | CmPIDAO | Td | 0 |
25 | Pid | CmPIDAO | Direct | [V]True,False |
26 | Pid | CmPIDAO | OutMaxLimit | [To Be Added] |
27 | Pid | CmPIDAO | OutMinLimit | [To Be Added] |
28 | Pid | CmPIDAO | Sp | [To Be Added] |
29 | Pid | CmPIDAO | SpMax | [To Be Added] |
30 | Pid | CmPIDAO | SpMin | [To Be Added] |
31 | Pid | CmPIDAO | SpRampRate | [To Be Added] |
32 | Pid | CmPIDAO | OutputResponseOnFailure | [V]Freeze,Through,Predetermined |
31 | Pid | CmPIDAO | CoFreezeValue | [To Be Added] |
33 | Pid | CmPIDAO | DevConfigPos | [To Be Added] |
34 | Pid | CmPIDAO | DevConfigNeg | [To Be Added] |
2.3.1 CmPIDAO - AO Information
Index | Parent-Element | CM-Name | Name | Initial |
---|---|---|---|---|
35 | AO | CmAnalogOut | DevAlmConfig | [V]True,False |
36 | AO | CmAnalogOut | DevAlmEnableLogic | [To Be Added] |
37 | AO | CmAnalogOut | DevAlmSeverity | [V]Low,Medium,High,Critical |
38 | AO | CmAnalogOut | DevAlmSetpoint | [To Be Added] |
39 | AO | CmAnalogOut | DevAlmHysteresis | [To Be Added] |
40 | AO | CmAnalogOut | DevAlmDelayTon | [To Be Added] |
41 | AO | CmAnalogOut | DevAlmDelayToff | [To Be Added] |
42 | AO | CmAnalogOut | DevAlmManReset | [To Be Added] |
3 Complex Control Module (CCM) Library
3.1 Introduction
The CDL is designed to be object oriented. Therefor the CCM object is constructed from one to many CM. In case of pump motor example, Each DO can have zero to six DIs and one optional DO.
Therefore the control strategy for a plant is analogous to jungle, each tree has a AO or DO as a root and the control code constructed by CM are their leaf. A Um can be represented as collection of trees.
For example DO for a pump motor can have the following structure
Index | CM-Name | Cm-Type |
---|---|---|
1 | DiFBRun | CmDigitalIn |
2 | DiFBStop | CmDigitalIn |
3 | DiReady | CmDigitalIn |
4 | AiPower | CmAnalogIn |
5 | AiTemp | CmAnalogIn |
6 | DoStop | CmDigitalOut |
7 | DO | CmDigitalOut |
Assuming that UM has tree pumps, it can be represented shown below.
The Pump CCM is constructed from the DO (Root-Tag) CM and all six associated DI CMs and one DO as shown below.
Where
N: is index number of CCM library
CM-Name: is the CCM Name of the object
Class: Is the Class Name
Element: Element Name in CCM
Generic Name: The Element Name + | + CmName
The yellow color signify the optional CM and green color represent tn Root-Tag
or
3.2 Strategy
a The CDL strategy to develop code is deigned bottom up, start from the ROOT
- Identify the Root-Tags
- AO Analog Output
- DO Digital Output
Select control strategy for each Root-Tags from CCM Library for the Root-Tag
Select IO Tag from {B1-IO} sheet for each of optional CM
3.3 CCM Module List
The CDL CCM Library contains the following generic CM Modules.
Index | Name | Description |
---|---|---|
N | Cm-Name | Type |
1 | CmStep | Step |
2 | CmTransition | Step |
3 | CmAnalogIn | Cm |
4 | CmAnalogCalc | Cm |
5 | CmDigitalIn | Cm |
6 | CmAnalogOut | Cm |
7 | CmAnalogOutA | Cm |
8 | CmAnalogOutB | Cm |
9 | CmDigitalOut | Cm |
10 | CCmAiSelector | CCM-Digital |
11 | CCmBlockDo | CCM-Digital |
12 | CCmBlock2Do | CCM-Digital |
13 | CCmPump | CCM-Digital |
14 | CCmDualPump | CCM-Digital |
15 | CCmMotor | CCM-Digital |
16 | CCmAgitator | CCM-Digital |
17 | CCmFan | CCM-Digital |
18 | CCmDODivertor | CCM-Digital |
19 | CCmAiABCSel | CCM-Analog |
20 | CCmAiABCDCalc | CCM-Analog |
21 | CCmL1Cntl | CCM-Analog |
22 | CCmLC1Cntl | CCM-Analog |
23 | CCmL1AOSplitCntl | CCM-Analog |
24 | CCmL1L2Cntl | CCM-Analog |
25 | CCmLC1L2Cntl | CCM-Analog |
26 | CCmL1L2SelCntl | CCM-Analog |
27 | CCmLC1L2SelCntl | CCM-Analog |
28 | CCmL1L2AL2BSplCntl | CCM-Analog |
29 | CCmLC1L2AL2BSplCntl | CCM-Analog |
30 | CCmLC1L2AL2BSplLC3Cntl | CCM-Analog |
31 | CCmL1L2L3Cntl | CCM-Analog |
32 | CCmLC1L2L3Cntl | CCM-Analog |
33 | CCmLC1LC2L3Cntl | CCM-Analog |
34 | CCmL1>L2L3SelCntl | CCM-Analog |
35 | CCmLC1>L2L3SelCntl | CCM-Analog |
36 | CCmDistT1T2>Ovr>StmCntl | CCM-Analog |
37 | CCmDistT1T2>2Ovr>StmCntl | CCM-Analog |
38 | CCmDistT1T2>3Ovr>StmCntl | CCM-Analog |
3.4 How to Construct CCM Modules
The CCM modules are built in {CM-CM-Definition} worksheet of CCm-library worksheet.
The following are example of how to construct CCM
3.4.1 The worksheet fields (Columns)
These are the fields (Columns) of the worksheet:
- N: Index of worksheet
- Cm-Name: Cm or CCM name of the object (CmStep, CCMPump)
- Class: Name for User
- Element: Element name within CCM
- GenericName | CmName: the object internal name
Color Code
Blue: Single CM
Green: Root-Tag
Yellow: Optional or non-Root-Tag
Gray: Connections
3.4.2 CCmBlockDo - Simple CCM
The CCmBlockDo is constructed from three CM
Index | Element | CM | Type |
---|---|---|---|
1 | DiFBClosed | CmDigitalIn | Optional |
2 | DiFBOpen | CmDigitalIn | Optional |
3 | DO | CmDigitalOut | Root-Tag |
The connections are
DiFBClosed >> DO
DiFBOpen >> DO
The “-v” establishes the connection
3.4.3 CCmDualPump - Medium CCM
The CCmBlockDo is constructed from fifteen CM
Index | Element | CM | Type |
---|---|---|---|
1 | DiAFBRun | CmDigitalIn | Optional |
2 | DiAFBStop | CmDigitalIn | Optional |
3 | DiAReady | CmDigitalIn | Optional |
4 | AiAPower | CmAnalogIn | Optional |
5 | DoAStop | CmDigitalOut | Optional |
6 | DoASel | CmDOStatus | Optional |
7 | DiBFBRun | CmDigitalIn | Optional |
8 | DiBFBStop | CmDigitalIn | Optional |
9 | DiBReady | CmDigitalIn | Optional |
10 | AiBPower | CmAnalogIn | Optional |
11 | DoBStop | CmDigitalOut | Optional |
12 | DoBSel | CmDOStatus | Optional |
13 | DoSel | CmSelectorDO | Optional |
14 | DOA | CmDigitalOut | Root-Tag |
15 | DOB | CmDigitalOut | Root-Tag(M) |
The design in the {Cm-Cm-Definition} is shown below
The design in the {Drawing} is shown below
3.4.4 CCmDistT1T2>2Ovr>StmCntl - Complex CCM
This control control strategy is an example of complex CCM
The design in the {Cm-Cm-Definition} is shown below
The design in the {Drawing} is shown below
4 CCM-CM Builder Engine
The D-Engines folder contains the CCM-CM Builder Engine
- CDL-P5-CCmLibrary-Builder-for-Excel.xlsm Engine
4.1 Step by Step
There are five steps to consider:
- Select CM CCM Library folder
- Select CM CCM Libraries
- Build Parent-Child DB
- Draw CCM
- Build CCM Database
4.1.1 Step 1 - Select CM CCM Library folder
Purpose: The purpose of this step is to select the CM and CCM libraries folder in the CDL Product.
To Do Please do the following :
- Click the [01] Select Library Folder Button
- Use the explorer to select
The CDL Tools folder contains:
- A-Documentation
- B-Templates
- C-CM-CCM-Libraries
- D-Engines
- E-Issues
The C-CM-CCM-Libraries folder contains
- CCm-Library.xlsx
- Cm-Library.xlsx
4.1.2 Step 2 - Select CM CCM Libraries
Purpose: The purpose of this step is to select the CM and CCM libraries in the CDL Product.
To Do Please do the following :
- Type the Cm-Library.xlsx and CCM-Library.xlsx in cells C5 and C6
- Click the [02] Select CM and CCM Lib Button
4.1.3 Step 3 - Build Parent-Child DB
Purpose: The purpose of this step is to build Parent-Child Database.
To Do Please do the following :
- Open the CCm-Library.xlsx
- Review {CM-CM-Definition} worksheet, add new CCM
- Save it
- Click the [03] Build Parent-Child DB Button
There are 258 lines in the {CM-CM-Definition} with 296 objects (shape) and 205 connections
4.1.4 Step 4 - Draw CCM
Purpose: The purpose of this step is to draw all CCM with their associate CMs
To Do Please do the following :
- Click the [04] Draw CCm Button
- Use the explorer to select
Each CCM is drawn in a box called wrapper
The drawing is saved as a PDF file in the following folder
CDL-Products\\C-CM-CCM-Libraries\\Reports\\CCm-Library.pdf
4.1.5 Step 5 - Build CCM Database
Purpose: The purpose of this step is to build CCM data based to be used by the FRS Engine.
To Do Please do the following :
- Click the [05] Build CCM Lib DB Button
Reference