What Is a PLC ?

What Is a PLC ?

Share this post

Full industrial automation has been the goal for quite a while now. Slowly but surely, we have been moving towards it. In 1785, the automatic flour mill was invented, marking the first fully automated industrial process. From 1968 until now, PLCs have been making their way into everything, from simple thermostats to complex heavy machinery. They have proven more than capable of automating a significant number of industrial processes and production lines. What is this indispensable tool? Here is everything you need to know.

What Is a PLC?

A PLC or a programmable logic controller is an industrial computer primarily used in factories and industrial environments that heavily rely on automation. It’s a stand-alone unit that controls, automates, and regulates various industrial processes, as well as all the elements that go into these processes. In other words, it oversees and controls input devices in order to produce the desired output. To get a better picture of what a PLC is, picture a thermostat – it is essentially a simple PLC, and here is why. With a thermostat, you set the temperature to a specific degree (the desired output). What the controller does is that it uses the data from its temperature sensor (input) to gauge whether or not the heating unit should be functioning. When the temperature goes below the desired output, the controller signals to the heating unit, which operates in response to maintain a desirable temperature. That’s how you end up with a consistently warm room.

For industrial PLCs, the core principle is the same, but because it is applied on a massive scale to control complex equipment, the controllers are equipped with a large number of specialized features. Not only that, but by connecting one PLC unit to other units, one can easily control an entire production line without needing as many workers as you would without PLCs. When used on a large scale, PLCs guarantee efficiency, save a great deal of money, time, and resources. For these reasons, the controller and its programmers are highly sought after by manufacturing companies.

Components of a PLC

I/O Section

The I/O or input/output section of a PLC is the hub that connects external machines/devices to the computer to gather input and control output. This I/O section is mainly responsible for translating real-world variables to electronic signals that the computer can understand. The section is also responsible for translating programming languages into machine commands. By connecting machines and devices, like temperature sensors, weight sensors, and tachometers, PLCs record variables that are used by the software to manage the manufacturing process. Through its I/O section, a controller can command motors, valves, and various elements within machinery.

If the PLC unit was a human, the input/output section would be the body. It senses external stimuli, sends them to the brain, and follows orders as they come.

CPU

Speaking of the brain, its equivalent is the central processing unit (CPU). This is where the magic happens. That’s the component responsible for analyzing and sorting all the data that comes through from the specified inputs in order to take appropriate actions (predetermined by the program). If certain conditions are met, the CPU starts stops, speeds up, etc., the process taking place. You can see this in an elevator. In order for the motor to operate (output), the doors must be closed (input 1), and a button must be pressed (input 2). If the CPU doesn’t receive either input, it won’t trigger an output. Once all the conditions are met, the motor will start, and the elevator will start working.

Programming Device

Just like a PLC, humans operate according to a specific program, except we don’t call it that. We call it instinct. We eat when hungry and sleep when tired. Imagine if you could rewrite instinct. That’s what a programming device does. It’s a computer, laptop, or handheld device with PLC software that allows a programmer to dictate how a machine thinks and how it reacts. It’s where you write instructions, essential inputs, desired outputs, and more. Once the programmer writes a program, they send it over to the memory component for the CPU to access.

Memory Unit

As the name suggests, this is where all data is sent/written by a programmer/input device and stored to be read by the CPU. Keep in mind, when we talk CPU memory, we’re talking about two types: RAM and ROM. ROM is “read-only memory.” It’s where fixed data, mainly the operating program, is stored only to be read and not altered by the CPU. Meanwhile, RAM stands for random access memory, and that is where anything can be read or written. Data stored there is variable in nature. It includes ladder logic programs and sensor/switch data, like temperature values, voltage, current, and pressure. As with any memory unit, PLC memory units have a specific capacity. The more complex your program is, and the more inputs and outputs you have, the more memory you will need.

Power Supply

The power supply is what keeps the PLC going. Depending on the scale of your operation, you will need to provide enough power for your PLC to operate smoothly. The power supply works by converting 240 Volts AC (alternating current) to 24 Volts DC (direct current). That said, it’s important to note that power supplies come in various capacities. While the voltage remains the same, the capacity is rated by the current (measured in amperes/amps). A 2 amp power supply is considered fit for small-scale use, while a 50 amp power supply is considered a better fit for large-scale productions.

How Is It Programmed?

To write a PLC program, first, you need to understand the project/process you will be writing. Once you’ve understood the process and determined the best approach to writing the program, the next step is picking a programming language. There are five officially recognized languages, each with its pros and cons. As a programmer, you don’t need to know all five as most companies use one, but the more you know, the better you’ll be at problem-solving.

