SlideShare a Scribd company logo
Spring 2003 CS 461 1
Outline
Encoding
Framing
Error Detection
Sliding Window Algorithm
Point-to-Point Links
Spring 2003 CS 461 2
Encoding
• Signals propagate over a physical medium
– modulate electromagnetic waves
– e.g., vary voltage
• Encode binary data onto signals
– e.g., 0 as low signal and 1 as high signal
– known as Non-Return to zero (NRZ)
Bits
NRZ
0 0 1 0 1 1 1 1 0 1 0 0 0 0 1 0
Spring 2003 CS 461 3
Problem: Consecutive 1s or 0s
• Low signal (0) may be interpreted as no signal
• High signal (1) leads to baseline wander
• Unable to recover clock
Spring 2003 CS 461 4
Alternative Encodings
• Non-return to Zero Inverted (NRZI)
– make a transition from current signal to encode a one;
stay at current signal to encode a zero
– solves the problem of consecutive ones
• Manchester
– transmit XOR of the NRZ encoded data and the clock
– only 50% efficient (bit rate = 1/2 baud rate)
Spring 2003 CS 461 5
Encodings (cont)
Bits
NRZ
Clock
Manchester
NRZI
0 0 1 0 1 1 1 1 0 1 0 0 0 0 1 0
Spring 2003 CS 461 6
Encodings (cont)
• 4B/5B
– every 4 bits of data encoded in a 5-bit code
– 5-bit codes selected to have no more than one leading 0
and no more than two trailing 0s
– thus, never get more than three consecutive 0s
– resulting 5-bit codes are transmitted using NRZI
– achieves 80% efficiency
Spring 2003 CS 461 7
Framing
• Break sequence of bits into a frame
• Typically implemented by network adaptor
Frames
Bits
Adaptor Adaptor Node BNode A
Spring 2003 CS 461 8
Approaches
• Sentinel-based
– delineate frame with special pattern: 01111110
– e.g., HDLC, SDLC, PPP
– problem: special pattern appears in the payload
– solution: bit stuffing
• sender: insert 0 after five consecutive 1s
• receiver: delete 0 that follows five consecutive 1s
Header Body
8 16 16 8
CRCBeginning
sequence
Ending
sequence
Spring 2003 CS 461 9
Approaches (cont)
• Counter-based
– include payload length in header
– e.g., DDCMP
– problem: count field corrupted
– solution: catch when CRC fails
SYN
Header Body
8 8 4214 168
SYN
Class
CRCCount
Spring 2003 CS 461 10
Approaches (cont)
• Clock-based
– each frame is 125us long
– e.g., SONET: Synchronous Optical Network
– STS-n (STS-1 = 51.84 Mbps)
Overhead Payload
90 columns
9 rows
STS-1
Hdr
STS-1
Hdr
STS-1
Hdr
STS-3cHdr
Spring 2003 CS 461 11
Cyclic Redundancy Check
• Add k bits of redundant data to an n-bit message
– want k << n
– e.g., k = 32 and n = 12,000 (1500 bytes)
• Represent n-bit message as n-1 degree polynomial
– e.g., MSG=10011010 as M(x) = x7
+ x4
+ x3
+ x1
• Let k be the degree of some divisor polynomial
– e.g., C(x) = x3
+ x2
+ 1
Spring 2003 CS 461 12
CRC (cont)
• Transmit polynomial P(x) that is evenly divisible
by C(x)
– shift left k bits, i.e., M(x)xk
– subtract remainder of M(x)xk
/ C(x) from M(x)xk
• Receiver polynomial P(x) + E(x)
– E(x) = 0 implies no errors
• Divide (P(x) + E(x)) by C(x); remainder zero if:
– E(x) was zero (no error), or
– E(x) is exactly divisible by C(x)
Spring 2003 CS 461 13
Selecting C(x)
• All single-bit errors, as long as the xk
and x0
terms have
non-zero coefficients.
• All double-bit errors, as long as C(x) contains a factor with
at least three terms
• Any odd number of errors, as long as C(x) contains the
factor (x + 1)
• Any ‘burst’ error (i.e., sequence of consecutive error bits)
for which the length of the burst is less than k bits.
• Most burst errors of larger than k bits can also be detected
• See Table 2.6 on page 102 for common C(x)
Spring 2003 CS 461 14
Internet Checksum Algorithm
• View message as a sequence of 16-bit integers; sum using
16-bit ones-complement arithmetic; take ones-complement
of the result.
u_short
cksum(u_short *buf, int count)
{
register u_long sum = 0;
while (count--)
{
sum += *buf++;
if (sum & 0xFFFF0000)
{
/* carry occurred, so wrap around */
sum &= 0xFFFF;
sum++;
}
}
return ~(sum & 0xFFFF);
}
Spring 2003 CS 461 15
Acknowledgements & Timeouts
Sender Receiver
Frame
ACK
Timeout
Time
Sender Receiver
Frame
ACK
Timeout
Frame
ACK
Timeout
Sender Receiver
Frame
ACK
Timeout Frame
ACK
Timeout
Sender Receiver
Frame
Timeout
Frame
ACK
Timeout
(a) (c)
(b) (d)
Spring 2003 CS 461 16
Stop-and-Wait
• Problem: keeping the pipe full
• Example
– 1.5Mbps link x 45ms RTT = 67.5Kb (8KB)
– 1KB frames implies 1/8th link utilization
Sender Receiver
Spring 2003 CS 461 17
Sliding Window
• Allow multiple outstanding (un-ACKed) frames
• Upper bound on un-ACKed frames, called window
Sender Receiver
Time
……
Spring 2003 CS 461 18
SW: Sender
• Assign sequence number to each frame (SeqNum)
• Maintain three state variables:
– send window size (SWS)
– last acknowledgment received (LAR)
– last frame sent (LFS)
• Maintain invariant: LFS - LAR <= SWS
• Advance LAR when ACK arrives
• Buffer up to SWS frames
≤SWS
LAR LFS
… …
Spring 2003 CS 461 19
SW: Receiver
• Maintain three state variables
– receive window size (RWS)
– largest frame acceptable (LFA)
– last frame received (NFE)
• Maintain invariant: LFA - LFR <= RWS
• Frame SeqNum arrives:
– if LFR < SeqNum < = LFA accept
– if SeqNum < = LFR or SeqNum > LFA discarded
• Send cumulative ACKs
≤ RWS
NFE LFA
… …
Spring 2003 CS 461 20
Sequence Number Space
• SeqNum field is finite; sequence numbers wrap around
• Sequence number space must be larger then number of
outstanding frames
• SWS <= MaxSeqNum-1 is not sufficient
– suppose 3-bit SeqNum field (0..7)
– SWS=RWS=7
– sender transmit frames 0..6
– arrive successfully, but ACKs lost
– sender retransmits 0..6
– receiver expecting 7, 0..5, but receives second incarnation of 0..5
• SWS < (MaxSeqNum+1)/2 is correct rule
• Intuitively, SeqNum “slides” between two halves of
sequence number space
Spring 2003 CS 461 21
Concurrent Logical Channels
• Multiplex 8 logical channels over a single link
• Run stop-and-wait on each logical channel
• Maintain three state bits per channel
– channel busy
– current sequence number out
– next sequence number in
• Header: 3-bit channel num, 1-bit sequence num
– 4-bits total
– same as sliding window protocol
• Separates reliability from order

