9.5.2 Combination of Logic Gates

  1. Logic gates can be combined together to perform certain tasks.
  2. The output can be determined by constructing a truth table.
Example 1:

In the combination of logic gate above, find the outputs X, Y and Z of of the inputs A and B.
Answer:
INPUT OUTPUT
A B X Y Z
0 0 1 1 1
0 1 1 0 1
1 0 1 1 1
1 1 0 0 0


Example 2:

In the combination of logic gate above, find the outputs X, Y and Z of of the inputs A and B.
Answer:
INPUT OUTPUT
A B X Y Z
0 0 1 1 1
0 1 1 0 1
1 0 0 1 1
1 1 0 0 0


Example 3:

In the combination of logic gate above, find the outputs X, Y and Z of of the inputs A and B.
Answer:
INPUT OUTPUT
A B W X Y Z
0 0 0 0 1 0
0 1 1 0 0 0
1 0 1 1 0 0
1 1 1 1 0 0


Example 4:

In the combination of logic gate above, find the outputs X, Y and Z of of the inputs A and B.
Answer:
INPUT OUTPUT
A B W X Y Z
0 0 0 0 1 1
0 1 1 0 0 0
1 0 1 0 0 0
1 1 1 1 0 1

 

9.5.1 Logic Gates

  1. A logic gate is a physical device that performs a logical operation on one or more logical inputs, and produces a only one logical output.
  2. The input is the signal or data that fed into a logic gate whereas the output is the result from processing the inputs by using the operation of the logic gate.
  3. The input and output can be either high (denoted by 1) or low (denoted by 0).
  4. Gates are identified by their function. The 5 basic logic gates that you need to know under SPM syllabus are
    1. the AND gate
    2. the OR gate
    3. the NOT gate
    4. the NAND gate
    5. the NOR gate
  5. Logic gates primarary work using diodes and transistors as switches.

Symbol of the Logic Gate

For each gate below, the input or inputs are on the left of the symbol. The output is on the right

The Truth Tables

  1. The function of a logic gates can be shown by using the Truth tables.
  2. A truth table lists all possible input together with the corresponding output.


AND gate

Symbol:


Boolean Expression:
X=AB
Truth Table:
Truth Table
INPUT OUTPUT
0 0 0
0 1 0
1 0 0
1 1 1

Notes:
The output is HIGH (1) only if both the inputs are HIGH (1).

OR gate

Symbol:


Boolean Expression:
X=A+B
Truth Table:
Truth Table
INPUT OUTPUT
0 0 0
0 1 1
1 0 1
1 1 1

Notes:
The output is HIGH (1) only if one or more inputs are HIGH (1).

NOT gate

Symbol:


Boolean Expression:
X= A ¯
Truth Table:
Truth Table
INPUT OUTPUT
0 1
1 0

Notes:
The output is the opposite of the input.

NAND gate

Symbol:


Boolean Expression:
X= AB ¯
Truth Table:
Truth Table
INPUT OUTPUT
0 0 1
0 1 1
1 0 1
1 1 0

Notes:
The output is LOW (0) only if both the inputs are HIGH (1).

NOR gate

Symbol:


Boolean Expression:
X= A+B ¯
Truth Table:
Truth Table
INPUT OUTPUT
0 0 1
0 1 0
1 0 0
1 1 0

Notes:
The output is HIGH (1) only if both the inputs are LOW (0).

 

 

9.4.3 Transistor as Current Amplifier

  1. The major application of a transistor is as a current amplifier.
  2. A transistor can be used to amplify ('magnify') current changes because a small change in base current produces a large change in collector current.
  3. A simple transistor amplifier circuit is shown in Figure 1 below.
    (Figure 1)
  4. The graph in Figure 2 below shows the relationship between the base current and the collector current. From the graph, we can conclude that, the collector current is directly proportional to the base current.
    (Figure 2: The collector current is directly proportional to the emitter current)
  5. Since the small change in the base current IB results in a big change in the collector current, IC, the transistor therefore function as a current amplifier.
  6. The ratio IC/IB is called the amplification factor.

  7. Figure 3 below shows another amplification circuit. In this case however, the base current is varying because of the small alternating voltage produced by the microphone.
    (Figure 3)
  8. The small changes in base current cause much larger changes in collector current.
  9. The collector circuit includes an earphone through which you would hear an amplified version of the original sound.
  10. The input capacitor passes on current changes from the microphone but blocks the steady current which might otherwise flow through the microphone from the potential divider. Such a current would upset the biasing effect of the potential divider.

 

9.4.2 Transistor as an Automatic Switch

  1. Transistor can be used as automatic switches.
  2. In the diagram above, the bulb is off when the collector current is off or very small. It is switched on when the collector current become large.
  3. We have learned that in a transistor, the collector current is controlled by the base current, or the base voltage.
  4. The greater the base voltage is, the greater the base current, and hence the greater the collector current.
  5. Therefore the bulb can be switched on and off by varying the voltage supplied to the base.
  6. The voltage across the base can be controlled a potential divider.
  7. According to the potential divider rule, the voltages across the resistor R1 and R2 are given by the following equations:
  8. Therefore, by varying the resistance of R1 and R2, we can control the voltage across the base V2, and hence switch the bulb on and off.

