Arduino PLC

The PLC (Programmable Logic Controller) has been and still is the basic component of the industrial automation world. PLCs are usually pretty expensive pieces of hardware, which led many people who know micro-controllers to come up with their own ideas to implement similar functionality.

Arduino is a kind of universal programmable controller, although it is only the “core” and in any case it has been built for general applications; with a little of external hardware (essentially interfaces capable of transferring signals from sensors and to actuators, reducing the EMI which may damage the microcontroller) and an appropriate software may, however, become something very similar to a PLC. For output you can use Arduino Relay modules. For input you can use varying Arduino sensors of build your own adapter for some industrial sensors.

Arduino as a programmable logic controller (PLC) tutorial we will explain how to “convert” our Arduino board in a PLC-like controller.  There are several ways to turn Arduino into a Programmable Logic Controller, and Arduino as a programmable logic controller (PLC) tutorial presents two: Ladder Logic for PIC and AVR software and ladder.h Generator for LDmicro → Arduino. Also OpenPLC project has a OpenPLC Ladder Editor that can generate code for a standard arduino from a ladder diagram.

In some applications PLCs are more used as IO interfaces for SCADA systems more than doing the controlling. If you want to make Arduino board to look like PLC from SCADA point of view, you can put in software that make it to communicate with MODBUS or other suitable SCADA protocol. One easy way to experiment is to try SCADA for Arduino that includes both Arduino software and SCADA software. I tried it and you can read my experiences with it at Experimenting with SCADA for Arduino posting.

If you are worried if your Arduino based rat’s nest would survive in industrial environment or would be accepted by industrial control people, it is a good idea to to consider available Arduino compatible products designed for industrial control applications. There are now several commercial products built for Arduino PLC applications:

CONTROLLINO advertises to be first software Open-Source PLC. It is ARDUINO compatible.It started as Kickstarter project, but is now available directly from manufacturer web site. It advertises to be designed  to control your Internet of Things and be CE & UL certificated. For more details check the video ARDUINO + PLC = CONTROLLINO

Industruino is an Arduino compatible industrial controller. Industruino is a fully featured Arduino Leonardo compatible board housed in a DIN-rail mountable case + prototyping area + onboard LCD + membrane panel. With this product you will be able to permanently install your Arduino application to industrial. Industruino is a pre-built solution offering a range of industrial voltage level I/O. All controlled with the ease of Arduino coding.

Industrial Shields has a selection of Arduino compatible industrial PLC hardware that can be plugges to DIN rail. The ARDBOX PLC, as it uses an Arduino UNO or Arduino LEONARDO, lets you program it through the USB. M-DUINO family is based on Arduino Mega. This PLC can be programmed using the Arduino IDE platform


