I/O Interface (Interrupt and DMA Mode) Last Updated : 13 Sep, 2025 Comments Improve Suggest changes Like Article Like Report The method that is used to transfer information between internal storage and external I/O devices is known as I/O interface. The CPU is interfaced using special communication links by the peripherals connected to any computer system. These communication links are used to resolve the differences between CPU and peripheral. I/O InterfaceNote: There exists special hardware components between CPU and peripherals to supervise and synchronize all the input and output transfers that are called interface units.Mode of TransferThe binary information that is received from an external device is usually stored in the memory unit. CPU merely processes the information but the source and target is always the memory unit. Data transfer between CPU and the I/O devices may be done in different modes: Programmed I/O. Interrupt- initiated I/O. Direct memory access( DMA). Programmed I/O In this each data item transfer is initiated by an instruction in the programUsually the transfer is from a CPU register and memory. In this case it requires constant monitoring by the CPU of the peripheral devices. In this case, the I/O device does not have direct access to the memory unit. A transfer from I/O device to memory requires the execution of several instructions by the CPUIncluding an input instruction to transfer the data from device to the CPU and store instruction to transfer the data from CPU to memory. Note: The CPU stays in the program loop until the I/O unit indicates that it is ready for data transfer. This keeps the CPU busy & can be avoided by using an interrupt facility. Interrupt-Initiated I/O Since in the above case we saw the CPU is kept busy unnecessarily. This situation can very well be avoided by using an interrupt driven method for data transfer. By using interrupt facility and special commands to inform the interface to issue an interrupt request signal whenever data is available from any device. Steps:In the meantime the CPU can proceed for any other program execution. The interface meanwhile keeps monitoring the device. Whenever it is determined that the device is ready for data transfer it initiates an interrupt request signal to the computer. Upon detection of an external interrupt signal the CPU stops momentarily the task that it was already performing, branches to the service program to process the I/O transfer and then return to the task it was originally performing. The I/O transfer rate is limited by the speed with which the processor can test and service a device. The processor is tied up in managing an I/O transfer; a number of instructions must be executed for each I/O transfer. Interrupt-driven I/OTypes of Interrupts: Hardware and Software Interrupts: Hardware interrupts are triggered by hardware pins from external devices, while software interrupts are generated by executing specific instructions in a program when required.Vectored and Non-Vectored Interrupts: Vectored interrupts use a static vector address assigned by the system, whereas non-vectored interrupts use a dynamic vector address determined at runtime.Maskable and Non-Maskable Interrupts: Maskable interrupts can be explicitly enabled or disabled by the system, while non-maskable interrupts are always enabled and cannot be disabled (e.g., for critical events like power failure).External and Internal Interrupts: External interrupts are generated by external hardware devices such as I/O peripherals, while internal interrupts are generated by the processor itself, e.g., due to power failure or illegal instructions.Synchronous and Asynchronous Interrupts: Synchronous interrupts occur at fixed time intervals in a controlled manner, whereas asynchronous interrupts are triggered unpredictably based on external events or instruction feedback.Direct Memory AccessThe data transfer between a fast storage media such as magnetic disk and memory unit is limited by the speed of the CPU. Thus we can allow the peripherals directly communicate with each other using the memory buses, removing the intervention of the CPU. This type of data transfer technique is known as DMA or direct memory access. During DMA the CPU is idle and it has no control over the memory buses. The DMA controller takes over the buses to manage the transfer directly between the I/O devices and the memory unit. Bus grant request time. Transfer the entire block of data at transfer rate of device because the device is usually slow than the speed at which the data can be transferred to CPU. Release the control of the bus back to CPU So, Total time taken to transfer the N bytes = Bus grant request time + (N) * (memory transfer rate) + Bus release control time. Buffer the byte into the buffer & Inform the CPU that the device has 1 byte to transfer (i.e. bus grant request) Transfer the byte (at system bus speed) & Release the control of the bus back to CPU. I/O interface intro Visit Course Comment More infoAdvertise with us K kartik Follow Improve Article Tags : Computer Organization & Architecture Explore Basic Computer InstructionsWhat is a Computer? 8 min read Issues in Computer Design 1 min read Difference between assembly language and high level language 2 min read Addressing Modes in 8086 7 min read Difference between Memory based and Register based Addressing Modes 4 min read Von Neumann Architecture 6 min read Harvard Architecture 3 min read Interaction of a Program with Hardware 3 min read Simplified Instructional Computer (SIC) 4 min read Instruction Set used in simplified instructional Computer (SIC) 1 min read Instruction Set used in SIC/XE 2 min read RISC vs CISC 4 min read Vector processor classification 5 min read Essential Registers for Instruction Execution 3 min read Introduction of Single Accumulator based CPU organization 2 min read Stack based CPU Organization 4 min read Machine Control Instructions in Microprocessor 4 min read Very Long Instruction Word (VLIW) Architecture 4 min read Input and Output SystemsComputer Organization | Different Instruction Cycles 11 min read Machine Instructions 5 min read Instruction Formats 6 min read Difference between 2-address instruction and 1-address instructions 4 min read Difference between 3-address instruction and 0-address instruction 4 min read Register content and Flag status after Instructions 3 min read Debugging a machine level program 3 min read Vector Instruction Format in Vector Processors 7 min read Vector Instruction Types 4 min read Instruction Design and FormatIntroduction of ALU and Data Path 8 min read Computer Arithmetic | Set - 1 5 min read Computer Arithmetic | Set - 2 4 min read Difference Between 1's Complement Representation and 2's Complement Representation Technique 5 min read Restoring Division Algorithm For Unsigned Integer 5 min read Non-Restoring Division For Unsigned Integer 4 min read Computer Organization | Booth's Algorithm 7 min read How the Negative Numbers are Stored in Memory? 2 min read Microprogrammed ControlMicro-Operation 2 min read Microarchitecture and Instruction Set Architecture 5 min read Types of Program Control Instructions 6 min read Difference between CALL and JUMP instructions 5 min read Hardwired and Micro-programmed Control Unit 3 min read Implementation of Micro Instructions Sequencer 4 min read Performance of Computer in Computer Organization 5 min read Introduction to Control Unit and its Design 4 min read Computer Organization | Amdahl's law and its proof 2 min read Subroutine, Subroutine nesting and Stack memory 5 min read Different Types of RAM (Random Access Memory ) 8 min read Random Access Memory (RAM) and Read Only Memory (ROM) 8 min read 2D and 2.5D Memory organization 4 min read Input and Output OrganizationPriority Interrupts | (S/W Polling and Daisy Chaining) 5 min read I/O Interface (Interrupt and DMA Mode) 6 min read Direct memory access with DMA controller 8257/8237 3 min read Computer Organization | Asynchronous input output synchronization 7 min read Programmable peripheral interface 8255 4 min read Synchronous Data Transfer in Computer Organization 4 min read Introduction of Input-Output Processor 5 min read MPU Communication in Computer Organization 4 min read Memory Mapped I/O and Isolated I/O 5 min read Memory OrganizationIntroduction to memory and memory units 4 min read Memory Hierarchy Design and its Characteristics 6 min read Register Allocations in Code Generation 6 min read Cache Memory 5 min read Cache Organization | Set 1 (Introduction) 3 min read Multilevel Cache Organisation 6 min read Difference between RAM and ROM 7 min read Difference Between CPU Cache and TLB 4 min read Introduction to Solid-State Drive (SSD) 4 min read Read and Write operations in Memory 3 min read PipeliningInstruction Level Parallelism 5 min read Computer Organization and Architecture | Pipelining | Set 1 (Execution, Stages and Throughput) 9 min read Computer Organization and Architecture | Pipelining | Set 3 (Types and Stalling) 3 min read Computer Organization and Architecture | Pipelining | Set 2 (Dependencies and Data Hazard) 6 min read Last Minute Notes Computer Organization 15+ min read Like