UA Ansi C Server Professional
1.3.3.242
|
Functions | |
void | OpcUa_ProxyStubConfiguration_InitializeDefault (OpcUa_ProxyStubConfiguration *a_pProxyStubConfiguration) |
Initialize UA stack configuration structure with default values. More... | |
OpcUa_StatusCode | UaServer_Module_InitializeUaStack (OpcUa_Handle *a_phProxyStubPlatformLayer, OpcUa_ProxyStubConfiguration *a_pProxyStubConfiguration) |
Initialize UA stack. More... | |
OpcUa_StatusCode | UaServer_Module_ClearUaStack (OpcUa_Handle *a_phProxyStubPlatformLayer) |
Clear UA stack. More... | |
OpcUa_StatusCode | UaServer_SetPKIConfiguration (UaServer *a_pUaServer, OpcUa_P_PKI_Types a_ePkiType, OpcUa_StringA a_sPrivateKey, OpcUa_StringA a_sServerCert, OpcUa_StringA a_sCrl, OpcUa_StringA a_sCertDir, OpcUa_StringA a_sRejectedCertLocation) |
Initializes the PKI configuartion of the Server. More... | |
OpcUa_StatusCode | UaServer_SetUserAuthenticationType (UaServer *a_pUaServer, UaServer_UserAuthType a_type, UaServer_pfServer_AuthenticateSession a_pUserAuthFunction) |
Sets the authentication type used in ActivateSession. More... | |
OpcUa_StatusCode | UaServer_SetUserAuthenticationTypeEx (UaServer *a_pUaServer, UaServer_UserAuthType a_type, UaServer_pfServer_AuthenticateSessionEx a_pUserAuthFunction) |
Sets the authentication type used in ActivateSession. More... | |
OpcUa_StatusCode | UaServer_SetCallback_SessionCreated (UaServer *a_pUaServer, UaServer_pfServer_SessionCreated a_pCallbackFunction) |
Sets the SessionCreated callback function. More... | |
OpcUa_StatusCode | UaServer_SetCallback_SessionActivated (UaServer *a_pUaServer, UaServer_pfServer_SessionActivated a_pCallbackFunction) |
Sets the SessionActivated callback function. More... | |
OpcUa_StatusCode | UaServer_SetCallback_SessionClosed (UaServer *a_pUaServer, UaServer_pfServer_SessionClosed a_pCallbackFunction) |
Sets the SessionClosed callback function. More... | |
OpcUa_StatusCode | UaServer_Initialize (UaServer *a_pUaServer, OpcUa_StringA a_sEndpointUrl, OpcUa_StringA a_sApplicationUri, OpcUa_StringA a_sProductUri, OpcUa_StringA a_sApplicationName, OpcUa_P_PKI_Types a_ePKIType, OpcUa_StringA a_sPKIPrivateKey, OpcUa_StringA a_sPKIServerCert, OpcUa_StringA a_sPKICrl, OpcUa_StringA a_sPKICertDir, OpcUa_StringA a_sPKIRejectedDir) |
Initialize the UaServer object structure with the base settings. More... | |
UaServer_Configuration * | UaServer_GetConfiguration (UaServer *a_pUaServer) |
Returns the configuration struct of the server. More... | |
OpcUa_StatusCode | UaServer_StartUp (UaServer *a_pUaServer) |
Start the UaServer to enable OPC UA connection establishment from clients. More... | |
OpcUa_StatusCode | UaServer_DoCom () |
The internal main 'event loop' which processes messages and triggers timers. More... | |
OpcUa_StatusCode | UaServer_Shutdown (UaServer *a_pUaServer, OpcUa_UInt32 a_uSecondsTillShutdown, OpcUa_LocalizedText *a_pShutdownReason) |
Shut the server down in the given number of seconds. More... | |
OpcUa_Void | UaServer_Clear (UaServer *a_pUaServer) |
Cleans up application and used resources. More... | |
void OpcUa_ProxyStubConfiguration_InitializeDefault | ( | OpcUa_ProxyStubConfiguration * | a_pProxyStubConfiguration | ) |
Initialize UA stack configuration structure with default values.
The configuration structure is used to initialize the UA Stack. The default values are set by the stack configuration e.g. in the stack file opcua_config.h
The structure contains the following settings:
Trace settings
bProxyStub_Trace_Enabled - Flag that indicates if the stack trace is activated. This requires that the traces are not disabled with the stack compiler switch. The trace is also used by the Server SDK
uProxyStub_Trace_Level - Tracelevel used if trace is activated. Possible settings are
Serializer settings
This part of the configuration defines the OPC UA Stack serializer settings. These are the security constraints for the serializer. The settings are also relevant for the resource consuption of the UA stack. Set this values carefully.
The other settings should not be changed since they are set by the SDK and changing them will cause undefined behaviour.
a_pProxyStubConfiguration | Configuration structure for the UA Stack. |
OpcUa_Void UaServer_Clear | ( | UaServer * | a_pUaServer | ) |
Cleans up application and used resources.
a_pUaServer | a pointer to the servers object. |
OpcUa_StatusCode UaServer_DoCom | ( | ) |
The internal main 'event loop' which processes messages and triggers timers.
UaServer_Configuration * UaServer_GetConfiguration | ( | UaServer * | a_pUaServer | ) |
Returns the configuration struct of the server.
[in] | a_pUaServer | The server to use |
OpcUa_StatusCode UaServer_Initialize | ( | UaServer * | a_pUaServer, |
OpcUa_StringA | a_sEndpointUrl, | ||
OpcUa_StringA | a_sApplicationUri, | ||
OpcUa_StringA | a_sProductUri, | ||
OpcUa_StringA | a_sApplicationName, | ||
OpcUa_P_PKI_Types | a_ePKIType, | ||
OpcUa_StringA | a_sPKIPrivateKey, | ||
OpcUa_StringA | a_sPKIServerCert, | ||
OpcUa_StringA | a_sPKICrl, | ||
OpcUa_StringA | a_sPKICertDir, | ||
OpcUa_StringA | a_sPKIRejectedDir | ||
) |
Initialize the UaServer object structure with the base settings.
[in] | a_pUaServer | A pointer to the UaServer object. |
[in] | a_sEndpointUrl | URL of the UA server endpoint. This URL is used by the server to open the endpoint in the UA stack and by clients to connect to the server. |
[in] | a_sApplicationUri | Globally unique identifier for the server instance. |
[in] | a_sProductUri | Globally unique identifier for the server application. |
[in] | a_sApplicationName | Human readable name for the server application. |
[in] | a_ePKIType | ToDoDoc |
[in] | a_sPKIPrivateKey | ToDoDoc |
[in] | a_sPKIServerCert | ToDoDoc |
[in] | a_sPKICrl | ToDoDoc |
[in] | a_sPKICertDir | ToDoDoc |
[in] | a_sPKIRejectedDir | ToDoDoc |
OpcUa_StatusCode UaServer_Module_ClearUaStack | ( | OpcUa_Handle * | a_phProxyStubPlatformLayer | ) |
Clear UA stack.
If this function was called, no UA stack functionality can be used any more.
a_phProxyStubPlatformLayer | UA Stack platform layer handle. |
OpcUa_StatusCode UaServer_Module_InitializeUaStack | ( | OpcUa_Handle * | a_phProxyStubPlatformLayer, |
OpcUa_ProxyStubConfiguration * | a_pProxyStubConfiguration | ||
) |
Initialize UA stack.
This function must be called before any UA stack functionality is used.
a_phProxyStubPlatformLayer | UA Stack platfrom layer handle. |
a_pProxyStubConfiguration | Configuration structure for the UA Stack. |
OpcUa_StatusCode UaServer_SetCallback_SessionActivated | ( | UaServer * | a_pUaServer, |
UaServer_pfServer_SessionActivated | a_pCallbackFunction | ||
) |
Sets the SessionActivated callback function.
This function was introduced in version 1.2.1.
[in] | a_pUaServer | A pointer to the UaServer object. |
[in] | a_pCallbackFunction | The function to call if a session was activated. |
OpcUa_StatusCode UaServer_SetCallback_SessionClosed | ( | UaServer * | a_pUaServer, |
UaServer_pfServer_SessionClosed | a_pCallbackFunction | ||
) |
Sets the SessionClosed callback function.
This function was introduced in version 1.2.1.
[in] | a_pUaServer | A pointer to the UaServer object. |
[in] | a_pCallbackFunction | The function to call if a session was closed. |
OpcUa_StatusCode UaServer_SetCallback_SessionCreated | ( | UaServer * | a_pUaServer, |
UaServer_pfServer_SessionCreated | a_pCallbackFunction | ||
) |
Sets the SessionCreated callback function.
This function was introduced in version 1.2.1.
[in] | a_pUaServer | A pointer to the UaServer object. |
[in] | a_pCallbackFunction | The function to call if a session was created. |
OpcUa_StatusCode UaServer_SetPKIConfiguration | ( | UaServer * | a_pUaServer, |
OpcUa_P_PKI_Types | a_ePkiType, | ||
OpcUa_StringA | a_sPrivateKey, | ||
OpcUa_StringA | a_sServerCert, | ||
OpcUa_StringA | a_sCrl, | ||
OpcUa_StringA | a_sCertDir, | ||
OpcUa_StringA | a_sRejectedCertLocation | ||
) |
Initializes the PKI configuartion of the Server.
[in] | a_pUaServer | a pointer to the servers description. |
[in] | a_ePkiType | ToDoDoc |
[in] | a_sPrivateKey | path to private key |
[in] | a_sServerCert | path to server certificate |
[in] | a_sCrl | path to crl |
[in] | a_sCertDir | path of cert directory |
[in] | a_sRejectedCertLocation | ToDoDoc |
OpcUa_StatusCode UaServer_SetUserAuthenticationType | ( | UaServer * | a_pUaServer, |
UaServer_UserAuthType | a_type, | ||
UaServer_pfServer_AuthenticateSession | a_pUserAuthFunction | ||
) |
Sets the authentication type used in ActivateSession.
[in] | a_pUaServer | A pointer to the UaServer object. |
[in] | a_type | The authentication type to set. |
[in] | a_pUserAuthFunction | Optional: If a custom authentication module should be set, the function pointer to the authentication callback function must be set here and a_type to UserAuthType_User. If no custom authentication module is set, this parameter is ignored and can be OpcUa_Null. |
OpcUa_StatusCode UaServer_SetUserAuthenticationTypeEx | ( | UaServer * | a_pUaServer, |
UaServer_UserAuthType | a_type, | ||
UaServer_pfServer_AuthenticateSessionEx | a_pUserAuthFunction | ||
) |
Sets the authentication type used in ActivateSession.
[in] | a_pUaServer | A pointer to the UaServer object. |
[in] | a_type | The authentication type to set. |
[in] | a_pUserAuthFunction | Optional: If a custom authentication module should be set, the function pointer to the authentication callback function must be set here and a_type to UserAuthType_User. If no custom authentication module is set, this parameter is ignored and can be OpcUa_Null. |
OpcUa_StatusCode UaServer_Shutdown | ( | UaServer * | a_pUaServer, |
OpcUa_UInt32 | a_uSecondsTillShutdown, | ||
OpcUa_LocalizedText * | a_pShutdownReason | ||
) |
Shut the server down in the given number of seconds.
After a_uSecondsTillShutdown have passed, UaServer_DoCom will return with status OpcUa_BadShutdown.
a_pUaServer | A pointer to the server object. |
a_uSecondsTillShutdown | The number of seconds to wait until shutdown. |
a_pShutdownReason | The reason for shutdown. |
OpcUa_StatusCode UaServer_StartUp | ( | UaServer * | a_pUaServer | ) |
Start the UaServer to enable OPC UA connection establishment from clients.
a_pUaServer | a pointer to the UaServer object. |