| Name | Modified | Size | Downloads / Week |
|---|---|---|---|
| Parent folder | |||
| Main.cpp | 2023-02-20 | 4.2 kB | |
| README.txt | 2023-02-20 | 317 Bytes | |
| stoplight.cpp | 2023-02-20 | 4.2 kB | |
| stoplight.h | 2023-02-20 | 4.4 kB | |
| stoplight.sm | 2023-02-20 | 2.3 kB | |
| stoplightdefs.h | 2023-02-20 | 1.5 kB | |
| Makefile | 2023-02-20 | 3.3 kB | |
| Totals: 7 Items | 20.2 kB | 0 | |
C++ Example 4
Simplistic, non-graphical simulation of a stoplight. Demonstrates
how to use state machines to handle external events (in this case
timeouts).
+ Building
----------
NOTE: Smc.jar must be built and installed.
$ make traffic
+ Executing
-----------
$ traffic