Lesson 1 - Signals: Signal
Lesson 1 - Signals: Signal
LESSON 1 – SIGNALS
SIGNAL
- energy applied to a circuit to cause it to perform an intended action, such as
transmission or reception of information
1. ANALOG SIGNAL
- any continuous signal for which the time varying feature (variable) of the signal
is a representation of some other time varying quantity
- nominally continuous electrical signal that varies in amplitude or frequency in
response to changes in sound, light, heat, position, or pressure
- continuously varying representation of a condition, physical phenomenon, or
quantity such as flow, pressure, or temperature, transmitted as electrical,
mechanical, or pneumatic energy
- EXAMPLES:
THERMOMETERS
CLASSICAL MECHANICS
o used for describing the motion of macroscopic objects, from projectiles
to parts of machinery, as well as astronomical objects, such as
spacecraft, planets, stars, and galaxies
PNEUMATICS
o the use of pressurized gas to affect mechanical motion
o Pneumatic power is used in industry, where factory machines are
commonly plumbed for compressed air; other compressed. Pneumatics
also has applications in dentistry, construction, mining, and other areas
2. DIGITAL SIGNAL
- in computer architecture, and other digital systems, a DIGITAL SIGNAL is a
waveform that switches between two voltage levels that represents two
states (0 and 1)
- EXAMPLES:
LAPTOP / LCD MONITOR
CAMCORDER / DIGITAL CAMERAS
HANDHELD PC / BLACKBERRY PDA
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
LOGIC DESIGN
- involves determining on how to interconnect basic logic building blocks to
perform specific functions
- EXAMPLE:
o Determining the interconnection of logic gates and flip-flops required
to perform binary addition
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
CIRCUIT DESIGN
- involves specifying the interconnection of certain components (resistors,
diodes, transistors, etc.) to form a gate, flip-flop, or other logic building
block using appropriate computer-aided design tools
- EXAMPLE:
o Laying out and interconnection of components on a silicon chip
SWITCHING FUNCTIONS
- Many things can be described by two distinct
states; for example, a light can be ``on'' or ``off;'' a
door can be ``open'' or ``closed;'' a statement can
be ``true'' or ``false.''
- A number system which has only two digits, 0 and
1, can be defined to represent any number (the binary number system.)
- A typical electronic device with 2 states is a switch, which can be ``on''
(switch closed) or ``off'' (switch open).
- Switching functions can be implemented using simple switches. In digital
electronic circuits, transistors are used as simple switches in circuits very
similar those which follow.
- The functions NOT, AND and OR can be easily implemented with two simple
switches.
- Any set that is restricted to a finite number of elements contain discrete
information
- EXAMPLES OF DISCRETE SETS:
o 10 decimal digits o 52 playing cards
o 26 letters of the alphabet o 64 squares of a chessboard
- Early digital computers were used mostly for numeric computations. In this
case, the discrete elements used were the digits. From such an application,
the term digital computer emerged.
- Discrete elements of information are represented in a digital system by
physical quantities called signals.
- EXAMPLES:
o Voltage
o Current
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
EXAMPLES:
1. Convert 1310 to binary (base 2)
EXAMPLE:
Octal Addition
RECALL:
In the octal numbering system, the lowest digit is 0 and the highest is 7.If
the result is greater than 7, divide it by 8, placing the quotient (as a
“carry”) on the next higher-order octal digit position, and the remainder
as part of the sum. Repeat the process up to the most significant bit of
the operands.
EXAMPLE:
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Hexadecimal Addition
RECALL:
In the hexadecimal numbering system, the lowest digit is 0 and the
highest is F. If the result is greater than 15, divide it by 16, placing the
quotient (as a “carry”) on the next higher-order hexadecimal digit
position, and the remainder as part of the sum. Repeat the process up to
the most significant bit of the operands.
EXAMPLE:
EXAMPLES:
EXAMPLES:
Find the 10’s complement of 7. Find the 10’s complement of 75.
.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
EXAMPLES:
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
EXAMPLE: Let X represent an 8-bit signed binary integer which follows the format
X7X6X5X4X3X2X1X0
EXAMPLE: Let X represent an 8-bit signed binary fraction which follows the format
X7X6X5X4X3X2X1X0
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
DECIMAL SIGN
1’s COMPLEMENT 2’s COMPLEMENT
VALUE MAGNITUDE
+7 0111 0111 0111
+6 0110 0110 0110
+5 0101 0101 0101
+4 0100 0100 0100
+3 0011 0011 0011
+2 0010 0010 0010
+1 0001 0001 0001
+0 0000 0000 0000
-0 1000 1111 0000
-1 1001 1110 1111
-2 1010 1101 1110
-3 1011 1100 1101
-4 1100 1011 1100
-5 1101 1010 1011
-6 1110 1001 1010
-7 1111 1000 1001
-8 not possible not possible 1000
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
EXAMPLES:
Find the 1’s complement of 10012. Find the 2’s complement of 00012.
SEATWORK: PERFORM THE ARITHMETIC OPERATIONS USING THE 2’s COMPLEMENT METHOD:
11111111 00001010 00000001
-10101010 -11101111 -11111111
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
EXAMPLE: Perform the following arithmetic operations using the 2’s complement
method:
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
UNPACKED PACKED
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
EXAMPLE: Represent the decimal number +789 in the unpacked decimal format.
EXAMPLE: Represent the decimal number +789 in the packed decimal format.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Coding Techniques
NUMERIC CHARACTERS : One punch in a column (digit portion)
ALPHABETIC CHARACTERS : Two punches in a column (zone and digit portions)
SPECIAL CHARACTERS : One, two or more punches in a column
1 A J /
2 B K S
3 C L T
digit portion 4 D M U
5 E N V
6 F O W
7 G P X
8 H Q Y
9 I R Z
BINARY CODES
- The binary system is the most natural system Bit 3 Bit 2 Bit 1
for a computer, but people are accustomed to
the decimal system. One way to resolve this 0 0 0
difference is to convert decimal numbers to 0 0 1
binary, perform all arithmetic calculations in
0 1 0
binary, and then convert the binary results
back to decimal. 0 1 1
- An n-bit binary code is a group of n bits that 1 0 0
assume up to 2n distinct combinations of 1’s
and 0’s, with each combinations representing 1 0 1
one element of the set being coded . 1 1 0
- Each element is assigned a unique binary bit
1 1 1
combination, and no two elements can have
the same value; otherwise, the code A 2-bit code uses 2 bits that
assignment is ambiguous. 2
can assume up to 4 (2 ) distinct
- A set of 4 elements can be coded with a 2-bit combinations of 0’s and 1’s
binary code.
- A set of 8 elements requires a 3-bit code, and
a set of 16 elements requires a 4-bit code.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
BCD Addition
- When the binary sum is less than 1010 (without a carry), the corresponding
BCD digit is correct. When the binary sum is greater than or equal to 1010, the
result is an invalid BCD digit.
- The addition of binary 6 (0110)2, to the sum converts it to the correct digit, and
also produces a decimal carry as required.
EXAMPLE: Perform the required BCD addition. BCD = 448 + 489
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Binary Logic
- deals with binary variables that take on 2 discrete value and with the
operations of mathematical logic applied to these variables
Truth Table
- a table of combination of the binary variables showing the relationship
between the values that the variables take on and the values of the result of
the operation
X Z
0 1
1 0
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
AND GATE
- represented by a dot ( . ) or by the absence of the operator
- EXAMPLE: Z = X .Y or Z = XY
X Y Z
0 0 0
0 1 0
1 0 0
1 1 1
OR GATE
- represented by a plus ( + ) symbol
- EXAMPLE: Z = X + Y
X Y Z
0 0 0
0 1 1
1 0 1
1 1 1
Boolean Expressions
- A BOOLEAN ALGEBRA is an algebra dealing with binary variables (A, B, C, …)
and logic operations (AND, OR, NOT).
- A BOOLEAN FUNCTION consists of a binary variable denoting the function, an
equal sign, and an algebraic expression formed by using binary variables,
the constants 0 and 1, the logic operation symbol, and parentheses (added as
needed to specify the order in which the operations are performed).
EXAMPLE:
Algebraic Manipulation
EXAMPLE: Derive circuit diagram of the Boolean expression F = X’YZ + X’YZ’ + XZ
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
- Logic design problems are often stated in terms of one or more English
sentences.
- The first step in designing a logic circuit is to translate these sentences into
Boolean equations by breaking down each sentence into phrases and associate
a Boolean variable with each phrase.
Example:
MARY watches TV if it is Monday night and she has finished her homework.
F X Y
A B C f
0 0 0 0
0 0 1 0
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
f (A, B, C) = m3 + m4 + m5 + m6 + m7
f (A, B, C) = ∑ m(3, 4, 5, 6, 7)
MAXTERM EXPANSION
- A MAXTERM of n variables is the
sum of n literals in which each
variable appears exactly once in either
true or complemented form.
Each maxterm has a value of 0 for exactly one
combination of values for A, B, and C
- When a function f is written as a product of
maxterms, this is referred to as a maxterm
expansion or standard product of sums.
- If f = 0 for row i of the truth table, then Mi
must be present in the maxterm expansion
because Mi = 0 only for the combination of
values of the variables corresponding to row
i of the table.
f = (A + B + C)(A + B + C’)(A + B’ + C) = M0M1M2
f (A, B, C) = ∏ M(0, 1, 2)
Each maxterm is the complement of the corresponding minterm, that is, Mi = m’i.
Given the minterm or maxterm expansions for f, the minterm or maxterm
expansions for the complement of f are easy to obtain. Because f’ = 1 when f = 0,
the minterm expansion for f’ contains the minterms not present in f.
EXAMPLES:
f (A, B, C) = m3 + m4 + m5 + m6 + m7
f’ = (m3 + m4 + m5 + m6 + m7)’ = m’3 m’4 m’5 m’6 m’7 = M3M4M5M6M7
f (A, B, C) = ∏ M(0, 1, 2) = M0M1M2
f’ = (M0M1M2)’ = M’0 + M’1 + M’2 = m0 + m1 + m2
Find the minterm expansion of the function f(X, Y, Z) based on the given truth table
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
f(X, Y, Z) = X’ Y’ Z’ + X’ Y Z’ + X Y’ Z + X Y Z
f(X, Y, Z) = m0 + m2 + m5 + m7
f(X, Y, Z) = ∑ m(0, 2, 5, 7)
Find the minterm expansion of f’ on the given truth table of the function f(X, Y, Z)
f’(X, Y, Z) = X’ Y’ Z + X’ Y Z + X Y’ Z’ + X Y Z’
f’(X, Y, Z) = m1 + m3 + m4 + m6
f’(X, Y, Z) = ∑ m(1, 3, 4, 6)
Taking the complement of f’:
f(X, Y, Z) = (m1 + m3 + m4 + m6)’ = m’1 m’3 m’4 m’6 but m’i = Mi
f(X, Y, Z) = M1 M3 M4 M6
f(X, Y, Z) = (X + Y + Z’)(X + Y’ + Z’)(X’ + Y + Z)(X’ + Y’ +Z)
f(X, Y, Z) = ∏ M(1, 3, 4, 6)
f(a,b,c,d) = ∑ m(0,1,2,3,5,7,10,14)
EXAMPLE: Design an adder which adds two 2-bit binary numbers to give a 3-bit
binary sum. Find the truth table for the circuit. The circuit has four inputs and three
outputs as shown. Express the output signals as minterm expansions.
-
Problems in using Algebraic Procedures:
- Procedures are difficult to apply in a systematic way
- Difficult to tell when you have arrived at a minimum solution
MAP
- a diagram made up of squares, with each square representing one minterm of
the function
o A Boolean function is recognized graphically by those squares whose
minterms are included in the function.
- presents a visual diagram of all possible ways a function may be expressed in
a standard form
o By recognizing various patterns, the user can derive alternative
algebraic expressions for the same function.
NOTE: The simplified expressions produced by the map are always in the sum-
of-products or product-of-sums form.
2-VARIABLE MAP
- consists of 4 squares, one for each minterm
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
EXAMPLE: Derive the equation of the Boolean function F based on the given map.
F = m1 + m2 + m3
F = X’Y + X Y’ + X Y
F = X’Y + X Y’ + X Y = X’Y + X (Y’ + Y but (Y’ + Y) = 1
F = X’Y + X = (X + X’) (X + Y) but (X’ + X) = 1
F= X+Y
3-VARIABLE MAP
- consists of 8 squares, one for each minterm
- BASIC PROPERTIES OF ADJACENT SQUARES
Any two(2) adjacent squares placed horizontally or
vertically (but not diagonally) to form a rectangle
correspond to minterms that differ in only a single
variable.
- SIMPLIFICATION PROCESS:
One square represents a minterm of 3 literals
A rectangle of 2 squares is a product term of 2 literals
A rectangle of 4 squares represents a product term of 1 literal
A rectangle of 8 squares yields a function that is equal to 1
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
EXAMPLE:
m5 + m7 = X Y’ Z + X Y Z
m5 + m7 = X Z(Y’ + Y) but (Y’ + Y) = 1
m5 + m7 = X Z
OTHER WAY:
F = (m0 + m2 + m4 + m6)
F = (X’Y’Z’ + X’YZ’ + XY’Z’ + XYZ’)
F = X’Z’(Y’ + Y) + XZ’(Y’ + Y)
F = X’Z’ + XZ’
F = Z’ (X’ + X)
F = Z’
4-VARIABLE MAP
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
PRIME IMPLICANT
- a product term obtained by combining the maximum possible number of adjacent
squares in the map
- Four adjacent 1’s form a prime implicant if they are not within a group of 8 adjacent
squares.
NOTE: A single 1 on a map is a prime implicant if it is not adjacent to any other 1’s.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
PRODUCT-OF-SUM SIMPLIFICATION
- The procedure for obtaining a simplified expression from sum-of-product to
the product-of-sum form can be obtained from the basic properties of Boolean
functions.
- The 1’s placed in the squares of the map represent the minterms of the
function. The minterms not included in the function represents the
complement of the function.
- The minterms not included in the function is represented in the map by the
squares not marked by 1’s.
- The simplified expression of the function is obtained by marking the empty
squares with 0’s and combining them into valid rectangles.
- To obtain the function F as a product of sums, take the complement of F’ (by
taking the dual and complementing each literal).
EXAMPLE: Simplify the Boolean function F (W,X,Y,Z) = ∑ m(0,1,2,5,8,9,10) using a
map.
F’ = YZ + WX + XZ’
Take the dual of the OR operation
(YZ) (WX) (XZ’)
Take the dual of the logical operations
inside the parentheses
(Y+Z) (W+X) (X+Z’)
Complement each literal
F = (Y’+Z’) (W’+X’) (X’+Z)
EXAMPLE: Consider the incompletely unspecified function F that has three (3) don’t-
care conditions: F(W,X,Y,Z) = ∑ m(1,3,7,11,15) d(W,X,Y,Z) = ∑ m(0,2,5)
5-VARIABLE MAP
- consists of 32 squares, one for each minterm
- consists of two(2) 4-variable maps (V,W,X,Y,Z)
- Variable V distinguishes between the two maps.
- One 4-variable map represents the 16 squares
where V = 0.
- The other 4-variable map represents the other
16 squares where V = 1.
- Minterms 0 through 15 belong with V = 0.
- Minterms 16 through 31 belong with V = 1.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
6-VARIABLE MAP
- consists of 64 squares, one for each minterm
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
2. Compare each term of a group with every term of the next group. If two terms
are logically adjacent combine the two terms to make a new term. The new
term has the same bit values as the original two terms except the one bit that
was different is replaced with the hyphen (-) symbol.
3. Repeat the process of combining and marking with the new combined terms
until no more combinations are
possible.
- If the resulting term cannot be
reduced further, then the term is
considered to be a prime implicant.
7. Choose a set of prime implicants that covers the minterms (columns) not
covered by the prime implicants.
When constructing prime implicant chart, some
minterms may be covered by two or more prime
implicants.
If the essential prime implicant do not cover all of the
minterms, then additional prime implicants are
needed.
The non-essential implicants needed to form the
minimum solution may be selected by trial and error.
Some functions may have two or more minimum
sum-of-products expressions, having the same number of terms and literals.
Organize these binary values into groups where the elements in each group have the
same number of one's. The groups are also ordered from least to most one's in a
group.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
BINARY INFORMATION
1. DATA
- Information that are manipulated to perform some operation/s
- EXAMPLES:
Arithmetic (adders, counters, etc…)
Logic (decoders, etc…)
Shifting (shift register, etc…)
other similar ops (multiplexers, etc…)
2. CONTROL INFORMATION
- Provides command signals that supervise operations in the data section to
meet required data processing tasks
DIGITAL DESIGN OF LOGIC CIRCUITS
- Design of digital circuits that perform data-processing operations
- Design of control circuits that supervise the operations and their sequence
Control and Data Processor Interaction
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
COMBINATIONAL CIRCUIT
- consist of logic gates whose outputs at any given time are determined by the
combining values of the applied inputs using logic operations
SEQUENTIAL CIRCUIT
- outputs depend not only on the presently applied values of the inputs, but also
on past inputs, and the behavior of the circuit must be specified by a sequence
in time of inputs and internal stored bit values
DESIGN PROCEDURE
- The design of a combinational circuit starts from the specification of the
problem and culminates in a logic diagram or set of Boolean equations from
which the logic diagram can be obtained.
PROCEDURE:
1. From the specification of the circuit, determine the required number of inputs and
outputs, and assign a letter symbol to each.
2. Derive the truth table that defines the required relationship between inputs and
outputs.
3. Obtain the simplified Boolean functions for each output as a function of the input
variable.
4. Draw the logic diagram.
5. Verify the correctness of the design.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
CODE CONVERTER
- a circuit that translates information from one binary code to another
INPUTS
- provide the bit combination of the elements as specified by the first code
OUTPUTS
- generate the corresponding bit combination of the second code
EXAMPLE: Design a logic circuit that can convert 4-bit binary digits in BCD Code to Excess-3
Code. Decimal digits that can be represented under the BCD coding system.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
FULL ADDER
- forms the sum of three input bits
- third input bit, Z, represents the carry from the previous lower significant
position
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
DESIGN PROCESS
- Given a desired range of behavior and a set of available components,
determine a structure (design) formed from these components that achieves
the desired behavior with acceptable cost and performance.
Circuit Modification 1:
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Circuit Modification 2:
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
MULTIPLEXER
- A multiplexer is a combinational circuit that selects binary information from
one of many input lines and directs the information to a single output line.
The selection of the input line is controlled by a set of input variables.
- NOTE:
If the number of data sources is k and each I/O data line carries m bits,
the multiplexer is referred to as k-input, m-bit multiplexer.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Common Applications
- Address decoding, where Ai is interpreted as an address that selects a specific
output line zi or some circuit attached to zi
- For routing data from a common source to one of several destination.
7 SEGMENT DISPLAY
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
ENCODERS
- An encoder is a digital function that performs the inverse operation of a
decoder. An encoder has 2n (or fewer) input lines and n output lines. The
output lines generate the binary code corresponding to the input value.
Priority Encoder
- A combinational circuit that implements a priority function.
- If two or more input signals are equal to 1 at the same time, the input having
the highest priority takes precedence.
- OUTPUT SIGNALS
a = C + A + (B + D)’
b = B + (C + D)’
c = B + C’ + D
d = A + CD’ + B’C + BC’D + B’D’
e = D’(B’ + C)
f = A + C’D’ + BC’ + BD’
g = A + CD’ + (B C)
LATCHES
- A storage element can maintain a binary state indefinitely (as long as power
is delivered to the circuit), until directed by an input signal to switch states.
- The major differences among the various types of latches and flip-flops are
the number of inputs they possess and the manner in which the inputs
affect the binary state.
- The most basic storage elements are latches, from which flip-flops are
usually constructed.
- A latch is a storage element that has no clock input
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
S-R LATCHES
D LATCHES
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Flip-Flops
- basic circuit for storing information in a digital machine is called a FLIP-FLOP
- has 2 output signals
- state is taken to be the state of the Q output
- is given a name
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Edge-Triggered Flip-Flops
- An edge-triggered flip-flop ignores the pulse while it is at a constant level and
triggers only during the transition of the clock signal.
The Clock
SETUP TIME (tsetup)
The minimum time for which the input signal must be maintained at a
constant value prior to the occurrence of the clock transition.
HOLD TIME (thold)
The minimum time for which the input signal must not change after the
application of the positive transition of the pulse.
PROPAGATION DELAY TIME (tpd)
The delay time for the change in value of a signal to propagate from input
to output.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
J K Q Operation
(t+1)
0 0 Q(t) No charge
0 1 0 Reset
1 0 1 Set
1 1 Q’(t) Toggle
EXAMPLE: Show the state table of a sequential circuit with two J-K flip-flops A and
B and one input X specified by the following input equations:
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
STATE DIAGRAM
- The information available in the state table may be represented graphically in
the form of a state diagram.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
EXAMPLE: Using the Mealy Model, derive the state diagram of a sequential circuit
whose behavior is characterized by the given state table.
STATE REDUCTION
- The reduction of the number of flip-flops in a sequential circuit is referred to
as the state reduction problem.
- State-reduction algorithms are concerned with procedures for reducing the
number of states in a state table.
- Since m flip-flops produce 2m states, a reduction in the number of states may
(or may not) result in a reduction in the number of flip-flops.
- An unpredictable effect in reducing the number of flip-flops is that the
equivalent circuit may require more combinational gates.
Original State Diagram
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Block Diagram
LOADING
- the process of transferring information into the register
Parallel Loading
- all of the bits of the register are loaded simultaneously with a common clock
pulse
Serial Loading
- transferring the content of the register one bit at a time
Block Diagram
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Counters
- A register that goes through a prescribed sequence of states upon the application
of input pulses is called a counter.
- The input pulses may be clock pulses or may originate from other sources, and
they may occur at fixed intervals of time or at random intervals.
- A counter that follows the binary number sequence is called a binary counter.
- An n-bit binary counter consists of n flip-flops and can count in binary from 0 to
2n – 1.
Categories of Counters:
RIPPLE
- The flip-flop output transition serves as a source for triggering other flip-flops.
- The clock input of some or all of the flip-flops is triggered not by the common
clock pulses, but rather by the transition that occurs in other flip-flop outputs
SYNCHRONOUS
- The clock inputs of all the flip-flops receive the common clock pulses, and the
change of state is determined from the present state of the counter.
Exercise #1: A SEQUENTIAL CIRCUIT HAS 3 D FLIP-FLOPS A, B, & C AND ONE INPUT X. THE CIRCUIT IS DESCRIBED
BY THE FOLLOWING INPUT EQUATIONS:
DA = (BC’ + B’C)X + (BC + B’C’)X’ DB = A DC = B
Draw the state diagram of the circuit (one for X = 0 and one for X = 1)
Derive the state table for the circuit
Exercise #2: A SEQUENTIAL CIRCUIT HAS 2 J-K FLIP-FLOPS A & B, TWO INPUTS X & Y, AND ONE OUTPUT Z. THE
FLIP-FLOP INPUT EQUATIONS AND OUTPUT FUNCTION ARE:
JA = BX + B’Y’ JB = A’X
KA = B’XY’ KB = A + XY’ Z = AXY + BX’Y’
Draw the state diagram of the circuit
Derive the state table of the circuit
Draw the logic diagram of the circuit
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
- Control Information
o Provides command signals that activate various micro-operations in the data path to
perform the specified data-processing tasks
o Determines the sequence in which various actions are performed
The Clock
- The timing of all registers in a synchronous digital system is controlled by a
master clock.
- The clock pulses are applied to all flip-flops and registers in the system,
including those in the control unit.
LEVEL CLOCKING
o the FF responds to the LEVEL (high or low) of the clock signal
- EDGE TRIGGERING
o the FF can only respond on the rising or falling edge of the clock
ALGORITHM
- consists of a finite number of procedural steps that specify how to obtain a
solution to a problem
- HARDWARE ALGORITHM
- specifies the control sequence and data-processing tasks of a digital system
- a procedure for implementing the problem with a given piece of equipment
Control Logic
- Initiates properly sequenced commands to data-processor
- Uses status conditions from data processor and some external inputs which
serve as decision variables in determining sequence of control signals
Data Processor
- Manipulates data in registers according to system requirements
FLOWCHART
- A conventional flow chart describes the sequence of procedural steps and
decision paths for an algorithm without concern for their time relationship.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Decision Box
- describes the effect of an input signal on the control subsystem
- input condition to be tested is written inside the box
- value of the signal being tested (either 1 [true] or 0 [false]) determines which of
the decision box’s two exit paths is to be followed in the current clock cycle
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Conditional Box
- input path to the conditional box comes from one of exit paths of a decision box
that tests some condition
- conditional operations that are contained in a conditional box are only invoked
when the path containing the conditional box is selected by the decision box
o If the ASM is in the state IDLE, R is reset for every clock pulse
o the ASM is in the state IDLE, PC is cleared to 0 as well, but
only if the variable E = 1
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
State Diagram
Control Implementation
From the ASM chart, we may obtain:
The Controller Logic (via State Table/Diagram)
- determined from the decision boxes and the required state transitions
Architecture/Data Processor
- can be obtained from the operations specified with the state and conditional
boxes
EXAMPLE: Design a digital system wherein the Datapath Unit consists of two J-K flip-
flops, E and F, and one 4-bit binary counter, A.
ASM CHART
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
Sequence of Operation
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
- From the table, the next-state column of G2 has 1s in the 2nd, 3rd, 4th, and 5th row.
- The D input of flip-flop G2 must be equal to 1 during the present states T0 & T1
- The D input function:
DG2 = G1’G2’S + G1’G2A3’ + G1’G2A3A4’ + G1’G2A3A4
= G1’G2’S + G1’G2A3’ + G1’G2A3 (A4’ + A4)
= G1’G2’S + G1’G2A3’ + G1’G2A3
= G1’G2’S + G1’G2 (A3’ + A3)
= G1’G2’S + G1’G2
DG2 = G1’G2’S + G1’G2
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
- Since the state diagram has 3 states, assign 3 flip-flops to the circuit and label
them T0, T1, and T2.
- The Boolean function for setting the flip-flop is determined from the present-
state and the input conditions along the directed lines.
Notes:
- Initially, flip-flop T0 must be set to 1 and all other FFs cleared to 0 so that the FF
representing the initial state is equal to 1 and all other states equal to 0.
- Once started, the FF per state controller will propagate itself from state to state
in the proper manner.
- For a register with a common asynchronous clear input, all FFs including the Q
output of T0, are cleared to 0.
- Taking the output of T0 from the complement output Q’ provides the required
initial signal for T0.
COE117 - LOGIC CIRCUITS AND SWITCHING THEORY
- In order to keep Q’ as the output of T0, it is necessary that the input function to
the D input be complemented. This is done by the extra inverter that is placed at
the D input of FF T0.