S2OPC OPCUA Toolkit
Loading...
Searching...
No Matches
p_sopc_threads.h File Reference
#include "sopc_threads.h"

Go to the source code of this file.

Typedefs

typedef void * ptrFct(void *pCtx)
 Implementation of SOPC threads in scope of ZEPHYR OS.
 

Functions

SOPC_Thread P_THREAD_Create (ptrFct *callback, void *pCtx, const char *taskName, const int priority)
 Create an handle of a thread and initialize it.
 
bool P_THREAD_Destroy (SOPC_Thread *ppHandle)
 Join and destroy a thread.
 

Typedef Documentation

◆ ptrFct

typedef void * ptrFct(void *pCtx)

Implementation of SOPC threads in scope of ZEPHYR OS.

Function Documentation

◆ P_THREAD_Create()

SOPC_Thread P_THREAD_Create ( ptrFct * callback,
void * pCtx,
const char * taskName,
const int priority )

Create an handle of a thread and initialize it.

Parameters
callbackThe new thread entry point
pCtxAny user-defined context parameter. This will be passed to "callback" call.
taskNameA task name. Caller should ensure uniqueness of names. Possibly can be NULL.
priorityThe ZEPHYR priority of the new thread.

◆ P_THREAD_Destroy()

bool P_THREAD_Destroy ( SOPC_Thread * ppHandle)

Join and destroy a thread.

Parameters
ppHandleA pointer to a tThreadHandle* object, previously returned by P_THREAD_Create
Returns
true in case of success. Otherwise, the thread is not guaranteed to be terminated