Module 13 - Introduction to Number Systems and Logic
Pages i - ix,
1-1 to 1-10,
1-11 to 1-20,
1-21 to 1-33,
1-31 to 1-40,
1-41 to 1-50,
1-51 to 1-60,
1-61 to 69,
2-1 to 2-10, 2-11 to 2-20,
2-21 to 2-30,
2-31 to 2-36,
3-1 to 3-10,
3-11 to 2-20,
3-21 to 3-30,
3-31 to 3-40,
3-41 to 3-46, Index
Now let's subtract 102 from 112 using the adder/subtracter circuit. The minuend (112)
is input on the A terminals, and the subtrahend (102) is input on the B terminals. In the subtract
mode, a 1 from the control circuit is input to each of the X-OR gates and to the C0 carry input. By
applying a 1 to each of the X-OR gates, you find the output will be the complement of the subtrahend input at B1
and B2. Since B1 is a 0, the output of X-OR 1 will be 1. The input B2 to X-OR 2
will be inverted to a 0. The HIGH input to C0 acts as a carry from a previous circuit. The combination
of the X-OR gates and the HIGH at C0 produces the R's complement of the subtrahend. The full adders add
the minuend and the R's complement of the subtrahend and produce the difference. The output of C2 is
not used. The outputs of S2 and S1 are 0 and 1, respectively, indicating a
difference of 012. Therefore, 112 minus 102 equals 012.
Q13. What type of logic gates are added to a parallel adder to enable it to subtract?
How many of these gates would be needed to add a four-digit number?
Q15. In the add mode, what
does the output of C2 indicate?
Q16. In the subtract mode, a 1 at C0
performs what portion of the R's complement?
Q17. In the subtract mode, which portion of the
problem is complemented?
Flip-flops (FFs) are devices used in the digital field for a variety of purposes. When properly connected,
flip-flops may be used to store data temporarily, to multiply or divide, to count operations, or to receive and
Flip-flops are bistable multivibrators. The types used in digital equipment are identified by the inputs. They may
have from two up to five inputs depending on the type. They are all common in one respect. They have two, and only
two, distinct output states. The outputs are normally labeled Q and Q
and should always be complementary. When Q = 1, then Q = 0 and vice versa.
In this section we will discuss four types of FFs that are common to digital equipment. They are the R-S, D, T,
and J-K FFs.
The R-S FF is used to temporarily hold or store
information until it is needed. A single R-S FF will store one binary digit, either a 1 or a 0. Storing a
four-digit binary number would require four R-S FFs.
The standard symbol for the R-S FF is shown in figure
3-12, view A. The name is derived from the inputs, R for reset and S for set. It is often referred to as an R-S
LATCH. The outputs Q and Q are
complements, as mentioned earlier.
Figure 3-12. - R-S flip-flop: A. Standard symbol; B. R-S FF with inverted inputs.
The R-S FF has two output conditions. When the Q output is HIGH and Q is LOW,
the FF is set. When Q is LOW and Q is HIGH, the FF is reset. When the R and S inputs are both LOW, the Q and
Q outputs will both be HIGH. When this condition exists, the FF is considered to
be JAMMED and the outputs cannot be used. The jammed condition is corrected when either S or R goes HIGH.
To set the flip-flop requires a HIGH on the S input and a LOW on the R input. To reset, the opposite is required;
S input LOW and R input HIGH. When both R and S are HIGH, the FF will hold or "latch" the condition that existed
before both inputs went HIGH.
Because the S input of this FF requires a logic LOW to set, a more easily
understood symbol is shown in figure 3-12, view B. Refer to this view while reading the following paragraph.
In our description of R-S FF operation, let's assume that the signals applied to the S and R inputs are the LSDs
of two different binary numbers. Let's also assume that these two binary numbers represent the speed and range of
a target ship. The LSDs will be called SB0 (Speed Bit 0) and RB0 (Range Bit 0) and will be applied to the S and R
inputs respectively. Refer to figure 3-12, view B, and figure 3-13. At time T0, both SB0 and RB0 are HIGH, as a
result, both Q and
Q are HIGH. This is the jammed state and as mentioned earlier, cannot be used in
logic circuitry. At T1, SB0 goes LOW and RB0 remains HIGH; Q goes LOW and Q
remains HIGH; the FF is reset. At T2 RB0 goes LOW and SB0 remains LOW; the FF is latched in the
reset condition. At T3, SB0 goes HIGH and RB0 remains LOW; the FF sets. At T4 SB0 goes LOW
and RB0 goes HIGH; the FF resets. When SB0 and RB0 input conditions reverse at T5, the FF sets. The
circuit is put in the latch condition at T6 when SB0 goes LOW. Notice that the output changes states
ONLY when the inputs are in opposite states.
Figure 3-13. - R-S flip-flop with inverted inputs timing diagram.
Figure 3-14 shows two methods of constructing an R-S FF. We can use these diagrams to prove the
for the R-S FF.
Figure 3-14. - R-S FF construction: A. Using cross-coupled NAND gates; B. Using cross-coupled OR
Look at figure 3-14, view A. Let's assume SB0 is HIGH and RB0 is LOW. You should remember from chapter 2 that
the output of an inverter is the complement of the input. In this case, since SB0 is HIGH,
SBO will be LOW. The LOW input to NAND gate 1 causes the Q output to go HIGH.
This HIGH Q output is also fed to the input of NAND gate 2. The other input to NAND gate 2,
RBO, is HIGH. With both inputs to gate 2 HIGH, the output goes LOW. The LOW Q
output is also fed to NAND gate 1 to be used as the "latch" signal. If SB0 goes LOW while this condition exists,
there will be no change to the outputs because the FF would be in the latched condition; both SB0 and RB0 LOW.
When RB0 is HIGH and SB0 is LOW, RBO being LOW drives the output,
Q , to a HIGH condition. The HIGH Q and HIGH
SBO inputs to gate 1 cause the output, Q, to go LOW. This LOW is also fed to NAND
gate 2 to be used as the latch signal. Since SB0 is LOW, the FF will again go into the latched mode if RB0 goes
The cross-coupled OR gates in figure 3-14, view B, perform the same functions as the NAND gate configuration of
view A. A HIGH input at SB0 produces a HIGH Q output, and a LOW at RB0 produces a LOW Q
output. The cross-coupled signals (Q to gate 1 and Q to gate 2) are used as the
latch signals just as in view A. You can trace other changes of the inputs using your knowledge of basic logic
Q18. What are R-S FFs used for?
Q19. How many R-S FFs are required to store the number 1001012?
Q20. For an R-S FF to change output conditions, the inputs must be in what states?
Q21. How may
R-S FFs be constructed?
The toggle, or T, flip-flop is a bistable device that changes state on command from a common input terminal.
The standard symbol for a T FF is illustrated in figure 3-15, view A. The T input may be preceded by an inverter.
An inverter indicates a FF will toggle on a HIGH-to-LOW transition of the input pulse. The absence of an inverter
indicates the FF will toggle on a LOW-to-HIGH transition of the pulse.
Figure 3-15. - Toggle (T) flip-flop: A. Standard symbol; B. Timing diagram.
The timing diagram in figure 3-15, view B, shows the toggle input and the resulting outputs. We will assume an
initial condition (T0) of Q being LOW and Q being HIGH. At T1,
the toggle changes from a LOW to a HIGH and the device changes state; Q goes HIGH and Q
goes LOW. The outputs remain the same at T2 since the device is switched only by a LOW-to-HIGH
transition. At T3, when the toggle goes HIGH, Q goes LOW and Q goes
HIGH; they remain that way until T5.
Between T1 and T5, two complete
cycles of T occur. During the same time period, only one cycle is observed for Q or Q
. Since the output cycle is one-half the input cycle, this device can be used to divide the input by 2.
The most commonly used T FFs are J-K FFs wired to perform a toggle function. This use will be demonstrated later
in this section.
Q22. How many inputs does a T FF have?
Q23. What is the purpose of using T FFs?
The D FF is a two-input FF. The inputs are the data (D) input and a clock
(CLK) input. The clock is a timing pulse generated by the equipment to control operations. The D FF is used to
store data at a predetermined time and hold it until it is needed. This circuit is sometimes called a delay FF. In
other words, the data input is delayed up to one clock pulse before it is seen in the output.
form of a D FF is shown in figure 3-16, view A. Now, follow the explanation of the circuit using the Truth Table
and the timing diagram shown in figure 3-16, views B and C.
Figure 3-16. - D flip-flop: A. Standard symbol; B. Truth Table; C. Timing diagram.
Depending on the circuit design, the clock (CLK) can be a square wave, a constant frequency, or asymmetrical
pulses. In this example the clock (CLK) input will be a constant input at a given frequency. This frequency is
determined by the control unit of the equipment. The data (D) input will be present when there is a need to store
information. Notice in the Truth Table that output Q reflects the D input only when the clock transitions from 0
to 1 (LOW to HIGH).
Let's assume that at T0, CLK is 0, D is 1, and Q is 0. Input D remains at 1 for approximately 2 1/2
clock pulses. At T1, when the clock goes to 1, Q also goes to 1 and remains at 1 even though D goes to
0 between T2 and T3. At T3, the positive-going pulse of the clock causes Q to go
to 0, reflecting the condition of D. The positive-going clock pulse at T5 causes no change in the
output because D is still LOW. Between T5 and T6, D goes HIGH, but Q remains LOW until T7
when the clock goes HIGH.
The key to understanding the output of the D FF is to remember that the data (D)
input is seen in the output only after the clock has gone HIGH.
You may see D FF symbols with two
additional inputs ¾ CLR (clear) and PR (preset). These inputs are used to set the start condition of the FF ¾ CLR
sets Q to 0; PR sets Q to 1. Figure 3-17 shows the standard symbol with the CLR and PR inputs. Since these inputs
are preceded by inverters (part of the FF), a LOW-going signal is necessary to activate the FF. These signals (CLR
and PR) override any existing condition of the output.
Figure 3-17. - D flip-flop with PR and CLR inputs.
You may also see an inverter at the clock input. In this case, the output will change on the negative- going
transition of the clock pulse.
Q24. What are the inputs to a D FF?
How long is data delayed by a D FF?
Q26. What condition must occur to have a change in the
output of a D FF?
The J-K FF is the most widely used FF because of
its versatility. When properly used it may perform the function of an R-S, T, or D FF. The standard symbol for the
J-K FF is shown in view A of figure 3-18.
Figure 3-18. - J-K flip-flop: A. Standard symbol; B. Truth Table; C. Timing diagram.
The J-K is a five-input device. The J and K inputs are for data. The CLK input is for the clock; and the PS and
CLR inputs are the preset and clear inputs, respectively. The outputs Q and Q are
the normal complementary outputs.
Observe the Truth Table and timing diagram in figure 3-18, views B and
C, as the circuit is explained.
Line 1 of the Truth Table corresponds to T0 in the timing diagram. The PS and CLR inputs are both
LOW. The CLK, J, and K inputs are irrelevant. At this point the FF is jammed, and both Q and
Q are HIGH. As with the R-S FF, this state cannot be used.
At T1, PS remains LOW while CLR goes
HIGH. The Q output remains HIGH and Q goes LOW. The FF is in the PRESET condition
(line 2 of the Truth Table).
At T2, PS goes HIGH, CLR goes LOW, Q goes LOW, and
Q goes HIGH. At this point the FF is CLEARED (line 3 of the Truth Table). The
condition of the CLK, J, and K inputs have no effect on the PS and CLR actions since these inputs override the
other inputs. Starting at T3, PS and CLR will be held at HIGHs so as not to override the other actions of the FF.
Using the PS and CLR inputs only, the circuit
will function as an R-S FF.
Between T2 and T3,
the CLK input is applied to the device. Since the CLK input has an inverter, all actions will take place on the
negative-going transition of the clock pulse.
Line 4 of the Truth Table shows both PS and CLR HIGH, a
negative-going CLK, and J and K at 0, or LOW. This corresponds to T3 on the timing diagram. In this
condition the FF holds the previous condition of the output. In this case the FF is reset. If the circuit were set
when these inputs occurred, it would remain set.
At time T5, we have a negative-going clock
pulse and a HIGH on the J input. This causes the circuit to set, Q to go HIGH, and Q
to go LOW. See line 5 of the Truth Table.
At T6, J goes LOW, K goes HIGH, and the clock is in a
positive-going transition. There is no change in the output because all actions take place on the negative clock
At T7, when J is LOW, K is HIGH; the clock is going negative, the FF resets, Q goes
goes HIGH (line 6).
With both J and K HIGH and a negative-going
clock (as at T9 and line 7), the FF will toggle or change state with each clock pulse. It will continue
to toggle as long as J and K both remain HIGH.
Line 8 of the Truth Table indicates that as long as the
clock is in any condition other than a negative- going transition, there will be no change in the output
regardless of the state of J or K. As mentioned at the beginning of this section, J-K FFs may be used as R-S, T,
or D FFs. Figure 3-19 shows how a J-K can be made to perform the other functions.
Figure 3-19. - J-K versatility: A. Using just the PS and CLR inputs; B. Data applied to the J
input; C. Both J and K inputs held HIGH.
In view A, using just the PS and CLR inputs of the J-K will cause it to react like an R-S FF.
B, data is applied to the J input. This same data is applied to the K input through an inverter to ensure that the
K input is in the opposite state. In this configuration, the J-K performs the same function as a D FF.
View C shows both the J and K inputs held at 1, or HIGH. The FF will change state or toggle with each
negative-going transition of the clock just as a T FF will.
Now you can see the versatility of the J-K FF.
Q27. What type of FF can be used as an R-S, a T, or a D FF?
Q28. What will be the
output of Q if J is HIGH, PS and CLR are HIGH, and the clock is going negative?
that K goes HIGH and J goes LOW; when will the FF reset?
Q30. What logic levels must exist for
the FF to be toggled by the clock?
Q31. What two inputs to a J-K FF will override the other
Q32. How is the J-K FF affected if PS and CLR are both LOW?
NEETS Table of Contents
- Introduction to Matter, Energy,
and Direct Current
- Introduction to Alternating Current and Transformers
- Introduction to Circuit Protection,
Control, and Measurement
- Introduction to Electrical Conductors, Wiring
Techniques, and Schematic Reading
- Introduction to Generators and Motors
- Introduction to Electronic Emission, Tubes,
and Power Supplies
- Introduction to Solid-State Devices and
- Introduction to Amplifiers
- Introduction to Wave-Generation and Wave-Shaping
- Introduction to Wave Propagation, Transmission
Lines, and Antennas
- Microwave Principles
- Modulation Principles
- Introduction to Number Systems and Logic Circuits
- Introduction to Microelectronics
- Principles of Synchros, Servos, and Gyros
- Introduction to Test Equipment
- Radio-Frequency Communications Principles
- Radar Principles
- The Technician's Handbook, Master Glossary
- Test Methods and Practices
- Introduction to Digital Computers
- Magnetic Recording
- Introduction to Fiber Optics