QP/C  7.2.2
Real-Time Embedded Framework
Loading...
Searching...
No Matches
qpc.h File Reference

QP/C public interface including backwards-compatibility layer. More...

#include "qf_port.h"
#include "qassert.h"
#include "qs_port.h"

Go to the source code of this file.

Macros

#define QP_API_VERSION   0
 
#define Q_ASSERT_COMPILE(expr_)   Q_ASSERT_STATIC(expr_)
 
#define QS_FILTER_ON(rec_)   QS_GLB_FILTER((rec_))
 
#define QS_FILTER_OFF(rec_)   QS_GLB_FILTER(-(rec_))
 
#define QS_FILTER_SM_OBJ(obj_)   ((void)0)
 
#define QS_FILTER_AO_OBJ(obj_)   ((void)0)
 
#define QS_FILTER_MP_OBJ(obj_)   ((void)0)
 
#define QS_FILTER_EQ_OBJ(obj_)   ((void)0)
 
#define QS_FILTER_TE_OBJ(obj_)   ((void)0)
 
#define QS_FILTER_AP_OBJ(obj_)   (QS_priv_.locFilter_AP = (obj_))
 
#define QS_BEGIN(rec_, obj_)
 
#define QS_U32_HEX(width_, data_)    (QS_u32_fmt_((uint8_t)(((width_) << 4)) | QS_HEX_FMT, (data_)))
 
#define Q_XTHREAD_CAST(handler_)   ((QXThreadHandler)(handler_))
 
#define QMSM_INIT(me_, e_)   QHSM_INIT((me_), (e_))
 
#define QMSM_DISPATCH(me_, e_)   QHSM_DISPATCH((me_), (e_), 0U)
 

Typedefs

typedef char char_t
 

Detailed Description

This header file must be included directly or indirectly in all application modules (*.c files) that use QP/C.

Definition in file qpc.h.

Macro Definition Documentation

◆ QP_API_VERSION

#define QP_API_VERSION   0

Specifies the backwards compatibility with the QP/C API version.

For example, QP_API_VERSION==691 will cause generating the compatibility layer with QP/C version 6.9.1 and newer, but not older than 6.9.1. QP_API_VERSION==0 causes generation of the maximum currently supported backwards compatibility. This is the default.

Conversely, QP_API_VERSION==9999 means that no compatibility layer should be generated. This setting is useful for checking if an application complies with the latest QP/C API.

Definition at line 77 of file qpc.h.

◆ Q_ASSERT_COMPILE

#define Q_ASSERT_COMPILE (   expr_)    Q_ASSERT_STATIC(expr_)

Static (compile-time) assertion.

Deprecated:
Use Q_ASSERT_STATIC() or better yet _Static_assert() instead.

Definition at line 94 of file qpc.h.

◆ QS_FILTER_ON

#define QS_FILTER_ON (   rec_)    QS_GLB_FILTER((rec_))
Deprecated:
enable the QS global filter

Definition at line 100 of file qpc.h.

◆ QS_FILTER_OFF

#define QS_FILTER_OFF (   rec_)    QS_GLB_FILTER(-(rec_))
Deprecated:
disable the QS global filter

Definition at line 103 of file qpc.h.

◆ QS_FILTER_SM_OBJ

#define QS_FILTER_SM_OBJ (   obj_)    ((void)0)
Deprecated:
enable the QS local filter for SM (state machine) object

Definition at line 106 of file qpc.h.

◆ QS_FILTER_AO_OBJ

#define QS_FILTER_AO_OBJ (   obj_)    ((void)0)
Deprecated:
enable the QS local filter for AO (active objects)

Definition at line 109 of file qpc.h.

◆ QS_FILTER_MP_OBJ

#define QS_FILTER_MP_OBJ (   obj_)    ((void)0)
Deprecated:
enable the QS local filter for MP (memory pool) object

Definition at line 112 of file qpc.h.

◆ QS_FILTER_EQ_OBJ

#define QS_FILTER_EQ_OBJ (   obj_)    ((void)0)
Deprecated:
enable the QS local filter for EQ (event queue) object

Definition at line 115 of file qpc.h.

◆ QS_FILTER_TE_OBJ

#define QS_FILTER_TE_OBJ (   obj_)    ((void)0)
Deprecated:
enable the QS local filter for TE (time event) object

Definition at line 118 of file qpc.h.

◆ QS_FILTER_AP_OBJ

#define QS_FILTER_AP_OBJ (   obj_)    (QS_priv_.locFilter_AP = (obj_))
Deprecated:
local Filter for a generic application object obj_.

Definition at line 123 of file qpc.h.

◆ QS_BEGIN

#define QS_BEGIN (   rec_,
  obj_ 
)
Value:
if (((QS_priv_.glbFilter[(uint_fast8_t)(rec_) >> 3U] \
& (1U << ((uint_fast8_t)(rec_) & 7U))) != 0U) \
&& ((QS_priv_.locFilter_AP == (void *)0) \
|| (QS_priv_.locFilter_AP == (obj_)))) \
{ \
QS_CRIT_STAT_ \
QS_CRIT_E_(); \
QS_beginRec_((uint_fast8_t)(rec_)); \
QS_TIME_PRE_(); {
QS_tx QS_priv_
void const * locFilter_AP
Definition: qs.h:366
uint8_t glbFilter[16]
Definition: qs.h:360
Deprecated:
begin of a user QS record, instead use QS_BEGIN_ID()

Definition at line 126 of file qpc.h.

◆ QS_U32_HEX

#define QS_U32_HEX (   width_,
  data_ 
)     (QS_u32_fmt_((uint8_t)(((width_) << 4)) | QS_HEX_FMT, (data_)))
Deprecated:
Output formatted uint32_t to the QS record

Definition at line 138 of file qpc.h.

◆ Q_XTHREAD_CAST

#define Q_XTHREAD_CAST (   handler_)    ((QXThreadHandler)(handler_))
Deprecated:
casting to QXThreadHandler instead use: the new signature of QXThreadHandler and don't cast

Definition at line 155 of file qpc.h.

◆ QMSM_INIT

#define QMSM_INIT (   me_,
  e_ 
)    QHSM_INIT((me_), (e_))
Deprecated:
call to the QMSM_INIT() operation; instead use: QHSM_INIT()

Definition at line 161 of file qpc.h.

◆ QMSM_DISPATCH

#define QMSM_DISPATCH (   me_,
  e_ 
)    QHSM_DISPATCH((me_), (e_), 0U)
Deprecated:
call to the QMSM_DISPATCH() operation; instead use: QHSM_DISPATCH()

Definition at line 165 of file qpc.h.

Typedef Documentation

◆ char_t

typedef char char_t
Deprecated:
plain 'char' is no longer forbidden in MISRA-C 2012

Definition at line 87 of file qpc.h.