[ns] Wired-cum-Wireless simulations in ns

Hai Nam hainam at gmail.com
Wed Jun 21 08:01:53 PDT 2006


Hello,

After examining some wireless ad hoc routing protocols implemented in
NS-2, I've found that AODV doesn't support hybrid ad hoc network, DSDV
and DSR support it but not very sure. For example look at DSDV code:

===== from dsdv/dsdv.cc, line 890 =====
  dst = Address::instance().get_nodeaddr(iph->daddr());
  if (diff_subnet(iph->daddr())) {
	   prte = table_->GetEntry (dst);
	  if (prte && prte->metric != BIG)
		  goto send;
	
	  //int dst = (node_->base_stn())->address();
	  dst = node_->base_stn();
	  prte = table_->GetEntry (dst);
	  if (prte && prte->metric != BIG)
		  goto send;
	
	  else {
		  //drop pkt with warning
		  fprintf(stderr, "warning: Route to base_stn not known: dropping pkt\n");
		  Packet::free(p);
		  return;
	  }
  }

  prte = table_->GetEntry (dst);
=====

We see that the choice of route is local. Every node forwards the
packet to the next-hop for its base station, not the base station of
the sender. So if there're more than one access points in the network,
a packet sent from mobile node A to a fixed node may go through a AP
different from AP(A).

Are those implementations correct ? Should we have a mechanism of
tunneling if we want that a packet from A should go to AP(A) before it
reaches the fixed network ?

Best regards,

-- 
Hai-Nam NGUYEN
Elève 3A SLR, ENST Bretagne
2 rue de la Châtaigneraie, 35576 Cesson Sévigné
Site web: http://www.jcisio.com



More information about the Ns-users mailing list