SlideShare a Scribd company logo
Accessing I/O devices

           V. Saranya
             AP/CSE
Sri vidya College of Engg & Tech
• I/O devices accessed through I/O interface.
• Requirements for I/O interface:
  – CPU communication
  – Device communication
  – Data buffering
  – Control and timing
  – Error detection.
CPU Communication:
• Processor sends commands to the I/O system
  which are generally the control signals on the
  control bus.
• Exchange of data between the processor and
  the I/O interface over the data bus.
• Check whether the devices are ready or not.
Data Buffering:
• Data transfer rate is too high .
• Data from processor and memory are sent to
  an I/O interface, buffered and then sent to the
  peripheral device at its data rate.
Error Detection:
• I/O interface is responsible for error detection
• Used to report errors to the processor.
• Types of errors:
  – Mechanical, electrical malfunctions, bad disk
    track, unintentional changes.
I/O interface Block diagram
                           Data Register
   Data                                                   Data
   Lines
                    Status/Control Register




Address Lines                                                Status
                 Address
                 Decoder                       External
                                                Device
                                              Interface          Control
 Control Lines                                   Logic
• Data Register: holds the data being
  transferred to or from the processor.
• Status/Control        Register:       contains
  information relevant to the operation.
• Data and status/control registers: are
  connected to the data bus.
• Address decoder: enables the device to
  recognize its address.
I/O interface for Input Device
                                                               Address Lines
BUS
                                                                   Data Lines


                                                                    Control lines




                                                          Data & Status
      Address Decoder   Control Circuits
                                                            Registers


                                                                          I/O
                                                                          interface
                                           Input Device
I/O interface for Output Device
                                                         Address Lines

BUS
                                                             Data Lines


                                                              Control lines




                                                    Data & Status
       Address Decoder   Control Circuits
                                                      Registers


                                                                    I/O
                                                                    interface
                                        Output Device
I/O interface Techniques
I/O Ports
• 4 registers - status, control, data-in, data-out
   – Status - states whether the current command is
     completed, byte is available, device has an error, etc
   – Control - host determines to start a command or
     change the mode of a device
   – Data-in - host reads to get input
   – Data-out - host writes to send output
• Size of registers - 1 to 4 bytes

                                                        10
I/O devices can be interfaced to a computer
  system I/O in 2 ways:

• Memory Mapped I/O

• I/O mapped I/O
Memory-Mapped I/O (1)
                           Memory Address Space




                  I/O Address Space

  (a) Separate I/O and memory space
  (b) Memory-mapped I/O
  (c) Hybrid                                  12
Memory Mapped I/O
• No need of special I/O instructions.
• Memory related instructions are used for I/O
  related operations.
I/O Mapped I/O



  Memory Address
     Space                 I/O address Space




Total Address Space
I/O Mapped I/O
• If we want to reduce the memory address
  space, we allot a different I/O address space,
  apart from total memory space.

Memory related instructions do not work here
Processor use these mode only for I/O Read, I/O
Write.
Difference between Memory Mapped
        I/O & I/O mapped I/O
        Memory Mapped I/O                           I/O Mapped I/O

Memory & I/O share the entire address    Processor provides separate address
        range of processor                    range for memory & I/O
Processor provides more address lines     Less address lines for accessing I/O
       for accessing memory
      More Decoding is required                Less decoding is required

Memory control signals used to control   I/O control signals are used to control
   Read & Write I/O operations                Read & Write I/O operations
Programmed I/O
• I/O operation means
  – A data transfer between an I/O device & memory
    or
  – Between I/O device & Processor.
• If any I/O operations are completely
  controlled by processor, then the system is
  said to be using “ Programmed I/O”
  – Processor has to check I/O system periodically
    until the operation completes  “POLLING”
  – Microprocessor has to check if any device need
    service.
Programmed I/O
                             j
              &     Int A?


                                     Service
              &                      routine A
Address
Decoder
                    Int C?
                             j
              &                      Service
                                     routine C



                    Int Z?
                                 j
                                     Service
                                     routine Z
Priority:
The Routines assigns priority to the different
  I/O devices
