Radio Inspire

How To Learn Sign Language

How Does Hardware and Software Communicate?


A System resource is a tool used by either
hardware or software to communicate with each other. When software wants to send data to a device,
such as when you want to save a file to a hard drive. Or when the hardware needs attention, such
as when you press a key on the keyboard. The hardware or software uses system resources
to communicate. There are four types of system resources.
memory addresses input output addresses
interrupt requests and direct memory access channels when we press a key on the keyboard, the keyboard
wants to tell the CPU that a key has been pressed. but CPU is already busy doing something else. So the keyboard places a volatage on the IRQ
line assigned to it. And this voltage serves as a signal to the
CPU that the device has a request which needs processing. An operating system relates to memory as a
long list of cells that it can use to hold data and instructions, somewhat like one dimensional
spreadsheet. Think of a memory address as a seat number
in a theatre. Each seat is assigned a number regardless
of whether someone is sitting in it. The person sitting in a seat can be data or
instructions. And the OS does not refer to the person by
the name but only by the seat number. For example, the operating system might say,
I want to print data in memory address 500. These addresses are most often displayed on
the screen as hexadecimal number in segment offset form. Input output addresses which are simply called
ports, the CPU can use to access hardware devices in much the same way it uses memory
address to access physical memory. The address bus on the motherboard sometimes
carries memory addresses and sometimes carries input output addresses. If the address bus has been set to carry input
output addresses, then each hardware device listens to this bus. For example, if CPU wants to communicate with
keyboard, It will place the Input Output address of keyboard on the address bus. Once address is placed, CPU announces, Input
Output addresses are on the address line. Now all input output controllers listen for
their address. Hard drive controller says not my address. Floppy disk controller says not my address. But keyboard controller says its mine, I’ll
respond. Input Output address lines on the bus work
much like an old telephone party line. All devices hear the addresses but only one
responds. Another system resource used by hardware and
software is a direct memory access channel. A shortcut method that lets an input output
device send data directly to memory bypassing the CPU. some devices such as the printer are designed
to use DMA channels. and others such as the mouse are not. DMA channels are not as popular as they once
were. because their design makes them slower than
newer methods.. however slower
devices such as floppy drives, sound cards and tape drives may still use DMA channels. So basically hardware devices call the CPU
for attention using Interrupt Requests. Software calls a hardware by input output
address of hardware device. software looks at a memory as a hardware device
and calls it with memory address. DMA channels pass data back and forth between
hardware device and memory. So thats how.. the hardware.. communicates with software !

Leave a Reply

Your email address will not be published. Required fields are marked *