You are on page 1of 17

Programming Industrial Automation

Systems
Course code: 23EMEC302 (3-0-2)
Credits: 5, Contact Hrs: 7hrs/week

School of Mechanical Engineering


2023-2024, Semester-V
Chapter 2 - Programmable logic
controllers (PLC) & its building blocks

Class 1 - Internal architecture of Programmable Logic


Controllers systems

DTSI, CEER, KLE Tech. 2


Course outcomes

At the end of the course, the student will be able to:

1. Develop a comprehensive understanding of the fundamental concepts


of automation and its role in production systems.
2. Gain proficiency in the internal workings of Programmable Logic
Controller (PLC) systems.
3. Explore IEC61131-3 standards and other PLC programming languages.
4. Develop expertise in creating medium to complex logic using advanced
instructions like FIFO, FAL and PLC MOVE.
5. Develop and debug PLC-based systems, adhering to safety standards.
6. Design SCADA-based virtual systems like i. Assembly lines and ii. Multi-
stage water filtration units and iii. HMI interfaces to control machine
parameters.

SME, KLETECH, Hubballi -31 3


Topic Learning Outcomes

At the end of the chapter, the student will be able to


1. Explain the internal components of a PLC system and their
functions.
2. Explain different I/Os that are commonly used in building a PLC
system.
3. Emphasize the signal conditioning, networking and scanning
phenomenon in a PLC system.
4. Describe how error detection mechanisms and diagnostics
contribute to troubleshooting in PLC systems.
5. Emphasize the Boolean algebra in ladder programs.

DTSI, CEER, KLE Tech. 4


Memory Organization

Types of Memories in general,


RAM: Random Access Memory, is a crucial component of a
computer's hardware system. It is a form of volatile computer
memory that temporarily stores data that the CPU (Central
Processing Unit) is actively using while the computer is powered on.
Features:
1. Temporary Storage: RAM is used to store data that is actively
being used by the computer's processor. This includes data
required by running applications and the operating system itself.
It's temporary storage because the data in RAM is lost when the
computer is turned off.
2. Faster Access: RAM is much faster to access than long-term
storage devices. This speed allows the CPU to read and write data
rapidly, which is essential for the performance of your computer.
When data is in RAM, the CPU can access it almost instantly.

5
3. Data Volatility: As mentioned earlier, RAM is volatile memory,
meaning it loses its data when the computer is powered down. This
is in contrast to non-volatile storage like hard drives or SSDs, which
retain data even when the computer is turned off.
4. Capacity: RAM comes in various capacities, typically measured in
gigabytes (GB) or, in some cases, terabytes (TB). Modern computers
generally have 4GB to 32GB or more of RAM, with higher-end
workstations and servers having even larger amounts.
5. Upgradability: RAM is often upgradable in many computers. You
can increase your computer's performance by adding more RAM, up
to a certain limit defined by the motherboard's specifications.
6. Dual-Channel and Quad-Channel: Some computers and
motherboards support dual-channel or quad-channel memory
configurations. This involves using multiple sticks of RAM to increase
data transfer rates and improve overall system performance.

6
ROM - Read-Only Memory, is a type of computer memory that stores data
that can only be read and is not easily altered or overwritten.
It serves a different purpose than RAM (Random Access Memory) and is
often used to store essential and unchanging firmware or software
instructions that are necessary for a computer or other electronic devices
to function.
1. Non-Volatile: Unlike RAM, which is volatile memory and loses its data
when the computer is turned off, ROM is non-volatile. This means that
the data stored in ROM remains intact even when the power is
switched off.
2. Read-Only: As the name suggests, the data in ROM is read-only. In
most cases, users cannot write or modify the data stored in ROM. This
data is typically "burned" onto the ROM chip during the manufacturing
process and is meant to be permanent.
3. Firmware: ROM is often used to store firmware, which is software that
is permanently programmed into a device's hardware. Firmware is
responsible for booting up the device and contains instructions for its
basic operation. For example, the BIOS (Basic Input/Output System) in a
computer is stored in ROM.