Port A is always checked 1st.
Then Port B
Then Port C
Order may change by changing routine.
• When Programmed I/O techniques is used:
  – Processor fetches I/O related instructions from
    memory and Issues I/O commands to I/O system
    to execute the instruction.
  – Memory Mapped I/O & I/O mapped I/O
    technique may apply.
  – Processor has 2 separate instructions IN & OUT
    for data transfer.
  – When the I/O instruction is encountered by the
    processor the I/O port is expected to be ready to
    response.
              Processor is usually programmed to test the I/O
               device status before initiating a data transfer.

More Related Content

What's hot

Direct memory access
Direct memory accessDirect memory access
Direct memory access
shubham kuwar
 
Input output organization
Input output organizationInput output organization
Input output organization
abdulugc
 
Input output interface
Input output interfaceInput output interface
Input output interface
Christ University
 
Instruction pipeline: Computer Architecture
Instruction pipeline: Computer ArchitectureInstruction pipeline: Computer Architecture
Instruction pipeline: Computer Architecture
InteX Research Lab
 
Memory Organization
Memory OrganizationMemory Organization
Memory Organization
Kamal Acharya
 
Modes of transfer
Modes of transferModes of transfer
Modes of transfer
Andhra University
 
Computer organization and architecture
Computer organization and architectureComputer organization and architecture
Computer organization and architecture
Subesh Kumar Yadav
 
Pin diagram 8085
Pin diagram 8085 Pin diagram 8085
Pin diagram 8085
Siddhesh Palkar
 
Input Output Organization
Input Output OrganizationInput Output Organization
Input Output Organization
Kamal Acharya
 
Computer organization memory
Computer organization memoryComputer organization memory
Computer organization memory
Deepak John
 
ADDRESSING MODES
ADDRESSING MODESADDRESSING MODES
ADDRESSING MODES
Sadaf Rasheed
 
Microprogrammed Control Unit
Microprogrammed Control UnitMicroprogrammed Control Unit
Microprogrammed Control Unit
PreethiSureshkumar1
 
Assembly Language
Assembly LanguageAssembly Language
Assembly Language
Ibrahimcommunication Al Ani
 
Direct memory access (dma)
Direct memory access (dma)Direct memory access (dma)
Direct memory access (dma)
Zubair Khalid
 
Architecture of 8086 Microprocessor
Architecture of 8086 Microprocessor  Architecture of 8086 Microprocessor
Architecture of 8086 Microprocessor
Mustapha Fatty
 
Bus aribration
Bus aribrationBus aribration
Bus aribration
Saiyam Agrawal
 
8259 Programmable Interrupt Controller
8259 Programmable Interrupt Controller8259 Programmable Interrupt Controller
8259 Programmable Interrupt Controller
abhikalmegh
 
Lecture 3 instruction set
Lecture 3  instruction setLecture 3  instruction set
Lecture 3 instruction set
Pradeep Kumar TS
 
8086 microprocessor-architecture
8086 microprocessor-architecture8086 microprocessor-architecture
8086 microprocessor-architecture
prasadpawaskar
 
Computer instructions
Computer instructionsComputer instructions
Computer instructions
Anuj Modi
 

What's hot (20)

Direct memory access
Direct memory accessDirect memory access
Direct memory access
 
Input output organization
Input output organizationInput output organization
Input output organization
 
Input output interface
Input output interfaceInput output interface
Input output interface
 
Instruction pipeline: Computer Architecture
Instruction pipeline: Computer ArchitectureInstruction pipeline: Computer Architecture
Instruction pipeline: Computer Architecture
 
Memory Organization
Memory OrganizationMemory Organization
Memory Organization
 
Modes of transfer
Modes of transferModes of transfer
Modes of transfer
 
Computer organization and architecture
Computer organization and architectureComputer organization and architecture
Computer organization and architecture
 
Pin diagram 8085
Pin diagram 8085 Pin diagram 8085
Pin diagram 8085
 
Input Output Organization
Input Output OrganizationInput Output Organization
Input Output Organization
 
Computer organization memory
Computer organization memoryComputer organization memory
Computer organization memory
 
ADDRESSING MODES
ADDRESSING MODESADDRESSING MODES
ADDRESSING MODES
 
