Categories

WaDeD simulation

Here is the first results of the WaDeD environment simulator. Until now it has only be usefull to test and debug the  memory function in a more realistic environment than just battery tests. But here is some result of the WaDeD environment working.

What the simulator does:

  • It simulates some fix WaDeD placed in a grid, far enough not to communicate with each other
  • It simulates one WaDeD moving in this environment.
  • It uses as much as possible the same code as the embedded one.

What the simulator does not yet:

  • It does not simulate the “jungle protocol”, meaning how the WaDeD will synchronize with each other. For now, the synchronization is just a lot of dumb insertions in the Merkel trees.

So what happens in this simulation, is that all WaDeD start with one message of its own, different for each. And then the moving WaDeD goes from the top left to the bottom right, in diagonal.

The result expected is that the moving WaDeD will gather all the messages from the fix WaDeD close to the diagonal, and that this WaDeD will have a portion of this gathering, more and more important as we go down and left.

And this is exactly what we get! So all the bugs are resolved and all is working for now.

Here is the output for a 16×16 grid. The moving WaDeD start with the test message (hash a94a8fe5ccb19ba6) and the fixes with “message from (i, j)” (hash 0x0001000000000000 * i + 0x0000000100000000 * j).

a94a8fe5ccb19ba6: test
0: message from (0, 0)
500000000: message from (0, 5)
5000000000000: message from (5, 0)
5000500000000: message from (5, 5)
5000a00000000: message from (5, 10)
a000500000000: message from (10, 5)
a000a00000000: message from (10, 10)
a000f00000000: message from (10, 15)
f000a00000000: message from (15, 10)
f000f00000000: message from (15, 15)

—–
Stone in (0, 0):
0: message from (0, 0)
a94a8fe5ccb19ba6: test
500000000: message from (0, 5)
5000000000000: message from (5, 0)
5000500000000: message from (5, 5)
—–
Stone in (0, 5):
500000000: message from (0, 5)
a94a8fe5ccb19ba6: test
0: message from (0, 0)
5000000000000: message from (5, 0)
5000500000000: message from (5, 5)
—–
Stone in (0, 10):
a00000000: message from (0, 10)
—–
Stone in (0, 15):
f00000000: message from (0, 15)
—–
Stone in (5, 0):
5000000000000: message from (5, 0)
a94a8fe5ccb19ba6: test
0: message from (0, 0)
500000000: message from (0, 5)
5000500000000: message from (5, 5)
—–
Stone in (5, 5):
5000500000000: message from (5, 5)
a94a8fe5ccb19ba6: test
0: message from (0, 0)
500000000: message from (0, 5)
5000000000000: message from (5, 0)
5000a00000000: message from (5, 10)
a000500000000: message from (10, 5)
a000a00000000: message from (10, 10)
—–
Stone in (5, 10):
5000a00000000: message from (5, 10)
a94a8fe5ccb19ba6: test
0: message from (0, 0)
500000000: message from (0, 5)
5000000000000: message from (5, 0)
5000500000000: message from (5, 5)
a000500000000: message from (10, 5)
a000a00000000: message from (10, 10)
—–
Stone in (5, 15):
5000f00000000: message from (5, 15)
—–
Stone in (10, 0):
a000000000000: message from (10, 0)
—–
Stone in (10, 5):
a000500000000: message from (10, 5)
a94a8fe5ccb19ba6: test
0: message from (0, 0)
500000000: message from (0, 5)
5000000000000: message from (5, 0)
5000500000000: message from (5, 5)
5000a00000000: message from (5, 10)
a000a00000000: message from (10, 10)
—–
Stone in (10, 10):
a000a00000000: message from (10, 10)
a94a8fe5ccb19ba6: test
0: message from (0, 0)
500000000: message from (0, 5)
5000000000000: message from (5, 0)
5000500000000: message from (5, 5)
5000a00000000: message from (5, 10)
a000500000000: message from (10, 5)
a000f00000000: message from (10, 15)
f000a00000000: message from (15, 10)
f000f00000000: message from (15, 15)
—–
Stone in (10, 15):
a000f00000000: message from (10, 15)
a94a8fe5ccb19ba6: test
0: message from (0, 0)
500000000: message from (0, 5)
5000000000000: message from (5, 0)
5000500000000: message from (5, 5)
5000a00000000: message from (5, 10)
a000500000000: message from (10, 5)
a000a00000000: message from (10, 10)
f000a00000000: message from (15, 10)
f000f00000000: message from (15, 15)
—–
Stone in (15, 0):
f000000000000: message from (15, 0)
—–
Stone in (15, 5):
f000500000000: message from (15, 5)
—–
Stone in (15, 10):
f000a00000000: message from (15, 10)
a94a8fe5ccb19ba6: test
0: message from (0, 0)
500000000: message from (0, 5)
5000000000000: message from (5, 0)
5000500000000: message from (5, 5)
5000a00000000: message from (5, 10)
a000500000000: message from (10, 5)
a000a00000000: message from (10, 10)
a000f00000000: message from (10, 15)
f000f00000000: message from (15, 15)
—–
Stone in (15, 15):
f000f00000000: message from (15, 15)
a94a8fe5ccb19ba6: test
0: message from (0, 0)
500000000: message from (0, 5)
5000000000000: message from (5, 0)
5000500000000: message from (5, 5)
5000a00000000: message from (5, 10)
a000500000000: message from (10, 5)
a000a00000000: message from (10, 10)
a000f00000000: message from (10, 15)
f000a00000000: message from (15, 10)

Sacha Delanoue

Facebook Twitter Google+ 

Commentaires fermés.