equal
deleted
inserted
replaced
106 res = dict(URI=cfg("Server_URI"), AuthType=AuthType) |
106 res = dict(URI=cfg("Server_URI"), AuthType=AuthType) |
107 |
107 |
108 paramList = authParams.get(AuthType, None) |
108 paramList = authParams.get(AuthType, None) |
109 if paramList: |
109 if paramList: |
110 for name,default in paramList: |
110 for name,default in paramList: |
111 res[name] = cfg("AuthType."+name) |
111 value = cfg("AuthType."+name) |
|
112 if value == "" or value is None: |
|
113 value = default |
|
114 # cryptomaterial is expected to be in project's user provide file directory |
|
115 if name in ["Certificate","PrivateKey"]: |
|
116 value = os.path.join(self.GetCTRoot()._getProjectFilesPath(), value) |
|
117 res[name] = value |
112 |
118 |
113 print(res) |
|
114 return res |
119 return res |
115 |
120 |
116 def GetFileName(self): |
121 def GetFileName(self): |
117 return os.path.join(self.CTNPath(), 'selected.csv') |
122 return os.path.join(self.CTNPath(), 'selected.csv') |
118 |
123 |
131 c_file.write(c_code) |
136 c_file.write(c_code) |
132 |
137 |
133 LDFLAGS = [' "' + os.path.join(Open62541LibraryPath, "libopen62541.a") + '"'] |
138 LDFLAGS = [' "' + os.path.join(Open62541LibraryPath, "libopen62541.a") + '"'] |
134 |
139 |
135 CFLAGS = ' '.join(['-I"' + path + '"' for path in Open62541IncludePaths]) |
140 CFLAGS = ' '.join(['-I"' + path + '"' for path in Open62541IncludePaths]) |
|
141 |
|
142 # Note: all user provided files are systematicaly copied, including cryptomaterial |
136 |
143 |
137 return [(c_path, CFLAGS)], LDFLAGS, True |
144 return [(c_path, CFLAGS)], LDFLAGS, True |
138 |
145 |
139 def GetVariableLocationTree(self): |
146 def GetVariableLocationTree(self): |
140 current_location = self.GetCurrentLocation() |
147 current_location = self.GetCurrentLocation() |