More Related Content

What's hot

Stop and Wait arq
Stop and Wait arqStop and Wait arq
Stop and Wait arq
pramodmmrv
 
Introduction of Hidden Markov Model
Introduction of Hidden Markov Model Introduction of Hidden Markov Model
Introduction of Hidden Markov Model
Billy Yang
 
Stop And Wait
Stop And WaitStop And Wait
Stop And Wait
Harsh Singh
 
3a data link layer continued
3a data link layer continued3a data link layer continued
3a data link layer continued
kavish dani
 
Go Back N Arq1
Go  Back N Arq1Go  Back N Arq1
Go Back N Arq1
guestb4ff06
 
modified aes algorithm using multiple s-boxes
modified aes algorithm using multiple s-boxesmodified aes algorithm using multiple s-boxes
modified aes algorithm using multiple s-boxes
chutinhha
 
Simplex stop and_wait_protocol
Simplex stop and_wait_protocolSimplex stop and_wait_protocol
Simplex stop and_wait_protocol
Musfira Ameer
 
GO BACK N PROTOCOL
GO BACK N PROTOCOLGO BACK N PROTOCOL
GO BACK N PROTOCOL
shayan singla
 
Stop-and-Wait ARQ Protocol
Stop-and-Wait ARQ ProtocolStop-and-Wait ARQ Protocol
Stop-and-Wait ARQ Protocol
praneetayargattikar
 
