2017/02/28

[國考-電信類] 01 計算機概論-01 電腦網路 筆記(五)




第五章. DataLink Layer 資料鏈結層

1. Error Detection    Logical Link Control (LLC)

  • Parity checks: 
    • even(偶數個1), odd(奇數個1) -> detect single bit error
    • two dimensional bit parity -> detect and correct single bit error
    • 缺: 錯一串資料,不一定能偵測,無法更正
  • checksumming:
    • detect "errors" (e.g. flipped bits) in transmitted segment (only transport layer)
    • 優: easy and fast to compute [in TCP/UDP]
  • cyclic redundancy check
    • 可偵測連續n bits的errors, e.g. CRC32 -> 32 bits

2. Multiple access protocols    Media Access Control (MAC)
  • Channel Partitioning protocols -> 適合heavy loading
    • TDMA (time division multiple access): 缺點是不能搶BW,不用浪費,無法達到rateR
    • FDMA (frequency division multiple access): 缺點是沒用到的band浪費,無法達到rateR
    • CDMA (code division multiple access): 所有的user分享一樣的frequency,但使用自己的code去編碼;通常用在無線寬頻(cellular satellite)
  • Random access protocols -> 適合light loading
    • Slotted ALOHA: collision之後,以P的機率決定下次slot是否傳送data;缺點是collision wasting slots,會有idle slot
    • ALOHA: 有packet就立即送出,collision機會變大
    • CSMA/CD (carrier sense multiple access with collision detection):
      • channel idle -> 傳送;channel busy -> wait idle
      • collision -> Jam signal, then exponential back off K={0,1,~,2^m-1}, m=min(n,10), t=K*512 bit times [slot time=0.1us * 512=51.2us]
  • Taking-truns protocols: polling / token passing


3. Address Resolution Protocols (ARP): 建立IP/MAC的對照表

4. Ethernet: 46~1500 bytes (+18 bytes header), CSMA/CD

  • 10Base2: 10Mbps, max 2m; 10BaseT: Twisted pair
  • Hubs: physical-layer repeaters
  • Switch: link-layer device, store and forward
  • Router: network-layer device
  • Manchester encoding: 1: up to down; 0: down to up, 讓sender和receiver同步,避免一連串0/1的資料

5. Point-to-point protocol (PPP): 點對點(2點), no multiple access control

6. Asynchronous Transfer Mode (ATM): 建立連線來保留資源,QoS


沒有留言:

張貼留言