Question about programming (Logic gates)

Artronix

Mar 19, 2012
2
Joined
Mar 19, 2012
Messages
2
I'm fairly new to programming, I am pre-registered for a PLC and Microprocessors class starting in mid May for summer. Me and my father purchased this "PLC similar" module called DMT912A and was purchased from Digitec. It is basically just a device in which you can use the normal functional logic gates with its software to program whatever may be needed. My question is, we are having a difficult time creating a type of alternator with the gates.  The alternator is used for Motor 1 and Motor 2 for a pump station to maintain water levels, looks to work almost like a relay but not quite. It is very hard to explain but I will try if needed, my main question is if it is possible to make something similar to how an alternator works by using logic gates?

 

Twidget

Apr 13, 2012
7
Joined
Apr 13, 2012
Messages
7
Hello Artronix, I can try and give you a hand with your PLC problems. I am a bit confused with your terminology, but before we get into your problem, here is some general PLC knowledge to get you started.

A PLC is a Programmable Logic Controller. It was developed in 1969 for General Motors. The PLC mimics relays and is configurable/reprogrammable. Before the PLC, when their was a change to a production line, electricians would have to rewire a rats nest of relays and switches.
april_wire_side.jpg
One single PLC can replace 1,000's of switches and relays, making installations and modifications an easy endeavor. Today the PLC is used as a controller in industrial automation process.

PLC's use whats called "Ladder Logic" as its programming language. Its a simple, graphical interface that was intended to give electricians the ability to modify a program without requiring the need to learn Assembly or Machine code.

To understand ladder logic programming you can think of the Ladder "rails" as power rails, a "rung" will connect power rails together, with "logic" riding the rails.

"Logic" is simple and there are just a few simple symbols you need to remember; Inputs | |, Outputs ( ), and Functions [ ].

This is what a PLC ladder looks like:
scaled.php


Keeping it simple, inputs are either, N.O. (Normally Open), or N.C. (Normally Closed). Just a note, there are a few other types of inputs but NO & NC are simple and used most often. Any symbol that has two horizontal lines is an input | |. If the lines are open the input is N.O., if there is a slash the inputs are N.C.

An output is designated by ( ). an output can be something that is connected to the PLC or it can refer to an Internal relay or input within the PLC.

A function [ ], not pictured, is a box. The function of the box will be something like a counter, compare, math, etc.

If an input is energized, the current will flow to an output, turning the output on, or "changing the state".
scaled.php

So, a PLC does not use Logic Gates. There are equivalent operations to and, or, nand, xor, etc. but it's important you understand a PLC is not a field-programmable gate array (FPGA).
---------------------------
But back to your question,

I am going to assume that by 'alternator' you are not talking about a power generating device. I'm almost positive your intention is to:

Turn on a pump to fill a tank;
Turn off the pump when tank is full;
Turn on another pump to empty the tank;
Stop the pump when empty and repeat;

scaled.php


You have a few parts you would need to set up. A low level sensor, a high level sensor, and two motors/pumps.

Your two sensors are inputs
your two motors are outputs

The trick with this problem is to use interlocks.

Also you need to 'Latch' your pump on and reset the latch when a level sensor is toggled.

I hope this helps, I can write more latter but its late and I must sleep. Good luck and take a look at http://www.thelearningpit.com/lp/logixpro.html

 

Twidget

Apr 13, 2012
7
Joined
Apr 13, 2012
Messages
7
Im going to assume you’re no longer looking for help so I will not finish the lesson

 
Top