Content
# Project: Cambria CSD Water Ignition Phase 3
Ignition Phase 3
✅Replace Opto 22 S1 controller functions with AB Compactlogix 5069-L330ER
✅Use Prosoft Modbus TCP gateway (on site and installed) to create timed messages to each IO site
Writing messages to the IO will override live system, we will want to schedule this when ready to test
CCSD Water Project Backups IO Configs
Opto learning center PAC Control config file
The learning center IP is 192.168.102.91
Uses PAC Project 10.4c or higher
Install professional version using this password: 05Apollo18
This software provides this view:
PAC Manager provides the Modbus calculator
CCSD Water Ignition Phase 3 Tags - updated
This is the current version of IO and P&ID tags: https://docs.google.com/spreadsheets/d/12DObnBd5r5nWkdom1YDtSgJxO8dVcEX3k4dxl6IqeR8/edit?usp=sharing
Use application code manager to instantiate the process object library.
192.168.102.251 66 CCSD Water SCADA AB PLC Compactlogix
.67 is modbus gateway, linked to PLC already
Already linked to Ignition
Project Outline
1. Planning
1. ✅Develop P&IDs for system
1. ✅Overview
2. ✅Boosters
3. ✅PK
4. ✅SSWF
2. ✅Develop Tag list based on P&IDs
2. RTU List
RTU1100
Leimert
RTU1200
Pine Knolls (PK)
RTU1300
SR3
RTU1400
Stuart
RTU1500
SSWF W1
RTU1600
SSWF W2
RTU1700
SSWF W3
RTU1800
Fiscalini
RTU1900
WBE
RTU2000
SR4
RTU2100
Rodeo
RTU3000
WRF
SCADA
3. Programming
1. PLC
1. ✅IP address at live network 192.168.102.251
2. ✅IP address at dev network 192.168.1.150
3. ✅PAX Objects
1. ✅Build PAX object list in spreadsheet
2. ✅Create ACM project to create project with PAX objects
4. ✅Modules
1. ✅Create and configure Prosoft Modbus TCP module
2. ✅IP address at live network 192.168.102.67
5. Control Strategies
1. 2. Use Mason’s MCR Process Control Data Type v1.0
3. Use the PAX Objects to control the pumps, then this allows for the SCADA Hand and SCADA Auto functionality to work.
4. Allow the user to initiate an auto call, without having the change the setpoints to simulate an auto call
5. All Motors:
HOA not in Auto takes out of call service (accomplished by P_Motor object input permissive and interlock)
1. Fault takes out of call service (accomplished by P_Motor object becoming not available due to fault input)
6. SSWF (W1, W2, W3)
1. All 3 wells are called by individual on/off setpoints looking at Pine Knolls, no lead lag alternation
2. Has Ignition Edge at W2 to handle historical data to the primary gateway
7. Stuart and Rodeo Grounds Boosters
1. Rodeo Grounds Booster references Stuart St. Tank Level
2. Stuart St Tank Level references Fiscalini Tank Level
3. Both Boosters are the same
4. 2 Pump Boosters, lead lag alternation
1. Lead On/Off
2. Lag On/Off
3. When building this logic, copy your process tags into tags that exist within the P_AinAdv object that they reference
4. 5. HOA not in Auto takes out of call service (accomplished by P_Motor object input permissive and interlock)
6. Fault takes out of call service (accomplished by P_Motor object becoming not available due to fault input)
8. SR3 and SR4 Well Call
1. Both wells are called by individual on/off setpoints looking at Pine Knolls, no lead lag alternation
1. SCADA_TO_SR4_DATA[0].0 is the SR4 SCADA Auto Call
2. There is an interlock that WBE level must be greater that x (3.0ft)
2. Even though SR3 is not functional, write the logic to call it anyway.
3. Both SR3 and SR4 are individual self controlled treatment plants
1. SR4 has been updated and is running its own Ignition Edge Project that is linked to the Ignition gateway to provide historical data and alarms
2. SR3 has not been updated and runs on Opto 22 PLC, using Ignition edge only as a historical data handler
4. Communications - reference CCSD Water Project Backups IO Configs
1. Reference this spreadsheet for IO Point correlation with Modbus addresses
1. https://docs.google.com/spreadsheets/d/1v5gXvtNvfIo58OJE3jPbdhaI5_uVJG3G/edit?usp=drive_link&ouid=105974013212587964753&rtpof=true&sd=true
2. Andy to get screenshots of IO config within Opto 22 PAC Control
2. Andy - Use Page/Embedded/Comms page to develop UI on
3. How does the Prosoft handled method handle these things:
1. Create Program that creates sequential messaging (message RTU 1100, and once it gets DN or ER, move on to RTU1200) to each RTU with the following features:
1. Polling time between cycles display
1. Alarm if greater than 60 seconds or count the errors, greater than x, lets pick one
2. Escalating attempt intervals (user editable, global intervals: internal 1- 10 seconds, interval 2 60 seconds, interval 3 300 seconds)
3. Ability to disable polling a particular RTU by user
4. Andy - WRF is an Allen Bradley Compactlogix Controller that can be messaged explicitly, this is what the Opto 22 controller is doing now, we can replace that functionality with the new SCADA controller, all other RTUs are Opto 22 SNAP PAC R1 or EB1 controllers.
Prosoft Device Status and Error Codes info @end of document
4. Alarms:
1. Stale data alarm
2. Tie in Comm fails into each device IO Fault on the PAX object that it is affected by
5. Andy - Database tags
1. Export Existing Ignition tags,
2. Export PLC tags
3. Let Claude update the OPC tags with the new tags, what to do about scaling… Claude needs to reference the scaled output of the analog objects, not the modbus OPC data.
1. HMI (Human-Machine Interface) Additions
* Get alarms working right again
* Make sure users are in the user source
* Test alarms text and call
* Update trends everywhere
* Reports
* Integrate P&ID’s into HMI somehow
* Ribbon Charts for Pump Status 1
* ✅Import Resource
* Andy - ☐ Configure a ribbon chart for any motors in a given loop
* Andy - ☐ Implement a separate ribbon chart on each loop section that contains pumps4.
* Alarm Analysis Tool 5
* ✅Import Alarm Analysis Tool
* Andy - Look into Alarm Description to be referenced, not tag name
* System Diagnostics Screen 8
* ✅Import System Diagnostics resources
* Andy - ☐ Make sure appropriate systems are included or excluded from old configurations
2.
Mobile User Interface (UI)
* ☐ Develop a mobile-friendly version of the SCADA project12.
3.
Andy - Reporting
* Gallons Per Day (GPD) Report 16
* ☐ Create a new report that details the GPD for each individual well site17.
* Daily Production Report 18
* ☐ Configure the system to automatically generate a production report every day for the preceding 24-hour period19.
* ☐ Implement a real-time display showing a rolling 24-hour production total20.
* ☐ Ensure the real-time production data is pulled into Ignition, historized, and updated every 15 minutes21.
* Daily Demand Report 22
* ☐ Configure the system to automatically generate a demand report every day for the preceding 24-hour period23.
* ☐ Implement the demand calculation:
Demand = Total Production - Change in Total Storage24.
* ☐ Create a real-time display showing a rolling 24-hour demand result25.
* ☐ Ensure the real-time demand data is pulled into Ignition, historized, and updated every 15 minutes26.
Tank storage volumes as function of height
Tank Site
Tank Qty.
ID Tank 1, ft
ID Tank 2, ft
Vol/ ft H, Tank 1
Vol/ ft, Tank 2
Tot. Vol./ ft, gal
Pine Knolls
2
52 ft
52 ft
15,886.5 gal
15,886.5 gal
31,772.9 gal
Stuart St.
2
40 ft
30 ft
9,400.3 gal
5,287.7 gal
14,687.9 gal
Fiscalini
1
46 ft
0 ft
12,431.9 gal
0.0 gal
12,431.9 gal
Leimert
1
38 ft
0 ft
8,483.7 gal
0.0 gal
8,483.7 gal
D = P - ΔV
(System Demand t0-t1) = (Total Production t0-t1) - (Change in Total Storage t0-t1)
Where (Total Production t0-t1) is the sum of production from all sources between time 0 and time 1 in MG; and,
(Change in Storage) t0-t1 is the total change in volume in storage between time 0 and time 1 in MG, calculated as Vol at t=1 minus Vol at t=0
E.g.
Demand Aug 1st. = Production Aug. 1st - (Vol Aug 1st - Vol Jul 31st)
Prod Aug 1st = 5 MG
Vol in storage Aug 1st = 11 MG
Vol in storage Jul 31st = 12 MG
(between Jul 31st and Aug 1st we lost 1 MG from storage
Demand Aug 1st = 5 - (11-12) = 6 MG
4. System Resiliency and Alarming
* Disaster Recovery Solution 27
* ✅Procure a new 24" industrial panel mount touchscreen28.
* ☐ Install the new touchscreen and PC at the Pine Knolls site, replacing the existing Windows 7 machine29.
* ☐ Configure the new panel to be ready for an automated gateway backup restoration from the off-site hard drive30. The goal is to enable full SCADA control from Pine Knolls in an emergency31.
* ☐ Move the NAS and Backup PLC to pine knolls
* Watchdog Alarms for State Reporting 32
* ☐ Integrate watchdog alarms for every individual tag associated with state reporting data33.
* ☐ Program the watchdog to monitor that each tag value changes within a set time period to prevent stale data34.
* ☐ Program the watchdog to also monitor for significant value changes over a longer time period to ensure data is live and accurate35.
☐ Ensure an alarm is triggered if a tag has bad quality, even if the communication link to the controller is active36.
Standard RTU Signals: All discrete P_DIn
a. Generator
i. Generator - Normal Power Available
ii. Generator - Emergency Power Available
iii. Generator - Fail
b. Utility Power – Available (120VAC supply power to 120VAC Relay)
c. UPS
i. UPS – DC IN OK
ii. UPS – BATT OK
iii. UPS – DC OUT OK
d. Comm Status
1. Boosters
a. Suction Pressure
b. Discharge Pressure
c. Flow
i. Rate
ii. Totalizer
2. Wells
a. Well Level
b. Flow
i. Rate
ii. Totalizer
3. Pumps:
a. Output:
i. Run Command
ii. Reset
b. Input:s
i. Run Feedback
ii. Fault
iii. HOA in Auto
1. Modbus Client Command Error Codes
The most critical diagnostic for a SCADA integrator is the Command Error List. Each of the 160 possible Modbus commands has an associated error code.
* Where it lives: By default, these start in the gateway's internal database at register 4000 (this can be moved in ProSoft Configuration Builder).
* What it tells you: * 0: Success.
* 1: Timeout (Target device is down or network path is broken).
* 2-6: Modbus Exception codes (e.g., Illegal Function, Illegal Data Address).
* Implementation: Map these registers to your CompactLogix Input tags. If a register is non-zero, you know exactly which device or specific poll is failing.
2. General Module Status (Health Tags)
The gateway maintains a block of "Status Data" that provides a high-level overview of the module’s health.
* Standard Status Block: Includes the product name, revision, and uptime.
* Error Counters: Total number of Modbus messages sent, received, and errors encountered.
* Connection Status: Number of active Modbus TCP client/server connections.
* Access: In ProSoft Configuration Builder (PCB), you can use the Data Map feature to move these status registers (starting at upper memory locations like register 12000) down into the user-accessible database (0–9999) so they can be read by the PLC.
1. Setting Up the Modbus Client Command Error Codes
The manual refers to this specific feature as the Command Error Pointer. The gateway uses this pointer to define where in its internal database it should store the success/fail codes for your Modbus polling list.
Configuration Steps:
1. Open ProSoft Configuration Builder (PCB) and expand your PLX31 module tree.
2. Expand the Modbus TCP/IP Client section and double-click on Modbus TCP/IP Client 0.
3. Locate the parameter named Command Error Pointer.
4. Set this value to an unused starting register within the gateway's internal user database (e.g., 4000).
5. Click OK and download the configuration to the gateway.
How it works: The gateway will now drop a 16-bit integer error code for every command in your Client Command List sequentially, starting at the register you defined. Command 1's status will be at register 4000, Command 2 at 4001, Command 3 at 4002, and so on. A value of 0 means the poll was successful; any non-zero value represents a specific Modbus exception or timeout.
Ensure your EtherNet/IP read configuration (Class 1 or Class 3) is sized to pull this block of registers into your CompactLogix Input tags. Once the data is in the controller, you can use a MOVE instruction to pass the specific error registers into your SCADA alarm arrays, or set up a simple comparison (> 0) to trigger a communication fault.
________________
2. Setting Up General Module Status (Health Tags)
According to the PLX31-EIP-MBTCP specifications, ProSoft handles the general status data in one of two ways, depending on how you add the module to your Studio 5000 I/O Configuration tree.
Method A: Studio 5000 Add-On Profile (Recommended) The documentation notes that this gateway includes an embedded EDS Add-On Profile (AOP). If you install the AOP and add the PLX31 to your IO configuration using it, no internal mapping in PCB is required.
* Studio 5000 will automatically generate a dedicated Status structure in your Controller Tags (e.g., ModuleName:I.Status). This auto-generated block inherently contains the general module health, active connection counts, and total error counters.
Method B: Generic Ethernet Module (Manual Mapping) If you add the gateway to Studio 5000 as a "Generic Ethernet Module," you must manually expose the status data. The gateway stores its status in upper, non-accessible memory.
1. In PCB, expand the module tree and double-click on Data Map.
2. Create a new mapping entry.
3. Set the From Address to the upper memory block where the status data lives (the manual outlines specific offsets for module status vs. port status).
4. Set the To Address to an accessible user database register (e.g., 4100).
5. Set the Register Count to cover the length of the status block.
6. Verify your EtherNet/IP connection is configured to read the 4100 register block into your CompactLogix.