B SLP协议(3) IP数据报中出现相同END字符? ■为避免收端错误地终止一帧的接收,SLIP中使用了转义字 符ESC。 END字符转换成ESC-END;ESC转换ESC-ESC P数据报 Co DB 1 1 END ESC ESC END Co DB DC DB DD CO 字节1 1 1 1 1 Broadband Wireless Communications Laboratory,Xidian University
Broadband Wireless Communications Laboratory, Xidian University 11 BWC Xidian Univ. ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈~ ≈ ~ ≈ SLIP协议(3) IP数据报中出现相同END字符? 为避免收端错误地终止一帧的接收,SLIP中使用了转义字 符ESC。 END字符转换成ESC-END;ESC转换ESC-ESC C0 DB C0 DB DC DB DD C0 END ESC ESC END 字节 1 1 1 1 1 1 1 1 IP数据报
SLIP协议 (4) ■收端只要收到END字符即表示一帧的开始或结束。 ■每当遇到ESC字符就进行字符转换,恢复IP报文中的原有 的END和ESC字符。 ■这样就可以完全以一个IP数据报的形式向IP层提交数据。 Broadband Wireless Communications Laboratory,Xidian University 12
Broadband Wireless Communications Laboratory, Xidian University 12 BWC Xidian Univ. ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈ ~ ≈~ ≈ ~ ≈ SLIP协议(4) 收端只要收到END字符即表示一帧的开始或结束。 每当遇到ESC字符就进行字符转换,恢复IP报文中的原有 的END和ESC字符。 这样就可以完全以一个IP数据报的形式向IP层提交数据