wrps-demo-kit/03-plc/register-map.csv
Clio Liu dca7797d68 feat(plc): ST sources, generators and the Modbus contract
The PLC program from the old repo's 04-plc/, flattened into one folder and
checked against the running system.

Verified during the move:
  - build.py regenerates register-map.csv byte-identically (69 points)
  - polled the live PLC: the SIMULATION build is what is deployed and
    running, %MW21=2 wet weather, values moving, run hours accumulating
  - addresses, %MW HR1024 segmentation and %QW17/%QW7 signedness all
    match the map

Corrections against the old repo:
  - 10_globals.st header cited WRPS-CTL-002 (the FDS); it means CTL-003
  - build.py wrote the map to its parent directory; now beside itself
  - deploy/README.md was a single-file folder; now DEPLOY.md
  - dropped the empty editor-devices/remote/
  - README no longer claims the simulation build is uncompiled - it is
    the one running

Two open items are now stated plainly rather than buried:
  - none of the 20 acceptance tests in CTL-003 have ever been run
  - the OpenPLC Editor lived only on the retired dev-ubuntu host, so
    there is currently NO route to deploy a new program (DEPLOY.md 0)

Documents the setpoint distinction: IO_MUX seeds %MW defaults once at
first scan, operators retune them live, and that tuning exists only in
the container volume - a restart reverts it.
2026-09-02 15:48:49 +10:00

3.9 KiB

1iec_addressmodbus_objectmodbus_addresstagdescriptionunitsscalingaccess
2%IW0Input register0LIT-101Wet well levelmm1R
3%IW1Input register1FIT-201Inlet flowL/sx10R
4%IW2Input register2FIT-301Discharge flowL/sx10R
5%IW3Input register3PIT-302Manifold pressurekPa1R
6%IW4Input register4PIT-311PU-301 discharge pressurekPa1R
7%IW5Input register5PIT-321PU-302 discharge pressurekPa1R
8%IW6Input register6PIT-331PU-303 discharge pressurekPa1R
9%IW7Input register7VE-314PU-301 bearing vibrationmm/sx10R
10%IW8Input register8VE-324PU-302 bearing vibrationmm/sx10R
11%IW9Input register9VE-334PU-303 bearing vibrationmm/sx10R
12%IX0.0Discrete input0LSHH-102High high level (TRUE = wet)R
13%IX0.1Discrete input1LSLL-103Low low level (TRUE = wet, FALSE = dry)R
14%IX0.2Discrete input2LSH-104Spill detected (TRUE = spilling)R
15%IX0.3Discrete input3TE-312PU-301 motor thermal (TRUE = healthy)R
16%IX0.4Discrete input4TE-322PU-302 motor thermal (TRUE = healthy)R
17%IX0.5Discrete input5TE-332PU-303 motor thermal (TRUE = healthy)R
18%IX0.6Discrete input6MSE-313PU-301 seal leak (TRUE = leak)R
19%IX0.7Discrete input7MSE-323PU-302 seal leak (TRUE = leak)R
20%IX1.0Discrete input8MSE-333PU-303 seal leak (TRUE = leak)R
21%IX1.1Discrete input9XA-502Mains healthy (TRUE = healthy)R
22%QX0.0Coil0PU-301Run commandR
23%QX0.1Coil1PU-302Run commandR
24%QX0.2Coil2PU-303Run commandR
25%QX0.3Coil3PU-301RunningR
26%QX0.4Coil4PU-302RunningR
27%QX0.5Coil5PU-303RunningR
28%QX0.6Coil6PU-301AvailableR
29%QX0.7Coil7PU-302AvailableR
30%QX1.0Coil8PU-303AvailableR
31%QX1.1Coil9STNStation in autoR
32%QX1.2Coil10STNHigh level alarmR
33%QX1.3Coil11STNSpill activeR
34%QX1.4Coil12PU-301TrippedR
35%QX1.5Coil13PU-302TrippedR
36%QX1.6Coil14PU-303TrippedR
37%QW0Holding register0STNWet well levelmm1R
38%QW1Holding register1STNInflowL/sx10R
39%QW2Holding register2STNTotal discharge flowL/sx10R
40%QW3Holding register3STNPumps runningcount1R
41%QW4Holding register4STNCommon drive speedHzx10R
42%QW5Holding register5STNTime to spill weir (32767 = drawing down)s1R
43%QW6Holding register6STNTime to LSHH (32767 = drawing down)s1R
44%QW7Holding register7STNNet accumulation (signed)L/sx10R
45%QW8Holding register8PU-301Run hoursh1R
46%QW9Holding register9PU-302Run hoursh1R
47%QW10Holding register10PU-303Run hoursh1R
48%QW11Holding register11STNVolume remaining to spillm31R
49%QW12Holding register12STNStation state (enum 3.1)1R
50%QW13Holding register13PU-301Pump state (enum 3.2)1R
51%QW14Holding register14PU-302Pump state (enum 3.2)1R
52%QW15Holding register15PU-303Pump state (enum 3.2)1R
53%QW16Holding register16STNCurrent duty pump (0 = none, 1-3)1R
54%QW17Holding register17STNAlarm bitmask (section 6) - READ AS UNSIGNED1R
55%QW20Holding register20STNCommand acknowledge (echoes %MW1)1R
56%MW0Holding register1024STNStation mode: 1 = auto, 2 = off1RW
57%MW1Holding register1025STNCommand word (section 3.3)1RW
58%MW2Holding register1026STNCommand parameter (pump number)1RW
59%MW3Holding register1027STNLevel control setpointmm1RW
60%MW4Holding register1028STNStart duty levelmm1RW
61%MW5Holding register1029STNStart pump 2 levelmm1RW
62%MW6Holding register1030STNStart pump 3 levelmm1RW
63%MW7Holding register1031STNStop all levelmm1RW
64%MW8Holding register1032STNHigh level alarmmm1RW
65%MW9Holding register1033STNMinimum drive speedHzx10RW
66%MW10Holding register1034STNService intervalh1RW
67%MW20Holding register1044SIMSIM ONLY: manual inflow (mode 0)L/sx10RW
68%MW21Holding register1045SIMSIM ONLY: scenario 0=man 1=diurnal 2=wet 3=ref1RW
69%MW22Holding register1046SIMSIM ONLY: write 1 to reset scenario, self-clearing1RW
70%MW23Holding register1047SIMSIM ONLY: time scale 1-120x1RW