Stop And Wait ARQ
Stop And Wait ARQStop And Wait ARQ
Stop And Wait ARQ
Anitha Selvan
 
Advanced Encryption Standard Report
Advanced Encryption Standard ReportAdvanced Encryption Standard Report
Advanced Encryption Standard Report
brakanjero
 
Module15: Sliding Windows Protocol and Error Control
Module15: Sliding Windows Protocol and Error Control Module15: Sliding Windows Protocol and Error Control
Module15: Sliding Windows Protocol and Error Control
gondwe Ben
 
Cyclic Redundancy Check
Cyclic Redundancy CheckCyclic Redundancy Check
Cyclic Redundancy Check
Rajan Shah
 
Ch 11
Ch 11Ch 11
Sliding window protocol
Sliding window protocolSliding window protocol
Sliding window protocol
Shehara Abeythunga
 
Compactrouting
CompactroutingCompactrouting
Compactrouting
Meenakshi Tripathi
 
Stop and-wait protocol
Stop and-wait protocolStop and-wait protocol
Stop and-wait protocol
Venkata Sreeram
 
Protocols
ProtocolsProtocols
Importance of sliding window protocol
Importance of sliding window protocolImportance of sliding window protocol
Importance of sliding window protocol
eSAT Journals
 

What's hot (19)

Stop and Wait arq
Stop and Wait arqStop and Wait arq
Stop and Wait arq
 
Introduction of Hidden Markov Model
Introduction of Hidden Markov Model Introduction of Hidden Markov Model
Introduction of Hidden Markov Model
 
Stop And Wait
Stop And WaitStop And Wait
Stop And Wait
 
3a data link layer continued
3a data link layer continued3a data link layer continued
3a data link layer continued
 
Go Back N Arq1
Go  Back N Arq1Go  Back N Arq1
Go Back N Arq1
 
modified aes algorithm using multiple s-boxes
modified aes algorithm using multiple s-boxesmodified aes algorithm using multiple s-boxes
modified aes algorithm using multiple s-boxes
 
Simplex stop and_wait_protocol
Simplex stop and_wait_protocolSimplex stop and_wait_protocol
Simplex stop and_wait_protocol
 
GO BACK N PROTOCOL
GO BACK N PROTOCOLGO BACK N PROTOCOL
GO BACK N PROTOCOL
 
Stop-and-Wait ARQ Protocol
Stop-and-Wait ARQ ProtocolStop-and-Wait ARQ Protocol
Stop-and-Wait ARQ Protocol
 
Stop And Wait ARQ
Stop And Wait ARQStop And Wait ARQ
Stop And Wait ARQ
 
Advanced Encryption Standard Report
Advanced Encryption Standard ReportAdvanced Encryption Standard Report
Advanced Encryption Standard Report
 
Module15: Sliding Windows Protocol and Error Control
Module15: Sliding Windows Protocol and Error Control Module15: Sliding Windows Protocol and Error Control
Module15: Sliding Windows Protocol and Error Control
 
Cyclic Redundancy Check
Cyclic Redundancy CheckCyclic Redundancy Check
Cyclic Redundancy Check
 
Ch 11
Ch 11Ch 11
Ch 11
 
Sliding window protocol
Sliding window protocolSliding window protocol
Sliding window protocol
 
Compactrouting
CompactroutingCompactrouting
Compactrouting
 
Stop and-wait protocol
Stop and-wait protocolStop and-wait protocol
Stop and-wait protocol
 
Protocols
ProtocolsProtocols
Protocols
 
Importance of sliding window protocol
Importance of sliding window protocolImportance of sliding window protocol
Importance of sliding window protocol
 

Similar to Solar Project C Test

Lecture set 2
Lecture set 2Lecture set 2
Lecture set 2
Gopi Saiteja
 
