WarpTwin
Documentation for WarpTwin models and classes.
Loading...
Searching...
No Matches
appmacros.h File Reference
#include "configuration.h"

Go to the source code of this file.

Macros

#define SIGNAL(NAME, TYPE, INITIAL_VALUE)
#define START_OUTPUTS
#define END_OUTPUTS
#define START_INPUTS
#define END_INPUTS
#define START_PARAMS
#define END_PARAMS
#define LOG(LEVEL, MESSAGE)
 Logging macro which wraps os log for easy use.
#define LOG_SCHEDULER(LEVEL, MESSAGE)

Macro Definition Documentation

◆ END_INPUTS

#define END_INPUTS
Value:
};\
Inputs inputs = Inputs(this, "inputs");

◆ END_OUTPUTS

#define END_OUTPUTS
Value:
};\
Outputs outputs = Outputs(this, "outputs");

◆ END_PARAMS

#define END_PARAMS
Value:
};\
Params params = Params(this, "params");

◆ LOG

#define LOG ( LEVEL,
MESSAGE )
Value:
EXCLUDE_FROM_COVERAGE(\
if(LEVEL <= exc.logLevel() || LEVEL <= _local_log_level /* LCOV_EXCL_LINE */) {\
exc.os().sysLog(exc.os().systemTime().asFloatingPoint(), name(), MESSAGE, strlen(MESSAGE)); /* LCOV_EXCL_LINE */\
}\
)

Logging macro which wraps os log for easy use.

Parameters
LEVELThe log level to log at
MESSAGEThe (c string) log message to write

◆ LOG_SCHEDULER

#define LOG_SCHEDULER ( LEVEL,
MESSAGE )
Value:
EXCLUDE_FROM_COVERAGE(\
if(_exc_ptr) {\
if(LEVEL <= _exc_ptr->logLevel() /* LCOV_EXCL_LINE */) {\
_exc_ptr->os().sysLog(_exc_ptr->os().systemTime().asFloatingPoint(), name(), MESSAGE, strlen(MESSAGE)); /* LCOV_EXCL_LINE */\
}\
}\
)

◆ SIGNAL

#define SIGNAL ( NAME,
TYPE,
INITIAL_VALUE )
Value:
clockwerk::DataIO<TYPE> NAME = clockwerk::DataIO<TYPE>(this, #NAME, INITIAL_VALUE);
Class for inter-object communication.
Definition DataIO.hpp:60

◆ START_INPUTS

#define START_INPUTS
Value:
struct Inputs : clockwerk::GraphTreeObject {\
Inputs(clockwerk::GraphTreeObject* par, const char* nme) : clockwerk::GraphTreeObject(nme, _children, MAXIMUM_APP_CHILDREN) {parent(par);}\
private:\
clockwerk::GraphTreeObject* _children[MAXIMUM_APP_CHILDREN];\
public:
Base class for object organization.
Definition GraphTreeObject.h:98
GraphTreeObject * parent()
Functions to get object's parent/children.
Definition GraphTreeObject.h:107
GraphTreeObject(const char *gt_nme="", GraphTreeObject **storage_array=nullptr, uint32 storage_size=0)
Name-based constructor for GraphTreeObject which will have no children by default.
Definition GraphTreeObject.cpp:23
Definition CircularBuffer.hpp:28

◆ START_OUTPUTS

#define START_OUTPUTS
Value:
struct Outputs : clockwerk::GraphTreeObject {\
Outputs(clockwerk::GraphTreeObject* par, const char* nme) : clockwerk::GraphTreeObject(nme, _children, MAXIMUM_APP_CHILDREN) {parent(par);}\
private:\
clockwerk::GraphTreeObject* _children[MAXIMUM_APP_CHILDREN];\
public:

◆ START_PARAMS

#define START_PARAMS
Value:
struct Params : clockwerk::GraphTreeObject {\
Params(clockwerk::GraphTreeObject* par, const char* nme) : clockwerk::GraphTreeObject(nme, _children, MAXIMUM_APP_CHILDREN) {parent(par);}\
private:\
clockwerk::GraphTreeObject* _children[MAXIMUM_APP_CHILDREN];\
public: