Is anyone doing anything with weather underground

Thank you very much for that!

Did that fix it for you?

I havenā€™t had a chance to test it out, but it makes more sense to me looking at it. Iā€™ll try it out and report back. Cheers.

Now I know that this is probably a weird question, butā€¦
Can this be set up to show what the weather was a few hours ago?

No, but if you use the forecast.io platform or OWM and click on any of the sensors, they will show you history.

Sorry, my bad. Let me rephrase my question:

Can the current sensor value display what the temperature was a few hours ago?

Did we figure out the update issue?

I havenā€™t heard anything from @kellbot on the subject, nor do I see any updates on Git.

I have an update to fix the missing UV index data. In the sensor template for the UV sensor, change the case from

pws_uv:
   value_template: '{{ states.sensor.weather_underground_pws.attributes.uv }}'

to:

pws_uv:
   value_template: '{{ states.sensor.weather_underground_pws.attributes.UV }}'

Sorry I missed that!

Has anybody figured out the update/refresh issue? @kellbot seems to be MIA and this is the only thing holding this platform up from being outstanding.

No luck on my end. At first I thought it was just grabbing cached data, so I commented out the throttle code, but that made no difference. I may have to rewrite the whole thing and test each stage to see if it updates. I just donā€™t understand HA enough to do any real troubleshooting. I just need a way to see what this module is doing via logs or something elseā€¦

I wish I could offer some help but my Python knowledge is very basic. I wonder if the problem was somewhere here:

from datetime import timedelta

CONF_PWS_ID = 'pws_id'
_RESOURCE = 'http://api.wunderground.com/api/'

# Return cached results if last scan was less then this time ago.
MIN_TIME_BETWEEN_UPDATES = timedelta(seconds=300)

in the use of timedelta?

Yeah, I commented out both the from datetime and the variable MIN_TIME_BETWEEN_UPDATES lines among others when i was referring to the throttle codeā€¦ no luck yet :confused:

1 Like

Thanks to @kellbot for all the workā€¦I was able to update the sensor. Created a new thread in share your project.

Nicely done @arsaboo! Thanks everyone else who made this happen!

Thanks for getting the updates to work @arsaboo! Iā€™ve posted underneath your new post with the pictures, instructions and the updated YAML files, so you can edit your post to remove the link (it was pointing to the older files anyway).

I merged @arsabooā€™s changes into my version of the repo as well, so anyone whoā€™s on mine can just git pull origin master to get the fixed code. Thanks for picking up the pieces everyone!

Coolā€¦will work on it to improve how the sensors are added and only the relevant details are saved.

@kellbot I have three things to add @ https://github.com/AlucardZero/hass-wunderground/commits/add-forecast

  1. switch to https, because why not
  2. add forecast data
  3. correct some Readme typos and document forecast a bit

Do you want a straight pull request of everything?

1 Like

To circle back to this, once you have a WU API key you can get a local radar picture and display it in HASS. Now, do not use a generic camera component with a still_image_url, or you will quickly go over your API limits. Instead, use a cron job / scheduled task to download the file, say, every 15 minutes, and use a local_file camera instead,

Example cron entry to download an animated radar image every 15 minutes, see the API documentation for the options:

# m h dom mon dow command */15 * * * * wget -qO /home/hass/weather.gif "https://api.wunderground.com/api/KEY/animatedradar/q/ST/TOWN.gif?newmaps=1&timelabel=1&timelabel.y=10&num=10&delay=50&noclutter=1&rainsnow=1&radius=15&height=400&width=400"
One remaining quirk is the height and width is dynamic in HASS based on browser size, so Iā€™m not sure what to do about the image scaling.
Then in your HASS config:

camera: platform: local_file file_path: /home/hass/weather.gif name: Recent Radar

1 Like