Lecture intro to_wcdma
Lecture intro to_wcdmaLecture intro to_wcdma
Lecture intro to_wcdma
Gurpreet Singh
 
Ch3 datalink
Ch3 datalinkCh3 datalink
Ch3 datalink
Ramesh Kumar
 
Mediumaccesscontrol
MediumaccesscontrolMediumaccesscontrol
Mediumaccesscontrol
Vk Sreedhar
 
Part 8 : TCP and Congestion control
Part 8 : TCP and Congestion controlPart 8 : TCP and Congestion control
Part 8 : TCP and Congestion control
Olivier Bonaventure
 
Direct Link Lan
Direct Link LanDirect Link Lan
Direct Link Lan
yanhul
 
IMT Advanced
IMT AdvancedIMT Advanced
Gsm Security and Attacks
Gsm Security and AttacksGsm Security and Attacks
Gsm Security and Attacks
Abdullah Mohamed
 
sliding window protocol for datalink layer.ppt
sliding window protocol for datalink layer.pptsliding window protocol for datalink layer.ppt
sliding window protocol for datalink layer.ppt
ManimegalaM3
 
Data link layar
Data link layarData link layar
Data link layar
jaysanshrestha
 
Data link layar
Data link layarData link layar
Data link layar
jaysanshrestha
 
Digital logic-formula-notes-final-1
Digital logic-formula-notes-final-1Digital logic-formula-notes-final-1
Digital logic-formula-notes-final-1
Kshitij Singh
 
Data link layer elementry protocols
Data link layer elementry protocolsData link layer elementry protocols
Data link layer elementry protocols
sabitha sairam
 
Arduino microcontroller and nRF24L01+ transceivers
Arduino microcontroller and nRF24L01+ transceiversArduino microcontroller and nRF24L01+ transceivers
Arduino microcontroller and nRF24L01+ transceivers
Pavlos Kallis
 
Introduction to Computer Networks
Introduction to Computer Networks Introduction to Computer Networks
Introduction to Computer Networks
TechKev
 
Part5-tcp-improvements.pptx
Part5-tcp-improvements.pptxPart5-tcp-improvements.pptx
Part5-tcp-improvements.pptx
Olivier Bonaventure
 
Performance Analysis Of Different Digital Modulation Scheme
Performance Analysis Of Different Digital Modulation SchemePerformance Analysis Of Different Digital Modulation Scheme
Performance Analysis Of Different Digital Modulation Scheme
Ajay Walia
 
Ntdd
NtddNtdd
Ntdd
NtddNtdd
Lecture 5 from virtual university of pakistan
Lecture 5 from virtual university of pakistanLecture 5 from virtual university of pakistan
Lecture 5 from virtual university of pakistan
Saba Hanif
 

Similar to Solar Project C Test (20)

Lecture set 2
Lecture set 2Lecture set 2
Lecture set 2
 
Lecture intro to_wcdma
Lecture intro to_wcdmaLecture intro to_wcdma
Lecture intro to_wcdma
 
Ch3 datalink
Ch3 datalinkCh3 datalink
Ch3 datalink
 
Mediumaccesscontrol
MediumaccesscontrolMediumaccesscontrol
Mediumaccesscontrol
 
Part 8 : TCP and Congestion control
Part 8 : TCP and Congestion controlPart 8 : TCP and Congestion control
Part 8 : TCP and Congestion control
 
Direct Link Lan
Direct Link LanDirect Link Lan
Direct Link Lan
 
IMT Advanced
IMT AdvancedIMT Advanced
IMT Advanced
 
Gsm Security and Attacks
Gsm Security and AttacksGsm Security and Attacks
Gsm Security and Attacks
 
sliding window protocol for datalink layer.ppt
sliding window protocol for datalink layer.pptsliding window protocol for datalink layer.ppt
sliding window protocol for datalink layer.ppt
 
Data link layar
Data link layarData link layar
Data link layar
 
Data link layar
Data link layarData link layar
Data link layar
 
Digital logic-formula-notes-final-1
Digital logic-formula-notes-final-1Digital logic-formula-notes-final-1
Digital logic-formula-notes-final-1
 
Data link layer elementry protocols
Data link layer elementry protocolsData link layer elementry protocols
Data link layer elementry protocols
 
