Vous êtes sur la page 1sur 96

Edited with the trial version of Foxit Advanced PDF Editor To remove this notice, visit: www.foxitsoftware.

com/shopping

ME2255- ELECTRONICS & MICROPROCESSOR

KARTHIC.K AP/ECE

SSM COLLEGE OF ENGINEERING

UNIT 1

SEMICONDUCTORS & DIODES

ELECTRICAL CONDUCTIVITY
In order of conductivity: superconductors, conductors, semiconductors, insulators
conductors: material capable of carrying electric current, i.e. material which has mobile charge carriers (e.g. electrons, ions,..) e.g. metals, liquids with ions (water, molten ionic compounds), plasma insulators: materials with no or very few free charge carriers; e.g. quartz, most covalent and ionic solids, plastics semiconductors: materials with conductivity between that of conductors and insulators; e.g. germanium Ge, silicon Si, GaAs, GaP, InP superconductors: certain materials have zero resistivity at very low temperature.

ENERGY BANDS IN SOLIDS:


In solid materials, electron energy levels form bands of allowed energies, separated by forbidden bands valence band = outermost (highest) band filled with electrons (filled = all states occupied) conduction band = next highest band to valence band (empty or partly filled) gap = energy difference between valence and conduction bands, = width of the forbidden band Note:
electrons in a completely filled band cannot move, since all states occupied (Pauli principle); only way to move would be to jump into next higher band - needs energy; electrons in partly filled band can move, since there are free states to move to.

CLASSIFICATION OF SOLIDS INTO THREE TYPES, ACCORDING TO THEIR BAND STRUCTURE:


insulators: gap = forbidden region between highest filled band (valence band) and lowest empty or partly filled band (conduction band) is very wide, about 3 to 6 eV; semiconductors: gap is small about 0.1 to 1 eV; conductors: valence band only partially filled, or (if it is filled), the next allowed empty band overlaps with it

Band structure and conductivity

Band structure and conductivity

INTRINSIC SEMICONDUCTORS
semiconductor = material for which gap between valence band and conduction band is small; (gap width in Si is 1.1 eV, in Ge 0.7 eV). at T = 0, there are no electrons in the conduction band, and the semiconductor does not conduct (lack of free charge carriers); at T > 0, some fraction of electrons have sufficient thermal kinetic energy to overcome the gap and jump to the conduction band; fraction rises with temperature; e.g. at 20o C (293 K), Si has 0.9x1010 conduction electrons per cubic centimeter; at 50o C (323 K) there are 7.4x1010 .

Intrinsic semiconductor
electrons moving to conduction band leave hole (covalent bond with missing electron) behind; under influence of applied electric field, neighboring electrons can jump into the hole, thus creating a new hole, etc. holes can move under the influence of an applied electric field, just like electrons; both contribute to conduction. in pure Si and Ge, there are equally many holes (p-type charge carriers) as there are conduction electrons (ntype charge carriers); pure semiconductors also called intrinsic semiconductors.

N-Type material
donor (n-type) impurities:
dopant with 5 valence electrons (e.g. P, As, Sb) 4 electrons used for covalent bonds with surrounding Si atoms, one electron left over; left over electron is only loosely bound only small amount of energy needed to lift it into conduction band (0.05 eV in Si) n-type semiconductor, has conduction electrons, no holes (apart from the few intrinsic holes) example: doping fraction of 10-8 Sb in Si yields about 5x1016 conduction electrons per cubic centimeter at room temperature, i.e. gain of 5x106 over intrinsic Si.

N-TYPE MATERIAL

P-TYPE MATERIAL
acceptor (p-type) impurities:
dopant with 3 valence electrons (e.g. B, Al, Ga, In) only 3 of the 4 covalent bonds filled vacancy in the fourth covalent bond hole p-type semiconductor, has mobile holes, very few mobile electrons (only the intrinsic ones).

advantages of doped semiconductors:


cantune conductivity by choice of doping fraction can choose majority carrier (electron or hole) can vary doping fraction and/or majority carrier within piece of semiconductor can make p-n junctions (diodes) and transistors

P-TYPE MATERIAL

DIODES
p-n JUNCTION:
p-n junction = semiconductor in which impurity changes abruptly from p-type to ntype ; diffusion = movement due to difference in concentration, from higher to lower concentration; in absence of electric field across the junction, holes diffuse towards and across boundary into n-type and capture electrons; electrons diffuse across boundary, fall into holes (recombination of majority carriers); formation of a depletion region (= region without free charge carriers) around the boundary; charged ions are left behind (cannot move):
negative ions left on p-side net negative charge on p-side of the junction; positive ions left on n-side net positive charge on n-side of the junction electric field across junction which prevents further diffusion

Diode

PN Junction

DIODE
diode = biased p-n junction, i.e. p-n junction with voltage applied across it forward biased: p-side more positive than n-side; reverse biased: n-side more positive than p-side; forward biased diode:
the direction of the electric field is from p-side towards n-side p-type charge carriers (positive holes) in p-side are pushed towards and across the p-n boundary, n-type carriers (negative electrons) in n-side are pushed towards and across n-p boundary current flows across p-n boundary

DIODE

FORWARD BIASED

REVERSE BIASED
reverse biased diode: applied voltage makes n-side more positive than p-side electric field direction is from n-side towards pside pushes charge carriers away from the p-n boundary depletion region widens, and no current flows

diode only conducts when positive voltage applied to pside and negative voltage to n-side diodes used in rectifiers, to convert ac voltage to

REVERSE BIASED

ZENER DIODES

ZENER DIODES
The simplest of all voltage regulators is the zener diode voltage regulator. A zener diode is a special diode that is optimized for operation in the breakdown region.

ZENER DIODE CIRCUIT


The zener diode is typically connected reverse biased, in parallel with the load. Resistor Rs limits current to zener.

Simplest rectifier
Simplest rectifier resistive load

Simplest rectifier

VOLTAGE REGULATION
A voltage regulator circuit automatically maintains the output voltage of a power supply constant, regardless of a change in the load - a change in the source voltage

SERIES VOLTAGE REGULATOR

SHUNT VOLTAGE REGULATOR

Unit-2

TRANSISTORS AND AMPLIFIERS

TRANSISTORS
(bipolar) transistor = combination of two diodes that share middle portion, called base of transistor; other two sections: emitter'' and collector; usually, base is very thin and lightly doped. two kinds of bipolar transistors: pnp and npn transistors pnp means emitter is p-type, base is n-type, and collector is ptype material; in normal operation of pnp transistor, apply positive voltage to emitter, negative voltage to collector;

TRANSISTORS

OPERATION OF PNP TRANSISTOR


if emitter-base junction is forward biased, holes flow from battery into emitter, move into base; some holes annihilate with electrons in ntype base, but base thin and lightly doped most holes make it through base into collector, holes move through collector into negative terminal of battery; i.e. collector current flows whose size depends on how many holes have been captured by electrons in the base; this depends on the number of n-type carriers in the base which can be controlled by the size of the current (the base current) that is allowed to flow from the base to the emitter; the base current is usually very small; small changes in the base current can cause a big difference in the collector current;

PNP TRANSISTOR

PNP TRANSISTOR
if emitter-base junction is forward biased, holes flow from battery into emitter, move into base; some holes annihilate with electrons in ntype base, but base thin and lightly doped most holes make it through base into collector, holes move through collector into negative terminal of battery; i.e. collector current flows whose size depends on how many holes have been captured by electrons in the base; this depends on the number of n-type carriers in the base which can be controlled by the size of the current (the base current) that is allowed to flow from the base to the emitter; the base current is usually very small; small changes in the base current can cause a big difference in the collector current;

PNP TRANSISTOR
Operation as amplifier
Transistor acts as amplifier of base current, since small changes in base current cause big changes in collector current. transistor as switch: if voltage applied to base is such that emitter-base junction is reverse-biased, no current flows through transistor -- transistor is off therefore, a transistor can be used as a voltage-controlled switch; computers use transistors in this way.

