Skip to content

SCADA connector (live inflow feed)

Most models the live loop runs are rainfall-runoff models

  • they have subcatchments, so the loop drives them with the weather forecast. But a pumped sanitary or combined system modelled with [INFLOWS] hydrographs and no subcatchments cannot be moved by rainfall: its flow is the measured inflow arriving at the works. For that kind of model the live driver is the measured SCADA inflow, and the SCADA connector is how you point the loop at it.

The app tells you which case you are in: open Live Ops and read the driver badge - Weather-forecast driven or Inflow-driven (needs SCADA).

Open CSO monitoring & alerts, create a monitor for the cloud-saved project, and click its SCADA button.

  1. Map the inflow. Set the inflow tag - the SCADA signal carrying the system inflow (e.g. LSPS_Inflow) - and the model node it arrives at (e.g. LSPS_WW, a wet-well storage node). The loop compares the measured inflow at that tag against the simulated inflow at that node.

  2. Choose the driver. Recorded replay for a pilot, or Live REST historian for a production feed (see below).

  3. Set the window. The recent window (default 180 min) is the span the measured peak is taken over.

  4. Save, then turn Decisions: on so the hourly loop logs recommendations.

Live REST historian

A production feed the server polls directly - AVEVA/OSIsoft PI Web API, InfluxDB, or an MQTT / Sparkplug bridge that exposes HTTP, or a utility edge agent.

Recorded replay

A recorded SCADA export replayed against the wall clock - the way to pilot the loop on real data before wiring a live endpoint. The Warkworth pilot preset configures this.

Give a URL template and the connector substitutes the query window into it on each poll. The tokens (write them exactly, with the braces) are:

  • {tag} - the inflow tag, URL-encoded
  • {startIso} / {endIso} - the window bounds as ISO-8601
  • {startMs} / {endMs} - the same bounds as epoch milliseconds

A PI Web API stream query looks like:

https://your-historian/piwebapi/streams/{tag}/recorded?startTime={startIso}&endTime={endIso}

Then map the response shape:

  • Authorization header - e.g. Bearer … (optional; sent on every request).
  • Time field / Value field - the record fields holding the timestamp and the value. Defaults are Timestamp and Value, which match the PI Web API {Items:[{Timestamp,Value}]} shape. For InfluxDB or a custom endpoint, set them to your field names.

The connector reads the records inside the window, keeps the finite numeric ones, and takes their peak as the measured inflow.

Point the connector at a recorded SCADA CSV (a bundled sample, or your own export). It replays against the wall clock so the loop behaves as it would live; with no time anchor it uses the window around the recording’s storm peak, so a demo is always meaningful. The Warkworth pilot preset fills in the tag (LSPS_Inflow), node (LSPS_WW) and the bundled warkworth-scada.csv in one click.

On each run (hourly, or Run live decision on demand) the loop:

  1. Runs the model as-modelled to get the simulated peak inflow at the mapped node.

  2. Pulls the recent measured peak from the historian.

  3. Bias-corrects the model’s [INFLOWS] to the measured level by scaling (peak-scaling, clamped to a safe range so a stuck or spiking sensor cannot distort the run).

  4. Simulates candidate control actions on the corrected model and recommends the one that buys down the most flooding - the same simulate-before-recommend decision as the forecast path, logged to the audit ledger.

The recommendation’s trigger names the live inflow, e.g. “Live inflow 240 L/s (1.3× modelled) → …”, so the evidence trail shows what the field was actually seeing.