Arduino microcontroller and nRF24L01+ transceivers
Arduino microcontroller and nRF24L01+ transceiversArduino microcontroller and nRF24L01+ transceivers
Arduino microcontroller and nRF24L01+ transceivers
 
Introduction to Computer Networks
Introduction to Computer Networks Introduction to Computer Networks
Introduction to Computer Networks
 
Part5-tcp-improvements.pptx
Part5-tcp-improvements.pptxPart5-tcp-improvements.pptx
Part5-tcp-improvements.pptx
 
Performance Analysis Of Different Digital Modulation Scheme
Performance Analysis Of Different Digital Modulation SchemePerformance Analysis Of Different Digital Modulation Scheme
Performance Analysis Of Different Digital Modulation Scheme
 
Ntdd
NtddNtdd
Ntdd
 
Ntdd
NtddNtdd
Ntdd
 
Lecture 5 from virtual university of pakistan
Lecture 5 from virtual university of pakistanLecture 5 from virtual university of pakistan
Lecture 5 from virtual university of pakistan
 

Recently uploaded

Advanced Java[Extra Concepts, Not Difficult].docx
Advanced Java[Extra Concepts, Not Difficult].docxAdvanced Java[Extra Concepts, Not Difficult].docx
Advanced Java[Extra Concepts, Not Difficult].docx
adhitya5119
 
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
 
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptxChapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Mohd Adib Abd Muin, Senior Lecturer at Universiti Utara Malaysia
 
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
 
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdfবাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
eBook.com.bd (প্রয়োজনীয় বাংলা বই)
 
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
 
Reimagining Your Library Space: How to Increase the Vibes in Your Library No ...
Reimagining Your Library Space: How to Increase the Vibes in Your Library No ...Reimagining Your Library Space: How to Increase the Vibes in Your Library No ...
Reimagining Your Library Space: How to Increase the Vibes in Your Library No ...
Diana Rendina
 
How to Setup Warehouse & Location in Odoo 17 Inventory
How to Setup Warehouse & Location in Odoo 17 InventoryHow to Setup Warehouse & Location in Odoo 17 Inventory
How to Setup Warehouse & Location in Odoo 17 Inventory
Celine George
 
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdfANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
Priyankaranawat4
 
spot a liar (Haiqa 146).pptx Technical writhing and presentation skills
spot a liar (Haiqa 146).pptx Technical writhing and presentation skillsspot a liar (Haiqa 146).pptx Technical writhing and presentation skills
spot a liar (Haiqa 146).pptx Technical writhing and presentation skills
haiqairshad
 
Chapter wise All Notes of First year Basic Civil Engineering.pptx
Chapter wise All Notes of First year Basic Civil Engineering.pptxChapter wise All Notes of First year Basic Civil Engineering.pptx
Chapter wise All Notes of First year Basic Civil Engineering.pptx
Denish Jangid
 
BÀI TẬP DẠY THÊM TIẾNG ANH LỚP 7 CẢ NĂM FRIENDS PLUS SÁCH CHÂN TRỜI SÁNG TẠO ...
BÀI TẬP DẠY THÊM TIẾNG ANH LỚP 7 CẢ NĂM FRIENDS PLUS SÁCH CHÂN TRỜI SÁNG TẠO ...BÀI TẬP DẠY THÊM TIẾNG ANH LỚP 7 CẢ NĂM FRIENDS PLUS SÁCH CHÂN TRỜI SÁNG TẠO ...
BÀI TẬP DẠY THÊM TIẾNG ANH LỚP 7 CẢ NĂM FRIENDS PLUS SÁCH CHÂN TRỜI SÁNG TẠO ...
Nguyen Thanh Tu Collection
 
Liberal Approach to the Study of Indian Politics.pdf
Liberal Approach to the Study of Indian Politics.pdfLiberal Approach to the Study of Indian Politics.pdf
Liberal Approach to the Study of Indian Politics.pdf
WaniBasim
 
PIMS Job Advertisement 2024.pdf Islamabad
PIMS Job Advertisement 2024.pdf IslamabadPIMS Job Advertisement 2024.pdf Islamabad
PIMS Job Advertisement 2024.pdf Islamabad
AyyanKhan40
 
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
GeorgeMilliken2
 
