| Name | Modified | Size | Downloads / Week |
|---|---|---|---|
| Parent folder | |||
| main.m | 2023-02-20 | 2.2 kB | |
| README.txt | 2023-02-20 | 402 Bytes | |
| stoplight.m | 2023-02-20 | 2.9 kB | |
| stoplightdefs.h | 2023-02-20 | 1.1 kB | |
| Makefile | 2023-02-20 | 2.6 kB | |
| stoplight.h | 2023-02-20 | 1.3 kB | |
| stoplight.sm | 2023-02-20 | 1.9 kB | |
| Totals: 7 Items | 12.6 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.
Unix:
$ make traffic
Windows Visual C++:
1. Load ex1.dsw.
2. Rebuild all.
+ Executing
-----------
Unix & Windows:
$ traffic