Electrical Systems and Control Methods: PLCs
By Ed Butts, PE, CPI
We have been discussing the electrical components and requirements for a pumping system along with basic control methods in this column. We will now begin a two-part series on programmable logic controllers. Later we will expand into supervisory control and data acquisition (SCADA) systems in the next installment of the column in the October issue.
A programmable logic controller (PLC), or programmable controller, should not be confused with a personal computer (PC). The biggest difference between a programmable logic controller and a personal computer is that a PLC can perform discrete and continuous processing functions to external devices that a PC cannot do—plus, a PLC is much better suited to more rugged industrial environments than a PC.
A PLC is an industrial digital computer, invented during the 1960s, that has been adapted to replace conventional hardwired or relay-based control systems for the supervisory control of various manufacturing and industrial control processes.
These processes include assembly lines; industrial processes; oil, gas, or water pumping or metering stations; water and industrial/wastewater treatment plants; and any other activity that requires high reliability, repeatability, accuracy, simple installation, ease of programming, and process fault diagnosis and alert capabilities.
PLCs are available from numerous manufacturers including Rockwell International (Allen-Bradley), ABB, Schneider Electric (Square D), Siemens AG, Telemecanique, Mitsubishi, and General Electric (Fanuc), as well as many electronics suppliers such as Automation Direct, PLC Direct, Omron, and Phoenix Contact.
Figures 1a and 1b show examples of programmable logic controllers made by the manufacturer Allen-Bradley.
Knowing the Advantages
One of the main advantages of a PLC over a hardwired relay control system is that a technician can return to the site and modify the functions of a PLC after the original programming at minimal time and cost.
In a hardwired control system requiring a modification to the control process, the technician essentially must remove the controls or wires and start over, whereas a PLC-controlled system can usually be revised with a few new key entries.
Modern PLCs can be provided as complete stand-alone (all-in-one) devices, with the single unit acting as the processing unit along with integral inputs and outputs, or as modular devices with separate modules for the power supply, processor, and input and output signals.
Most PLCs today are modular, allowing the user to add several input/output (I/O) modules as needed to provide a wide assortment of I/O capability and functionality. This can include discrete input and output control, analog input and output control, human-machine interface (HMI), PID (proportional, integral, and derivative) control, valve position control, motor control, serial communication, and high-speed networking.
A typical PLC (Figure 2) is composed of four basic components:
- A power supply, usually 120VAC or 12/24VDC
- A central processing unit (CPU) which includes memory, communication, and computing functions
- Input/output cards or modules
- Depending on the type of PLC, a backplate, terminal boards, carrier, or rack that allow individual components to interface to the field devices.
A backplate creates an electrical connection between the separate components. This electrical connection includes both power and communication signals. Many PLC manufacturers use proprietary communication protocols on the backplate so that the I/Os can securely communicate with the CPU in both directions.
Compared to older relay technologies, the PLC is easier and faster to troubleshoot, more reliable, more cost-effective, and far more versatile than hardwired logic.
In addition to input and output devices, a PLC might also need to connect or interface with other kinds of systems. For example, users may want to export application data recorded by the PLC to a supervisory control and data acquisition (SCADA) system, which in turn may monitor several connected devices.
PLCs offer a range of ports and communication protocols to ensure the PLC can communicate with these other systems. Most PLCs are programmed using onboard keypad entries, programming devices, or software applications that run on conventional laptop or desktop computers. They communicate using Ethernet or USB, while some may use a proprietary data communication system.
Knowing the Components
Components of a PLC generally include a power supply module that is used to provide the required power to the entire PLC system. It converts the available AC power to DC power, which is required by the CPU and most I/O modules.
The output capacity of the power supply, often expressed in amps or watts/VA, will vary with the demand of the CPU along with the power demand placed onto the input and output modules and peripheral devices. Most PLCs function on a 24V DC power supply; few PLCs use an isolated power supply.
Next is a central processing unit (CPU), the brains of the device, which receives information from connected sensors or input external devices. The CPU then processes the various types of data and triggers output commands based on pre-programmed parameters.
A CPU module has a central processor with both read-only memory (ROM) and random-access memory (RAM). ROM memory includes the operating system, drivers, and application programs. RAM memory is used to store the programs and data.
Some PLCs also possess a programmable read-only memory (PROM) chip, which stores the program on a non-volatile memory source. This enables retrieval and reload of the program in cases of program loss or corruption and the ability to write programs on a remote device.
The processing speed of the CPU must be rapid enough to handle multiple inputs and outputs (I/Os) and the types of data collection required for the application. The scan cycle is the cycle in which the PLC gathers the inputs, runs the PLC program, and then updates the outputs. Another consideration is the scan time, which is the amount of time it takes for the CPU to perform one cycle of gathering inputs, running the PLC program, and updating the outputs.
Possessing enough memory is also essential and will depend on how many devices there are and the complexity of the operation. Program memory for the CPU will be determined by the type of program and instructions planned to be used.
Memory capacities of PLCs vary with the processor size, programming requirements and complexity, and I/O capability. Memory is usually expressed in kilobytes (K), with 16K or 16284 bytes the most common sizes.
Knowing How to Choose
Choosing the right PLC can be overwhelming for most people unfamiliar to the technology. For anyone tasked with determining what control solution is needed for a specific application, the use of a control system integrator (CSI) can be an excellent resource.
A CSI should be technology-agnostic. That means their priority should be to understand the specific technical and operational requirements of the application. Only after clearly understanding the project objectives should a CSI begin the process of discussing or recommending potential PLC options—it should never be performed the other way around. If a CSI tries to make the application fit their PLC solution, then the client is not working with a true systems integrator.
Selection of a PLC should consider the CPU’s processor speed, scan time, memory, how many input and output circuits it can accommodate (number of I/Os), reliability (warranty and redundancy options), local source of components, and an ease and understanding of programming requirements.
Although the CPU stores and processes program data, the I/O modules actually connect or interface the PLC to the respective input or output peripheral devices and circuits. PLCs can be configured as a stand-alone or compact unit in which the I/Os are attached directly to the CPU as a single unit or as a rack, chassis, or stackable unit in which the CPU and I/O modules are individually attached to a common DIN rail support base that also provides signal transmission between the modules and CPU.
PLCs are primarily available in rack, mini, micro, and based on software styles. They are also available in various processing speeds, scan times, RAM and ROM memory capacities, number of inputs and outputs (I/Os), software and programming styles, and communication connections, including network and serial cable styles.
Communication involves sharing data or status of applications with other electronic devices, such as a remote computer or monitor at the station of an operator. Communication can occur locally via a twisted pair of wires, remotely via telephone or by using a radio modem. The input modules provide the needed incoming information or parameters to the PLC’s CPU which, in turn, activates internal instructions that trigger specific outputs.
Most inputs and outputs (I/Os) are designed to accommodate two types of inputs and outputs (Figure 3). These are typically either analog (continuously variable) or discrete (digital or on/off signals) in function. Inputs to a PLC often include digital or discrete input (DI) signals such as hand-off-auto switches, high/low control or alarm signals, relay contacts, power or phase protection or overload contacts, auxiliary contacts, and limit/pressure/float switches.
Analog inputs (AI) receive PLC signals from variable power devices such as strain gauges or potentiometers, which produce a continuously variable electrical signal wired in series with the circuit that is linearly proportional to the measured parameter. This includes process parameters such as flowmeters, pressure or water level transmitters, variable valve position indicators, variable chemical feed or concentration levels, or weight or volume transmission of bulk storage vessels.
Discrete outputs (DO) will often transmit digital signals that originate from the PLC to motor starters, solenoid coils, valve actuators, motor run confirmation, signal annunciators, run time meters, counters, SCADA panels, and interfacing relays.
Analog outputs (AO) are transmitted from the PLC as control or process parameters such as a variable speed drive (VSD) speed control, batching operations for volume control, variable chemical feed injection rates, and continuous indication of flow and pressure to a remote destination such as an annunciator or SCADA panel.
Discrete I/O is available in a sink, voltage source, or relay configuration. With sinking inputs/outputs, the PLC will provide the reference voltage (typically 0V) when completing the circuit. Sourcing inputs/outputs are the opposite in function, with the PLC providing the source voltage (12 or 24VDC, 120 or 240VAC) that is necessary for the application.
Relay types do not provide either sink or source configuration. They function just as an ordinary relay contact would and act as a dry contact, using an external power source to connect the source voltage to a load, once activated.
Analog outputs are typically limited to direct current (DC), in milliamps (mA) or voltage (VDC) and powered from a 24VDC source. Common values of analog voltage outputs include 0-5VDC, 0-10VDC, and 0-50VDC and current outputs are typically 4-20mA, 0-50 mA, or 0-20 mA.
RTD and thermocouple modules are two analog modules that specialize in converting low voltage signals from temperature probes into usable data. One important factor to remember with analog modules is the resolution they provide. The higher the resolution, the higher the accuracy of the input measurement or output response.
Selecting whether to use either voltage or current analog is largely determined by the instrument, the application, and the user or designer. Most of the newer industrial controllers will also accept current signals but may not be configured for voltage analog values.
Additionally, an analog current signal provides inherent error condition detection since the signal, even at its lowest threshold value, is still active. Even at the extreme lowest end, or at the so-called zero position of 4-20 mA, the sensor is still providing a measurable 4.0 mA signal.
AC discrete voltage values can be read with an ordinary AC measuring multimeter, but DC analog values must be read with the meter connected in series with the signal, using a multimeter capable of reading low values of DC current or voltage.
The final group of I/Os are referred to as specialty I/Os. This type of I/O includes special functions such as high-speed transmission and communication. High-speed modules are needed when the input/output data is comprised of high-frequency pulses. These modules can track input data, such as encoder or flow totalizer pulse signals, independent of the CPU scan, guaranteeing a more accurate pulse count.
In addition, high-speed outputs can provide precision control with stepper motors used in motion or positioning applications. Communication modules provide additional communication ports/protocols that a system may require, including RS232, RS485, Ethernet, etc.
Generally, designers can mix and match a PLC’s available I/O space to get the right configuration for their client’s application. Placement and installation of the I/O modules is simply a matter of inserting the correct modules in their proper locations. This procedure involves verifying the type of module (115VAC or dry contact output, 24 or 115VDC input, etc.) and the slot address as defined by the I/O address assignment
document. Each terminal in the module is then hardwired to the field devices that have been assigned to that specific termination address.
Another peripheral device that is frequently used with a PLC is a human-machine interface (HMI) (Figure 4). HMIs communicate with PLCs and I/O sensors to receive and display information for users to view.
An HMI is used for programming of the PLC (Figure 5). There are three basic types of HMIs: the pushbutton replacer, the data handler, and the overseer.
Before HMIs came into existence, a control might consist of hundreds of pushbuttons and LEDs performing different operations. The pushbutton-replacer HMI has streamlined manufacturing processes, centralizing all the functions of each button into one location.
The pushbutton replacer takes the place of LEDs, on/off buttons, switches, or any mechanical device that performs a control function. The elimination of these mechanical devices is possible because the HMI provides a visual representation of all these devices on its LCD screen, while performing all the same functions.
The data handler is perfect for applications requiring constant feedback from the system or printouts of the production reports and is often comprised of a personal computer. With the data handler, you must ensure the HMI screen is big enough to display information such as graphs, visual representations of data, and production summaries.
The data handler includes such functions as recipes, data trending, data logging, and alarm handling/logging. The data handler is used for applications that require constant feedback and monitoring and often comes equipped with large capacity memories.
Now anytime an application involves SCADA or MES, an overseer HMI is extremely beneficial and usually consists of a personal computer. The overseer HMI will most likely require Windows to operate, have several Ethernet ports, and works with SCADA and MES systems.
These are centralized systems that monitor and control entire sites or complexes of large systems spread out over large areas. An HMI is usually linked to the SCADA system’s databases and software programs to provide trending, diagnostic data, and management information.
HMI screens can be used for a single function, like data monitoring and tracking, or for performing more sophisticated operations such as switching machines on or off or increasing motor or production speed with a VFD, depending on how they are implemented.
HMIs are used to optimize an industrial process by digitizing and centralizing data for a viewer. By leveraging an HMI, operators can view important information displayed in graphs, charts, or digital dashboards; review, manage, and acknowledge alarms; and connect with SCADA systems, all through one console.
This concludes this first of a two-part series on an introduction to programmable logic controllers. We will continue this topic with an overview on programming languages and PLC applications in October.
As always, keep them pumping!
Ed Butts, PE, CPI, is the chief engineer at 4B Engineering & Consulting, Salem, Oregon. He has more than 40 years of experience in the water well business, specializing in engineering and business management. He can be reached at firstname.lastname@example.org.