How to Create a More Engaging and Human Online Learning Experience
How to Create a More Engaging and Human Online Learning Experience How to Create a More Engaging and Human Online Learning Experience
How to Create a More Engaging and Human Online Learning Experience
Wahiba Chair Training & Consulting
 
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
 
NEWSPAPERS - QUESTION 1 - REVISION POWERPOINT.pptx
NEWSPAPERS - QUESTION 1 - REVISION POWERPOINT.pptxNEWSPAPERS - QUESTION 1 - REVISION POWERPOINT.pptx
NEWSPAPERS - QUESTION 1 - REVISION POWERPOINT.pptx
iammrhaywood
 
UGC NET Exam Paper 1- Unit 1:Teaching Aptitude
UGC NET Exam Paper 1- Unit 1:Teaching AptitudeUGC NET Exam Paper 1- Unit 1:Teaching Aptitude
UGC NET Exam Paper 1- Unit 1:Teaching Aptitude
S. Raj Kumar
 
The History of Stoke Newington Street Names
The History of Stoke Newington Street NamesThe History of Stoke Newington Street Names
The History of Stoke Newington Street Names
History of Stoke Newington
 

Recently uploaded (20)

Advanced Java[Extra Concepts, Not Difficult].docx
Advanced Java[Extra Concepts, Not Difficult].docxAdvanced Java[Extra Concepts, Not Difficult].docx
Advanced Java[Extra Concepts, Not Difficult].docx
 
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
 
Chapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.pptxChapter 4 - Islamic Financial Institutions in Malaysia.pptx
Chapter 4 - Islamic Financial Institutions in Malaysia.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” .
 
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdfবাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
বাংলাদেশ অর্থনৈতিক সমীক্ষা (Economic Review) ২০২৪ UJS App.pdf
 
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
 
Reimagining Your Library Space: How to Increase the Vibes in Your Library No ...
Reimagining Your Library Space: How to Increase the Vibes in Your Library No ...Reimagining Your Library Space: How to Increase the Vibes in Your Library No ...
Reimagining Your Library Space: How to Increase the Vibes in Your Library No ...
 
How to Setup Warehouse & Location in Odoo 17 Inventory
How to Setup Warehouse & Location in Odoo 17 InventoryHow to Setup Warehouse & Location in Odoo 17 Inventory
How to Setup Warehouse & Location in Odoo 17 Inventory
 
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdfANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
ANATOMY AND BIOMECHANICS OF HIP JOINT.pdf
 
spot a liar (Haiqa 146).pptx Technical writhing and presentation skills
spot a liar (Haiqa 146).pptx Technical writhing and presentation skillsspot a liar (Haiqa 146).pptx Technical writhing and presentation skills
spot a liar (Haiqa 146).pptx Technical writhing and presentation skills
 
Chapter wise All Notes of First year Basic Civil Engineering.pptx
Chapter wise All Notes of First year Basic Civil Engineering.pptxChapter wise All Notes of First year Basic Civil Engineering.pptx
Chapter wise All Notes of First year Basic Civil Engineering.pptx
 
BÀI TẬP DẠY THÊM TIẾNG ANH LỚP 7 CẢ NĂM FRIENDS PLUS SÁCH CHÂN TRỜI SÁNG TẠO ...
BÀI TẬP DẠY THÊM TIẾNG ANH LỚP 7 CẢ NĂM FRIENDS PLUS SÁCH CHÂN TRỜI SÁNG TẠO ...BÀI TẬP DẠY THÊM TIẾNG ANH LỚP 7 CẢ NĂM FRIENDS PLUS SÁCH CHÂN TRỜI SÁNG TẠO ...
BÀI TẬP DẠY THÊM TIẾNG ANH LỚP 7 CẢ NĂM FRIENDS PLUS SÁCH CHÂN TRỜI SÁNG TẠO ...
 
Liberal Approach to the Study of Indian Politics.pdf
Liberal Approach to the Study of Indian Politics.pdfLiberal Approach to the Study of Indian Politics.pdf
Liberal Approach to the Study of Indian Politics.pdf
 
