genielabs / HomeGenie

HomeGenie, the programmable automation intelligence
https://homegenie.it
GNU General Public License v3.0
388 stars 154 forks source link

OpenWeatherMap enhancement? #378

Closed tuicemen closed 5 years ago

tuicemen commented 5 years ago

@genemars I love the new weather program which replaces WU. The options for triggering are much greater. Could you include humidity like the rain, wind, temperature and pressure sensors? I know others would find this very useful. I know the JkUtilsOpenWeather has this so it should be an easy enhancement.

tuicemen commented 5 years ago

I managed to add the humidity sensor code to this with 2 simple lines so it may be worth examining the OpenWeatherMap APi to see what else may be possible. I know this originally offered more info then WU.

tuicemen commented 5 years ago

@genemars Although I don't use imperial measurements though in the US many do so this would be another enhancement if possible as mentioned here #376. Since I've not dug into the Openweather API I'm not sure if all values can be retrieved based on the unit or if each would need to be converted. So that may be a bit more work.

tuicemen commented 5 years ago

@genemars I'm not sure why I never noticed this before (I guess I never had this loaded to my dashboard) the latest HG 1.3-beta.2 has the OpenWeatherMap widget displaying values in Fahrenheit even though °C is displaying also HG now displays the info top right in Fahrenheit. I think I read somewhere this was auto calculated based on location. I'm in Canada and we use metric however I wonder if me being close to the boarder maybe the cause. I also noticed the min max values are the same and shown not shown in metric either. Interestingly values are in metric if I create a script using values from the OpenweatherMap program.

genemars commented 5 years ago

@tuicemen internally HG stores everything in celsius then the UI makes the conversion based on the user preference (not location): from maintenance menu, scroll down to "User Interface" and select Celsius or Fahrenheit. Isn't that working?

tuicemen commented 5 years ago
OWM

I don't see that settings however I may have screwed up the app when I added the humidity option to the program so I could have the humidity value triggering devices

tuicemen commented 5 years ago

@genemars I just loaded a old backup sd card to my RPi and updated to latest beta and got some strange results with this. in Programs it still sees WU but when I Open it it says it is OPM even after a recompile and entering in my api key. also it still only displays the options as posted above. I just reread your post and also checked my user interface, Celsius is selected

tuicemen commented 5 years ago

@genemars I got it displaying correctly I changed the theme and that did it returning to my old theme (A) and the °C setting stuck so there may be something to that. this worked for both my RPis.

noliono commented 5 years ago

I don't see that settings however I may have screwed up the app when I added the humidity option to the program so I could have the humidity value triggering devices

Did you try the test propose by gene (not in the program settings) ?

from maintenance menu, scroll down to "User Interface" and select Celsius or Fahrenheit. Isn't that working?

tuicemen commented 5 years ago

@noliono, yes did the setting @genemars stated. I was already set to use Celsius so I switched to Fahrenheit and back with no change however switching my theme from "A" to "B" cause every thing to report Celsius. This worked for three different SD card images on two different RPi boards. Switching back to theme "A" kept everything reporting in Celsius.

tuicemen commented 5 years ago

@genemars I just updated one of my RPi to the latest 1.3-stable.3 and had hoped to see some fixes to the OpenWeatherMap program or widget however there are still lots of issues with this which I'm becoming more aware of now with attempting to create a Weather Alerting and triggering program. almost all issues are with the value conversions from metric not being done for the widget or the values you can use for macros. I'll close this issue and open a new one detailing my findings as this one is getting confusing.