Error Detection / Correction Hamming code. Why might we need Error detection/correction? Even & Odd Parity — Error detection Hamming code — Used for error.

Slides:



Advertisements
Similar presentations
Serial Communications Interfaces
Advertisements

Mahdi Barhoush Mohammad Hanaysheh
The following 5 questions are about VOLTAGE DIVIDERS. You have 20 seconds for each question What is the voltage at the point X ? A9v B5v C0v D10v Question.
Inside the binary adder. Electro-mechanical relay A solid state relay is a switch that is controlled by a current. When current flows from A to B, the.
Error-Correcting codes
1 Performance Monitoring A Guide for Larger Local Councils (First Draft)
by Colin Kriwox. 2 Contents Introduction credit card error checking what is a code purpose of error-correction codes Encoding naïve approach.
Dan Ernst Improving Reliability We used parity to determine when a memory bit failed. We can protect buses from transmission failures using parity/ECC.
Hamming Code.
parity bit is 1: data should have an odd number of 1's
Tutorial 11 Reference for Hamming Code:
CSCI 4717/5717 Computer Architecture
Parity Generator and Checker
NETWORKING CONCEPTS. ERROR DETECTION Error occures when a bit is altered between transmission& reception ie. Binary 1 is transmitted but received is binary.
Quantum Error Correction SOURCES: Michele Mosca Daniel Gottesman Richard Spillman Andrew Landahl.
Error Detection / Correction
Revision of Chapter III For an information source {p i, i=1,2,…,N} its entropy is defined by Shannon’s first theorem: For an instantaneous coding, we have.
Error detection and correction
Informationsteknologi Friday, October 19, 2007Computer Architecture I - Class 61 Today’s class Floating point numbers Computer systems organization.
Unit 1 Protocols Learning Objectives: Understand the need to detect and correct errors in data transmission.
Hamming It Up with Hamming Codes CSE 461 Section Week 3.
Shashank Srivastava Motilal Nehru National Institute Of Technology, Allahabad Error Detection and Correction : Data Link Layer.
Error Detection and Correction
Information Coding in noisy channel error protection:-- improve tolerance of errors error detection: --- indicate occurrence of errors. Source.
Chapter 5 Internal Memory. Semiconductor Memory Types.
1 Data Link Layer Lecture 20 Imran Ahmed University of Management & Technology.
CIT 307 Online Data Communications Error Detection Module 11 Kevin Siminski, Instructor.
Data and Computer Communications by William Stallings Eighth Edition Digital Data Communications Techniques Digital Data Communications Techniques Click.
Practical Session 10 Error Detecting and Correcting Codes.
ECE453 – Introduction to Computer Networks Lecture 4 – Data Link Layer (I)
Riyadh Philanthropic Society For Science Prince Sultan College For Woman Dept. of Computer & Information Sciences CS 251 Introduction to Computer Organization.
COMPUTER NETWORKS Ms. Mrinmoyee Mukherjee Assistant Professor St. Francis Institute of Technology, Mount Poinsur, S.V.P Road, Borivli (west), Mumbai
Overview All data can be corrupted, for reliable communications we must be able to detect and correct errors implemented at the data link and transport.
VLSI AND INTELLIGENT SYTEMS LABORATORY 12 Bit Hamming Code Error Detector/Corrector December 2nd, 2003 Department of Electrical and Computer Engineering.
1 © Unitec New Zealand CRC calculation and Hammings code.
CS 111 – Sept. 13 Error detection Error correction Review/practice chapter 1 questions Commitment: –Please read sections 2.1 and 2.2.
Review.
Error Detection. Data can be corrupted during transmission. Some applications require that errors be detected and corrected. An error-detecting code can.
Error Detection and Correction – Hamming Code
Data Link Layer. Data Link Layer Topics to Cover Error Detection and Correction Data Link Control and Protocols Multiple Access Local Area Networks Wireless.
Error Detection and Correction
Error-Detecting and Error-Correcting Codes
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Data Link Layer PART III.
Computer Architecture Error Correcting Codes Ralph Grishman Oct (Text pp and B-65-67) NYU.
1 Product Codes An extension of the concept of parity to a large number of words of data 0110… … … … … … …101.
Data Link Layer 1. 2 Single-bit error 3 Multiple-bit error 4.
Practical Session 10 Computer Architecture and Assembly Language.
ERROR DETECTION AND CORRECTION Chapter 8 Data Communications & Networking ERROR DETECTION AND CORRECTION Chapter 8 First Semester 2007/2008.
parity bit is 1: data should have an odd number of 1's
Modulo-2 Digital coding uses modulo-2 arithmetic where addition becomes the following operations: 0+0= =0 0+1= =1 It performs the.
Computer Architecture and Assembly Language
ERROR DETECTION AND CORRECTION
Error Detection and Correction
Character coding schemes
… General Decoder for a Linear Block Code … …
Error Correcting Code.
Even/odd parity (1) Computers can sometimes make errors when they transmit data. Even/odd parity: is basic method for detecting if an odd number of bits.
Coding Theory Dan Siewiorek June 2012.
Error Detection Bit Error Rate(BER): It is the ratio of number Ne of errors appearing over a certain time interval t to the number Nt of 1 and 0 pulses.

