AmbientWeather.net weather station binding

Looks good. I’ve implemented it and the 1404-ip seems to work for my 1002-wifi as well, at least for what I’ve tried. (They’re the same base units, just different interfaces).

Thank you!

I’m not sure if there’s something that can be done to better handle celsius vs fahrenheit – I did add a transform JS file, but perhaps OpenHAB has some built-in selectors?

The binding supports UOM (units of measure) functionality. If you define your items as Number:Temperature and have your locale configured in the openHAB system config, it should show the right units.

Great. If you notice any values that are missing, we can do a thing type for the 1002.

BTW, how’d you get an application key so fast? It usually takes a few hours, if not a day.

Will take a look at that later…

I’ve had it kicking around since I access the API with a few other tools as well. :slight_smile:

I don’t remember it taking that long last time, though… but I might be mistaken.

1 Like

I have a WS-2000 and it’s working well with the WS-2902A configuration… other than missing battery metrics. Thank you for this binding!

Now to find a replacement for wunderground’s forecasts.

1 Like

Does your WS-2000 send battery data to Ambient Weather? If so, I can create a WS-2000 thing with the battery info.

If you upload your weather data to Weather Underground, you can use my other binding to get a 5 day forecast from The Weather Company. :wink:

2 Likes

I have a ambient weather station and I can’t get it to communicate with OH. I downloaded eclipse so I could modify the key but now I can’t find anywhere to modify the .jar file.

Battery Data: “All Batteries OK” on the web UI and mobile app. I haven’t poked at the API. The 2902A and the 2000 use the same “Osprey” array. Just different consoles. I’m pretty sure they report the same way, and I’ve noticed my software version matches that of the 2902. They’re cut from the same cloth. I noticed another 2902 user reported same with battery. I’ll poll the API results and get back to ya… if I remember. :wink:

Oooh, I was hoping the mainline binding was updated to support these restricted APIs from “I Buy Mainframes” Yay! I think you might be my favorite developer this week. :wink:

Yeah, the data structures and API were very different, so it was essentially a rewrite.

I also thought they were being a bit lame with providing only a 5-day forecast. But it’s better than nothin’ (and it’s free!).

I should probably update my binding. I am still running the version I setup last time we talked. :slight_smile: Working great still.

Thank you for all your hard work on it.

Hi there, anybody tried this binding with MISOL Weather stations (this for example)? It’s looks like OEM manufacturer for Ambient Weather.

The weather station needs to upload data to ambientweather.net in order to be able to use this binding.

OTOH, I see this station uploads to Weather Underground. That being the case, you can use my WeatherCompany binding to get access to your PWS data, as well as a 5 day forecast.

1 Like

Yes, the Misol that I use can not change to be made to upload to AW cloud server.

Your close. The same factory in China makes them all and is called ‘fine offset’ and then multiple companies put their brand on the hardware.

Check this thread out as you can get the Misol ones working.

1 Like

I got this working with my 2902A in just a few minutes! Thanks for the info! If you happen to have a sitemap file which has the icons per item that’d be great! The one I found here:

didn’t have the fun icons you have going. If not, I’ll go through the icon set and apply them.

Also, the Application key auto-approved for me. I didn’t have to contact support.

Sorry, which icons are you referring to?

Right. He recently changed this process to make it easier to get the app key.

I went through and added the icons, just in the site map there as the example site map didn’t have any, but it was quick to add them.


I’ll poke around to see if the temperature icon can be dynamic like some of the others. For now I’m using the “heating” icon as the needle moves as the temp changes :slight_smile:

Thanks again for making this!!!

