SysTaskEnd (FUN) ¶ FUNCTION SysTaskEnd : RTS_IEC_RESULT <description>Is called from the task itself, that ends its execution.</description> <result><p>RESULT: Returns the runtime system error code (see CmpErrors.library).</p></result> InOut: Scope Name Type Comment Return SysTaskEnd RTS_IEC_RESULT Input hTask RTS_IEC_HANDLE <param name=”hTask” type=”IN”>Handle to task</param> ulExitCode UDINT <param name=”ulExitCode” type=”IN”>Exit code of the task</param>
SysTaskEnter (FUN) ¶ FUNCTION SysTaskEnter : RTS_IEC_RESULT <description>This function is called to mark entering the while loop.</description> <result><p>RESULT: Returns the runtime system error code (see CmpErrors.library).</p></result> InOut: Scope Name Type Comment Return SysTaskEnter RTS_IEC_RESULT Input hTask RTS_IEC_HANDLE <param name=”hTask” type=”IN”>Handle to task</param>
SysTaskExit (FUN) ¶ FUNCTION SysTaskExit : RTS_IEC_RESULT <description>Tries to exit the given task gracefully. If the task doesn’t answer in the specified timeout, then the task will be deleted hard!</description> <result><p>RESULT: Returns the runtime system error code (see CmpErrors.library).</p></result> InOut: Scope Name Type Comment Return SysTaskExit RTS_IEC_RESULT Input hTask RTS_IEC_HANDLE <param name=”hTask” type=”IN”>Handle to task</param> ulTimeoutMs UDINT <param name=”ulTimeoutMs” type=”IN”>Timeout in milliseconds</param>
SysTaskGenerateException (FUN) ¶ FUNCTION SysTaskGenerateException : RTS_IEC_RESULT <description>Call the corresponding exception handler of the task.</description> <result><p>RESULT: Returns the runtime system error code (see CmpErrors.library).</p></result> InOut: Scope Name Type Comment Return SysTaskGenerateException RTS_IEC_RESULT Input ulTaskOSHandle RTS_IEC_HANDLE <param name=”ulTaskOSHandle” type=”IN”>Operating system handle of the task</param> ulException UDINT <param name=”ulException” type=”IN”>Rts standard exception</param> Context RegContext <param name=”Context” type=”IN”>Context to detect the code location where the exception occurred</param>
SysTaskGetContext (FUN) ¶ FUNCTION SysTaskGetContext : RTS_IEC_RESULT <description>Get the current register context of the task. Task must be in suspended mode!</description> <result><p>RESULT: Returns the runtime system error code (see CmpErrors.library).</p></result> InOut: Scope Name Type Comment Return SysTaskGetContext RTS_IEC_RESULT Input hTask RTS_IEC_HANDLE <param name=”hTask” type=”IN”>Handle to task</param> pContext POINTER TO RegContext <param name=”pContext” type=”OUT”>Pointer to context</param>
SysTaskGetCurrent (FUN) ¶ FUNCTION SysTaskGetCurrent : RTS_IEC_RESULT <description>Returns the handle of the current running task.</description> <result><p>RESULT: Returns the runtime system error code (see CmpErrors.library).</p></result> InOut: Scope Name Type Comment Return SysTaskGetCurrent RTS_IEC_RESULT Input phTask POINTER TO RTS_IEC_HANDLE <param name=”phTask” type=”OUT”>Pointer to task handle</param>
SysTaskGetCurrentOSHandle (FUN) ¶ FUNCTION SysTaskGetCurrentOSHandle : RTS_IEC_RESULT <description>Returns the operating system handle of the current running task.</description> <result><p>RESULT: Returns the runtime system error code (see CmpErrors.library).</p></result> InOut: Scope Name Type Comment Return SysTaskGetCurrentOSHandle RTS_IEC_RESULT Input puiTaskOSHandle POINTER TO RTS_IEC_HANDLE <param name=”puiTaskOSHandle” type=”OUT”>Pointer to operating system task handle</param>
SysTaskGetInfo (FUN) ¶ FUNCTION SysTaskGetInfo : RTS_IEC_RESULT <description>Returns the task info of the specified task.</description> <result><p>RESULT: Returns the runtime system error code (see CmpErrors.library).</p></result> InOut: Scope Name Type Comment Return SysTaskGetInfo RTS_IEC_RESULT Input hTask RTS_IEC_HANDLE <param name=”hTask” type=”IN”>Handle to task</param> ppInfo POINTER TO POINTER TO SYS_TASK_INFO <param name=”ppInfo” type=”OUT”>Pointer pointer to get task info structure</param>
SysTaskGetInterval (FUN) ¶ FUNCTION SysTaskGetInterval : RTS_IEC_RESULT <description>Get the actual interval of a cyclic task. If the specified task is no cyclic task, the function return an error.</description> <result><p>RESULT: Returns the runtime system error code (see CmpErrors.library).</p></result> InOut: Scope Name Type Comment Return SysTaskGetInterval RTS_IEC_RESULT Input hTask RTS_IEC_HANDLE <param name=”hTask” type=”IN”>Handle to the task</param> Inout pulInterval UDINT <param name=”pulInterval” type=”OUT”>Interval of the task in microseconds!</param>
SysTaskGetOSHandle (FUN) ¶ FUNCTION SysTaskGetOSHandle : RTS_IEC_HANDLE <description>Function to get the operating system specific handle.</description> <result><p>RESULT: Returns the runtime system error code (see CmpErrors.library).</p></result> InOut: Scope Name Type Comment Return SysTaskGetOSHandle RTS_IEC_HANDLE Input hTask RTS_IEC_HANDLE <param name=”hTask” type=”IN”>Handle to task</param>