Welcome to the presentation. Linear Block Codes Almost all block codes used today belong to a subset called linear block codes. The exclusive OR of two.
Dhanushiya. R I YEAR BSc COMPUTER TECHNOLOGY.  Error is a condition when the output information does not match with the input information. During transmission,
II. Linear Block Codes.
Information Redundancy Fault Tolerant Computing
RAID Redundant Array of Inexpensive (Independent) Disks
Error Detection / Correction
Computer Architecture and Assembly Language
parity bit is 1: data should have an odd number of 1's
Error Detection and Correction
Presentation transcript:

Error Detection / Correction Hamming code

Why might we need Error detection/correction? Even & Odd Parity — Error detection Hamming code — Used for error detection & error correction Error Detection / Correction

Parity bits ASCII – 7 bit code (hex 00 to 7F) Could use “8 th ” bit for parity bit: X –Even parity: make total number of “1” bits is even –Odd parity: make total number of “1” bits odd If a parity bit is added to a bit stream, then there is a basis to check for bit(s) being corrupted.

Error detecting Code Example Error Detection/correction coding: Word: With even parity: With Error: Identifying error:

Hamming Distance The Hamming distance is the number of bits that have to be changed to get from one bit pattern to another. Example: & have a hamming distance of 2 For any coding whose members have a Hamming distance of two, any one bit error can be detected. Why?

Hamming Distance For any coding whose members have a Hamming distance of three, any one bit error can be detected and corrected. Why? And any two bit error can be detected. Why?

Error Correcting Code Function The output of the “Compare” to the “Corrector” is termed the “syndrome”, and is K bits long Syndrome Data Code

Hamming Code Syndrome If we compare the read K bits compared with the write K bits, using an EXOR function, the result is called the “syndrome”. If the syndrome is all zeros, there were no errors. If there is a 1 bit somewhere, we know it represents an error.

Hamming Code Design – determining K To store an M bit word with detection/correction takes M+K bit words If K =1, we can detect single bit errors but not correct them If 2 K - 1 >= M + K, we can detect, identify, and correct all single bit errors, i.e. the syndrome contains the information to correct any single bit error Example: For M = 8: and K = 3: 2 3 – 1 = 7 < (doesn’t work) and K = 4: 2 4 – 1 = 15 > (works!) Therefore, we must choose K =4, i.e., the minimum size of the syndrome is 4

Hamming Code Syndrome If we compare the read K bits with the write K bits, using an exclusive or function, the result is called the “syndrome”. - If the syndrome is all zeros, there were no errors, i.e. the bits were exactly alike - If there is a 1 bit somewhere, we know that 1 represents an error.

Increased word length for error correcting

Hamming Code Syndrome Design Criteria

A Layout of Data and Check Bits that Achieves Our Design Criteria: C1 is a parity check on every data bit whose position is xxx1 C1 = D1 exor D2 exor D4 exor D5 exor D7 C2 is a parity check on every data bit whose position is xx1x C2 = D1 exor D3 exor D4 exor D6 exor D7 C4 is a parity check on every data bit whose position is x1xx C4 = D2 exor D3 exor D4 exor D8 C8 is a parity check on every data bit whose position is 1xxx C8 = D5 exor D6 exor D7 exor D8 Why this ordering? Because we want the syndrome, the Hamming test word, to yield the address of the error.

Example: Data stored = Check bits: Putting it together:

Example:

Word fetched: Check Bits: Putting it all together: Comparing: C8 C4 C2 C Orig Check Bits New Check Bits Syndrome 0110 = 6  bit position 6 is wrong, i.e. bit D3 is wrong

Increased word length for error correcting

SEC-DEC Example Requires One Extra Check Bit Single Error Correction: Single Error Correction, Double Error Detection: Word With Even Parity Word With Even Parity With Two Errors With Errors Identifying Error SEC Attempt IS SEC Correct? Extra Bit Confirms DE

Increased word length for error correcting