[Ns-developers] emulation use cases
craigdo@ee.washington.edu
craigdo at ee.washington.edu
Thu Feb 12 12:07:36 PST 2009
> For example, if a routing
> protocol's core logic is too slow to keep up with load, that will show
> up in live and distributed emulation tests. It won't show up in
> simulation because there is essentially infinite processing time
> between events.
It can show up in a real-time simulation, though. This is something I tried
to address with the real-time simulator implementation.
If you turn on the real-time simulator,
GlobalValue::Bind ("SimulatorImplementationType",
StringValue ("ns3::RealtimeSimulatorImpl"));
you then have the ability to get at the real time during your processing;
and can see how much real time is consumed
Time tStart = Simulator::GetImplementation ())->RealtimeNow ();
...
Time tConsumed = Simulator::GetImplementation ())->RealtimeNow () -
tStart;
and trace or log that info.
You can also set the "SynchronizationMode" Attribute to "HardLimit" and also
set the "HardLimit" Attribute to some maximum acceptable time. You will
then error out if your simulation time gets further behind real-lime than
the limit.
Regards,
-- Craig
More information about the Ns-developers
mailing list