The LDR

  1. A light-dependent resistor (LDR), or photoresistor, is a resistor sensitive to light.
  2. In darkness, the LDR has a resistance about 1 million Ohm.
  3. In bright light however, the resistance of the LDR falls to only a few hundred Ohms.

Light Operating Switch

  1. In a light operating switch, we connect an LDR to the potential divider.
  2. As a result, the voltage across the base vary according to the presence or absence of light.
  3. Example 1 and 2 below shows how the resistance of the LDR, the base voltage, the base current and the collector current change in different conditions.


Example 1

Bright Surrounding:
Resistance of LDR: Low
Base voltage: High
Base current: High

Collector current: High
Bulb: ON
Dark Surrounding
Resistance of LDR: High
Base voltage: Low
Base current: Low

Collector current: Low
Bulb: OFF

Conclusion
The bulb will be switched on when the surrounding is bright and switched off when the surrounding is dark.

Example 2

Bright Surrounding:
Resistance of LDR: Low
Base voltage: Low
Base current: Low

Collector current: Low
Bulb: OFF
Dark Surrounding
Resistance of LDR: High
Base voltage: High
Base current: Low

Collector current: High
Base current: ON

Conclusion
The bulb will be switched on when the surrounding is dark and switched off when the surrounding is bright.

Thermistor

  1. In a heat operated switch, the LDR is replaced by a thermistor.
  2. A thermistor is a resistor which its resistance changes as the temperature changes.
  3. There are 2 types of thermistor:
    1. The positive temperature coefficient (PTC) thermistor
    2. The negative temperature coefficient (NTC) thermistor
  4. For the PTC thermistor, the resistance of the thermistor increases as the temperature increases whereas for the NTC thermistor, the resistance of the thermistor decreases as the temperature increases.
  5. In SPM, we assume all the thermistor used is the NTC thermistor, unless it is stated otherwise.

Heat Operated Switch

  1. The circuit of a heat operated switch is similar to the light operated switch, except that the LDR is replaced by an NTC thermistor.
  2. If heat is applied to the thermistor, its resistance drops. As a result, the base voltage will increase and the transistor is switched on and the bulb lights.

Sound Controlled Switch

  1. Figure above shows the circuit design of a sound controlled switch.
  2. The microphone is used to convert sound to electric current.
  3. The variable resistor is adjusted as such that the transistor is switched on when sound is detected by the microphone.
  4. The function of the capacitor is to prevent the direct current from the cell to flow in the base circuit.

 

9.4.1 Transistors

  1. A transistor is a double p-n junction semiconductor with three terminals, 
    1. the emitter (e), 
    2. the base (b) 
    3. the collector (c).
  2. Figure below shows the illustration of a transistor. It looks like a combination of 2 p-n junction diodes.
  3. In a transistor, the emitter emits charge carriers (free electrons or holes).
  4. The charge carriers move towards the base.
  5. Under certain condition, large amount of the charge carriers will pass through the thin base layer and to be collected by the collector.

Types of the Transistors

  1. There are 2 types of transistors:
    1. npn transistor
    2. pnp transistor
  2. Figure 2 below shows the illustration of the npn and pnp transistor and Figure 3 below shows the symbol of both npn and pnp transistor.
  3. For the symbol of the transistor, the arrow shows the direction of current. Take note that, for the emitter and base, the current always flow from the positive terminal to the negative terminal.

(Figure 2: Illustration of the npn and pnp transistor)

(Figure 3: Symbol of the npn and pnp transistor)

How a Transistor Work?

(Figure 4)
  1. In the Figure 4 above, there are 2 circuits in the connection:
    1. the base circuit
    2. the collector circuit
  2. The base circuit is forward bias whereas the collector circuit is reverse bias (This will be discuss in "The Connection of a Transistor").
  3. Table below shows the response of bulb 1 (B1) and bulb 2 (B2) when switch 1 (S1) and switch 2 (S2) are closed.
S1
S2
B1
B2
Open
Open
 Does not light up
 Does not light up
Close
Open
 Light up
Does not light up 
Open
Close
 Does not light up
 Does not light up
Close
Close
 Light up
Light up 

  1. From the table, we can see that, the collector circuit is controlled by the base circuit.
  2. Current will flow in collector circuit only when the base circuit is closed.

Connection of Transistor

  1. The terminals of a transistor must be connected to the terminals of a cell correctly to avoid damaging the transistor.
  2. Transistor should be connected in such a way that
    1. the emitter-base circuit is forward bias
    2. the collector-base circuit is reverse bias.

Example:

Emitter-Base: Forward Bias

Collector-Base: Reverse Bias

Connection: CORRECT

Example:

Emitter-Base: Forward Bias

Collector-Base: Reverse Bias

Connection: CORRECT