Ladder Diagram (LD)

This is by far the most popular language because it’s easy to read and easy to edit online. It’s written in the form of horizontal rungs and read from left to right. The inputs/conditions that need to be met are written on the left side, and the desired outputs are on the right side. If you are new to PLC programming, LD is a great starting point, especially because it’s easy to learn. The one drawback you should watch out for is the language’s limitations. While perfect for basic projects, ladder diagrams can’t be used to program motion controls. In short, it’s a great place to start, but you’ll need to branch out to other languages if you want to stand out in this field.

Instruction List (IL)

Unlike ladder diagrams, IL is a textual language which means you’ll be writing lines of code instead of drawing your program. The language’s textual nature is also what gives it its two crucial perks. First of all, text takes less space than graphics which means that you can write as large of a program as you want without having to worry about memory space. Second, text is easier for the CPU to read, so it gets executed faster. Despite the benefits, it’s not as common as other languages because most people prefer depending on graphics seeing how they help avoid the risk of critical errors.

Structured Text (ST)

ST is a high-level textual language that means two things. One, it’s much closer to human languages than the rest. Two, it’s extremely powerful and more than capable of executing complex projects. In terms of versatility, think of it as the C++ of industrial automation. Of course, for those inexperienced in C languages, ST won’t be as easy to learn, but it is guaranteed to make you a strong candidate for any job. What’s better, it doesn’t have any limitations, unlike LD and SFC. The main drawbacks of the language are that it’s hard to debug and hard to edit online.

Function Block (FB)

Function blocks are where PLC programmers divide. Some believe that the graphical language is extremely useful; others believe it’s rather overcomplicated. The diagrams are composed of numbered input and output boxes connected together by lines. The CPU then scans the diagrams to figure out the order of execution. The main drawback is that there is no particular structure or order for the boxes to be put in. This can get confusing when tackling a large project with a lot of moving parts. However, for small, repetitive tasks, FB has proven to be one of the best for the job.

Sequential Function Charts (SFC)

This is a graphical language quite similar to flowcharts. When writing, you write vertically, using steps to indicate the actions needed to be taken (outputs). The required inputs/conditions are written as transitions. The program then goes from one step to the next by meeting the transition requirements. As you might imagine, the language is to write and read, which helps a lot when it comes to editing the program or diagnosing an error. In the field, most people prefer to use SFC when they program several parallel processes or draw an overview of a program.

Types of PLC

There are two major types of programmable logic controllers, fixed and modular. They are classified based on how many input/output slots are available. Fixed PLCs are manufactured with a set number of inputs and outputs. The number is decided by the manufacturer, and it cannot be altered by the user. Meanwhile, modular PLCs allow for additional I/O sections and more. It all goes back to how they are structured. The components of a modular PLC are divided into several modules, which, when connected, form the full PLC system. In order to increase the number of input units, you simply need to add more I/O modules. This scalability feature makes modular PLCs a highly desirable choice for rapidly growing companies.

The Advantages

There are many reasons why one would need to use a PLC. In large-scale productions where uniformity is a must, PLCs guarantee a desirable and consistent output by overseeing and controlling the production process. They also reduce the need to hire too many human workers. While the company will still have to spend money on the system and a qualified technician, it will save money that would have otherwise been spent on wages, insurance, and the liabilities that come with potential human errors.

What’s more beneficial is that PLCs play a role in preventative maintenance. When a machine is overworked, its performance quality decreases. Because PLCs collect enormous amounts of data from the machines they are connected to, a technician can easily program a PLC to be on the lookout for any signs of declining performance. When the machine reaches a specific point set by the technician, the system will display a warning message indicating the need for maintenance. That way, there won’t be any need to stop production due to a sudden breakdown or unplanned maintenance. In addition, with constant maintenance and supervision, a company can guarantee efficiency, which translates into larger profit margins, increased production, and lower costs. There is no denying the impact of programmable logic controllers on industrial automation and production costs. There is also no use denying its footing in the industry. In 2019, according to Mordor Intelligence, the PLC market was worth just under $4 billion. The same research also showed that the market is expected to grow during the years to come. If you’re a programmer or an electric engineer mulling over the idea of a career in PLC programming, you should seriously consider it. If you’re a business owner that’s still hesitant about buying a system, what are you waiting for?

Plc Mastery

Automation Specialist

Posted on July 21, 2021

Join the Top 1% of PLC programmers

Related Blog Posts

PLC history

When we think industry, we can’t deny how the industrial revolution changed how we manufactured everything, from clothes