Running OH v1.8.1, and using Wunderground with the weather binding. I copied the item definitions from here:
// new total property in 1.8, only Wunderground
Number Precip_Total "Precip total [%d mm]" {weather="locationId=home, type=precipitation, property=total"}
Number Precip_Total_Inches "Precip total [%d in]" {weather="locationId=home, type=precipitation, property=total, unit=inches"}
The first works and returns a value, however when trying to get ‘inches’ of total precipitation the item returns simply ‘Err’. Anyone else face this issue?
I’ve not seen this error but I’ ve not tried to do anything with precipitation. But your example is character for character identical to the example in the wiki as far as I can tell.
Yea, it doesn’t work adding the unit=inches. You have to proxy an item
2 items:
Number WB_Precip_Total_Inches “Precip total [%.2f in]” (Weather, WeatherDisplay)
Number WB_Precip_Total_MM “Precip total [%d mm]” (Weather, WeatherDisplay) {weather=“locationId=Home, type=precipitation, property=total”}
1 rule:
rule "Convert PrecipTotal MM to IN"
when
Item WB_Precip_Total_MM received update
then
/* Weather biniding wunderground inches broken for total precip - using proxy item */
var Number PrecipIN = (((WB_Precip_Total_MM.state as DecimalType)) / 25.4)
postUpdate(WB_Precip_Total_Inches, PrecipIN);
end