 |
F´ Flight Software - C/C++ Documentation
NASA-v2.1.0
A framework for building embedded system applications to NASA flight quality standards.
|
Go to the documentation of this file.
45 "Please switch to start(Fw::StringBase &name, taskRoutine routine, void* arg, NATIVE_UINT_TYPE priority, NATIVE_UINT_TYPE stackSize, NATIVE_UINT_TYPE cpuAffinity, NATIVE_UINT_TYPE identifier)");
53 void suspend(
bool onPurpose =
false);
68 POINTER_CAST m_handle;
75 bool m_suspendedOnPurpose;
void setStarted(bool started)
set task to started when thread is fully up. Avoids a VxWorks race condition.
virtual void removeTask(Task *task)=0
remove a task from the registry
void suspend(bool onPurpose=false)
suspend task
@ TASK_UNKNOWN_ERROR
unexpected error return value
@ TASK_ERROR_PERMISSION
permissions error setting-up tasks
static NATIVE_INT_TYPE getNumTasks(void)
@ TASK_ERROR_RESOURCES
unable to allocate more tasks
TaskRegistry()
constructor for task registry
void(* taskRoutine)(void *ptr)
prototype for task routine started in task context
static void registerTaskRegistry(TaskRegistry *registry)
bool wasSuspended(void)
returns whether or not task was suspended on purpose
void resume(void)
resume execution of task
taskRoutine routine
contains the task entrypoint
static const NATIVE_UINT_TYPE TASK_DEFAULT
virtual void addTask(Task *task)=0
Add a task to the registry.
@ TASK_INVALID_AFFINITY
unable to set the task affinity
@ TASK_OK
message sent/received okay
unsigned int NATIVE_UINT_TYPE
native unsigned integer type declaration
@ TASK_INVALID_PARAMS
started task with invalid parameters
@ TASK_DELAY_ERROR
error trying to delay the task
bool isStarted(void)
check to see if task is started
virtual ~TaskRegistry()
destructor for task registry
DEPRECATED(TaskStatus start(const Fw::StringBase &name, NATIVE_INT_TYPE identifier, NATIVE_INT_TYPE priority, NATIVE_INT_TYPE stackSize, taskRoutine routine, void *arg, NATIVE_INT_TYPE cpuAffinity=TASK_DEFAULT), "Please switch to start(Fw::StringBase &name, taskRoutine routine, void* arg, NATIVE_UINT_TYPE priority, NATIVE_UINT_TYPE stackSize, NATIVE_UINT_TYPE cpuAffinity, NATIVE_UINT_TYPE identifier)")
start the task
TaskStatus start(const Fw::StringBase &name, taskRoutine routine, void *arg, NATIVE_UINT_TYPE priority=TASK_DEFAULT, NATIVE_UINT_TYPE stackSize=TASK_DEFAULT, NATIVE_UINT_TYPE cpuAffinity=TASK_DEFAULT, NATIVE_UINT_TYPE identifier=TASK_DEFAULT)
start the task
POINTER_CAST getRawHandle()
static TaskStatus delay(NATIVE_UINT_TYPE msecs)
delay the task
bool isSuspended(void)
check with OS to see if it is suspended already
virtual ~Task()
destructor
I32 getIdentifier(void)
get the identifier for the task
Declares ISF basic types.
void * arg
contains the task entrypoint pointer
static TaskId getOsIdentifier(void)
int NATIVE_INT_TYPE
native integer type declaration
@ TASK_INVALID_STACK
started with invalid stack size
@ TASK_JOIN_ERROR
error trying to join the task
TaskStatus join(void **value_ptr)
Wait for task to finish.