0% found this document useful (0 votes)
36 views14 pages

Chapter 6

This document discusses I/O organization and system software and programming techniques. It describes two main types of I/O organization: programmed I/O and interrupt-driven I/O. It also discusses common system software including operating systems, device drivers, file systems, and networking software. Finally, it outlines several programming techniques for efficiently handling I/O such as system calls, concurrency, asynchronous I/O, buffering, caching, polling, and interrupts.

Uploaded by

eyoelbiniyam876
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
36 views14 pages

Chapter 6

This document discusses I/O organization and system software and programming techniques. It describes two main types of I/O organization: programmed I/O and interrupt-driven I/O. It also discusses common system software including operating systems, device drivers, file systems, and networking software. Finally, it outlines several programming techniques for efficiently handling I/O such as system calls, concurrency, asynchronous I/O, buffering, caching, polling, and interrupts.

Uploaded by

eyoelbiniyam876
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 14

1

CHAPTER 6
I/O ORGANIZATION AND SYSTEM
SOFTWARE AND PROGRAMMING
TECHNIQUES
2

Introduction
What is I/O organization?
 I/O organization is the way computers communicate with external
devices.
 Is essential for the efficient and reliable operation of any computer
system.
 I/O interfaces provide a standard way for the CPU to communicate
with different types of devices.
 They translate the CPU's electrical signals into a format that the
device can understand, and vice versa.
3

There are two main types of I/O organization:


1. Programmed I/O
 The CPU continuously polls the I/O device to check for its status
 This means that the CPU must constantly waste time checking the I/O
device, even if it is not ready.
 The simplest type of I/O organization, but it is also the slowest and most
inefficient.
2. Interrupt-driven I/O
 The CPU issues an I/O command to the device and then continues to
execute other instructions.
 When the I/O device is ready, it generates an interrupt signal to the CPU.
3. Direct memory access (DMA)
 Allow I/O devices to transfer data directly to and from memory without
involving the CPU.
 This can significantly improve the performance of I/O operations, as the
CPU does not have to waste time waiting for the transfer to complete.
4

I/O ports and buses


I/O ports are physical connectors that allow the CPU to
communicate with I/O devices.
They are typically located on the motherboard or on a
separate expansion card.
Some common examples of I/O ports include
• USB ports
• Serial ports
• Parallel ports
• HDMI ports
• VGA ports
• Ethernet ports
5

I/O ports and buses


I/O buses are electrical pathways that connect the CPU
to I/O devices.
I/O buses typically consist of a set of parallel wires that
carry data, address, and control signals.
Some common examples of I/O buses include:
PCI Express bus
USB bus
SATA bus
ATA bus
ISA bus
6

System software
Type of computer software that is designed to run and
manage computer hardware and software.
It is in contrast to application software, which includes
programs that are used for specific tasks.
Some common types of system software.
• Operating systems
• Device drivers
• File systems
• Networking software
7

System software
1. Operating system (OS)
Are the most important type of system software.
Managing the CPU and memory.
Are essential for the operation of any computer system.
Providing a platform for running application software
Providing services to application programs.
Some common operating systems include
Windows
Mac OS
Linux
Android
8

System software
2. Device drivers
 Is a computer program that allows a hardware device to communicate
with an operating system (OS).
 It translates the OS's commands into the device's specific language.
 It also handles data transfers between the device and the OS.
 Some common examples of device drivers include
Printer drivers
Scanner drivers
Network interface card (NIC) drivers
Graphics card drivers
Sound card drivers
Mouse drivers
Keyboard drivers
 Device drivers work by interacting with the OS and the hardware device
9

System software
3. File systems
A way of organizing and storing data on a disk or other storage
device.
It provides a logical structure for the data and manages how the
data is accessed and modified.
Efficiently organize and store our data.
File systems are an essential part of any computer system.
There are many different types of file systems, but some of
the most common include:
NTFS The default file system for Windows operating systems.
FAT32 such as USB drives and SD cards.
EXT4 The default file system for Linux operating systems.
APFS The default file system for mac OS operating systems.
10

System Software
4. Networking software
 It allows computers to communicate with each other and to access
resources on the network.
 It includes protocols for routing data between computers, as well as
programs for managing network devices and services.
 Some common networking software programs include
TCP/IP is the suite of protocols that is used to connect devices to the
internet.
It provides a reliable way to transmit data between computers.
UDP is a lightweight protocol that is often used for streaming video and
audio.
It is not as reliable as TCP/IP, but it is faster and more efficient.
DHCP It is not as reliable as TCP/IP, but it is faster and more efficient.
DNS s a protocol that translates domain names, such as google.com, into
IP addresses.
11

Programming Techniques
Methods and strategies that programmers use to write
code that efficiently and reliably interacts with input and
output (I/O) devices.
• System calls are low-level functions that provide an
interface between an application program and the
operating system.
• They allow the application program to request services
from the operating system, such as
Reading
writing files
creating and managing processes
accessing hardware devices.
12

Programming Techniques
• Concurrency is the ability of a computer system to execute
multiple tasks simultaneously.
• This can be achieved by multitasking or by multiprocessing.
• Multitasking allows the system to switch between multiple
tasks that are running on the same processor
• while multiprocessing allows the system to run multiple tasks
on multiple processors.
• Asynchronous programming is a programming paradigm
that allows tasks to be executed concurrently without
blocking the calling thread.
• This is achieved by using callback functions, promises,
futures, or other mechanisms to notify the calling thread
when a task has completed.
13

Programming Techniques
• Some common I/O programming techniques include
• Buffering:
• Is the process of storing data in a temporary location in memory before
transferring it to an I/O device.
• This can improve performance by reducing the number of times the CPU
has to access the I/O device.
• Caching:
• Is the process of storing frequently accessed data in memory so that it
can be retrieved quickly without having to access the I/O device.
• This can further improve performance.
• Asynchronous I/O:
• Asynchronous I/O allows the CPU to continue processing other tasks
while waiting for I/O operations to complete.
• This can improve responsiveness and prevent the program from blocking.
14

Programming techniques
• Polling:
• Polling is the process of repeatedly checking the status of
an I/O device to see if it is ready for data transfer. This is a
simple but inefficient technique that can waste CPU time.
• Interrupts:
• Interrupts are signals sent to the CPU by I/O devices
when they are ready for data transfer. This allows the
CPU to respond to I/O requests immediately, without
having to poll the devices.

You might also like