PIMS Job Advertisement 2024.pdf Islamabad
PIMS Job Advertisement 2024.pdf IslamabadPIMS Job Advertisement 2024.pdf Islamabad
PIMS Job Advertisement 2024.pdf Islamabad
 
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
What is Digital Literacy? A guest blog from Andy McLaughlin, University of Ab...
 
How to Create a More Engaging and Human Online Learning Experience
How to Create a More Engaging and Human Online Learning Experience How to Create a More Engaging and Human Online Learning Experience
How to Create a More Engaging and Human Online Learning Experience
 
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)
 
NEWSPAPERS - QUESTION 1 - REVISION POWERPOINT.pptx
NEWSPAPERS - QUESTION 1 - REVISION POWERPOINT.pptxNEWSPAPERS - QUESTION 1 - REVISION POWERPOINT.pptx
NEWSPAPERS - QUESTION 1 - REVISION POWERPOINT.pptx
 
UGC NET Exam Paper 1- Unit 1:Teaching Aptitude
UGC NET Exam Paper 1- Unit 1:Teaching AptitudeUGC NET Exam Paper 1- Unit 1:Teaching Aptitude
UGC NET Exam Paper 1- Unit 1:Teaching Aptitude
 
The History of Stoke Newington Street Names
The History of Stoke Newington Street NamesThe History of Stoke Newington Street Names
The History of Stoke Newington Street Names
 

