---
# System prepended metadata

title: 無線網路導論 期中考
tags: [大學部課程]

---

# 無線網路導論 期中考
###### tags: `大學部課程`
# Topic #1 MAC
- MACA: Multiple Access with Collision Avoidance (RTS/CTS)
- DCF: CSMA + RTS/CTS + ACK
- CTS的功能：
    - 同意傳送
    - 警告鄰居
    - MACA: 聽到CTS安靜 -> 解決hidden/exposed terminal
    - DCF: 聽到RTS/CTS都安靜 -> 沒解決exposed terminal
- Aloha: 想傳就傳
    - slotted Aloha
- DAMA: demand assigned multiple access
    1. Explicit reservation: 使用小slot進行競爭(ALOHA)，再依照預約使用通道
    2. Implicit Reservation: PRMA (packet reservation multiple access)
        直接競爭packet slot，搶到就可以一直用，當slot空了就搶下個slot
    3. Reservation TDMA：
        N mini slots，sta各自預約至多 K 個data slots，共N*K data slot
- Polling： Bluetooth and 802.11 PCF
- CDMA: 使用正交碼進行編碼解碼
    - 怕蓋台
# Topic #2 WLAN (Part I)
### IEEE 802.11
- 包含PHY和MAC層
- 僅PYH層不同
- 使用CSMA/CA
- 可變速度
- AP、Ad hoc模式
- MAC Address: 6 Bytes
- Infrastructure:
    - STA
    - AP
    - BSS: basic service set
    - ESS: same subnet
- Ad hoc
    - STA only
    - IBSS: indepedent BSS
    - Every STA act as a router
- Association
    - AP 定期發Beacon (SSID, MAC)
    - STA associate with AP
- Scanning
    - Passive
    - Active
### 802.11 MAC
+ Traffic services
    - DCF
    - PCF
+ Access methods
    - DCF CSDM/CA: random back-off
    - DCF w/ RTS/CTS: avoid hidden terminal
    - PCF: polling
+ Priorities
    - 先等IFS，若空直接送，不然等back-off
    - SIFS: For ACK, CTS, polling response
    - PIFS: For PCF
    - DIFS: For DCF
- CFP and CP: PCF架於DCF之上
    - Superframe: CFP+CP frames
    - NAV: network allocation vector CFP長度
- Random Back-Off
    - 若等完IFS，通道使用中，倒數RBO，避免Collision
    - 當別人搶到通道，倒數暫停 (fairness and starvation avoidance)
    - 通道空了後，再等IFS和剩下的back-off time
- DCF w/o RTS/CTS
    - 傳送後等待ACK
    - 沒收到ACK，增加RBO
    - 接收端ACK只要等SIFS
    - receiver透過CRC判斷要不要ACK
    - Broadcast不用ACK
- DCF w/ RTS/CTS
    - 等DIFS，透過RTS競爭通道
    - Data超過RTS Threshold才用
    - 搶到後，RTS、CTS包含NAV叫大家安靜
    - 這時Data只要等SIFS就可以傳
- PCF: Point Coordination Function
    - PC等PIFS後開始Poll，之後大家等SIFS傳資料/Poll
    - PC等PIFS後沒回就換下個STA
- addressing (MAC addr)
    - 透過addr1判斷是不是給自己的
    - from AP:
        1. DA (STA)
        2. BSSID (AP)
        3. SA (router)
    - To AP:
        1. BSSID (AP)
        2. SA (STA)
        3. DA (router)
    - AP to Router
        - Dest: router
        - From: STA
        - AP隱形了
### Power Managerment
- Active Mode (AM)
- Power-saving mode (PSM)
    - AP 在Beacon中放 TIM
    - TIM: traffic indication map
        AP這裡有buffer哪些STA要收的資料
    - STA定期醒來聽TIM，被點到就發PS poll並收資料
    - DTIM = Delivery TIM
        表示接下來要送Broadcast封包，都不准睡
- Rate Adaption
    - 透過ACK收到狀況決定速率
    - 連續10個ACK就升速
    - 漏掉 2個ACK就降速
# Topic #2 (Part II) Bluetooth, Cellular
## Bluetooth
### 架構
- less than 10m
- fast frequency hopping: reduce interference
- short packets
- piconet: basic network
- 1 master upto 7 slaves
- master poll slave, slave 回 data or NULL
### Addressing
- BD_ADDR: 48 bits MAC addr
- AM_ADDR: 3 bits active slave addr
- PM_ADDR 8 bits parked slave addr
### 特徵
- 2.4GHz,79 sub-channels
- FHSS: frequency hopping at 1600 hops/s
- TDD: 奇數slot上行，偶數slot下行
- SCO、ACL
### 連接
- 透過inquiry和page交換BD_ADDR、CLOCK
- M: Inquiry -> S: Inquiry scan, response -> M
- M: page -> S: page scan, response -> M
- M: response -> S: connection -> M: connection
- Inquiry: M蒐集S
- Page: M提供資料
### Hop seq
- Master BD_addr -> hop seq
- Master Clock -> 大家同步
### Mixed Link types
- SCO: sync connection oriented
    - circuit switching
    - voice
    - reserve time slot
    - 保證頻寬
- ACL: async
    - packet switching
    - data
    - 1,3,5 slots packet size
    - 上下行可以不同大小
    - 可能被別人用掉時間，造成延遲，所以只能傳非同步資料
    - 可以廣播
### Low Power mode
- Hold Mode
    - 小睡一下
    - 仍持有AMA
    - ACL Lost就算了
- Sniff Mode
    - 定時醒來聽ACL
    - 仍持有AMA
    - ACL Lost就算了
- Parked Mode
    - 定時醒來收beacon
    - 歸還AMA
    - 不能參與傳輸
## Cellular Internet
### Components
- cell
- BS
    - FDMA/TDMA
    - CDMA
- MSC(mobile switching center)
    - manage multi BS
    - connect to wired PSTN
    - manages call
    - handles mobility
    - BS frequency planning
- PSTN
### Call setup
- control, traffic channel 使用不同channel
### 2G cellular (voice) network
- BSC
    - serve tens of BTSs
    - allocate BTS radio channels
    - paging (finding cell)
    - handoff (mobile user)
- MSC
    - 收錢
    - 建通話
    - handles mobility (cross BSCs)
- Gateway MSC
    - 整理 MSC資料
    - 到公用電話系統
### 3G
- data network operates in parallel
- RNC (radio network controller)
    - 除了voice還處裡data分給MSC和SGSN
- SGSN (serving GPRS Support Node)
    - delever datagram
    - interact with MSC 來收錢
- GGSN (Gateway GSN)
    - similar to a gateway router
    - connect multi SGSN to internet
- MSC
- GMSC
### 4G
- voice data皆用IP封包傳送
- 針對多媒體分配資源
- 把時間頻率分成小格(RU)，依照RUs收錢

---
## Topic #3 (Part I)
### 自分で読む。