Siemens Modular Programming
Siemens PLC Programming This chapter covers the following topics ( Modular Programming , Program Blocks , CPU Memory, Data Types ). Modular Programming linear program A PLC executes its program in a cyclic manner referred to as a scan. A PLC program can be organized as a linear program or a modular program. As shown on the left in the graphic a linear program has all the instructions in one block and executes these instructions in sequence in each PLC scan. A linear program works well when the program is simple and does not need to vary from one PLC scan to another. As shown on the right in the graphic a modular program is composed of multiple program blocks. Some program blocks are executed in each PLC scan and other program blocks are executed under special circumstances such as during startup at specific times when a special process event occurs or when an error or interrupt occurs. An interrupt is a special signal or condition that causes a PLC to immediately perform a specific tas...