43#define QF_EQUEUE_TYPE QEQueue
48#define QF_OS_OBJECT_TYPE void*
51#define QF_THREAD_TYPE void*
54#define QXK_TLS(type_) (static_cast<type_>(QXK_current()->m_thread))
91#ifdef QXK_ON_CONTEXT_SW
165 #ifndef QXK_ISR_CONTEXT_
170 #define QXK_ISR_CONTEXT_() \
171 (QXK_attr_.intNest != 0U)
178 #define QF_SCHED_STAT_ QSchedStatus lockStat_;
181 #define QF_SCHED_LOCK_(prio_) do { \
182 if (QXK_ISR_CONTEXT_()) { \
185 lockStat_ = QXK::schedLock((prio_)); \
190 #define QF_SCHED_UNLOCK_() do { \
191 if (lockStat_ != 0xFFU) { \
192 QXK::schedUnlock(lockStat_); \
197 #define QACTIVE_EQUEUE_WAIT_(me_) \
198 Q_ASSERT_ID(110, (me_)->m_eQueue.m_frontEvt != nullptr)
200 #define QACTIVE_EQUEUE_SIGNAL_(me_) do { \
201 QXK_attr_.readySet.insert( \
202 static_cast<std::uint_fast8_t>((me_)->m_dynPrio)); \
203 if (!QXK_ISR_CONTEXT_()) { \
204 if (QXK_sched_() != 0U) { \
211 #define QF_EPOOL_TYPE_ QMPool
212 #define QF_EPOOL_INIT_(p_, poolSto_, poolSize_, evtSize_) \
213 (p_).init((poolSto_), (poolSize_), (evtSize_))
214 #define QF_EPOOL_EVENT_SIZE_(p_) ((p_).m_blockSize)
215 #define QF_EPOOL_GET_(p_, e_, m_, qs_id_) \
216 ((e_) = static_cast<QEvt *>((p_).get((m_), (qs_id_))))
217 #define QF_EPOOL_PUT_(p_, e_, qs_id_) ((p_).put((e_), (qs_id_)))
QActive active object (based on QP::QHsm implementation)
static QSchedStatus schedLock(std::uint_fast8_t const ceiling) noexcept
QXK selective scheduler lock.
static void schedUnlock(QSchedStatus const stat) noexcept
QXK selective scheduler unlock.
static void onIdle(void)
QXK idle callback (customized in BSPs for QXK)
namespace associated with the QP/C++ framework
std::uint_fast16_t QSchedStatus
The scheduler lock status.
platform-independent fast "raw" thread-safe event queue interface
platform-independent memory pool QP::QMPool interface.
platform-independent priority sets of 8 or 64 elements.
std::uint8_t volatile lockPrio
lock prio (0 == no-lock)
std::uint8_t volatile lockHolder
prio of the lock holder
void QXK_onContextSw(QP::QActive *prev, QP::QActive *next)
QXK context switch callback (customized in BSPs for QXK)
QP::QActive * idleThread
pointer to the idle thread
void QXK_activate_(void)
QXK activator activates the next active object. The activated AO preempts.
std::uint_fast8_t QXK_sched_(void) noexcept
QXK scheduler finds the highest-priority thread ready to run.
QP::QActive *volatile next
next thread to execute
std::uint8_t volatile actPrio
prio of the active basic thread
QP::QPSet readySet
ready-set of all threads
QP::QActive *volatile curr
currently executing thread
QXK_Attr QXK_attr_
global attributes of the QXK kernel
QP::QActive * QXK_current(void) noexcept
return the currently executing active-object/thread
std::uint8_t volatile intNest
ISR nesting level.
attributes of the QXK kernel
Priority Set of up to 32 elements */.