37 #include "qs_dummy.hpp"
42 #error Source file included in a project NOT based on the QV kernel
47Q_DEFINE_THIS_MODULE(
"qv")
81 QS::beginRec_(
static_cast<std::uint_fast8_t
>(
QS_QF_RUN));
89#if (defined QF_ON_CONTEXT_SW) || (defined Q_SPY)
90 std::uint_fast8_t pprev = 0U;
92#ifdef QF_ON_CONTEXT_SW
105 if (QV::priv_.readySet.notEmpty()) {
107 std::uint_fast8_t
const p = QV::priv_.readySet.findMax();
110#if (defined QF_ON_CONTEXT_SW) || (defined Q_SPY)
116 static_cast<std::uint8_t
>(pprev));
119#ifdef QF_ON_CONTEXT_SW
133#if (QF_MAX_EPOOL > 0U)
139 QV::priv_.readySet.remove(p);
143#if (defined QF_ON_CONTEXT_SW) || (defined Q_SPY)
147 QS_U8_PRE(
static_cast<std::uint8_t
>(pprev));
150#ifdef QF_ON_CONTEXT_SW
177 std::uint_fast16_t
const qLen,
179 std::uint_fast16_t
const stkSize,
180 void const *
const par)
192 m_prio =
static_cast<std::uint8_t
>(prioSpec & 0xFFU);
Active Object class (based on the QP::QHsm implementation strategy).
void init(void const *const e, std::uint_fast8_t const qsId) override
Take the top-most initial transition in QActive (delegate to QP::QHsm).
void register_() noexcept
Register this active object to be managed by the framework.
void dispatch(QEvt const *const e, std::uint_fast8_t const qsId) override
Dispatch an event to QActive (delegate to QP::QHsm).
QACTIVE_EQUEUE_TYPE m_eQueue
Port-dependent event-queue type (often QP::QEQueue).
QEvt const * get_() noexcept
Get an event from the event queue of an active object.
void start(QPrioSpec const prioSpec, QEvtPtr *const qSto, std::uint_fast16_t const qLen, void *const stkSto, std::uint_fast16_t const stkSize, void const *const par=nullptr)
Starts execution of an active object and registers the object with the framework.
std::uint8_t m_pthre
Preemption-threshold [1..QF_MAX_ACTIVE] of this AO.
std::uint8_t m_prio
QF-priority [1..QF_MAX_ACTIVE] of this AO.
QV non-preemptive kernel.
QF Active Object Framework namespace \clearpage .
void onCleanup()
Cleanup QF callback.
void gc(QEvt const *const e) noexcept
Recycle a mutable (mutable) event.
void init()
QF initialization.
int_t run()
Transfers control to QF to run the application.
void stop()
Invoked by the application layer to stop the QF framework and return control to the OS/Kernel (used i...
void onStartup()
Startup QF callback.
QP/C++ Framework namespace \clearpage .
@ QS_QF_RUN
QF_run() was entered.
@ QS_SCHED_NEXT
scheduler started next task
@ QS_SCHED_IDLE
scheduler restored the idle task
std::array< QActive *, QF_MAX_ACTIVE+1U > QActive_registry_
Internal array of pointers to the registered Active Objects.
std::uint16_t QPrioSpec
Priority specification for Active Objects in QP.
int int_t
Alias for assertion-ID numbers in QP assertions and return from QP::QF::run() \clearpage .
#define Q_UNUSED_PAR(par_)
Helper macro to mark unused parameters of functions.
void QF_onContextSw(QP::QActive *prev, QP::QActive *next)
QF context switch callback used in built-in kernels (QV/QK/QXK).
QP/C++ Framework in C++ internal (package-scope) interface.
#define QF_CRIT_ENTRY()
Port-specific critical section entry.
#define QF_INT_DISABLE()
Port-specific interrupt disable.
#define QF_INT_ENABLE()
Port-specific interrupt enable.
#define QF_CRIT_EXIT()
Port-specific critical section exit.
#define QF_CRIT_STAT
Define the critical section status that was present before entering the critical section.
QS (QP/Spy software tracing) internal (package-scope) interface. \clearpage .
#define QS_2U8_PRE(data1_, data2_)
Output two pre-formatted unsigned 8-bit integer data elements.
#define QS_U8_PRE(data_)
Output pre-formatted unsigned 8-bit integer data element.
#define QS_END_PRE()
Pre-formatted QS trace record end.
#define QS_BEGIN_PRE(rec_, qsId_)
Pre-formatted QS trace record begin.
QP Functional Safety (FuSa) Subsystem.
#define Q_REQUIRE_INCRIT(id_, expr_)
Assertion for checking a precondition (in critical section).
The data type to store in the event queue ring-buffer.