Field-effect Transistor (FET)


In a pnp FET, current flowing through a thin channel of ntype material is controlled by the voltage (electric field) applied to two pieces of ptype material on either side of the channel (current depends on electric field). Many different kinds of FETs FETs are the kind of transistor most commonly used in computers.

Field-effect Transistor (FET)

SCRs and Their Characteristics


The silicon controlled rectifier (SCR) is a four-layer pnpn device with three leads, the anode, gate, and cathode. An SCR will not conduct until the forward breakover voltage is reached, even though its anodecathode is forward-biased. The gate current in an SCR controls the forward breakover voltage. Once an SCR turns on, the gate loses all control. The only way to turn an SCR off is to reduce the anode current below the holding current,

SCRs and Their Characteristics


A silicon controlled rectifier (SCR) is a four-layer pnpn device. Fig. 32-3 (a) shows the basic construction of an SCR, and Fig. 32-3 (b) shows the schematic symbol. The SCR has three external leads: the anode, cathode, and gate.

SCRs and Their Characteristics

Triacs
A triac is a bi-directional thyristor used to control the power in ac circuits. A triac has two leads designated MT1, and MT2 or A1 and A2. A triac has a gate lead which is used to control its conduction. A triac is equivalent to two SCRs in parallel.

Triacs

TRIACS

Unijunction Transistors
The unijunction transistor (UJT) is a three-terminal semiconductor device that has only one p-n junction. The unijunction transistor (UJT) has two base leads, B1 and B2 and an emitter (E) lead. The interbase resistance, RBB of a UJT is the resistance of its n-type silicon bar. The ratio RB1/(RB1 + RB2) is called the intrinsic standoff ratio, designated . UJTs are used in conjunction with SCRs and Triacs to control their conduction angle.

Unijunction Transistors operation


The unijunction transistor (UJT) is a three-terminal semiconductor device that has only one p-n junction. The unijunction transistor (UJT) has two base leads, B1 and B2 and an emitter (E) lead. The interbase resistance, RBB of a UJT is the resistance of its n-type silicon bar. The ratio RB1/(RB1 + RB2) is called the intrinsic standoff ratio, designated . UJTs are used in conjunction with SCRs and Triacs to control their conduction angle.

Unijunction Transistors symbol

UNIJUNCTION TRANSISTORS CHARACTERISTICS


Negative resistance is illustrated in the emitter characteristic curve shown in Fig. 32-12.

Once VP is reached, the emitter voltage, VE, decreases as IE increases.

UNIJUNCTION TRANSISTORS CHARACTERISTICS

UNIJUNCTION TRANSISTORS CIRCUIT DIAGRAM

Application
Fig. 32-13 shows how a UJT can be used as a relaxation oscillator. Because the voltage waveform, VB1 is a sharp pulse of short duration, it is the ideal gate triggering source for either an SCR or triac.

Unit-3

DIGITAL ELECTRONICS

DIGITAL
Digital system is known as any electronic system that handle and process electrical signals in the form of 0s and 1s, no more analog signals used here.

Logic gates
A logic gate is an elementary building block of a digital circuit. logic gate is an electronic circuit can perform specific processing on the input signals. Logic gates have two inputs and one output.

Basic logic gates

A 0 1

Y 1 0

BASIC LOGIC GATES

A 0 0 1

B 0 1 0

Y 0 0 0

EX-OR GATE
A 0 0 1 1 B 0 1 0 1 Y 0 1 1 0

NAND GATE
A B Y

1 1

0 1

1 0

Boolean algebra basics


logic operations symbols: OR: (+) Plus symbol, e.g.:Y= A+B AND: (.) Dot symbol, e.g.: Y=A.B NOT: () a bar is drawn above the letter, e.g.: Y= . XOR: ( ) Plus symbol surrounded with a circle, e.g.: Y=A B.

Boolean algebra basics


. Commutative e.g. A+B = B+A, A.B = B.A. 2. Associative e.g. A+(B+C) = (A+B)+C = A+B+C, (B.C) = (A.B).C = A.B.C. 3.Distributive

