The Z-80 microprocessor : architecture, interfacing, programming and design by Gaonkar Ramesh S

The Z-80 microprocessor : architecture, interfacing, programming and design by Gaonkar Ramesh S

Author:Gaonkar, Ramesh S [Gaonkar, Ramesh S]
Language: eng
Format: epub
Tags: Memory, data, program, address, instruction, contents, interrupt, port, byte, memory location, assembly language, address lines, memory address, data transfer, stack pointer, control signals, data bus, opcode operand, memory locations
ISBN: 0675205409
Publisher: London : Merrill
Published: 1988-11-15T00:00:00+00:00


0 000

IdeallyQuantizedAnalogInput

FIGURE 12.8

A 3-bit A/D Converter (a) Block Diagram (b) Analog-to-Digital Conversion

□ Provide a START pulse to initialize the conversion process by writing to the device asan output port.

□ Wait until the end of the conversion.

□ Read the binary equivalent when the DATA READY signal goes active.

We need to interpret these conditions in terms of circuitry and control signals. Themicroprocessor can communicate with any external device through a port address and itsRead and Write control signals. To meet the above requirements we need to build

n one output port to send a START pulse,

□ one input port with a latch so that the Z80 can read the binary data,

□ a circuit to sense the end of the conversion.

Fortunately, manufacturers have begun to include latches, buffers, and control logicon the same chip with data converters so that data converters can be easily interfaced withthe microprocessor. For our illustration, we selected the National SemiconductorADC0801 because it has all the necessary interfacing circuitry built in.

THE ADC0801

This is an 8-bit A/D converter (Figure 12.9(a)) available as an integrated circuit on a chip.The analog signal is connected to Vin(+), and the binary output is available on eight datalines DB7-DB0. The maximum input signal can be +5 V or it can be connected as adifferential input by using the pin Vin(-). The signal Vref is used to limit the maximuminput voltage; if it is not connected externally, it is set for +5 V internally. The internalclock is determined by the RC network connectged to pins 10 and 4.

To interface the A/D converter with the microprocessor requires three signals: CS,

WR, and RD. To start the conversion, the chip should be selected and WR asserted low.When WR goes low, the chip is reset, and when it goes high, the conversion begins. At theend of the conversion, it initiates the signal INTR; this can be used to interrupt the micro-processor. When the microprocessor reads the output, the INTR is reset (see the timingwaveforms in Figure 12.9(b)). The ADC0801 is ideally suited for interfacing as an inter-rupt I/O not only because it generates the INTR pulse, but also because it is turned off afterthe data byte is read. This eliminates our concern about the INT pulse width for the Z80microprocessor.

12.33 Interfacing Circuit

To interface the ADC0801, three signals are necessary: WR, RD, and CS. Figure 12.9(a)shows such a circuit. The output line Oq of the 3-to-8 decoder is connected to the CS signalof the converter. The converter is selected when the address on the address lines from A7-Ao is F8h; thus, the converter is assigned the port address F8h. To start the conversion, theZ80 should write to port F8h; however, we are interested not in writing anything, but inasserting the WR signal. At the end of the conversion, the converter asserts the INTR,which is connected to the INT signal of the Z80.

Assuming the Z80 interrupt is enabled and is set for Mode 1, the program will betransferred to memory location 0038h. If the system is being designed, the service routineto read data can be written at 00.



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.
Popular ebooks
Architecting High-Performance Embedded Systems by Jim Ledin(1324)
DIY Microcontroller Projects for Hobbyists by Miguel Angel Garcia-Ruiz Pedro Cesar Santana Mancilla(1247)
Raspberry Pi For Dummies by Sean McManus(763)
Computers for Seniors for Dummies by Nancy C. Muir(621)
Troubleshooting and Maintaining PCs All-in-One For Dummies by Dan Gookin(566)
Windows 10: The Missing Manual by Pogue David(522)
Arduino Uno: A Hands-On Guide for Beginner by Agus Kurniawan(467)
Getting Started with Adafruit FLORA by Becky Stern(462)
Teach Yourself VISUALLY Chromebook by Guy Hart-Davis(434)
Samsung Galaxy S6 for Dummies by Bill Hughes(418)
IMac for Dummies by Chambers Mark L.;(373)
Raspberry Pi: A Step-by-Step Guide For Beginners to Program and Set-Up Top 10 Raspberry Pi Projects + First Steps on Configuration by Cage Jonathan(368)
Raspberry Pi 4: The Ultimate Step-by-Step Guide to Using Raspbian to Create Incredible Projects and Expand Your Programming Skills with the Latest Version of Raspberry Pi by Liam Clark(356)
2020 Ultimate Guide to Raspberry Pi : Tips, Tricks and Hacks by oney Youssef & oney Youssef(350)
iPad For Seniors For Dummies by Jesse Feiler(350)
Software Architecture by Neal Ford(345)
Super Arduino: Step-by-Step Instructions to Build Cool Gadgets by Kenneth Hawthorn(335)
Raspberry Pi: Tips and Tricks to Learn Raspberry Pi Programming by Pratt Logan(322)
Build Your Own Autonomous NERF Blaster by Bryce Bigger(312)
RASPBERRY PI 4 : A Comprehensive Guide to Raspberry Pi 4 Setup, Learning Programming and Developing Innovative Projects by DENTON DUKE(312)