Embedded System Design
|
|
- Helena James
- 5 years ago
- Views:
Transcription
1 Embedded System Design Lecture 4 Jaeyong Chung System-on-Chips (SoC) Laboratory Incheon National University
2 CPUs Takes inputs from input devices (sensors, keyboards, ) Process inputs and produce results Send results to output devices (display, actuators, ) Communicate with I/O devices via I/O Device Controllers I/O Device controllers provide abstraction for CPUs Chung EPC6071 2
3 I/O Device Controllers Now and then PXA32x SoC Block Diagram Chung EPC6071 3
4 mechanism I/O Device Controllers Each device controller maintains a set of device registers Command registers (write-only) Status registers (read-only) Data registers (read/write) Typical digital interface to CPU: CPU status reg data reg Chung EPC6071 4
5 I/O Controllers: 8251 UART Universal asynchronous receiver transmitter (UART) : provides serial communication functions are integrated into standard PC interface chip. Allows many communication parameters to be programmed. Chung EPC6071 5
6 Serial Communication Characters are transmitted separately: no char start bit 0 bit 1... bit n-1 stop time Serial Communication Parameters Baud (bit) rate. Number of bits per character. Parity/no parity. Even/odd parity. Length of stop bit (1, 1.5, 2 bits). Chung EPC6071 6
7 8251 CPU interface status (8 bit) CPU 8251 data (8 bit) xmit/ rcv serial port Chung EPC6071 7
8 System Bus Communication system between CPUs and device controllers including memory controllers Connects CPUs and device controllers physically by wires Consists of address lines, control lines, data lines memory System bus address data R/W CPU Chung EPC6071 8
9 Programming I/O Two types of instructions can support I/O: special-purpose I/O instructions (port-mapped IO or isolated I/O); memory-mapped load/store instructions. Let s access registers in I/O devices in the same way as memory Intel x86 provides in, out instructions. Most other CPUs use memory-mapped I/O. I/O instructions do not preclude memory-mapped I/O. Chung EPC6071 9
10 Memory-mapped I/O Memory Map Cortex-M3 Memory Map Chung EPC
11 Memory-mapped I/O Lincoln-60 (Cortex M3 based microcontroller) Memory Map Chung EPC
12 Address Decoding The process of generating chip select (CS) signals from the address bus for each device in the system We set address decoders following a memory map, or the settings of address decoders determine the memory map Designing address decoders is one of important tasks when you design embedded hardware (boards or chips) for your embedded systems Chung EPC
13 Full Address Decoding Chung EPC
14 Partial Address Decoding Chung EPC
15 Generic Bus to I/O Device Interface Device controller Chung EPC
16 An Example controller Chung EPC
17 An Example controller Chung EPC
18 Another Example Chung EPC
19 Implementing Address Decoders Discrete logic High chip-count, lacks flexibility Data decoder Programmable Read Only Memory (PROM) Lookup tables can become very large for more than 8 address lines Programmable Logic Device (PLD) Field Programmable Gate Array (FPGA) X-hyper320TKU [hybus] Chung EPC
20 Activity Finish hardware design and fill out memory map Memory Map CPU D0,,D7 A0 A1 A2 A3 D0,,D7 cs WIFI U0 U1 U2 U3 D0,,D7 cs S0 S1 UART 0x0 0x1 0x2 0x3 0x4 0x5 0x6 0x7 0x8 0x9 0xA 0xB 0xC 0xD 0xE 0xF Chung EPC
21 ARM Memory-mapped I/O Define location for device: DEV1 EQU 0x1000 Read/write code: LDR r1,#dev1 ; set up device adrs LDR r0,[r1] ; read DEV1 LDR r0,#8 ; set up value to write STR r0,[r1] ; write value to device Chung EPC
22 Peek and Poke Traditional HLL interfaces: int peek(char *location) { return *location; } void poke(char *location, char newval) { (*location) = newval; } Chung EPC
23 Busy-wait IO (Busy-wait Polling) Simplest way to program device. Use instructions to test when device is ready. current_char = mystring; while (*current_char!= \0 ) { poke(out_char,*current_char); while (peek(out_status)!= 0); current_char++; } Chung EPC
24 Simultaneous Busy/wait I/O while (TRUE) { /* read */ while (peek(in_status) == 0); achar = (char)peek(in_data); /* write */ poke(out_data,achar); poke(out_status,1); while (peek(out_status)!= 0); } Chung EPC
25 Interrupt I/O Busy/wait is very inefficient. CPU can t do other work while testing device. Hard to do simultaneous I/O. Interrupts allow a device to change the flow of control in the CPU. Causes subroutine call to handle device. Chung EPC
26 IR PC mechanism Interrupt Interface CPU intr request intr ack data/address status reg data reg Chung EPC
27 Interrupt Behavior Based on subroutine call mechanism. Interrupt forces next instruction to be a subroutine call to a predetermined location. Return address is saved to resume executing foreground program. Chung EPC
28 Interrupt Physical Interface CPU and device are connected by CPU bus. CPU and device handshake: device asserts interrupt request; CPU asserts interrupt acknowledge when it can handle the interrupt. Chung EPC
29 Example: character I/O handlers void input_handler() { achar = peek(in_data); gotchar = TRUE; poke(in_status,0); } void output_handler() { } Chung EPC
30 Priorities and Vectors Two mechanisms allow us to make interrupts more specific: Priorities determine what interrupt gets CPU first. Vectors determine what code is called for each type of interrupt. Mechanisms are orthogonal: most CPUs provide both. Chung EPC
31 Prioritized Interrupts device 1 device 2 device n interrupt acknowl edge L1 L2.. Ln CPU Chung EPC
32 Interrupt Prioritization Masking: interrupt with priority lower than current priority is not recognized until pending interrupt is complete. Non-maskable interrupt (NMI): highest-priority, never masked. Often used for power-down. Chung EPC
33 Example: Prioritized I/O :interrupts :foreground :A :B :C B C A A,B Chung EPC
34 Interrupt Vectors Allow the interrupting device to specify its handler Interrupt vector table: Interrupt vector table head handler 0 handler 1 handler 2 handler 3 Chung EPC
35 Interrupt Vector Acquisition :CPU :device receive request receive vector receive ack Chung EPC
36 Generic Interrupt Mechanism continue execution ignore N N intr? Y intr priority > current priority? Assume priority selection is handled before this point. Y ack Y bus error Y timeout? N vector? Y call table[vector] Chung EPC
37 Interrupt Sequence CPU acknowledges request. Device sends vector. CPU calls handler. Software processes request. CPU restores state to foreground program. Chung EPC
38 Sources of Interrupt Overhead Handler execution time. Interrupt mechanism overhead. Register save/restore. Pipeline-related penalties. Cache-related penalties. Chung EPC
39 ARM Interrupts ARM7 supports two types of interrupts: Fast interrupt requests (FIQs). Interrupt requests (IRQs). Interrupt table starts at location 0. Chung EPC
40 ARM Interrupt Procedure CPU actions: Save PC. Copy CPSR to SPSR. Force bits in CPSR to record interrupt. Force PC to vector. Handler responsibilities: Restore proper PC. Restore CPSR from SPSR. Clear interrupt disable flags. Chung EPC
41 ARM Interrupt Latency Worst-case latency to respond to interrupt is 27 cycles: Two cycles to synchronize external request. Up to 20 cycles to complete current instruction. Three cycles for data abort. Two cycles to enter interrupt handling state. Chung EPC
42 Software Interrupt Caused either by an exceptional condition in the processor itself, or a special instruction in the instruction set which causes an interrupt when it is executed (ex, SWI in ARM) The former is often called a trap or exception and is used for errors or events occurring during program execution that are exceptional enough that they cannot be handled within the program itself. For example, if the processor's arithmetic logic unit is commanded to divide a number by zero, this impossible demand will cause a divide-by-zero exception Chung EPC
43 I/O in Systems with OS When OS is installed, we cannot perform I/O this way Why? I/O is a resource and need to be shared by processes carefully OS will supervise OS Kernel I/O Device Controller Device Driver. inb(mydev); outb(x, MYDEV);. System calls Process In Linux, for peek(), use inb() for poke(), use outb() Chung EPC
44 System Call A request for service that a program makes of the kernel. The service is generally something that only the kernel has the privilege to do, such as doing I/O. Executed via software interrupts Low level I/O is performed by making system calls. In Linux, all low-level I/O is done by reading and writing file handles System calls in Linux: sys_open: open a file sys_close: close a file sys_read: read from a file sys_write: write to a file sys_lseek: seek and many more Chung EPC
45 System Call Programmers don't call system calls directly Call wrapper functions corresponding to system calls in the GNU C Library #include <unistd.h> #include <sys/syscall.h> #include <errno.h> int rc;... rc = syscall(sys_chmod, "/etc/passwd", 0444); if (rc == -1) fprintf(stderr, "chmod failed, errno = %d\n", errno); #include <sys/types.h> #include <sys/stat.h> #include <errno.h> int rc;... rc = chmod("/etc/passwd", 0444); if (rc == -1) fprintf(stderr, "chmod failed, errno = %d\n", errno); Direct calls Using wrappers Chung EPC
46 System Call Software intrrupt x86 Chung EPC
47 Supervisor Mode SWI instruction put the ARM CPU in supervisor mode OS runs in supervisor mode, and applications run in user mode Supervisor mode has privileges that user modes do not Chung EPC
48 CPUs Cache. a memory that transparently stores data so that future requests for that data can be served faster Cache Hit/miss Locality Multiple levels of caches (L1, L2, L3) Direct-mapped and set-associative Replacement policies (LRU, LFU, ) Scratch pad memory and etc Cache is not covered by this course Memory management unit (next class) Chung EPC
49 Pipelining Several instructions are executed simultaneously at different stages of completion. pipeline bubbles Latency, Throughput Fetch, decode, execute Stalls, etc Pipelining is not covered by this course Chung EPC
CPUs. Input and output. Supervisor mode, exceptions, traps. Co-processors. Computers as Components 4e 2016 Marilyn Wolf
CPUs Input and output. Supervisor mode, exceptions, traps. Co-processors. I/O devices Usually includes some non-digital component. Typical digital interface to CPU: CPU status reg data reg mechanism Application:
More informationInput/Output. Jin-Soo Kim Computer Systems Laboratory Sungkyunkwan University
Input/Output Jin-Soo Kim (jinsookim@skku.edu) Computer Systems Laboratory Sungkyunkwan University http://csl.skku.edu mechanism I/O Devices Usually includes some non-digital component Typical digital interface
More informationThe Embedded Computing Platform
The Embedded Computing Platform I/O Interfaces and Service José Costa Software for Embedded Systems Department of Computer Science and Engineering (DEI) Instituto Superior Técnico Adapted from the overheads
More informationRecap from last class
Recap from last class Taxonomy of microprocessor architecture Von Neumann Memory for both data and instructions, single bus Easier to write Harvard Separate memories for data and instructions, two buses
More informationInput/Output Programming
Input/Output Programming Chapter 3: Section 3.1, 3.2 Input and output (I/O) programming Communicating with I/O devices Busy-wait I/O Interrupt-driven I/O I/O devices Devices may include digital and non-digital
More informationLecture 10 Exceptions and Interrupts. How are exceptions generated?
Lecture 10 Exceptions and Interrupts The ARM processor can work in one of many operating modes. So far we have only considered user mode, which is the "normal" mode of operation. The processor can also
More informationEmbedded System Design
Embedded System Design Lecture 5 Jaeyong Chung System-on-Chips (SoC) Laboratory Incheon National University What We Have Covered So Far Instruction Set Architecture How CPU interacts with I/O controllers
More informationHercules ARM Cortex -R4 System Architecture. Processor Overview
Hercules ARM Cortex -R4 System Architecture Processor Overview What is Hercules? TI s 32-bit ARM Cortex -R4/R5 MCU family for Industrial, Automotive, and Transportation Safety Hardware Safety Features
More informationEEL 4744C: Microprocessor Applications. Lecture 7. Part 1. Interrupt. Dr. Tao Li 1
EEL 4744C: Microprocessor Applications Lecture 7 Part 1 Interrupt Dr. Tao Li 1 M&M: Chapter 8 Or Reading Assignment Software and Hardware Engineering (new version): Chapter 12 Dr. Tao Li 2 Interrupt An
More informationReading Assignment. Interrupt. Interrupt. Interrupt. EEL 4744C: Microprocessor Applications. Lecture 7. Part 1
Reading Assignment EEL 4744C: Microprocessor Applications Lecture 7 M&M: Chapter 8 Or Software and Hardware Engineering (new version): Chapter 12 Part 1 Interrupt Dr. Tao Li 1 Dr. Tao Li 2 Interrupt An
More information18-349: Introduction to Embedded Real-Time Systems
18-349: Introduction to Embedded Real-Time Systems Embedded Real-Time Systems Lecture 6: Timers and Interrupts Anthony Rowe Electrical and Computer Engineering Carnegie Mellon University Embedded Real-Time
More informationOperating System: Chap13 I/O Systems. National Tsing-Hua University 2016, Fall Semester
Operating System: Chap13 I/O Systems National Tsing-Hua University 2016, Fall Semester Outline Overview I/O Hardware I/O Methods Kernel I/O Subsystem Performance Application Interface Operating System
More informationINPUT/OUTPUT ORGANIZATION
INPUT/OUTPUT ORGANIZATION Accessing I/O Devices I/O interface Input/output mechanism Memory-mapped I/O Programmed I/O Interrupts Direct Memory Access Buses Synchronous Bus Asynchronous Bus I/O in CO and
More informationINPUT/OUTPUT ORGANIZATION
INPUT/OUTPUT ORGANIZATION Accessing I/O Devices I/O interface Input/output mechanism Memory-mapped I/O Programmed I/O Interrupts Direct Memory Access Buses Synchronous Bus Asynchronous Bus I/O in CO and
More informationINPUT/OUTPUT ORGANIZATION
INPUT/OUTPUT ORGANIZATION Accessing I/O Devices I/O interface Input/output mechanism Memory-mapped I/O Programmed I/O Interrupts Direct Memory Access Buses Synchronous Bus Asynchronous Bus I/O in CO and
More informationThe ARM processor. Morgan Kaufman ed Overheads for Computers as Components
The ARM processor Born in Acorn on 1983, after the success achieved by the BBC Micro released on 1982. Acorn is a really smaller company than most of the USA competitors, therefore it initially develops
More informationI/O - input/output. system components: CPU, memory, and bus -- now add I/O controllers and peripheral devices. CPU Cache
I/O - input/output system components: CPU, memory, and bus -- now add I/O controllers and peripheral devices CPU Cache CPU must perform all transfers to/from simple controller, e.g., CPU reads byte from
More informationECE 1160/2160 Embedded Systems Design. Midterm Review. Wei Gao. ECE 1160/2160 Embedded Systems Design
ECE 1160/2160 Embedded Systems Design Midterm Review Wei Gao ECE 1160/2160 Embedded Systems Design 1 Midterm Exam When: next Monday (10/16) 4:30-5:45pm Where: Benedum G26 15% of your final grade What about:
More informationProcessor Structure and Function
WEEK 4 + Chapter 14 Processor Structure and Function + Processor Organization Processor Requirements: Fetch instruction The processor reads an instruction from memory (register, cache, main memory) Interpret
More informationInterrupt-Driven Input/Output
Interrupt-Driven Input/Output Textbook: Chapter 11 (Interrupts) ARM Cortex-M4 User Guide (Interrupts, exceptions, NVIC) Sections 2.1.4, 2.3 Exceptions and interrupts Section 4.2 Nested Vectored Interrupt
More informationPC Interrupt Structure and 8259 DMA Controllers
ELEC 379 : DESIGN OF DIGITAL AND MICROCOMPUTER SYSTEMS 1998/99 WINTER SESSION, TERM 2 PC Interrupt Structure and 8259 DMA Controllers This lecture covers the use of interrupts and the vectored interrupt
More informationInput / Output. School of Computer Science G51CSA
Input / Output 1 Overview J I/O module is the third key element of a computer system. (others are CPU and Memory) J All computer systems must have efficient means to receive input and deliver output J
More informationOctober, Saeid Nooshabadi. Overview COMP 3221
Overview COMP 3221 Microprocessors and Embedded Systems Lectures 28: Exceptions & Interrupts - II http://www.cse.unsw.edu.au/~cs3221 Instruction Set Support for Exceptions Role of O/S in Handling Exceptions
More information8086 Interrupts and Interrupt Responses:
UNIT-III PART -A INTERRUPTS AND PROGRAMMABLE INTERRUPT CONTROLLERS Contents at a glance: 8086 Interrupts and Interrupt Responses Introduction to DOS and BIOS interrupts 8259A Priority Interrupt Controller
More informationInterrupt: (verb) the interruption of a CPU s normal processing...using a mechanism provided for this purpose.
15-1 Interrupts 15-1 Interrupt: (verb) the interruption of a CPU s normal processing......using a mechanism provided for this purpose. Interrupt: (noun)......(1)aneventthatcausesaninterrupt......(2) the
More informationWilliam Stallings Computer Organization and Architecture 10 th Edition Pearson Education, Inc., Hoboken, NJ. All rights reserved.
+ William Stallings Computer Organization and Architecture 10 th Edition 2016 Pearson Education, Inc., Hoboken, NJ. All rights reserved. 2 + Chapter 14 Processor Structure and Function + Processor Organization
More informationGrundlagen Microcontroller Interrupts. Günther Gridling Bettina Weiss
Grundlagen Microcontroller Interrupts Günther Gridling Bettina Weiss 1 Interrupts Lecture Overview Definition Sources ISR Priorities & Nesting 2 Definition Interrupt: reaction to (asynchronous) external
More informationCISC RISC. Compiler. Compiler. Processor. Processor
Q1. Explain briefly the RISC design philosophy. Answer: RISC is a design philosophy aimed at delivering simple but powerful instructions that execute within a single cycle at a high clock speed. The RISC
More informationECEN 449 Microprocessor System Design. Hardware-Software Communication. Texas A&M University
ECEN 449 Microprocessor System Design Hardware-Software Communication 1 Objectives of this Lecture Unit Learn basics of Hardware-Software communication Memory Mapped I/O Polling/Interrupts 2 Motivation
More informationNotes Interrupts and Exceptions. The book uses exception as a general term for all interrupts...
08 1 Interrupts and Exceptions 08 1 Notes The book uses exception as a general term for all interrupts...... in these notes interrupt is used as the general term...... and a narrower definition is used
More informationCS 550 Operating Systems Spring System Call
CS 550 Operating Systems Spring 2018 System Call 1 Recap: The need for protection When running user processes, the OS needs to protect itself and other system components For reliability: buggy programs
More informationCMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 09, SPRING 2013
CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 09, SPRING 2013 TOPICS TODAY I/O Architectures Interrupts Exceptions FETCH EXECUTE CYCLE 1.7 The von Neumann Model This is a general
More informationMicroprocessors & Interfacing
Lecture Overview Microprocessors & Interfacing Interrupts (I) Lecturer : Dr. Annie Guo Introduction to Interrupts Interrupt system specifications Multiple sources of interrupts Interrupt priorities Interrupts
More informationInterrupts (I) Lecturer: Sri Notes by Annie Guo. Week8 1
Interrupts (I) Lecturer: Sri Notes by Annie Guo Week8 1 Lecture overview Introduction to Interrupts Interrupt system specifications Multiple Sources of Interrupts Interrupt Priorities Interrupts in AVR
More informationThese three counters can be programmed for either binary or BCD count.
S5 KTU 1 PROGRAMMABLE TIMER 8254/8253 The Intel 8253 and 8254 are Programmable Interval Timers (PTIs) designed for microprocessors to perform timing and counting functions using three 16-bit registers.
More informationWilliam Stallings Computer Organization and Architecture 8 th Edition. Chapter 12 Processor Structure and Function
William Stallings Computer Organization and Architecture 8 th Edition Chapter 12 Processor Structure and Function CPU Structure CPU must: Fetch instructions Interpret instructions Fetch data Process data
More informationGeneral-Purpose Input/Output. Textbook: Chapter 14 General-Purpose I/O programming
General-Purpose Input/Output Textbook: Chapter 14 General-Purpose I/O programming 1 I/O devices May include digital and/or non-digital components. Typical digital interface to CPU is via addressable registers:
More informationEmbedded system functionality aspects
INTERFACING Introduction Embedded system functionality aspects Processing Transformation of data Implemented using processors Storage Retention of data Implemented using memory Communication Transfer of
More informationEmbedded Computing Platform. Architecture and Instruction Set
Embedded Computing Platform Microprocessor: Architecture and Instruction Set Ingo Sander ingo@kth.se Microprocessor A central part of the embedded platform A platform is the basic hardware and software
More informationReplacement Policy: Which block to replace from the set?
Replacement Policy: Which block to replace from the set? Direct mapped: no choice Associative: evict least recently used (LRU) difficult/costly with increasing associativity Alternative: random replacement
More informationI/O Handling. ECE 650 Systems Programming & Engineering Duke University, Spring Based on Operating Systems Concepts, Silberschatz Chapter 13
I/O Handling ECE 650 Systems Programming & Engineering Duke University, Spring 2018 Based on Operating Systems Concepts, Silberschatz Chapter 13 Input/Output (I/O) Typical application flow consists of
More informationDesign and Implementation Interrupt Mechanism
Design and Implementation Interrupt Mechanism 1 Module Overview Study processor interruption; Design and implement of an interrupt mechanism which responds to interrupts from timer and UART; Program interrupt
More informationArchitecture and OS. To do. q Architecture impact on OS q OS impact on architecture q Next time: OS components and structure
Architecture and OS To do q Architecture impact on OS q OS impact on architecture q Next time: OS components and structure Computer architecture and OS OS is intimately tied to the hardware it runs on
More information18-349: Embedded Real-Time Systems Lecture 2: ARM Architecture
18-349: Embedded Real-Time Systems Lecture 2: ARM Architecture Anthony Rowe Electrical and Computer Engineering Carnegie Mellon University Basic Computer Architecture Embedded Real-Time Systems 2 Memory
More informationCSE 410. Operating Systems
CSE 410 Operating Systems Handout: syllabus 1 Today s Lecture Course organization Computing environment Overview of course topics 2 Course Organization Course website http://www.cse.msu.edu/~cse410/ Syllabus
More informationCOEN-4720 Embedded Systems Design Lecture 4 Interrupts (Part 1) Cristinel Ababei Dept. of Electrical and Computer Engineering Marquette University
COEN-4720 Embedded Systems Design Lecture 4 Interrupts (Part 1) Cristinel Ababei Dept. of Electrical and Computer Engineering Marquette University Outline Introduction NVIC and Interrupt Control Interrupt
More informationSystems Programming and Computer Architecture ( ) Timothy Roscoe
Systems Group Department of Computer Science ETH Zürich Systems Programming and Computer Architecture (252-0061-00) Timothy Roscoe Herbstsemester 2016 AS 2016 Exceptions 1 17: Exceptions Computer Architecture
More informationLast class: Today: Course administration OS definition, some history. Background on Computer Architecture
1 Last class: Course administration OS definition, some history Today: Background on Computer Architecture 2 Canonical System Hardware CPU: Processor to perform computations Memory: Programs and data I/O
More informationSystems Architecture II
Systems Architecture II Topics Interfacing I/O Devices to Memory, Processor, and Operating System * Memory-mapped IO and Interrupts in SPIM** *This lecture was derived from material in the text (Chapter
More informationEmbedded Systems: Hardware Components (part II) Todor Stefanov
Embedded Systems: Hardware Components (part II) Todor Stefanov Leiden Embedded Research Center, Leiden Institute of Advanced Computer Science Leiden University, The Netherlands Outline Generic Embedded
More informationLecture-51 INTEL 8259A Programmable Interrupt Controller
Lecture-51 INTEL 8259A Programmable Interrupt Controller The 8259A is a programmable interrupt controller designed to work with Intel microprocessor 8080 A, 8085, 8086, 8088. The 8259 A interrupt controller
More informationInterrupt/Timer/DMA 1
Interrupt/Timer/DMA 1 Exception An exception is any condition that needs to halt normal execution of the instructions Examples - Reset - HWI - SWI 2 Interrupt Hardware interrupt Software interrupt Trap
More informationby I.-C. Lin, Dept. CS, NCTU. Textbook: Operating System Concepts 8ed CHAPTER 13: I/O SYSTEMS
by I.-C. Lin, Dept. CS, NCTU. Textbook: Operating System Concepts 8ed CHAPTER 13: I/O SYSTEMS Chapter 13: I/O Systems I/O Hardware Application I/O Interface Kernel I/O Subsystem Transforming I/O Requests
More informationARM processor organization
ARM processor organization P. Bakowski bako@ieee.org ARM register bank The register bank,, which stores the processor state. r00 r01 r14 r15 P. Bakowski 2 ARM register bank It has two read ports and one
More informationintroduction to interrupts
introduction to interrupts Geoffrey Brown Chris Haynes Bryce Himebaugh C335 Fall 2013 Overview Why interrupts? Basic interrupt processing Sources of interrupts Handling interrupts Issues with interrupt
More informationAnne Bracy CS 3410 Computer Science Cornell University
Anne Bracy CS 3410 Computer Science Cornell University The slides were originally created by Deniz ALTINBUKEN. P&H Chapter 4.9, pages 445 452, appendix A.7 Manages all of the software and hardware on the
More informationDigital Input and Output
Digital Input and Output Topics: Parallel Digital I/O Simple Input (example) Parallel I/O I/O Scheduling Techniques Programmed Interrupt Driven Direct Memory Access Serial I/O Asynchronous Synchronous
More informationINTERRUPTS in microprocessor systems
INTERRUPTS in microprocessor systems Microcontroller Power Supply clock fx (Central Proccesor Unit) CPU Reset Hardware Interrupts system IRQ Internal address bus Internal data bus Internal control bus
More informationLecture 25: Interrupt Handling and Multi-Data Processing. Spring 2018 Jason Tang
Lecture 25: Interrupt Handling and Multi-Data Processing Spring 2018 Jason Tang 1 Topics Interrupt handling Vector processing Multi-data processing 2 I/O Communication Software needs to know when: I/O
More informationUNIT- 5. Chapter 12 Processor Structure and Function
UNIT- 5 Chapter 12 Processor Structure and Function CPU Structure CPU must: Fetch instructions Interpret instructions Fetch data Process data Write data CPU With Systems Bus CPU Internal Structure Registers
More information6 Direct Memory Access (DMA)
1 License: http://creativecommons.org/licenses/by-nc-nd/3.0/ 6 Direct Access (DMA) DMA technique is used to transfer large volumes of data between I/O interfaces and the memory. Example: Disk drive controllers,
More informationSystems Architecture The ARM Processor
Systems Architecture The ARM Processor The ARM Processor p. 1/14 The ARM Processor ARM: Advanced RISC Machine First developed in 1983 by Acorn Computers ARM Ltd was formed in 1988 to continue development
More informationFINALTERM EXAMINATION Fall 2008 CS501- Advance Computer Architecture (Session - 1) Marks: 75
FINALTERM EXAMINATION Fall 2008 CS501- Advance Computer Architecture (Session - 1) Marks: 75 Question No: 1 ( Marks: 1 ) - Please choose one Which one of the following is the memory organization of SRC
More informationComputer Organization (Input-output)
Computer Organization (Input-output) KR Chowdhary Professor & Head Email: kr.chowdhary@gmail.com webpage: krchowdhary.com Department of Computer Science and Engineering MBM Engineering College, Jodhpur
More informationChapter 5 Input/Output Organization. Jin-Fu Li Department of Electrical Engineering National Central University Jungli, Taiwan
Chapter 5 Input/Output Organization Jin-Fu Li Department of Electrical Engineering National Central University Jungli, Taiwan Outline Accessing I/O Devices Interrupts Direct Memory Access Buses Interface
More informationModule 3. Embedded Systems I/O. Version 2 EE IIT, Kharagpur 1
Module 3 Embedded Systems I/O Version 2 EE IIT, Kharagpur 1 Lesson 15 Interrupts Version 2 EE IIT, Kharagpur 2 Instructional Objectives After going through this lesson the student would learn Interrupts
More informationOS Structure. Hardware protection & privilege levels Control transfer to and from the operating system
OS Structure Topics Hardware protection & privilege levels Control transfer to and from the operating system Learning Objectives: Explain what hardware protection boundaries are. Explain how applications
More informationCS 550 Operating Systems Spring Interrupt
CS 550 Operating Systems Spring 2019 Interrupt 1 Revisit -- Process MAX Stack Function Call Arguments, Return Address, Return Values Kernel data segment Kernel text segment Stack fork() exec() Heap Data
More informationReview: Hardware user/kernel boundary
Review: Hardware user/kernel boundary applic. applic. applic. user lib lib lib kernel syscall pg fault syscall FS VM sockets disk disk NIC context switch TCP retransmits,... device interrupts Processor
More informationSamsung S3C4510B. Hsung-Pin Chang Department of Computer Science National Chung Hsing University
Samsung S3C4510B Hsung-Pin Chang Department of Computer Science National Chung Hsing University S3C4510B A 16/32-bit RISC microcontroller is a cost-effective, highperformance microcontroller 16/32-bit
More informationInterconnecting Components
Interconnecting Components Need interconnections between CPU, memory, controllers Bus: shared communication channel Parallel set of wires for data and synchronization of data transfer Can become a bottleneck
More informationEE 457 Unit 8. Exceptions What Happens When Things Go Wrong
1 EE 457 Unit 8 Exceptions What Happens When Things Go Wrong 2 What are Exceptions? Exceptions are rare events triggered by the hardware and forcing the processor to execute a software handler HW Interrupts
More informationThe Embedded computing platform. Four-cycle handshake. Bus protocol. Typical bus signals. Four-cycle example. CPU bus.
The Embedded computing platform CPU bus. Memory. I/O devices. CPU bus Connects CPU to: memory; devices. Protocol controls communication between entities. Bus protocol Determines who gets to use the bus
More informationOperating systems and concurrency B02
Operating systems and concurrency B02 David Kendall Northumbria University David Kendall (Northumbria University) Operating systems and concurrency B02 1 / 13 Device handling - ARM7 bus structure David
More informationHardware platform architecture
Interfacing 1 Hardware platform architecture Fall 2005 2 Bus Means for transferring bits wired or wireless Bus Connectivity scheme (serial, etc.) Protocol Ports Single function (data bus) or complex protocol
More informationComputer and Hardware Architecture I. Benny Thörnberg Associate Professor in Electronics
Computer and Hardware Architecture I Benny Thörnberg Associate Professor in Electronics Hardware architecture Computer architecture The functionality of a modern computer is so complex that no human can
More informationInterrupts Peter Rounce
Interrupts Peter Rounce P.Rounce@cs.ucl.ac.uk 22/11/2011 11-GC03 Interrupts 1 INTERRUPTS An interrupt is a signal to the CPU from hardware external to the CPU that indicates than some event has occured,
More informationPOLITECNICO DI MILANO. Exception handling. Donatella Sciuto:
POLITECNICO DI MILANO Exception handling Donatella Sciuto: donatella.sciuto@polimi.it Interrupts: altering the normal flow of control I i-1 HI 1 program I i HI 2 interrupt handler I i+1 HI n An external
More informationIntroduction to Operating. Chapter Chapter
Introduction to Operating Systems Chapter 1 1.3 Chapter 1.5 1.9 Learning Outcomes High-level understand what is an operating system and the role it plays A high-level understanding of the structure of
More informationLast Time. Think carefully about whether you use a heap Look carefully for stack overflow Especially when you have multiple threads
Last Time Cost of nearly full resources RAM is limited Think carefully about whether you use a heap Look carefully for stack overflow Especially when you have multiple threads Embedded C Extensions for
More informationInterrupts in Zynq Systems
Interrupts in Zynq Systems C r i s t i a n S i s t e r n a U n i v e r s i d a d N a c i o n a l d e S a n J u a n A r g e n t i n a Exception / Interrupt Special condition that requires a processor's
More information3.1 Introduction. Computers perform operations concurrently
PROCESS CONCEPTS 1 3.1 Introduction Computers perform operations concurrently For example, compiling a program, sending a file to a printer, rendering a Web page, playing music and receiving e-mail Processes
More informationVE7104/INTRODUCTION TO EMBEDDED CONTROLLERS UNIT III ARM BASED MICROCONTROLLERS
VE7104/INTRODUCTION TO EMBEDDED CONTROLLERS UNIT III ARM BASED MICROCONTROLLERS Introduction to 32 bit Processors, ARM Architecture, ARM cortex M3, 32 bit ARM Instruction set, Thumb Instruction set, Exception
More informationWilliam Stallings Computer Organization and Architecture. Chapter 11 CPU Structure and Function
William Stallings Computer Organization and Architecture Chapter 11 CPU Structure and Function CPU Structure CPU must: Fetch instructions Interpret instructions Fetch data Process data Write data Registers
More informationComputer System Overview
Computer System Overview Operating Systems 2005/S2 1 What are the objectives of an Operating System? 2 What are the objectives of an Operating System? convenience & abstraction the OS should facilitate
More informationINPUT-OUTPUT ORGANIZATION
1 INPUT-OUTPUT ORGANIZATION Peripheral Devices Input-Output Interface Asynchronous Data Transfer Modes of Transfer Priority Interrupt Direct Memory Access Input-Output Processor Serial Communication 2
More informationECE251: Thursday September 27
ECE251: Thursday September 27 Exceptions: Interrupts and Resets Chapter in text and Lab #6. READ ALL this material! This will NOT be on the mid-term exam. Lab Practical Exam #1 Homework # due today at
More informationThe control of I/O devices is a major concern for OS designers
Lecture Overview I/O devices I/O hardware Interrupts Direct memory access Device dimensions Device drivers Kernel I/O subsystem Operating Systems - June 26, 2001 I/O Device Issues The control of I/O devices
More informationProcesses, Execution and State. Process Operations: fork. Variations on Process Creation. Windows Process Creation.
Processes, Execution, and State 3C. Process Operations 3D. Implementing Processes 3E. Asynchronous Exceptions and Events 3U. User-Mode Programs and Exceptions 3F. Execution State Model Process Operations:
More informationArchitectural Support for Operating Systems. Jin-Soo Kim Computer Systems Laboratory Sungkyunkwan University
Architectural Support for Operating Systems Jin-Soo Kim (jinsookim@skku.edu) Computer Systems Laboratory Sungkyunkwan University http://csl.skku.edu Today s Topics Basic structure of OS Basic computer
More informationDevice I/O Programming
Overview Device I/O Programming Don Porter CSE 506 Many artifacts of hardware evolution Configurability isn t free Bake-in some reasonable assumptions Initially reasonable assumptions get stale Find ways
More informationWhat are Exceptions? EE 457 Unit 8. Exception Processing. Exception Examples 1. Exceptions What Happens When Things Go Wrong
8. 8.2 What are Exceptions? EE 457 Unit 8 Exceptions What Happens When Things Go Wrong Exceptions are rare events triggered by the hardware and forcing the processor to execute a software handler Similar
More informationIntroduction to Operating Systems. Chapter Chapter
Introduction to Operating Systems Chapter 1 1.3 Chapter 1.5 1.9 Learning Outcomes High-level understand what is an operating system and the role it plays A high-level understanding of the structure of
More informationComputer System Overview OPERATING SYSTEM TOP-LEVEL COMPONENTS. Simplified view: Operating Systems. Slide 1. Slide /S2. Slide 2.
BASIC ELEMENTS Simplified view: Processor Slide 1 Computer System Overview Operating Systems Slide 3 Main Memory referred to as real memory or primary memory volatile modules 2004/S2 secondary memory devices
More informationInterrupts (Exceptions) (From LM3S1968) Gary J. Minden August 29, 2016
Interrupts (Exceptions) (From LM3S1968) Gary J. Minden August 29, 2016 1 Interrupts Motivation Implementation Material from Stellaris LM3S1968 Micro-controller Datasheet Sections 2.5 and 2.6 2 Motivation
More informationCS152 Computer Architecture and Engineering Lecture 20: Busses and OS s Responsibilities. Recap: IO Benchmarks and I/O Devices
CS152 Computer Architecture and Engineering Lecture 20: ses and OS s Responsibilities April 7, 1995 Dave Patterson (patterson@cs) and Shing Kong (shing.kong@eng.sun.com) Slides available on http://http.cs.berkeley.edu/~patterson
More informationARM Accredited Engineer Certification
ARM Accredited Engineer Certification Mock Test with Answers Question 1 Which of the following processors would be best suited to a system requiring hard real-time responses, such as a hard drive controller?
More informationBasics of Microprocessor
Unit 1 Basics of Microprocessor 1. Microprocessor Microprocessor is a multipurpose programmable integrated device that has computing and decision making capability. This semiconductor IC is manufactured
More informationARM ARCHITECTURE. Contents at a glance:
UNIT-III ARM ARCHITECTURE Contents at a glance: RISC Design Philosophy ARM Design Philosophy Registers Current Program Status Register(CPSR) Instruction Pipeline Interrupts and Vector Table Architecture
More informationIntroduction to Operating Systems. Chapter Chapter
Introduction to Operating Systems Chapter 1 1.3 Chapter 1.5 1.9 Learning Outcomes High-level understand what is an operating system and the role it plays A high-level understanding of the structure of
More information