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
e10bc6a4
Commit
e10bc6a4
authored
Dec 21, 2020
by
Eric Duminil
Browse files
Adding debug info
parent
3ace1b61
Changes
1
Hide whitespace changes
Inline
Side-by-side
co2_sensor.cpp
View file @
e10bc6a4
...
...
@@ -84,6 +84,8 @@ namespace sensor {
static
int16_t
previous_co2
=
0
;
if
(
co2
>
(
previous_co2
-
30
)
&&
co2
<
(
previous_co2
+
30
))
{
stable_measurements
++
;
Serial
.
print
(
"Stable since : "
);
Serial
.
println
(
stable_measurements
);
waiting_color
=
color
::
green
;
}
else
{
stable_measurements
=
0
;
...
...
@@ -142,7 +144,9 @@ namespace sensor {
* Fresh data. Show it and send it if needed.
*/
if
(
freshData
)
{
countStableMeasurements
();
if
(
should_calibrate
)
{
countStableMeasurements
();
}
timestamp
=
ntp
::
getLocalTime
();
Serial
.
println
(
timestamp
);
...
...
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