[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ns] Multicast and Unicast node



Hello all,

In one network topology, can I define one node as unicast node and the other as multicast node at the same time ?

I am very confused about the functionality of enable-module(routing-module-name) and the command to enable the multicast when one simulator is created: set ns [new Simulator -multicast on].

As far as I read in Ns-manual, when I use the function before creating new node: Node enable-module("Mcast"), ns will add this routing module into the module_list_ of node. This routing module will be applied for all new nodes ? It means that all new nodes will be the multicast nodes ? If YES, what is the difference from the command set ns [new Simulator -multicast on] ?

Is it possible if I have a OTcl script like following

set ns [new Simulator]

set node1 [$ns node]     <-- this is the Unicast node by default

Node enable-module Mcast
set node2 [$ns node]    <-- is node2 the multicast node ?? and node1 is unicast ?

Node disable-module Mcast
set node3 [$ns node]    <-- node3 is the unicast ? 

Thanks in advance,
Tuan