Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
co2ampel
ampel-firmware
Commits
7f930549
Commit
7f930549
authored
Feb 11, 2022
by
Eric Duminil
Browse files
Save timers to config
parent
e2fb6ded
Pipeline
#5790
failed with stage
in 1 minute and 46 seconds
Changes
6
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
ampel-firmware/co2_sensor.cpp
View file @
7f930549
...
...
@@ -305,6 +305,7 @@ namespace sensor {
Serial
.
println
(
F
(
"s (change will only be applied after next measurement)."
));
scd30
.
setMeasurementInterval
(
timestep
);
config
::
measurement_timestep
=
timestep
;
config
::
save
();
led_effects
::
showKITTWheel
(
color
::
green
,
1
);
}
}
...
...
ampel-firmware/csv_writer.cpp
View file @
7f930549
...
...
@@ -176,6 +176,7 @@ namespace csv_writer {
Serial
.
print
(
F
(
"Setting CSV Interval to : "
));
Serial
.
print
(
config
::
csv_interval
);
Serial
.
println
(
"s."
);
config
::
save
();
led_effects
::
showKITTWheel
(
color
::
green
,
1
);
}
...
...
ampel-firmware/lorawan.cpp
View file @
7f930549
...
...
@@ -239,6 +239,7 @@ namespace lorawan {
Serial
.
print
(
F
(
"Setting LoRa sending interval to : "
));
Serial
.
print
(
config
::
lorawan_sending_interval
);
Serial
.
println
(
"s."
);
config
::
save
();
led_effects
::
showKITTWheel
(
color
::
green
,
1
);
}
}
...
...
ampel-firmware/mqtt.cpp
View file @
7f930549
...
...
@@ -188,6 +188,7 @@ namespace mqtt {
Serial
.
print
(
F
(
"Setting MQTT sending interval to : "
));
Serial
.
print
(
config
::
mqtt_sending_interval
);
Serial
.
println
(
"s."
);
config
::
save
();
led_effects
::
showKITTWheel
(
color
::
green
,
1
);
}
...
...
ampel-firmware/web_config.cpp
View file @
7f930549
...
...
@@ -292,6 +292,9 @@ namespace config {
float
&
temperature_offset
=
web_config
::
temperatureOffsetParam
.
value
();
// [K] Sign isn't relevant.
bool
&
wifi_active
=
web_config
::
ampelWifiParam
.
value
();
void
save
()
{
web_config
::
iotWebConf
->
saveConfig
();
}
// LEDs
uint8_t
&
max_brightness
=
web_config
::
maxBrightnessParam
.
value
();
...
...
ampel-firmware/web_config.h
View file @
7f930549
...
...
@@ -19,6 +19,7 @@ namespace config {
extern
float
&
temperature_offset
;
// [K] Sign isn't relevant.
extern
bool
&
wifi_active
;
// [true / false]
void
save
();
// Save config to EEPROM
// LED
extern
uint8_t
&
max_brightness
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment