SlideShare une entreprise Scribd logo
1  sur  18
Télécharger pour lire hors ligne
1
Logic Design
BT0064 Paper-1
By Milan K Antony
2
1. Convert the following binary numbers to base 10.
a. 10101101 = 173
b. 110110.1 = 54.1
2. How AND gate can be realized using NOR gate?
The NOR gate can also be classed as a "Universal"
type gate. NOR gates can be used to produce any other type
of logic gate function just like the NAND gate and by
connecting them together in various combinations the three
basic gate types of AND function can be formed using only
NOR's, for example.
3
3. Simplify the following three-variable Boolean functions
algebraically:
a. f = 1,2,5,6∑
b. f = 0,1,2,3∑
4. Draw the circuit for 3-to-8 line decoder.
5. Write a short note on J-K Master Slave Flip-Flop.
The Master-Slave Flip-Flop is basically two JK bistable flip-
flops connected together in a series configuration with the
outputs from Q and Q from the "Slave" flip-flop being fed
back to the inputs of the "Master" with the outputs of the
4
"Master" flip-flop being connected to the two inputs of the
"Slave" flip-flop as shown below.
Master-Slave JK Flip-Flops
The input signals J and K are connected to the "Master" flip-
flop which "locks" the input while the clock (Clk) input is high
at logic level "1". As the clock input of the "Slave" flip-flop
is the inverse (complement) of the "Master" clock input, the
outputs from the "Master" flip-flop are only "seen" by the
"Slave" flip-flop when the clock input goes "LOW" to logic
level "0". Therefore on the "High-to-Low" transition of the
clock pulse the locked outputs of the "Master" flip-flop are
fed through to the JK inputs of the "Slave" flip-flop making
this type of flip-flop edge or pulse-triggered.
Then, the circuit accepts input data when the clock signal is
"HIGH", and passes the data to the output on the falling-
edge of the clock signal. In other words, the Master-Slave
JK Flip-flop is a "Synchronous" device as it only passes data
with the timing of the clock signal.
5
6. Convert the following decimal numbers to base 2:
a. 122 = (1111010)
b. 98 = (1100010)
7. List the fundamental logical gates.
While each logical element or condition must always have a logic
value of either "0" or "1", we also need to have ways to
combine different logical signals or conditions to provide a
logical result.
For example, consider the logical statement: "If I move the
switch on the wall up, the light will turn on." At first glance,
this seems to be a correct statement. However, if we look at
a few other factors, we realize that there's more to it than
this. In this example, a more complete statement would be:
"If I move the switch on the wall up and the light bulb is
good and the power is on, the light will turn on."
If we look at these two statements as logical expressions and
use logical terminology, we can reduce the first statement to:
Light = Switch
This means nothing more than that the light will follow the
action of the switch, so that when the switch is up/on/true/1
6
the light will also be on/true/1. Conversely, if the switch is
down/off/false/0 the light will also be off/false/0.Looking at
the second version of the statement, we have a slightly more
complex expression:Light = Switch and Bulb and PowerNormally,
we use symbols rather than words to designate the and
function that we're using to combine the separate variables of
Switch, Bulb, and Power in this expression. The symbol normally
used is a dot, which is the same symbol used for multiplication
in some mathematical expressions. Using this symbol, our
three-variable expression becomes:Light = Switch Bulb
PowerWhen we deal with logical circuits (as in computers), we
not only need to deal with logical functions; we also need
some special symbols to denote these functions in a logical
diagram. There are three fundamental logical operations, from
which all other functions, no matter how complex, can be
derived. These functions are named and, or, and not. Each of
these has a specific symbol and a clearly-defined behavior, as
follows:
The AND Gate
The AND gate implements the AND
function. With the gate shown to
the left, both inputs must have
logic 1 signals applied to them in
order for the output to be a logic
1. With either input at logic 0, the
output will be held to logic 0.
7
If your browser supports the
Javascript functions required for
the demonstrations built into this
page, you can click the buttons to
the left of the AND gate drawing
to change their assigned logic
values, and the drawing will change
to reflect the new input states.
Other demonstrations on these
pages will work the same way.
There is no limit to the number of
inputs that may be applied to an
AND function, so there is no
functional limit to the number of
inputs an AND gate may have.
However, for practical reasons,
commercial AND gates are most
commonly manufactured with 2, 3,
or 4 inputs. A standard Integrated
Circuit (IC) package contains 14 or
16 pins, for practical size and
handling. A standard 14-pin
package can contain four 2-input
gates, three 3-input gates, or two
4-input gates, and still have room
for two pins for power supply
8
connections.
The OR Gate
The OR gate is sort of the reverse
of the AND gate. The OR
function, like its verbal
counterpart, allows the output to
be true (logic 1) if any one or
more of its inputs are true.
Verbally, we might say, "If it is
raining OR if I turn on the
sprinkler, the lawn will be wet."
Note that the lawn will still be wet
if the sprinkler is on and it is also
raining. This is correctly reflected
by the basic OR function.
In symbols, the OR function is
designated with a plus sign (+).
In logical diagrams, the symbol to
the left designates the OR gate.
As with the AND function, the OR
function can have any number of
inputs. However, practical
commercial OR gates are mostly
limited to 2, 3, and 4 inputs, as
9
with AND gates.
The NOT Gate, or Inverter
The inverter is a little different
from AND and OR gates in that it
always has exactly one input as well
as one output. Whatever logical
state is applied to the input, the
opposite state will appear at the
output.
The NOT function, as it is called,
is necesasary in many applications
and highly useful in others. A
practical verbal application might
be:
The door is NOT locked = You may
enter
The NOT function is denoted by a
horizontal bar over the value to be
inverted, as shown in the figure to
the left. In some cases a single
quote mark (') may also be used
for this purpose: 0' = 1 and
1' = 0. For greater clarity in some
10
logical expressions, we will use the
overbar most of the time.
In the inverter symbol, the triangle
actually denotes only an amplifier,
which in digital terms means that it
"cleans up" the signal but does not
change its logical sense. It is the
circle at the output which denotes
the logical inversion. The circle
could have been placed at the
input instead, and the logical
meaning would still be the same.
The logic gates shown above are used in various combinations
to perform tasks of any level of complexity. Some functions
are so commonly used that they have been given symbols of
their own, and are often packaged so as to provide that
specific function directly. On the next page, we'll begin our
coverage of these functions.
By combining thousands or millions of logic gates, it is possible
to perform highly complex operations. The maximum number of
logic gates on an integrated circuit is determined by the size
of the chip divided by the size of the logic gates. Since
transistors make up most of the logic gates in computer
11
processors, smaller transistors mean more complex and faster
processors.Minimize the following functions using the ‘don’t
care’ terms for simplification wherever possible:
a. f(A,B,C) = 3,5 with don’t care term 0,7∑
b. f(A,B,C,D) = 1,2,3,4,5,6,7,8,9,10 with ‘don’t care’ terms∑
9, 12, 15
9. Design full-adder using only NOR gates.
First of all, NAND and NOR gates have been proven to be
logically complete. That means you can create every other
logical gate with just NANDs or just NORs. Other gate
functions are XOR, AND, OR, NOT, etc.
To clarify: The notation I am using is [NAND] represents the
NAND gate. Having A,B means the two inputs are A and B. If
there is just one input, then that input gets mapped to both
inputs. The '|' is supposed to show a junction between two
lines. '-' is a single line and '=' is a double line. The
'. . .' is just empty space, trying to keep the diagram
intact.
Some NAND designs we will need are:
AND: A,B--[NAND]==[NAND]-->out
OR: A--[NAND]--|==[NAND]--out
12
. . . .B--[NAND]--|
first NAND connects to top and bottom NANDs
last NAND has inputs taken from output of the middle two
NANDs
. . . . . . . . . . . . . . . A--|[NAND]---|
XOR: A,B--[NAND]------| . . . . . . . |===[NAND]--out
. . . . . . . . . . . . . . . B--|[NAND]---|
The second part is what a full adder is. A full adder is a
system that takes in three signals and outputs two. The three
input signals are A, B, and Cin. The two outputs are S and
Cout. The point of a full adder is that you can cascade them.
The Cout of the first becomes the Cin of the second. That
way you have a general one bit adder, but can make an N bit
adder by stringing cascading them. So the first step in
creating a full adder is writing out the truth table, a table
where inputs get mapped to specific outputs. I am going to
use '-' in place of spaces so the spacing stays the same
after I post.
Input- - - - - - - - - - - - - - - -Output
A - - B - - Cin - - - - - - - - - S - - Cout
0 - - 0 - - 0 - - - - - - - - - - -0 - - 0
0 - - 0 - - 1 - - - - - - - - - - -1 - - 0
0 - - 1 - - 0 - - - - - - - - - - -1 - - 0
13
0 - - 1 - - 1 - - - - - - - - - - -0 - - 1
1 - - 0 - - 0 - - - - - - - - - - -1 - - 0
1 - - 0 - - 1 - - - - - - - - - - -0 - - 1
1 - - 1 - - 0 - - - - - - - - - - -0 - - 1
1 - - 1 - - 1 - - - - - - - - - - -1 - - 1
It can be seen that S = [A XOR B XOR Cin]
It can be seen that C = [(A AND B) OR (A AND Cin) or (B
AND Cin)]
or equivelently (and more efficiently) C = [(A AND B) or (C
AND (A XOR B))]
10. Draw and explain the working of JK, S-R, and D flip
flops.
In The J-K Flip-Flop
This diagram, P stands for "Preset," C stands for "Clear"
and Clk stands for "Clock." The logic table looks like this:
P C Clk J K Q Q'
1 1
1-
to-
0
1 0 1 0
1 1 1- 0 1 0 1
14
to-
0
1 1
1-
to-
0
1 1
Togg
les
1 0 X X X 0 1
0 1 X X X 1 0
Here is what the table is saying: First, Preset and Clear
override J, K and Clk completely. So if Preset goes to 0,
then Q goes to 1; and if Clear goes to 0, then Q goes to
0 no matter what J, K and Clk are doing. However, if
both Preset and Clear are 1, then J, K and Clk can
operate. The 1-to-0 notation means that when the clock
changes from a 1 to a 0, the value of J and K are
remembered if they are opposites. At the low-going edge
of the clock (the transition from 1 to 0), J and K are
stored. However, if both J and K happen to be 1 at the
low-going edge, then Q simply toggles. That is, Q changes
from its current state to the opposite state.
You might be asking yourself right now, "What in the world is
that good for?" It turns out that the concept of "edge
triggering" is very useful. The fact that J-K flip-flop only
"latches" the J-K inputs on a transition from 1 to 0 makes it
much more useful as a memory device. J-K flip-flops are
also extremely useful in counters (which are used extensively
15
when creating a digital clock). Here is an example of a 4-bit
counter using J-K flip-flops:
The outputs for this circuit are A, B, C and D, and they
represent a 4-bit binary number. Into the clock input of the
left-most flip-flop comes a signal changing from 1 to 0 and
back to 1 repeatedly (an oscillating signal). The counter will
count the low-going edges it sees in this signal. That is,
every time the incoming signal changes from 1 to 0, the 4-bit
number represented by A, B, C and D will increment by 1. So
the count will go from 0 to 15 and then cycle back to 0. You
can add as many bits as you like to this counter and count
anything you like. For example, if you put a magnetic switch
on a door, the counter will count the number of times the
door is opened and closed. If you put an optical sensor on a
road, the counter could count the number of cars that drive
by.
Another use of a J-K flip-flop is to create an edge-
triggered latch, as shown here:
16
In this arrangement, the value on D is "latched" when the
clock edge goes from low to high. Latches are extremely
important in the design of things like central processing units
(CPUs) and peripherals in computers.
SR Flip-Flop
An SR Flip-Flop can be considered as a basic one-bit memory
device that has two inputs, one which will "SET" the device and
another which will "RESET" the device back to its original state
and an output Q that will be either at a logic level "1" or
logic "0" depending upon this Set/Reset condition. A basic
NAND Gate SR flip flop circuit provides feedback from its
outputs to its inputs and is commonly used in memory circuits
to store data bits. The term "Flip-flop" relates to the actual
operation of the device, as it can be "Flipped" into one logic
state or "Flopped" back into another.
The simplest way to make any basic one-bit Set/Reset SR
flip-flop is to connect together a pair of cross-coupled 2-
input NAND Gates to form a Set-Reset Bistable or a SR
17
NAND Gate Latch, so that there is feedback from each output
to one of the other NAND Gate inputs. This device consists
of two inputs, one called the Reset, R and the other called
the Set, S with two corresponding outputs Q and its inverse or
complement Q as shown below.
The SR NAND Gate Latch
D flip flops
The edge-triggered D flip-flop is easily derived from its RS
counterpart. The only requirement is to replace the R input
with an inverted version of the S input, which thereby becomes
D. This is only needed in the master latch section; the slave
remains unchanged.
One essential point about the D flip-flop is that when the
clock input falls to logic 0 and the outputs can change state,
the Q output always takes on the state of the D input at the
moment of the clock edge. This was not true of the RS and
JK flip-flops. The RS master section would repeatedly change
states to match the input signals while the clock line is logic 1,
and the Q output would reflect whichever input most recently
18
received an active signal. The JK master section would receive
and hold an input to tell it to change state, and never change
that state until the next cycle of the clock. This behavior is
not possible with a D flip-flop.
The edge-triggered D NAND flip-flop is shown below.

Contenu connexe

Tendances

Reversible logic gate
Reversible logic gateReversible logic gate
Reversible logic gateDebraj Maji
 
Digital logic gates and Boolean algebra
Digital logic gates and Boolean algebraDigital logic gates and Boolean algebra
Digital logic gates and Boolean algebraSARITHA REDDY
 
Digital Logic Circuits
Digital Logic CircuitsDigital Logic Circuits
Digital Logic Circuitssathish sak
 
Physics investigatory project for class 12 logic gates
Physics investigatory project for class 12 logic gatesPhysics investigatory project for class 12 logic gates
Physics investigatory project for class 12 logic gatesbiswanath dehuri
 
Digital electronics
Digital electronicsDigital electronics
Digital electronicsnanishajieha
 
Combinational logic With Multiplexers and Decoders
Combinational logic With Multiplexers and DecodersCombinational logic With Multiplexers and Decoders
Combinational logic With Multiplexers and DecodersHarsh Parmar
 
Logic gate implementing without using ICs by Nimay Giri
Logic gate implementing without using ICs by Nimay GiriLogic gate implementing without using ICs by Nimay Giri
Logic gate implementing without using ICs by Nimay Girinimay1
 
Introduction to Boolean Algebra
Introduction to Boolean AlgebraIntroduction to Boolean Algebra
Introduction to Boolean Algebrablaircomp2003
 
Combinational logic circuits by Tahir Yasin
Combinational logic circuits by Tahir YasinCombinational logic circuits by Tahir Yasin
Combinational logic circuits by Tahir YasinTAHIR YASIN
 
Digital logic gate and its application
Digital logic gate and its applicationDigital logic gate and its application
Digital logic gate and its applicationAbdullah Al Masud
 
boolean algrebra and logic gates in short
boolean algrebra and logic gates in shortboolean algrebra and logic gates in short
boolean algrebra and logic gates in shortRojin Khadka
 

Tendances (20)

Logic Fe Tcom
Logic Fe TcomLogic Fe Tcom
Logic Fe Tcom
 
Reversible logic gate
Reversible logic gateReversible logic gate
Reversible logic gate
 
Logic gates presentation
Logic gates presentationLogic gates presentation
Logic gates presentation
 
Digital logic gates and Boolean algebra
Digital logic gates and Boolean algebraDigital logic gates and Boolean algebra
Digital logic gates and Boolean algebra
 
Digital Logic Circuits
Digital Logic CircuitsDigital Logic Circuits
Digital Logic Circuits
 
Amit vish
Amit vishAmit vish
Amit vish
 
Physics investigatory project for class 12 logic gates
Physics investigatory project for class 12 logic gatesPhysics investigatory project for class 12 logic gates
Physics investigatory project for class 12 logic gates
 
Digital electronics
Digital electronicsDigital electronics
Digital electronics
 
EE8351 DLC
EE8351 DLCEE8351 DLC
EE8351 DLC
 
Digital electronics - Basics
Digital electronics - BasicsDigital electronics - Basics
Digital electronics - Basics
 
Combinational logic With Multiplexers and Decoders
Combinational logic With Multiplexers and DecodersCombinational logic With Multiplexers and Decoders
Combinational logic With Multiplexers and Decoders
 
Csc 2313 (lecture 4)
Csc 2313 (lecture 4)Csc 2313 (lecture 4)
Csc 2313 (lecture 4)
 
Logic gate implementing without using ICs by Nimay Giri
Logic gate implementing without using ICs by Nimay GiriLogic gate implementing without using ICs by Nimay Giri
Logic gate implementing without using ICs by Nimay Giri
 
Introduction to Boolean Algebra
Introduction to Boolean AlgebraIntroduction to Boolean Algebra
Introduction to Boolean Algebra
 
[ASM] Lab1
[ASM] Lab1[ASM] Lab1
[ASM] Lab1
 
Digital Logic Rcs
Digital Logic RcsDigital Logic Rcs
Digital Logic Rcs
 
Combinational logic circuits by Tahir Yasin
Combinational logic circuits by Tahir YasinCombinational logic circuits by Tahir Yasin
Combinational logic circuits by Tahir Yasin
 
Ch1 2
Ch1 2Ch1 2
Ch1 2
 
Digital logic gate and its application
Digital logic gate and its applicationDigital logic gate and its application
Digital logic gate and its application
 
boolean algrebra and logic gates in short
boolean algrebra and logic gates in shortboolean algrebra and logic gates in short
boolean algrebra and logic gates in short
 

En vedette

Bt8901 objective oriented systems2
Bt8901 objective oriented systems2Bt8901 objective oriented systems2
Bt8901 objective oriented systems2Techglyphs
 
Bt0074 oops with java
Bt0074 oops with javaBt0074 oops with java
Bt0074 oops with javaTechglyphs
 
Bt0067 c programming and data structures 1
Bt0067 c programming and data structures 1Bt0067 c programming and data structures 1
Bt0067 c programming and data structures 1Techglyphs
 
Bt0062 fundamentals of it(1)
Bt0062 fundamentals of it(1)Bt0062 fundamentals of it(1)
Bt0062 fundamentals of it(1)Techglyphs
 
Bt0067 c programming and data structures2
Bt0067 c programming and data structures2Bt0067 c programming and data structures2
Bt0067 c programming and data structures2Techglyphs
 
Bt9002 grid computing 1
Bt9002 grid computing 1Bt9002 grid computing 1
Bt9002 grid computing 1Techglyphs
 
Bt0074 oops with java2
Bt0074 oops with java2Bt0074 oops with java2
Bt0074 oops with java2Techglyphs
 
Bt0064 logic design2
Bt0064 logic design2Bt0064 logic design2
Bt0064 logic design2Techglyphs
 
Bt0066 database management system2
Bt0066 database management system2Bt0066 database management system2
Bt0066 database management system2Techglyphs
 
Bt0062 fundamentals of it(2)
Bt0062 fundamentals of it(2)Bt0062 fundamentals of it(2)
Bt0062 fundamentals of it(2)Techglyphs
 
Bt0066 database management system1
Bt0066 database management system1Bt0066 database management system1
Bt0066 database management system1Techglyphs
 
Bt9002 Grid computing 2
Bt9002 Grid computing 2Bt9002 Grid computing 2
Bt9002 Grid computing 2Techglyphs
 
Elements analysis dfd_er_std
Elements analysis dfd_er_stdElements analysis dfd_er_std
Elements analysis dfd_er_stdAmmar Jamali
 

En vedette (13)

Bt8901 objective oriented systems2
Bt8901 objective oriented systems2Bt8901 objective oriented systems2
Bt8901 objective oriented systems2
 
Bt0074 oops with java
Bt0074 oops with javaBt0074 oops with java
Bt0074 oops with java
 
Bt0067 c programming and data structures 1
Bt0067 c programming and data structures 1Bt0067 c programming and data structures 1
Bt0067 c programming and data structures 1
 
Bt0062 fundamentals of it(1)
Bt0062 fundamentals of it(1)Bt0062 fundamentals of it(1)
Bt0062 fundamentals of it(1)
 
Bt0067 c programming and data structures2
Bt0067 c programming and data structures2Bt0067 c programming and data structures2
Bt0067 c programming and data structures2
 
Bt9002 grid computing 1
Bt9002 grid computing 1Bt9002 grid computing 1
Bt9002 grid computing 1
 
Bt0074 oops with java2
Bt0074 oops with java2Bt0074 oops with java2
Bt0074 oops with java2
 
Bt0064 logic design2
Bt0064 logic design2Bt0064 logic design2
Bt0064 logic design2
 
Bt0066 database management system2
Bt0066 database management system2Bt0066 database management system2
Bt0066 database management system2
 
Bt0062 fundamentals of it(2)
Bt0062 fundamentals of it(2)Bt0062 fundamentals of it(2)
Bt0062 fundamentals of it(2)
 
Bt0066 database management system1
Bt0066 database management system1Bt0066 database management system1
Bt0066 database management system1
 
Bt9002 Grid computing 2
Bt9002 Grid computing 2Bt9002 Grid computing 2
Bt9002 Grid computing 2
 
Elements analysis dfd_er_std
Elements analysis dfd_er_stdElements analysis dfd_er_std
Elements analysis dfd_er_std
 

Similaire à Bt0064 logic design1

Similaire à Bt0064 logic design1 (20)

Chapter+13.ppt
Chapter+13.pptChapter+13.ppt
Chapter+13.ppt
 
Boolean algebra
Boolean algebraBoolean algebra
Boolean algebra
 
Lecture 04-Digital logic gates.pptx
Lecture 04-Digital logic gates.pptxLecture 04-Digital logic gates.pptx
Lecture 04-Digital logic gates.pptx
 
Practica 4 algebra booleana por compuertas lógicas.
Practica 4 algebra booleana por compuertas lógicas.Practica 4 algebra booleana por compuertas lógicas.
Practica 4 algebra booleana por compuertas lógicas.
 
chapter 3 Boolean algebra (2).pptx
chapter 3 Boolean algebra (2).pptxchapter 3 Boolean algebra (2).pptx
chapter 3 Boolean algebra (2).pptx
 
Basic logic gates and buffers
Basic logic gates and buffersBasic logic gates and buffers
Basic logic gates and buffers
 
logic gates By ZAK
logic gates By ZAKlogic gates By ZAK
logic gates By ZAK
 
Digital Logic circuit
Digital Logic circuitDigital Logic circuit
Digital Logic circuit
 
B T0064
B T0064B T0064
B T0064
 
Bt0064
Bt0064Bt0064
Bt0064
 
Logic gates
Logic gatesLogic gates
Logic gates
 
Combinational logic circuits design and implementation
Combinational logic circuits design and implementationCombinational logic circuits design and implementation
Combinational logic circuits design and implementation
 
Computer Organization And Architecture lab manual
Computer Organization And Architecture lab manualComputer Organization And Architecture lab manual
Computer Organization And Architecture lab manual
 
assignment_mathematics.pptx
assignment_mathematics.pptxassignment_mathematics.pptx
assignment_mathematics.pptx
 
2 gates
2 gates2 gates
2 gates
 
Ceng232 Decoder Multiplexer Adder
Ceng232 Decoder Multiplexer AdderCeng232 Decoder Multiplexer Adder
Ceng232 Decoder Multiplexer Adder
 
Sequential Logic
Sequential LogicSequential Logic
Sequential Logic
 
Module 4 Logic Circuits.pptx
Module 4 Logic Circuits.pptxModule 4 Logic Circuits.pptx
Module 4 Logic Circuits.pptx
 
9. logic gates._rr
9. logic gates._rr9. logic gates._rr
9. logic gates._rr
 
class xi pptx-1.pptx
class xi pptx-1.pptxclass xi pptx-1.pptx
class xi pptx-1.pptx
 

Plus de Techglyphs

Bt0068 computer organization and architecture
Bt0068 computer organization and architecture Bt0068 computer organization and architecture
Bt0068 computer organization and architecture Techglyphs
 
Bt0068 computer organization and architecture 2
Bt0068 computer organization and architecture 2Bt0068 computer organization and architecture 2
Bt0068 computer organization and architecture 2Techglyphs
 
Bt0070 operating systems 1
Bt0070 operating systems  1Bt0070 operating systems  1
Bt0070 operating systems 1Techglyphs
 
Bt0070 operating systems 2
Bt0070 operating systems  2Bt0070 operating systems  2
Bt0070 operating systems 2Techglyphs
 
Bt0072 computer networks 1
Bt0072 computer networks  1Bt0072 computer networks  1
Bt0072 computer networks 1Techglyphs
 
Bt0072 computer networks 2
Bt0072 computer networks  2Bt0072 computer networks  2
Bt0072 computer networks 2Techglyphs
 
Bt0075 rdbms with mysql 1
Bt0075 rdbms with mysql 1Bt0075 rdbms with mysql 1
Bt0075 rdbms with mysql 1Techglyphs
 
Bt0075 rdbms with mysql 2
Bt0075 rdbms with mysql 2Bt0075 rdbms with mysql 2
Bt0075 rdbms with mysql 2Techglyphs
 
Bt0077 multimedia systems
Bt0077 multimedia systemsBt0077 multimedia systems
Bt0077 multimedia systemsTechglyphs
 
Bt0078 website design
Bt0078 website design Bt0078 website design
Bt0078 website design Techglyphs
 
Bt0077 multimedia systems2
Bt0077 multimedia systems2Bt0077 multimedia systems2
Bt0077 multimedia systems2Techglyphs
 
Bt0078 website design 2
Bt0078 website design 2Bt0078 website design 2
Bt0078 website design 2Techglyphs
 
Bt0080 fundamentals of algorithms1
Bt0080 fundamentals of algorithms1Bt0080 fundamentals of algorithms1
Bt0080 fundamentals of algorithms1Techglyphs
 
Bt0080 fundamentals of algorithms2
Bt0080 fundamentals of algorithms2Bt0080 fundamentals of algorithms2
Bt0080 fundamentals of algorithms2Techglyphs
 
Bt0081 software engineering
Bt0081 software engineeringBt0081 software engineering
Bt0081 software engineeringTechglyphs
 
Bt0082 visual basic2
Bt0082 visual basic2Bt0082 visual basic2
Bt0082 visual basic2Techglyphs
 
Bt0081 software engineering2
Bt0081 software engineering2Bt0081 software engineering2
Bt0081 software engineering2Techglyphs
 
Bt0082 visual basic
Bt0082 visual basicBt0082 visual basic
Bt0082 visual basicTechglyphs
 

Plus de Techglyphs (18)

Bt0068 computer organization and architecture
Bt0068 computer organization and architecture Bt0068 computer organization and architecture
Bt0068 computer organization and architecture
 
Bt0068 computer organization and architecture 2
Bt0068 computer organization and architecture 2Bt0068 computer organization and architecture 2
Bt0068 computer organization and architecture 2
 
Bt0070 operating systems 1
Bt0070 operating systems  1Bt0070 operating systems  1
Bt0070 operating systems 1
 
Bt0070 operating systems 2
Bt0070 operating systems  2Bt0070 operating systems  2
Bt0070 operating systems 2
 
Bt0072 computer networks 1
Bt0072 computer networks  1Bt0072 computer networks  1
Bt0072 computer networks 1
 
Bt0072 computer networks 2
Bt0072 computer networks  2Bt0072 computer networks  2
Bt0072 computer networks 2
 
Bt0075 rdbms with mysql 1
Bt0075 rdbms with mysql 1Bt0075 rdbms with mysql 1
Bt0075 rdbms with mysql 1
 
Bt0075 rdbms with mysql 2
Bt0075 rdbms with mysql 2Bt0075 rdbms with mysql 2
Bt0075 rdbms with mysql 2
 
Bt0077 multimedia systems
Bt0077 multimedia systemsBt0077 multimedia systems
Bt0077 multimedia systems
 
Bt0078 website design
Bt0078 website design Bt0078 website design
Bt0078 website design
 
Bt0077 multimedia systems2
Bt0077 multimedia systems2Bt0077 multimedia systems2
Bt0077 multimedia systems2
 
Bt0078 website design 2
Bt0078 website design 2Bt0078 website design 2
Bt0078 website design 2
 
Bt0080 fundamentals of algorithms1
Bt0080 fundamentals of algorithms1Bt0080 fundamentals of algorithms1
Bt0080 fundamentals of algorithms1
 
Bt0080 fundamentals of algorithms2
Bt0080 fundamentals of algorithms2Bt0080 fundamentals of algorithms2
Bt0080 fundamentals of algorithms2
 
Bt0081 software engineering
Bt0081 software engineeringBt0081 software engineering
Bt0081 software engineering
 
Bt0082 visual basic2
Bt0082 visual basic2Bt0082 visual basic2
Bt0082 visual basic2
 
Bt0081 software engineering2
Bt0081 software engineering2Bt0081 software engineering2
Bt0081 software engineering2
 
Bt0082 visual basic
Bt0082 visual basicBt0082 visual basic
Bt0082 visual basic
 

Dernier

Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxRoyAbrique
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfciinovamais
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfchloefrazer622
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104misteraugie
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...Marc Dusseiller Dusjagr
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesFatimaKhan178732
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdfQucHHunhnh
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...RKavithamani
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxpboyjonauth
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingTechSoup
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdfQucHHunhnh
 

Dernier (20)

Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdf
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 
Staff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSDStaff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSD
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and Actinides
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptx
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy Consulting
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 

Bt0064 logic design1

  • 2. 2 1. Convert the following binary numbers to base 10. a. 10101101 = 173 b. 110110.1 = 54.1 2. How AND gate can be realized using NOR gate? The NOR gate can also be classed as a "Universal" type gate. NOR gates can be used to produce any other type of logic gate function just like the NAND gate and by connecting them together in various combinations the three basic gate types of AND function can be formed using only NOR's, for example.
  • 3. 3 3. Simplify the following three-variable Boolean functions algebraically: a. f = 1,2,5,6∑ b. f = 0,1,2,3∑ 4. Draw the circuit for 3-to-8 line decoder. 5. Write a short note on J-K Master Slave Flip-Flop. The Master-Slave Flip-Flop is basically two JK bistable flip- flops connected together in a series configuration with the outputs from Q and Q from the "Slave" flip-flop being fed back to the inputs of the "Master" with the outputs of the
  • 4. 4 "Master" flip-flop being connected to the two inputs of the "Slave" flip-flop as shown below. Master-Slave JK Flip-Flops The input signals J and K are connected to the "Master" flip- flop which "locks" the input while the clock (Clk) input is high at logic level "1". As the clock input of the "Slave" flip-flop is the inverse (complement) of the "Master" clock input, the outputs from the "Master" flip-flop are only "seen" by the "Slave" flip-flop when the clock input goes "LOW" to logic level "0". Therefore on the "High-to-Low" transition of the clock pulse the locked outputs of the "Master" flip-flop are fed through to the JK inputs of the "Slave" flip-flop making this type of flip-flop edge or pulse-triggered. Then, the circuit accepts input data when the clock signal is "HIGH", and passes the data to the output on the falling- edge of the clock signal. In other words, the Master-Slave JK Flip-flop is a "Synchronous" device as it only passes data with the timing of the clock signal.
  • 5. 5 6. Convert the following decimal numbers to base 2: a. 122 = (1111010) b. 98 = (1100010) 7. List the fundamental logical gates. While each logical element or condition must always have a logic value of either "0" or "1", we also need to have ways to combine different logical signals or conditions to provide a logical result. For example, consider the logical statement: "If I move the switch on the wall up, the light will turn on." At first glance, this seems to be a correct statement. However, if we look at a few other factors, we realize that there's more to it than this. In this example, a more complete statement would be: "If I move the switch on the wall up and the light bulb is good and the power is on, the light will turn on." If we look at these two statements as logical expressions and use logical terminology, we can reduce the first statement to: Light = Switch This means nothing more than that the light will follow the action of the switch, so that when the switch is up/on/true/1
  • 6. 6 the light will also be on/true/1. Conversely, if the switch is down/off/false/0 the light will also be off/false/0.Looking at the second version of the statement, we have a slightly more complex expression:Light = Switch and Bulb and PowerNormally, we use symbols rather than words to designate the and function that we're using to combine the separate variables of Switch, Bulb, and Power in this expression. The symbol normally used is a dot, which is the same symbol used for multiplication in some mathematical expressions. Using this symbol, our three-variable expression becomes:Light = Switch Bulb PowerWhen we deal with logical circuits (as in computers), we not only need to deal with logical functions; we also need some special symbols to denote these functions in a logical diagram. There are three fundamental logical operations, from which all other functions, no matter how complex, can be derived. These functions are named and, or, and not. Each of these has a specific symbol and a clearly-defined behavior, as follows: The AND Gate The AND gate implements the AND function. With the gate shown to the left, both inputs must have logic 1 signals applied to them in order for the output to be a logic 1. With either input at logic 0, the output will be held to logic 0.
  • 7. 7 If your browser supports the Javascript functions required for the demonstrations built into this page, you can click the buttons to the left of the AND gate drawing to change their assigned logic values, and the drawing will change to reflect the new input states. Other demonstrations on these pages will work the same way. There is no limit to the number of inputs that may be applied to an AND function, so there is no functional limit to the number of inputs an AND gate may have. However, for practical reasons, commercial AND gates are most commonly manufactured with 2, 3, or 4 inputs. A standard Integrated Circuit (IC) package contains 14 or 16 pins, for practical size and handling. A standard 14-pin package can contain four 2-input gates, three 3-input gates, or two 4-input gates, and still have room for two pins for power supply
  • 8. 8 connections. The OR Gate The OR gate is sort of the reverse of the AND gate. The OR function, like its verbal counterpart, allows the output to be true (logic 1) if any one or more of its inputs are true. Verbally, we might say, "If it is raining OR if I turn on the sprinkler, the lawn will be wet." Note that the lawn will still be wet if the sprinkler is on and it is also raining. This is correctly reflected by the basic OR function. In symbols, the OR function is designated with a plus sign (+). In logical diagrams, the symbol to the left designates the OR gate. As with the AND function, the OR function can have any number of inputs. However, practical commercial OR gates are mostly limited to 2, 3, and 4 inputs, as
  • 9. 9 with AND gates. The NOT Gate, or Inverter The inverter is a little different from AND and OR gates in that it always has exactly one input as well as one output. Whatever logical state is applied to the input, the opposite state will appear at the output. The NOT function, as it is called, is necesasary in many applications and highly useful in others. A practical verbal application might be: The door is NOT locked = You may enter The NOT function is denoted by a horizontal bar over the value to be inverted, as shown in the figure to the left. In some cases a single quote mark (') may also be used for this purpose: 0' = 1 and 1' = 0. For greater clarity in some
  • 10. 10 logical expressions, we will use the overbar most of the time. In the inverter symbol, the triangle actually denotes only an amplifier, which in digital terms means that it "cleans up" the signal but does not change its logical sense. It is the circle at the output which denotes the logical inversion. The circle could have been placed at the input instead, and the logical meaning would still be the same. The logic gates shown above are used in various combinations to perform tasks of any level of complexity. Some functions are so commonly used that they have been given symbols of their own, and are often packaged so as to provide that specific function directly. On the next page, we'll begin our coverage of these functions. By combining thousands or millions of logic gates, it is possible to perform highly complex operations. The maximum number of logic gates on an integrated circuit is determined by the size of the chip divided by the size of the logic gates. Since transistors make up most of the logic gates in computer
  • 11. 11 processors, smaller transistors mean more complex and faster processors.Minimize the following functions using the ‘don’t care’ terms for simplification wherever possible: a. f(A,B,C) = 3,5 with don’t care term 0,7∑ b. f(A,B,C,D) = 1,2,3,4,5,6,7,8,9,10 with ‘don’t care’ terms∑ 9, 12, 15 9. Design full-adder using only NOR gates. First of all, NAND and NOR gates have been proven to be logically complete. That means you can create every other logical gate with just NANDs or just NORs. Other gate functions are XOR, AND, OR, NOT, etc. To clarify: The notation I am using is [NAND] represents the NAND gate. Having A,B means the two inputs are A and B. If there is just one input, then that input gets mapped to both inputs. The '|' is supposed to show a junction between two lines. '-' is a single line and '=' is a double line. The '. . .' is just empty space, trying to keep the diagram intact. Some NAND designs we will need are: AND: A,B--[NAND]==[NAND]-->out OR: A--[NAND]--|==[NAND]--out
  • 12. 12 . . . .B--[NAND]--| first NAND connects to top and bottom NANDs last NAND has inputs taken from output of the middle two NANDs . . . . . . . . . . . . . . . A--|[NAND]---| XOR: A,B--[NAND]------| . . . . . . . |===[NAND]--out . . . . . . . . . . . . . . . B--|[NAND]---| The second part is what a full adder is. A full adder is a system that takes in three signals and outputs two. The three input signals are A, B, and Cin. The two outputs are S and Cout. The point of a full adder is that you can cascade them. The Cout of the first becomes the Cin of the second. That way you have a general one bit adder, but can make an N bit adder by stringing cascading them. So the first step in creating a full adder is writing out the truth table, a table where inputs get mapped to specific outputs. I am going to use '-' in place of spaces so the spacing stays the same after I post. Input- - - - - - - - - - - - - - - -Output A - - B - - Cin - - - - - - - - - S - - Cout 0 - - 0 - - 0 - - - - - - - - - - -0 - - 0 0 - - 0 - - 1 - - - - - - - - - - -1 - - 0 0 - - 1 - - 0 - - - - - - - - - - -1 - - 0
  • 13. 13 0 - - 1 - - 1 - - - - - - - - - - -0 - - 1 1 - - 0 - - 0 - - - - - - - - - - -1 - - 0 1 - - 0 - - 1 - - - - - - - - - - -0 - - 1 1 - - 1 - - 0 - - - - - - - - - - -0 - - 1 1 - - 1 - - 1 - - - - - - - - - - -1 - - 1 It can be seen that S = [A XOR B XOR Cin] It can be seen that C = [(A AND B) OR (A AND Cin) or (B AND Cin)] or equivelently (and more efficiently) C = [(A AND B) or (C AND (A XOR B))] 10. Draw and explain the working of JK, S-R, and D flip flops. In The J-K Flip-Flop This diagram, P stands for "Preset," C stands for "Clear" and Clk stands for "Clock." The logic table looks like this: P C Clk J K Q Q' 1 1 1- to- 0 1 0 1 0 1 1 1- 0 1 0 1
  • 14. 14 to- 0 1 1 1- to- 0 1 1 Togg les 1 0 X X X 0 1 0 1 X X X 1 0 Here is what the table is saying: First, Preset and Clear override J, K and Clk completely. So if Preset goes to 0, then Q goes to 1; and if Clear goes to 0, then Q goes to 0 no matter what J, K and Clk are doing. However, if both Preset and Clear are 1, then J, K and Clk can operate. The 1-to-0 notation means that when the clock changes from a 1 to a 0, the value of J and K are remembered if they are opposites. At the low-going edge of the clock (the transition from 1 to 0), J and K are stored. However, if both J and K happen to be 1 at the low-going edge, then Q simply toggles. That is, Q changes from its current state to the opposite state. You might be asking yourself right now, "What in the world is that good for?" It turns out that the concept of "edge triggering" is very useful. The fact that J-K flip-flop only "latches" the J-K inputs on a transition from 1 to 0 makes it much more useful as a memory device. J-K flip-flops are also extremely useful in counters (which are used extensively
  • 15. 15 when creating a digital clock). Here is an example of a 4-bit counter using J-K flip-flops: The outputs for this circuit are A, B, C and D, and they represent a 4-bit binary number. Into the clock input of the left-most flip-flop comes a signal changing from 1 to 0 and back to 1 repeatedly (an oscillating signal). The counter will count the low-going edges it sees in this signal. That is, every time the incoming signal changes from 1 to 0, the 4-bit number represented by A, B, C and D will increment by 1. So the count will go from 0 to 15 and then cycle back to 0. You can add as many bits as you like to this counter and count anything you like. For example, if you put a magnetic switch on a door, the counter will count the number of times the door is opened and closed. If you put an optical sensor on a road, the counter could count the number of cars that drive by. Another use of a J-K flip-flop is to create an edge- triggered latch, as shown here:
  • 16. 16 In this arrangement, the value on D is "latched" when the clock edge goes from low to high. Latches are extremely important in the design of things like central processing units (CPUs) and peripherals in computers. SR Flip-Flop An SR Flip-Flop can be considered as a basic one-bit memory device that has two inputs, one which will "SET" the device and another which will "RESET" the device back to its original state and an output Q that will be either at a logic level "1" or logic "0" depending upon this Set/Reset condition. A basic NAND Gate SR flip flop circuit provides feedback from its outputs to its inputs and is commonly used in memory circuits to store data bits. The term "Flip-flop" relates to the actual operation of the device, as it can be "Flipped" into one logic state or "Flopped" back into another. The simplest way to make any basic one-bit Set/Reset SR flip-flop is to connect together a pair of cross-coupled 2- input NAND Gates to form a Set-Reset Bistable or a SR
  • 17. 17 NAND Gate Latch, so that there is feedback from each output to one of the other NAND Gate inputs. This device consists of two inputs, one called the Reset, R and the other called the Set, S with two corresponding outputs Q and its inverse or complement Q as shown below. The SR NAND Gate Latch D flip flops The edge-triggered D flip-flop is easily derived from its RS counterpart. The only requirement is to replace the R input with an inverted version of the S input, which thereby becomes D. This is only needed in the master latch section; the slave remains unchanged. One essential point about the D flip-flop is that when the clock input falls to logic 0 and the outputs can change state, the Q output always takes on the state of the D input at the moment of the clock edge. This was not true of the RS and JK flip-flops. The RS master section would repeatedly change states to match the input signals while the clock line is logic 1, and the Q output would reflect whichever input most recently
  • 18. 18 received an active signal. The JK master section would receive and hold an input to tell it to change state, and never change that state until the next cycle of the clock. This behavior is not possible with a D flip-flop. The edge-triggered D NAND flip-flop is shown below.