hi,i m trying to simulate wsn with mobility and i have used bonnmotion for 
adding mobility in wsn. the problem is when i run the simulation script it 
gives the following error.  what i can get from the following error is that 
there is some problem in reading bonnmotion movement patern file. i have used 
the movement pattern file the way we use it for manet like:
set val(t) "S1.ns_movements"    and calling that file after the creation of 
nodes
for { set common_node_i 0 } { $common_node_i < 100 } { incr common_node_i } {   
                                                        set local(x) [$rng 
uniform 0.0 $val(x)]                                         set local(y) [$rng 
uniform 0.0 $val(y)]                                         set local(z) 0.0   
             source $val(t)          
i'll be grateful if anyone can point out the reason for this error.regards,najma


najmaismat@ubuntu:~/ns-allinone-2.29/ns-2.29$ ns SM1.tclInitializing MannaSim 
Script...Setting up mica 2 mote with Antenna/OmniAntenna and range = 100
Nodes count: - 1 access points - 100 common nodes - 0 cluster heads - 101 nodes 
- AODV routing protocol - LL link layer - Phy/WirelessPhy network interface
Using sensor.tr as trace filenum_nodes is set 101Creating an access 
point...Setting up mica 2 mote with Antenna/OmniAntenna and range = 100Using 
mica 2 mote settingsSetting up mica 2 mote with Antenna/OmniAntenna and range = 
100warning: Please use -channel as shown in tcl/ex/wireless-mitf.tclINITIALIZE 
THE LIST xListHead* Access point 0 = 0 created in (50.0, 50.0, 0.0)Creating 
common node...Setting up mica 2 mote with Antenna/OmniAntenna and range = 
100Using mica 2 mote settingsSetting up mica 2 mote with Antenna/OmniAntenna 
and range = 100Setting disseminating type to programmedSetting disseminating 
interval: 20.0can't read "node_(1)": no such element in array    while 
executing"$node_(1) set X_ 104.53228771707317"    (file "S1.ns_movements" line 
5)    invoked from within"source.orig S1.ns_movements"    ("uplevel" body line 
1)    invoked from within"uplevel source.orig [list $fileName]"    invoked from 
within"if [$instance_ is_http_url $fileName] {set buffer [$instance_ rea!
 d_url $fileName]uplevel eval $buffer} else {uplevel source.orig [list 
$fileName]..."    (procedure "source" line 8)    invoked from within"source 
$val(t)                      "    ("for" body line 7)    invoked from 
within"for { set common_node_i 0 } { $common_node_i < 100 } { incr 
common_node_i } {                                                           set 
local(x) [$rng uniform 0.0 $val(x)]                                         set 
local(y) [$rn..."    (file "SM1.tcl" line 604)
                                                                                
  

Reply via email to