added very simple sky ipv6 test: exercises the examples/udp-sender-ipv6 and examples/udp-receiver-ipv6 code

This commit is contained in:
fros4943 2009-02-25 12:14:19 +00:00
parent 90767a76b3
commit f6b8fdc2a8
3 changed files with 122 additions and 0 deletions

View File

@ -0,0 +1,100 @@
<?xml version="1.0" encoding="UTF-8"?>
<simconf>
<simulation>
<title>My simulation</title>
<delaytime>0</delaytime>
<ticktime>1</ticktime>
<randomseed>123457</randomseed>
<motedelay>1000</motedelay>
<radiomedium>
se.sics.cooja.radiomediums.UDGM
<transmitting_range>50.0</transmitting_range>
<interference_range>100.0</interference_range>
<success_ratio_tx>1.0</success_ratio_tx>
<success_ratio_rx>1.0</success_ratio_rx>
</radiomedium>
<motetype>
se.sics.cooja.mspmote.SkyMoteType
<identifier>sky1</identifier>
<description>Sky Mote Type #1</description>
<source>../../../examples/udp-sender-ipv6/example-udp-sender.c</source>
<command>make example-udp-sender.sky TARGET=sky DEFINES=WITH_UIP6,WITH_NULLMAC,UDP_ADDR_A=0xfe80,UDP_ADDR_B=0,UDP_ADDR_C=0,UDP_ADDR_D=0,UDP_ADDR_E=0x0212,UDP_ADDR_F=0x7502,UDP_ADDR_G=0x02,UDP_ADDR_H=0x202</command>
</motetype>
<motetype>
se.sics.cooja.mspmote.SkyMoteType
<identifier>sky2</identifier>
<description>Sky Mote Type #2</description>
<source>../../../examples/udp-receiver-ipv6/example-udp-receiver.c</source>
<command>make example-udp-receiver.sky TARGET=sky DEFINES=WITH_UIP6,WITH_NULLMAC,UDP_ADDR_A=0xfe80,UDP_ADDR_B=0,UDP_ADDR_C=0,UDP_ADDR_D=0,UDP_ADDR_E=0x0212,UDP_ADDR_F=0x7501,UDP_ADDR_G=0x01,UDP_ADDR_H=0x101</command>
</motetype>
<mote>
se.sics.cooja.mspmote.SkyMote
<motetype_identifier>sky1</motetype_identifier>
<interface_config>
se.sics.cooja.interfaces.Position
<x>65.934608127183</x>
<y>63.70462190529231</y>
<z>0.0</z>
</interface_config>
<interface_config>
se.sics.cooja.mspmote.interfaces.MspMoteID
<id>1</id>
</interface_config>
</mote>
<mote>
se.sics.cooja.mspmote.SkyMote
<motetype_identifier>sky2</motetype_identifier>
<interface_config>
se.sics.cooja.interfaces.Position
<x>67.66105781539623</x>
<y>63.13924301161143</y>
<z>0.0</z>
</interface_config>
<interface_config>
se.sics.cooja.mspmote.interfaces.MspMoteID
<id>2</id>
</interface_config>
</mote>
</simulation>
<plugin>
se.sics.cooja.plugins.SimControl
<width>248</width>
<z>1</z>
<height>200</height>
<location_x>0</location_x>
<location_y>0</location_y>
<minimized>false</minimized>
</plugin>
<plugin>
se.sics.cooja.plugins.LogListener
<plugin_config>
<filter />
<history>256</history>
</plugin_config>
<width>1067</width>
<z>2</z>
<height>300</height>
<location_x>0</location_x>
<location_y>523</location_y>
<minimized>false</minimized>
</plugin>
<plugin>
se.sics.cooja.plugins.RadioLogger
<width>1062</width>
<z>4</z>
<height>309</height>
<location_x>6</location_x>
<location_y>207</location_y>
<minimized>false</minimized>
</plugin>
<plugin>
se.sics.cooja.plugins.VisUDGM
<width>300</width>
<z>3</z>
<height>108</height>
<location_x>766</location_x>
<location_y>11</location_y>
<minimized>false</minimized>
</plugin>
</simconf>

View File

@ -0,0 +1 @@
Two Sky nodes: examples/udp-receiver-ipv6/example-udp-receiver.c and examples/udp-sender-ipv6/example-udp-sender.c. Test success after 5 replies

View File

@ -0,0 +1,21 @@
TIMEOUT(100000, log.log("last msg: " + msg + "\n")); /* print last msg at timeout */
WAIT_UNTIL(msg.contains("Created connection"));
YIELD_THEN_WAIT_UNTIL(msg.contains("Created connection"));
log.log("Both nodes booted\n");
count = 0;
while (count++ < 5) {
/* Message from sender process to receiver process */
YIELD_THEN_WAIT_UNTIL(msg.contains("Sender sending"));
YIELD_THEN_WAIT_UNTIL(msg.contains("Receiver received"));
log.log(count + ": Sender -> Receiver OK\n");
/* Message from receiver process to sender process */
YIELD_THEN_WAIT_UNTIL(msg.contains("Receiver sending"));
YIELD_THEN_WAIT_UNTIL(msg.contains("Sender received"));
log.log(count + ": Receiver -> Sender OK\n");
}
log.testOK(); /* Report test success and quit */