Sunday, 30 November 2014

Multiple Outputs Analogy

We are now at ease working on multiple outputs and I hope that we are ready to tackle some more questions but with some new things are to be learnt. Let us make this a bit interesting and let us introduce multiple outputs as well.
Now we will take multiple inputs and multiple outputs. The inputs would be same for all the outputs yet the set of control instruction for each output will be different. Let’s take an example:


A
B
SUM
CARRY
0
0
0
0
0
1
1
0
1
0
1
0
1
1
0
1
We need to implement a half adder that adds two bits and output is SUM and Carry.
Let’s design a truth table for it first here we are adding two bits and hence forth we will get sum and carry

1.   When A = 0 and B = 0 in that case no sum is generated as well as no carry
2.   In case when A = 0 and B = 1 the sum will be 1 and no carry will be generated.
3.   Similar to the upper case the sum will be 1 and carry zero when A = 1 and B = 0.
4.   For the last case we see that both the inputs A and B are high and therefore their sum will be 10; i.e. 0 will be considered as sum and 1 will be carry.
In case we have to design relay logic for such an case or simply we want to verify the half adder logic electrically using switches in that case we consider the switches to be A & B, and definitely we have two outputs here Sum and Carry; so two relay coils.
A
B
SUM
0
0
0
0
1
1
1
0
1
1
1
0
Keep in mind the outputs are separate they have no influence on each other as well they have different logics of operation.
Let us consider the table for Sum first.
The output turns ON in only two conditions first when
 A=0 and B=1 or second when A=1 and B=0.
Check out the highlighted words and they will tell you about how to get a Boolean equation from them
 Let us design the relay logic for the SUM first
 Negated switch that is A (bar) or B (bar) are notified by NC switch where else Normal switch by NO. A dot(.) between two switches shows they are connected in series and a sign of +(sum) tells they are parallel to each other
Keeping this in mind we can design the relay logic diagram for them.
Once done let us turn towards the second output that is carry.
Checking out the truth table it can be clearly figured out that the output for the CARRY goes high in only one condition A = 1 and B = 1, i.e. both the switches are pressed or inputs high.
As there is only one condition we will have a equation such as;
A . B  =  CARRY
Hence forth the relay logic for this can also be easily penned, need not to make a separate diagram just use the same line and neutral from the previous figure, in the same way that we have in our home separate switchers for fan and lights but they all are connected parallel through the same power supply.


Three switch Analogy





Now when we already know how to design a control logic for a 2 switch input let us proceed further now taking 3 input switches and solving some questions on them;

Ex 1:- Given three switches I1, I2, I3 to control the O/P, it is mandatory that all the three switches are pressed together to activate the O/P.

I1
I2
I3
O/P
0
0
0
0
0
0
1
0
0
1
0
0
0
1
1
0
1
0
0
0
1
0
1
0
1
1
0
0
1
1
1
1

Let us check out the question first so that we can pull out a truth table from it which will tell us that on what condition of the switches the output was ON or the relay coil was ON.

Just like a general truth table we put the inputs on one side and output on another one.

Each input will have only two conditions but when connected to each other that might raise upto 8

Now keeping in mind,

1     =  pressed

 0  =  released (no action)

We need to find out on which situation the output turn ON(high).

Recalling the question we find out a specific line “all the three switches are pressed together to activate the O/P” that verifies that the output will turn ON when all the switches (inputs) are pressed(1).

1
1
1
1

Hence forth the output will turn on when    I1 = 1,     I2 = 1, and I3 = 1.

Checking out the status of the switches and will give us there types and as the situation in which the output turns ON is when   I1 is pressed(1) and  I2 is pressed(1), and I3 is pressed(1), it provides us the relation between the inputs. i.e. AND gate.  Hence forth the Boolean equation can be deduced, i.e.

I1 . I2 . I3 = O/P

