3. Enabling Synchronization

The next step is that the 2 entities should do something at the same time beside the things that they do independently. The model in MoDeST is as follows:


01 action do_something,also_do_something,common_action;

02 process coordinator()
03 {
04 do{
05   ::do_something; common_action;do_something
06   }
07 }

08 process station()
09 {
10 do{
11   ::also_do_something; common_action; also_do_something
12   }
13 }

14 par{
15    ::coordinator()
16    ::station()
17 }

Download the model


The processes coordinator() and station() are active, hence they synchronize on the action common_action. This means that this action is executed if both processes have executed the actions before and both are ready to execute the common action.

The identification of common actions is done purely synctactical. We can choose arbitrary names for common actions (e.g. a, b, ...).



back to start

back to 2.First Simplified Model

forward to 4. Introduction of Time