You are on page 1of 43

CS270: INTRODUCTION TO COMPUTER

ENGINEERING

Switches
31st March 2023

Switches 31st March 2023 1


Content

• Switches
• The CMOS Transistor
• Building Circuits Using Gates
• Class Exercises
• Gates vs. switches
• Conclusion

Switches 31st March 2023 2


Switches 31st March 2023 3
Switches 31st March 2023 4
Switches 31st March 2023 5
Switches 31st March 2023 6
Switches 31st March 2023 7
Switches 31st March 2023 8
Switches 31st March 2023 9
Switches 31st March 2023 10
Switches 31st March 2023 11
Switches 31st March 2023 12
Switches 31st March 2023 13
Fuse and Circuit Breakers

Switches 31st March 2023 14


Fuses

Switches 31st March 2023 15


Fuse (contd.)

Switches 31st March 2023 16


Switches 31st March 2023 17
Circuit Breakers

Switches 31st March 2023 18


Circuit Breakes (contd.)

Switches 31st March 2023 19


Switches 31st March 2023 20
Switches 31st March 2023 21
Two Main Types of Circuit Breakers

• Miniature Circuit Breaker (MCB)


• Residual Current Circuit Breaker (RCCB)

Switches 31st March 2023 22


Miniature Circuit Breaker (MCB)
(i) Magnetic Type
• This type of MCB consists of an electromagnet.
• If the current exceeds the rating of the circuit-breaker the
pulling force of the magnet attracts an iron latch which
breaks the electrical contacts.

Switches 31st March 2023 23


Miniature Circuit Breaker (MCB) (contd.)
• Thermal Type
• This type makes use of the heating effect of electricity on
a bi-metallic strip.
• An increase in current causes the bi-metallic strip to bend
which breaks contact made via a latch mechanism.

Switches 31st March 2023 24


Residual Current Circuit Breaker (RCCB)
• Residual current circuit breakers work by comparing the current
entering the appliance via the live wire with the current leaving
the appliance through the neutral wire.
• Residual Current Circuit Breakers have the advantage of being
highly sensitive and a very quick response time making them
safe.

Switches 31st March 2023 25


Revision on Switches
• Electronic switches are the basis of
binary digital circuits
– Electrical terminology
• Voltage: Difference in electric potential

4.5 A
4.5 A
between two points (volts, V) – +
9V
– Analogous to water pressure
• Resistance: Tendency of wire to resist
2 ohms
current flow (ohms, )
– Analogous to water pipe diameter 9V
0V
• Current: Flow of charged particles (amps, A)
– Analogous to water flow 4.5 A
• V = I * R (Ohm’s Law) a

– 9 V = I * 2 ohms
– I = 4.5 A If a 9V potential difference is applied
across a 2 ohm resistor, then 4.5 A of
current will flow.

Switches 31st March 2023 26


Revision on Switches (contd.)
control
• A switch has three parts input

– Source input, and output “off”

• Current tries to flow from source


input to output source output
input a

– Control input control


input
• Voltage that controls whether that “on”
current can flow
source output
• The amazing shrinking switch input
– 1930s: Relays (b)

– 1940s: Vacuum tubes


– 1950s: Discrete transistor
– 1960s: Integrated circuits (ICs)
• Initially just a few transistors on IC discrete
• Then tens, hundreds, thousands... transistor
IC
relay vacuum tube

quarter
(to see the relative size)

Switches 31st March 2023 27


Moore’s Law
• IC capacity doubling about every 18 months
for several decades
– Known as “Moore’s Law” after Gordon Moore,
co-founder of Intel
• Predicted in 1965 predicted that components
per IC would double roughly every year or so
– Figure 2 depicts related phenomena
• For a particular number of transistors, the IC
area shrinks by half every 18 months
– Consider how much shrinking occurs in just 10
years (try drawing it)
– Enables incredibly powerful computation in
incredibly tiny devices
– Today’s ICs hold billions of transistors
• The first Pentium processor (early 1990s)
needed only 3 million

Figure 2. An Intel Pentium processor IC


having millions of transistors

Switches 31st March 2023 28


Relating Boolean Algebra to Digital Design
Boolean NOT OR AND
Boole’s intent: formalize x x
algebra human thought Symbol x F F F
y y
(mid-1800s)
x F x y F x y F
Switches For telephone Truth table 0 1 0 0 0 0 0 0
switching and other 1 0 0 1 1 0 1 0
(1930s)
electronic uses 1 0 1 1 0 0
1 1 1 1 1 1

Showed application 1 0 0

Shannon (1938) of Boolean algebra y


x y
to design of switch-
based circuits Transistor
x F
x F
circuit F y

x y
Digital design x
0
1 1
• Implement Boolean operators using
transistors 1.8 V
Next slides show how
“1”
these circuits work.
– Call those implementations logic gates. 1.2 V Note: The above OR/AND
– Lets us build circuits by doing math - 0.6 V implementations are
inefficient; we’ll show why,
“0”
- powerful concept 0V and show better ones,
later.
1 and 0 each actually corresponds to
a voltage range

Switches 31st March 2023 29


Building Circuits Using Gates

– Turn on lamp (F=1) when motion sensed (a=1) and no light (b=0)
– F = a AND NOT(b)
– Build using logic gates, AND and NOT, as shown
– In that case, a first digital circuit is built.

