User Tools

Site Tools


Two Sequences with Timeout Monitor

In the EEROS library you will find a directory with examples. Open a shell in the build directory of your EEROS library and run examples/sequencer/SequencerTest2.

Flow of SequencerTest2

The main sequences starts with three Step A after which the Sequence B is called. Sequence B is nonblocking, that means, it will run in parallel. Step A and Step B will be called in parallel, though their waiting time is different. Sequence B has its timeout condition set to 2.5s. This causes its associated timeout monitor to interrupt the sequence and jump to an exception sequence. In the meantime the main sequence continues unhindered. After the exception sequence Sequence B is aborted. The program stops after the main sequences has finished running its steps.

A next example demonstrates what happens if the caller of a sequence is interrupted by a monitor.

Flow of SequencerTest3

The main sequence simply starts Sequence A which is called blocking. Sequence A has its timeout set to 3.5s. It does two Step A (each of them waits for a second) and then calls Sequence B which itself does several Step B. After Sequence B has started Sequence A times out. Its timeout monitor has no associated exception behavior. Hence, as the monitor has its sequence property set to abort, Sequence A will stop immediately. Sequence B will obviously stop as well. The main sequence has no further work to do and will reach its end.

getting_started/tutorials/sequencer2.txt · Last modified: 2017/09/19 16:15 by graf