130 lines
3.3 KiB
XML
130 lines
3.3 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!DOCTYPE nta PUBLIC '-//Uppaal Team//DTD Flat System 1.1//EN' 'http://www.it.uu.se/research/group/darts/uppaal/flat-1_2.dtd'>
|
|
<nta>
|
|
<declaration>urgent chan SendSR, SendRS;
|
|
chan RcvSR, RcvRS;
|
|
</declaration>
|
|
<template>
|
|
<name x="5" y="5">Sender</name>
|
|
<declaration>
|
|
</declaration>
|
|
<location id="id0" x="-1156" y="-1216">
|
|
<name x="-1139" y="-1215">Wait</name>
|
|
</location>
|
|
<location id="id1" x="-1326" y="-1377">
|
|
<name x="-1394" y="-1385">Send</name>
|
|
</location>
|
|
<init ref="id1"/>
|
|
<transition>
|
|
<source ref="id0"/>
|
|
<target ref="id1"/>
|
|
<label kind="synchronisation" x="-1385" y="-1258">RcvRS!</label>
|
|
<nail x="-1300" y="-1232"/>
|
|
</transition>
|
|
<transition>
|
|
<source ref="id1"/>
|
|
<target ref="id0"/>
|
|
<label kind="synchronisation" x="-1139" y="-1326">SendSR!</label>
|
|
<nail x="-1224" y="-1368"/>
|
|
<nail x="-1164" y="-1326"/>
|
|
</transition>
|
|
</template>
|
|
<template>
|
|
<name>link</name>
|
|
<location id="id2" x="-102" y="-297">
|
|
<name x="-85" y="-314">TransmitRS</name>
|
|
</location>
|
|
<location id="id3" x="42" y="-374">
|
|
<name x="17" y="-357">Wait</name>
|
|
</location>
|
|
<location id="id4" x="110" y="-476">
|
|
<name x="127" y="-484">transmitSR</name>
|
|
</location>
|
|
<init ref="id3"/>
|
|
<transition>
|
|
<source ref="id2"/>
|
|
<target ref="id3"/>
|
|
<label kind="synchronisation" x="-136" y="-374">RcvRS?</label>
|
|
<nail x="-85" y="-374"/>
|
|
</transition>
|
|
<transition>
|
|
<source ref="id3"/>
|
|
<target ref="id2"/>
|
|
<label kind="synchronisation" x="68" y="-306">SendRS?</label>
|
|
<nail x="85" y="-357"/>
|
|
<nail x="76" y="-340"/>
|
|
<nail x="51" y="-255"/>
|
|
</transition>
|
|
<transition>
|
|
<source ref="id4"/>
|
|
<target ref="id3"/>
|
|
<label kind="synchronisation" x="-44" y="-467">RcvSR?</label>
|
|
<nail x="-1" y="-442"/>
|
|
</transition>
|
|
<transition>
|
|
<source ref="id3"/>
|
|
<target ref="id4"/>
|
|
<label kind="synchronisation" x="161" y="-450">SendSR?</label>
|
|
<nail x="195" y="-408"/>
|
|
<nail x="131" y="-455"/>
|
|
</transition>
|
|
</template>
|
|
<template>
|
|
<name>Receiver</name>
|
|
<location id="id5" x="170" y="-85">
|
|
<name x="187" y="-84">Send</name>
|
|
</location>
|
|
<location id="id6" x="9" y="-237">
|
|
<name x="-67" y="-246">Wait</name>
|
|
</location>
|
|
<init ref="id6"/>
|
|
<transition>
|
|
<source ref="id5"/>
|
|
<target ref="id6"/>
|
|
<label kind="synchronisation" x="-59" y="-127">SendRS!</label>
|
|
<nail x="26" y="-101"/>
|
|
</transition>
|
|
<transition>
|
|
<source ref="id6"/>
|
|
<target ref="id5"/>
|
|
<label kind="synchronisation" x="187" y="-195">RcvSR!</label>
|
|
<nail x="102" y="-237"/>
|
|
<nail x="162" y="-195"/>
|
|
</transition>
|
|
</template>
|
|
<system>mittente=Sender();
|
|
destinatario=Receiver();
|
|
canale = link();
|
|
|
|
|
|
|
|
system mittente,destinatario,canale;
|
|
|
|
</system>
|
|
<queries>
|
|
<query>
|
|
<formula>E<> destinatario.Send
|
|
</formula>
|
|
<comment>
|
|
</comment>
|
|
</query>
|
|
<query>
|
|
<formula>(mittente.Wait && x==0) --> (destinatario.Send && x <=50)
|
|
</formula>
|
|
<comment>
|
|
</comment>
|
|
</query>
|
|
<query>
|
|
<formula>mittente.Wait --> destinatario.Send
|
|
</formula>
|
|
<comment>
|
|
</comment>
|
|
</query>
|
|
<query>
|
|
<formula>A[] !(deadlock)
|
|
</formula>
|
|
<comment>
|
|
</comment>
|
|
</query>
|
|
</queries>
|
|
</nta>
|