Chapter 10 Input / Output Organization CS 147 Yueyang Zhou.

Slides:



Advertisements
Similar presentations
Accessing I/O Devices Processor Memory BUS I/O Device 1 I/O Device 2.
Advertisements

INPUT-OUTPUT ORGANIZATION
11-1 ECE 424 Design of Microprocessor-Based Systems Haibo Wang ECE Department Southern Illinois University Carbondale, IL I/O System Design.
PROGRAMMABLE PERIPHERAL INTERFACE -8255
Chapter 10 Input/Output Organization. Connections between a CPU and an I/O device Types of bus (Figure 10.1) –Address bus –Data bus –Control bus.
82C55 82C55 Programmable Peripheral Interface Interfacing Part III.
COMP3221: Microprocessors and Embedded Systems Lecture 17: Computer Buses and Parallel Input/Output (I) Lecturer: Hui.
Processor System Architecture
CS-334: Computer Architecture
FIU Chapter 7: Input/Output Jerome Crooks Panyawat Chiamprasert
Lecture Objectives: 1)Explain the limitations of flash memory. 2)Define wear leveling. 3)Define the term IO Transaction 4)Define the terms synchronous.
Input-output and Communication Prof. Sin-Min Lee Department of Computer Science.
DIRECT MEMORY ACCESS CS 147 Thursday July 5,2001 SEEMA RAI.
COMP3221: Microprocessors and Embedded Systems Lecture 15: Interrupts I Lecturer: Hui Wu Session 1, 2005.
Basic Input/Output Operations
1 Interrupts INPUT/OUTPUT ORGANIZATION: Interrupts CS 147 JOKO SUTOMO.
I/O Subsystem Organization and Interfacing Cs 147 Peter Nguyen
Input-Output Problems L1 Prof. Sin-Min Lee Department of Mathematics and Computer Science.
9/20/6Lecture 3 - Instruction Set - Al Hardware interface (part 2)
Practical Session No. 10 Input &Output (I/O). I/O Devices Input/output (I/O) devices provide the means to interact with the “outside world”. An I/O device.
Basic Computer Organization CH-4 Richard Gomez 6/14/01 Computer Science Quote: John Von Neumann If people do not believe that mathematics is simple, it.
GURSHARAN SINGH TATLA PIN DIAGRAM OF 8085 GURSHARAN SINGH TATLA
Unit-5 CO-MPI autonomous
INPUT-OUTPUT ORGANIZATION
Lecture 12 Today’s topics –CPU basics Registers ALU Control Unit –The bus –Clocks –Input/output subsystem 1.
Input/Output. Input/Output Problems Wide variety of peripherals —Delivering different amounts of data —At different speeds —In different formats All slower.
Khaled A. Al-Utaibi  Intel Peripheral Controller Chips  Basic Description of the 8255  Pin Configuration of the 8255  Block Diagram.
Dr. Rabie A. Ramadan Al-Azhar University Lecture 6
Fig 8-4 p-341. S 5 =IF flag (interrupt Enable). S 6 =0 always.
MICROPROCESSOR INPUT/OUTPUT
Basic I/O Interface A Course in Microprocessor
1 Input-Output Organization Computer Organization Computer Architectures Lab Peripheral Devices Input-Output Interface Asynchronous Data Transfer Modes.
1. Introduction 2. Methods for I/O Operations 3. Buses 4. Liquid Crystal Displays 5. Other Types of Displays 6. Graphics Adapters 7. Optical Discs 10/01/20151Input/Output.
(More) Interfacing concepts. Introduction Overview of I/O operations Programmed I/O – Standard I/O – Memory Mapped I/O Device synchronization Readings:
Dr Mohamed Menacer College of Computer Science and Engineering Taibah University CE-321: Computer.
Applications of PPI A/D - Temperature Sensor. Analog to Digital.
Accessing I/O Devices Processor Memory BUS I/O Device 1 I/O Device 2.
Input-Output Organization
CH10 Input/Output DDDData Transfer EEEExternal Devices IIII/O Modules PPPProgrammed I/O IIIInterrupt-Driven I/O DDDDirect Memory.
7. Peripherals 7.1 Introduction of peripheral devices Computer Studies (AL)
Computer Hardware A computer is made of internal components Central Processor Unit Internal External and external components.
CE Operating Systems Lecture 2 Low level hardware support for operating systems.
12/16/  List the elements of 8255A Programmable Peripheral Interface (PPI)  Explain its various operating modes  Develop a simple program to.
PPI-8255.
CE Operating Systems Lecture 2 Low level hardware support for operating systems.
PROGRAMMABLE PERIPHERAL INTERFACE -8255
Input/Output Problems Wide variety of peripherals —Delivering different amounts of data —At different speeds —In different formats All slower than CPU.
I/O Interface. INTRO TO I/O INTERFACE I/O instructions (IN, INS, OUT, and OUTS) are explained. Also isolated (direct or I/O mapped I/O) and memory-mapped.
I/O Organization Competency – C6. Important facts to remember when I/O devices are to be connected to CPU There is a vast variety of I/O devices. Some.
بسم الله الرحمن الرحيم MEMORY AND I/O.
1 Device Controller I/O units typically consist of A mechanical component: the device itself An electronic component: the device controller or adapter.
ASYNCHRONOUS DATA TRANSFER
Chapter 6 Input/Output Organization
Chapter 10 Input/Output Organization
Chapter 7.2 Computer Architecture
1 Input-Output Organization Computer Organization Computer Architectures Lab Peripheral Devices Input-Output Interface Asynchronous Data Transfer Modes.
Chapter 8 Input/Output I/O basics Keyboard input Monitor output
Interfacing Memory Interfacing.
8255.
Parallel communication interface 8255
Programmable Peripheral Interface
X1 & X2 These are also called Crystal Input Pins.
Md. Mojahidul Islam Lecturer Dept. of Computer Science & Engineering
Md. Mojahidul Islam Lecturer Dept. of Computer Science & Engineering
Chapter 8 I/O.
COMP3221: Microprocessors and Embedded Systems
William Stallings Computer Organization and Architecture
Presentation transcript:

