1 / 20

SIMS-201

SIMS-201. Introduction to Error Detection and Correction. Need and Basis for Data Protocols. Overview. Chapter 3: Error detection and correction Parity checking Repetition Redundancy check Chapter 4: Protocols. Error Detection and Correction.

meli
Download Presentation

SIMS-201

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. SIMS-201 Introduction to Error Detection and Correction. Need and Basis for Data Protocols.

  2. Overview Chapter 3: • Error detection and correction • Parity checking • Repetition • Redundancy check Chapter 4: • Protocols

  3. Error Detection and Correction • Many factors can lead to errors during transmission or storage • When binary information is sent across a physical channel such as wire, coax cable, optical fiber or air, there is always the possibility that some bits will be received in error due to interference form other sources; or, due to signal attenuation because of long distances or events like rain or snow, etc. • Binary representation makes it possible to perform coding (changing the original information into a new encoded pattern). Clever coding, or additional information added to the transmission can increase the odds of the sent information being received correctly. We will discuss 3 methods: • Parity checking • Repetition • Redundancy code word checking

  4. Adding redundancy (extra bits that repeat some of the previous information) to a code increases the number of bits that need to be transmitted, but the repetition allows the receiver to detect errors • Just about any system that uses digital information employs some form of error detection and/or correction. • For example, information on a CD is encoded to allow the CD player to detect and correct errors that might arise due to smudged or scratched disks

  5. Parity Checking • A simple form of error detection can be accomplished by appending an extra bit called a parity bit to the code • Even parity is when the parity bit is set so that the total number of 1’s in the word is even • 11  11 0 • 10  10 1 • Odd parity is when the parity bit is set so that the total number of 1’s in the word is odd • 11  11 1 • 10  10 0 Parity bit Parity bit

  6. Parity Errors • Even parity is set: 1 0 0 is received • Error present, but don’t know which one is the bit in error • Parity method can detect certain errors, but cannot correct them • Odd parity is set: 1111011 0 is received. Error? • Even parity is set: 1111011 0 is received. Error? • Parity checking has a major disadvantage due to its inability to detect even number of inverted bits, e.g. 0011 1001 would go undetected even if the original transmission was 0011 1111, because there are 2 errors (even number of errors)

  7. Repetition • Repetition is the provision of extra bits to ensure the information is received correctly • Original data: 1 0 0 1 • Transmitted: 111 000 000 111 • Received: 011 000 001 111 • Errors in the first and third bits detected • Errors in the first and third bits can be corrected

  8. Redundancy Check Code Steps: • Each symbol is given a parity bit (i.e. total “word” is given a redundancy check) • The first bit of each symbol in the word is given parity, then the second bit of each symbol in the word is given parity • The additional parity symbol is given its own parity and then appended to the transmitted information

  9. Redundancy Check Word Symbol • Information to be sent: 00 01 10 11 • With even parity, the above is converted to: 00 0 01 1 10 1 11 0 • First bits are: 0 0 1 1 Odd parity bit: 1 Second bits are: 0 1 0 1 Odd parity bit: 1 3.Odd parity bits: 1 1 Even parity bit: 0 • Transmitted: 000 011 101 110 110 Parity bits

  10. Redundancy Check Error • Transmitted: 000 011 101 110 110 • Received: 000 111 101 110 110 • Even parity tells us that the second symbol has an error • Comparing Odd parity with the first bit in each symbol shows us that the first bit in the second symbol should be a 0 • Comparing Odd parity with the second bit in each symbol shows us that everything is OK

  11. In-class examples • The following binary stream uses repetition to help detect errors. Find the erroneous 2-bit code word. • 001100100011 • If an even-parity bit has been added to each 3-bit data unit for error detection, find the erroneous 4-bit code word in the following: • 001100100011 • Determine the check code word for the following stream: • 10 00 11 10 • Find and correct the error in the following received data sequence that is terminated in a redundancy check code word. • 00 0 10 1 01 0 10 1

  12. Protocols • Believe it or not, we use protocols every day • When we see a red, octagonal sign, we_____ • When we pick up the telephone when it rings, we say _______ • We know to wait in line at the DMV • We understand how to mail a letter • Protocols give structure and provide rules, but they aren’t based on anything other than human convention, agreement and understanding “Agreed upon sets of rules that provide order to a system or situation.”

  13. Protocols are a vital component of IT • What type of connector or voltage level should be used by a device? • How can information be formatted in a standard manner? • Where in a bit stream do we begin? • Which bits comprise the destination address? • How can a document include bold, italics, different font sizes, etc. Interoperability requires sets of rules for communicating between various devices. Without agreed upon formats, we’d be drowning in a sea of 0s and 1s. 010100100101001011110101010110010101010101010

  14. IT Protocols To achieve interoperability, digital systems must organize, manage, and interpret information according to a set of widely accepted standards. • We’ve already discussed many IT standards. • Internet addresses have 32 bits. • The byte is commonly accepted as the smallest division of information for storage and manipulation. • ASCII is the standard protocol for alphanumeric data • IT is built on protocols • Hypertext Markup Language (HTML) • Hypertext Transfer Protocol (HTTP) • Simple Mail Transfer Protocol (SMTP) • Internet Protocol (IP) • And just about everything else we will talk about

  15. Who Sets Standards and Protocols? • Technology Consortiums • Internet Engineering Task Force (IETF) • World Wide Web Consortium (W3C) • International Organizations • International Telecommunications Union (ITU) • International Standards Organization (ISO) • National Organizations • American National Standards Institute (ANSI) • Professional Organizations • Institute of Electrical and Electronic Engineers (IEEE) • Companies: Microsoft, Cisco, 3Com, others…..

  16. Protocol example • An example of sending data. Why do we need a protocol? • Consider that there is some message to be transmitted; it may be destined to travel on the memory bus inside our computer, on the cable to our printer, on a local area network in our building, or across a transcontinental communications link. • First, the message must be encoded into a stream of 0’s and 1’s. Let us assume that it is simple text in English, then ASCII can be used.

  17. Protocol example • 10110011101111 1110101 Y o u • If we were to know where the string starts, and if no bits in the string were to be lost during transmission, then the decoding of the string back into the original characters at the receiver would be easy – using the ASCII table. • However, those two assumptions are not trivial to accomplish

  18. Flag = 01111110 Protocol example • How do we know where the bit stream begins? • Start bits; stop bits (These are protocols) • A commonly used strategy: flags - popularized by High-Level Data Link Control (HDLC) – an international standard defined by ISO, used with Ethernet.

  19. HDLC Protocol Challenges • A protocol procedure like the HDLC flag byte would fail if that byte also occurred somewhere in the content bit stream. • Recall that flag byte 01111110 = ASCII ~ • Furthermore, because the bit stream is read on a bit-by-bit basis, this pattern could appear under other circumstances. • To fix this problem, a rule had to be incorporated into the protocol: • Transmitter: Whenever you have five 1’s in a row, insert an unneeded 0 • Receiver: Whenever you receive five 1’s in a row, followed by a 0, discard the 0 • Note that this only happens in the data (or content) field AFTER the flag byte is transmitted. • This procedure is known as Bit Stuffing, or Zero Bit Insertion

  20. Insert 0 Insert 0 Insert 0 Bit Stuffing Example Original Data0110 1111 1111 1111 1111 0010 Transmitted Data 0110 1111 1011 1110 1111 1010 010

More Related