Dries
(Dries)
June 10, 2017, 9:56am
8
Hi,
This is how I defined my item:
Number Tex_Window_W16_EV_MasterBedroom_Rechts "Raam Slaapkamer K&D rechts [MAP(windows.map):%s]" <raam> (gAlarm, gEV_MasterBedroom, gRamen, gAircocontact)
This is what I have mentioned in my sitemap:
Text item=Tex_Window_W16_EV_MasterBedroom_Rechts
My files are in the folder conf\icons\classic:
When I check BasicUI via my Chromebrowser (even my Chrome browser on my Android), it works fine:
When checking the same sitemap using the Android app, I get:
So I don’t think it is related to .items or .sitemap configuration. Maybe it is a bug in the Android app?
sihui
(SiHui)
June 10, 2017, 11:13am
9
Did you try deleting the picture cache through options menu?
Lolodomo
(Lolodomo)
June 10, 2017, 1:55pm
10
It is due to the MAP you are using and a bug I fixed few months ago.
What version of OH are you rumning?
The bug is inside official OH 2.0.
Dries
(Dries)
June 10, 2017, 2:44pm
11
Hi Lolodomo,
Thanks for fixing the bug!
I have OpenHAB 2.1 (snapshot - #838 (from mid March)).
My Android app is 1.8.0.6 (the most recent version).
In which release is this bug fixed?
@sihui : clearing the cache did not help…
Lolodomo
(Lolodomo)
June 10, 2017, 2:54pm
12
The fix was available in the snapshots built after the 20th of March.
1 Like
Dries
(Dries)
June 10, 2017, 5:07pm
13
Ok, thanks!
I’ll upgrade somewhere next week. I’ll let you know if that fixed the issue.
Dries
(Dries)
June 12, 2017, 4:17pm
14
I upgraded to snapshot #946 today and I can confirm my icons are working correct. Thanks!
How did you get to display the time at the end of the text
Dries
(Dries)
June 13, 2017, 7:01am
16
Hi,
I update the label using a rule:
when
Item myitem received update
then
var label = myitem.label.toString.split(" ")
myitem.label = label.get(0) + " " + " " + " (" + myitem.lastUpdate.toDateTime.toString("dd-MM-yy HH:mm") + ")"
end
Related topics:
Using .rules-variable as item label
Adding timestamp in my label
Good luck!
3 Likes
I was used to updating an item with time but never a label. Never realized that was possible. tnx
Dries, should that be val label or var label?.
Your linked post uses “val”
Dries
(Dries)
August 7, 2017, 6:22am
20
I checked my code, I use “var”. But honestly, I forgot why.
1 Like
I got neither working yet, but seems you have been struggling a lot as well to get it right. I will just try a bit more. Thanks for showing this possibility
Dries
(Dries)
August 7, 2017, 6:48am
22
Hi Kees,
We are a bit getting off-topic here, so I suggest we continue in this thread if you have follow up questions.
Here is another code snippet from my side (that works):
postUpdate(GiraDCS_History_00, "Zijdeur - " + GiraDCS_Zijdeur.lastUpdate.toDateTime.toString("dd-MM-yy HH:mm"))
GiraDCS_History_00.label = GiraDCS_History_00.state.toString
Try something simple if that doesn’t work, such as:
myitem.label = "Blablabla"
Also, what OH version do you have? The label-update seems to be something rather new (I think OH 2.1 or above).
1 Like
angusc
(Chris Angus)
March 18, 2018, 9:02am
23
Hello there,
Day 5 of using OpenHab 2 and finally got a sitemap and weather and Astro things working. I have added some .svg custom Icons to the /openhab2/icons/classic folder nd they are appearing on my UI on PC. However in the Android app they do not appear, while the other “buit-in” icons all display. I searched and found this thread from over a year ago reporting the same issues. Was the Android app interface app never udated? Or do I have to change then from .svg to .png and activate their use in the settings of Paper UI?
Thanx and regrds
Chris
freugo
(Hugo Frederix)
March 18, 2018, 9:17am
24
Hi Chris,
It worked for me by changing the icons to .png.
Regards,
Hugo.
You can change the icon format in the android app settings to SVG.
angusc
(Chris Angus)
March 19, 2018, 1:07pm
26
Perfect thank you! I did not think to check the app settings as the standard icons were appearing. Selecting svg income in the app fixed the issue.
Homer-Sim
(Homer Sim)
May 9, 2018, 10:54pm
27
I found this threat after having similar issues.
But I solved it with saving for each icon a svg and a png version (identical filename)
Is working perfectly.