Chapter 10 Input / Output Organization CS 147 Yueyang Zhou

Overview Some examples of I/O Devices Synchronous data transfers Asynchronous data transfers Source-initiated data transfer without handshaking Destination-initiated data transfer without handshaking Source-initiated data transfer with handshaking Destination-initiated data transfer with handshaking Programmed I/O A thermostat The control algorithm of Thermostat

Examples of I/O Devices A personal computer Keyboard (input) Mouse(input) Monitor(output) Printer(output) Microwave ovens Sensor(input) Output signals

Devices Interface Controler Data I/O CPU Address bus Data bus Control bus

Synchronous data transfers Synchronous transfers usually occur when peripherals are located within the same computer as the CPU because their close proximity allows them to share a common clock and because data does not have to travel very far physically, which becomes a concern at a higher clock frequencies.

Asynchronous data transfers A computer can make use of asynchronous data transfers when synchronous transfers are not viable. Asynchronous transfers use control signals and their associated hardware to coordinate the movement of data. These data transfer do not require that the source and destination use the same system clock. There are four types of asynchronous data transfers.

The source outputs its data. Then strobes a control signal for a set amount of time. The destination device reads in the data during this time. The source device next desserts the strobe and stops outputting data.

Destination-initiated data transfer without handshaking The destination device transmits a data strobe signal to the source device which, after a brief delay, makes data available. The destination device reads in this data The destination device deasserts the data strobe.

For some devices, particularly electromechanical devices, do not require the same amount of time for every transfer, they can use handshaking to coordinate their transfers. Handshaking uses an additional control signal to indicate that data is ready or has been read in.

The timing for a source- initiated data transfer with handshaking

The source sets the data request signal high. Makes valid data available to the destination device The destination device reads in data. The destination device sends a data acknowledge signal to the source. The source sets its data request line low and stops sending data. The destination then resets its data acknowledge signal.

Similar to that of the source-initiated data transfer using handshaking, except that the data-acknowledge signal is replaced by a data-ready signal.

Definition: Programmed I/O is exactly what its name implies: A program instruction causes the CPU to input or output data. Programmed I/O can be either isolated or memory mapped. Isolated I/O uses separate instructions to access I/O ports. Memory-mapped I/O treats I/O ports as memory locations.

It perform the following sequence of operation: 1.Read temperature from external sensor. 2.If (temperature > thermostat setting +2) then turn on air conditioner. 3.If (temperature < thermostat setting and air conditioner is on) then turn off air conditioner. 4.If (temperature < thermostat setting – 2) then turn on heat. 5.If (temperature > thermostat setting and heat is on) then turn off heat. 6.Go to start of sequence.

1.Illustration An input port at address FFFFH Whenever the illustration LDAC FFFF is executed, the CPU reads data from this port and stores it in its accumulator register. 2.Implementation Design the hardware for the input port Makes data available to the CPU The CPU would read the data from the data bus

1.The tri-state buffers are only enable when: The address bus contains the value FFFFH Control bus signal READ= 1 2.Data from the input port passes on to the data bus of the computer. 3.Data is read in by the CPU. 4.Data stored in data register. 5.CPU moves data from its data register into its accumulator.

1.The software programmer is responsible for: The CPU never attempts to access memory location FFFFH The input port has been assigned to this address It cannot be used by a memory location 2.This is one of the limitation of memory-mapped I/O.

1.The CPU reads in the current temperature from the memory-mapped input port at address FFFH 2.The thermostat setting from the port at address FFFE 3.The CPU controls the heating and air conditioning system. 4.Writing one of the four values to the output port at address FFFD 01 = turn on air conditioning 02 = turn off air conditioning 03 = turn on heat 04 = turn off heat 5.The current status is stord in memory location 1000H 00 = heat and air conditioning are both off FF = heat is on FE = air conditioning is on

NEW INSTRUCTION InstructionInstruction Code Operation INPT TAC Input port T OTPT TOutput port T AC

New control signals 1.When using isolated I/O Need a signal to distinguish between memory references and I/O references 2.Without this signal, it is not possible to tell whether an address refers to a memory location or to an I/O port 3.We create a new signal called IO IO = 1 for input/ output operations IO = 0 for memory reference operations

1.Difference between INPT instruction and the LDAC instruction. In state LDAC4, the LDAC instruction reads data from memory. During the corresponding state of the INPT instruction’s execute routine, it must read data from an input port.

The modification the state diagram for the CPU

Modify the CPU hardware for the new instruction

Summary Synchronous data transfers Asynchronous data transfers Source-initiated data transfer without handshaking Destination-initiated data transfer without handshaking Source-initiated data transfer with handshaking Destination-initiated data transfer with handshaking Programmed I/O A thermostat