Microprogrammed Control Unit
Microprogrammed Control UnitMicroprogrammed Control Unit
Microprogrammed Control Unit
 
Assembly Language
Assembly LanguageAssembly Language
Assembly Language
 
Direct memory access (dma)
Direct memory access (dma)Direct memory access (dma)
Direct memory access (dma)
 
Architecture of 8086 Microprocessor
Architecture of 8086 Microprocessor  Architecture of 8086 Microprocessor
Architecture of 8086 Microprocessor
 
Bus aribration
Bus aribrationBus aribration
Bus aribration
 
8259 Programmable Interrupt Controller
8259 Programmable Interrupt Controller8259 Programmable Interrupt Controller
8259 Programmable Interrupt Controller
 
Lecture 3 instruction set
Lecture 3  instruction setLecture 3  instruction set
Lecture 3 instruction set
 
8086 microprocessor-architecture
8086 microprocessor-architecture8086 microprocessor-architecture
8086 microprocessor-architecture
 
Computer instructions
Computer instructionsComputer instructions
Computer instructions
 

Similar to Accessing I/O Devices

Io devies
Io deviesIo devies
Io devies
Siddique Ibrahim
 
20ME702– MECHATRONICS -UNIT-3.ppt
20ME702– MECHATRONICS -UNIT-3.ppt20ME702– MECHATRONICS -UNIT-3.ppt
20ME702– MECHATRONICS -UNIT-3.ppt
Mohanumar S
 
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
Mohanumar S
 
PROGRAMMABLE PERIPHERAL INTERFCAE.ppt
PROGRAMMABLE PERIPHERAL INTERFCAE.pptPROGRAMMABLE PERIPHERAL INTERFCAE.ppt
PROGRAMMABLE PERIPHERAL INTERFCAE.ppt
karthik R
 
Unit2 p1 io organization-97-2003
Unit2 p1 io organization-97-2003Unit2 p1 io organization-97-2003
Unit2 p1 io organization-97-2003
Swathi Veeradhi
 
PPI-MECHATRONICS
PPI-MECHATRONICSPPI-MECHATRONICS
PPI-MECHATRONICS
selvakumar948
 
MECHATRONICS-Unit 3-PROGRAMMABLE PERIPERAL INTERFACE.ppt
MECHATRONICS-Unit 3-PROGRAMMABLE PERIPERAL INTERFACE.pptMECHATRONICS-Unit 3-PROGRAMMABLE PERIPERAL INTERFACE.ppt
MECHATRONICS-Unit 3-PROGRAMMABLE PERIPERAL INTERFACE.ppt
CHANDRA KUMAR S
 
UNIT- 3.pptx
UNIT- 3.pptxUNIT- 3.pptx
UNIT- 3.pptx
BASKARS53
 
Unit4_IO_13623_AnilRawat.ppt
Unit4_IO_13623_AnilRawat.pptUnit4_IO_13623_AnilRawat.ppt
Unit4_IO_13623_AnilRawat.ppt
prateeksingh235912
 
Unit 4-lecte3-io interface
Unit 4-lecte3-io interfaceUnit 4-lecte3-io interface
Unit 4-lecte3-io interface
vishal choudhary
 
Unit 4-l ecture3-io interface
Unit 4-l ecture3-io interfaceUnit 4-l ecture3-io interface
Unit 4-l ecture3-io interface
vishal choudhary
 
Unit 4-lecte3-io interface
Unit 4-lecte3-io interfaceUnit 4-lecte3-io interface
Unit 4-lecte3-io interface
vishal choudhary
 
Unit 4 ca-input-output
Unit 4 ca-input-outputUnit 4 ca-input-output
Unit 4 ca-input-output
BBDITM LUCKNOW
 
UNIT 3 Peripheral Interfacing.pptx
UNIT 3 Peripheral Interfacing.pptxUNIT 3 Peripheral Interfacing.pptx
UNIT 3 Peripheral Interfacing.pptx
Gowrishankar C
 
Interfacingiodevice
InterfacingiodeviceInterfacingiodevice
Interfacingiodevice
Praneeth Kannegolla
 
Iosystemspre final-160922112930
Iosystemspre final-160922112930Iosystemspre final-160922112930
Iosystemspre final-160922112930
marangburu42
 
