Hi community,
I updated to OH2.4 on RPI3 and since then do have the problem that I see the items in PaperUI and can as well control them, but they do not work in the sitemap.
Could this be an issue with the Java?
I installed following version together with OH:
openjdk version “1.8.0_212”
OpenJDK Runtime Environment (Zulu8.38.0.163-CA-linux_aarch32hf) (build 1.8.0_212-b163)
OpenJDK Client VM (Zulu8.38.0.163-CA-linux_aarch32hf) (build 25.212-b163, mixed mode, Evaluation)
thanks for your help.
I added your code in the sitemap, but it doesn´t show anything. See attached the full code of the test sitemap
sitemap default label=“Test” {
This is what is shown in the browser.
I also changed the name of Date to CurrentDate, but no change.
IN the log I just find the info that the NTP updated.
2019-07-05 11:40:37.114 [vent.ItemStateChangedEvent] - ntp_ntp_local_dateTime changed from 2019-07-05T11:40:07.069+0200 to 2019-07-05T11:40:37.076+0200
…but no related errors or so.
HI rossko57,
I found the issue. But it is not logic to me.
In my standard sitemap I had an old adress of the channel for the sunrise event. (astro binding)
When I corrected this, everything worked again.
But why the simple test sitemap with the simple CurrentDate item did not work I do not understand.
Because since I corrected the default sitemap, as well the test sitemap works.
Probably they are linked somehow.
ok, that makes sense. Then it is explained why it refered to the default sitemap.
But why the astro binding determines the current date even though ntp binding is installed is somehow strange to me. ;.)
there are some points you mix together. As @rossko57 said your using several DateTime-Items.
So let’s begin with the item:
DateTime Date "Date [%1$tA, %1$td.%1$tm.%1$tY %1$tH:%1$tM]" { channel="ntp:ntp:demo:dateTime" }
As Rossko said it would be better to give it another name (e.g. current_Date, ntp_currentDate, etc.). What you made is to describe your item including the formatter ( [%1$tA, %1$td.%1$tm.%1$tY %1$tH:%1$tM] ". That’s quite correct, if you’re using the right file-format to (utf-8) to save the file (and of course all files in the openhab-conf Folder).
So what you then made, was to define the item in the sitemap, like this:
Default item=Date "date [%s]"
So first this is not correct as you forgot the keyword “label=” for the description !!!
Second the formatter you are using here is not correct too.
So try to use it in this way:
Default item=Date /or whatever name you gave in the .items-file
or
Text item=Date
or
Text item=Current_DateTime label="Heute ist [%1$tA, %1$td.%1$tm.%1$ty]" valuecolor=["red"] labelcolor=["red"]
BTW: As Rossko said: We’re talking about the NTP-Binding (and channel(s) linked to an item) not about the Astro-Binding.
sorry was off one week for business.
Ok got the point. I just wanted to say I had installed as well the astro binding and fixed there a code bug as well and then the current time + sunset … was working again.
So my first conclusion was, the problem was in the astro binding, but I corrected the ntp description and astro at the same time.