7
Types of ROM: There are several types of ROM, including:
• Mask ROM (MROM): In this type of ROM, the data is
permanently programmed during manufacturing, and it cannot
be changed.
• EPROM (Erasable Programmable Read-Only Memory): EPROM
can be erased and reprogrammed, but this requires exposure to
ultraviolet light.
• EEPROM (Electrically Erasable Programmable Read-Only
Memory): EEPROM can be reprogrammed electrically and
doesn't require UV light for erasure.
• Flash Memory: This is a type of EEPROM that is commonly used
in modern devices like USB drives, SSDs, and memory cards. It can
be reprogrammed and updated more easily than older ROM
types.

8
Memory organization takes into account the way a PLC divides the
available memory into different sections.
The memory space can be divided into two broad categories:
i. Program files and
ii. Data files.
Program files are the part of the processor memory that stores the
user ladder logic program.
• The program accounts for most of the total memory of a given
PLC system. It contains the ladder logic that controls the machine
operation.
• Program files are the areas of processor memory where ladder
logic programming is stored. They may include

9
• System functions (file 0): This file is always included and contains
various system-related information and user-programmed
information such as processor type, I/O configuration, processor
file name, and password.
• Reserved (file 1): This file is reserved by the processor and is not
accessible to the user.
• Main ladder program (file 2): This file is always included and
contains user-programmed instructions that define how the
controller is to operate.
• Subroutine ladder program (files 3–255): These files are user-
created and are activated according to subroutine instructions
residing in the main ladder program file.

10
11
The data file portion of the processor’s memory stores input and
output status, processor status, the status of various bits, and
numerical data.
All this information is accessed via the ladder logic program. These
files are organized by the type of data they contain and may include:
• Output (file 0): This file stores the state of the output terminals
for the controller.
• Input (file 1): This file stores the status of the input terminals for
the controller.
• Status (file 2): This file stores controller operation information
and is useful for troubleshooting controller and program
operation.
• Bit (file 3): This file is used for internal relay logic storage.
• **Timer (file 4):**This file stores the timer accumulated and
preset values and status bits.

12
• The processor operates on two different data types: integer and
floating point. All data types, except the floating-point files, are
treated as integers or whole numbers.
• All element and bit addresses in the output and input data files
are numbered actually. Element and bit addresses in all other
data files are numbered decimally.

13
The PLC store all data in global data tables and are based on 16-bit
operations. You access these data by specifying the address of the data you
want. Typical addressing formats for the PLC-5 controller are as follows:
• The addresses in the output data file and the input data file are
potential locations for either input modules or output modules
mounted in the I/O chassis.
• The status data file contains information about the processor status.
• The bit data file stores bit status. It frequently serves as storage when
using internal outputs, sequencers, bit-shift instructions, and logical
instructions.
• The timer file stores the timer status and timer data. A timer element
consists of three words: the control word, preset word, and
accumulated word. The addressing of the timer control word is the
assigned timer number.
• The counter file stores the counter status and counter data. A counter
element consists of three words: the control word, preset word, and
accumulated word.

14
• The control file stores the control element’s status and data, and
it is used to control various file instructions. The control element
consists of three words: the control word, length word, and
position word.
• The integer file stores integer data values, with a range from
232,768 through 32,767. Stored values are displayed in decimal
form. The integer element is a single-word (16-bit) element
• The floating-point file element can store values in the range from
61.1754944e-38 to 63.4028237e138. The floating-point element
is a two-word (32-bit) element.
• Data files 9 through 999 may be assigned to different data types,
as required. When assigned to a certain type, a file is then
reserved for that type and cannot be used for any other type.
Additional input, output, or status files cannot be created

15
I/O Processing

Input Processing:
• Input processing involves reading signals from sensors, switches, and
other input devices. PLCs continuously monitor inputs to determine the
system's current state and trigger appropriate control actions.

Output Processing:
• Output processing involves sending control signals to actuators, relays,
motors, and other output devices. PLCs ensure that the correct outputs
are activated based on the control program's logic and input conditions.
16
Questions?

17

You might also like