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

Re: [ns] How to halt and then resume the scheduler ?



Thank you very much for answer.

I would like to halt and resume the scheduler because I want to interfere into the event scheduler. The thing I want is reconfiguration the network topology dynamically (i.e while ns executes the script).
However now, I have found the solution to do that, no need to halt and resume the scheduler anymore.

I have tried 
 $ns_ at <timeA> "[$ns_ set scheduler_] halt"
but it seems that it have the same effect as $ns halt.
The event scheduler terminated and I can not resume it. I think the event "halt" means "stop", not "pause".

Best regard,
Tuan

>>> Dan Iregren <[email protected]> 08/20/01 09:21am >>>
> I would like to halt the running scheduler and then resume it but I could
> not.

Why would you want to do that?


> If I insert the following lines into the tcl :
>
> $ns_  halt
> $ns_  resume

Try 

$ns_ at <timeA> "[$ns_ set scheduler_] halt"
$ns_ at <timeB> "[$ns_ set scheduler_] resume"

> NS says that unable to dispatch method resume -> I searched in the file
> ns-lib.tcl, there is no procedure named resume.  Question : this function
> has not implemeted yet ?

The command function in scheduler.cc implements a resume "method".

/Dan