How to Make DIY Arduino Based PLC

Introduction

Programmable Logic Controllers or PLCs play an essential role in automating industrial processes, but they can quickly become costly. With the advancement of technology, it is now possible to create a cost-effective PLC using commonly available materials and equipment. The advent of the Arduino microcontroller has enabled many hobbyists and engineers to design their PLCs. In this article, we will outline the key steps and components required to create a DIY Arduino based PLC. We’ll also highlight the following components: Arduino Nano, ULN2003A IC, PC817 Optocoupler, and MC34063 IC, which are essential for building an efficient and powerful DIY PLC.

Explanation of DIY Arduino Based PLC

Arduino Nano:

Arduino Nano is a compact and easy-to-use microcontroller board based on the ATmega328P microcontroller. It is similar to the Arduino Uno but smaller in size and comes with a micro USB port for power and programming. The Nano has 14 digital input/output pins (six of which can be used for PWM), eight analog inputs, and onboard power regulation.

The digital input/output pins make it easy to interface with sensors and other digital devices while the analog inputs allow measurement of voltage or resistance levels. The Arduino Nano can be programmed using the Arduino Integrated Development Environment(IDE), which is a free and open-source tool. The Nano is widely used in DIY projects, including building a homemade PLC.

ULN2003A IC:

The ULN2003A IC is a high-voltage/high-current transistor array. It is a Darlington pair module containing seven open collector Darlington pairs with common emitters. The ULN2003A can be used in a wide range of applications, including driving DC motors, stepper motors, and solenoids.

The ULN2003A IC has an input voltage range of 5V to 35V and can handle a maximum continuous current of 500mA per channel. It is a useful component in building a DIY PLC since it allows the control of several devices with a single output pin.

PC817 Optocoupler:

The PC817 Optocoupler is an optical isolator designed to transfer electrical signals between two circuits while providing electrical isolation between them. The component’s function is to protect the Arduino from the high voltage and current, which may cause permanent damage or malfunction. The Optocoupler provides a safe and effective way to control high voltage devices in a DIY PLC.

The PC817 Optocoupler consists of an LED and a phototransistor that operate together. When the LED is powered by the controller, the phototransistor conducts to permit the flow of current to the connected device. The PC817 Optocoupler is a critical component in a DIY PLC since it ensures safety and protection of the microcontroller unit.

MC34063 IC:

The MC34063 is a DC-DC converter IC that is used to convert or regulate the voltage level between two devices. The MC34063 is commonly used in power supply circuits to step-down or step-up the voltage level. The MC34063 operates as a switch-mode regulator and has an output of up to 1.5A. The component’s function is to control the output voltage, thus protecting the connected devices.

The MC34063 IC features an internal oscillator that can be programmed using external components, allowing a wide range of frequencies to be realized. It is also straightforward to use, making it an excellent component for a DIY PLC.




How to Make DIY Arduino Based PLC
How to Make DIY Arduino Based PLC

Circuit Diagram of DIY Arduino Based PLC

This project can be designed using a few basic components. The circuit diagram of this project is shown below.

How to Make DIY Arduino Based PLC Circuit Diagram
DIY Arduino Based PLC Circuit Diagram




More Circuit Layouts



Components List of DIY Arduino Based PLC

Following is the list of all components used in this project:

  • 1 X Arduino Nano
  • 1 X ULN2003A IC
  • 5 X PC817 Opocoupler
  • 1 X MC34063 IC
  • 2 X BD139 Transistors
  • 12 X LEDS
  • 1 X 1N5809 Diodes
  • 1 X 1mH Inductor
  • 1 X 1n Capacitor
  • 1 X 470u Capacitor
  • 2 X 1u Capacitors
  • 19 X 1k Resistors
  • 10 X 10k Resistors
  • 1 X 1R Resistor
  • 1 X 3k3 Resistor
  • 4 X 8k2 Resistors
  • 2 X 680R Resistors
  • 2 X 4k7 Resistors
  • 11 X 2 Pin Terminal Block

Circuit Diagram:
Gerber files:
Ladder Maker :




Steps to Building a DIY Arduino based PLC

Step 1: Install the Arduino IDE software on your computer and connect the Arduino Nano to the USB port using a cable.

Step 2: Connect the ULN2003A IC to the breadboard and connect the digital pins of the Arduino Nano to the input pins of the IC as shown in the circuit diagram above.

Step 3: Connect the Output of the ULN2003 IC to the PC817 Optocoupler and then connect the PC817 Optocoupler output to the device you want to control as shown in the circuit diagram above.

Step 4: Install the MC34063 IC on the breadboard and connect the input pin to the power supply circuit. Connect the output of the MC34063 to the PC817 Optocoupler input.

Step 5: Write the code in the Arduino IDE software to control the device. The code will define the input and output pins, the timing, and the PWM signal settings.

Conclusion

Creating a DIY Arduino based PLC is an excellent option for hobbyists and engineers looking for a cost-effective way to automate their processes. The critical components needed include the Arduino Nano, ULN2003A IC, PC817 Optocoupler, and MC34063 IC. These components provide the necessary safety and protection to the microcontroller unit while ensuring efficient and reliable output. Building a DIY PLC has many benefits, including cost-effectiveness, customizability, and educational value. With the steps above and a clear understanding of the components required, it is easy to create a high-quality and efficient DIY Arduino based PLC.

More projects, You may like:



For more project and circuit diagrams, you can go through the Schematics in the main menu where you can find many interesting projects and circuit diagrams like audio amplifier circuits, voltage booster circuitbattery charger circuit and timer circuits etc., which are all beginner circuit projects. Feel free to check them out!

Thanks for visiting the article and watching the video.

(Visited 848 times, 1 visits today)

Leave a Reply

Your email address will not be published.