os: fixed getNSecs which did not return anything meaningful.

Signed-off-by: Peter Soetens <peter@thesourceworks.com>
tests: relax timer tests in order to avoid false failures.

Signed-off-by: Peter Soetens <peter@thesourceworks.com>
config: allow user to also define BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG on a global level

If the user includes posix time headers himself, he'll need to define
BOOST_DATE_TIME_POSIX_TIME_STD_CONFIG in order to enable these features
for our code as well.

Alternatively, we could modify the RTT code to work in both cases, if this is possible.

Signed-off-by: Peter Soetens <peter@thesourceworks.com>
scripting: fix bug where SM was installing synchronous operation callbacks

this->getEngine() is still null when building the SM, so the intent
of the code never happened.
Added extra argument to createEventTransition to get the target EE
where this SM wil run in, such that an asynchronous callback is
created.

Signed-off-by: Peter Soetens <peter@thesourceworks.com>
os: also cleanup the TypeInfoRepository in __os_exit

When parts of the TIR use TLSF, the TIR would be cleaned up after
the TLSF cleanup, causing asserts / segfaults.
fixes #49 on github

Signed-off-by: Peter Soetens <peter@thesourceworks.com>
revert the removal of the GlobalEngine bookkeeping. This belongs in another patch

This reverts one hunk of commit 00e748c5498865d210074d6fd618fca49941d355.
revert change caused by commit 2c7c2c8e until we have a solution.

This reverts the behavior of getNSecs so to always return rtos_get_time_ns(),
like it did before.

Signed-off-by: Peter Soetens <peter@thesourceworks.com>
cmake: Prevent errors when potentially redefine boost types
docs: fix bug in documenting port reads + add section on level events with ports.

Signed-off-by: Peter Soetens <peter@thesourceworks.com>
cmake: add all standard rpaths for all kind of targets to all kind of targes

Since the rpath_use_link_paths cmake option does not work on OSX with cmake < 3.0 this is a way to make sure that in-project targets can link with eachother.

Signed-off-by: Ruben Smits <ruben.smits@intermodalics.eu>
scripting: more robust state change scheduling in order to avoid races

When evenTransition comes into a state machine, this may cause re-writing
of the entry/running/exit programs currently being executed, becaues the
event sets these hooks immediately, instead of letting the FSM finish
the current (entry or exit) program.

This patch lets changeState schedule a state change, and makes enterstate/
leavestate effectively do the state change and switch the new state programs in.

Since changeState now only schedules, in a number of places, the executePending()
function needs to be called to effectively execute SM statements.

Signed-off-by: Peter Soetens <peter@thesourceworks.com>
scripting: fix bug where SM was installing synchronous operation callbacks

this->getEngine() is still null when building the SM, so the intent
of the code never happened.
Added extra argument to createEventTransition to get the target EE
where this SM wil run in, such that an asynchronous callback is
created.

Signed-off-by: Peter Soetens <peter@thesourceworks.com>
revert the removal of the GlobalEngine bookkeeping. This belongs in another patch

This reverts one hunk of commit 00e748c5498865d210074d6fd618fca49941d355.
scripting: correctly implement asynchronous events in eventTransition

Before this patch, only the last eventTransition of two consecutive ones took effect,
since the event data was shared among all subscribers. This patch makes eventTransition
synchronous again such that each eventTransition evaluates its own data. This requires
some proper locking in the SM.

Signed-off-by: Peter Soetens <peter@thesourceworks.com>
ports: add clear() to inputport operation object.

Signed-off-by: Peter Soetens <peter@thesourceworks.com>
Merge branch 'upstream-master' into pu

Conflicts:
	rtt/os/targets/target-config.h.in
Merge remote-tracking branch 'upstream-peter/master' into pu
cmake: Set RDT defaults