Thought I’d post, not sure if I’m the only one seeing this sometimes in my logs and something that looks like a Java error about it too:
2019-09-23 10:14:55.008 [WARN ] [pse.smarthome.core.items.GenericItem] - failed notifying listener 'org.eclipse.smarthome.model.rule.runtime.internal.engine.RuleEngineImpl@15ef8f' about state update of item WS2902A_RainHourlyRate: Can not compare incompatible units java.lang.IllegalArgumentException: Can not compare incompatible units. at org.eclipse.smarthome.core.library.types.QuantityType.compareTo(QuantityType.java:175) ~[133:org.openhab.core:2.5.0.M3] at org.eclipse.smarthome.core.library.types.QuantityType.equals(QuantityType.java:157) ~[133:org.openhab.core:2.5.0.M3] at org.eclipse.smarthome.core.items.GenericItem$1.run(GenericItem.java:261) [133:org.openhab.core:2.5.0.M3] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?] at java.lang.Thread.run(Thread.java:748) [?:?] 2019-09-23 10:15:57.102 [ERROR] [me.core.internal.events.EventHandler] - Creation of ESH-Event failed, because one of the registered event factories has thrown an exception: Error invoking #valueOf(String) on class 'org.eclipse.smarthome.core.library.types.QuantityType' with value '0.0 1/(h·h)'.
Here are my item file entries, with the mm/h commented out:

// Use this if your units are SI //Number:Speed WS2902A_RainHourlyRate "Rain Hourly Rate [%.1f mm/h]" { channel="ambientweather:ws2902a:7df2e2c2:weatherDataWs2902a#rainHourlyRate" } // Use this if your units are Imperial Number:Speed WS2902A_RainHourlyRate "Rain Hourly Rate [%.2f in/h]" { channel="ambientweather:ws2902a:7df2e2c2:weatherDataWs2902a#rainHourlyRate" }

Any thoughts? I’ll poke around on it a bit more too.

'org.eclipse.smarthome.model.rule.runtime.internal.engine.RuleEngineImpl@15ef8f' 

Thanks for reporting. It looks like this exception is being thrown from a rule. Can you post the body of the rule that is attempting to reference the WS2902A_RainHourlyRate item?

Hi Mark,
I actually don’t even have it in a rule, just my sitemap. My Openhab system is set to Imperial too. I have it set to mm/h right now but I receive this error sometimes:

2019-09-25 08:50:58.565 [WARN ] [pse.smarthome.core.items.GenericItem] - failed notifying listener 'org.eclipse.smarthome.model.rule.runtime.internal.engine.RuleEngineImpl@15ef8f' about state update of item WS2902A_RainHourlyRate: Unable to convert to system unit during compare. java.lang.IllegalArgumentException: Unable to convert to system unit during compare. at org.eclipse.smarthome.core.library.types.QuantityType.compareTo(QuantityType.java:172) ~[133:org.openhab.core:2.5.0.M3] at org.eclipse.smarthome.core.library.types.QuantityType.equals(QuantityType.java:157) ~[133:org.openhab.core:2.5.0.M3] at org.eclipse.smarthome.core.items.GenericItem$1.run(GenericItem.java:261) [133:org.openhab.core:2.5.0.M3] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?] at java.lang.Thread.run(Thread.java:748) [?:?] 2019-09-25 08:50:58.565 [WARN ] [pse.smarthome.core.items.GenericItem] - failed notifying listener 'org.eclipse.smarthome.core.persistence.internal.PersistenceManagerImpl@14077d3' about state update of item WS2902A_RainHourlyRate: Unable to convert to system unit during compare. java.lang.IllegalArgumentException: Unable to convert to system unit during compare. at org.eclipse.smarthome.core.library.types.QuantityType.compareTo(QuantityType.java:172) ~[133:org.openhab.core:2.5.0.M3] at org.eclipse.smarthome.core.library.types.QuantityType.equals(QuantityType.java:157) ~[133:org.openhab.core:2.5.0.M3] at org.eclipse.smarthome.core.items.GenericItem$1.run(GenericItem.java:261) [133:org.openhab.core:2.5.0.M3] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?] at java.lang.Thread.run(Thread.java:748) [?:?]

Items file:
Number:Speed WS2902A_RainHourlyRate "Rain Hourly Rate [%.1f mm/h]" { channel="ambientweather:ws2902a:7df2e2c2:weatherDataWs2902a#rainHourlyRate" }

Sitemap:
Text item=WS2902A_RainHourlyRate icon="rain"

I’ll just remove it from the sitemap and items file for now to keep the logs cleaner.

If it’s not referenced in a rule then I have no idea why RuleEngineImpl would be throwing an error.

What version of OH are you running?