Switches 31st March 2023 30


Exs. 1: Seat Belt Warning
Light System
• Design circuit for warning light
• Sensors
– s=1: seat belt fastened w = NOT(s) AND k
– k=1: key inserted
BeltWarn
• Capture Boolean equation
k w
– seat belt not fastened, and key
inserted
a

• Convert equation to circuit s

Seatbelt
• Timing diagram illustrates circuit Inputs
behavior k
1
– We set inputs to any values 0
1
– Output set according to circuit s a
0
Outputs
1
w
0

time
Switches 31st March 2023 31
Exs. 2: Seat belt warning light extensions
• Only illuminate warning light if
k Belt W a rn

person is in the seat (p=1), p w

and seat belt not fastened a

and key inserted


s
• w = p AND NOT(s) AND k

• Given t=1 for 5 seconds after key inserted. k BeltWarn


Turn on warning light when t=1 (to check
that warning lights are working) p
w
• w = (p AND NOT(s) AND k) OR t s
a

Switches 32 31st March 2023


Gates vs. switches
Notice
– Boolean algebra enables easy
capture as equation and conversion
to circuit
• How design with switches?
• Of course, logic gates are built from
switches, but we think at level of logic
gates, not switches
w = NOT(s) AND k
1 BeltWarn

0 BeltWarn
s
k w

w
0

k s

1 Seatbelt a

Switches 31st March 2023 33


Exs.2: Applying DeMorgan’s Law (a + b)’ = a’b’
(ab)’ = a’ + b’

Aircraft lavatory sign • Behavior • Alternative: Instead of


example • Three lavatories, each with sensor (a, lighting “Available,”
b, c), equals 1 if door locked
light “Occupied”
• Light “Available” sign (S) if any lavatory
available – Opposite of
“Available” function
• Equation and circuit
• S = a’ + b’ + c’ S = a’ + b’ + c’
• Transform – So S’ = (a’ + b’ + c’)’
• (abc)’ = a’+b’+c’ (by DeMorgan’s Law) • S’ = (a’)’ * (b’)’ * (c’)’
(by DeMorgan’s
• S = (abc)’ Law)
• New circuit • S’ = a * b * c (by
Involution Law)

Circuit
– Makes intuitive sense
a • Occupied if all doors
Circuit are locked
S a S
b b
c
c

Switches 31st March 2023 34


Class Exs. 3

Determine if F=ab+a’ is same function as


F=a’b’+a’b+ab, by converting each to truth
table first

Switches 31st March 2023 35


Circuit Delay and Critical Path
k BeltWarn

p 1 ns
1 ns
1 ns 1 ns a
w
s 1 ns 1+1+1+1+1 = 5 ns
1 ns
1 ns 1 ns 1+0.5+1+1+1+1+1 = 6.5 ns
0.5 ns
t 1 ns 1+1+1 = 3 ns
Critical path delay = 6.5 ns
Hence, circuit’s delay is 6.5 ns
• Wires also have delay
• Assume gates and wires have delays as shown
• Path delay – time for input to affect output
• Critical path – path with longest path delay
• Circuit delay – delay of critical path

Switches 31st March 2023 36


CMOS
• CMOS: Complementary metal–oxide–semiconductor
• Is a technology for constructing integrated circuits
• It is also known as Real-Time Clock (RTC), Non-Volatile
RAM (NVRAM) or CMOS RAM, CMOS
• It is used in microprocessors, microcontrollers, static
RAM, and other digital logic circuits
• CMOS is an on-board, battery
powered semiconductor chip inside
computers that stores information

Switches 31st March 2023 37


CMOS (contd.)
• Digital logic circuits
• Static RAM (SRAM)
• Microprocessors
• Microcontrollers

Switches 31st March 2023 38


The CMOS Transistor
• CMOS transistor
– Basic switch in modern ICs
a
A positive ...attracts electrons here,
voltage here... turning the channel between
the source and drain into nMOS
a conductor 1 0
gate
gate
oxide
IC package
source drain conducts does not
conduct

pMOS
1 0
IC gate
(a)

Silicon -- not quite a conductor or insulator: does not conducts


conduct
Semiconductor

Switches 31st March 2023 39


CMOS Transistor Analogy

Switches 40 31st March 2023


Conclusion
• Combinational circuits
– Circuit whose outputs are function of present inputs
• No “state”
• Switches: Basic component in digital circuits
• Boolean logic gates: AND, OR, NOT – Better building block
than switches
– Enables use of Boolean algebra to design circuits
• Boolean algebra: Uses true/false variables/operators
• Representations of Boolean functions: Can translate among
• Combinational design process: Translate from equation (or
table) to circuit through well-defined steps
Switches 31st March 2023 41
Conclusion (contd.)
• More gates: NAND, NOR, XOR, XNOR also useful
• A fuse is made up of a piece of metal that melts
when overheated
• Fuses tend to be quicker to interrupt the flow of
power, but must be replaced after they melt, while
circuit breakers can usually simply be reset.
• A circuit breaker has an internal switch
mechanism that is tripped by an unsafe surge of
electricity,

Switches 31st March 2023 42


End

Switches 31st March 2023 43

You might also like