Weather/Temp from online source

Made a minor update to my version of the driver. For the three capabilities I added, I had to change to lower-case the attribute title (they were all in Title-Case). I added those capabilities so I could use them in HousePanel, but HousePanel did not pull in the values until I changed them to lower-case.

Just an update on the problem I saw yesterday when there was no polling.
It looks like it occasionally does not poll. It misses the 5 minute poll.
As you can see from the events for the device below, there was no poll at 1:55pm.
image

@bobbles
@Matthew

Guys
I've posted a new driver which includes all the correct attributes for use with dashboards if you want to try that
I have also added a 'Weather Summary' which I hope to use later in WS

Thanks @Cobra. I added in lowercase illuminance and humidity in my version. I need those in lowercase for Housepanel. No other changes. Great work!

UPDATE: @Cobra has incorporated my small change into his driver. No need for my version now. Please just use his. Thanks @Cobra!

1 Like

@Matthew
The illuminence and humidity should have been there already!
They are sent by the ‘capabilities’ and should already be in the lowercase format
Did I miss the ‘sendEvents’ for these?

Where did you add your code?

Andy

Hmm... seems it was working for me

Have a look at the screenshot in this post (at the bottom)

Hi…
just spotted illuminence wasn’t there in the screen shot… I will update my code

Andy

I did miss lowercase humidity (it was there in your code). However, the sendEvent for lowercase illuminance is not. If you want to add that, I have no other changes. Thanks! Appreciate your work.

@Matthew
I have added the sendEvent for illuminence and added a lowercase ‘city’ which someone else asked me about.

Now version: 1.7.2

Andy

Excellent. Thank you. No need for my version now.

1 Like

FYI
Just uploaded version 1.8.0

Andy

1 Like

Is anybody else finding that the data is not being updated every 5 minutes. Mine is occasionally missing an update.

I use 10 minutes and I have not noticed it missing any updates.

I have left it the default of 5. May extend and see what happens.

Guys
I have just uploaded Version: 1.9.0
This has a couple of bug fixes and now has a couple of new attributes ‘Chance of Rain’ & ‘percentPrecip’

Andy

1 Like

I was not getting the Humidity (either upper or lower case) values to show in several dashboards (HousePanel and SmartTiles). Those dashboards show the humidity value as ‘null.’ In looking at examples that did work, it appeared that the humidity being reported by the driver was just the number and did not include the ‘%’ symbol. I altered the driver on lines 163 and 212 to the following:

sendEvent(name: "humidity", value: resp1.data.current_observation.relative_humidity.replaceFirst("%", "")) //, unit: "%")

That just removes the “%” symbol that is included in WeatherUnderground’s relative_humidity attribute. With that change my dashboards now are showing the humidity correctly.

I don’t know if this is unique to my use case or if it should be changed for other’s general use, but thought I would report on what I found.

Thanks.

@Matthew
Were you gettin a double % sign? (e.g. 60%%) or was it just not showing at all

Andy

They both just showed ‘%’ with no number. Those dashboards (HousePanel and SmartTiles) apparently need just the number and they add their own ‘%’ symbol as they both show correctly now (a number with a single ‘%’ at the end) after I removed the ‘%’ from the driver result.

2 Likes

@Matthew
Good find- thanks for that
I have the same issue with this on another thread.
I’ll make the same change to the lowercase setting (I use the uppercase one as my app does not add the %

Thanks again

Andy

Yes, the way it is supposed to work is the value should be a number and then a separate “units” setting for “F” or “C” or “%” would get passed to the device event state

That way when retrieving the attribute, you get {value:“58”, unit: “%”}

but most just put the unit in the value… Or override the unit (or ignore it)

2 Likes