ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
hi , i'm a newbie to ns2 i successfully installed ns2.34 on Ubuntu 12.04, i added the mit leach modules to it, and it works fine except that it generates a file called "leach.out" it is supposed to work fine on NAM but somehow it gives this error:
Code:
Cannot connect to existing nam instance. Starting a new one...
*** !!! ***
nam cannot recognize the trace file leach.out
Please make sure that the file is not empty and it is a nam trace
***********
i coundn't find anything about this, and i'm really disperate for a solution , i'm very close of acheiving my Final report and i appreciate any help you can provide, thanks in advance
help me deepa or kundfl
Data being sent to the Base Station - ns-leach.tcl
Node 9 sending {{9 , 0.0048719999999999996}} to BS at time 0.010680927377596929 - ns-leach.tcl
Data was sent to the base station - ns-leach.tcl
10: Warning!!! No Cluster Head ADVs were heard! - ns-leach.tcl
Data being sent to the Base Station - ns-leach.tcl
Node 10 sending {{10 , 0.0048719999999999996}} to BS at time 0.010341528578906101 - ns-leach.tcl
Data was sent to the base station - ns-leach.41: Warning!!! No Cluster Head ADVs were heard! - ns-leach.tcl
Data being sent to the Base Station - ns-leach.tcl
Node 41 sending {{41 , 0.0048719999999999996}} to BS at time 0.011923364219305741 - ns-leach.tcl
Data was sent to the base station - ns-leach.tcl.tcl
86 rcvd ADV_CH from 89 at 0.35214688126457688 - ns-leach.tcl
11 rcvd ADV_CH from 89 at 0.35214688240072201 - ns-leach.tcl
57 rcvd ADV_CH from 89 at 0.35214688368355757 - ns-leach.tcl
97 rcvd ADV_CH from 89 at 0.35214688552882117 - ns-leach.tcl
42 rcvd ADV_CH from 89 at 0.3521468952872554 - ns-leach.tcl
98 rcvd ADV_CH from 89 at 0.3521468973037466 - ns-leach.tcl
82 rcvd ADV_CH from 89 at 0.35214689918642728 - ns-leach.tcl
25 rcvd ADV_CH from 89 at 0.35214690052854253 - ns-leach.tcl
64 rcvd ADV_CH from 89 at 0.35214690593789666 - ns-leach.tcl
61 rcvd ADV_CH from 89 at 0.35214690959485345 - ns-leach.tcl
44 rcvd ADV_CH from 89 at 0.35214691731930575 - ns-leach.tcl
40 rcvd ADV_CH from 89 at 0.35214691766277584 - ns-leach.tcl
72 rcvd ADV_CH from 89 at 0.35214691796518416 - ns-leach.tcl
1 rcvd ADV_CH from 89 at 0.35214691843740381 - ns-leach.tcl
69 rcvd ADV_CH from 89 at 0.35214692764457595 - ns-leach.tcl
27 rcvd ADV_CH from 89 at 0.35214693476637199 - ns-leach.tcl
31 rcvd ADV_CH from 89 at 0.35214693667072827 - ns-leach.tcl
66 rcvd ADV_CH from 89 at 0.35214693901017496 - ns-leach.tcl
18 rcvd ADV_CH from 89 at 0.35214697116257959 - ns-leach.tcl
54 rcvd ADV_CH from 89 at 0.35214697153135915 - ns-leach.tcl
47 rcvd ADV_CH from 89 at 0.3521469826334877 - ns-leach.tcl
0 rcvd ADV_CH from 52 at 0.51508049079730844 - ns-leach.tcl
92 rcvd ADV_CH from 52 at 0.51508051038336478 - ns-leach.tcl
4 rcvd ADV_CH from 52 at 0.51508051054659898 - ns-leach.tcl
73 rcvd ADV_CH from 52 at 0.51508051257738785 - ns-leach.tcl
56 rcvd ADV_CH from 52 at 0.5150805143033349 - ns-leach.tcl
9 rcvd ADV_CH from 52 at 0.51508051523938381 - ns-leach.tcl
94 rcvd ADV_CH from 52 at 0.51508053982602364 - ns-leach.tcl
91 rcvd ADV_CH from 52 at 0.51508054745766396 - ns-leach.tcl
39 rcvd ADV_CH from 52 at 0.51508054776204004 - ns-leach.tcl
48 rcvd ADV_CH from 52 at 0.5150805490862147 - ns-leach.tcl
22 rcvd ADV_CH from 52 at 0.51508055289302634 - ns-leach.tcl
32 rcvd ADV_CH from 52 at 0.51508055844912826 - ns-leach.tcl
14 rcvd ADV_CH from 52 at 0.51508055982508105 - ns-leach.tcl
81 rcvd ADV_CH from 52 at 0.51508056097865151 - ns-leach.tcl
58 rcvd ADV_CH from 52 at 0.51508056264219626 - ns-leach.tcl
51 rcvd ADV_CH from 52 at 0.51508056461718177 - ns-leach.tcl
95 rcvd ADV_CH from 52 at 0.51508057070446978 - ns-leach.tcl
71 rcvd ADV_CH from 52 at 0.5150805730655772 - ns-leach.tcl
84 rcvd ADV_CH from 52 at 0.5150805815189804 - ns-leach.tcl
68 rcvd ADV_CH from 52 at 0.51508058162699388 - ns-leach.tcl
74 rcvd ADV_CH from 52 at 0.51508058240829657 - ns-leach.tcl
24 rcvd ADV_CH from 52 at 0.51508058473410701 - ns-leach.tcl
10 rcvd ADV_CH from 52 at 0.51508059284312702 - ns-leach.tcl
19 rcvd ADV_CH from 52 at 0.51508059750005253 - ns-leach.tcl
77 rcvd ADV_CH from 52 at 0.51508060149016643 - ns-leach.tcl
33 rcvd ADV_CH from 52 at 0.51508060633003161 - ns-leach.tcl
26 rcvd ADV_CH from 52 at 0.51508061002959837 - ns-leach.tcl
93 rcvd ADV_CH from 52 at 0.51508061038117858 - ns-leach.tcl
99 rcvd ADV_CH from 52 at 0.5150806113257671 - ns-leach.tcl
50 rcvd ADV_CH from 52 at 0.5150806167286156 - ns-leach.tcl
75 rcvd ADV_CH from 52 at 0.5150806303955433 - ns-leach.tcl
90 rcvd ADV_CH from 52 at 0.51508063123139525 - ns-leach.tcl
41 rcvd ADV_CH from 52 at 0.51508063384288227 - ns-leach.tcl
60 rcvd ADV_CH from 52 at 0.51508063655415981 - ns-leach.tcl
96 rcvd ADV_CH from 52 at 0.51508063854184616 - ns-leach.tcl
80 rcvd ADV_CH from 52 at 0.51508064293403322 - ns-leach.tcl
63 rcvd ADV_CH from 52 at 0.51508065404529102 - ns-leach.tcl
8 rcvd ADV_CH from 52 at 0.51508065424385119 - ns-leach.tcl
15 rc
Node 95 is DEAD!!!! - ns-leach.tcl
At 1.0999999999999999:
Total Energy = 2.2319545688929767
Total Data = 0
Total Alive = 4
Simulation complete.n
num_nodes is set 101
mac/channel.cc: sendUp - Calc highestAntennaZ_ and distCST_
mac/channel.cc: highestAntennaZ_ = 1.5, distCST_ = 221.2
i have this code in leach .out and i have just one TDMAschedule0.txt please help me so urgent haw i can correct this and have correct simulation leach sous ns2.34
help me deepa or kundfl
Data being sent to the Base Station - ns-leach.tcl
Node 9 sending {{9 , 0.0048719999999999996}} to BS at time 0.010680927377596929 - ns-leach.tcl
Data was sent to the base station - ns-leach.tcl
10: Warning!!! No Cluster Head ADVs were heard! - ns-leach.tcl
Data being sent to the Base Station - ns-leach.tcl
Node 10 sending {{10 , 0.0048719999999999996}} to BS at time 0.010341528578906101 - ns-leach.tcl
Data was sent to the base station - ns-leach.41: Warning!!! No Cluster Head ADVs were heard! - ns-leach.tcl
Data being sent to the Base Station - ns-leach.tcl
Node 41 sending {{41 , 0.0048719999999999996}} to BS at time 0.011923364219305741 - ns-leach.tcl
Data was sent to the base station - ns-leach.tcl.tcl
86 rcvd ADV_CH from 89 at 0.35214688126457688 - ns-leach.tcl
11 rcvd ADV_CH from 89 at 0.35214688240072201 - ns-leach.tcl
57 rcvd ADV_CH from 89 at 0.35214688368355757 - ns-leach.tcl
97 rcvd ADV_CH from 89 at 0.35214688552882117 - ns-leach.tcl
42 rcvd ADV_CH from 89 at 0.3521468952872554 - ns-leach.tcl
98 rcvd ADV_CH from 89 at 0.3521468973037466 - ns-leach.tcl
82 rcvd ADV_CH from 89 at 0.35214689918642728 - ns-leach.tcl
25 rcvd ADV_CH from 89 at 0.35214690052854253 - ns-leach.tcl
64 rcvd ADV_CH from 89 at 0.35214690593789666 - ns-leach.tcl
61 rcvd ADV_CH from 89 at 0.35214690959485345 - ns-leach.tcl
44 rcvd ADV_CH from 89 at 0.35214691731930575 - ns-leach.tcl
40 rcvd ADV_CH from 89 at 0.35214691766277584 - ns-leach.tcl
72 rcvd ADV_CH from 89 at 0.35214691796518416 - ns-leach.tcl
1 rcvd ADV_CH from 89 at 0.35214691843740381 - ns-leach.tcl
69 rcvd ADV_CH from 89 at 0.35214692764457595 - ns-leach.tcl
27 rcvd ADV_CH from 89 at 0.35214693476637199 - ns-leach.tcl
31 rcvd ADV_CH from 89 at 0.35214693667072827 - ns-leach.tcl
66 rcvd ADV_CH from 89 at 0.35214693901017496 - ns-leach.tcl
18 rcvd ADV_CH from 89 at 0.35214697116257959 - ns-leach.tcl
54 rcvd ADV_CH from 89 at 0.35214697153135915 - ns-leach.tcl
47 rcvd ADV_CH from 89 at 0.3521469826334877 - ns-leach.tcl
0 rcvd ADV_CH from 52 at 0.51508049079730844 - ns-leach.tcl
92 rcvd ADV_CH from 52 at 0.51508051038336478 - ns-leach.tcl
4 rcvd ADV_CH from 52 at 0.51508051054659898 - ns-leach.tcl
73 rcvd ADV_CH from 52 at 0.51508051257738785 - ns-leach.tcl
56 rcvd ADV_CH from 52 at 0.5150805143033349 - ns-leach.tcl
9 rcvd ADV_CH from 52 at 0.51508051523938381 - ns-leach.tcl
94 rcvd ADV_CH from 52 at 0.51508053982602364 - ns-leach.tcl
91 rcvd ADV_CH from 52 at 0.51508054745766396 - ns-leach.tcl
39 rcvd ADV_CH from 52 at 0.51508054776204004 - ns-leach.tcl
48 rcvd ADV_CH from 52 at 0.5150805490862147 - ns-leach.tcl
22 rcvd ADV_CH from 52 at 0.51508055289302634 - ns-leach.tcl
32 rcvd ADV_CH from 52 at 0.51508055844912826 - ns-leach.tcl
14 rcvd ADV_CH from 52 at 0.51508055982508105 - ns-leach.tcl
81 rcvd ADV_CH from 52 at 0.51508056097865151 - ns-leach.tcl
58 rcvd ADV_CH from 52 at 0.51508056264219626 - ns-leach.tcl
51 rcvd ADV_CH from 52 at 0.51508056461718177 - ns-leach.tcl
95 rcvd ADV_CH from 52 at 0.51508057070446978 - ns-leach.tcl
71 rcvd ADV_CH from 52 at 0.5150805730655772 - ns-leach.tcl
84 rcvd ADV_CH from 52 at 0.5150805815189804 - ns-leach.tcl
68 rcvd ADV_CH from 52 at 0.51508058162699388 - ns-leach.tcl
74 rcvd ADV_CH from 52 at 0.51508058240829657 - ns-leach.tcl
24 rcvd ADV_CH from 52 at 0.51508058473410701 - ns-leach.tcl
10 rcvd ADV_CH from 52 at 0.51508059284312702 - ns-leach.tcl
19 rcvd ADV_CH from 52 at 0.51508059750005253 - ns-leach.tcl
77 rcvd ADV_CH from 52 at 0.51508060149016643 - ns-leach.tcl
33 rcvd ADV_CH from 52 at 0.51508060633003161 - ns-leach.tcl
26 rcvd ADV_CH from 52 at 0.51508061002959837 - ns-leach.tcl
93 rcvd ADV_CH from 52 at 0.51508061038117858 - ns-leach.tcl
99 rcvd ADV_CH from 52 at 0.5150806113257671 - ns-leach.tcl
50 rcvd ADV_CH from 52 at 0.5150806167286156 - ns-leach.tcl
75 rcvd ADV_CH from 52 at 0.5150806303955433 - ns-leach.tcl
90 rcvd ADV_CH from 52 at 0.51508063123139525 - ns-leach.tcl
41 rcvd ADV_CH from 52 at 0.51508063384288227 - ns-leach.tcl
60 rcvd ADV_CH from 52 at 0.51508063655415981 - ns-leach.tcl
96 rcvd ADV_CH from 52 at 0.51508063854184616 - ns-leach.tcl
80 rcvd ADV_CH from 52 at 0.51508064293403322 - ns-leach.tcl
63 rcvd ADV_CH from 52 at 0.51508065404529102 - ns-leach.tcl
8 rcvd ADV_CH from 52 at 0.51508065424385119 - ns-leach.tcl
15 rc
Node 95 is DEAD!!!! - ns-leach.tcl
At 1.0999999999999999:
Total Energy = 2.2319545688929767
Total Data = 0
Total Alive = 4
Simulation complete.n
num_nodes is set 101
mac/channel.cc: sendUp - Calc highestAntennaZ_ and distCST_
mac/channel.cc: highestAntennaZ_ = 1.5, distCST_ = 221.2
i have this code in leach .out and i have just one TDMAschedule0.txt please help me so urgent haw i can correct this and have correct simulation leach sous ns2.34
Thanks in advance.
T
Last edited by goldking123; 07-08-2013 at 01:39 AM.
Sir I had to add mobility to eyana.tcl you sent me and the commands I'm using are:
Code:
$UE(0) set X_ 5.0
$UE(0) set Y_ 2.0
$UE(0) set Z_ 0.0
$UE(1) set X_ 8.0
$UE(1) set Y_ 9.0
$UE(1) set Z_ 5.0
$ns at 5.0 $UE(0) setdest 15.0 11.0 40
$ns at 5.0 $UE(0) setdest 13.0 18.0 80
I'm getting errors like
Code:
(_o31 cmd line 1)
invoked from within
"_o31 cmd random-motion 0"
invoked from within
"catch "$self cmd $args" ret"
invoked from within
"if [catch "$self cmd $args" ret] {
set cls [$self info class]
global errorInfo
set savedInfo $errorInfo
error "error when calling class $cls: $args" $..."
(procedure "_o31" line 2)
(SplitObject unknown line 2)
invoked from within
"$UE(0) random-motion 0"
I am getting following output for mannasim script of LEach Code...
the simulation time is 100 second..once time is completed, the following line error comes...
so, i m not getting complete output....pls give me solution to this!!
Node 01 - Temperature Data 18.192634 - Time 99.979518
Common Node 1 - Disseminating data - Time 99.980
- There is 100 data aggregated.
Node 02 - Temperature Data 27.967406 - Time 99.979518
Common Node 2 - Disseminating data - Time 99.980
- There is 9 data aggregated.
Node 03 - Temperature Data 26.173846 - Time 99.979518
Common Node 3 - Disseminating data - Time 99.980
- There is 13 data aggregated.
Node 04 - Temperature Data 30.666445 - Time 99.979518
Common Node 4 - Disseminating data - Time 99.980
- There is 4 data aggregated.
Node 05 - Temperature Data 26.938090 - Time 99.979518
Node 06 - Temperature Data 20.684796 - Time 99.979518
Node 07 - Temperature Data 24.443766 - Time 99.979518
Common Node 7 - Disseminating data - Time 99.980
- There is 10 data aggregated.
Node 08 - Temperature Data 28.144877 - Time 99.979518
Node 09 - Temperature Data 20.646578 - Time 99.979518
Common Node 9 - Disseminating data - Time 99.980
- There is 8 data aggregated.
Node 10 - Temperature Data 32.209547 - Time 99.979518
Common Node 10 - Disseminating data - Time 99.980
- There is 9 data aggregated.
Node 01 - Temperature Data 25.501328 - Time 99.989518
Common Node 1 - Disseminating data - Time 99.990
- There is 100 data aggregated.
Node 02 - Temperature Data 29.637047 - Time 99.989518
Common Node 2 - Disseminating data - Time 99.990
- There is 10 data aggregated.
Node 03 - Temperature Data 25.546828 - Time 99.989518
Common Node 3 - Disseminating data - Time 99.990
- There is 14 data aggregated.
Node 04 - Temperature Data 24.461382 - Time 99.989518
Common Node 4 - Disseminating data - Time 99.990
- There is 5 data aggregated.
Node 05 - Temperature Data 30.773853 - Time 99.989518
Node 06 - Temperature Data 24.260325 - Time 99.989518
Node 07 - Temperature Data 31.933280 - Time 99.989518
Common Node 7 - Disseminating data - Time 99.990
- There is 11 data aggregated.
Node 08 - Temperature Data 30.123167 - Time 99.989518
Node 09 - Temperature Data 22.324197 - Time 99.989518
Common Node 9 - Disseminating data - Time 99.990
- There is 9 data aggregated.
Node 10 - Temperature Data 16.452675 - Time 99.989518
Common Node 10 - Disseminating data - Time 99.990
- There is 10 data aggregated.
Node 3 sending 14 data to BS at time 99.992945
Node 01 - Temperature Data 28.536849 - Time 99.999518
Common Node 1 - Disseminating data - Time 100.000
- There is 100 data aggregated.
Node 02 - Temperature Data 26.184584 - Time 99.999518
Common Node 2 - Disseminating data - Time 100.000
- There is 11 data aggregated.
Node 03 - Temperature Data 20.140662 - Time 99.999518
Common Node 3 - Disseminating data - Time 100.000
- There is 1 data aggregated.
Node 04 - Temperature Data 25.497074 - Time 99.999518
Common Node 4 - Disseminating data - Time 100.000
- There is 6 data aggregated.
Node 05 - Temperature Data 30.570585 - Time 99.999518
Node 06 - Temperature Data 19.549540 - Time 99.999518
Node 07 - Temperature Data 22.688538 - Time 99.999518
Common Node 7 - Disseminating data - Time 100.000
- There is 12 data aggregated.
Node 08 - Temperature Data 25.157270 - Time 99.999518
Node 09 - Temperature Data 36.946266 - Time 99.999518
Common Node 9 - Disseminating data - Time 100.000
- There is 10 data aggregated.
Node 10 - Temperature Data 34.776099 - Time 99.999518
Common Node 10 - Disseminating data - Time 100.000
- There is 11 data aggregated.
ns: finish: can't read "namtraceAllFile_": no such variable
while executing
"if {$namtraceAllFile_ != ""} {
$self puts-nam-config "W -t $stoptime"
}"
(procedure "_o3" line 4)
(Simulator nam-end-wireless line 4)
invoked from within
"$ns_ nam-end-wireless $val(stop)"
(procedure "finish" line 8)
invoked from within
"finish"
Tell me the procedure to Remove This Error?? Why it is coming??
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.