libhomegear-base  0.7
Base library for Homegear and Homegear family modules.
PhysicalInterfaceSettings.h
Go to the documentation of this file.
1 /* Copyright 2013-2019 Homegear GmbH
2  *
3  * libhomegear-base is free software: you can redistribute it and/or
4  * modify it under the terms of the GNU Lesser General Public License as
5  * published by the Free Software Foundation, either version 3 of the
6  * License, or (at your option) any later version.
7  *
8  * libhomegear-base is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU Lesser General Public License for more details.
12  *
13  * You should have received a copy of the GNU Lesser General Public
14  * License along with libhomegear-base. If not, see
15  * <http://www.gnu.org/licenses/>.
16  *
17  * In addition, as a special exception, the copyright holders give
18  * permission to link the code of portions of this program with the
19  * OpenSSL library under certain conditions as described in each
20  * individual source file, and distribute linked combinations
21  * including the two.
22  * You must obey the GNU Lesser General Public License in all respects
23  * for all of the code used other than OpenSSL. If you modify
24  * file(s) with this exception, you may extend this exception to your
25  * version of the file(s), but you are not obligated to do so. If you
26  * do not wish to do so, delete this exception statement from your
27  * version. If you delete this exception statement from all source
28  * files in the program, then also delete it here.
29 */
30 
31 #ifndef PHYSICALINTERFACESETTINGS_H_
32 #define PHYSICALINTERFACESETTINGS_H_
33 
34 #include <string>
35 #include <map>
36 #include <unordered_map>
37 #include <memory>
38 
39 namespace BaseLib {
40 
41 class Variable;
42 typedef std::shared_ptr<Variable> PVariable;
43 
44 namespace Systems {
45 
46 class GPIOSetting {
47  public:
49  virtual ~GPIOSetting() {}
50 
51  int32_t number = -1;
52  std::string path;
53 };
54 
56  public:
57  PhysicalInterfaceSettings() = default;
58  virtual ~PhysicalInterfaceSettings() = default;
59  std::unordered_map<std::string, PVariable> all;
60  std::string id;
61  bool isDefault = false;
62  bool rawPacketEvents = false;
63  std::string device;
64  std::string type;
65  uint32_t responseDelay = 95;
66  std::map<uint32_t, GPIOSetting> gpio;
67  int32_t baudrate = -1;
68  bool openWriteonly = false;
69  int32_t oscillatorFrequency = -1;
70  int32_t txPowerSetting = -1;
71  int32_t interruptPin = -1;
72  uint32_t stackPosition = 0;
73  std::string host;
74  std::string port;
75  std::string port2;
76  std::string port3;
77  std::string port4;
78  std::string portKeepAlive;
79  uint32_t address = 0;
80  std::string listenIp;
81  std::string listenPort;
82  std::string lanKey;
83  bool ssl = false;
84  std::string caFile;
85  std::string certFile;
86  std::string keyFile;
87  bool verifyCertificate = true;
88  bool useIdForHostnameVerification = false;
89  bool oneWay = false;
90  bool fastSending = false;
91  bool sendFix = false;
92  uint32_t timeout = 10;
93  uint32_t interval = 100;
94  uint32_t waitForBus = 100;
95  uint32_t watchdogTimeout = 1000;
96  int32_t enableRXValue = -1;
97  int32_t enableTXValue = -1;
98  int32_t listenThreadPriority = -1;
99  int32_t listenThreadPolicy = SCHED_OTHER;
100  std::string ttsProgram;
101  std::string dataPath;
102  std::string user;
103  std::string password;
104  std::string passwordS21;
105  std::string passwordS22;
106  std::string passwordS23;
107  std::string additionalCommands;
108  std::string mode;
109  std::string serialNumber;
110  std::string uuid;
111 };
112 
113 typedef std::shared_ptr<PhysicalInterfaceSettings> PPhysicalInterfaceSettings;
114 
115 }
116 }
117 #endif
std::string passwordS23
Definition: PhysicalInterfaceSettings.h:106
GPIOSetting()
Definition: PhysicalInterfaceSettings.h:48
std::string listenPort
Definition: PhysicalInterfaceSettings.h:81
std::string id
Definition: PhysicalInterfaceSettings.h:60
std::string password
Definition: PhysicalInterfaceSettings.h:103
std::unordered_map< std::string, PVariable > all
Definition: PhysicalInterfaceSettings.h:59
std::string type
Definition: PhysicalInterfaceSettings.h:64
virtual ~GPIOSetting()
Definition: PhysicalInterfaceSettings.h:49
std::string additionalCommands
Definition: PhysicalInterfaceSettings.h:107
std::string user
Definition: PhysicalInterfaceSettings.h:102
Definition: BaseLib.cpp:34
Definition: PhysicalInterfaceSettings.h:46
Definition: PhysicalInterfaceSettings.h:55
std::map< uint32_t, GPIOSetting > gpio
Definition: PhysicalInterfaceSettings.h:66
std::string listenIp
Definition: PhysicalInterfaceSettings.h:80
std::string serialNumber
Definition: PhysicalInterfaceSettings.h:109
std::string passwordS22
Definition: PhysicalInterfaceSettings.h:105
std::string caFile
Definition: PhysicalInterfaceSettings.h:84
std::string portKeepAlive
Definition: PhysicalInterfaceSettings.h:78
std::string lanKey
Definition: PhysicalInterfaceSettings.h:82
std::shared_ptr< Variable > PVariable
Definition: PhysicalInterfaceSettings.h:41
std::string mode
Definition: PhysicalInterfaceSettings.h:108
std::string port3
Definition: PhysicalInterfaceSettings.h:76
std::string host
Definition: PhysicalInterfaceSettings.h:73
Definition: Variable.h:76
std::string passwordS21
Definition: PhysicalInterfaceSettings.h:104
std::shared_ptr< PhysicalInterfaceSettings > PPhysicalInterfaceSettings
Definition: PhysicalInterfaceSettings.h:113
int32_t number
Definition: PhysicalInterfaceSettings.h:51
std::string uuid
Definition: PhysicalInterfaceSettings.h:110
std::string dataPath
Definition: PhysicalInterfaceSettings.h:101
std::string port
Definition: PhysicalInterfaceSettings.h:74
std::string keyFile
Definition: PhysicalInterfaceSettings.h:86
std::string ttsProgram
Definition: PhysicalInterfaceSettings.h:100
std::string port2
Definition: PhysicalInterfaceSettings.h:75
std::string path
Definition: PhysicalInterfaceSettings.h:52
std::string port4
Definition: PhysicalInterfaceSettings.h:77
std::string device
Definition: PhysicalInterfaceSettings.h:63
std::string certFile
Definition: PhysicalInterfaceSettings.h:85