Io organization
Io organizationIo organization
Io organization
Venkata Rajitha M
 
Ch11.ppt
Ch11.pptCh11.ppt
Interfacing ics for microprocessor
Interfacing ics for microprocessorInterfacing ics for microprocessor
Interfacing ics for microprocessor
THANDAIAH PRABU
 
Peripheral devices
Peripheral devicesPeripheral devices
Peripheral devices
mahesh kumar prajapat
 

Similar to Accessing I/O Devices (20)

Io devies
Io deviesIo devies
Io devies
 
20ME702– MECHATRONICS -UNIT-3.ppt
20ME702– MECHATRONICS -UNIT-3.ppt20ME702– MECHATRONICS -UNIT-3.ppt
20ME702– MECHATRONICS -UNIT-3.ppt
 
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
Unit 3-PROGRAMMABLE PERIPHERAL INTERFACE-ME6702– MECHATRONICS
 
PROGRAMMABLE PERIPHERAL INTERFCAE.ppt
PROGRAMMABLE PERIPHERAL INTERFCAE.pptPROGRAMMABLE PERIPHERAL INTERFCAE.ppt
PROGRAMMABLE PERIPHERAL INTERFCAE.ppt
 
Unit2 p1 io organization-97-2003
Unit2 p1 io organization-97-2003Unit2 p1 io organization-97-2003
Unit2 p1 io organization-97-2003
 
PPI-MECHATRONICS
PPI-MECHATRONICSPPI-MECHATRONICS
PPI-MECHATRONICS
 
MECHATRONICS-Unit 3-PROGRAMMABLE PERIPERAL INTERFACE.ppt
MECHATRONICS-Unit 3-PROGRAMMABLE PERIPERAL INTERFACE.pptMECHATRONICS-Unit 3-PROGRAMMABLE PERIPERAL INTERFACE.ppt
MECHATRONICS-Unit 3-PROGRAMMABLE PERIPERAL INTERFACE.ppt
 
UNIT- 3.pptx
UNIT- 3.pptxUNIT- 3.pptx
UNIT- 3.pptx
 
Unit4_IO_13623_AnilRawat.ppt
Unit4_IO_13623_AnilRawat.pptUnit4_IO_13623_AnilRawat.ppt
Unit4_IO_13623_AnilRawat.ppt
 
Unit 4-lecte3-io interface
Unit 4-lecte3-io interfaceUnit 4-lecte3-io interface
Unit 4-lecte3-io interface
 
Unit 4-l ecture3-io interface
Unit 4-l ecture3-io interfaceUnit 4-l ecture3-io interface
Unit 4-l ecture3-io interface
 
Unit 4-lecte3-io interface
Unit 4-lecte3-io interfaceUnit 4-lecte3-io interface
Unit 4-lecte3-io interface
 
Unit 4 ca-input-output
Unit 4 ca-input-outputUnit 4 ca-input-output
Unit 4 ca-input-output
 
UNIT 3 Peripheral Interfacing.pptx
UNIT 3 Peripheral Interfacing.pptxUNIT 3 Peripheral Interfacing.pptx
UNIT 3 Peripheral Interfacing.pptx
 
Interfacingiodevice
InterfacingiodeviceInterfacingiodevice
Interfacingiodevice
 
Iosystemspre final-160922112930
Iosystemspre final-160922112930Iosystemspre final-160922112930
Iosystemspre final-160922112930
 
Io organization
Io organizationIo organization
Io organization
 
Ch11.ppt
Ch11.pptCh11.ppt
Ch11.ppt
 
Interfacing ics for microprocessor
Interfacing ics for microprocessorInterfacing ics for microprocessor
Interfacing ics for microprocessor
 
Peripheral devices
Peripheral devicesPeripheral devices
Peripheral devices
 

More from Slideshare

Crystal report generation in visual studio 2010
Crystal report generation in visual studio 2010Crystal report generation in visual studio 2010
Crystal report generation in visual studio 2010
Slideshare
 
Report generation
Report generationReport generation
Report generation
Slideshare
 
Trigger
TriggerTrigger
Trigger
Slideshare
 
Security in Relational model
Security in Relational modelSecurity in Relational model
Security in Relational model
Slideshare
 
