x02 c0 -----| |---------------------(SET)------ x02 c0 -----| / |---------------------(RST)------ x01 c0 c2 c1 -----| |-----| |--| |----(SET)------ x01 c1 -----| / |---------------------(RST)------ c1 y0 -----| |---------------------(OUT)------ c11 x02 c2 -----| |-----| / |-----------(RST)------ c2 ________ -----| / |------------------ | TMR |--- | T0 | | K500 | -------- T0 c2 -----| |--------------------(SET)------- | T0 ---(RST)------- c2 c11 -----| |--------------------(RST)------- _______ -------------------| End |-------------- ------- x01 = Sensor for high water level x02 = Sensor for low water level c0 = Water level low variable c1 = Indicates that the we whant to fill the tank c2 = Dump Done c11 = Dump valve y0 = the actual motor that fills the tank Bit Sate 0 0 1 0 1 1 --x01--x02- --x01--x02- --x01--x02- | | | | | | | | | | | | |''|''''|'| | | | | | | | | | | | |'''''''|'| | | | | | | | |'''''''''| |_________| |_________| |_________| Process State 1 2 3 The Dump Process waits for the dump valve to open, this is controlled by the PLC program, it also checks to see that there is some water to dump. The dump process is set on a timer so as you can see in rung 7 it waits for 50 seconds then stops dumping. Afterwards it sets the Dump Done variable and resets the Dump Valve in rung 9. In order to make sure that the tank only fills when we finished dumping we put in the 'dump done switch' in rung 3.