Compare commits
2 Commits
78311082a9
...
856567adb2
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
856567adb2 | ||
|
|
7a67425d6d |
File diff suppressed because one or more lines are too long
@ -94,6 +94,12 @@
|
|||||||
background: rgba(150, 150, 150, 0.3);
|
background: rgba(150, 150, 150, 0.3);
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.valve-warning {
|
||||||
|
color: var(--color-ok);
|
||||||
|
font-size: 80%;
|
||||||
|
font-weight: normal;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
@ -248,9 +254,9 @@
|
|||||||
|
|
||||||
let warningHtml = "";
|
let warningHtml = "";
|
||||||
if (!isOpen && data.temp > data.t1) {
|
if (!isOpen && data.temp > data.t1) {
|
||||||
warningHtml = ' <span title="Otevřete ventil" style="cursor: help;">⚠️</span>';
|
warningHtml = ' <span class="valve-warning">⚠️ Otevřete ventil</span>';
|
||||||
} else if (isOpen && data.temp < data.t0) {
|
} else if (isOpen && data.temp < data.t0) {
|
||||||
warningHtml = ' <span title="Zavřete ventil" style="cursor: help;">⚠️</span>';
|
warningHtml = ' <span class="valve-warning">⚠️ Zavřete ventil</span>';
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isOpen) {
|
if (isOpen) {
|
||||||
|
|||||||
@ -30,10 +30,10 @@ static bool s_valve_open = false; // false = closed, true = open
|
|||||||
|
|
||||||
static float s_temp_accum = 0.0f;
|
static float s_temp_accum = 0.0f;
|
||||||
static int s_temp_count = 0;
|
static int s_temp_count = 0;
|
||||||
// constexpr int TEMP_INTERVAL = 10000; // 10 seconds
|
constexpr int TEMP_INTERVAL = 10000; // 10 seconds
|
||||||
constexpr int TEMP_INTERVAL = 1000;
|
// constexpr int TEMP_INTERVAL = 1000;
|
||||||
// constexpr int TEMP_AVERAGING_INTERVAL = 6*15; // 15 minutes (6 readings of 10 seconds each)
|
constexpr int TEMP_AVERAGING_INTERVAL = 6*15; // 15 minutes (6 readings of 10 seconds each)
|
||||||
constexpr int TEMP_AVERAGING_INTERVAL = 10;
|
// constexpr int TEMP_AVERAGING_INTERVAL = 10;
|
||||||
|
|
||||||
constexpr size_t TEMP_HISTORY_CAPACITY = 4*24*5; // 5 days of 15-minute intervals
|
constexpr size_t TEMP_HISTORY_CAPACITY = 4*24*5; // 5 days of 15-minute intervals
|
||||||
static float s_temp_history[TEMP_HISTORY_CAPACITY] = {0.0};
|
static float s_temp_history[TEMP_HISTORY_CAPACITY] = {0.0};
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user