Interfacing with peripherals: analog to digital converters and digital to analog converters in 8086 (MCMP)

4,884 views 32 slides Jun 28, 2021
Slide 1
Slide 1 of 32
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32

About This Presentation

A MCMP presentation on Interfacing with peripherals: analog to digital converters and digital to analog converters in 8086


Slide Content

Ujjain Engineering College, Ujjain Department of Electronics and Communication Engineering Topic -: Interfacing with Peripherals- Analog to Digital Converters and Digital to Analog converters in 8086 Guided By :- Miss Anshul Malik PRASANNA VYAS (0701ec191043) PRASHANT KAUSHAL (0701ec191044) PRIYASH KIRADE (0701ec191045) RADHESHYAM PARMAR (0701ec191046) RAHUL JARIWALA (0701ec191047) NIMESH SINGH (0701ec191037) NISHA MAHESHWARI (0701ec191038) PALAK GUPTA (0701ec191039) PANKHURI VAPTA (0701ec191040) PARTH ARJARIYA (0701ec191041) PRANITA NIRAPURE (0701ec191042) Submitted By :-

Synopsis Interfacing with peripherals, 8255 PPI in brief ADC interfacing ADC 0808/0809 Interfacing ADC 0808 with 8086 using 8255 PPI DAC interfacing AD 7523 8 bit multiplying DAC Interfacing AD 7523 with 8086 using 8255 PPI

Interfacing With Peripherals Any application of a microprocessor based system requires the transfer of data between external circuitry to the microprocessor and from microprocessor to the external circuitry. The transfer of data is called input/output data transfer or I/O data transfer. This data transfer is done with the help of I/O ports. This type of interfacing is called I/O interfacing. External devices (connected to I/O ports) used to interface are called peripheral devices. There are many peripheral devices which can be interfaced with microprocessor like keyboard, mouse, printer, 8253 timer, 8255 PPI, ADCs and DACs.

8255 Programmable Peripheral Interface(PPI) For most of the applications 8086 needs parallel input ,output data to/from the peripherals. 8255 is a device used to interface different real time peripherals to the microprocessors which can be initialized for different modes operations like simple I/O, Strobed I/O and handshaking I/O. It has three 8-bit parallel ports : port A, port B, port C.

PIN DIAGRAM

Modes of Operation 8255 can be used in two modes: Bit set/Reset (BSR) mode and I/O mode. The BSR mode is used to set or reset the bits in port C. The I/O mode is further divided into 3 modes: mode 0, mode 1 and mode 2. Mode 0: Ports A, B, and C can be individually programmed as input or output ports. Port C is divided into two 4-bit ports which are independent from each other.

Modes of Operation Mode 1 : Ports A and B are programmed as input or output ports. Port C is used for handshaking. In the handshake mode, two types of I/O data transfer can be implemented: status check and interrupt. Mode 2 : Port A is programmed to be bi-directional. Port C is for handshaking. Port B can be either input or output in mode 0 or mode 1.

ADC INTERFACING This topic is aimed at the study of 8-bit and 12-bit analog to digital converters and their interfacing with 8086. In most of the cases, the PIO 8255 is used for interfacing the analog to digital converters with a microprocessor. The function of an A/D converter is to produce a digital word which represents the magnitude of some analog voltage or current.

ADC INTERFACING The resolution of an A/D converter refers to the number of bits in the output binary word. Accuracy and linearity specifications have the same meaning for an A/D converter as they do for a D/A converter. Another important specification for an ADC is its conversion time.

ADC INTERFACING This is simply the time it takes the converter to produce a valid output binary code for an applied input voltage. After the conversion is over, the ADC sends end of conversion (EOC) signal to inform the microprocessor and the result is ready at the output buffer of the ADC. The time taken by the ADC from the active edge of SOC pulse (the edge at which the conversion process actually starts) till the active edge of EOC signal is called as the conversion delay of the ADC.

ADC INTERFACING The available ADCs in the market use different conversion techniques for the conversion of analog signals to digital signals. Parallel converter or flash converter, Successive approximation and dual slope integration techniques are the most popular techniques used in the integrated ADC chips.

ADC 0808/0809 These are unipolar analog to digital converters, i.e. they are able to convert only positive analog input voltages to their digital equivalents. These chips do not contain any internal sample and hold circuit. The analog to digital converter chips 0808 and 0809 are 8-bit CMOS, successive approximation converters. The conversion delay is 100 µs at a clock frequency of 640 kHz, which is quite low as compared to other converters.

ADC 0808/0809 These converters internally have a 3:8 analog multiplexer so that at a time eight different analog inputs can be connected to the chips. Out of these eight inputs only one can be selected for conversion by using address lines ADD A, ADD B and ADD C, as shown. Using these address inputs, multichannel data acquisition systems can be designed using a single ADC.

ADC 0808/0809 PIN diagram

ADC INTERFACING A general algorithm for ADC interfacing contains the following steps : 1. Ensure the stability of analog input, applied to the ADC. 2. Issue start of conversion (SOC) pulse to ADC. 3. Read end of conversion (EOC) signal to mark the end of conversion process. 4. Read digital data output of the ADC as equivalent digital output.

ADC 0808/0809 Block diagram

Interfacing ADC 0808 with 8086 using 8255 ports Interface ADC 0808 with 8086 using 8255 ports. Use Port A of 8255 for transferring digital data output of ADC to the CPU and Port C for control signals. Assume that an analog input is present at I/P2 of the ADC and a clock input of suitable frequency is available for ADC. Draw the schematic and write required ALP.

Interfacing ADC 0808 with 8086 using 8255-STeps The analog input I/P2 is used & therefore address pins A,B,C should be 0,1,0 respectively to select I/P2. The OE (Out put latch Enable) & ALE pins are already kept at +5v to select the ADC and enable the outputs. Port C upper acts as the input port to receive the EOC signal while Port C lower acts as the output port to send SOC to ADC. Port A acts as a 8-bit input data port to receive the digital data output from the ADC.

Interfacing ADC 0808 with 8086 using 8255 The 8255 control word is written as follows: D7 D6 D5 D4 D3 D2 D1 D0 Control Word 1 1 1 = 98H

Interfacing ADC 0808 with 8086 using 8255- Block diagram

Interfacing ADC 0808 with 8086 using 8255 ports- ALP The required ALP is given as follows:

Dac iNTERFACING The digital to analog converters convert binary numbers into their analog equivalent voltages or currents. Several techniques are employed for digital to analog conversion. Weighted resistor network R-2R ladder network Current output D/A converter

DAC INTERFACING The DAC find applications in areas like : Digitally controlled gains Motor speed controls Programmable gain amplifiers etc. D/A converter have many applications besides those where they are used with a microcomputer. Most speech synthesizer integrated circuits contain a D/A converter to convert stored binary data words into analog audio signals.

DAC INTERFACING Characteristics: Resolution: It is a change in analog output for one LSB change in digital input. It is given by(1/2^n )*Vref. Settling time: It is the time required for the DAC to settle for a full scale code change

AD 7523 8-Bit Multiplying DAC Intersil’s AD 7523 is a 16 pin DIP, multiplying digital to analog converter, containing R-2R ladder (R=10K) for digital to analog conversion. Power supply +5v to +15v Vref -> -10v to +10v The maximum analog output voltage will be +10v

AD 7523 8-Bit Multiplying DAC A Zener is connected between OUT1 & OUT2 to save the DAC from negative transients. An operational amplifier is used as a current – to – voltage converter at the output of AD 7523. An external feedback resister acts to control the gain.

AD 7523 8-Bit Multiplying DAC pin diagram

Interfacing of AD 7523 with 8086 Interface DAC AD7523 with the 8086 running at 8MHz & write ALP to generate a saw tooth waveform of period 1ms with Vmax 5v.

Interfacing of AD 7523 with 8086 The required ALP is as follows:

Interfacing of AD 7523 with 8086-Block diagram

References https://www.iare.ac.in/sites/default/files/lecture_notes/IARE_MPID_Lectures_Notes.pdf https://vtucsenotes.files.wordpress.com/2013/06/unit-6.pdf https://nptel.ac.in/content/storage2/courses/106108100/pdf/Teacher_Slides/mod3/M3L8.pdf

Thank You