Water Pump Simulation Server
An OPC UA server that implements a simple water pump machine simulation.
Water Pump Simulation Server is created using OPC UA for the Water Pump and Qt Quick Water Pump examples.
The Simulation
The OPC UA server runs a simulation of a machine containing two tanks, a water pump, and a valve. Water can be pumped from the first tank into the second tank and then be flushed from the second tank by opening the valve. Both operations have a user-configurable setpoint, allowing control over the amount of water pumped into or flushed from the second tank.
The following nodes exist on the server:
NodeId | Function |
---|---|
ns=2;s=Machine | The folder containing the method and variable nodes for the machine |
ns=2;s=Machine.State | The state of the machine |
ns=2;s=Machine.Tank1.PercentFilled | The current fill status of the first tank |
ns=2;s=Machine.Tank2.PercentFilled | The current fill status of the second tank |
ns=2;s=Machine.Tank2.TargetPercent | The setpoint for pumping and flushing |
ns=2;s=Machine.Tank2.ValveState | The state of the valve of the second tank |
ns=2;s=Machine.Designation | A human readable designation of the machine for display purposes |
ns=2;s=Machine.Start | Call this method to start the pump |
ns=2;s=Machine.Stop | Call this method to stop the pump |
ns=2;s=Machine.FlushTank2 | Call this method to flush tank 2 |
ns=2;s=Machine.Reset | Call this method to reset the simulation |
All methods return Good in case of success and BadUserAccessDenied if the operation is illegal (for example, trying to start the pump if the first tank is empty).
Files:
See also Qt Quick Water Pump and Water Pump.
© 2024 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.