e.g. A (B+C) = AB + AC.

Boolean algebra basics


A+1= 1. A+0= A. A.0= 0. A.1= A. A+A= A. A+= 1. A.A= A. A. = 0. A+AB= A.

A+ B= A+B. A=A. -De Morgan's law:

THE 8085 MICROPROCESSOR ARCHITECTURE & INTERFACING

The 8085 and Its Buses


The 8085 is an 8-bit general purpose microprocessor that can address 64K Byte of memory. It has 40 pins and uses +5V for power. It can run at a maximum frequency of 3 MHz.
The pins on the chip can be grouped into 6 groups:
Address Bus. Data Bus. Control and Status Signals. Power supply and frequency. Externally Initiated Signals. Serial I/O ports.

The Address and Data Busses


The address bus has 8 signal lines A8 A15 which are unidirectional. The other 8 address bits are multiplexed (time shared) with the 8 data bits.
So, the bits AD0 AD7 are bi-directional and serve as A0 A7 and D0 D7 at the same time.
During the execution of the instruction, these lines carry the address bits during the early part, then during the late parts of the execution, they carry the 8 data bits.

In order to separate the address from the data, we can use a latch to save the value before the function of the bits changes

The Control and Status Signals


There are 4 main control and status signals. These are:
ALE: Address Latch Enable. This signal is a pulse that become 1 when the AD0 AD7 lines have an address on them. It becomes 0 after that. This signal can be used to enable a latch to save the address bits from the AD lines. RD: Read. Active low. WR: Write. Active low. IO/M: This signal specifies whether the operation is a memory operation (IO/M=0) or an I/O operation (IO/M=1). S1 and S0 : Status signals to specify the kind of operation being performed .Usually un-used in small systems.

Frequency Control Signals


There are 3 important pins in the frequency control group.
X0 and X1 are the inputs from the crystal or clock generating circuit.
The frequency is internally divided by 2.
So, to run the microprocessor at 3 MHz, a clock running at 6 MHz should be connected to the X0 and X1 pins.

CLK (OUT): An output clock pin to drive the clock of the rest of the system

Microprocessor Communication and Bus Timing


To understand how the microprocessor operates and uses these different signals, we should study the process of communication between the microprocessor and memory during a memory read or write operation.

Steps For Fetching an Instruction


Lets assume that we are trying to fetch the instruction at memory location 2005. That means that the program counter is now set to that value.
The following is the sequence of operations:
The program counter places the address value on the address bus and the controller issues a RD signal. The memorys address decoder gets the value and determines which memory location is being accessed. The value in the memory location is placed on the data bus. The value on the data bus is read into the instruction decoder inside the microprocessor. After decoding the instruction, the control unit issues the proper control signals to perform the operation.

Timing Signals For Fetching an Instruction


At T1 , the high order 8 address bits (20H) are placed on the address lines A8 A15 and the low order bits are placed on AD7 AD0. The ALE signal goes high to indicate that AD0 AD8 are carrying an address. At exactly the same time, the IO/M signal goes low to indicate a memory operation. At the beginning of the T2 cycle, the low order 8 address bits are removed from AD7 AD0 and the controller sends the Read (RD) signal to the memory. The signal remains low (active) for two clock periods to allow for slow devices. During T2 , memory places the data from the memory location on the lines AD7 AD0 . During T3 the RD signal is Disabled (goes high). This turns off the output Tri-state buffers in the memory. That makes the AD7 AD0 lines go to high impedence mode.

Demultiplexing AD7-AD0
From the above description, it becomes obvious that the AD7 AD0 lines are serving a dual purpose and that they need to be demultiplexed to get all the information. The high order bits of the address remain on the bus for three clock periods. However, the low order bits remain for only one clock period and they would be lost if they are not saved externally. Also, notice that the low order bits of the address disappear when they are needed most. To make sure we have the entire address for the full three clock cycles, we will use an external latch to save the value of AD7 AD0 when it is carrying the address bits. We use the ALE signal to enable this latch.

