moved test scripts into simulation config (.csc)
This commit is contained in:
parent
28a9b815b5
commit
2a5781566f
52 changed files with 2285 additions and 2072 deletions
|
@ -2,13 +2,13 @@
|
|||
<simconf>
|
||||
<project>../apps/mrm</project>
|
||||
<project>../apps/mspsim</project>
|
||||
<project>../apps/avrora</project>
|
||||
<project>../apps/native_gateway</project>
|
||||
<simulation>
|
||||
<title>My simulation</title>
|
||||
<delaytime>0</delaytime>
|
||||
<ticktime>1</ticktime>
|
||||
<randomseed>123456</randomseed>
|
||||
<motedelay>1000</motedelay>
|
||||
<randomseed>generated</randomseed>
|
||||
<motedelay_us>1000000</motedelay_us>
|
||||
<radiomedium>
|
||||
se.sics.cooja.radiomediums.UDGM
|
||||
<transmitting_range>50.0</transmitting_range>
|
||||
|
@ -24,7 +24,7 @@
|
|||
<commands>make multi-threading.sky TARGET=sky</commands>
|
||||
<firmware>../../../examples/multi-threading/multi-threading.sky</firmware>
|
||||
<moteinterface>se.sics.cooja.interfaces.Position</moteinterface>
|
||||
<moteinterface>se.sics.cooja.mspmote.interfaces.MspIPAddress</moteinterface>
|
||||
<moteinterface>se.sics.cooja.interfaces.IPAddress</moteinterface>
|
||||
<moteinterface>se.sics.cooja.interfaces.Mote2MoteRelations</moteinterface>
|
||||
<moteinterface>se.sics.cooja.mspmote.interfaces.MspClock</moteinterface>
|
||||
<moteinterface>se.sics.cooja.mspmote.interfaces.MspMoteID</moteinterface>
|
||||
|
@ -37,6 +37,7 @@
|
|||
<mote>
|
||||
se.sics.cooja.mspmote.SkyMote
|
||||
<motetype_identifier>sky1</motetype_identifier>
|
||||
<breakpoints />
|
||||
<interface_config>
|
||||
se.sics.cooja.interfaces.Position
|
||||
<x>83.20518861404864</x>
|
||||
|
@ -52,32 +53,81 @@
|
|||
<plugin>
|
||||
se.sics.cooja.plugins.SimControl
|
||||
<width>265</width>
|
||||
<z>1</z>
|
||||
<z>3</z>
|
||||
<height>200</height>
|
||||
<location_x>0</location_x>
|
||||
<location_y>0</location_y>
|
||||
<minimized>false</minimized>
|
||||
</plugin>
|
||||
<plugin>
|
||||
se.sics.cooja.plugins.VisState
|
||||
<width>300</width>
|
||||
<z>0</z>
|
||||
<height>300</height>
|
||||
<location_x>638</location_x>
|
||||
<location_y>0</location_y>
|
||||
se.sics.cooja.plugins.Visualizer
|
||||
<plugin_config />
|
||||
<width>263</width>
|
||||
<z>2</z>
|
||||
<height>292</height>
|
||||
<location_x>1</location_x>
|
||||
<location_y>202</location_y>
|
||||
<minimized>false</minimized>
|
||||
</plugin>
|
||||
<plugin>
|
||||
se.sics.cooja.plugins.LogListener
|
||||
<plugin_config>
|
||||
<filter />
|
||||
<history>256</history>
|
||||
</plugin_config>
|
||||
<width>938</width>
|
||||
<z>2</z>
|
||||
<width>865</width>
|
||||
<z>0</z>
|
||||
<height>209</height>
|
||||
<location_x>1</location_x>
|
||||
<location_y>746</location_y>
|
||||
<location_x>3</location_x>
|
||||
<location_y>701</location_y>
|
||||
<minimized>false</minimized>
|
||||
</plugin>
|
||||
<plugin>
|
||||
se.sics.cooja.plugins.ScriptRunner
|
||||
<plugin_config>
|
||||
<script>TIMEOUT(60000, log.log("nrLowAlpha: " + nrLowAlpha + "\nnrHighAlpha: " + nrHighAlpha + "\nnrLowCount: " + nrLowCount + "\nnrHighCount: " + nrHighCount + "\n"));
|
||||
|
||||
lowAlpha = "BA";
|
||||
highAlpha = "JIHGFEDCBA";
|
||||
lowCount = "10";
|
||||
highCount = "9876543210";
|
||||
|
||||
nrLowAlpha = 0;
|
||||
nrHighAlpha = 0;
|
||||
nrLowCount = 0;
|
||||
nrHighCount = 0;
|
||||
|
||||
while (true) {
|
||||
|
||||
if (msg.equals(lowCount)) {
|
||||
//log.log("Count is low\n");
|
||||
nrLowCount++;
|
||||
} else if (msg.equals(lowAlpha)) {
|
||||
//log.log("Alpha is low\n");
|
||||
nrLowAlpha++;
|
||||
} else if (msg.equals(highCount)) {
|
||||
//log.log("Count is high\n");
|
||||
nrHighCount++;
|
||||
} else if (msg.equals(highAlpha)) {
|
||||
//log.log("Alpha is high\n");
|
||||
nrHighAlpha++;
|
||||
}
|
||||
|
||||
if (nrLowCount >= 5 &&
|
||||
nrLowAlpha >= 5 &&
|
||||
nrLowCount >= 5 &&
|
||||
nrHighCount >= 5 &&
|
||||
nrHighAlpha >= 5) {
|
||||
log.testOK();
|
||||
}
|
||||
YIELD();
|
||||
}</script>
|
||||
<active>true</active>
|
||||
</plugin_config>
|
||||
<width>600</width>
|
||||
<z>1</z>
|
||||
<height>700</height>
|
||||
<location_x>267</location_x>
|
||||
<location_y>1</location_y>
|
||||
<minimized>false</minimized>
|
||||
</plugin>
|
||||
</simconf>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue