This final project follows through the development of the software control of a demonstrational factory unit. The work will include the following topics: First we get to know the hardware build-up of the factory unit, such as the main unit, known as programmable logic controller (PLC) manufactured by Siemens, which is responsible for the control signals, the moduls which help the PLC to operate (IO-moduls, high-speed-counters), the operations of the processing-stations and sensors. After that the final project presents the chosen programming language and the reason of that choice, the PLC foundations, the chosen software-model. After the necessary basics the documents follows through the design and implementation of the control-software. Following, we see the creation of software-blocks which are capable to handle non-designed situations. Finally, we visualize these processes with the help of a HMI-modul that can give us feedback about the occuring faults and modify the process-properties. These steps, included by this work, are necessary in a case of installing a real factory unit.