Demultiplexing AD7-AD0
8085
A15-A8 ALE AD7-AD0 Latch

A7- A0

D7 - D0

Given that ALE operates as a pulse during T1, we will be able to latch the address. Then when ALE goes low, the address is saved and the AD7 AD0 lines can be used for their purpose as the bidirectional data lines.

Cycles and States


T- State: One subdivision of an operation. A T-state lasts for one clock period.
An instructions execution length is usually measured in a number of Tstates. (clock cycles).

Machine Cycle: The time required to complete one operation of accessing memory, I/O, or acknowledging an external request.
This cycle may consist of 3 to 6 T-states.

Instruction Cycle: The time required to complete the execution of an instruction.


In the 8085, an instruction cycle may consist of 1 to 6 machine cycles.

Generating Control Signals


The 8085 generates a single RD signal. However, the signal needs to be used with both memory and I/O. So, it must be combined with the IO/M signal to generate different control signals for the memory and I/O.
Keeping in mind the operation of the IO/M signal we can use the following circuitry to generate the right set of signals:

The ALU
In addition to the arithmetic & logic circuits, the ALU includes the accumulator, which is part of every arithmetic & logic operation. Also, the ALU includes a temporary register used for holding data temporarily during the execution of the operation. This temporary register is not accessible by the programmer.

The Flags register


S-sign flag
The sign flag is set if bit D7 of the accumulator is set after an arithmetic or logic operation.

Z-zero flag
Set if the result of the ALU operation is 0. Otherwise is reset. This flag is affected by operations on the accumulator as well as other registers. (DCR B).

AC-Auxiliary Carry
This flag is set when a carry is generated from bit D3 and passed to D4 . This flag is used only internally for BCD operations. (Section 10.5 describes BCD addition including the DAA instruction).

P-Parity flag
After an ALU operation if the result has an even # of 1s the p-flag is set. Otherwise it is cleared. So, the flag can be used to indicate even parity.

CY-carry flag
Discussed earlier

The 8085 machine cycles


The 8085 executes several types of instructions with each requiring a different number of operations of different types. However, the operations can be grouped into a small set. The three main types are:
Memory Read and Write. I/O Read and Write. Request Acknowledge.

These can be further divided into various operations (machine cycles).

Opcode Fetch Machine Cycle


Opcode fetch cycle.
In this cycle, the microprocessor brings in the instructions Opcode from memory.
To differentiate this machine cycle from the very similar memory read cycle, the control & status signals are set as follows:
IO/M=0, s0 and s1 are both 1.

This machine cycle has four T-states.


The 8085 uses the first 3 T-states to fetch the opcode. T4 is used to decode and execute it.

It is also possible for an instruction to have 6 T-states in an opcode fetch machine cycle

Memory Read Machine Cycle


The memory read machine cycle is exactly the same as the opcode fetch except:
It only has 3 T-states The s0 signal is set to 0 instead.

The Memory Read Machine Cycle


To understand the memory read machine cycle, lets study the execution of the following instruction:
MVI A, 32

In memory, this instruction looks like:


The first byte 3EH represents the opcode for loading a byte into the accumulator (MVI A), the second byte is the data to be loaded.

The 8085 needs to read these two bytes from memory before it can execute the instruction. Therefore, it will need at least two machine cycles.
The first machine cycle is the opcode fetch discussed earlier. The second machine cycle is the Memory Read Cycle. Figure 3.10 page 83.

The Memory Write Operation


In a memory write operation:
The 8085 places the address (2065H) on the address bus Identifies the operation as a memory write (IO/M=0, s1=0, s0=1). Places the contents of the accumulator on the data bus and asserts the signal WR. During the last T-state, the contents of the data bus are saved into the memory location.

Memory interfacing
There needs to be a lot of interaction between the microprocessor and the memory for the exchange of information during program execution.
Memory has its requirements on control signals and their timing. The microprocessor has its requirements as well.

The interfacing operation is simply the matching of these requirements.

Memory structure & its requirements


Data Lines

RAM
Input Buffer WR Address Lines CS CS

Address Lines

