Github project repo:EVM (EVent Machine)
EVM (EVENT MACHINE) SOFTWARE PROJECT
====================================

--------------------------------------------------------------------
Copyright (C) 2014 Samo Pogacnik 
All rights reserved.

The EVM software project is provided under the terms of the
BSD 3-Clause license, which is available in the LICENSE file of this
project.
--------------------------------------------------------------------

The EVM (EVent Machine) software is a C programming framework consisting of
the libevm library at its core.

Features:
=========
- Layering capability.
- Usable in a sigle/multi-threaded application.

Building:
=========

Native build:
-------------

Out-of-source-build (preferred):
--------------------------------
$ cd evm
$ mkdir build
$ cd build
$ cmake ../
$ make

In-source-build:
----------------
$ cd evm
$ cmake ./
$ make

Installation:
=============

$ make install

If you need to specify installation path:
-----------------------------------------
cmake  -DCMAKE_INSTALL_PREFIX=

For example:
$ cmake ../ -DCMAKE_INSTALL_PREFIX=../install
$ make
$ make install

And you need to cross-compile as well:
--------------------------------------
cmake ../ -DCMAKE_INSTALL_PREFIX=../install -DCMAKE_TOOLCHAIN_FILE=../toolchains/Yocto-arm-linux-gnu.cmake

Cleaning:
=========

$ make clean

If you want to remove all files not under version control and you are using git:
--------------------------------------------------------------------------------
$ git clean -d -f -x

Demos:
======
Programs included under "demos" directory demonstrate usage of the framework.

"hello1_evm" - Minimal framework utilization by sending HELLO message to itself
on every IDLE timer expiration. Sending messages to ourself may be accomplished
directly in framework without any system call (as in this demo).

"hello2_evm" - This demo shows sending message between two processes. The parent
process sends the first HELLO message to its child process. Every received
message in a child or parent process sets new timeout and another HELLO
message is sent back to the sender process after timeout expiration.

"hello3_evm" - This a threaded version of the second demo. The first
thread sends the first HELLO message to the second thread. Every received
message in any thread sets new timeout and another HELLO message is sent back
to the sender thread after timeout expiration.

"hello4_evm" - This is the one to many threaded example. The initial thread
spawns requested number of other threads and sets QUIT timer. Each other thread
sends initial HELLO message to the first thread. Every received message in any
thread sets a new IDLE timeout and another HELLO message is sent back to the
sender thread after timeout expiration.
regards, Samo