Testing Communication Systems  When point-to-point communication between two DTEs is not functioning, which DTE is at fault? Or which DTE is correctly.

Slides:



Advertisements
Similar presentations
PLC Selection, Components, and Communication
Advertisements

System Integration and Performance
Slide 5-1 Copyright © 2004 Pearson Education, Inc. Operating Systems: A Modern Perspective, Chapter 5 5 Device Management.
INPUT-OUTPUT ORGANIZATION
Serial Communications Interface (SCI) Michael LennardZachary PetersBao Nguyen.
1 Homework Reading (linked from my web page) –S and S Extracts –National Semiconductor UART Data Sheet Machine Projects –mp2 due at start of class 12 Labs.
The 8051 Microcontroller Chapter 5 SERIAL PORT OPERATION.
Chapter 10 Input/Output Organization. Connections between a CPU and an I/O device Types of bus (Figure 10.1) –Address bus –Data bus –Control bus.
1/1/ / faculty of Electrical Engineering eindhoven university of technology Architectures of Digital Information Systems Part 1: Interrupts and DMA dr.ir.
Interfacing The Serial/RS-232 Port Hardware Serial Port Registers Programming.
CS4315A. Berrached:CMS:UHD1 Operating Systems and Computer Organization Chapter 4.
CS-334: Computer Architecture
Hierarchy of I/O Control Devices
Outline  Examine some of the H/W supplied with a typical PC and consider the software required to control it.  Introduce Commkit, a software tool that.
Asynchronous Communication Hardware  Data within a DTE is usually stored and moved in a parallel fashion.  Data sent across the channel is generally.
Implementing interrupt driven IO. Why use interrupt driven IO? Positive points –Allows asynchronous operation of IO events –Good use of resources –Leads.
6-1 I/O Methods I/O – Transfer of data between memory of the system and the I/O device Most devices operate asynchronously from the CPU Most methods involve.
PC Modem Control The 8250 UART supplied with the PC supports a limited number of RS-232-C modem functions: The UART can be programmed to interrupt the.
7-1 Digital Serial Input/Output Two basic approaches  Synchronous shared common clock signal all devices synchronised with the shared clock signal data.
1 The 9-Pin Connector Pin abbreviations (numbers in parentheses are the 25D pin numbers): 1. CD (8) 2. RD (Rx) (3) 3. TD (Tx) (2) 4. DTR (20) 5. SG (Ground)
Unit-5 CO-MPI autonomous
ECE 353 Introduction to Microprocessor Systems Michael G. Morrow, P.E. Week 13.
Hardware Interface Design Patterns Ahmet Selman Bozkır – Hacettepe Univ.
INPUT-OUTPUT ORGANIZATION
Khaled A. Al-Utaibi  8086 Pinout & Pin Functions  Minimum & Maximum Mode Operations  Microcomputer System Design  Minimum Mode.
University of Tehran 1 Interface Design Serial Communications Omid Fatemi.
The University of New Hampshire InterOperability Laboratory Serial ATA (SATA) Protocol Chapter 10 – Transport Layer.
ECE 265 – LECTURE 12 The Hardware Interface 8/22/ ECE265.
Embedded Systems Principle of Debugger. Reference Materials kl.de/avr_projects/arm_projects/#winarmhttp://
Interrupts. 2 Definition: An electrical signal sent to the CPU (at any time) to alert it to the occurrence of some event that needs its attention Purpose:
Serial Port I/O Serial port sends and receives data one bit at a time. Serial communication devices are divided into: Data Communications Equipment (DCE),
COMP201 Computer Systems Exceptions and Interrupts.
COMPUTER ORGANIZATIONS CSNB123 NSMS2013 Ver.1Systems and Networking1.
Lecture 7 Universal Asynchronous Receiver/Transmitter (UART) NCHUEE 720A Lab Prof. Jichiang Tsai.
Interrupts and DMA CSCI The Role of the Operating System in Performing I/O Two main jobs of a computer are: –Processing –Performing I/O manage and.
Universal Synchronous/Asynchronous Receiver/Transmitter (USART)
Firmware based Array Sorter and Matlab testing suite Final Presentation August 2011 Elad Barzilay & Uri Natanzon Supervisor: Moshe Porian.
Operating Systems ECE344 Ashvin Goel ECE University of Toronto Overview of Hardware.
I/O Example: Disk Drives To access data: — seek: position head over the proper track (8 to 20 ms. avg.) — rotational latency: wait for desired sector (.5.
Universal Asynchronous Receiver/Transmitter (UART)
ECE 353 Introduction to Microprocessor Systems Michael Schulte Week 13.
Microprocessors 2 lesson Subjects lesson 7 Planning Interrupts Serial communication /USART Questions.
Serial Communications
Advanced Microprocessor1 I/O Interface Programmable Interval Timer: 8254 Three independent 16-bit programmable counters (timers). Each capable in counting.
 8251A is a USART (Universal Synchronous Asynchronous Receiver Transmitter) for serial data communication.  Programmable peripheral designed for synchronous.
NS Training Hardware. Serial Controller - UART.
Universal Asynchronous Receiver/Transmitter (UART)
ATtiny23131 A SEMINAR ON AVR MICROCONTROLLER ATtiny2313.
RX Serial Peripheral Interface (RSPI)
Chapter 13 – I/O Systems (Pgs ). Devices  Two conflicting properties A. Growing uniformity in interfaces (both h/w and s/w): e.g., USB, TWAIN.
Serial Communications Interface Module Slide #1 of 19 MC68HC908GP20 Training PURPOSE -To explain how to configure and use the Serial Communications Interface.
NS Training Hardware Traffic Flow Note: Traffic direction in the 1284 is classified as either forward or reverse. The forward direction is.
© 2009, Renesas Technology America, Inc., All Rights Reserved 1 Course Introduction  Purpose:  This course provides an overview of the serial communication.
Interrupts and Exception Handling. Execution We are quite aware of the Fetch, Execute process of the control unit of the CPU –Fetch and instruction as.
Introduction to Exceptions 1 Introduction to Exceptions ARM Advanced RISC Machines.
8251 USART.
Transmitter Interrupts Review of Receiver Interrupts How to Handle Transmitter Interrupts? Critical Regions Text: Tanenbaum
Tiva C TM4C123GH6PM UART Embedded Systems ECE 4437 Fall 2015 Team 2:
The HCS12 SCI Subsystem A HCS12 device may have one or two serial communication interface. These two SCI interfaces are referred to as SCI0 and SCI1. The.
CS-401 Computer Architecture & Assembly Language Programming
Operating Systems (CS 340 D)
1 Input-Output Organization Computer Organization Computer Architectures Lab Peripheral Devices Input-Output Interface Asynchronous Data Transfer Modes.
UART Serial Port Programming
Transmitter Interrupts
Programmable Data Communication Blocks
Serial Communication 19th Han Seung Uk.
Chapter 13: I/O Systems.
Introduction Communication Modes Transmission Modes
Presentation transcript:

Testing Communication Systems  When point-to-point communication between two DTEs is not functioning, which DTE is at fault? Or which DTE is correctly following the protocol? Or is the channel OK?  Many UARTs support built-in hardware facilities that permit programmers to perform software tests. - Loopback testing - Interrupt generation

Loopback Testing  A loopback test causes all data normally supplied to the UART for transmission to be returned to the processor as if it has just been received.... Serial output Serial input Output (from CPU) Input (to CPU) Control Conditions UART (Idle with MARKs) (disconnected)

Loopback Testing  In 8250 UART, loopback is set by writing 0x10 to Modem Control Register (addr 0x3FC for SP1 and addr 0x2FC for SP 2). loopback MCR 07 #define MCR_DEFN (DTR+RTS+OUT2+LOOPBK)

Generating Interrupts  Certain errors (e.g., overrun error or framing error) are caused by random or spurious events that are hard to duplicate, making it difficult to test error-handling software.  In 8250 UART, hardware interrupts can be generated through software to facilitate software testing.  Six H/W interrupts can be software generated from the Line Status Register as well as four from the Modem Status Register.  These interrupts are caused by writing to any of the corresponding status bits in the LSR and the having the UART in loopback mode.

Testing Overrun-error Handling S/W Overrun error Parity error Framing error Break detected Transmit holding register empty Data Ready 1. Turn loopback on (port 0x2FC). 2. Write 0x02 to the LSR (port 0x2FD). 3. A line status interrupt is generated by UART, causing control to be passed to the interrupt handler. 4. IIR = 0x06, LSR = 0x Interrupt is serviced and cleared. LSR

UART Interrupts - Interrupt identification register indicates the cause of the interrupt Interrupt identification register Interrupt pending Interrupt id (b0) Interrupt id (b1) IIR Interrupt 6 Receive line status (overrun, parity error, etc.) 4 Received data available 2 TX holding Reg. empty 0 Modem status change

Channel-Monitoring Tools - indicate (by LED) which signals on each of the different pins/lines between two DTEs are active.  Break-Out Box  Line Analyzer - show the data that is being transmitted on the communication channel.

Commkit Line Analyzer - PC A acts as a line analyzer to monitor traffic between PC 1 and 2. - Basic operations: 1. Read a byte from either serial port. 2. Display the byte. 3. Forward the byte on to the other port. - Bytes from different serial ports are distinguished. - Implemented in three three parts (analyzer.c): 1. Interrupt handlers 2. Display/control process 3. Character-forwarding software A2 1 Need 2 serial ports

Message Flow sp2_ih() sp1_ih() do_analyzer( ) clk_ih() kb_ih() sp1_ih() sp2_ih()