Now let’s pen down the relay logic diagram for the given Boolean equation that is easy just keep in mind the simple logics that we have created.
 
 

Power and Control Circuit

 
 
 
 
While designing the Relay Logic you might have noticed that every time for an output we do connect a relay coil, yet the relay coil is only one side of complete control system. The coil might be of a relay or contactor but in both cases if you recall we have a NO, and NC on the other side. Both function differently when the coil is energized. One makes the contact while the other breaks it. And as the particular output is connected to these NO and NC side the logic alone can’t define the procedure through which we have acquired this control. And we need an additional circuit that tells us how the load is connected to the relay/contactor’s NO/NC side and what work it might do.
Control Logic/Circuit
For example if we say that we are given a NO switch and want the motor connected to it to turn off whenever the switch is pressed.
The first thought that comes to our mind is that it is not possible as a NO switch makes contact when pressed so there is no way it can turn off the output as it will make the current flow through it.
But here we do miss one thing that we do energize a relay coil by a switch not the load (motor), and every relay has a NO and NC. NO which makes the contact when energized and NC which breaks the contact when energized so just we need to do is connect the motor to the NC side.(click here to check out relay working)
Now if we recall that the switch is connected to the relay coil, and the motor to NC side of the relay. Now pressing the switch energizes the relay coil which will break the contact with NC and henceforth the supply to the motor will be broken.
Power Circuit
Yet the issue still persists that the relay logic design only clarifies about the logic that controls the relay coil called the Control Circuit.
This control logic provided no clue of which contact (NO or NC) is used to connect the load. Hence a circuit diagram should be drawn to clarify the connections of load through contactor/relay, this circuit diagram usually contains 3-phase loads and draws a lot of power hence the name Power Circuit.
For further clarification check out the diagram of power and control circuit.

Universal Gates




                  There is very less we have to recall about the universal gates as they are the most used and most asked ones in Boolean equations, yet we are here to draw out the required Relay Logic that fulfills each and every situation that can be created using two different inputs generated by a switch or by an sensor.
Let us start with NAND followed by NOR and at last we will check out one of unusual situations that can be created.

NAND Gate :-
                In general NAND gate can be termed as an inverted AND gate as for an AND gate the output turns ON when all the inputs provided to this gate are high. But for NAND it is OFF/low (0) when all the inputs are high and for all other conditions the output is ON/high (1).


Let us check out the truth table and using it we will derive an Boolean equation.

Checking out the truth-table we see that there are three conditions at which the output of such an gate is high

1.    When A = 0 and B = 0; i.e. When A=0(released) and B = 0(released)
2.    When A = 0 and B = 1; i.e. When A=0(released) and B = 1(pressed)
3.    When A = 1 and B = 0; i.e. When A=1(released) and B = 0(released)

All the three conditions will turn the output ON but for each instance only one condition can be there, i.e. either 1 or 2 or 3.
So here we can draw out an complete Boolean equation for our output checking out condition 1 when we have A=0 ‘and’ B=0 the word ‘and’ signifies here the use of AND function between them
i.e.       
switch or input that has an status zero will be denoted by negated switch that is A(bar)

Similarly we have for condition 2 and 3
But these all condition will never be there together i.e. only one condition can persist at a time either 1 or 2 or 3. The word 'or' has a specific significance here and tells about the function of OR gate b/w them; i.e. either of the three condition should be satisfied to turn ON the output.
Now combining all the three equations we get
Once we have received such an equation for an output this is very easy to design a relay logic for the same only we need to recall the logic we have established regarding switch status(pressed or released), input(0 or 1), and  switch type(NO or NC), 


It notifies that for a low input we use a negated input and it is replaced by a NC(Normally connected) switch when implemented in RLD.
Similarly for a high input we use a normal input and it is replaced by a NO(Normally open) switch when implemented in RLD.

Hence forth we get this relay logic using the Boolean equation.

In the same way we can pull out a relay logic diagram for NOR Gate