mirror of
https://github.com/richonguzman/LoRa_APRS_iGate.git
synced 2026-04-05 06:26:46 +00:00
bme autodetect
This commit is contained in:
parent
7753618756
commit
f1e712a363
7 changed files with 149 additions and 104 deletions
|
|
@ -92,6 +92,8 @@ void Configuration::writeFile() {
|
|||
data["syslog"]["port"] = syslog.port;
|
||||
|
||||
data["bme"]["active"] = bme.active;
|
||||
data["bme"]["heightCorrection"] = bme.heightCorrection;
|
||||
data["bme"]["temperatureCorrection"] = bme.temperatureCorrection;
|
||||
|
||||
data["ota"]["username"] = ota.username;
|
||||
data["ota"]["password"] = ota.password;
|
||||
|
|
@ -155,6 +157,8 @@ bool Configuration::readFile() {
|
|||
syslog.port = data["syslog"]["port"].as<int>();
|
||||
|
||||
bme.active = data["bme"]["active"].as<bool>();
|
||||
bme.heightCorrection = data["bme"]["heightCorrection"].as<int>();
|
||||
bme.temperatureCorrection = data["bme"]["temperatureCorrection"].as<float>();
|
||||
|
||||
ota.username = data["ota"]["username"].as<String>();
|
||||
ota.password = data["ota"]["password"].as<String>();
|
||||
|
|
@ -325,6 +329,8 @@ void Configuration::init() {
|
|||
syslog.port = 514;
|
||||
|
||||
bme.active = false;
|
||||
bme.heightCorrection = 0;
|
||||
bme.temperatureCorrection = 0.0;
|
||||
|
||||
ota.username = "";
|
||||
ota.password = "";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue