static state
This commit is contained in:
@@ -40,6 +40,7 @@ uint32_t PolicyEngine::TaskBuffer[PolicyEngine::TaskStackSize];
|
||||
osStaticThreadDef_t PolicyEngine::TaskControlBlock;
|
||||
union pd_msg PolicyEngine::tempMessage;
|
||||
union pd_msg PolicyEngine::_last_dpm_request;
|
||||
PolicyEngine::policy_engine_state PolicyEngine::state = PESinkStartup;
|
||||
StaticQueue_t PolicyEngine::xStaticQueue;
|
||||
uint8_t PolicyEngine::ucQueueStorageArea[PDB_MSG_POOL_SIZE
|
||||
* sizeof(union pd_msg)];
|
||||
@@ -67,7 +68,7 @@ void PolicyEngine::pe_task(const void *arg) {
|
||||
_pps_index = 8;
|
||||
/* Initialize the last_pps */
|
||||
_last_pps = 8;
|
||||
PolicyEngine::policy_engine_state state = PESinkStartup;
|
||||
|
||||
for (;;) {
|
||||
//Loop based on state
|
||||
switch (state) {
|
||||
|
||||
@@ -121,6 +121,7 @@ private:
|
||||
static osStaticThreadDef_t TaskControlBlock;
|
||||
static union pd_msg tempMessage;
|
||||
static union pd_msg _last_dpm_request;
|
||||
static policy_engine_state state;
|
||||
//queue of up to PDB_MSG_POOL_SIZE messages to send
|
||||
static StaticQueue_t xStaticQueue;
|
||||
/* The array to use as the queue's storage area. This must be at least
|
||||
|
||||
Reference in New Issue
Block a user