Some API's added
API's added: - Network (get and add). - Login (token) - General System (only get info) - Wifi (set, scan, get)
This commit is contained in:
17
ConfigHandler.py
Normal file
17
ConfigHandler.py
Normal file
@@ -0,0 +1,17 @@
|
||||
import io
|
||||
|
||||
import yaml
|
||||
|
||||
|
||||
class ConfigHandler:
|
||||
camera_settings = {}
|
||||
|
||||
@staticmethod
|
||||
def load() -> yaml or None:
|
||||
try:
|
||||
stream = io.open("config.yml", 'r', encoding='utf8')
|
||||
data = yaml.safe_load(stream)
|
||||
return data
|
||||
except Exception as e:
|
||||
print("Config Property Error\n", e)
|
||||
return None
|
||||
Reference in New Issue
Block a user