What are the Differences Between PLCs and Microcontrollers?

Post By: Harry Richardson On: 19-02-2024 Read Time: 4 minutes - Guides

What Are Microcontrollers?

It's a general trend in innovation and technology that things get progressively smaller. Just look at those room-sized computers they used in the 1940s and 50s! Now you can wear your computer on your wrist, and open-source electronics are widening up the industrial arena with single-board computers like Raspberry Pi. Interest in microcontrollers and their potential is increasing daily, but it's not always obvious how to tell a microcontroller from a PLC.

A microcontroller is a computer that you can use to control things. It shares typical features with all computers, such as:

  • CPU (central processing unit)

  • ROM (read-only memory)

  • RAM (random-access memory)

  • I/O (input and output devices) like monitors, mice, keyboards and printers

  • Some means of loading programs, like a disk drive

Larger devices like desktops and PCs are general-purpose computers with a large capacity for varied tasks. A microcontroller is dedicated to a single function, like running your health app or microwave oven.

Microcontroller Characteristics

How do you know whether you have a microcontroller or another type of computer? Some particular characteristics can be used to tell the difference.

1. Microcontrollers, often embedded microcontrollers, control another device's features or actions.

2. Microcontrollers are small, fast and inexpensive, so you can choose the minimum necessary to do the job quickly.

3. Microcontrollers use only about 50 milliwatts of power, a fraction of the average computer demand.

4. Microcontrollers are dedicated to a single task, running a specific program that stays unaltered in the ROM.

5. Microcontrollers have a dedicated device for input, like a remote control or keypad. They generally have a device for output, like a digital display or video screen. They can also receive and transmit signals to control the device in which they're embedded. 

6. Many microcontrollers are ruggedised to withstand more extreme conditions and temperatures. For example, the microcontroller in a vehicle engine may have to function in environments from the desert to the Arctic.

Microcontrollers used to be specialised items for hobbyists building their own robots and automated tools. Over time, they've become so affordable and versatile that they're getting more mainstream. As their functionality expands, many manufacturers are also beginning to use them for industrial applications.

How Does A Microcontroller Differ From A PLC?

A PLC is a microcontroller on a larger scale. It's an industrial computer that facilitates manufacturing processes and is rugged enough to cope with harsher environments. You'd use it for any industrial function with automated systems that require process fault diagnostics and precise, reliable control.

Input devices and connected sensors transmit data to your PLC, which processes that information and uses it to create outputs within preset parameters. It can be configured to your needs, so you can use a PLC to monitor run-time data. You can use this to analyse and improve operating function or machine line productivity.

PLC Characteristics 

1. The CPU in a PLC processes and stores program data, just as a microcontroller CPU does. However, to connect to the machine's functional parts, it also needs I/O modules to send information to trigger specific results. The I/O controls can be digital or analogue, with input types including switches, sensors and meters. Output types include drives, relays, lights and valves. A significant advantage to PLCs over microcontrollers is that I/O modules can be custom-tailored to an application's configuration requirements.

2. As well as I/O devices for internal connections, a PLC will be connected to various external systems. For example, you may collect application data from several devices and export it to a SCADA (Supervisory Control and Data Acquisition) system. For this purpose, you'll find multiple ports and communication protocols on your PLC that enable it to communicate with other systems.

3. To interact directly with a PLC, humans need some kind of Human Machine Interface (HMI). The simplest HMI is a primary display and keypad, but more advanced systems feature bright touchscreen panels.

Essential Differences Between PLCs And Microcontrollers

I/O Compatibility

Microcontrollers must have the correct number and type of I/Os for your application, though they can sometimes be converted.

PLCs usually offer more I/O choices since they're designed for industrial applications. Most will also have built-in isolation for I/O points to protect against electrical damage.

Housing And Mounting

PLCs come with all the necessary housing and mounting equipment for connecting to external devices. Most microcontrollers are bare-bones equipment – just a simple board with connection pins. Housing and mounting are more complex, as you'll have to make terminals to connect to other devices and provide power.

Operating Systems And Security

Microcontrollers are essential, with only the most straightforward capabilities. If you need more, you'll have to code it yourself, though the standard operating systems are usually sufficient. PLCs also have a straightforward O/S but with additional functionality like housekeeping programs and monitoring systems to ensure data integrity and security. 

PLCs have software that protects their programs and performance, plus hardware monitoring of the connected devices to safeguard the PLC's intercommunication. With appropriate knowledge and time, you can provide a microcontroller with this added functionality. It means reusing existing software or writing programs from scratch before testing and verifying them for use with a given application.

Extreme Environments

PLCs are designed specifically for industrial conditions and are better equipped for harsh environments, coping with extreme temperatures, shock, and vibration. Microcontrollers need unique connections and mounting to resist these conditions. 

Most PLCs are also built with corrosion-resistant materials and protection against electronic noise that could cause microcontrollers to malfunction. 

PLCs will also have industry-approved certification for the appropriate conditions, while microcontrollers typically don't. Brand-specific and generic boards also differ, making it harder to assess their capabilities. 

Does Your Application Need A Microcontroller Or A PLC?

Your choice will usually depend on your budget, usage and program expectations. While microcontrollers are less expensive, their functionality is limited. They're great for DIY projects and as uncomplicated teaching tools, but you'll most likely need a PLC for larger industrial applications.