WebUpdate for auto BME detect
This commit is contained in:
parent
6ecb733bea
commit
0a15813ef2
|
|
@ -840,42 +840,46 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row mt-3">
|
||||
<div class="col-12">
|
||||
<label for="bme.heightCorrection" class="form-label"
|
||||
>Heigh Correction</label
|
||||
>
|
||||
<input
|
||||
type="number"
|
||||
name="bme.heightCorrection"
|
||||
id="bme.heightCorrection"
|
||||
placeholder="0"
|
||||
class="form-control"
|
||||
step="1"
|
||||
min="0"
|
||||
/>
|
||||
<span class="input-group-text"
|
||||
>meters</span
|
||||
>
|
||||
</div>
|
||||
<div class="col-12 mt-3">
|
||||
<label for="bme.temperatureCorrection" class="form-label"
|
||||
>Temperature Correction</label
|
||||
>
|
||||
<input
|
||||
type="number"
|
||||
name="bme.temperatureCorrection"
|
||||
id="bme.temperatureCorrection"
|
||||
placeholder="0.0"
|
||||
class="form-control"
|
||||
step="0.1"
|
||||
min="-5"
|
||||
max="5"
|
||||
/>
|
||||
<span class="input-group-text"
|
||||
>C°</span
|
||||
>
|
||||
<div class="row mt-3">
|
||||
<div class="col-6">
|
||||
<label for="bme.heightCorrection" class="form-label"
|
||||
>Height Correction (Above Sea-Level)</label
|
||||
>
|
||||
<div class="input-group">
|
||||
<input
|
||||
type="number"
|
||||
name="bme.heightCorrection"
|
||||
id="bme.heightCorrection"
|
||||
placeholder="0"
|
||||
class="form-control"
|
||||
step="1"
|
||||
min="0"
|
||||
/>
|
||||
<span class="input-group-text"
|
||||
>meters</span
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
<label for="bme.temperatureCorrection" class="form-label"
|
||||
>Temperature Correction</label
|
||||
>
|
||||
<div class="input-group">
|
||||
<input
|
||||
type="number"
|
||||
name="bme.temperatureCorrection"
|
||||
id="bme.temperatureCorrection"
|
||||
placeholder="0.0"
|
||||
class="form-control"
|
||||
step="0.1"
|
||||
min="-5"
|
||||
max="5"
|
||||
/>
|
||||
<span class="input-group-text"
|
||||
>C°</span
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ function loadSettings(settings) {
|
|||
// document.getElementById("stationMode").value = settings.stationMode;
|
||||
document.getElementById("bme.active").checked = settings.bme.active;
|
||||
document.getElementById("bme.heightCorrection").value = settings.bme.heightCorrection;
|
||||
document.getElementById("bme.temperatureCorrection").value = settings.bme.temperatureCorrection;
|
||||
document.getElementById("bme.temperatureCorrection").value = settings.bme.temperatureCorrection.toFixed(1);
|
||||
|
||||
document.getElementById("beacon.comment").value = settings.beacon.comment;
|
||||
document.getElementById("beacon.symbol").value = settings.beacon.symbol;
|
||||
|
|
|
|||
|
|
@ -216,18 +216,12 @@ namespace BME_Utils {
|
|||
fifthLine = "";
|
||||
return wx;
|
||||
} else {
|
||||
//
|
||||
Serial.print("correccion temperatura: "); Serial.println(Config.bme.temperatureCorrection);
|
||||
//
|
||||
tempStr = generateTempString(((newTemp + Config.bme.temperatureCorrection) * 1.8) + 32);
|
||||
if (wxModuleType == 1 || wxModuleType == 3) {
|
||||
humStr = generateHumString(newHum);
|
||||
} else if (wxModuleType == 2) {
|
||||
humStr = "..";
|
||||
}
|
||||
//
|
||||
Serial.print("correccion altura: "); Serial.println(Config.bme.heightCorrection);
|
||||
//
|
||||
presStr = generatePresString(newPress + (Config.bme.heightCorrection/CORRECTION_FACTOR));
|
||||
fifthLine = "BME-> " + String(int(newTemp))+"C " + humStr + "% " + presStr.substring(0,4) + "hPa";
|
||||
wx = ".../...g...t" + tempStr + "r...p...P...h" + humStr + "b" + presStr;
|
||||
|
|
|
|||
Loading…
Reference in New Issue