6. Working When a PLC executes a program, it must know in realtime when external devices controlling a process are changing. During each operating cycle, the processor reads all the inputs, takes these values, and energizes or deenergizes the outputs according to the user program. This process is known as a program scan cycle. 6.1 Generally Boxes are transported by a conveyor belt from the entry bay to the conveyor belt that positions the boxes in the placing area. The parts conveyor belt transports metallic supplied parts. The three axis arm robot picks the parts using a magnetic gripper and places them in the previously positioned box. The loaded boxes are then transported to the automatic exit conveyor belt for the boxes. 6.2 The boxes The box is subdivided into 9 cells (part/cell) after the three axis arm robots picks the part then the PLC sends pluses out to control the stepper motor move FW/BW for specific distance according to cells position in the box. The required pluses for stepper motor for this distance it should be calculated and stored into the PLC memory the