Entity Relationship Model
Entity Relationship ModelEntity Relationship Model
Entity Relationship Model
Slideshare
 
OLAP
OLAPOLAP
Major issues in data mining
Major issues in data miningMajor issues in data mining
Major issues in data mining
Slideshare
 
Data preprocessing
Data preprocessingData preprocessing
Data preprocessing
Slideshare
 
What is in you
What is in youWhat is in you
What is in you
Slideshare
 
Propositional logic & inference
Propositional logic & inferencePropositional logic & inference
Propositional logic & inference
Slideshare
 
Logical reasoning 21.1.13
Logical reasoning 21.1.13Logical reasoning 21.1.13
Logical reasoning 21.1.13
Slideshare
 
Logic agent
Logic agentLogic agent
Logic agent
Slideshare
 
Statistical learning
Statistical learningStatistical learning
Statistical learning
Slideshare
 
Resolution(decision)
Resolution(decision)Resolution(decision)
Resolution(decision)
Slideshare
 
Reinforcement learning 7313
Reinforcement learning 7313Reinforcement learning 7313
Reinforcement learning 7313
Slideshare
 
Neural networks
Neural networksNeural networks
Neural networks
Slideshare
 
Instance based learning
Instance based learningInstance based learning
Instance based learning
Slideshare
 
Statistical learning
Statistical learningStatistical learning
Statistical learning
Slideshare
 
Neural networks
Neural networksNeural networks
Neural networks
Slideshare
 
Logical reasoning
Logical reasoning Logical reasoning
Logical reasoning
Slideshare
 

More from Slideshare (20)

Crystal report generation in visual studio 2010
Crystal report generation in visual studio 2010Crystal report generation in visual studio 2010
Crystal report generation in visual studio 2010
 
Report generation
Report generationReport generation
Report generation
 
Trigger
TriggerTrigger
Trigger
 
Security in Relational model
Security in Relational modelSecurity in Relational model
Security in Relational model
 
Entity Relationship Model
Entity Relationship ModelEntity Relationship Model
Entity Relationship Model
 
OLAP
OLAPOLAP
OLAP
 
Major issues in data mining
Major issues in data miningMajor issues in data mining
Major issues in data mining
 
Data preprocessing
Data preprocessingData preprocessing
Data preprocessing
 
What is in you
What is in youWhat is in you
What is in you
 
Propositional logic & inference
Propositional logic & inferencePropositional logic & inference
Propositional logic & inference
 
Logical reasoning 21.1.13
Logical reasoning 21.1.13Logical reasoning 21.1.13
Logical reasoning 21.1.13
 
Logic agent
Logic agentLogic agent
Logic agent
 
Statistical learning
Statistical learningStatistical learning
Statistical learning
 
Resolution(decision)
Resolution(decision)Resolution(decision)
Resolution(decision)
 
Reinforcement learning 7313
Reinforcement learning 7313Reinforcement learning 7313
Reinforcement learning 7313
 
Neural networks
Neural networksNeural networks
Neural networks
 
Instance based learning
Instance based learningInstance based learning
Instance based learning
 
Statistical learning
Statistical learningStatistical learning
Statistical learning
 
Neural networks
Neural networksNeural networks
Neural networks
 
Logical reasoning
Logical reasoning Logical reasoning
Logical reasoning
 

Recently uploaded

Digital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments UnitDigital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments Unit
chanes7
 
A Independência da América Espanhola LAPBOOK.pdf
A Independência da América Espanhola LAPBOOK.pdfA Independência da América Espanhola LAPBOOK.pdf
A Independência da América Espanhola LAPBOOK.pdf
Jean Carlos Nunes Paixão
 
Hindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdfHindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdf
Dr. Mulla Adam Ali
 
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama UniversityNatural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
Akanksha trivedi rama nursing college kanpur.
 
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptxC1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
mulvey2
 
How to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRMHow to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRM
Celine George
 
Digital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental DesignDigital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental Design
amberjdewit93
 
S1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptxS1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptx
tarandeep35
 
