ladder logic for cement plant grinding mill