A small Node.js program that runs on your PC and connects this browser scene to a real Modbus TCP or Modbus RTU master such as a PLC, SCADA system, or Modbus Poll software.
Download the zip file and extract it to a folder on your PC.
Download acc-modbus-bridge.zipThe bridge requires Node.js. Download the LTS version from nodejs.org and run the installer.
install.batinstall.commandstart-modbus-bridge shortcut for youstart-modbus-bridge.bat (Windows) or
start-modbus-bridge.command (macOS)ws://127.0.0.1:8502CONNECT — the badge turns amber when linkedCoil 00001 → Y1 Inlet Valve (master writes)Coil 00002 → Y2 Drain Pump (master writes)Coil 00003 → Y3 Overflow Alarm (master writes)Coil 00004 → Y4 Mixer Motor (master writes)DI 10001 → X1 Low Float 20% (master reads)DI 10002 → X2 High Float 85% (master reads)DI 10003 → X3 Start PB N.O. (master reads)DI 10004 → X4 Stop PB N.C. (master reads)DI 10005 → X5 E-Stop N.C. (master reads)DI 10006 → X6 Auto/Manual Selector (master reads)DI 10007 → X7 Inlet Valve PB Manual (master reads)DI 10008 → X8 Drain Pump PB Manual (master reads)DI 10009 → X9 Mixer PB Manual (master reads)DI 10010 → X10 Overflow Float 95% (master reads)IR 30001 → Tank Level ×10 — 0–1000 = 0.0–100.0% (master reads)More tutorials at accautomation.ca · YouTube @ACCautomation
Process Tank with Auto/Manual Control
An industrial process tank with an inlet solenoid valve, drain pump, agitator mixer, three float level switches, and an overflow alarm light. The floor-mounted control panel features an IEC-style emergency stop mushroom button, an Auto/Manual selector switch, and individual indicator lights for all key states. The tank operates in two modes: an automatic Fill→Mix→Drain cycle, and a manual mode where each device is controlled by individual pushbuttons on the panel.
| Address | Dir | Description |
|---|---|---|
| X1 | IN | Low float switch — ON when fluid is at or below low level (20%), indicating tank approaching empty |
| X2 | IN | High float switch — ON when fluid above high level (85%) |
| X3 | IN | Start pushbutton — N.O. |
| X4 | IN | Stop pushbutton — N.C. |
| X5 | IN | Emergency Stop — N.C. latching mushroom (click to engage, click again to release) |
| X6 | IN | Auto/Manual selector switch — OFF=Manual, ON=Auto |
| X7 | IN | Inlet valve pushbutton (Manual mode) — N.O. |
| X8 | IN | Drain pump pushbutton (Manual mode) — N.O. |
| X9 | IN | Mixer pushbutton (Manual mode) — N.O. |
| X10 | IN | Overflow float switch — ON when fluid reaches overflow level (95%). Use to trigger Y3 alarm and close inlet. |
| Y1 | OUT | Inlet solenoid valve — opens when ON |
| Y2 | OUT | Drain pump motor — runs when ON |
| Y3 | OUT | Overflow alarm — strobe light on top of control panel |
| Y4 | OUT | Mixer / agitator motor — runs when ON |
| ANALOG — MODBUS INPUT REGISTER (scene → master, read-only) | ||
| IR 30001 | OUT | Tank Level ×10 — integer 0–1000 represents 0.0–100.0%. Divide by 10 in your PLC to get the display value (e.g. 437 = 43.7%). Updates continuously during fill and drain. Use for analog bar display on HMI or SCADA trend. Available via Modbus TCP — connect the ACC Modbus Bridge, then read Input Register 30001. |
Use these five steps to develop your ladder program for this scene. Run standalone mode first to observe correct behaviour, then build and test your program in the ACC PLC Simulator.
A process tank must automatically fill to the high level (X2), mix for 15 seconds, then drain until empty (X1 OFF), and repeat. The control panel has a latching E-Stop mushroom (X5) that must immediately shut everything off when engaged. A separate Stop (X4) halts the auto cycle cleanly. An overflow float (X10) at 95% level must trigger the alarm (Y3) and close the inlet valve if the high float fails to stop filling. Manual mode allows individual operation of each device for maintenance.
Three level sensors: X1=Low Float (20%), X2=High Float (85%), X10=Overflow Float (95%). Control inputs: X3=Start (N.O.), X4=Stop (N.C.), X5=E-Stop (N.C. latching mushroom — click to engage/release), X6=Auto/Manual selector. Manual pushbuttons: X7=Inlet, X8=Drain, X9=Mixer. Outputs: Y1=Inlet Valve, Y2=Drain Pump, Y3=Overflow Alarm (strobe on panel top), Y4=Mixer. Stop and E-Stop are N.C. for safety. X10 gives the PLC a dedicated physical overflow input — your program uses X10 to energise Y3 and force Y1 OFF. When using the ACC Modbus Bridge, the scene also publishes a continuous analog level value as Input Register IR 30001 (scaled ×10: 0–1000 = 0.0–100.0%), which can drive an HMI bar graph or SCADA trend without requiring extra float switches.
Auto cycle: (1) Fill — open inlet (Y1) until X2=ON. If X10 activates before X2, alarm (Y3=ON) and close inlet. (2) Mix — close inlet, run mixer (Y4) for 15 seconds via timer. (3) Drain — stop mixer, run pump (Y2) until X1=ON (low level reached), then return to Idle. Manual mode: X7→Y1, X8→Y2, X9→Y4 directly (OTE rungs — outputs drop when button released). E-Stop (X5 latching): engaging X5 opens the N.C. contact, immediately de-energising all outputs regardless of mode or phase. The machine must not restart until X5 is released AND a new Start is given.
Use C bits to track which Auto phase is active (fill, mix, drain). A TON timer drives the 15-second mix phase. Structure the E-Stop and Stop as overriding conditions that de-energise all outputs when true. In manual mode, outputs use OTE (not OTL) so they drop when the button is released. Add an XIO X10 interlock on Y1 so the inlet valve cannot open while the overflow float is active, even in manual mode. Test each safety interlock independently. If using the ACC Modbus Bridge, read Input Register IR 30001 into a word register in your PLC program. Divide the raw value by 10 to obtain the tank level in tenths of a percent (e.g. raw 437 ÷ 10 = 43.7%). Use this value to drive an analog bar graph on your HMI, a SCADA trend historian, or add custom setpoint logic (e.g. begin drain at a programmable level rather than fixed float switches).
Test Auto mode: tank fills to 85%, mixer runs for 15 seconds, then drains completely. Test overflow: manually toggle Y1 ON and let the level reach 95% — Y3 alarm should activate and Y1 should close. Test E-Stop: engage the mushroom button at any point in the Auto cycle — all outputs must drop immediately. Release the mushroom and verify a new Start command is required to resume. Test Manual mode: verify each button controls only its device and outputs drop on release. Use the event log to track float switch transitions. If using the ACC Modbus Bridge: open ACC Modbus Poll, connect to the bridge, and monitor IR 30001 while the tank fills and drains — the value should climb from 0 to ~1000 during fill and fall back to 0 during drain. Confirm the value crosses the expected thresholds: 200 (20% low float), 850 (85% high float), and 950 (95% overflow) at the same moments X1, X2, and X10 change state in the I/O panel.