Chinaunix首页 | 论坛 | 博客
  • 博客访问: 221266
  • 博文数量: 25
  • 博客积分: 4085
  • 博客等级: 上校
  • 技术积分: 585
  • 用 户 组: 普通用户
  • 注册时间: 2006-07-30 02:09
文章分类

全部博文(25)

文章存档

2011年(1)

2009年(2)

2008年(22)

我的朋友

分类: 系统运维

2008-03-18 14:47:17

Notes on preparing a demo MAC model


I am working on a MAC model for demo. The model will be like:


  • MAC as a root process model (based on simple_mac model from Session 1510 LAb of OPNETWORK)
  • child process models for CSMA, ALOHA, slotted ALOHA respectvely
  • used with a simple networking/routing layer

simple_mac can assign MAC addresses automatically, based on a global address pool. And the ARP model will also reference this address pool to do address resolution. The two address schemes, i.e. IP addresses and MAC addresses (or MAC identifiers), may not necessarily be needed, though it's the real-life fact.

Since we can reference an IP address in a higher layer application, such as a web browser, FTP client or PING program, why cannot we just use one address scheme all whole the protocol stack?

This sounds violating the principle of layering. Yes, it does. But we're violating it all the time, for the sake of less implementation effort and performance of running.

So I decide to use only 1 address scheme.



Network Layer PDU format:
  • Source Address
  • Destination Address
  • Hop Limit
  • Tag  (a random integer)

Network Layer module:
  • prepend a network layer header to upper layer SDU
  • populate the fields of the network layer header (generate a tag via random number generator)
  • on receiving a PDU from other nodes, deliver it to upper layer if it's destined for this node, otherwise re-send it after decreasing Hop Limit

MAC module:
  • send out (broadcast) the network layer PDU
  • implement CSMA to reduce collisions
There's no MAC header. So why do we need a MAC layer in this example? It's because we need it to perform CSMA (or other MAC algorithms).


阅读(1133) | 评论(0) | 转发(0) |
0

上一篇:没有了

下一篇:Notes on Cisco IOS commands

给主人留下些什么吧!~~