|
CMSDK 2.0.1
Cross-platform C++ base library and SDK for the Psyclone AIOS platform
|
The Examples/ directory of the distribution is a graded tutorial ladder: every concept in this guide has a runnable PsySpec there. Run any of them with:
./Psyclone spec=<file>.xml
The crank code behind them is in Examples/src/Examples.cpp (built into the Examples library), the external-module program in Examples/src/ExternalModules.cpp, and the system test suite in Examples/src/PsyTest.cpp.
| # | PsySpec | Demonstrates | Guide page |
|---|---|---|---|
| 1 | pingpong.xml | Two modules exchanging messages; triggers, named posts, system shutdown; message-throughput timing | Getting Started |
| 2 | shutdown.xml | The minimal system: one module posting Psyclone.Shutdown | Writing a PsySpec |
| 3 | signals.xml | System-wide signals instead of routed messages (cmlabs::PsyAPI::emitSignal() / cmlabs::PsyAPI::waitForSignal()) | Core Concepts |
| 4 | contexts.xml | Context-gated modules; posting context changes; timed triggers (interval=) | Core Concepts |
| 5 | contextprint.xml | Context switching with a message generator; root vs leaf contexts; a module whose context never activates | Core Concepts |
| 6 | whiteboard.xml | Whiteboards with custom integer indexes; named retrieves; FileCatalog and DataCatalog queries | Whiteboards & Catalogs |
| 7 | messagerecord.xml | ReplayCatalog recording message traffic to disk | Whiteboards & Catalogs |
| 8 | messageplayback.xml | ReplayCatalog playing a recording back (rotate, interval) | Whiteboards & Catalogs |
| 9 | single.xml | Full tour on one node: ping-pong → signals → catalogs phases chained by contexts; variables and parameters | Writing a PsySpec |
| 10 | singlecont.xml | The same tour looping continuously (last phase re-posts the first context) | Writing a PsySpec |
| 11 | adhoc.xml | A module placed in an external space (space=) between two in-node modules; parameter tweaking | Distributed Systems |
| 12 | externals.xml | External spaces plus modules whose cranks run in your own executable (ExternalModules.cpp) | Writing a Module (Crank) |
| 13 | multinodesimple.xml | Two nodes, minimal setup | Distributed Systems |
| 14 | multinode.xml | The full test suite across two nodes; guaranteed vs unguaranteed (guaranteed="no") transport | Distributed Systems |
| 15 | multicont.xml | The multi-node tour looping continuously | Distributed Systems |
| 16 | psyprobe.xml | A steadily-active system to browse in the PsyProbe web UI | Getting Started |
| 17 | psytest.xml | The complete self-test architecture used by ./Psyclone psytest (with PsyTest.cpp) | Going Deeper |
All in Examples/src/Examples.cpp:
To start your own module library, copy the Examples project, rename the library, and keep this index open in a second window.