Solar Project C Test

  • 1. Spring 2003 CS 461 1 Outline Encoding Framing Error Detection Sliding Window Algorithm Point-to-Point Links
  • 2. Spring 2003 CS 461 2 Encoding • Signals propagate over a physical medium – modulate electromagnetic waves – e.g., vary voltage • Encode binary data onto signals – e.g., 0 as low signal and 1 as high signal – known as Non-Return to zero (NRZ) Bits NRZ 0 0 1 0 1 1 1 1 0 1 0 0 0 0 1 0
  • 3. Spring 2003 CS 461 3 Problem: Consecutive 1s or 0s • Low signal (0) may be interpreted as no signal • High signal (1) leads to baseline wander • Unable to recover clock
  • 4. Spring 2003 CS 461 4 Alternative Encodings • Non-return to Zero Inverted (NRZI) – make a transition from current signal to encode a one; stay at current signal to encode a zero – solves the problem of consecutive ones • Manchester – transmit XOR of the NRZ encoded data and the clock – only 50% efficient (bit rate = 1/2 baud rate)
  • 5. Spring 2003 CS 461 5 Encodings (cont) Bits NRZ Clock Manchester NRZI 0 0 1 0 1 1 1 1 0 1 0 0 0 0 1 0
  • 6. Spring 2003 CS 461 6 Encodings (cont) • 4B/5B – every 4 bits of data encoded in a 5-bit code – 5-bit codes selected to have no more than one leading 0 and no more than two trailing 0s – thus, never get more than three consecutive 0s – resulting 5-bit codes are transmitted using NRZI – achieves 80% efficiency
  • 7. Spring 2003 CS 461 7 Framing • Break sequence of bits into a frame • Typically implemented by network adaptor Frames Bits Adaptor Adaptor Node BNode A
  • 8. Spring 2003 CS 461 8 Approaches • Sentinel-based – delineate frame with special pattern: 01111110 – e.g., HDLC, SDLC, PPP – problem: special pattern appears in the payload – solution: bit stuffing • sender: insert 0 after five consecutive 1s • receiver: delete 0 that follows five consecutive 1s Header Body 8 16 16 8 CRCBeginning sequence Ending sequence
  • 9. Spring 2003 CS 461 9 Approaches (cont) • Counter-based – include payload length in header – e.g., DDCMP – problem: count field corrupted – solution: catch when CRC fails SYN Header Body 8 8 4214 168 SYN Class CRCCount
  • 10. Spring 2003 CS 461 10 Approaches (cont) • Clock-based – each frame is 125us long – e.g., SONET: Synchronous Optical Network – STS-n (STS-1 = 51.84 Mbps) Overhead Payload 90 columns 9 rows STS-1 Hdr STS-1 Hdr STS-1 Hdr STS-3cHdr
  • 11. Spring 2003 CS 461 11 Cyclic Redundancy Check • Add k bits of redundant data to an n-bit message – want k << n – e.g., k = 32 and n = 12,000 (1500 bytes) • Represent n-bit message as n-1 degree polynomial – e.g., MSG=10011010 as M(x) = x7 + x4 + x3 + x1 • Let k be the degree of some divisor polynomial – e.g., C(x) = x3 + x2 + 1
  • 12. Spring 2003 CS 461 12 CRC (cont) • Transmit polynomial P(x) that is evenly divisible by C(x) – shift left k bits, i.e., M(x)xk – subtract remainder of M(x)xk / C(x) from M(x)xk • Receiver polynomial P(x) + E(x) – E(x) = 0 implies no errors • Divide (P(x) + E(x)) by C(x); remainder zero if: – E(x) was zero (no error), or – E(x) is exactly divisible by C(x)
  • 13. Spring 2003 CS 461 13 Selecting C(x) • All single-bit errors, as long as the xk and x0 terms have non-zero coefficients. • All double-bit errors, as long as C(x) contains a factor with at least three terms • Any odd number of errors, as long as C(x) contains the factor (x + 1) • Any ‘burst’ error (i.e., sequence of consecutive error bits) for which the length of the burst is less than k bits. • Most burst errors of larger than k bits can also be detected • See Table 2.6 on page 102 for common C(x)
  • 14. Spring 2003 CS 461 14 Internet Checksum Algorithm • View message as a sequence of 16-bit integers; sum using 16-bit ones-complement arithmetic; take ones-complement of the result. u_short cksum(u_short *buf, int count) { register u_long sum = 0; while (count--) { sum += *buf++; if (sum & 0xFFFF0000) { /* carry occurred, so wrap around */ sum &= 0xFFFF; sum++; } } return ~(sum & 0xFFFF); }
  • 15. Spring 2003 CS 461 15 Acknowledgements & Timeouts Sender Receiver Frame ACK Timeout Time Sender Receiver Frame ACK Timeout Frame ACK Timeout Sender Receiver Frame ACK Timeout Frame ACK Timeout Sender Receiver Frame Timeout Frame ACK Timeout (a) (c) (b) (d)
  • 16. Spring 2003 CS 461 16 Stop-and-Wait • Problem: keeping the pipe full • Example – 1.5Mbps link x 45ms RTT = 67.5Kb (8KB) – 1KB frames implies 1/8th link utilization Sender Receiver
  • 17. Spring 2003 CS 461 17 Sliding Window • Allow multiple outstanding (un-ACKed) frames • Upper bound on un-ACKed frames, called window Sender Receiver Time ……
  • 18. Spring 2003 CS 461 18 SW: Sender • Assign sequence number to each frame (SeqNum) • Maintain three state variables: – send window size (SWS) – last acknowledgment received (LAR) – last frame sent (LFS) • Maintain invariant: LFS - LAR <= SWS • Advance LAR when ACK arrives • Buffer up to SWS frames ≤SWS LAR LFS … …
  • 19. Spring 2003 CS 461 19 SW: Receiver • Maintain three state variables – receive window size (RWS) – largest frame acceptable (LFA) – last frame received (NFE) • Maintain invariant: LFA - LFR <= RWS • Frame SeqNum arrives: – if LFR < SeqNum < = LFA accept – if SeqNum < = LFR or SeqNum > LFA discarded • Send cumulative ACKs ≤ RWS NFE LFA … …
  • 20. Spring 2003 CS 461 20 Sequence Number Space • SeqNum field is finite; sequence numbers wrap around • Sequence number space must be larger then number of outstanding frames • SWS <= MaxSeqNum-1 is not sufficient – suppose 3-bit SeqNum field (0..7) – SWS=RWS=7 – sender transmit frames 0..6 – arrive successfully, but ACKs lost – sender retransmits 0..6 – receiver expecting 7, 0..5, but receives second incarnation of 0..5 • SWS < (MaxSeqNum+1)/2 is correct rule • Intuitively, SeqNum “slides” between two halves of sequence number space
  • 21. Spring 2003 CS 461 21 Concurrent Logical Channels • Multiplex 8 logical channels over a single link • Run stop-and-wait on each logical channel • Maintain three state bits per channel – channel busy – current sequence number out – next sequence number in • Header: 3-bit channel num, 1-bit sequence num – 4-bits total – same as sliding window protocol • Separates reliability from order