Programming and implementation of PLC systems