SysTaskCreate2 (FUN)
FUNCTION SysTaskCreate2 : RTS_IEC_HANDLE
<description>Is called to create a task in _suspended_ mode. SysTaskResume must be called afterwards!</description> <result><p>RESULT: Handle to the created task</p></result>
- InOut:
Scope
Name
Type
Comment
Return
SysTaskCreate2RTS_IEC_HANDLEInput
pszTaskNameREFERENCE TO STRING
<param name=”pszTaskName” type=”IN”>The name of the task</param>
pFunction<param name=”pFunction” type=”IN”>Function which implements the task: void func (SYS_TASK_PARAM/// pParam*)</param>
pParamPOINTER TO SYS_TASK_PARAM
<param name=”pParam” type=”IN”>Pointer to the argument which is passed on entry, see SYS_TASK_PARAM->pParam</param>
ulPriorityUDINT<param name=”ulPriority” type=”IN”>Priority of the task. Can be 0..255</param>
ulIntervalUDINT<param name=”ulInterval” type=”IN”>Interval in microseconds</param>
ulStackSizeUDINT<param name=”ulStackSize” type=”IN”>Stack size of task in bytes. 0=Default</param>
pExceptionHandler<param name=”pExceptionHandler” type=”IN”>Function pointer to exception handler that is called after an exception has occurred in the task</param>
pResultPOINTER TO RTS_IEC_RESULT
<param name=”pResult” type=”OUT”>Pointer to runtime system error code (see CmpErrors.library)</param>