Dear Sajad, I think you need to link an otcl file with your c files in order for ns to recognize it. Tcl scripting doesn't directly respond to c code. It has to be implemented through otcl. ------------------
-----Original Message----- From: ns-users-requ...@isi.edu Sender: ns-users-boun...@isi.edu Date: Fri, 06 Aug 2010 17:00:19 To: <ns-users@ISI.EDU> Reply-To: ns-users@ISI.EDU Subject: Ns-users Digest, Vol 80, Issue 6 Send Ns-users mailing list submissions to ns-users@isi.edu To subscribe or unsubscribe via the World Wide Web, visit http://mailman.isi.edu/mailman/listinfo/ns-users or, via email, send a message with subject or body 'help' to ns-users-requ...@isi.edu You can reach the person managing the list at ns-users-ow...@isi.edu When replying, please edit your Subject line so it is more specific than "Re: Contents of Ns-users digest..." Today's Topics: 1. Running a new routing algorithm (sajad m) 2. Problem using DSR in ns 2.34 and few general queries (visq) 3. Re: Exclamation Problem with nam in ns-2.34 (Shirley ?) 4. Re: Exclamation Problem with nam in ns-2.34 (Shirley ?) ---------------------------------------------------------------------- Message: 1 Date: Fri, 6 Aug 2010 01:06:32 -0700 (PDT) From: sajad m <sajadm1...@yahoo.com> Subject: [ns] Running a new routing algorithm To: ns-users@isi.edu Message-ID: <509422.84428...@web45605.mail.sp1.yahoo.com> Content-Type: text/plain; charset=iso-8859-1 I'm trying to implement a new routing algorithm,saying SM; I've written scripts in 4 files: sm.cc , sm.h, and roting table?smtb.cc, smtb.h.?Then I added some?necessary line to ns.lib and?installed ns again successfully. But when I tried to run a simulation with rt(value)?SM. it showed some errors. Moreover in the directory SM there's no sm.o!! ? whats the solution to run my routing algorithm? ------------------------------ Message: 2 Date: Fri, 6 Aug 2010 03:36:15 -0700 (PDT) From: visq <vamsikrishnagr...@gmail.com> Subject: [ns] Problem using DSR in ns 2.34 and few general queries To: ns-users@isi.edu Message-ID: <29356436.p...@talk.nabble.com> Content-Type: text/plain; charset=us-ascii Sir, I have the following problem testing a scenario using DSR protocol in ns 2.34. 1) It gives segmentation error . How to solve this problem? It worked fine with AODV and DSDV. 2)simulation time . when i specified that $ns at 2.0 "$cbr0 start" $ns at 6.0 "$cbr0 stop" In simulation the start time and stop time are different. and in not in accordance with tcl script. 3)Regarding the throughput calculation, Suppose I am sending a tcp packet of 1500 bytes at 1.00 and the packet is received at 1.35 what is throughput in this case ? Is throughput calculated at sender side or receiver side? And what is throughput in case of multiple flows or multiple senders? is throughput defined for each sender? or a network on a whole? 4) Regarding the trace format :- what does this trace indicate? Sconfig 0.00000 tap: on snoop: rts? on errs? on Sconfig 0.00000 salvage: on !bd replies? on Sconfig 0.00000 grat error: on grat reply: on Sconfig 0.00000 $reply for props: on ring 0 search: on Sconfig 0.00000 using MOBICACHE s 2.000000000 _11_ AGT --- 0 tcp 1500 [0 0 0 0] ------- [11:0 36:0 32 0] [0 0] 0 0 r 2.000000000 _11_ RTR --- 0 tcp 1500 [0 0 0 0] ------- [11:0 36:0 32 0] [0 0] 0 0 s 2.007477689 _11_ RTR --- 1 DSR 32 [0 0 0 0] ------- [11:255 36:255 32 0] 1 [1 1] [0 1 0 0->0] [0 0 0 0->0] -- View this message in context: http://old.nabble.com/Problem-using-DSR-in-ns-2.34-and-few-general-queries-tp29356436p29356436.html Sent from the ns-users mailing list archive at Nabble.com. ------------------------------ Message: 3 Date: Fri, 6 Aug 2010 07:34:06 -0700 (PDT) From: Shirley ? <lily.shir...@gmail.com> Subject: Re: [ns] Exclamation Problem with nam in ns-2.34 To: ns-users@isi.edu Message-ID: <29356457.p...@talk.nabble.com> Content-Type: text/plain; charset=us-ascii modify the file of tk-8.4.*/generic/tbBind.c pls add #ifdef GenericEvent /* GenericEvent */ 0, #endif below the line of 588 save the file reinstall ns2 dreams2010 wrote: > > Hello, my OS is F12 with Gnome desktop, after many alternatives i > installed ns-allinone-2.34 so ns-2.34 run very well: > [dre...@localhost ~]$ ns > % exit > > When i try nam, i got this error: > [dre...@localhost ~]$ nam > nam: > [code omitted because of length] > : no event type or button # or keysym > while executing > "bind Listbox <MouseWheel> { > %W yview scroll [expr {- (%D / 120) * 4}] units > }" > invoked from within > "if {[tk windowingsystem] eq "classic" || [tk windowingsystem] eq "aqua"} > { > bind Listbox <MouseWheel> { > %W yview scroll [expr {- (%D)}] units > } > bind Li..." > > I m not familiar with Linux so i don't understand what it means. > I want to tell you that i can run nam when i acces to the folder with this > command ./nam and i can see the samples so i run simulation. > I visit some pages when they speak about gcc and their compatibilities > with F12. > > When i use Makefile i got access dined. > > i tried this solution (from fedora Forum): 2 patchs: tkBind and lastevent > but they failed > > [dre...@localhost ~]$ cd ns-allinone-2.34/tk8.4.18 > [dre...@localhost tk8.4.18]$ patch -p0 < tk-8.4-lastevent.patch > patching file generic/tk.h > Hunk #1 FAILED at 635. > 1 out of 1 hunk FAILED -- saving rejects to file generic/tk.h.rej > > what does it means? > > I m very stupid , i wait for your help to continue my work. > I m sorry because this msg isn't short i tried to clarify my problem. > > Thank you for your answers. > -- View this message in context: http://old.nabble.com/Exclamation--Problem-with-nam-in-ns-2.34-tp29356452p29356457.html Sent from the ns-users mailing list archive at Nabble.com. ------------------------------ Message: 4 Date: Fri, 6 Aug 2010 12:23:02 -0700 (PDT) From: Shirley ? <lily.shir...@gmail.com> Subject: Re: [ns] Exclamation Problem with nam in ns-2.34 To: ns-users@isi.edu Message-ID: <29356483.p...@talk.nabble.com> Content-Type: text/plain; charset=UTF-8 I met this problem under ns2.29 and ns2.30, and resolved it through the way I told you. but I did not met this problem under ns2.34. dreams2010 wrote: > > Think you for reply > i have the lines mentioned below line 588 and i reinstalled many time but > the prob is the same. > > > Shirley ? wrote: >> >> modify the file of tk-8.4.*/generic/tbBind.c >> pls add >> >> #ifdef GenericEvent >> /* GenericEvent */ 0, >> #endif >> >> below the line of 588 >> >> save the file >> >> reinstall ns2 >> >> dreams2010 wrote: >>> >>> Hello, my OS is F12 with Gnome desktop, after many alternatives i >>> installed ns-allinone-2.34 so ns-2.34 run very well: >>> [dre...@localhost ~]$ ns >>> % exit >>> >>> When i try nam, i got this error: >>> [dre...@localhost ~]$ nam >>> nam: >>> [code omitted because of length] >>> : no event type or button # or keysym >>> while executing >>> "bind Listbox <MouseWheel> { >>> %W yview scroll [expr {- (%D / 120) * 4}] units >>> }" >>> invoked from within >>> "if {[tk windowingsystem] eq "classic" || [tk windowingsystem] eq >>> "aqua"} { >>> bind Listbox <MouseWheel> { >>> %W yview scroll [expr {- (%D)}] units >>> } >>> bind Li..." >>> >>> I m not familiar with Linux so i don't understand what it means. >>> I want to tell you that i can run nam when i acces to the folder with >>> this command ./nam and i can see the samples so i run simulation. >>> I visit some pages when they speak about gcc and their compatibilities >>> with F12. >>> >>> When i use Makefile i got access dined. >>> >>> i tried this solution (from fedora Forum): 2 patchs: tkBind and >>> lastevent but they failed >>> >>> [dre...@localhost ~]$ cd ns-allinone-2.34/tk8.4.18 >>> [dre...@localhost tk8.4.18]$ patch -p0 < tk-8.4-lastevent.patch >>> patching file generic/tk.h >>> Hunk #1 FAILED at 635. >>> 1 out of 1 hunk FAILED -- saving rejects to file generic/tk.h.rej >>> >>> what does it means? >>> >>> I m very stupid , i wait for your help to continue my work. >>> I m sorry because this msg isn't short i tried to clarify my problem. >>> >>> Thank you for your answers. >>> >> >> > > -- View this message in context: http://old.nabble.com/Exclamation--Problem-with-nam-in-ns-2.34-tp29356452p29356483.html Sent from the ns-users mailing list archive at Nabble.com. ------------------------------ _______________________________________________ Ns-users mailing list Ns-users@isi.edu http://mailman.isi.edu/mailman/listinfo/ns-users End of Ns-users Digest, Vol 80, Issue 6 ***************************************