Hap Panel Weather Data in US Units

New to OH2 & Habpanel. Have been able to slog through most all problems except how to display Netatmo data in US units. Have searched and tried all suggestions found on this forum but nothing works. I have tried the Netatmo widget, plain dummy widget, and even some custom widgets but always the same result. I can either display °C properly formated with 1 decimal (0.0) or °F with 10 decimals (32.xxxxxxxxxxxx) but never °F with one decimal (32.0).

Netatmo binding, thing & items are all working in both PaperUI “control” display and Openhab Android app. Problem seems to be exclusively in the Habpanel app.

Why must this be so difficult? Can someone please post a detailed (and hopefully simple) way to display formatted US weather units in Habpanel? If I must install some files not installed in the standard Raspberry OH2 build then please identify.

The sample custom widget at Template widget - tutorial & examples - make your own widget! is exactly what I am trying to do. This code would be a good base for explaining how to format in US units.

Post your items and a screen shot of the dummy widget your are trying to configure
Why not trying to use °C anyway. At least Centigrade makes sense… :wink:

1 Like

Trying to keep it simple until I get it working. Working only with this one item for now.

Number:Temperature NA_Indoor_Temp_F “Indoor Temperature [%.1f °F]” {channel=“netatmo:NAMain:xxxxxxxx:xxxxxxxxxxxx:Temperature”}

No need to post screen shot of “dummy” widget. Just shows a number with 10+ decimal places. Besides, cannot get to code of “dummy” widget to alter.

Formatting [%.1f °F] in item statement has no affect on Habpanel. And Habpanel offers no chance of formatting within the app.

If you download and install weather custom widget from forum topic shown in first post, the code is viewable and alterable - but I don’t know how. Can’t find the correct syntex to acheive proper format.

Will accept any solution you might come up with for converting Netatmo weather data to show in US units on Habpanel.

C° is fine for those used to it but retraining after a lifetime of using F° is not easy. And all US references are in F°.

What version of openHAB as you running?
Because HABPanel had an issue with units that has now been resolved.
Update to the latest milestone.

Currently running OH@ 2.3.0 release build

Update to the milestone 2.4

1 Like

Updated to MS 2.4.
Good news - Openhab widgets for netatmo now work with proper formatting.
Bad news - every other widget stopped working! Modbus binding disappeared and all other “things” related to modbus are “uninitiated”. Zwave binding is still there but also uninitiated.
So now what? Do I have to remove and reinstall bindings and all 24 modbus related things? Same with 6 Zwave “things”?
Maybe °C is better!

Can you help, here?

Reinstalled Modbus binding, removed other non-working things & reinstalled. Most items working again. Final question. Netatmo pressure is in mm. What format can I use to convert to inches?


Assuming that you item looks like this:

Number:Pressure NetatmoPressure "Pressure [%d mmHg]" { binding }

Your can display it in inches of mercury in the sitemap like this:

Text item=NetatmoPressure label="Pressure [%d inHg]

In HABpanel, you can try setting the format in the widget to %d inHg, I don’t know if the conversion will happen. If it doesn’t you’ll need a proxy item to convert

Got most everything working again after updating to MS4. Habpanel now seems to handle formatting much better and displays as expected. My “Pressure” item looks like this:

Number:Pressure NA_Indoor_Pressure_In “Pressure-In [%.1f inHg]” {channel=“netatmo:NAMain:xxxxxxxx:xxxxxxxxxxxx:Pressure”}

and it displays properly on Habpanel with formatting : %.1f inHg

I thank you for your help on this issue.

So with this problem solved, can you please answer a couple of questions about Habpanel in general?

  1. The state formatting in an item does not seem to affect formatting in Habpanel yet it must be there. The item statement formatting certainly is required for apps using the sitemap but why must you redefine it in Habpanel again if it is the same? I first assumed Habpanel ignores the item statement formatting but this seems not to be true. The two formats seem to be required to be the same. I have even gone as far as to try creating two almost identical items, one for sitemap apps, one for Habpanel , one with formatting, one without, but this now seems not to be required. Do you have any explanation for this requirement?

  2. In my item listing above, what does the initial “: Pressure” after “Number” accomplish? Some items seem to work OK without this initial additional value, some do not. Any explanation?

  3. Working on this Habpanel problem, I notice that some changes to either “items” or Habpanel widget definitions do not update immediately - sometimes yes, sometimes no. Many times I have gone to bed thinking I have had no success only to wake up and find the changes were successful. For example: last night the icon I used for “Pressure” refused to display in Habpanel then this morning it is displaying properly. Yes, I do reboot occasionally during many changes. Rebooting will sometimes correct (update) recent changes made but many times you just have to be patient for a very long time. This makes it very hard to try something and then make a valid determination whether the change worked or not. Is there a method to force updates to take immediately?

Thanks agin for all your help.

You must specify in the dummy widget wether to use a “local” format or the one specified by the OH server

Refresh the browser?

No, refreshing the browser does not work.