File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -137,6 +137,7 @@ var stationValves = {};
137137var controllerWind = null ;
138138var controllerWindDir = null ;
139139var controllerRain = null ;
140+ var controllerRainDiff = null ;
140141var controllerRadiation = null ;
141142var controllerLuminosity = null ;
142143var controllerTemperature = null ;
@@ -550,6 +551,7 @@ function updateWeatherStation(response) {
550551 controllerWindDirInfowElement . innerText = weatherStationStatus [ ID_WIND_DIR ] ;
551552
552553 // Update the rain value.
554+ controllerRainDiff = weatherStationStatus [ ID_RAIN ] ;
553555 controllerRain = weatherStationStatus [ ID_RAIN_ACC ] ;
554556 let controllerRainElement = document . getElementById ( ID_RAIN_ACC ) ;
555557 if ( controllerRainElement != null )
@@ -956,7 +958,8 @@ function updateCurrentWeather() {
956958 currentWeatherIcon = SUN_GREEN ;
957959 currentWeatherStatus = "sunny" ;
958960
959- rain = document . getElementById ( "rain_acc" ) . innerText ;
961+ //rain = document.getElementById("rain_acc").innerText;
962+ rain = controllerRainDiff
960963 rain = parseInt ( rain )
961964 luminosity = document . getElementById ( "luminosity" ) . innerText ;
962965 luminosity = parseInt ( luminosity )
You can’t perform that action at this time.
0 commit comments