:: The Circuits and Boards

In the following pictures are the PLC circuit schemes and the circuit boards in PCB.

Click them to enlarge:

-> Virtual PLC Scheme

-> Virtual PLC
PCB MainBoard (two sides)

-> Virtual PLC Output Scheme Board

-> Virtual PLC Output PCB Board

-> Virtual PLC Input Scheme Board

-> Virtual PLC Input PCB Board

:: Project Study

Is described below in more detail the operation of each of the PCB boards that form the virtual PLC and the principle of operation of each of the main components.

Main Board

The main board is controlled by PC through the RS232 serial port through which receives the clock and control signals in addition sending and receiving data from the respective inputs and outputs in serie format.
This board contains 4 integrated 4021, connected in cascade, that work as parallel-to-serie converters, these integrated periodically collect the information in the status of inputs and send them to the PC after conversion to the serie format.

Another 4 integrated 74HCT4094, also connected in cascade, are also shift registers that run, in this case, as serie-to-parallel converters.
hey have a circuit of memorization of state for each output (latch).
These circuits receive the PC information in serie format, decoding it with the help of the control signals sent by the PC and also activate the output that the monitoring program designate.

The diode D1 to D3, with the respective current limiting resistors R1 to R3, limiting the levels of signal from the port series, which normally are +12 V and -12V, 4.7 V (value of zener) and -0,6 V (voltage of zener barrier polarized directly).

The LEDs D5 to D36 and respective current limiting resistors, allow the visibility of the logical levels that exist in 32 outputs.

The 32 inputs have their polarization resistors for showing a logical high level when not in use.

The supply has an integrated voltage regulator, +5 V, 7805.

The 1N4001 diode protects against inversions of the circuit voltage.

Output Interface Board

This board has 8 relays of 24V and can command up to 8 different devices.
It connects to the main board through a 20 pins IDC connector.

To reconcile the signals of 5V the shift registers with 24V of relays, was used an integrated ULN2803, fed to 24V, with 8 inputs and outputs and the ability to supply current to the excitement of the relays.

The main board holdsup to 4 output boards, for a total of 32 outputs.

Input Interface Board

The board of input interface is built based on 8 optic coupler isolation for the circuits on outside.
Therefore it has ability to 8 independent inputs and connects to the main board, as the board of outputs, through a 20 pins IDC connector.
The main board holds up to 4 input boards, for a total of 32 inputs.

:: Objective

The objective of this project is the completion of a virtual PLC.
After some research i chose a circuit witch i found in the magazine elektor No. 204, which also contained links to the page of the author, on the Internet, where I found more information and references to the same assembly.
The referenced assembly, which i called virtual PLC, is a PLC implemented in two parts;

1) One part of Hardware, consists in 3 PCB boards:
The main board, which corresponds to the circuit for interface with the PC and selection circuits of inputs and outputs, done with the use of placement records, still incorporating IDC connector of 20 pins for connection to the boards of inputs and outputs. This board has the capacity of 32 inputs and 32 outputs.

The input board with capacity for 8 independent inputs and has also a 20 pins IDC connector for interface with the main board by a 20 wires plan cable. The link with the outside is made through 8 optical wavelength for a good insulation of the main board in relation to the outside.

The main board can support up to 4 input boards. The output board with capacity for 8 independent inputs and has also a 20 pins IDC connector for interface with the main board by a 20 wires plan cable. The outputs are switched through relays. The main board can support up to 4 output boards.

2) The other part is implemented on PC. The author of the project has established a program to control the virtual PLC that still incorporates an interpreter of the programming language "ladder." Therefore, the PC, where is made all the virtual PLC programming according to the task we want it to execute. In this case i chose to schedule it as irrigation PLC for garden.

:: What's Virtual PLC?

The commons PLC's (Programmable Logic Controllers) are micro controller circuits boards used for automation of industrial process...