Things configuration file: How to add a name and location

Hi,

during the migrating from OH1 to OH2 I want to use configuration files instead of using the PaperUI for defining things…
The migration from OH1 to OH2 is already finished, using OH1 bindings. I’m now using a 2nd OH2 installation to prepare the move from the OH1 to OH2 bindings. So currently I’m defining the things in configuration files. Works like a charm - only problem is that I haven’t found a way to define the name and location of the thing in the configuration file. So now I’ve a bunch of “Funk-Schaltaktor 1-fach, Unterputzmontage” in the Paper UI - only way to identify them is by looking at the address “LEQ012234”. Is there anyway to define name and location in the configuration file? I can’t use PaperUI for those parameters because the thing itself is stored in the configuration file and those are read only for PaperUI,
THX

Thomas

Hello Thomas,
from your text it did not get clear to me if you followed the official documentation. As stated in the Homematic Binding doc, you need to build a things file and then derive a items file from it. Let me show you my configuration as an example: things, items 1, items 2

Hi Thomas,

actually I took your config files as blueprint for my configuration (thanks for publishing your config!)
So the configuration itself is working fine, also no problems linking the items.
I just want to give the things custom name and possibly a location, because that would make it easier to identify them in the PaperUI Configuration - also to group them in the Basic UI.

So it would be great if there is some kind of parameter in the thing Configuration like

Thing HG-BC-SC-Rd-WM-2 LKF0012944 [name=“Bathroom Window”]

Without the possibility to give a custom name via the thing configuration file it looks like that:

Configuration / Things

Thomas

Good question. Maybe @gerrieg can tell more about that?

The names are fetched from the gateway, you have to set the names there.

Reading the following, you can set a name in the .things file.

https://www.eclipse.org/smarthome/documentation/features/dsl.html

This is working for me with different bindings.

2 Likes

@gerrieg : I’ve added the name in homegear to the actors - but then the entry for the thing in OH2 showed “No Description” - before it was showing at least the Actor description (like Max Fensterkontakt)

@hmerk : Thanks! that is exactly what I was looking for!!

So for others as reference, copied from the link posted by Hans-Jörg:

Thing yahooweather:weather:losangeles "Los Angeles" @ "home" [ location="2442047", unit="us", refresh=120 ]

Los Angeles would be the name of the Thing and home the location.
Here as example parts of my homematic things configuration file:

Bridge homematic:bridge:homegear [gatewayAddress="192.168.0.60",gatewayType="auto" ]
{
    Thing   HG-HM-CC-RT-DN      	LEQ12345678  "Heating Kitchen"  @  "Kitchen"
}

Thomas

2 Likes

Great that I could help.

Best
Hans-Jörg

@ThomasH
Did you reload the page in PaperUI? Sometimes the descriptions are not shown and you have to reload the page. It’s a PaperUI issue. If it still does not work, then i have to take a look.

@hmerk
Thanks for the link, i didn’t know that!

That’s great! Would you or @ThomasH care to include this in the homematic readme?

@ThomDietrich I’ve updated the readme.md and created a pull request - my first commit on Github - so sorry in advance if I did anything wrong :wink:

1 Like