MODULE sender(ack) VAR st : {sending,sent}; message1 : boolean; message2 : boolean; ASSIGN init(st) := sending; next(st) := case ack = message2 & !(st=sent) : sent; 1 : sending; esac; next(message1) := case st = sent : {0,1}; 1 : message1; esac; next(message2) := case st = sent : !message2; 1 : message2; esac; FAIRNESS running LTLSPEC G F st=sent MODULE receiver(message1,message2) VAR st : {receiving,received}; ack : boolean; expected : boolean; ASSIGN init(st) := receiving; next(st) := case message2=expected & !(st=received) : received; 1 : receiving; esac; next(ack) := case st = received : message2; 1 : ack; esac; next(expected) := case st = received : !expected; 1 : expected; esac; FAIRNESS running LTLSPEC G F st=received MODULE one-bit-chan(input) VAR output : boolean; forget : boolean; ASSIGN next(output) := case forget : output; 1 : input; esac; FAIRNESS running FAIRNESS input & !forget FAIRNESS input & !forget MODULE two-bit-chan(input1,input2) VAR forget : boolean; output1 : boolean; output2 : boolean; ASSIGN next(output1) := case forget : output1; 1: input1; esac; next(output2) := case forget : output2; 1: input2; esac; FAIRNESS running FAIRNESS input1 & !forget FAIRNESS !input1 & !forget FAIRNESS input2 & !forget FAIRNESS !input2 & !forget MODULE main VAR s : process sender(ack_chan.output); r : process receiver(msg_chan.output1,msg_chan.output2); msg_chan : process two-bit-chan(s.message1,s.message2); ack_chan : process one-bit-chan(r.ack); ASSIGN init(s.message2) := 0; init(r.expected) := 0; init(r.ack) := 1; init(msg_chan.output2) := 1; init(ack_chan.output) := 1; LTLSPEC G (s.st=sent & s.message1=1 -> msg_chan.output1=1)