MARY JANE WILSON, A “BOA MÃE” .
MARY JANE WILSON, A “BOA MÃE”           .MARY JANE WILSON, A “BOA MÃE”           .
MARY JANE WILSON, A “BOA MÃE” .
Colégio Santa Teresinha
 
DRUGS AND ITS classification slide share
DRUGS AND ITS classification slide shareDRUGS AND ITS classification slide share
DRUGS AND ITS classification slide share
taiba qazi
 
writing about opinions about Australia the movie
writing about opinions about Australia the moviewriting about opinions about Australia the movie
writing about opinions about Australia the movie
Nicholas Montgomery
 
South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)
Academy of Science of South Africa
 
Introduction to AI for Nonprofits with Tapp Network
Introduction to AI for Nonprofits with Tapp NetworkIntroduction to AI for Nonprofits with Tapp Network
Introduction to AI for Nonprofits with Tapp Network
TechSoup
 
Smart-Money for SMC traders good time and ICT
Smart-Money for SMC traders good time and ICTSmart-Money for SMC traders good time and ICT
Smart-Money for SMC traders good time and ICT
simonomuemu
 
The basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptxThe basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptx
heathfieldcps1
 
PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.
Dr. Shivangi Singh Parihar
 
The Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collectionThe Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collection
Israel Genealogy Research Association
 
A Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in EducationA Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in Education
Peter Windle
 
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
PECB
 
How to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP ModuleHow to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP Module
Celine George
 

Recently uploaded (20)

Digital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments UnitDigital Artifact 1 - 10VCD Environments Unit
Digital Artifact 1 - 10VCD Environments Unit
 
A Independência da América Espanhola LAPBOOK.pdf
A Independência da América Espanhola LAPBOOK.pdfA Independência da América Espanhola LAPBOOK.pdf
A Independência da América Espanhola LAPBOOK.pdf
 
Hindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdfHindi varnamala | hindi alphabet PPT.pdf
Hindi varnamala | hindi alphabet PPT.pdf
 
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama UniversityNatural birth techniques - Mrs.Akanksha Trivedi Rama University
Natural birth techniques - Mrs.Akanksha Trivedi Rama University
 
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptxC1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
C1 Rubenstein AP HuG xxxxxxxxxxxxxx.pptx
 
How to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRMHow to Manage Your Lost Opportunities in Odoo 17 CRM
How to Manage Your Lost Opportunities in Odoo 17 CRM
 
Digital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental DesignDigital Artefact 1 - Tiny Home Environmental Design
Digital Artefact 1 - Tiny Home Environmental Design
 
S1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptxS1-Introduction-Biopesticides in ICM.pptx
S1-Introduction-Biopesticides in ICM.pptx
 
MARY JANE WILSON, A “BOA MÃE” .
MARY JANE WILSON, A “BOA MÃE”           .MARY JANE WILSON, A “BOA MÃE”           .
MARY JANE WILSON, A “BOA MÃE” .
 
DRUGS AND ITS classification slide share
DRUGS AND ITS classification slide shareDRUGS AND ITS classification slide share
DRUGS AND ITS classification slide share
 
writing about opinions about Australia the movie
writing about opinions about Australia the moviewriting about opinions about Australia the movie
writing about opinions about Australia the movie
 
South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)South African Journal of Science: Writing with integrity workshop (2024)
South African Journal of Science: Writing with integrity workshop (2024)
 
Introduction to AI for Nonprofits with Tapp Network
Introduction to AI for Nonprofits with Tapp NetworkIntroduction to AI for Nonprofits with Tapp Network
Introduction to AI for Nonprofits with Tapp Network
 
Smart-Money for SMC traders good time and ICT
Smart-Money for SMC traders good time and ICTSmart-Money for SMC traders good time and ICT
Smart-Money for SMC traders good time and ICT
 
The basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptxThe basics of sentences session 6pptx.pptx
The basics of sentences session 6pptx.pptx
 
PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.PCOS corelations and management through Ayurveda.
PCOS corelations and management through Ayurveda.
 
The Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collectionThe Diamonds of 2023-2024 in the IGRA collection
The Diamonds of 2023-2024 in the IGRA collection
 
A Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in EducationA Strategic Approach: GenAI in Education
A Strategic Approach: GenAI in Education
 
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
ISO/IEC 27001, ISO/IEC 42001, and GDPR: Best Practices for Implementation and...
 
How to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP ModuleHow to Add Chatter in the odoo 17 ERP Module
How to Add Chatter in the odoo 17 ERP Module
 

Accessing I/O Devices

  • 1. Accessing I/O devices V. Saranya AP/CSE Sri vidya College of Engg & Tech
  • 2. • I/O devices accessed through I/O interface. • Requirements for I/O interface: – CPU communication – Device communication – Data buffering – Control and timing – Error detection.
  • 3. CPU Communication: • Processor sends commands to the I/O system which are generally the control signals on the control bus. • Exchange of data between the processor and the I/O interface over the data bus. • Check whether the devices are ready or not.
  • 4. Data Buffering: • Data transfer rate is too high . • Data from processor and memory are sent to an I/O interface, buffered and then sent to the peripheral device at its data rate. Error Detection: • I/O interface is responsible for error detection • Used to report errors to the processor. • Types of errors: – Mechanical, electrical malfunctions, bad disk track, unintentional changes.
  • 5. I/O interface Block diagram Data Register Data Data Lines Status/Control Register Address Lines Status Address Decoder External Device Interface Control Control Lines Logic
  • 6. • Data Register: holds the data being transferred to or from the processor. • Status/Control Register: contains information relevant to the operation. • Data and status/control registers: are connected to the data bus. • Address decoder: enables the device to recognize its address.
  • 7. I/O interface for Input Device Address Lines BUS Data Lines Control lines Data & Status Address Decoder Control Circuits Registers I/O interface Input Device
  • 8. I/O interface for Output Device Address Lines BUS Data Lines Control lines Data & Status Address Decoder Control Circuits Registers I/O interface Output Device
  • 10. I/O Ports • 4 registers - status, control, data-in, data-out – Status - states whether the current command is completed, byte is available, device has an error, etc – Control - host determines to start a command or change the mode of a device – Data-in - host reads to get input – Data-out - host writes to send output • Size of registers - 1 to 4 bytes 10
  • 11. I/O devices can be interfaced to a computer system I/O in 2 ways: • Memory Mapped I/O • I/O mapped I/O
  • 12. Memory-Mapped I/O (1) Memory Address Space I/O Address Space (a) Separate I/O and memory space (b) Memory-mapped I/O (c) Hybrid 12
  • 13. Memory Mapped I/O • No need of special I/O instructions. • Memory related instructions are used for I/O related operations.
  • 14. I/O Mapped I/O Memory Address Space I/O address Space Total Address Space
  • 15. I/O Mapped I/O • If we want to reduce the memory address space, we allot a different I/O address space, apart from total memory space. Memory related instructions do not work here Processor use these mode only for I/O Read, I/O Write.
  • 16. Difference between Memory Mapped I/O & I/O mapped I/O Memory Mapped I/O I/O Mapped I/O Memory & I/O share the entire address Processor provides separate address range of processor range for memory & I/O Processor provides more address lines Less address lines for accessing I/O for accessing memory More Decoding is required Less decoding is required Memory control signals used to control I/O control signals are used to control Read & Write I/O operations Read & Write I/O operations
  • 18. • I/O operation means – A data transfer between an I/O device & memory or – Between I/O device & Processor. • If any I/O operations are completely controlled by processor, then the system is said to be using “ Programmed I/O” – Processor has to check I/O system periodically until the operation completes  “POLLING” – Microprocessor has to check if any device need service.
  • 19. Programmed I/O j & Int A? Service & routine A Address Decoder Int C? j & Service routine C Int Z? j Service routine Z
  • 20. Priority: The Routines assigns priority to the different I/O devices Port A is always checked 1st. Then Port B Then Port C Order may change by changing routine.
  • 21. • When Programmed I/O techniques is used: – Processor fetches I/O related instructions from memory and Issues I/O commands to I/O system to execute the instruction. – Memory Mapped I/O & I/O mapped I/O technique may apply. – Processor has 2 separate instructions IN & OUT for data transfer. – When the I/O instruction is encountered by the processor the I/O port is expected to be ready to response. Processor is usually programmed to test the I/O device status before initiating a data transfer.