High Performance OPC UA Server SDK  1.7.1.383
server_main.c
/*****************************************************************************
* *
* Copyright (c) 2006-2023 Unified Automation GmbH. All rights reserved. *
* *
* Software License Agreement ("SLA") Version 2.8 *
* *
* Unless explicitly acquired and licensed from Licensor under another *
* license, the contents of this file are subject to the Software License *
* Agreement ("SLA") Version 2.8, or subsequent versions as allowed by the *
* SLA, and You may not copy or use this file in either source code or *
* executable form, except in compliance with the terms and conditions of *
* the SLA. *
* *
* All software distributed under the SLA is provided strictly on an "AS *
* IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, *
* AND LICENSOR HEREBY DISCLAIMS ALL SUCH WARRANTIES, INCLUDING WITHOUT *
* LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR *
* PURPOSE, QUIET ENJOYMENT, OR NON-INFRINGEMENT. See the SLA for specific *
* language governing rights and limitations under the SLA. *
* *
* The complete license agreement can be found here: *
* http://unifiedautomation.com/License/SLA/2.8/ *
* *
*****************************************************************************/
/* generic commandline parsing and server run functions */
#include "../../utility/server_utilities.h"
/* include our custum provider*/
#include "custom_provider.h"
/* global application constants */
#define COMPANY_LONG_NAME "Unified Automation GmbH"
#define COMPANY_NAME "UnifiedAutomation"
#define PRODUCT_LONG_NAME "High Performance OPC UA SDK"
#define PRODUCT_NAME "UASDKHP"
#define PRODUCT_URI "urn:UnifiedAutomation:UASDKHP"
#define SERVER_LONG_NAME "GettingStarted Server Lesson02"
#define SERVER_NAME "UaServerHP"
static struct uaserver_provider g_provider[] = {
UASERVER_PROVIDER_INITIALIZER(uaprovider_server_init),
UASERVER_PROVIDER_INITIALIZER(custom_provider_init)
};
int main(int argc, char *argv[])
{
struct server_main_args args;
struct server_vendor_info info = {
COMPANY_LONG_NAME, COMPANY_NAME, PRODUCT_LONG_NAME, PRODUCT_NAME, PRODUCT_URI, SERVER_LONG_NAME, SERVER_NAME,
};
server_set_vendor_info(&info);
server_main_args_init(&args, g_provider, countof(g_provider));
server_main_parse_commandline(argc, argv, &args, NULL, NULL);
server_main_execute(&args);
return 0;
}