You are on page 1of 4

TITLE : Memory Mapped I/O & Dedicated I/O OBJECTIVE : To understand the difference between Memory Mapped I/O

/O & Dedicated I/O To understand the advantages and disadvantages of the input/output mapped memory and input/output mapped separately.

THEORY : Memory Mapped I/O Memory-mapped I/O uses the same address bus to address both memory and I/O devices, and the CPU instructions used to access the memory are also used for accessing devices. In order to accommodate the I/O devices, areas of CPU's addressable space must be reserved for I/O. The reservation might be temporarythe Commodore 64 could bank switch between its I/O devices and regular memoryor permanent. Each I/O device monitors the CPU's address bus and responds to any CPU's access of device-assigned address space, connecting the data bus to a desirable device's hardware register.
Bus Address Bus data RD Write

Memory

CPU

I/O Port

I/O Port

I/O Port

I/O Device

I/O Device

Memory Mapped I/O

Dedicated I/O Dedicated I/O uses a special class of CPU instructions specifically for performing I/O.This is generally found on Intel microprocessors, specifically the IN and OUT instructions which can read and write a single byte to an I/O device. I/O devices have a separate address space from general memory, either accomplished by an extra "I/O" pin on the CPU's physical interface, or an entire bus dedicated to I/O.

Bus Address Bus data MEMR MEMW IOR IOW

Memory

CPU

I/O Port

I/O Port

I/O Port

I/O Device

I/O Device

DISCUSSION : Advantages Memory-mapped I/O a limited addressing capability Because portmapped I/O separates I/O access from memory access, the full address space can be used for memory obvious to a person reading an assembly language program listing (or even, in rare instances, analyzing machine language)When I/O is being performed, due to the special instructions that can only be used for that purpose to accommodate the I/O devices, areas of CPU's addressable space must be reserved for I/O. The reservationmight be temporarythe Commodore 64 could bank switch between its I/O devices and regular memoryor permanent Disadvantages adds to the complexity and pin count of the microprocessor itself.

by discarding the extra complexity that port I/O brings, a CPU requires less internal logic and is thus cheaper, faster, easier to build, consumes less power and can be physically

very limited, often providing only forplain load and store operations between CPU registers and I/O ports. for example,to add a constant to a portmapped device register would require three instructions: readthe port to a CPU register, add the constant to the CPU register, and write the result back to the port.

Dedicated I/O

smaller; this follows the basic tenets of reduced instruction set computing embedded systems regular memory instructions are used to address devices, all of the CPU's addressing modes are available for the I/O as well as the memory, and instructions that perform an ALU operation directly on a memory operand--loading an operand from a memory location, storing the result to a memory location, or both--can be used with I/O

device registers as well

CONLUSION : As a conclusion, we already understand the difference between Memory Mapped I/O & Dedicated I/O and understand the advantages and disadvantages of the input/output mapped memory and input/output mapped separately.Memory mapped IO is one where the processor and the IO device share the same memory location(memory) while IO mapped IO is one where the processor and the IO device have different memory located to each other. while in memory mapped I/O the I/O devices are mapped(identify for communication) through memory address. The address of the port will stored in memory locations. In I/O mapped I/O devices are mapped using the the port address.

You might also like