Example:

Emitter-Base: Forward Bias

Collector-Base: Forward Bias

Connection: INCORRECT

Example:

Emitter-Base: Forward Bias

Collector-Base: Forward Bias

Connection: INCORRECT


Current in a Transistor

  1. The current flows in the base, emitter and collector is called the base current (IB), the emitter current(IE) and the collector current(IC) respectively.
  2. Figure below shows the direction of the current in an npn transistor.
  3. In general, IE is related to IB and IC through the formula

IE = IB + IC

Another thing that you need to know about the 3 currents is

IE > IC > IB


 

9.3.2.2 Full-wave Rectification

  1. Figure above shows a circuit to produce full-wave rectification. 
  2. Using an ingenious arrangement of diodes, called a bridge rectifier, this reverses the negative half of each a.c. cycle, instead of just blocking it. 
  3. The result is that current always flows in the same direction through the load, no matter which way it leaves the supply. 
  4. Combine a transformer (to reduce mains voltage) with a bridge rectifier and a smoothing capacitor, and you have a mains-operated d.c. power supply - as used in radios, instead of batteries.
  5. Another method of full wave rectification is arrange two diode to the output of a transformer as show below. A similar result will be produced.

Smoothing


  1. In the circuit above, the `one-way' direct current flows in a series of surges with brief periods of zero current in between. 
  2. These surges can be partly smoothed out by connecting a large capacitor across the load.
  3. The capacitor charges up when current flows from the diode, then discharges through the load when the current from the diode is zero. 
  4. Smoothed in this way, the current through the load is similar to the steady direct current which would flow from a battery. 

 

9.3.2.1 Half-wave Rectification

  1. Diodes are also known as rectifiers. They can be used to change a.c. into d.c., a process called rectification.
  2. A simple rectification circuit is shown in figure below.
  3. The final waveform on the screen is the positive half only of the original a.c. waveform - hence the term 'half-wave' rectification.

Half-wave rectification: the negative part of the current is prevented from passing.

 

9.3.1 Semiconductor Diodes

The p-n junction

  1. We can produce a single crystal with p-type semiconductor on one side and n-type on the other side as shown in figure above.
  2. The border where the p-type and the n-type region meet is called the p-n junction.

Depletion Layer and Junction Voltage

  1. At the p-n junction, electrons from the n-type semiconductor will be attracted to the holes in the p-type semiconductor.
  2. As a result, the holes and the electrons at the p-n junction disappear, forming a layer called “depletion layer”.
  3. At the same time, the p-type semiconductor becomes more negative whereas the n-type semiconductor becomes more positive.
  4. This will result a potential difference across the p-n junction. This potential difference is called the junction voltage (or the barrier voltage).
  5. The junction voltage will prevent the charge carrier from flowing across the depletion layer.

Forward Bias And Reverse Bias

(figure 1)
  1. The figure above shows a dc source across a diode. The negative source terminal is connected to the n-type material, and the positive terminal is connected to the p-type material. 
  2. This connection Figure is called forward bias.
  3. Current flows easily in a forward-biased silicon diode.
    (Figure 2)
  4. Turn the dc source around and you reverse-bias the diode as shown in Figure 2. 
  5. This time, the negative battery terminal is connected to the p side, and the positive battery terminal to the n side. This connection is called reverse bias.

Depletion Layer Widens

  1. The negative battery terminal attracts the holes, and the positive battery terminal attracts the free electrons. Because of this, holes and free electrons flow away from the junction. Therefore, the depletion layer gets wider.

 

9.2.2.2 P-type Semiconductor

  1. A p-type semiconductor can be produced by doped some trivalent atoms into a semiconductor.
  2. Trivalent atom is atom has only three valence electrons. Examples include aluminum, boron, and gallium.
  3. Figure above shows an aluminium atom (which is trivalent ) in the center, surrounded by four silicon atoms.
  4. We can see that, the trivalent atom form 4 covalent bonds with the silicon atoms around. Since the trivalent atom has only three valence electrons and each neighbour shares one electron, only seven electrons are in the valence orbit..
  5. This means a hole exists in the valence orbit of each trivalent atom. A trivalent tom is also called an acceptor atom because each hole it contributes can accept a free electron.
  6. The more trivalent impurity that is added, the more holes in the semiconductor, and hence the greater the conductivity of the semiconductor.
  7. Some free electrons will also formed in the semiconductor when some electrons are promoted to shell with higher energy level.
  8. The holes outnumber the free electrons, hence they are called the majority carrier and the free electrons are called the minority carriers.
  9. Since the positive charge carrier (the holes) outnumber the negative charge carrier (the free electrons), the semiconductor is called a p-type semiconductor, where the p stands for positive. 

 

p-type semiconductor n-type semiconductor
Doping Material Trivalent:
aluminum, boron, and gallium
Pentavalent:
antimony, and phosphorus
Role of doping material Atom receiver Atom donor
Majority Charge Carrier Holes Free electrons
Minority Charge Carrier Free electrons Holes