[Tinyos-help] Different results from one simulation to an other
Nahr ...
nahrelk at gmail.com
Thu Jul 10 01:08:34 PDT 2008
Hi,
thank you very much professor Philip,
I am running simulation for one hour:
while (t.time() < 3600 * t.ticksPerSecond()):
t.runNextEvent()
As I know I should run simulation several times to have accurate results.
so have you,please, a solution to get around this problem.
2008/7/10 Philip Levis <pal at cs.stanford.edu>:
>
> On Jul 9, 2008, at 12:35 PM, Nahr ... wrote:
>
>
>>
>> Hi all,
>>
>> I found a very astonishing thing in Tossim simulator because I got
>> extremely different result from one simulation to an other.
>> In the first simulation I get the packet delivery rate = ~ 0.9
>> in the second I get the packet delivery rate = 0 !!!!!!!!!!!!!!
>> I found that it is illogical result.
>>
>> I am using this code to turn mote aff and restart the second simulation:
>>
>> for simul in range(1,(nbrsimulation + 1)):
>> t = Tossim([])
>> r = t.radio()
>> numnodes = 2
>> for i in range(0, numnodes):
>> m = t.getNode(i);
>> time = randint(t.ticksPerSecond(), 10 * t.ticksPerSecond())
>> m.bootAtTime(time)
>>
>> ******************************
>> ******************************
>>
>> *******ADDing**************
>> *******GAIN &**************
>> *******Noise****************
>>
>> ******************************
>> ******************************
>> for i in range(0, numnodes):
>> m = t.getNode(i);
>> m.turnOff()
>>
>>
>>
>> Could someone explain to me why?
>>
>
> Maybe in the second simulation one of the nodes never turned on (due to the
> random start time), or turned on just before turning off?
>
> Without knowing how long the simulation ran, it's hard to tell.
>
> Phil
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://www.millennium.berkeley.edu/pipermail/tinyos-help/attachments/20080710/c7d1beb2/attachment.htm
More information about the Tinyos-help
mailing list