Edouard@2020: /************************************************************************** Edouard@2020: * Edouard@2020: * Copyright (C) 2006 Steve Karg Edouard@2020: * Copyright (C) 2017 Mario de Sousa Edouard@2020: * Edouard@2020: * Permission is hereby granted, free of charge, to any person obtaining Edouard@2020: * a copy of this software and associated documentation files (the Edouard@2020: * "Software"), to deal in the Software without restriction, including Edouard@2020: * without limitation the rights to use, copy, modify, merge, publish, Edouard@2020: * distribute, sublicense, and/or sell copies of the Software, and to Edouard@2020: * permit persons to whom the Software is furnished to do so, subject to Edouard@2020: * the following conditions: Edouard@2020: * Edouard@2020: * The above copyright notice and this permission notice shall be included Edouard@2020: * in all copies or substantial portions of the Software. Edouard@2020: * Edouard@2020: * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, Edouard@2020: * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF Edouard@2020: * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. Edouard@2020: * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY Edouard@2020: * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, Edouard@2020: * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE Edouard@2020: * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. Edouard@2020: * Edouard@2020: *********************************************************************/ Edouard@2020: Edouard@2020: #ifndef SERVER_H_ Edouard@2020: #define SERVER_H_ Edouard@2020: Edouard@2020: Edouard@2020: #include Edouard@2020: #include Edouard@2020: Edouard@2020: Edouard@2020: Edouard@2020: typedef struct{ Edouard@2020: const char *location; Edouard@2020: const char *network_interface; Edouard@2020: const char *port_number; Edouard@2020: const char *device_name; Edouard@2020: const char *comm_control_passwd; Edouard@2020: uint32_t device_id; // device ID is 22 bits long! uint16_t is not enough! Edouard@2020: int init_state; // store how far along the server's initialization has progressed Edouard@2020: pthread_t thread_id; // thread handling this server Edouard@2020: } server_node_t; Edouard@2020: Edouard@2020: Edouard@2020: Edouard@2020: /*initialization following all parameters given by user in application*/ Edouard@2020: static server_node_t server_node = { Edouard@2020: "%(locstr)s", Edouard@2020: "%(network_interface)s", // interface (NULL => use default (eth0)) Edouard@2020: "%(port_number)s", // Port number (NULL => use default) Edouard@2020: "%(BACnet_Device_Name)s", // BACnet server's device (object) name Edouard@2020: "%(BACnet_Comm_Control_Password)s",// BACnet server's device (object) name Edouard@2020: %(BACnet_Device_ID)s // BACnet server's device (object) ID Edouard@2020: }; Edouard@2020: Edouard@2020: Edouard@2020: Edouard@2020: #endif /* SERVER_H_ */