BieMme Italia offers Soft PLC Arduino which is based on Advanced Arduino Relay Shield. You plug your Arduino to this shield, and it should be then industrial compatible with the control voltage and electrical protection. BieMme Italia also has Bmini All-in-one that has 4 optoiso­lated 24V dig­i­tal inputs, 4 high qual­ity relays, 8 ana­log inputs, PWM, I2C, RS485, Eth­er­net and more.





  1. Tomi Engdahl says:

    The Arduino team has announced a new piece of software for its Arduino Pro range, aimed at the upcoming programmable logic controller engineer: the Arduino PLC IDE.

    Arduino PLC IDE Blends the Worlds of Programmable Logic Controllers and Arduino Sketches
    Designed to support all major PLC programming languages plus Arduino sketches, the Arduino PLC IDE is a new venture for the company.

    The Arduino team has announced a new piece of software for its Arduino Pro range, aimed at the upcoming programmable logic controller (PLC) engineer: the Arduino PLC Integrated Development Environment (IDE).

    “With the demand for PLC programming rising due to the spread of automation in a wide range of industrial fields, we felt we had to step up for our community of budding and experienced engineers,” the company writes of its latest software release. “That’s why we have just launched a dedicated Arduino PLC IDE, which supports the five languages defined by the IEC 61131-3 standard: Ladder Diagram, Functional Block Diagram, Structured Text, Sequential Function Chart and Instruction List.”

    The software, available to all, is designed to combine traditional PLC programming and Arduino sketch programming in a single environment. A range of libraries are included, supporting features including embedded machine learning and no-code Fieldbus configuration for CanOpen, ModBus RTU, and ModBus TCP.

    The launch comes a month after Arduino launched Opta, its first-ever “micro PLC,” based on the STMicro STM32H747XI and designed for use in the Industrial Internet of Things (IIoT).

    More information on the Arduino PLC IDE, which uses a more detailed interface than the traditional Arduino IDE, is available on the Arduino Pro site

  2. Tomi Engdahl says:

    An Affordable And Programmable PLC

    We’re all used to general purpose microcontroller boards such as the Arduino or its many imitators, but perhaps we don’t see as much of their industrial cousins. A programmable logic controller (PLC) is a computer designed to automate industrial machinery, and comes with protected interfaces and usually a specific PLC programming environment. Thus [Galopago]’s work with an inexpensive Chinese PLC clone is especially interesting, providing a route forward to using it within the Arduino IDE ecosystem.

    Opening it up, the processor is identified as an STM32F103, and the connection needed to place it in bootloader mode is identified. Then it can be programmed from the Arduino IDE, even though its bootloader can’t be changed. Then to complete the process it’s necessary to identify the various different inputs and outputs by old-fashioned hardware reverse engineering.

    Repurposing a PLC clone for use with Arduino

    Attack of the clonesPermalink

    These boards mention compatibility with GX software, which is manufactured by a Japanese company that makes PLC and also cars. At first sight, the compatibility is not official, as no trademark is printed. Their origin is unknown, maybe they were simplified copies based on original schematics and source code, or somehow the native binary format of the PLC was reverse engineered and an interpreter was built and runs in the microcontroller translating the code. Most of the cards are based on STM32 microcontrollers, and according to some articles and videos, the original programming software actually recognizes them as an original PLC!

    Due to their low cost (around $25 USD), and for their relay isolated outputs, optically isolated inputs, RS232 serial port and regulated power supply, are great candidates for small projects as long as they can be programmed with a free multi-platform tool like Arduino or STM suite. In addition, a schematic diagram is needed to find out which I/O of the microcontroller goes to which peripheral in the board!

  3. Tomi Engdahl says:


    I’m looking for a new PLC to try out some automation and I/O integration for various projects and I was wondering what peoples go to or favorite PLC / Logic controllers are?

    I have some “Ideal Specs” that I normally look for on a good number of projects I will list below, but if your favorite doesn’t check all the boxes I would still like to know it and what you like about it!

    Ideal PLC Spec’s
    - Ethernet Connection
    - TCP/IP Communication (UDP is a plus)
    - DC Power/Logic (12V/24V)
    - High Speed Inputs (Not all but some)
    - Sink/Source Outputs (Prefered over Relay)
    - Analog I/O (Can be an add-on module)
    - Prefer Function Block Diagram or Scripting Programming
    - LCD Screen is a plus or a cheap HMI

    Any and all recommendations would be great! Looking online hasn’t shown much for being able to easily compare different manufactures

    I think you can get all or most of those features in just about any PLC line. Mostly comes down to which particular CPU and IO modules you select. I don’t have a huge amount of experience in this area, but for getting started without spending a huge amount of time and money check out Automation Direct. I’ve used their Click line which is very good value for money, but they have a few other lines that I think are more sophisticated, and they have great documentation right there on the website that should help narrow down what you need.

    For the HMI, often those are pretty straightforward to connect as an outboard device. You’d create all of the screens in a tool specific to the HMI and then set up a mapping for registers and bits between the HMI and whatever PLC.

    Andrew Berry I agree with automationdirect, the Click PLCs are very easy to use.

    I haven’t tried many, but if I don’t need anything coded I usually go for Siemens Logo. For relatively simple things it’s great, easy to make projects involving multiple units via network, and show and adjust parameters via the built in display. Being able to change the programming via micro SD has been a life saver. It’s not sexy or flashy, but for projects where it’s a good choice it’s probably the best choice.

    If code is needed I go for Controllino, but I’m also very curious about the new Arduino Opta. (the latter is a lot more PLC-like than the Controllino, which essentially is an Arduino on a DIN rail with 12/24V IO)

    Some day I’ll take the plunge into Beckhoff. Having hardware modules for stuff like DMX, DALI and AC/DC dimmers is very tempting, and they’re quite popular in the entertainment/staging space.

  4. Tomi Engdahl says:

    “For those on track to become electrical engineers, this may end up being a stepping stone between the two worlds.”

    Make: Magazine recently featured the new Arduino PLC IDE.

    Arduino Brings PLC Features To Their IDE

    Admittedly, most makers in their workshop aren’t going to harness this. However, for those on track to become electrical engineers, this may end up being a stepping stone between the two worlds.

  5. Tomi Engdahl says:

    Arduino Opta is a micro PLC for industrial IoT applications
    Arduino has recently announced the Opta micro PLC with industrial IoT capabilities adding yet another solution to the Arduino Pro family.

  6. Tomi Engdahl says:

    In this video, YouTuber Jakob Sagatowski takes a first look at the newly released Arduino PLC IDE. Watch as he takes you through the complete process of installing the IDE and configuring the Arduino Pro Portenta Machine Control to run a simple PLC program.

    Arduino PLC

  7. Tomi Engdahl says:

    Following the release of the new Arduino PLC IDE, Control Automation has put together a tutorial that introduces programming and understanding of the function blocks common to all IEC 61131 languages, starting with bit commands, timers, and counters.

    How To: Use the Arduino PLC IDE to Build Basic Ladder Diagrams

  8. Tomi Engdahl says:

    The RevPi has a strange new Raspberry Pi

    Thanks to Revolution Pi for sending this RevPi Connect S along with the Compute Module 4S.


    00:00 – Revolution Pi’s problem – no Pis!
    00:43 – Compute Module 4, with an S
    02:27 – Delidded, accidentally
    03:26 – A drop-in replacement (mostly)
    03:51 – DIN-rail industrial computer
    04:39 – The biggest downside

  9. Tomi Engdahl says:

    Control Automation’s new Arduino PLC IDE tutorial shows how to connect various peripheral devices, such as a VFD and a six-axis robot, to the Portenta Machine Control using analog inputs and outputs.

  10. Tomi Engdahl says:

    DirectIndustry highlights three new products released in 2022 that represent a major step forward for the industries they are serving, including the Arduino Pro Opta!

    “By adopting Opta, industrial engineers can implement an easy-to-use and affordable PLC in their stack without the long learning curve required by other established solutions.”

  11. Tomi Engdahl says:

    Arduino PLC

    The Arduino PLC and the Arduino PLC IDE… there has been a lot of buzz around it since it was announced recently. I’m a long-time user of the Arduino eco-system and have been using their IDE for over 10 years for various projects. Guess if I was surprised when they released their new IDE aimed at the industrial automation industry! The Arduino PLC IDE only supports one board right now, the Arduino Portenta Machine Control, and luckily I had just been using one of these boards for another project recently, so I could try the new PLC IDE that Arduino have released.

    0:00 Introduction
    3:10 Download & installation
    7:25 First start & impressions
    15:46 Version control?
    18:31 OOP
    20:11 Connect to PLC
    26:13 License activation
    28:11 Compile & online change
    34:25 Wrap-up

  12. Tomi Engdahl says:

    Check out this video to learn how Jakob Sagatowski makes an Arduino Portenta Machine Control talk to a Beckhoff Automation PLC via Modbus TCP.

  13. Tomi Engdahl says:

    Arduino-pohjainen laite teollisuuden tiedonkeruuseen

    Linux-pohjaisia Teollisuustietokoneita ja IoT-ohjaimia kehittävä taiwanilainen Artila on julkistanut äskettäin uuden 32-bittisen Arduino-pohjaisen ohjelmoitavan IIoT-alustan. Matrix-310 sisältää suorituskykyisen ohjaimen (ESP32) ja helppokäyttöisen ohjelmiston (Arduino IDE). Nämä yhdessä tekevät siitä monipuolisen ja vankan teollisuustasoisen tiedonkeruualustan IIoT-sovellukselle.

    Matrix-310:ssä on kaksi sarjaporttia ja digitaali I/O-liitännät, mikä tekee siitä ihanteellisen reaaliaikaiseen seurantaan, ennakoivaan ylläpitoon sekä tehdassovellusten, kuten teollisuusautomaation, ympäristön valvonnan ja muiden älykkäiden sovellusten optimointiin ja käyttöönottoon.

  14. Tomi Engdahl says:

    EDATEC CM4 Industrial – An Raspberry Pi CM4 computer for IIoT, automation, and industrial control

    EDATEC CM4 Industrial is both a Raspberry Pi CM4 carrier board and a computer for industrial IoT, control, and automation that expands on the company’s CM4 Sensing and CM4 Nano solutions with more features and interfaces.

  15. Tomi Engdahl says:

    “While the Arduino organization has been making industrial single-board computers for a while, it has finally taken the plunge and produced a complete industrial product – an industrial controller called Opta.”

  16. Tomi Engdahl says:

    Arduino OPTA: how do we cook it?

    The last born is OPTA, a micro-PLC, developed in collaboration with Finder, which contains Portenta H7, the princess of the PRO line.

    On the official website it is presented as “The secure, easy-to-use micro-PLC with Industrial IoT capabilities, supporting Arduino programming experience and PLC standard languages.”

  17. Tomi Engdahl says:

    Introducing the Arduino Opta microPLC
    The intersection of Industrial Automation and Embedded Systems

  18. Tomi Engdahl says:

    Arduino Industrial 101 is an Evaluation board for Arduino 101 LGA module. The ATmega32u4 microcontroller is integrated in the baseboard. The module supports a Linux distribution based on OpenWRT named LininoOS. The board has built-in WiFi (IEEE 802.11b/g/n operations up to 150Mbps 1×1 2.4 GHz), 3 GPIOs (of which 2 can be used as PWM Outputs), 4 Analog Inputs, 1 USB, 1 Ethernet signal on pin headers and a built-in DC/DC converter. Check out the assembling guide and simply connect your board to a computer with a micro USB cable to get started.

  19. Tomi Engdahl says:

    Finder Opta Advanced OHJELMOITAVA LOGIIKKARELE (PLR) Modbus+Wifi+BLE

    Finder 8A. – Arduino pohjainen uusi 8A-sarjan PLR ohjelmoitava rele

    209,90 €


    Finder 8A. – Arduino pohjainen uusi 8A-sarjan PLR ohjelmoitava rele

    145,50 €

  20. Tomi Engdahl says:


    Seuraa kaikkien kodinkoneiden, sähköpiirien ja toimistolaitteiden (valot, sähköjohdot, turvajärjestelmät, lämmitys ja jäähdytys jne.) kulutusta erikseen. Laite näyttää myös aurinkopaneeleilla tuotetun sähkön. EM sisältää myös suojauksen ylikulutukselta – rele katkaisee piirin välittömästi, jos se havaitsee kulutuksen, joka on suurempi kuin määritetty tehoasetus.

    Erittäin nopea prosessori – ESP32
    WiFi-käyttöinen – Yhdistyy Wi-Fi-verkkoon. HUBia ei tarvita!
    Parannettu turvallisuus – Yliteho-, ylijännite- ja ylilämpösuojaus.
    Tukee yleisimpiä integraatioita kuten Alexa, Google, Smart Home, Smart Things jne.
    Sisäiseen muistiin tallentuu jopa 365 päivän historiatiedot, mikäli Wi-Fi ei ole käytettävissä
    Jännitteen mittaus ja konfiguroitava hälytysraportointi

    Teknisiä tietoja

    kantama sisätiloissa n. 30m, ulkona vapaassa tilassa 50m
    kaksi itsenäistä max. 120 A mittauskanavaa
    käyttösähkö 110-230VAC ±10%, 50/60Hz
    kontaktorin ohjaus MAX 2A

    69,00 €

  21. Tomi Engdahl says:

    The Arduino PLC IDE enables you to program the Arduino Pro Opta using the five programming languages defined by the IEC 61131-3 standard, including ladder diagram. Control Automation’s new tutorial details how to create your first Opta ladder logic program and take advantage of the micro PLC’s built-in I/O for an easy introduction to the platform.

    Ladder Logic for the Arduino Opta PLC: Creating Your First Program

    Arduino’s Opta mini PLC platform is supported by the new PLC IDE. Learn to create and download your first program and take advantage of built-in I/O for an easy introduction to the platform.
    Arduino, the company known and loved around the world for introducing students and professionals to the world of electrical engineering, has made a push in the past year to capture a foothold in the industrial marketplace.

    What Arduino Board Supports PLC Programming?
    Two new hardware platforms have been launched recently to meet various needs in the industrial environment. One of these, the Portenta Machine Control (PMC), was the first to be officially supported by the PLC development software for which you can find tutorials for basic discrete I/O control and more advanced analog and device connections.

    The second platform, the Arduino Opta, has more recently been added to the list of hardware officially recognized in the PLC IDE. To get started with your very first PLC project on this platform, follow the following program and troubleshooting steps to set up success.

    Before getting started, it is recommended to download the most recent version of the IDE and the tools (both free and available from the official Arduino software site). Install both packages, which as of this writing, are version 1.0.3, which indeed supports the Opta platform.

    After installation, open the software, and create a new project. Give it a name, which I will reference for my own project as Opta_Test_2 from this point forward, and be sure to select ‘Opta 1.0’ as the target.

    Create a New Ladder Diagram Program
    The default ‘main’ program created is structured text (ST). This is a great platform to work with, but for automation engineers, ladder diagrams are often the go-to, so this article uses ladder logic.

    To create this new Ladder Diagram interface, navigate to the ‘project’ tab (lower left corner). You should see a ‘main’ up near the top, and it will have a default counter program, all in structured text.

    To create the new LD program, first click on the top-level tree project name, as you can see in the image below–mine is ‘Opta_Test_2’. If you don’t select the top-level project tree, the options for ‘New program’ will be grayed out.

    Select a New program, and you can choose the type, name, and how it will run. ‘Fast’ means that it will be continuously running in a cyclic fashion.

  22. Tomi Engdahl says:

    Open Smart Kit

    Open source, flexible, modular hardware modules with Home Assistant compatibility for any of your automation needs

  23. Tomi Engdahl says:

    “Arduino’s foray into the industrial packaging sector offers an interesting proposition for machinery builders. With a combination of open-source flexibility, rapid development, and tapping into an already Arduino-familiar workforce, their offerings align with the evolving needs of the industry.”

    Read more on OEM Magazine about how the Arduino Pro product line provides efficient solutions to the challenges facing packaging OEMs:


Leave a Comment

Your email address will not be published. Required fields are marked *