Output Buffer Output Buffer RD Date Lines

RD

Data Lines

The process of interfacing the above two chips is the same.


However, the ROM does not have a WR signal.

Interfacing Memory
Accessing memory can be summarized into the following three steps:
Select the chip. Identify the memory register. Enable the appropriate buffer.

Translating this to microprocessor domain:


The microprocessor places a 16-bit address on the address bus. Part of the address bus will select the chip and the other part will go through the address decoder to select the register. The signals IO/M and RD combined indicate that a memory read operation is in progress. The MEMR signal can be used to enable the RD line on the memory chip.

Address decoding
The result of address decoding is the identification of a register for a given address.
A large part of the address bus is usually connected directly to the address inputs of the memory chip. This portion is decoded internally within the chip. What concerns us is the other part that must be decoded externally to select the chip. This can be done either using logic gates or a decoder.

Interfacing concepts
Interfacing concepts together
8085
A15-A8
ALE
CS

A15- A10

Chip Selection Circuit

A9- A0
AD7-AD0 Latch

A7- A0

1K Byte Memory Chip

WR RD

IO/M

D7 - D0
RD WR

Interfacing the 8155


The 8155 is a special chip designed to work with the 8085 to demonstrate the interfacing of the 8085. the 8155 has 256 bytes of RAM, 2 programmable I/O ports and a timer. It is usually used in systems designed for use in university labs.

Traffic light controller

Stepper motor controller


In the PM type stepper motor, a permanent magnet is used for rotor and coils are put on stator. The stepper motor model which has 4poles is shown in the figure on the left. In case of this motor, step angle of the rotor is 90 degrees. As for four poles, the top and the bottom and either side are a pair. coil, coil and coil, coil correspond respectively. For example, coil and coil are put to the upper and lower pole. coil and coil are rolled up for the direction of the pole to become opposite when applying an electric current to the coil and applying an electric current to the coil. It is similar about and , too. The turn of the motor is controlled by the electric current which pours into , , and . The rotor rotational speed and the direction of the turn can be controlled by this control.

STEPPER MOTOR CONTROLLER

STEPPER MOTOR CONTROLLER

TEMPERATURE CONTROLLER
To accurately control process temperature without extensive operator involvement, a temperature control system relies upon a controller, which accepts a temperature sensor such as a thermocouple or RTD as input. It compares the actual temperature to the desired control temperature, or setpoint, and provides an output to a control element. The controller is one part of the entire control system, and the whole system should be analyzed in selecting the proper controller. The following items should be considered when selecting a controller: Type of input sensor (thermocouple, RTD) and temperature range Type of output required (electromechanical relay, SSR, analog output) Control algorithm needed (on/off, proportional, PID) Number and type of outputs (heat, cool, alarm, limit)

TEMPERATURE CONTROLLER
There are three basic types of controllers: onoff, proportional and PID. Depending upon the system to be controlled, the operator will be able to use one type or another to control the process. On/Off Control An on-off controller is the simplest form of temperature control device. The output from the device is either on or off, with no middle state. An on-off controller will switch the output only when the temperature crosses the setpoint. For heating control, the output is on when the temperature is below the setpoint, and off above setpoint. Since the temperature crosses the setpoint to change the output state, the process temperature will be cycling continually, going from below setpoint to above, and back below. In cases where this cycling occurs rapidly, and to prevent damage to contactors and valves, an on-off differential, or hysteresis, is added to the controller operations.

TEMPERATURE CONTROLLER
This differential requires that the temperature exceed setpoint by a certain amount before the output will turn off or on again. On-off differential prevents the output from chattering or making fast, continual switches if the cycling above and below the setpoint occurs very rapidly. On-off control is usually used where a precise control is not necessary, in systems which cannot handle having the energy turned on and off frequently, where the mass of the system is so great that temperatures change extremely slowly, or for a temperature alarm. One special type of on-off control used for alarm is a limit controller. This controller uses a latching relay, which must be manually reset, and is used to shut down a process when a certain temperature is reached

THANKYOU

Vous aimerez peut-être aussi